Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

panic: index out of bounds: the len is 1 but the index is 1 #89

Open
Sinderella opened this issue May 5, 2024 · 2 comments
Open

panic: index out of bounds: the len is 1 but the index is 1 #89

Sinderella opened this issue May 5, 2024 · 2 comments

Comments

@Sinderella
Copy link

I am unable to provide the PDF file as it contains a lot of PII. Please let me know if it's really required, I can try to redact as much as I can. Cheers!

thread 'main' panicked at /$HOME/.cargo/registry/src/index.crates.io-6f17d22bba15001f/pdf-extract-0.7.6/src/lib.rs:1710:51:
index out of bounds: the len is 1 but the index is 1
stack backtrace:
   0: rust_begin_unwind
             at /rustc/7f2fc33da6633f5a764ddc263c769b6b2873d167/library/std/src/panicking.rs:652:5
   1: core::panicking::panic_fmt
             at /rustc/7f2fc33da6633f5a764ddc263c769b6b2873d167/library/core/src/panicking.rs:72:14
   2: core::panicking::panic_bounds_check
             at /rustc/7f2fc33da6633f5a764ddc263c769b6b2873d167/library/core/src/panicking.rs:268:5
   3: <usize as core::slice::index::SliceIndex<[T]>>::index
             at /rustc/7f2fc33da6633f5a764ddc263c769b6b2873d167/library/core/src/slice/index.rs:249:10
   4: core::slice::index::<impl core::ops::index::Index<I> for [T]>::index
             at /rustc/7f2fc33da6633f5a764ddc263c769b6b2873d167/library/core/src/slice/index.rs:18:9
   5: <alloc::vec::Vec<T,A> as core::ops::index::Index<I>>::index
             at /rustc/7f2fc33da6633f5a764ddc263c769b6b2873d167/library/alloc/src/vec/mod.rs:2907:9
   6: pdf_extract::Processor::process_stream
             at /$HOME/.cargo/registry/src/index.crates.io-6f17d22bba15001f/pdf-extract-0.7.6/src/lib.rs:1710:51
   7: pdf_extract::output_doc
             at /$HOME/.cargo/registry/src/index.crates.io-6f17d22bba15001f/pdf-extract-0.7.6/src/lib.rs:2234:9
   8: pdf_extract::extract_text_from_mem
             at /$HOME/.cargo/registry/src/index.crates.io-6f17d22bba15001f/pdf-extract-0.7.6/src/lib.rs:2169:9
...
@jrmuizel
Copy link
Owner

jrmuizel commented May 5, 2024

Do you know what tool was used to make the PDF?

@Sinderella
Copy link
Author

I don't know which exact tool was it, but exiftool gives me the following:

Creator                         : Vault Rendering Engine
Producer                      : Rendering Engine 7.4.1.9

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants