cessen / kobo_jp_dict

A Japanese-English dictionary builder for Kobo e-readers.
Apache License 2.0
32 stars 2 forks source link

Panic on no file or directory found? #9

Closed lxaw closed 1 year ago

lxaw commented 1 year ago

Hello! I am trying to use this app to convert my monolingual dictionaries. However, when running cargo run yomichan/明鏡国語辞典.zip -y dicthtml-ja-en.zip I get the error:

(base) lexingtonwhalen@LexingtonnoMBP ~/Desktop/personal/code/kobo_jp_dict % cargo run yomichan/明鏡国語辞典.zip -y dicthtml-ja-en.zip
    Finished dev [unoptimized + debuginfo] target(s) in 0.04s
warning: the following packages contain code that will be rejected by a future version of Rust: quick-xml v0.22.0
note: to see what the problems were, use the option `--future-incompat-report`, or run `cargo report future-incompatibilities --id 1`
     Running `target/debug/kobo_jp_dict 'yomichan/明鏡国語辞典.zip' -y dicthtml-ja-en.zip`
Extracting bundled data...
    Metadata entries: 191598
    Pitch Accent entries: 124135
Loading dictionaries...
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: Os { code: 2, kind: NotFound, message: "No such file or directory" }', src/main.rs:150:61
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

I have installed everything (including marisa). Any ideas?

lxaw commented 1 year ago

I think I figured it out. I needed to run cargo run -- -y yomichan/大辞泉.zip dicthtml-ja.zip (Note the -- -y)