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

Build types are inconsistent during local testnet build #1456

Open
loziniak opened this issue Mar 16, 2024 · 3 comments
Open

Build types are inconsistent during local testnet build #1456

loziniak opened this issue Mar 16, 2024 · 3 comments

Comments

@loziniak
Copy link
Contributor

loziniak commented Mar 16, 2024

When I'm running a local testnet using the command from README file:

cargo run --bin safenode-manager --features local-discovery -- run --build

The safenode-manager binary is built in debug mode, and then faucet is built in release mode. This takes twice as much time, and twice the storage space, because most libraries are shared among subprojects. I have both release and debug folders in safe_network/target.

@jacderida
Copy link
Contributor

Thanks for the feedback.

However, I can't really tell whether you'd like it to build the binaries in release or debug mode, because you are referencing a problem with both space and time. You can't have both. Either we build in debug mode and we use more space, or we build in release mode and it takes longer. Which do you prefer for the local network?

@loziniak
Copy link
Contributor Author

Perhaps I didn't make myself clear. By default, node_manager is built in dev mode, and the binaries it builds itself, like safenode or faucet, are built with release mode. It makes all dependencies be built two times - once for release and once for dev. I see two solutions:

  1. Add --release option to cargo commands in README
  2. Make node_manager build other binaries in dev mode.

I prefer solution no.1, because release saves much more space, and takes only a little longer.

@jacderida
Copy link
Contributor

OK, thanks. I'll look into this.

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