Skip to content

Don't send unstable signing key update EDUs#19481

Open
velikopter wants to merge 9 commits into
element-hq:developfrom
velikopter:fix/remove-unstable-sk-update
Open

Don't send unstable signing key update EDUs#19481
velikopter wants to merge 9 commits into
element-hq:developfrom
velikopter:fix/remove-unstable-sk-update

Conversation

@velikopter
Copy link
Copy Markdown
Contributor

@velikopter velikopter commented Feb 18, 2026

I think 5 years is enough.

Pull Request Checklist

  • Pull request is based on the develop branch
  • Pull request includes a changelog file. The entry should:
    • Be a short description of your change which makes sense to users. "Fixed a bug that prevented receiving messages from other servers." instead of "Moved X method from EventStore to EventWorkerStore.".
    • Use markdown where necessary, mostly for code blocks.
    • End with either a period (.) or an exclamation mark (!).
    • Start with a capital letter.
    • Feel free to credit yourself, by adding a sentence "Contributed by @github_username." or "Contributed by [Your Name]." to the end of the entry.
  • Code style is correct (run the linters)

@velikopter velikopter requested a review from a team as a code owner February 18, 2026 20:01
@reivilibre reivilibre self-requested a review March 3, 2026 12:37
Copy link
Copy Markdown
Contributor

@reivilibre reivilibre left a comment

Choose a reason for hiding this comment

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

Thank you very much, always nice to get a cleanup.


Some archaeology notes:


Comment thread changelog.d/19481.removal Outdated
# also send the unstable version
# FIXME: remove this when enough servers have upgraded
# and remove the length budgeting above.
results.append(("org.matrix.signing_key_update", result))
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Now each entry only produces only one EDU, need to update the 'budgeting' logic on R668 and R691 to compensate.

There are also a bunch of stale comments to remove. :)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I don't see any budgeting logic on R691..

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

sorry for being elusive, I think I meant

            if (
                is_cross_signing_key_update
                and user_id not in cross_signing_keys_by_user
            ):
                # This will give rise to 2 device updates.
                # If we don't have the budget, stop here!
                if remaining_length_budget < 2:
                    break

I think that full block can come out; if we updated this directly we'd change the 2nd if to if remaining_length_budget < 1: BUT we already have assert remaining_length_budget >= 0 earlier, so there is no time it would hit this anymore

Comment thread tests/storage/test_devices.py
@MadLittleMods MadLittleMods requested a review from reivilibre April 6, 2026 16:00
Copy link
Copy Markdown
Contributor

@reivilibre reivilibre left a comment

Choose a reason for hiding this comment

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

Thank you!

@reivilibre reivilibre enabled auto-merge (squash) April 9, 2026 17:20
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.

2 participants