README tutorial not working
shanebenlolo opened this issue · comments
Hello, I am following the Rust tutorial found in the readme. when I run the example, I get an error on this line:
// Load a SPK/BSP file
let spk = SPK::load("../data/de440.bsp").unwrap();
I am receiving the following error:
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value:
DecodingData {
kind: "SPKSummaryRecord", idx: 0, source: InaccessibleBytes {
start: 0, end: 1024, size: 134
}
}'
Anise version: 0.2.1
OS: WSL2 with Ubuntu 22.04.2 LTS distro
if I run on Anise version 0.1.0 I get this error:
thread 'main' panicked at 'range end index 1024 out of range for slice of length 134', /home/shanebenlolo/.cargo/registry/src/index.crates.io-6f17d22bba15001f/anise-0.1.0/src/naif/daf/daf.rs:116:50
thank you for any help you can offer
Hi Chris,
thanks for the quick response. You are correct that the file seems to only contain 134 bytes which I verified by doing:
wc -c de440.bsp
134 de440.bsp
However when I run git lfs pull
I only get an error:
git lfs pull
git: 'lfs' is not a git command. See 'git --help'.
Perhaps I am missing some setup steps? The only setup I have done so far is pulled this repo and executed the dev-env-setup shell script found here: https://github.com/nyx-space/anise/blob/master/dev-env-setup.sh
You may also wish to have ANISE automatically download the latest planetary data, constants, ephemerides, and rotations by using the Meta Almanac : https://github.com/nyx-space/anise/blob/master/anise/src/almanac/metaload/mod.rs#L67. That will download the files to your computer's user cache folder, like AppData on Windows.
Oh, I see. You'll need to install the lfs extension to your local git application. On Linux, these packages are usually available under the name "git-lfs", so something like apt-get install git-lfs. On Windows, I'm not sure how to install it, but I know it's possible.
That did the trick, I had never head of Git LFS until now. Thank you for the help!