pomerado 0.4.0-canary.310 → 0.4.0-canary.312

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -164,6 +164,8 @@
164
164
 
165
165
  ### Other changes
166
166
 
167
+ - The forms skill tells a script to name a conditional pop-up's close control as `dismiss` of `waitForReady`, which closes it whenever it opens, rather than checking for it at one point. The testing skill adds a live case for a free-text input with a value the example used written another way, such as in other case or with other spacing, punctuation or accents. The core skill says to prefer a unique input, such as an ID: a tool that acts on one record takes the ID the site's other tools use for it, and finds the record another way, such as by name, only when the caller gives none.
168
+ - A recorded minter response keyed on the exact forms, testing or core skill text needs recording again.
167
169
  - The core skill tells a search step to wait for either the site's results or its own no-match state, and to return the site's no-match answer with its message, so a value the site does not recognise no longer runs into a timeout waiting on results that never appear.
168
170
  - A recorded minter response keyed on the exact core skill text needs recording again.
169
171
  - The caller-input skill says to apply each caller input the way the site applies it, and only that: no added constraints between inputs, no filtering of them and no value the caller didn't give, so a store and a delivery ZIP the site sets separately are both applied as given. The search skill says that a location given without a store uses what the site would show for that location, such as the nearest store, rather than what the site guessed from the browser's own location, and returns what was applied.
@@ -670,6 +672,8 @@
670
672
 
671
673
  ### Fixes
672
674
 
675
+ - The refusal of a step that repeats a write no longer tells the minter to wait for an outcome review when the host wires none (`MintDependencies.outcomeReview` absent). It used to say the write stays refused until its outcome review finds it did not happen, a review that never comes there, which led a minter to send the write again through a copy of the step. Without an outcome reviewer, the refusal now says the step stays refused for the rest of the attempt, never to run a copy of it to send the write again, and to read back what happened in a new file that changes nothing. With one, its note on reusing the write's file says the step stays refused only until the outcome review finds the earlier write did not happen, and then to run that step itself again, not a copy.
676
+ - A recorded minter response keyed on the exact refusal text needs recording again.
673
677
  - Guardian's execution review treats a sign-in field as a valid code slot when its label, name, id or placeholder asks for a one-time, verification or authenticator code, or when it is the screen's only text input and the screen's own prompt asks for that code, even when it is a plain text box without `autocomplete="one-time-code"` or a numeric `type` or `inputmode`. A username, email, password, search, recovery or backup code, card security code, security question answer, captcha, voucher or promo field never takes a code, nor does a field whose own label, name or id names such a value. The policy used to call the slot a "one-time-code field", which reviews could read as requiring that autocomplete token, so the same field was allowed in one review and refused as final in another.
674
678
  - A recorded Guardian response keyed on the exact policy text needs recording again.
675
679
  - A `host_refused` report now ends a build as sign-in unavailable once the host refused a sign-in screen because the login's password fills are spent. The host fills a password at most twice in one sign-in and refuses every later screen that needs it as `credential_already_filled`, a step result rather than a failure, so the harness had no host refusal on record and refused the report as `host_not_refused`, while the minter tried recoveries that could not sign in. The new optional `MintDependencies.signInRefillRefused` says whether the host refused such a screen and the password is still spent, with no sign-in verified and no corrected login since, and a `host_refused` report stands on it as on any host refusal of a sign-in; with the sign-in unconfirmed, the build ends as sign-in unavailable. Spent fills with no screen refused yet, and a fill that remains, leave the report refused as before. `passwordFillsSpent` from `pomerado/core/runtime/autofill-state` reads the spent state from a host's sign-in state, and the local host's recorder answers the dependency. A host without the dependency is unchanged.
@@ -191,8 +191,10 @@ exception: it is optional unless the task can't run without it (below).
191
191
  from the one you saw.
192
192
  - Inputs are values a caller knows, such as codes, names, dates and counts, never a
193
193
  suggestion's full display text or an internal id the caller cannot know (an id the site
194
- shows on its own pages, such as a product number, is not internal). A closed list
195
- of options stays an enum of the site's options, as above. When the options come from a
194
+ shows on its own pages, such as a product number, is not internal). Prefer a unique input,
195
+ such as an ID: a tool that acts on one record takes the ID the site's other tools use for it,
196
+ and finds the record another way, such as by name, only when the caller gives none. A closed
197
+ list of options stays an enum of the site's options, as above. When the options come from a
196
198
  query, as in a search box, autocomplete, typeahead or searchable combobox, look the value
197
199
  up the way a person would, with `pickValue` from `pickerCode` (forms skill). It types the
198
200
  caller's value into the site's own search, reads every suggestion, matches names loosely
