Prove that disk and network peers obey the same Peer protocol
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Idoneità per principianti
- 70/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- postgresql, python
- Ambito
- backend, testing-qa
Direzione di ricerca
Inizia da tests/testapp/tests/integration/test_peer_protocol_contract.py, leggendo la sottoclasse di rete di #372 e l’harness del secondo server in tests/testapp/tests/integration/test_syncsession.py. Aggiungi la sottoclasse disco usando un percorso temporaneo e un alias di archivio, quindi esegui python -O -m pytest tests/testapp/tests/integration/test_peer_protocol_contract.py -v nell’ambiente postgres tox. Il lavoro è completato quando entrambe le sottoclassi superano tutti e sette i casi di contratto invariati.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Overview
The contract suite runs its cases against the disk connection, so that both connection types show the same Peer protocol behavior. This issue is part of milestone M7 (verification).
Background & Motivation
#372 wrote the contract suite and ran it against the network connection. The network connection is the reference implementation. The disk connection copies the order of the server stage steps, and that copy can drift from the server behavior over time.
A run of the same cases against the disk connection catches this drift early. If a case fails, the test identifies the exact protocol behavior that differs.
Design: spec. Plan: implementation plan, Task 24.
Description & Expected Outcomes
A disk subclass of the contract suite runs every contract case with a DiskSyncConnection on a temporary path. The subclass reads the peer records from the archive alias. The contract cases themselves do not change.
If a disk case fails, the fix goes into DiskSyncConnection. The contract case stays as the reference behavior.
Deliverables & Contracts
The feature delivers these capabilities:
- A disk subclass of
PeerProtocolContractin the contract suite. - All contract cases pass for the network subclass and the disk subclass.
Acceptance Criteria
-
DiskPeerProtocolTestCaseexists and runs all cases ofPeerProtocolContract. - All seven contract cases pass for both subclasses.
- No contract case changes in this issue.
- The contract suite passes in the
postgrestox environment.
Technical Pointers & Architecture
- Target Components / Context:
tests/testapp/tests/integration/test_peer_protocol_contract.py. - Related Patterns: The network subclass from #372 and the second-server harness in
tests/testapp/tests/integration/test_syncsession.py. - Data Model & Schema Considerations: None.
- Resilience & Failure Modes: Contract case 6 expects a rejection of records outside the filter. The network raises
requests.HTTPError, and the disk connection raisesValidationError.
Notes & Tradeoffs
- Dependencies: Blocked by: #372 (contract suite, network half), #384 (disk Peer protocol). Blocks: none.
- Testing Requirements: Integration tests. Run
python -O -m pytest tests/testapp/tests/integration/test_peer_protocol_contract.py -v. - Tradeoffs & Alternatives Considered: The parity test in #386 compares data outcomes. The contract suite compares protocol behavior. Both are necessary.
Metadata
- Complexity: Low
- Target Branch: release-v0.9.x
AI Usage
Drafted with Claude (Claude Code) from the approved design spec and implementation plan. The author reviewed the requirements, and the code references were checked against the release-v0.9.x codebase.
- Lingua principale
- Python
- Stelle
- 15
- Fork
- 23
- Merge medio
- 1g 11h
- PR unite (30g)
- 4
Preparare l'ambiente
- Include un Dockerfile o un file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di learningequality/morango
-
DEV: dev-ops DEV: distributions DOCS: developer
Difficoltà 1/5 1-3 ore Idoneità per principianti 78/100
learningequality/morango#387 ·
-
DEV: backend P0 - critical TAG: tech update / debt TAG: unit tests
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
learningequality/morango#364 ·
-
DEV: backend TAG: new feature
Difficoltà 5/5 Più di una settimana Idoneità per principianti 10/100
learningequality/morango#388 ·
-
DEV: backend TAG: unit tests
Difficoltà 4/5 3-5 giorni Idoneità per principianti 55/100
learningequality/morango#386 ·
-
DEV: backend P0 - critical TAG: new feature
Difficoltà 4/5 3-5 giorni Idoneità per principianti 38/100
learningequality/morango#384 ·
Tutte le issue di learningequality/morango
Issue simili
-
needs-human needs-triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
gke-labs/kube-agents#2400 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Device Details tables: FS/SF columns contradict each other (nfet_01v8 Vt row, pfet_01v8 Idsat row)Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
google/skywater-pdk#450 ·
-
Drained trajectory arrays are overwritten when the sequence buffer is reusedForse già presa @sylvesterkaczmarek l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
google-deepmind/bsuite#56 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
LearningCircuit/local-deep-research#7206 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
chingu-voyages/V62-tier3-team-33#285 ·
I maintainer di solito rispondono entro 1 giorno