Main application thread panicked

I'm getting main thread panicked when I install and run Rust binary I published to however it works fine when I execute cargo run -- in the project directory.

What could I be doing wrong.
Link to code repository : GitHub - opeolluwa/ths: Rust Command Line Application for scaffolding Node.js network applications
Crate name : stormz

File an issue with the repository.

It's my repository. Should I still file an issue?

Sorry, didn't realize it was yours.
You are using a relative path to access resources/5lineoblique.flf, which is why you are getting a file not found.
You can embed the file in your source code (if it is small enough) with include_bytes macro.
Alternatively, you have to move them to a standard location by an external build script, or via


I have a lot of files, embedding them would make the code ugly and hard to maintain. How do I execute moving them to a standard location by an external build script, or via I'm pretty new to rust

"Embedding" here means "replace the code which loads them at runtime with include_bytes!" (or include_str!, if they're Unicode text), not "copy their contents into the code".

1 Like

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.