feat(qa): redeploy decision guide and faster QA bring-up (#325) #802

Merged
PlasticDigits merged 3 commits from cursor/gitlab-issue-workflow-2dff into main 2026-06-05 12:39:24 +00:00
PlasticDigits commented 2026-06-05 12:31:56 +00:00 (Migrated from gitlab.com)

Implements #325


Note

Medium Risk
Changes QA deploy orchestration and idempotent skip logic; a mistaken skip could leave stale on-chain state until qa-verify-deploy fails, and lighter QA_DEPLOY_SEED profiles change what QA data exists on chain.

Overview
Adds GitLab #325 QA bring-up optimizations: faster restarts, optional CI artifacts, and a redeploy decision guide for agents/operators.

make start-qa now skips deploy-local when deploy_up_to_date passes (stamp git_sha == HEAD, factory env alignment, fresh wasm vs sources/stamp, factory LCD probe). Otherwise it chooses deploy-local-no-build vs full deploy-local. Optional QA_FETCH_CI_ARTIFACTS=1 pulls wasm/indexer from GitLab generic packages; INDEXER_QA_BIN avoids recompiling the indexer. Phase [timing] logs were added to start-qa and deploy-dex-local.

deploy-dex-local.sh gains QA_DEPLOY_SEED profiles (minimal, charts, wallet, full) that skip or trim treasury/wrap, unpaired tokens, liquidity cycles, and swap seeding. Fixed sleep 3 waits are replaced with terrad-wait-tx.sh polling. Wasm staleness checks move to shared wasm-artifacts-stale.sh.

New .gitlab-ci.yml jobs build optimized wasm and release indexer on default-branch path changes and publish via publish-qa-ci-artifacts.sh. skills/AGENTS_QA_REDEPLOY_DECISION.md, Makefile targets (deploy-local-no-build, fetch-qa-ci-artifacts, test-qa-redeploy-decision), and QA docs/README updates document when to reset-qa vs redeploy vs skip. Cloud Agent setup reuses deploy_up_to_date from deploy-up-to-date.sh.

Reviewed by Cursor Bugbot for commit cac5a457c1. Bugbot is set up for automated code reviews on this repo. Configure here.

Implements #325 <!-- CURSOR_SUMMARY --> --- > [!NOTE] > **Medium Risk** > Changes QA deploy orchestration and idempotent skip logic; a mistaken skip could leave stale on-chain state until **`qa-verify-deploy`** fails, and lighter **`QA_DEPLOY_SEED`** profiles change what QA data exists on chain. > > **Overview** > Adds **GitLab #325** QA bring-up optimizations: faster restarts, optional CI artifacts, and a redeploy decision guide for agents/operators. > > **`make start-qa`** now skips **`deploy-local`** when **`deploy_up_to_date`** passes (stamp **`git_sha`** == **`HEAD`**, factory env alignment, fresh wasm vs sources/stamp, factory LCD probe). Otherwise it chooses **`deploy-local-no-build`** vs full **`deploy-local`**. Optional **`QA_FETCH_CI_ARTIFACTS=1`** pulls wasm/indexer from GitLab generic packages; **`INDEXER_QA_BIN`** avoids recompiling the indexer. Phase **`[timing]`** logs were added to **`start-qa`** and **`deploy-dex-local`**. > > **`deploy-dex-local.sh`** gains **`QA_DEPLOY_SEED`** profiles (`minimal`, `charts`, `wallet`, `full`) that skip or trim treasury/wrap, unpaired tokens, liquidity cycles, and swap seeding. Fixed **`sleep 3`** waits are replaced with **`terrad-wait-tx.sh`** polling. Wasm staleness checks move to shared **`wasm-artifacts-stale.sh`**. > > New **`.gitlab-ci.yml`** jobs build optimized wasm and release indexer on default-branch path changes and publish via **`publish-qa-ci-artifacts.sh`**. **`skills/AGENTS_QA_REDEPLOY_DECISION.md`**, Makefile targets (`deploy-local-no-build`, `fetch-qa-ci-artifacts`, `test-qa-redeploy-decision`), and QA docs/README updates document when to **`reset-qa`** vs redeploy vs skip. Cloud Agent setup reuses **`deploy_up_to_date`** from **`deploy-up-to-date.sh`**. > > <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit cac5a457c116ceaf7d2de95e52927b68b9a5d1e0. Bugbot is set up for automated code reviews on this repo. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup> <!-- /CURSOR_SUMMARY -->
PlasticDigits commented 2026-06-05 12:32:07 +00:00 (Migrated from gitlab.com)

changed the description

changed the description
PlasticDigits commented 2026-06-05 12:32:07 +00:00 (Migrated from gitlab.com)

mentioned in issue #325

mentioned in issue #325
ghost1 commented 2026-06-05 12:32:08 +00:00 (Migrated from gitlab.com)

changed the description

changed the description
ghost1 commented 2026-06-05 12:32:16 +00:00 (Migrated from gitlab.com)

changed the description

changed the description
ghost1 commented 2026-06-05 12:33:23 +00:00 (Migrated from gitlab.com)
Stale Security Review comment
Stale Security Review comment

Cursor Bugbot has reviewed your changes and found 3 potential issues.
Bugbot Autofix is ON. A cloud agent has been kicked off to fix the reported issues.

Reviewed by Cursor Bugbot for commit 6763580ad2. Configure here.

<details> <summary>Stale Security Review comment</summary> <details> <summary>Stale Security Review comment</summary> <!-- BUGBOT_REVIEW --> Cursor Bugbot has reviewed your changes and found 3 potential issues.<!-- BUGBOT_AUTOFIX_REVIEW_FOOTNOTE_BEGIN --> <sup>Bugbot Autofix is [ON](https://www.cursor.com/dashboard/bugbot). A cloud agent has been kicked off to fix the reported issues. <!-- BUGBOT_AUTOFIX_AGENT_LINK --></sup> <!-- BUGBOT_AUTOFIX_REVIEW_FOOTNOTE_END --> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 6763580ad2c83c6ee0d9f3d34346708d775f2781. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup> </details> </details>
ghost1 commented 2026-06-05 12:33:24 +00:00 (Migrated from gitlab.com)

Query waiter ignores failed transactions

Medium Severity

terrad_wait_tx_query only returns when the tx reports success code 0. If terrad query tx returns a failed execution (non-zero code), it keeps polling until timeout instead of failing fast like terrad_wait_tx_inclusion and the Python swarm.py helper this file references.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 6763580ad2. Configure here.

### Query waiter ignores failed transactions **Medium Severity** <!-- DESCRIPTION START --> `terrad_wait_tx_query` only returns when the tx reports success code 0. If `terrad query tx` returns a failed execution (non-zero code), it keeps polling until timeout instead of failing fast like `terrad_wait_tx_inclusion` and the Python `swarm.py` helper this file references. <!-- DESCRIPTION END --> <!-- BUGBOT_BUG_ID: d25a87e7-1a6f-4ee5-be69-496c44711e33 --> <!-- LOCATIONS START scripts/lib/terrad-wait-tx.sh#L40-L61 LOCATIONS END --> <div><a href="https://cursor.com/open?link=eyJ2ZXJzaW9uIjoxLCJ0eXBlIjoiQlVHQk9UX0ZJWF9JTl9DVVJTT1IiLCJkYXRhIjp7InJlZGlzS2V5IjoiYnVnYm90OjU4MDQyOWE1LTBmMWQtNDAwYi04NTBkLTE3M2QyNTdmYTM5MSIsImVuY3J5cHRpb25LZXkiOiJKME1UT1lkbjN4QWN6MVliZ1o3NUwxdTFQeElHYlh5MU9xLUp6SmE2ODFBIiwiYnJhbmNoIjoiY3Vyc29yL2dpdGxhYi1pc3N1ZS13b3JrZmxvdy0yZGZmIiwicmVwb093bmVyIjoiUGxhc3RpY0RpZ2l0cyIsInJlcG9OYW1lIjoiY2w4eS1kZXgtdGVycmFjbGFzc2ljIn19" target="_blank" rel="noopener noreferrer"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/fix-in-cursor-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/fix-in-cursor-light.png"><img alt="Fix in Cursor" width="115" height="28" src="https://cursor.com/assets/images/fix-in-cursor-dark.png"></picture></a>&nbsp;<a href="https://cursor.com/agents?link=eyJ2ZXJzaW9uIjoxLCJ0eXBlIjoiQlVHQk9UX0ZJWF9JTl9XRUIiLCJkYXRhIjp7InJlZGlzS2V5IjoiYnVnYm90OjU4MDQyOWE1LTBmMWQtNDAwYi04NTBkLTE3M2QyNTdmYTM5MSIsImVuY3J5cHRpb25LZXkiOiJKME1UT1lkbjN4QWN6MVliZ1o3NUwxdTFQeElHYlh5MU9xLUp6SmE2ODFBIiwiYnJhbmNoIjoiY3Vyc29yL2dpdGxhYi1pc3N1ZS13b3JrZmxvdy0yZGZmIiwicmVwb093bmVyIjoiUGxhc3RpY0RpZ2l0cyIsInJlcG9OYW1lIjoiY2w4eS1kZXgtdGVycmFjbGFzc2ljIiwicHJOdW1iZXIiOjg0LCJjb21taXRTaGEiOiI2NzYzNTgwYWQyYzgzYzZlZTBkOWYzZDM0MzQ2NzA4ZDc3NWYyNzgxIiwicHJvdmlkZXIiOiJnaXRsYWIiLCJob3N0bmFtZSI6ImdpdGxhYi5jb20ifX0" target="_blank" rel="noopener noreferrer"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/fix-in-web-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/fix-in-web-light.png"><img alt="Fix in Web" width="99" height="28" src="https://cursor.com/assets/images/fix-in-web-dark.png"></picture></a></div> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 6763580ad2c83c6ee0d9f3d34346708d775f2781. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup>
ghost1 commented 2026-06-05 12:33:24 +00:00 (Migrated from gitlab.com)

Deploy skip bypasses wasm staleness

Medium Severity

When deploy_up_to_date succeeds, start-qa skips deploy-local entirely, so deploy-dex-local.sh’s source-vs-wasm staleness check never runs. With an unchanged HEAD and stamp, rebuilt wasm after local contract edits can leave the chain on an older deployment while verification still passes schema probes.

Additional Locations (1)
Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 6763580ad2. Configure here.

### Deploy skip bypasses wasm staleness **Medium Severity** <!-- DESCRIPTION START --> When `deploy_up_to_date` succeeds, `start-qa` skips `deploy-local` entirely, so `deploy-dex-local.sh`’s source-vs-wasm staleness check never runs. With an unchanged `HEAD` and stamp, rebuilt wasm after local contract edits can leave the chain on an older deployment while verification still passes schema probes. <!-- DESCRIPTION END --> <!-- BUGBOT_BUG_ID: 4c042088-a751-4c76-a8f1-9f96d745450e --> <!-- LOCATIONS START scripts/qa/start-qa.sh#L96-L99 scripts/lib/deploy-up-to-date.sh#L6-L28 LOCATIONS END --> <details> <summary>Additional Locations (1)</summary> - [`scripts/lib/deploy-up-to-date.sh#L6-L28`](https://gitlab.com/PlasticDigits/cl8y-dex-terraclassic/-//blob/6763580ad2c83c6ee0d9f3d34346708d775f2781/scripts/lib/deploy-up-to-date.sh#L6-L28) </details> <div><a href="https://cursor.com/open?link=eyJ2ZXJzaW9uIjoxLCJ0eXBlIjoiQlVHQk9UX0ZJWF9JTl9DVVJTT1IiLCJkYXRhIjp7InJlZGlzS2V5IjoiYnVnYm90OjFjODU5YmViLTJhZDAtNDA4Zi05ZTQ1LWQzZDM1YjRhNGE3ZiIsImVuY3J5cHRpb25LZXkiOiJVbjlBT01LR0FkS01ZeEZIQmk0Z29aMG55SFdZQVFUTHo0Ymd2N2Z6eWVjIiwiYnJhbmNoIjoiY3Vyc29yL2dpdGxhYi1pc3N1ZS13b3JrZmxvdy0yZGZmIiwicmVwb093bmVyIjoiUGxhc3RpY0RpZ2l0cyIsInJlcG9OYW1lIjoiY2w4eS1kZXgtdGVycmFjbGFzc2ljIn19" target="_blank" rel="noopener noreferrer"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/fix-in-cursor-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/fix-in-cursor-light.png"><img alt="Fix in Cursor" width="115" height="28" src="https://cursor.com/assets/images/fix-in-cursor-dark.png"></picture></a>&nbsp;<a href="https://cursor.com/agents?link=eyJ2ZXJzaW9uIjoxLCJ0eXBlIjoiQlVHQk9UX0ZJWF9JTl9XRUIiLCJkYXRhIjp7InJlZGlzS2V5IjoiYnVnYm90OjFjODU5YmViLTJhZDAtNDA4Zi05ZTQ1LWQzZDM1YjRhNGE3ZiIsImVuY3J5cHRpb25LZXkiOiJVbjlBT01LR0FkS01ZeEZIQmk0Z29aMG55SFdZQVFUTHo0Ymd2N2Z6eWVjIiwiYnJhbmNoIjoiY3Vyc29yL2dpdGxhYi1pc3N1ZS13b3JrZmxvdy0yZGZmIiwicmVwb093bmVyIjoiUGxhc3RpY0RpZ2l0cyIsInJlcG9OYW1lIjoiY2w4eS1kZXgtdGVycmFjbGFzc2ljIiwicHJOdW1iZXIiOjg0LCJjb21taXRTaGEiOiI2NzYzNTgwYWQyYzgzYzZlZTBkOWYzZDM0MzQ2NzA4ZDc3NWYyNzgxIiwicHJvdmlkZXIiOiJnaXRsYWIiLCJob3N0bmFtZSI6ImdpdGxhYi5jb20ifX0" target="_blank" rel="noopener noreferrer"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/fix-in-web-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/fix-in-web-light.png"><img alt="Fix in Web" width="99" height="28" src="https://cursor.com/assets/images/fix-in-web-dark.png"></picture></a></div> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 6763580ad2c83c6ee0d9f3d34346708d775f2781. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup>
ghost1 commented 2026-06-05 12:33:24 +00:00 (Migrated from gitlab.com)

Wallet seed keeps extra tokens

Medium Severity

The wallet QA_DEPLOY_SEED branch trims main tokens and PAIR_CONFIGS but leaves the default NOWHITELIST_* and UNPAIRED_* arrays intact, unlike minimal and charts. Phases 2b/2c still run, so a “wallet” deploy creates five extra tokens and extra work while the banner still advertises a lighter profile.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 6763580ad2. Configure here.

### Wallet seed keeps extra tokens **Medium Severity** <!-- DESCRIPTION START --> The `wallet` `QA_DEPLOY_SEED` branch trims main tokens and `PAIR_CONFIGS` but leaves the default `NOWHITELIST_*` and `UNPAIRED_*` arrays intact, unlike `minimal` and `charts`. Phases 2b/2c still run, so a “wallet” deploy creates five extra tokens and extra work while the banner still advertises a lighter profile. <!-- DESCRIPTION END --> <!-- BUGBOT_BUG_ID: de939b4c-f6f9-4af7-b635-3f559f1ff31d --> <!-- LOCATIONS START scripts/deploy-dex-local.sh#L123-L128 LOCATIONS END --> <div><a href="https://cursor.com/open?link=eyJ2ZXJzaW9uIjoxLCJ0eXBlIjoiQlVHQk9UX0ZJWF9JTl9DVVJTT1IiLCJkYXRhIjp7InJlZGlzS2V5IjoiYnVnYm90OjlmYmZiMzlmLWU2MDgtNDdjOC1iNjQ4LTBjYmE2ODVhZjAyNyIsImVuY3J5cHRpb25LZXkiOiJjNkFFeWFqMzVaSjlHZmg3QS1wWWg2RWVSMEgtRndidDFRcENTQld4WktjIiwiYnJhbmNoIjoiY3Vyc29yL2dpdGxhYi1pc3N1ZS13b3JrZmxvdy0yZGZmIiwicmVwb093bmVyIjoiUGxhc3RpY0RpZ2l0cyIsInJlcG9OYW1lIjoiY2w4eS1kZXgtdGVycmFjbGFzc2ljIn19" target="_blank" rel="noopener noreferrer"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/fix-in-cursor-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/fix-in-cursor-light.png"><img alt="Fix in Cursor" width="115" height="28" src="https://cursor.com/assets/images/fix-in-cursor-dark.png"></picture></a>&nbsp;<a href="https://cursor.com/agents?link=eyJ2ZXJzaW9uIjoxLCJ0eXBlIjoiQlVHQk9UX0ZJWF9JTl9XRUIiLCJkYXRhIjp7InJlZGlzS2V5IjoiYnVnYm90OjlmYmZiMzlmLWU2MDgtNDdjOC1iNjQ4LTBjYmE2ODVhZjAyNyIsImVuY3J5cHRpb25LZXkiOiJjNkFFeWFqMzVaSjlHZmg3QS1wWWg2RWVSMEgtRndidDFRcENTQld4WktjIiwiYnJhbmNoIjoiY3Vyc29yL2dpdGxhYi1pc3N1ZS13b3JrZmxvdy0yZGZmIiwicmVwb093bmVyIjoiUGxhc3RpY0RpZ2l0cyIsInJlcG9OYW1lIjoiY2w4eS1kZXgtdGVycmFjbGFzc2ljIiwicHJOdW1iZXIiOjg0LCJjb21taXRTaGEiOiI2NzYzNTgwYWQyYzgzYzZlZTBkOWYzZDM0MzQ2NzA4ZDc3NWYyNzgxIiwicHJvdmlkZXIiOiJnaXRsYWIiLCJob3N0bmFtZSI6ImdpdGxhYi5jb20ifX0" target="_blank" rel="noopener noreferrer"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/fix-in-web-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/fix-in-web-light.png"><img alt="Fix in Web" width="99" height="28" src="https://cursor.com/assets/images/fix-in-web-dark.png"></picture></a></div> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 6763580ad2c83c6ee0d9f3d34346708d775f2781. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup>
PlasticDigits commented 2026-06-05 12:33:51 +00:00 (Migrated from gitlab.com)

Security review

Commit reviewed: 6763580ad2c83c6ee0d9f3d34346708d775f2781
Scope: QA bring-up only — scripts/lib/deploy-up-to-date.sh, terrad-wait-tx.sh, qa-phase-timing.sh, scripts/qa/fetch-qa-ci-artifacts.sh, publish-qa-ci-artifacts.sh, start-qa.sh, deploy-dex-local.sh seed profiles / tx polling, .gitlab-ci.yml generic-package publish jobs, Makefile/docs/skills (17 files).

Method: Diff reviewed on GitLab MR !802; traced env-controlled inputs (GIT_SHA, GITLAB_REPO, CI_API_V4_URL, QA_FETCH_CI_ARTIFACTS, INDEXER_QA_BIN, QA_DEPLOY_SEED) to sinks (curl, tar extract, docker exec, indexer exec). Checked deploy-skip path still runs qa-verify-deploy schema probes. No prior security-review threads on this MR.

Outcome: FINDINGS: 0 medium+

Security review: no medium+ findings on this diff.

Notes (below threshold / accepted trust boundaries):

  • CI generic-package fetch/publish assumes the same trust model as existing make build-optimized / CI — authenticated GitLab API, project-scoped tokens; not an internet-facing attack surface.
  • tar xzf on fetched wasm tarball is supply-chain-sensitive in theory (tar slip); mitigated in practice by private packages + maintainer/CI-only publish rules on main; no untrusted user input path.
  • deploy_up_to_date skip is followed by qa-verify-deploy (schema + stamp checks); LCD factory probe limits stale-volume false negatives documented in Q1.
  • QA_DEPLOY_SEED only trims local QA seed data; production deploy paths unchanged.

Inline threads: none

## Security review **Commit reviewed:** `6763580ad2c83c6ee0d9f3d34346708d775f2781` **Scope:** QA bring-up only — `scripts/lib/deploy-up-to-date.sh`, `terrad-wait-tx.sh`, `qa-phase-timing.sh`, `scripts/qa/fetch-qa-ci-artifacts.sh`, `publish-qa-ci-artifacts.sh`, `start-qa.sh`, `deploy-dex-local.sh` seed profiles / tx polling, `.gitlab-ci.yml` generic-package publish jobs, Makefile/docs/skills (17 files). **Method:** Diff reviewed on GitLab MR !802; traced env-controlled inputs (`GIT_SHA`, `GITLAB_REPO`, `CI_API_V4_URL`, `QA_FETCH_CI_ARTIFACTS`, `INDEXER_QA_BIN`, `QA_DEPLOY_SEED`) to sinks (curl, tar extract, `docker exec`, indexer exec). Checked deploy-skip path still runs `qa-verify-deploy` schema probes. No prior security-review threads on this MR. **Outcome:** `FINDINGS: 0` medium+ Security review: **no medium+ findings** on this diff. **Notes (below threshold / accepted trust boundaries):** - CI generic-package fetch/publish assumes the same trust model as existing `make build-optimized` / CI — authenticated GitLab API, project-scoped tokens; not an internet-facing attack surface. - `tar xzf` on fetched wasm tarball is supply-chain-sensitive in theory (tar slip); mitigated in practice by private packages + maintainer/CI-only publish rules on `main`; no untrusted user input path. - `deploy_up_to_date` skip is followed by `qa-verify-deploy` (schema + stamp checks); LCD factory probe limits stale-volume false negatives documented in Q1. - `QA_DEPLOY_SEED` only trims local QA seed data; production deploy paths unchanged. **Inline threads:** none
ghost1 commented 2026-06-05 12:34:56 +00:00 (Migrated from gitlab.com)

added 1 commit

  • 347ca7b9 - Fix wallet seed extras, tx query fail-fast, and deploy skip wasm freshness

Compare with previous version

added 1 commit <ul><li>347ca7b9 - Fix wallet seed extras, tx query fail-fast, and deploy skip wasm freshness</li></ul> [Compare with previous version](/PlasticDigits/cl8y-dex-terraclassic/-/merge_requests/84/diffs?diff_id=1836682212&start_sha=6763580ad2c83c6ee0d9f3d34346708d775f2781)
ghost1 commented 2026-06-05 12:35:11 +00:00 (Migrated from gitlab.com)

changed the description

changed the description
ghost1 commented 2026-06-05 12:35:37 +00:00 (Migrated from gitlab.com)

resolved all threads

resolved all threads
ghost1 commented 2026-06-05 12:35:37 +00:00 (Migrated from gitlab.com)

resolved all threads

resolved all threads
ghost1 commented 2026-06-05 12:36:28 +00:00 (Migrated from gitlab.com)
Stale Security Review comment

Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is ON. A cloud agent has been kicked off to fix the reported issue.

Reviewed by Cursor Bugbot for commit 347ca7b9ae. Configure here.

<details> <summary>Stale Security Review comment</summary> <!-- BUGBOT_REVIEW --> Cursor Bugbot has reviewed your changes and found 1 potential issue.<!-- BUGBOT_AUTOFIX_REVIEW_FOOTNOTE_BEGIN --> <sup>Bugbot Autofix is [ON](https://www.cursor.com/dashboard/bugbot). A cloud agent has been kicked off to fix the reported issue. <!-- BUGBOT_AUTOFIX_AGENT_LINK --></sup> <!-- BUGBOT_AUTOFIX_REVIEW_FOOTNOTE_END --> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 347ca7b9ae2c42b7cc9e224cb63fca1ed2167a90. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup> </details>
ghost1 commented 2026-06-05 12:36:29 +00:00 (Migrated from gitlab.com)

Stale wasm picks no-build path

Medium Severity

After deploy_up_to_date rejects a stale deploy, start-qa still chooses make deploy-local-no-build whenever any cl8y_dex_*.wasm files exist. That path always hits dex_wasm_stale_vs_sources in deploy-dex-local.sh and exits without building, so a common contract-source change leaves QA bring-up stuck until someone runs make build-optimized manually instead of make deploy-local.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 347ca7b9ae. Configure here.

### Stale wasm picks no-build path **Medium Severity** <!-- DESCRIPTION START --> After `deploy_up_to_date` rejects a stale deploy, `start-qa` still chooses `make deploy-local-no-build` whenever any `cl8y_dex_*.wasm` files exist. That path always hits `dex_wasm_stale_vs_sources` in `deploy-dex-local.sh` and exits without building, so a common contract-source change leaves QA bring-up stuck until someone runs `make build-optimized` manually instead of `make deploy-local`. <!-- DESCRIPTION END --> <!-- BUGBOT_BUG_ID: 8f205a59-6d43-47ef-8edb-dfc26cb501a5 --> <!-- LOCATIONS START scripts/qa/start-qa.sh#L99-L102 LOCATIONS END --> <div><a href="https://cursor.com/open?link=eyJ2ZXJzaW9uIjoxLCJ0eXBlIjoiQlVHQk9UX0ZJWF9JTl9DVVJTT1IiLCJkYXRhIjp7InJlZGlzS2V5IjoiYnVnYm90OjMyYTk3ZGE0LTg4ZmItNDFlNy05MjVkLTVhYzA4ZTg4OTk0NyIsImVuY3J5cHRpb25LZXkiOiJpVkJLbXB6N2ZsSGNzZUtBblRTYUF6TVFEMUtDaVdyVm9EZVZONWZZY0lrIiwiYnJhbmNoIjoiY3Vyc29yL2dpdGxhYi1pc3N1ZS13b3JrZmxvdy0yZGZmIiwicmVwb093bmVyIjoiUGxhc3RpY0RpZ2l0cyIsInJlcG9OYW1lIjoiY2w4eS1kZXgtdGVycmFjbGFzc2ljIn19" target="_blank" rel="noopener noreferrer"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/fix-in-cursor-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/fix-in-cursor-light.png"><img alt="Fix in Cursor" width="115" height="28" src="https://cursor.com/assets/images/fix-in-cursor-dark.png"></picture></a>&nbsp;<a href="https://cursor.com/agents?link=eyJ2ZXJzaW9uIjoxLCJ0eXBlIjoiQlVHQk9UX0ZJWF9JTl9XRUIiLCJkYXRhIjp7InJlZGlzS2V5IjoiYnVnYm90OjMyYTk3ZGE0LTg4ZmItNDFlNy05MjVkLTVhYzA4ZTg4OTk0NyIsImVuY3J5cHRpb25LZXkiOiJpVkJLbXB6N2ZsSGNzZUtBblRTYUF6TVFEMUtDaVdyVm9EZVZONWZZY0lrIiwiYnJhbmNoIjoiY3Vyc29yL2dpdGxhYi1pc3N1ZS13b3JrZmxvdy0yZGZmIiwicmVwb093bmVyIjoiUGxhc3RpY0RpZ2l0cyIsInJlcG9OYW1lIjoiY2w4eS1kZXgtdGVycmFjbGFzc2ljIiwicHJOdW1iZXIiOjg0LCJjb21taXRTaGEiOiIzNDdjYTdiOWFlMmM0MmI3Y2M5ZTIyNGNiNjNmY2ExZWQyMTY3YTkwIiwicHJvdmlkZXIiOiJnaXRsYWIiLCJob3N0bmFtZSI6ImdpdGxhYi5jb20ifX0" target="_blank" rel="noopener noreferrer"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/fix-in-web-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/fix-in-web-light.png"><img alt="Fix in Web" width="99" height="28" src="https://cursor.com/assets/images/fix-in-web-dark.png"></picture></a></div> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 347ca7b9ae2c42b7cc9e224cb63fca1ed2167a90. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup>
PlasticDigits commented 2026-06-05 12:36:30 +00:00 (Migrated from gitlab.com)

Security review

Commit reviewed: 347ca7b9ae2c42b7cc9e224cb63fca1ed2167a90
Scope: QA bring-up only — delta since prior review (6763580): wasm-artifacts-stale.sh, deploy-up-to-date.sh wasm freshness gates, terrad-wait-tx.sh fail-fast on failed txs, deploy-dex-local.sh wallet seed profile fix. Full MR also covers fetch-qa-ci-artifacts.sh, publish-qa-ci-artifacts.sh, start-qa.sh, .gitlab-ci.yml generic-package jobs, Makefile/docs/skills (18 files).

Method: Diff reviewed on GitLab MR !802; traced env-controlled inputs (GIT_SHA, GITLAB_REPO, CI_API_V4_URL, QA_FETCH_CI_ARTIFACTS, INDEXER_QA_BIN, QA_DEPLOY_SEED) to sinks (curl, tar extract, docker exec, indexer exec). Verified deploy-skip path still runs qa-verify-deploy schema probes and now rejects stale/newer wasm vs sources and deploy stamp.

Outcome: FINDINGS: 0 medium+

Security review: no medium+ findings on this diff.

Notes (below threshold / accepted trust boundaries):

  • CI generic-package fetch/publish assumes the same trust model as existing make build-optimized / CI — authenticated GitLab API, project-scoped tokens; not an internet-facing attack surface.
  • tar xzf on fetched wasm tarball is supply-chain-sensitive in theory (tar slip); mitigated in practice by private packages + maintainer/CI-only publish rules on main; no untrusted user input path.
  • deploy_up_to_date skip is followed by qa-verify-deploy (schema + stamp checks); wasm freshness checks added in 347ca7b9 close the prior stale-artifact skip gap.
  • QA_DEPLOY_SEED is allowlisted (full|minimal|charts|wallet); only trims local QA seed data; production deploy paths unchanged.
  • terrad_wait_tx_query fail-fast on non-zero tx codes is a reliability improvement, not a new attack surface.

Inline threads: none

## Security review **Commit reviewed:** `347ca7b9ae2c42b7cc9e224cb63fca1ed2167a90` **Scope:** QA bring-up only — delta since prior review (`6763580`): `wasm-artifacts-stale.sh`, `deploy-up-to-date.sh` wasm freshness gates, `terrad-wait-tx.sh` fail-fast on failed txs, `deploy-dex-local.sh` wallet seed profile fix. Full MR also covers `fetch-qa-ci-artifacts.sh`, `publish-qa-ci-artifacts.sh`, `start-qa.sh`, `.gitlab-ci.yml` generic-package jobs, Makefile/docs/skills (18 files). **Method:** Diff reviewed on GitLab MR !802; traced env-controlled inputs (`GIT_SHA`, `GITLAB_REPO`, `CI_API_V4_URL`, `QA_FETCH_CI_ARTIFACTS`, `INDEXER_QA_BIN`, `QA_DEPLOY_SEED`) to sinks (curl, tar extract, `docker exec`, indexer exec). Verified deploy-skip path still runs `qa-verify-deploy` schema probes and now rejects stale/newer wasm vs sources and deploy stamp. **Outcome:** `FINDINGS: 0` medium+ Security review: **no medium+ findings** on this diff. **Notes (below threshold / accepted trust boundaries):** - CI generic-package fetch/publish assumes the same trust model as existing `make build-optimized` / CI — authenticated GitLab API, project-scoped tokens; not an internet-facing attack surface. - `tar xzf` on fetched wasm tarball is supply-chain-sensitive in theory (tar slip); mitigated in practice by private packages + maintainer/CI-only publish rules on `main`; no untrusted user input path. - `deploy_up_to_date` skip is followed by `qa-verify-deploy` (schema + stamp checks); wasm freshness checks added in `347ca7b9` close the prior stale-artifact skip gap. - `QA_DEPLOY_SEED` is allowlisted (`full|minimal|charts|wallet`); only trims local QA seed data; production deploy paths unchanged. - `terrad_wait_tx_query` fail-fast on non-zero tx codes is a reliability improvement, not a new attack surface. **Inline threads:** none
ghost1 commented 2026-06-05 12:37:26 +00:00 (Migrated from gitlab.com)

changed this line in version 3 of the diff

changed this line in [version 3 of the diff](/PlasticDigits/cl8y-dex-terraclassic/-/merge_requests/84/diffs?diff_id=1836686851&start_sha=347ca7b9ae2c42b7cc9e224cb63fca1ed2167a90#9d125ac4aa647a70eff9d21704c2124f800381eb_102_100)
ghost1 commented 2026-06-05 12:37:27 +00:00 (Migrated from gitlab.com)

added 1 commit

  • cac5a457 - fix(qa): use deploy-local when wasm artifacts are stale

Compare with previous version

added 1 commit <ul><li>cac5a457 - fix(qa): use deploy-local when wasm artifacts are stale</li></ul> [Compare with previous version](/PlasticDigits/cl8y-dex-terraclassic/-/merge_requests/84/diffs?diff_id=1836686851&start_sha=347ca7b9ae2c42b7cc9e224cb63fca1ed2167a90)
ghost1 commented 2026-06-05 12:37:41 +00:00 (Migrated from gitlab.com)

changed the description

changed the description
ghost1 commented 2026-06-05 12:37:52 +00:00 (Migrated from gitlab.com)

resolved all threads

resolved all threads
PlasticDigits commented 2026-06-05 12:39:04 +00:00 (Migrated from gitlab.com)

Security review

Commit reviewed: cac5a457c116ceaf7d2de95e52927b68b9a5d1e0
Scope: QA bring-up delta since prior review (347ca7b): start-qa.sh stale-wasm deploy path fix (deploy-local when artifacts are stale/missing). Full MR also covers deploy-up-to-date.sh, wasm-artifacts-stale.sh, terrad-wait-tx.sh, fetch-qa-ci-artifacts.sh, publish-qa-ci-artifacts.sh, deploy-dex-local.sh seed profiles, .gitlab-ci.yml generic-package publish jobs, Makefile/docs/skills (18 files).

Method: Diff reviewed on GitLab MR !802; traced env-controlled inputs (GIT_SHA, GITLAB_REPO, CI_API_V4_URL, QA_FETCH_CI_ARTIFACTS, INDEXER_QA_BIN, QA_DEPLOY_SEED) to sinks (curl, tar extract, docker exec, indexer exec). Verified deploy-skip path runs qa-verify-deploy schema probes and deploy_up_to_date rejects stale/newer wasm vs sources and deploy stamp. Re-checked prior security-review threads (6763580, 347ca7b) — no medium+ findings remain applicable.

Outcome: FINDINGS: 0 medium+

Security review: no medium+ findings on this diff.

Notes (below threshold / accepted trust boundaries):

  • CI generic-package fetch/publish assumes the same trust model as existing make build-optimized / CI — authenticated GitLab API, project-scoped tokens; not an internet-facing attack surface.
  • tar xzf on fetched wasm tarball is supply-chain-sensitive in theory (tar slip); mitigated in practice by private packages + maintainer/CI-only publish rules on main; no untrusted user input path.
  • deploy_up_to_date skip is followed by qa-verify-deploy (schema + stamp checks); cac5a45 ensures stale wasm triggers full deploy-local instead of a no-build path that could leave mismatched artifacts.
  • QA_DEPLOY_SEED is allowlisted (full|minimal|charts|wallet); only trims local QA seed data; production deploy paths unchanged.
  • terrad_wait_tx_* uses quoted docker exec args; tx hashes originate from local terrad broadcasts, not external input.

Inline threads: none

## Security review **Commit reviewed:** `cac5a457c116ceaf7d2de95e52927b68b9a5d1e0` **Scope:** QA bring-up delta since prior review (`347ca7b`): `start-qa.sh` stale-wasm deploy path fix (`deploy-local` when artifacts are stale/missing). Full MR also covers `deploy-up-to-date.sh`, `wasm-artifacts-stale.sh`, `terrad-wait-tx.sh`, `fetch-qa-ci-artifacts.sh`, `publish-qa-ci-artifacts.sh`, `deploy-dex-local.sh` seed profiles, `.gitlab-ci.yml` generic-package publish jobs, Makefile/docs/skills (18 files). **Method:** Diff reviewed on GitLab MR !802; traced env-controlled inputs (`GIT_SHA`, `GITLAB_REPO`, `CI_API_V4_URL`, `QA_FETCH_CI_ARTIFACTS`, `INDEXER_QA_BIN`, `QA_DEPLOY_SEED`) to sinks (curl, tar extract, `docker exec`, indexer exec). Verified deploy-skip path runs `qa-verify-deploy` schema probes and `deploy_up_to_date` rejects stale/newer wasm vs sources and deploy stamp. Re-checked prior security-review threads (`6763580`, `347ca7b`) — no medium+ findings remain applicable. **Outcome:** `FINDINGS: 0` medium+ Security review: **no medium+ findings** on this diff. **Notes (below threshold / accepted trust boundaries):** - CI generic-package fetch/publish assumes the same trust model as existing `make build-optimized` / CI — authenticated GitLab API, project-scoped tokens; not an internet-facing attack surface. - `tar xzf` on fetched wasm tarball is supply-chain-sensitive in theory (tar slip); mitigated in practice by private packages + maintainer/CI-only publish rules on `main`; no untrusted user input path. - `deploy_up_to_date` skip is followed by `qa-verify-deploy` (schema + stamp checks); `cac5a45` ensures stale wasm triggers full `deploy-local` instead of a no-build path that could leave mismatched artifacts. - `QA_DEPLOY_SEED` is allowlisted (`full|minimal|charts|wallet`); only trims local QA seed data; production deploy paths unchanged. - `terrad_wait_tx_*` uses quoted `docker exec` args; tx hashes originate from local `terrad` broadcasts, not external input. **Inline threads:** none
PlasticDigits (Migrated from gitlab.com) merged commit 775ad0e620 into main 2026-06-05 12:39:24 +00:00
PlasticDigits commented 2026-06-05 12:39:25 +00:00 (Migrated from gitlab.com)

mentioned in commit 775ad0e620

mentioned in commit 775ad0e62003034e6ad6570f5144629a133aa756
ghost1 commented 2026-06-05 12:39:37 +00:00 (Migrated from gitlab.com)

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

Bugbot Autofix is ON, but it could not run because the branch was deleted or merged before autofix could start.

Reviewed by Cursor Bugbot for commit cac5a457c1. Configure here.

<!-- BUGBOT_REVIEW --> Cursor Bugbot has reviewed your changes and found 1 potential issue. <!-- BUGBOT_FIX_ALL --> <a href="https://cursor.com/open?link=eyJ2ZXJzaW9uIjoxLCJ0eXBlIjoiQlVHQk9UX0ZJWF9BTExfSU5fQ1VSU09SIiwiZGF0YSI6eyJyZWRpc0tleSI6ImJ1Z2JvdC1tdWx0aTo3YWNmNzQ5Mi02NjBjLTQwOTMtYTRjZS04MzhmM2JkZmRhODUiLCJlbmNyeXB0aW9uS2V5IjoiTTNiNzlocDNHalhsc0RZbklqcklOdU1UZEJVNzhKcWRTTGh5Vm5kMmd3MCIsImJyYW5jaCI6ImN1cnNvci9naXRsYWItaXNzdWUtd29ya2Zsb3ctMmRmZiIsInJlcG9Pd25lciI6IlBsYXN0aWNEaWdpdHMiLCJyZXBvTmFtZSI6ImNsOHktZGV4LXRlcnJhY2xhc3NpYyJ9fQ" target="_blank" rel="noopener noreferrer"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/fix-in-cursor-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/fix-in-cursor-light.png"><img alt="Fix All in Cursor" width="115" height="28" src="https://cursor.com/assets/images/fix-in-cursor-dark.png"></picture></a> <!-- /BUGBOT_FIX_ALL --> <!-- BUGBOT_AUTOFIX_REVIEW_FOOTNOTE_BEGIN --> <sup>Bugbot Autofix is ON, but it could not run because the branch was deleted or merged before autofix could start.</sup> <!-- BUGBOT_AUTOFIX_REVIEW_FOOTNOTE_END --> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit cac5a457c116ceaf7d2de95e52927b68b9a5d1e0. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup>
ghost1 commented 2026-06-05 12:39:38 +00:00 (Migrated from gitlab.com)

Infrastructure timing phase never closed

Low Severity

qa_timing_phase_start "infrastructure" runs at the start of Phase 1, but no matching qa_timing_phase_end runs before the next qa_timing_phase_start (treasury-wrap or tokens-pairs). The infrastructure phase never logs a finish duration, and later phase timings can include work that belongs under infrastructure.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit cac5a457c1. Configure here.

### Infrastructure timing phase never closed **Low Severity** <!-- DESCRIPTION START --> `qa_timing_phase_start "infrastructure"` runs at the start of Phase 1, but no matching `qa_timing_phase_end` runs before the next `qa_timing_phase_start` (`treasury-wrap` or `tokens-pairs`). The infrastructure phase never logs a finish duration, and later phase timings can include work that belongs under infrastructure. <!-- DESCRIPTION END --> <!-- BUGBOT_BUG_ID: 93ca6b5e-7c4c-4d3b-9470-ec4ed526e1ac --> <!-- LOCATIONS START scripts/deploy-dex-local.sh#L169-L342 LOCATIONS END --> <div><a href="https://cursor.com/open?link=eyJ2ZXJzaW9uIjoxLCJ0eXBlIjoiQlVHQk9UX0ZJWF9JTl9DVVJTT1IiLCJkYXRhIjp7InJlZGlzS2V5IjoiYnVnYm90OmRjMWRlNmU0LWY3MjUtNDQ5OC05MDZlLWM1NWU2ZTI3ZTFhMCIsImVuY3J5cHRpb25LZXkiOiJzZWpqUUNaeVZ2UFdXd3RJQ3FvQ01Ea2ZWM3dIb0hFSmRMMHY5VEpIVWZRIiwiYnJhbmNoIjoiY3Vyc29yL2dpdGxhYi1pc3N1ZS13b3JrZmxvdy0yZGZmIiwicmVwb093bmVyIjoiUGxhc3RpY0RpZ2l0cyIsInJlcG9OYW1lIjoiY2w4eS1kZXgtdGVycmFjbGFzc2ljIn19" target="_blank" rel="noopener noreferrer"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/fix-in-cursor-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/fix-in-cursor-light.png"><img alt="Fix in Cursor" width="115" height="28" src="https://cursor.com/assets/images/fix-in-cursor-dark.png"></picture></a>&nbsp;<a href="https://cursor.com/agents?link=eyJ2ZXJzaW9uIjoxLCJ0eXBlIjoiQlVHQk9UX0ZJWF9JTl9XRUIiLCJkYXRhIjp7InJlZGlzS2V5IjoiYnVnYm90OmRjMWRlNmU0LWY3MjUtNDQ5OC05MDZlLWM1NWU2ZTI3ZTFhMCIsImVuY3J5cHRpb25LZXkiOiJzZWpqUUNaeVZ2UFdXd3RJQ3FvQ01Ea2ZWM3dIb0hFSmRMMHY5VEpIVWZRIiwiYnJhbmNoIjoiY3Vyc29yL2dpdGxhYi1pc3N1ZS13b3JrZmxvdy0yZGZmIiwicmVwb093bmVyIjoiUGxhc3RpY0RpZ2l0cyIsInJlcG9OYW1lIjoiY2w4eS1kZXgtdGVycmFjbGFzc2ljIiwicHJOdW1iZXIiOjg0LCJjb21taXRTaGEiOiJjYWM1YTQ1N2MxMTZjZWFmN2QyZGU5NWU1MjkyN2I2OGI5YTVkMWUwIiwicHJvdmlkZXIiOiJnaXRsYWIiLCJob3N0bmFtZSI6ImdpdGxhYi5jb20ifX0" target="_blank" rel="noopener noreferrer"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/fix-in-web-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/fix-in-web-light.png"><img alt="Fix in Web" width="99" height="28" src="https://cursor.com/assets/images/fix-in-web-dark.png"></picture></a></div> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit cac5a457c116ceaf7d2de95e52927b68b9a5d1e0. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup>
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
code/cl8y-dex-terraclassic!802
No description provided.