Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

BReg: name `relationship` in the Action input refusal message

Aperta Adatta ai principianti
#2,150 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
92/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
rust
Ambito
backend

Direzione di ricerca

Inizia in crates/registry-breg/src/contract.rs presso impl Deserialize for ActionInputSource, dove sono definiti la condizione di rifiuto e il messaggio Invalid::expected. Aggiorna le due stringhe di member previste ed esamina l'asserzione in crates/registry-breg/tests/field_encryption_contract.rs; se necessario, aggiungi o modifica un test sibling che copra un member relationship. La modifica è completata quando il testo della diagnostica e del quick fix indica relationship, la validazione lo rifiuta ancora e i test rilevanti superano.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

area:breg bug criticality:p3

A relationship member on an Action input is refused, which is correct: inputs are ephemeral and
cannot declare an inverse relationship. But the diagnostic and its fix-it list only
validTimeRole, pattern, encrypted and lookup. An author who copied a reference field into
inputs is told to remove four members, none of which is present, and the one that caused the
refusal is never named.

Minimal repro, in a project whose registry.yaml has an Action with a reference input:

actions:
  - id: register-facility
    # ...
    inputs:
      - id: operator
        type: reference
        target: operator
        relationship: {inverseName: registeredFacilities}
        required: true
        classification: internal

bregctl check <project> reports:

error[config.invalid-value] registry.yaml:<line>:<col> /actions/0/inputs/<n>
  expected an action input without validTimeRole, pattern, encrypted, or lookup
  next: Remove validTimeRole, pattern, encrypted, and lookup from the action input.

Expected:

  expected an action input without validTimeRole, pattern, encrypted, lookup, or relationship
  next: Remove validTimeRole, pattern, encrypted, lookup, and relationship from the action input.

Likely fix: crates/registry-breg/src/contract.rs, impl Deserialize for ActionInputSource. The
condition already refuses raw.relationship; only the two strings passed to Invalid::expected
need the fifth member. The assertion in crates/registry-breg/tests/field_encryption_contract.rs
(native_proposal_inputs_do_not_accept_persisted_record_encryption_members) matches the current
wording with .contains(...) and needs the same update. A sibling test that sets relationship
on an input would cover the case. Naming only the member actually present would be a better
message still.

The generated authoring schema already refuses relationship on inputs, so this is a
message-only fix.

Seen on main at 2fe7e90b2: the condition and both strings are unchanged.

Lingua principale
Rust
Stelle
2
Fork
0
Merge medio
10h 32m
PR unite (30g)
256

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di registrystack/registry-stack

Tutte le issue di registrystack/registry-stack

Issue simili

Altre issue su Rust

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.