Keep the policy contract address in one place; it is repeated in three files
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- Half a day
- Newbie friendliness
- 72/100
- Issue type
- Refactor
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- shell
- Domain
- documentation, tooling
Research direction
Start with grep -rn "CACR5H46" . outside evidence/ to list every copy of the address, then read the "What it calls" table in README.md, line 13 of scripts/verify-deployment.sh, line 21 of scripts/testnet-demo.sh, and the "Moving to a different deployment" section of CONTRIBUTING.md. Use tests/fixtures/access_policy.wasm.sha256 as the model for a single shared file. Done when the address lives only in the new env file, a check fails with a message naming both files when the README disagrees, and both scripts still run.
Written by the indexing model from the issue text.
Description
Written against commit 78d0a89; later commits may have moved things, so check the code first.
Size: Trivial
Description
The address of Sorogate's public Testnet deployment is written by hand in README.md, scripts/verify-deployment.sh and scripts/testnet-demo.sh (and in the recorded evidence, which is a record of a past run and should keep it). CONTRIBUTING.md ("Moving to a different Sorogate deployment") tells the person to change all three together and nothing checks that they agree, so a move to a new deployment that misses one file leaves the demo and the check talking about different contracts.
Current state
README.md(the "What it calls" table),scripts/verify-deployment.shline 13,scripts/testnet-demo.shline 21.- The pinned hash already has one home:
tests/fixtures/access_policy.wasm.sha256, read by the tests and the script.
What to build
Put the address in one small file (for example scripts/deployment.env containing POLICY_CONTRACT=C...) that both scripts source, and add a check (a step in scripts/ run by CI, or a Rust test that reads the file) that fails if the README does not contain the same address. Update CONTRIBUTING.md's "Moving to a different deployment" steps to match. Do not touch evidence/.
Acceptance criteria
-
grep -rn "CACR5H46" scripts/finds the address only in the new file. - Changing the address in the new file without changing the README makes the check fail with a message naming both.
- Both scripts behave as before.
-
CONTRIBUTING.mdlists the new, shorter set of places to change.
Out of scope
Changing the deployment.
Verification
Run both scripts' bash -n, bash scripts/verify-deployment.sh, and the check, then edit the file and re-run the check.
- Dominant language
- Rust
- Stars
- 2
- Forks
- 2
- Avg merge
- 49m
- Merged PRs (30d)
- 1
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from Sorogate/example-consumer
-
documentation good first issue help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
Sorogate/example-consumer#17 ·
-
documentation good first issue help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 85/100
Sorogate/example-consumer#16 · 1 comment · 1 reaction ·
-
documentation good first issue help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Sorogate/example-consumer#15 ·
-
enhancement good first issue help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Sorogate/example-consumer#14 ·
-
enhancement good first issue help wanted
Difficulty 2/5 Half a day Newbie friendliness 80/100
Sorogate/example-consumer#12 ·
All issues in Sorogate/example-consumer
Similar issues
-
defect
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 2 days
-
enhancement user-priority/P3
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
Maintainers usually reply within 1 day