Skip to content

feat(contract): extend storage TTL for escrow entries and instance (%2310) - #239

Open
shakourllahfashola-dev wants to merge 1 commit into
DocForum:mainfrom
shakourllahfashola-dev:feat/storage-ttl-issue-10
Open

shakourllahfashola-dev wants to merge 1 commit into
DocForum:mainfrom
shakourllahfashola-dev:feat/storage-ttl-issue-10

Conversation

@shakourllahfashola-dev

Copy link
Copy Markdown
Contributor

closes #10

@drips-wave

drips-wave Bot commented Oct 21, 2026

Copy link
Copy Markdown

@shakourllahfashola-dev Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@afeezorobsco-cyber

Copy link
Copy Markdown
Contributor

@shakourllahfashola-dev CI is failing on this branch against the latest main, so it can't be merged yet. The errors from the latest run:

Soroban contract (test + wasm build)

cargo test changed committed Soroban snapshots under contracts/escrow/test_snapshots.

SDK bindings match contract WASM

sdk/src/generated/contract-client.ts is out of date.

sdk/src/generated/contract-client.ts doesn't match the contract any more, because main has changed the contract since your branch was created. Regenerate the bindings against the latest main and commit them:

cd contracts/escrow && cargo build --target wasm32v1-none --release
stellar contract bindings typescript --wasm target/wasm32v1-none/release/docforum_escrow.wasm --output-dir /tmp/escrow-bindings --overwrite
cp /tmp/escrow-bindings/src/index.ts ../../sdk/src/generated/contract-client.ts

(scripts/check-generated-bindings.sh runs the same check locally.)

Your change alters contract behaviour that the committed Soroban snapshots record. Run cargo test in contracts/escrow, review the diff under contracts/escrow/test_snapshots/, and commit the updated snapshots.

@github-actions github-actions Bot added the needs-rebase Has merge conflicts with main; the author needs to rebase label Oct 22, 2026
@github-actions

Copy link
Copy Markdown

@shakourllahfashola-dev This PR now has merge conflicts with main, most likely because #180 (feat(sdk): batch create and batch settle support) was just merged, so it can't be merged until it's rebased:

git fetch upstream            # upstream = https://github.com/DocForum/docforum-escrow.git
git rebase upstream/main
# resolve the conflicts, re-run the tests, then:
git push --force-with-lease

The usual culprits are shared docs like ROADMAP.md and ARCHITECTURE*.md. If the conflict is in the ROADMAP.md changelog, move your entry into a new file under changelog.d/ (see changelog.d/README.md) rather than resolving it in place, so it can't conflict again. CI re-runs when you push, and the needs-rebase label is removed automatically once the conflicts are resolved.

Automated message. It won't repeat unless the PR conflicts again after your next push.

@github-actions github-actions Bot removed the needs-rebase Has merge conflicts with main; the author needs to rebase label Oct 22, 2026
@afeezorobsco-cyber

Copy link
Copy Markdown
Contributor

@shakourllahfashola-dev CI is failing on this branch against the latest main, so it can't be merged yet. The errors from the latest run:

SDK bindings match contract WASM

sdk/src/generated/contract-client.ts is out of date.

sdk/src/generated/contract-client.ts doesn't match your contract. Regenerate it (don't hand-edit or hand-merge it):

cd contracts/escrow && cargo build --target wasm32v1-none --release
stellar contract bindings typescript --wasm target/wasm32v1-none/release/docforum_escrow.wasm --output-dir /tmp/escrow-bindings --overwrite
cp /tmp/escrow-bindings/src/index.ts ../../sdk/src/generated/contract-client.ts

sdk/src/generated/contract-client.ts doesn't match the contract any more, because main has changed the contract since your branch was created. Regenerate the bindings against the latest main and commit them:

cd contracts/escrow && cargo build --target wasm32v1-none --release
stellar contract bindings typescript --wasm target/wasm32v1-none/release/docforum_escrow.wasm --output-dir /tmp/escrow-bindings --overwrite
cp /tmp/escrow-bindings/src/index.ts ../../sdk/src/generated/contract-client.ts

(scripts/check-generated-bindings.sh runs the same check locally.)

@github-actions github-actions Bot added the needs-rebase Has merge conflicts with main; the author needs to rebase label Oct 24, 2026
@github-actions

Copy link
Copy Markdown

@shakourllahfashola-dev This PR now has merge conflicts with main, most likely because #260 (feat(perf): profile and optimize status reads) was just merged, so it can't be merged until it's rebased:

git fetch upstream            # upstream = https://github.com/DocForum/docforum-escrow.git
git rebase upstream/main
# resolve the conflicts, re-run the tests, then:
git push --force-with-lease

The usual culprits are shared docs like ROADMAP.md and ARCHITECTURE*.md. If the conflict is in the ROADMAP.md changelog, move your entry into a new file under changelog.d/ (see changelog.d/README.md) rather than resolving it in place, so it can't conflict again. CI re-runs when you push, and the needs-rebase label is removed automatically once the conflicts are resolved.

Automated message. It won't repeat unless the PR conflicts again after your next push.

@shakourllahfashola-dev

Copy link
Copy Markdown
Contributor Author

Kindly review.

@github-actions github-actions Bot removed the needs-rebase Has merge conflicts with main; the author needs to rebase label Oct 25, 2026
@afeezorobsco-cyber

Copy link
Copy Markdown
Contributor

@shakourllahfashola-dev CI is failing on two jobs.

Resource cost baseline:

get_escrow exceeds source-size baseline

If the growth is intended, update the baseline (see scripts/check-resource-baseline.py) and note why in the PR.

The SDK bindings match contract WASM job fails: sdk/src/generated/contract-client.ts is out of date with the contract. Regenerate it:

cd contracts/escrow
cargo build --target wasm32v1-none --release
stellar contract bindings typescript --wasm target/wasm32v1-none/release/docforum_escrow.wasm --output-dir /tmp/escrow-bindings --overwrite
cp /tmp/escrow-bindings/src/index.ts ../../sdk/src/generated/contract-client.ts

Use stellar CLI 28.1.0, as CI does (see scripts/stellar-cli-version).

Please fix and push.

@github-actions github-actions Bot added the needs-rebase Has merge conflicts with main; the author needs to rebase label Oct 27, 2026
@github-actions

Copy link
Copy Markdown

@shakourllahfashola-dev This PR now has merge conflicts with main, most likely because #164 (feat(sdk): publish dual ESM and CommonJS builds) was just merged, so it can't be merged until it's rebased:

git fetch upstream            # upstream = https://github.com/DocForum/docforum-escrow.git
git rebase upstream/main
# resolve the conflicts, re-run the tests, then:
git push --force-with-lease

The usual culprits are shared docs like ROADMAP.md and ARCHITECTURE*.md. If the conflict is in the ROADMAP.md changelog, move your entry into a new file under changelog.d/ (see changelog.d/README.md) rather than resolving it in place, so it can't conflict again. CI re-runs when you push, and the needs-rebase label is removed automatically once the conflicts are resolved.

Automated message. It won't repeat unless the PR conflicts again after your next push.

@afeezorobsco-cyber

Copy link
Copy Markdown
Contributor

@shakourllahfashola-dev Heads-up: #268 just changed how contract PRs work in this repo. Your PR changes contracts/escrow/src/lib.rs, so CI's new "Contract changes use a fragment, not a version bump" step will fail it until you make these changes (details in contract-changes.d/README.md):

  1. Don't edit CONTRACT_VERSION when you merge main (currently 2.3.0). Keep main's line as it is.

  2. Add a fragment, e.g. contract-changes.d/10-feat-contract-extend-storage-ttl-for-esc.md:

    bump: minor
    ---
    Issue #10: one-paragraph summary of the contract change.

    Use patch for a behaviour fix with no interface change, minor for new entry points, arguments, events or errors, and major for breaking changes.

  3. If you add any new Error variants, give them provisional codes (issue number × 100 + n, e.g. 1000) and never renumber existing ones.

This should also make your next merge from main much easier: the version line was the one thing every contract PR conflicted on.

@github-actions

Copy link
Copy Markdown

@shakourllahfashola-dev This PR now has merge conflicts with main, most likely because #238 (feat(contract): emit lifecycle events on create, release, and refund (%239)) was just merged, so it can't be merged until it's rebased:

git fetch upstream            # upstream = https://github.com/DocForum/docforum-escrow.git
git rebase upstream/main
# resolve the conflicts, re-run the tests, then:
git push --force-with-lease

The usual culprits are shared docs like ROADMAP.md and ARCHITECTURE*.md. If the conflict is in the ROADMAP.md changelog, move your entry into a new file under changelog.d/ (see changelog.d/README.md) rather than resolving it in place, so it can't conflict again. CI re-runs when you push, and the needs-rebase label is removed automatically once the conflicts are resolved.

Automated message. It won't repeat unless the PR conflicts again after your next push.

…ocForum#10)

Extend instance TTL on every public contract call (~30 days, threshold ~7 days) and escrow entry persistent TTL on create_escrow (~180 days default or deadline + 30-day grace, threshold ~30 days). Active write paths extend entry TTL; settlement paths maintain a 30-day post-settlement audit window. Confirmed NextId continuity and non-reuse across archival.

Closes DocForum#10
@github-actions github-actions Bot removed the needs-rebase Has merge conflicts with main; the author needs to rebase label Oct 29, 2026
@afeezorobsco-cyber

Copy link
Copy Markdown
Contributor

@shakourllahfashola-dev The conflict is resolved, thanks. Three checks still fail:

  1. Contract change fragment (Soroban job): lib.rs changed but there is no fragment. Add contract-changes.d/10-storage-ttl.md:
    bump: minor
    ---
    Issue #10: extend storage TTL for escrow entries and instance storage (see ARCHITECTURE_ESSENTIALS.md § Storage TTL & Archival).
  2. Resource cost baseline: get_escrow exceeds source-size baseline. The TTL extension makes get_escrow larger than the recorded baseline. If that's intended, update the baseline with scripts/check-resource-baseline.py's update mode and say why in the PR.
  3. SDK bindings: sdk/src/generated/contract-client.ts is out of date. Regenerate it with stellar CLI 28.1.0 (./scripts/check-generated-bindings.sh prints the steps and must report OK).

Then push.

@github-actions github-actions Bot added the needs-rebase Has merge conflicts with main; the author needs to rebase label Oct 31, 2026
@github-actions

Copy link
Copy Markdown

@shakourllahfashola-dev This PR now has merge conflicts with main, most likely because #271 (chore(contract): fold contract changes into 2.5.0 and fold changelog) was just merged, so it can't be merged until it's rebased:

git fetch upstream            # upstream = https://github.com/DocForum/docforum-escrow.git
git rebase upstream/main
# resolve the conflicts, re-run the tests, then:
git push --force-with-lease

The usual culprits are shared docs like ROADMAP.md and ARCHITECTURE*.md. If the conflict is in the ROADMAP.md changelog, move your entry into a new file under changelog.d/ (see changelog.d/README.md) rather than resolving it in place, so it can't conflict again. CI re-runs when you push, and the needs-rebase label is removed automatically once the conflicts are resolved.

Automated message. It won't repeat unless the PR conflicts again after your next push.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-rebase Has merge conflicts with main; the author needs to rebase

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Phase E4] Extend storage TTL so escrows don't archive

2 participants