@@ -146,9 +146,9 @@ shows one, and otherwise with any of its controls, accept included. Name that co
146
146
 
147
147
  Decide whether each pop-up, banner or interstitial is conditional or always triggered. A
148
148
  conditional one shows only for some accounts, states or visits, such as a cookie banner, a
149
- one-time promotion or a membership upsell shown only to non-members: check for it, resolve it
150
- when it shows, and continue without error when it does not, as one outcome beside the page's
151
- next state. Never wait for it or require it. One the page always opens in answer to an action,
149
+ one-time promotion or a membership upsell shown only to non-members: name its close control as
150
+ `dismiss` of `waitForReady` (core skill), which closes it whenever it opens, rather than checking
151
+ for it at one point. Never wait for it or require it. One the page always opens in answer to an action,
152
152
  such as a confirmation dialog a button always opens, may be expected, and the script accepts it
153
153
  when it only restates what this run entered or acts on. One that shows something new, such as a
154
154
  fee, a consequence beyond the request, another record or a warning about this input, goes to the
@@ -100,6 +100,8 @@ run no batch before then. Aim for a handful of cases, not dozens:
100
100
  one made-up key in the site's own format, with a serial past any the site lists, and expect
101
101
  `invalid_input`. Without a no-results answer, move on: it needs no
102
102
  `notTested` entry and no question;
103
+ - for a free-text input, one case with a value the example used written another way, such as in
104
+ other case or with other spacing, punctuation or accents;
103
105
  - another case only where a different page structure or a real variant needs one, and each such
104
106
  case sets as many inputs as still return rows: another retailer, store or seller; another
105
107
  category; a record whose page is laid out differently (a single option, grouped options, a
@@ -2356,14 +2356,19 @@ export const runMint = (input) => Effect.scoped(Effect.gen(function* () {
2356
2356
  if (settled.current &&
2357
2357
  settled.assessments.every((assessment) => assessment?.outcome === "not_done"))
2358
2358
  return undefined;
2359
+ const writes = earlier.map((write) => write.executionId).join(", ");
2360
+ // With no outcome reviewer, nothing can clear the write, so the refusal lasts the
2361
+ // attempt, and a copy of the step is the double write this guard prevents.
2362
+ if (dependencies.outcomeReview === undefined)
2363
+ return `This step repeats a write that may already have changed the site (${writes}). No outcome review runs here, so ${submitted.entrypoint} stays refused for the rest of this attempt. Never run a copy of it to send the write again: read back what happened in a new file that changes nothing. A write whose outcome stays unknown is reported as possibly applied. Nothing was executed.`;
2359
2364
  const applied = settled.assessments.some((assessment) => assessment?.outcome === "done");
2360
2365
  // A read-back that reuses the write's file is refused as this same repeat.
2361
2366
  const newFile = earlier.some((write) => write.entrypoint === submitted.entrypoint)
2362
- ? ` Write a read-back as a new file: any step that runs ${submitted.entrypoint} again is refused as this repeat.`
2367
+ ? ` Write the read-back as a new file. A step that runs ${submitted.entrypoint} stays refused as this repeat only until the outcome review finds the earlier write did not happen; then run ${submitted.entrypoint} itself again, not a copy, since a repair publishes only the entrypoint its confirming step ran.`
2363
2368
  : "";
2364
2369
  return ((applied
2365
- ? `This step repeats a write that already changed the site (${earlier.map((write) => write.executionId).join(", ")}), as the outcome review found. Never run it again: continue with the next step, read back the result, or publish. Nothing was executed.`
2366
- : `This step repeats a write that may already have changed the site (${earlier.map((write) => write.executionId).join(", ")}), and no review has shown it did not. A write is never repeated unless its outcome review finds it did not happen. Read back the account or page in a step that changes nothing, so the review can settle it, or publish: a write whose outcome stays unknown is reported as possibly applied. Nothing was executed.`) +
2370
+ ? `This step repeats a write that already changed the site (${writes}), as the outcome review found. Never run it again: continue with the next step, read back the result, or publish. Nothing was executed.`
2371
+ : `This step repeats a write that may already have changed the site (${writes}), and no review has shown it did not. A write is never repeated unless its outcome review finds it did not happen. Read back the account or page in a step that changes nothing, so the review can settle it, or publish: a write whose outcome stays unknown is reported as possibly applied. Nothing was executed.`) +
2367
2372
  newFile);
2368
2373
  });
2369
2374
  const reviewedExecution = (submitted, onDispatch = () => Effect.void) => dependencies
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pomerado",
3
- "version": "0.4.0-canary.310",
3
+ "version": "0.4.0-canary.312",
4
4
  "description": "Pomerado's integration minter and Guardian with local compute and native Playwright",
5
5
  "type": "module",
6
6
  "license": "MIT",