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

🐛 Internal Server Error on Previewing Some Treasury Withdrawal Proposals #1911

Closed
kneerose opened this issue Sep 3, 2024 · 4 comments
Closed
Assignees
Labels
🐛 Bug Something isn't working Other area

Comments

@kneerose
Copy link
Contributor

kneerose commented Sep 3, 2024

Area

Other

Domain

dev-sanchogov.tools

Which wallet were you using?

No response

Context

Some treasury proposals are not viewable, and the same governance action ID appears multiple times. Navigating to the details page for these actions results in an error page.

Steps to reproduce

  1. Connect your wallet.
  2. Register as a dRep.
  3. Navigate to the governance actions.
  4. Paste d7c0940e3f1279f2648eb849b38f9410ed620c452342ff59d79eb3ce92b1d64d#0 into the search bar.
  5. Click on any listed governance action to view details.
  6. Observe the page.

https://www.loom.com/share/ee4e5fb86ad445d79321a3652af85aba?sid=188ca0a3-8388-4dbb-ae17-0d4f8e027461

Actual behavior

The details page for the treasury governance action with ID d7c0940e3f1279f2648eb849b38f9410ed620c452342ff59d79eb3ce92b1d64d#0 results in an internal server error. The JSON response contains multiple entries with the same ID:

  {
            "id": "247",
            "txHash": "d7c0940e3f1279f2648eb849b38f9410ed620c452342ff59d79eb3ce92b1d64d",
            "index": 0,
            "type": "TreasuryWithdrawals",
            "details": {
                "Amount": 50000000,
                "Reward Address": "stake_test1uq827mlrnza02v3fac4mngcfecjjfyngvf0vh3hy2zrae4sz0mj79"
            },
            "expiryDate": "2024-09-07T06:58:57.62332Z",
            "expiryEpochNo": 450,
            "createdDate": "2024-08-23T05:00:11Z",
            "createdEpochNo": 435,
            "url": "http://bit.ly/3QFMhii?index=0",
            "metadataHash": "1111111111111111111111111111111111111111111111111111111111111112",
            "protocolParams": null,
            "title": null,
            "abstract": null,
            "motivation": null,
            "rationale": null,
            "dRepYesVotes": 0,
            "dRepNoVotes": 702323928897,
            "dRepAbstainVotes": 4504163250230,
            "poolYesVotes": 0,
            "poolNoVotes": 0,
            "poolAbstainVotes": 0,
            "ccYesVotes": 0,
            "ccNoVotes": 0,
            "ccAbstainVotes": 0,
            "prevGovActionIndex": null,
            "prevGovActionTxHash": null
        },
        {
            "id": "247",
            "txHash": "d7c0940e3f1279f2648eb849b38f9410ed620c452342ff59d79eb3ce92b1d64d",
            "index": 0,
            "type": "TreasuryWithdrawals",
            "details": {
                "Amount": 40000000,
                "Reward Address": "stake_test1uz55q6nl8072h37l3ukq6ja7cxezhhpths65x8uvd9477fcmgle3c"
            },
            "expiryDate": "2024-09-07T06:58:57.62332Z",
            "expiryEpochNo": 450,
            "createdDate": "2024-08-23T05:00:11Z",
            "createdEpochNo": 435,
            "url": "http://bit.ly/3QFMhii?index=0",
            "metadataHash": "1111111111111111111111111111111111111111111111111111111111111112",
            "protocolParams": null,
            "title": null,
            "abstract": null,
            "motivation": null,
            "rationale": null,
            "dRepYesVotes": 0,
            "dRepNoVotes": 702323928897,
            "dRepAbstainVotes": 4504163250230,
            "poolYesVotes": 0,
            "poolNoVotes": 0,
            "poolAbstainVotes": 0,
            "ccYesVotes": 0,
            "ccNoVotes": 0,
            "ccAbstainVotes": 0,
            "prevGovActionIndex": null,
            "prevGovActionTxHash": null
        },
        {
            "id": "247",
            "txHash": "d7c0940e3f1279f2648eb849b38f9410ed620c452342ff59d79eb3ce92b1d64d",
            "index": 0,
            "type": "TreasuryWithdrawals",
            "details": {
                "Amount": 50000000,
                "Reward Address": "stake_test1uzjqvaxvpl3fu7w2795hm74qyvn397ygy7x27yw8zd3x58gnnuce6"
            },
            "expiryDate": "2024-09-07T06:58:57.62332Z",
            "expiryEpochNo": 450,
            "createdDate": "2024-08-23T05:00:11Z",
            "createdEpochNo": 435,
            "url": "http://bit.ly/3QFMhii?index=0",
            "metadataHash": "1111111111111111111111111111111111111111111111111111111111111112",
            "protocolParams": null,
            "title": null,
            "abstract": null,
            "motivation": null,
            "rationale": null,
            "dRepYesVotes": 0,
            "dRepNoVotes": 702323928897,
            "dRepAbstainVotes": 4504163250230,
            "poolYesVotes": 0,
            "poolNoVotes": 0,
            "poolAbstainVotes": 0,
            "ccYesVotes": 0,
            "ccNoVotes": 0,
            "ccAbstainVotes": 0,
            "prevGovActionIndex": null,
            "prevGovActionTxHash": null
        }

Navigating to the details page leads to the following error page:

image

Expected behavior

The governance action details page should correctly display all listed governance actions without errors.

@kneerose kneerose added the 🐛 Bug Something isn't working label Sep 3, 2024
@bosko-m
Copy link
Contributor

bosko-m commented Sep 3, 2024

This shouldnt be considered P0 for bootstrapping phase.

@jdyczka
Copy link
Contributor

jdyczka commented Sep 3, 2024

Actually, we cannot display those details, because we cannot get the data from the server. The response we get is
Multiple proposal found for id: d7c0940e3f1279f2648eb849b38f9410ed620c452342ff59d79eb3ce92b1d64d#0. This should never happen.

So I'd say the solution would be to delete duplicate GAs. The question is how were they added and is it possible to add multiple GA with the same id through GovTool

@Ryun1
Copy link
Member

Ryun1 commented Sep 10, 2024

TxHash#TxIndex SHOULD be unique and should be caught at insert time into DBSync

@bosko-m
Copy link
Contributor

bosko-m commented Nov 3, 2024

So this is a DBSync issue.

@bosko-m bosko-m closed this as completed Nov 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 Bug Something isn't working Other area
Projects
Status: Done
Development

No branches or pull requests

5 participants