A sync change can modify a channel other than the one it names
Les mainteneurs répondent en général sous 1 jour
Personne n'a encore pris cette issue.
Évaluation
- Difficulté
- 3/5
- Temps estimé
- 1-2 jours
- Accessibilité débutants
- 68/100
Piste de recherche
Start with SyncView.handle_changes in contentcuration/contentcuration/viewsets/sync/endpoint.py, then trace the contentnode create, update, and move handlers that use parent or target. Add tests for changes naming a different channel and run the relevant sync endpoint tests. Done means those mismatched changes are rejected without creating nodes or change records, while valid same-channel changes still work.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Description
Overview
The sync endpoint checks that the user can edit the channel_id a change names, and records the change under that channel. Nothing checks that the parent or target of a contentnode create, update or move is in that channel. A user who edits two channels can send a change naming channel A that creates a node in channel B, and channel B records no change for it, so its unpublished-changes tracking misses the edit.
Complexity: Medium
Target branch: hotfixes
Context
SyncView.handle_changessorts changes by theirchannel_idand creates theChangerows with it. The contentnode create, update and move handlers then place the node under whateverparentortargetthe change gives.- Reproduced: an editor of channels A and B sent a contentnode create change with
channel_idA andparentset to B's root node. The node was created in B, theChangerow was recorded under A, and B had noChangerows.
The Change
- A contentnode create, update or move change should be rejected when its
parentortargetisn't in the channel the change names.
Acceptance Criteria
General
- The reproduced change in Context is rejected with an error, and nothing is created in either channel.
- Changes whose objects are in the named channel are applied as before.
Testing
- Tests cover create, update and move changes whose
parentortargetis in a different channel from the one the change names.
AI usage
I scoped the audit. Claude Code found and reproduced this failure and drafted this issue.
- Langage dominant
- Python
- Étoiles
- 212
- Forks
- 321
- Merge moyen
- 1 j 7 h
- PR mergées (30 j)
- 14
Préparer son environnement
- Fournit un Dockerfile ou un fichier Docker Compose
- Aucun modèle de pull request
- Lire le guide de contribution
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Autres issues de learningequality/studio
-
Community library status changes don't update `date_updated`Peut-être pris @LightCreator1007 l’a pris il y a 1 jour. OuverteDEV: backend good first issue help wanted
Difficulté 2/5 1-3 heures Accessibilité débutants 84/100
learningequality/studio#6414 · 3 commentaires ·
Les mainteneurs répondent en général sous 1 jour
-
DEV: backend
Difficulté 2/5 1-3 heures Accessibilité débutants 82/100
learningequality/studio#6410 ·
Les mainteneurs répondent en général sous 1 jour
-
DEV: backend
Difficulté 2/5 1-3 heures Accessibilité débutants 76/100
learningequality/studio#6409 ·
Les mainteneurs répondent en général sous 1 jour
-
DEV: backend
Difficulté 2/5 1-3 heures Accessibilité débutants 78/100
learningequality/studio#6407 ·
Les mainteneurs répondent en général sous 1 jour
-
DEV: backend good first issue help wanted
Difficulté 2/5 1-3 heures Accessibilité débutants 78/100
learningequality/studio#6404 · 1 commentaire ·
Les mainteneurs répondent en général sous 1 jour
Toutes les issues de learningequality/studio
Issues similaires
-
[Bug]: HTTP 499 (Client Closed Request) is classified as a non-retryable format_error, so a mid-flight abort fails the turn over instead of retryingPeut-être pris @yipinghuang1991 l’a pris aujourd’hui. Ouvertecomp/agent P2 type/bug
Difficulté 2/5 1-3 heures Accessibilité débutants 82/100
NousResearch/hermes-agent#156837 ·
Les mainteneurs répondent en général sous 1 jour
-
Bug: Missing continue on ValueError in CpanBackend.check_feed causes UnboundLocalError or duplicate yieldsPeut-être pris @muskan-creates352 l’a pris aujourd’hui. Ouverte
Difficulté 1/5 1-3 heures Accessibilité débutants 86/100
fedora-infra/anitya#2188 ·
Les mainteneurs répondent en général sous 1 jour
-
docs documentation need-triage SaaS
Difficulté 2/5 1-3 heures Accessibilité débutants 72/100
Les mainteneurs répondent en général sous 1 jour
-
integration:hermes
Difficulté 2/5 1-3 heures Accessibilité débutants 85/100
vectorize-io/hindsight#6601 ·
Les mainteneurs répondent en général sous 1 jour
-
triage:product type:bug
Difficulté 2/5 1-3 heures Accessibilité débutants 76/100
dbt-labs/dbt-adapters#2333 ·
Les mainteneurs répondent en général sous 1 jour