neo-project / neo-express

Neo Private Net optimized for development scenarios
MIT License
35 stars 37 forks source link

Contract deploy failing when Neo Express is not running and the --force flag is used #451

Open lock9 opened 2 months ago

lock9 commented 2 months ago

Describe the bug If I try to redeploy a contract that already exists using the --force flag when Neo Express is not running, the application will throw an error. This only happens if Neo Express is not running.

To Reproduce Steps to reproduce the behavior:

  1. Use neoxp contract deploy nef -a account command with neoxp offline. It should work the first time.
  2. Repeat the command. It will fail with the following error: Inner InvalidOperationException: Contract Already Exists: 0xabfb9e99997b27283e4bd872986907c4c999740b
  3. Use neoxp run to start Neo Express
  4. Repeat the command. It will 'work', and an error message will appear Neo Express logs (however, the RPC node won't return an error)

Expected behavior Using the force flag to deploy a contract when the node is not running.

please complete the following information

Additional context This problem appears to exist before version 3.7.3

cschuchardt88 commented 1 month ago

you can use neoxp reset for work around

cschuchardt88 commented 2 weeks ago

Note: Need better error output for ExpressRPCServer