-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
gov/v1beta1/proposal doesn't handle correctly new SoftwareUpgradeProposal #14334
Comments
In fact the same problem is with all "new" proposals. For example, we created a "new" proposal for one of our custom modules, and it also breaks the explorer, because the |
@AmauryM can lend some help, but v1 is a breaking change and was expected to cause some breaking changes. We can look into what can be done, but also a nil check on explorers can be done. |
Changes for gov v1 always needed to be implemented by explorers. For instance, they need to implement metadata changes: #11301 |
Keplr Dashboard already supports the |
Great news @dogemos . Is there a roadmap for |
BTW, @dogemos , I don't think handling |
Hey Robert, Noted. I think I misunderstood the issue as being an endpoint formatting issue. Seems like this is more around the breaking changes on gov/v1. This will take a little bit more time, but I've notified the team and we will work on getting gov/v1 supported. |
I think the biggest issue is that the gov/v1 stuff no longer has a static title and description. It relies on the goodwill of the proposer to format and upload the Metadata matching the "recommended" format. Just something to keep in mind, as I've had to deal with the switch as well. |
I am preparing a fix for |
Good observation @minxylynx , it's a big issue. The Title / Description is ensured on the interface level, which obviously won't work on the proto level. |
I spent about 2 weeks updating the Provenance Explorer to handle the new changes. That was a big point of frustration. If the metadata doesnt exist, there is no title or description. So I had to handle that case with defaults, which are not a nice as a true title. I understand why it was moved into a freeform field, but that leaves it open to being ignored. On the same note, I do parse out the legacy content, if present, to pull the old title and description fields. That at least works for some of the time. |
yeah, I spent this week debuging various things, previously we spent few weeks doing migrations and creating new v1 proposals, so I understand your pain. I would like to avoid rolling back that work. |
@robert-zaremba I think we have patched the null content issue, You need put a sdk version >0.46.6 in the chain.json. let me know if it still not work. Regarding the metadata, We haven't figured out what is a practical way to implement, Because there are some common issues (availability, cors) on parsing contents the external link. The only thing I would suggest is putting title out of the metadata, using a separated field and storing it on chain. that keep minimum necessary info about the proposal. also help display on front-end, especially for iteration. |
@liangping how does 0.46.7 change anything here (compared to 46.0)? |
@liangping if you don't support |
we only handle null content when version> 0.46.6, Because osmosis(current 0.46.1) adapted the gov to previous version, while others did not. so we added a version compare. |
Welcome to push a request. |
fyi, the reason it title/description was removed was because groups was added and that needed to be off-chain so it didn't blow up state. gov was changed so gov/groups would conform. We did our best to document this and I went around to major wallets/explorers to notify them of the change months ago. |
@hxrts |
Is there any explorer which already handle gov metadata? |
Haven't. |
Mintscan is looking into it and will prepare against this issues. thanks for ping us. @hxrts
|
Summary of Bug
ping.pub and Kepler explorer crash when opening a governance page, when there is a new SoftwareUpgradeProposal (submitted as a new
tx gov submit-proposal
) as well as any new proposal gov message. The exception in the browser console is:TypeError: t.p.contents is null
. Example.Probably other explorers (mintscan...) will crash as well.
The reason is that
gov/v1beta1/proposals
endpoint doesn't setContent
for the new Proposal types.The problem is that today, explorers use
gov/v1beta1/proposals
and expectProposal.Content
.Ecosystem bugs:
Version
v0.46.7
I guess, v0.47-alpha2 has same issue.
Steps to Reproduce
Start
simd
Make proposal upgrade:
wait until upgrade, and start new binary with compiled upgrade plan, and API server enabled
Open ping pug gov page - it will break
You won't be able to see details of any new gov proposal, until explorer will start supporting
gov/v1
Open
127.0.0.1:1317/cosmos/gov/v1/proposals/1
, you will see correct response:open
127.0.0.1:1317/cosmos/gov/v1beta1/proposals/1
, you will see response with null contentThe text was updated successfully, but these errors were encountered: