-
Notifications
You must be signed in to change notification settings - Fork 261
v3: feature: verdi collab #7516
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
khsrali
wants to merge
48
commits into
aiidateam:main
Choose a base branch
from
khsrali:collab
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 39 commits
Commits
Show all changes
48 commits
Select commit
Hold shift + click to select a range
cfacf01
Node: preserve the modification time when rehashing
khsrali cf45eb3
Collab: add the collab profile options and the per-profile state file
khsrali 0c1ebec
Collab: add the wire protocol and the HTTP transport that carries it
khsrali cd79600
Collab: select and export the nodes a peer is owed since its cursor
khsrali 175ac9f
Archive: reject a thin collab delta in verdi archive import
khsrali 00a8cfb
Collab: negotiate the missing UUIDs and import a thin delta
khsrali ddf9b49
Collab: add the endpoint that serves pull negotiations and push imports
khsrali d257a18
Collab: supervise the collab endpoint as a watcher of the daemon
khsrali 0a02773
Collab: add verdi collab init and the join code that founds or joins
khsrali 139e9c9
Collab: add the immutable collab.policy option, fixed at creation
khsrali 9b166e3
Collab: stamp peer addresses and gossip the roster on every sync
khsrali 0a103bc
Collab: add verdi collab pull and verdi collab push
khsrali 1644259
Collab: gate the handshake on the peer's archive format version
khsrali c86861e
Collab: add verdi collab log and compact the log as it grows
khsrali 98865ba
Collab: add verdi collab rotate and rekey to replace the token
khsrali 44de161
Collab: add a collab section to verdi status
khsrali 2e1ed2c
Collab: record tombstones when nodes are deleted, to stop re-delivery
khsrali f315f76
Collab: replicate node extras between peers under the sync policy
khsrali 94b4788
Collab: replicate curated group membership under the grow policy
khsrali bfa730b
Collab: map computers so a pulled calculation can be a cache hit
khsrali d8c9785
Collab: cap concurrent endpoint work with expiring slots
khsrali 4e71c64
Docs: add the how-to for sharing provenance with collab peers
khsrali a99432d
Collab: a three-member end-to-end suite over the real wire
khsrali d7dfde2
🐛 Collab: hold every route against the collab UUID
khsrali d64cc55
🐛 Collab: one lock for every collab configuration write
khsrali 6f0e2cb
🐛 Collab: refuse a push at its first request, and sweep what one leav…
khsrali 168f0c5
🐛 Collab: hold a serving slot for the peer, not for the request
khsrali b62188c
🐛 Collab: let a peer say that its negotiation is over
khsrali a466f3e
🐛 Collab: one bad peer no longer ends the round
khsrali d93bc2a
🐛 Collab: renegotiate the extras a retried push had negotiated
khsrali ce03347
🐛 Collab: read the collab state at the instant a sync describes
khsrali cbf9f9c
🐛 Collab: the join code is asked for, not printed by `verdi status`
khsrali fa86096
🧪 Collab: pin why the claim carries every tombstone
khsrali 66549fb
🐛 Collab: a withheld seed stops disabling the delta cache
khsrali 95c5200
🐛 Collab: report the sealed processes no delta can carry
khsrali ea59a9c
🐛 Collab: a policy pydantic can build, a log the bug report carries, …
khsrali 2da1799
👌 Collab: name the computers that arrived through the collab
khsrali eb9d122
🐛 Collab: a computer map cannot name a computer this profile lacks
khsrali 184cdbd
📚 Collab: say that a node's PK is local to the profile it lands in
khsrali e00cb76
🐛 Collab: the 401 says that it closes the connection
khsrali 3b9d60a
🐛 Collab: offer the extras a peer without a cursor may already hold
khsrali be5a3ca
🐛 Collab: refuse tombstoned nodes at the diff, not in the claim
khsrali fe65e9d
🐛 Collab: what a delta offers, and when it must be renegotiated
khsrali 6f3e29d
🐛 Collab: the HTTP layer answers rather than hangs
khsrali e03825a
🐛 Collab: the locks say what they know, and the roster survives a bad…
khsrali 8b5057f
🐛 Collab: one sync at a time, and init never founds over a membership
khsrali bb587e9
🧪 Collab: the convergence oracle compares content, not only shape
khsrali 53df008
📚 Collab: the one-command rule, and what a tombstone does not gate
khsrali File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -64,3 +64,4 @@ docker-bake.override.json | |
|
|
||
| # dev files | ||
| .dev | ||
| .aep/ | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1 +1,29 @@ | ||
| @AGENTS.md | ||
|
|
||
|
|
||
| ## Code | ||
|
|
||
| The smallest change that satisfies the requirement. Prefer extending an existing function or module over adding a new one. No abstraction, configuration knob, or extensibility hook until there is a second caller that needs it. | ||
|
|
||
| No defensive code for conditions that cannot currently occur. No compatibility shims for versions we do not support. | ||
|
|
||
| Comments explain *why*, never *what*. If a comment restates the line below it, delete the comment. If the code needs a comment to be readable, first try renaming things. | ||
|
|
||
| Delete code that a change makes dead. Do not leave it commented out — that is what git is for. | ||
|
|
||
| ## Tests | ||
|
|
||
| Test the functionality, not the implementation. The minimum suite that would actually fail if the feature broke, and no more. | ||
|
|
||
| Mock anything slow or external: network, filesystem beyond a tmpdir, databases, subprocesses, time, third-party APIs. CI time is a real cost. | ||
|
|
||
| One test per behavior. No parametrized matrices covering combinations that cannot differ. No test helper frameworks, custom assertion DSLs, or fixture hierarchies built for a single test file — a test that needs its own framework to be readable is over-engineered. | ||
|
|
||
| A test that cannot fail is worse than no test. Before adding one, know what break it catches. | ||
|
|
||
| It's better to run pytest via "-n auto" to speed up | ||
|
|
||
|
|
||
| ## Development phases | ||
|
|
||
| Don't worry about migration between development phases. All phases in this PR are still a PR, there're no users yet. |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -17,6 +17,7 @@ How-To Guides | |
| data | ||
| query | ||
| share_data | ||
| collaborate | ||
| archive_profile | ||
| visualising_graphs | ||
| installation | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -17,6 +17,7 @@ | |
| cmd_bug_report, | ||
| cmd_calcjob, | ||
| cmd_code, | ||
| cmd_collab, | ||
| cmd_computer, | ||
| cmd_config, | ||
| cmd_daemon, | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🔒 Security & Privacy | 🟡 Minor | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
Repository: aiidateam/aiida-core
Length of output: 24540
🏁 Script executed:
Repository: aiidateam/aiida-core
Length of output: 50376
🏁 Script executed:
Repository: aiidateam/aiida-core
Length of output: 47434
🏁 Script executed:
Repository: aiidateam/aiida-core
Length of output: 50376
Stop logging the full request line.
BaseHTTPRequestHandler.send_response()logsself.requestline, which includes query strings even for unauthenticated requests. A token or join code in the request URL is therefore copied to the collab log and bug-report archive. Log only the method and path, without the query string.🤖 Prompt for AI Agents
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The server's
log_messagewrites at DEBUG only, and no request in this protocol ever carries a token or join code in a URL — the token travels exclusively as a Bearer header, the join code never travels at all. The scenario needs debug logging enabled and a client that does not exist, so we are leaving it as is.