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

required query flags not enforced #5592

Closed
4 tasks
okwme opened this issue Jan 30, 2020 · 3 comments
Closed
4 tasks

required query flags not enforced #5592

okwme opened this issue Jan 30, 2020 · 3 comments

Comments

@okwme
Copy link
Contributor

okwme commented Jan 30, 2020

Summary of Bug

(originally posted here: cosmos/gaia#274)

Query commands should require chain-id as a flag or as a preset inside of config. Instead of throwing an error with chain-id is not found there is an attempt to make the query without it which results in a tendermint panic error:

panic: runtime error: invalid memory address or nil pointer dereference

Version

f3b82c5, v0.38.0

Steps to Reproduce

This occurs under two scenarios:

  1. Scenario 1
  • There is no config file
  • The query is made without the --chain-id flag
  • The result is the tendermint error
  1. Scenario 2
  • There is no config file
  • The query is made with an incorrect --chain-id flag
  • The result is the tendermint error (This may be expected behavior idk if it's possible to confirm a the chain-id before trying to use it)

There is another scenario that seems abnormal:

  • There is a config file with trust-node set to true
  • The query is made without the --chain-id flag
  • The result is correct (Does that imply that chain-id is in fact not necessary?? or expected behaviour when trusting a node?)

For Admin Use

  • Not duplicate issue
  • Appropriate labels applied
  • Appropriate contributors tagged
  • Contributor assigned/self-assigned
@kwunyeung
Copy link
Contributor

kwunyeung commented Feb 24, 2020

This also happens in v0.37.7 which is running with gaia v2.0.6. And it doesn't work even if the --chain-id is correct.

@RiccardoM
Copy link
Contributor

I'm not sure whether this is related to this issue, but using the query tx <hash> command without the --trust-node flag returns the following error:

ERROR: header has vhash E02EA28D2A3E784E408254006301978132591B24231B3887985E77848AB188BB but valset hash is C8AFA4C799D1C02F8558E9C5E1DEC29F1E0B6CF94CC9B0CA35EEC997345E30BA

I've also opened an issue inside Tendermint's repo but I wanted to point this out here too.

@github-actions
Copy link
Contributor

github-actions bot commented Jul 5, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

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

Successfully merging a pull request may close this issue.

3 participants