Recipe call arguments that name a data-driven column are not expanded, and the result depends on map order
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 58/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Attiva
- Stack tecnologico
- go
- Ambito
- testing-qa
Direzione di ricerca
Start in internal/runner/executor.go at runRecipeCall and resolve, then read the Data-driven page mentioned in the issue. Reproduce the issue with an Executor unit test using row values in e.vars and recipe arguments containing <email> and <password>. Done when recipe arguments are either expanded consistently before binding or the lint and documentation rule is made explicit, with behavior independent of map order.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
What happens
A recipe called from a data-driven test cannot reliably receive the row's columns as call arguments.
recipe "sign in as" (email, password)
type "<email>" into #email
type "<password>" into #password
test "role-based access"
sign in as "<email>" with "<password>"
with examples:
email password
"[email protected]" "admin123"
runRecipeCall binds each argument's text as it is (internal/runner/executor.go, the loop that calls setVar(param, args[i], ...)), so the parameter email is set to the text <email>. That replaces the row's email, and resolve then finds a variable whose value is its own placeholder and makes no progress: the step types <email> literally.
With parameter names that differ from the columns (recipe "sign in as" (address, secret)), the call binds address to the text <email>. resolve makes one pass over the variables in map order, so whether <address> becomes <email> and then the row's value depends on the order the pass visits address and email.
Measured
In a unit test on Executor (newTestExecutor, the row values set in e.vars, runRecipeCall with the arguments "<email>" and "<password>", then e.resolve("type <address> then <secret>")), 300 runs gave four different results:
type <email> then <password>: 179type [email protected] then <password>: 51type <email> then rowpw: 37type [email protected] then rowpw: 33
With the parameters named like the columns, the result is type <email> every time.
Expected
Either the arguments of a recipe call are expanded (against the row and the other variables) before they are bound, or probe lint and the docs say that a column must not be passed as an argument. The Data-driven page now says the latter, and shows a recipe without parameters that reads the columns directly; that form does not depend on the order.
Found while checking the recipe "log in as" example, which also had a keyword problem (fixed separately).
- Lingua principale
- Go
- Stelle
- 6
- Fork
- 3
- Merge medio
- 6h 28m
- PR unite (30g)
- 362
Preparare l'ambiente
- Nessun Dockerfile né 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 AlphaWaveSystems/flutter-probe
-
agent: is checked on a wrapper holding several checkables answers from the first one in tree orderApertabug
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
AlphaWaveSystems/flutter-probe#865 ·
I maintainer di solito rispondono entro 1 giorno
-
area/cli bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 73/100
AlphaWaveSystems/flutter-probe#424 ·
I maintainer di solito rispondono entro 1 giorno
-
area/docs documentation
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
AlphaWaveSystems/flutter-probe#409 ·
I maintainer di solito rispondono entro 1 giorno
-
Dial timeout error should say how long it waited and name the timeout settingForse già presa @jay23606 l’ha presa 2 giorni fa. Apertaarea/cli bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
AlphaWaveSystems/flutter-probe#408 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 45/100
AlphaWaveSystems/flutter-probe#888 ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di AlphaWaveSystems/flutter-probe
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
IBM-Cloud/terraform-provider-ibm#7115 ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 86/100
fluxcd/notification-controller#1441 ·
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
volcengine/volcengine-go-sdk#163 · 1 commento ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
OneBusAway/maglev#2145 ·
I maintainer di solito rispondono entro 2 giorni
-
priority/medium status/ready type/chore
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
discobox-ai/discobox#1357 ·
I maintainer di solito rispondono entro 1 giorno