Skip to content

feat: Federation Expiration - #574

Merged
m1sterc001guy merged 17 commits into
fedimint:masterfrom
m1sterc001guy:fed_expiry
Sep 16, 2026
Merged

m1sterc001guy merged 17 commits into
fedimint:masterfrom
m1sterc001guy:fed_expiry

Conversation

@m1sterc001guy

Copy link
Copy Markdown
Collaborator

Partially closes: #274

Adds a loud banner message when the meta in the federation has been set to indicate that the federation is expiring. Disables receives into the federation and disallows Lightning Address registrations. Details screen guides the user on what to do:

  1. Remove funds
  2. Remove their pre-existing Lightning Address
  3. Join successor or new federation
  4. Leave existing federation

Also fixes a bug with the onchain sweep logic for both walletv2 and walletv1.

image image image

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 15, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-09-16T19:36:37.825407Z cc80d38 New commits
🔒 Security Review ✅ Completed 2026-09-16T19:35:41.995022Z cc80d38 New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: d420473aa8

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread lib/screens/federation_info_screen.dart Outdated
Comment thread rust/ecashapp/src/multimint.rs Outdated
Comment thread rust/ecashapp/src/multimint.rs Outdated
Comment thread rust/ecashapp/src/multimint.rs Outdated
Comment thread lib/screens/dashboard.dart
Comment thread lib/screens/federation_expiry_screen.dart
Comment thread lib/screens/dashboard.dart

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 20b284e370

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread rust/ecashapp/src/multimint.rs
Comment thread lib/screens/dashboard.dart

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 18240a2162

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread lib/screens/federation_info_screen.dart
Comment thread lib/screens/federation_expiry_screen.dart Outdated
Comment thread lib/ln_address.dart Outdated
Comment thread rust/ecashapp/src/multimint.rs
Comment thread lib/screens/federation_expiry_screen.dart

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: cc80d38af3

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +294 to +296
hasExpired
? l10n.federationExpiryHeadlinePast(widget.federationName)
: l10n.federationExpiryHeadline(widget.federationName),

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Use successor-only wording on the details screen

When guardians publish only federation_successor, expiry is null and hasExpired is false, so this branch displays “is shutting down”; the same screen also always shows the shutdown explanation even though the banner explicitly treats a successor alone as a recommendation rather than a shutdown. Tapping the successor banner therefore escalates it into an unsupported closure warning that may prompt users to remove an address or leave unnecessarily. Add successor-only headline, title, and explanation copy when no expiry date was announced.

Useful? React with 👍 / 👎.

Comment thread lib/ln_address.dart
Comment on lines 217 to +218
Future<void> _onRegisteredPressed() async {
if (_selectedFederationExpiring) return;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Recheck expiry before registering an address

If guardians announce a shutdown while this screen remains open, this guard still uses the one-time _expiringFederations snapshot populated by _initialize; unlike the dashboard, the screen does not consume subsequent MetaUpdated events, and the backend registration call performs no expiry check. A user who opened the form before the periodic metadata refresh can therefore register after the shutdown date appears. Refresh or subscribe to metadata before enabling/submitting registration, preferably enforcing the check in the shared backend path.

Useful? React with 👍 / 👎.

@m1sterc001guy
m1sterc001guy merged commit 254b371 into fedimint:master Sep 16, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Escape Hatch

1 participant