Skip to content

Ask the scope before provisioning when an agent enters there - #37

Merged
franco-zalamena-iterable merged 1 commit into
mainfrom
fix/scope-before-provision
Oct 25, 2026
Merged

franco-zalamena-iterable merged 1 commit into
mainfrom
fix/scope-before-provision

Conversation

@franco-zalamena-iterable

Copy link
Copy Markdown
Contributor

Summary

#35 gates Step 0 in bin/agent preflight, but only an agent that enters through the platform skill reaches preflight. An agent that opens iterable-provision because Firebase or the API keys are missing follows that skill's own first command, bin/agent question opening, and starts provisioning without the scope. #35 noted this as out of scope ("Entering provisioning directly ... isn't gated"). In a live run the agent went straight to the Firebase setup without asking the features or the identity.

This keeps #35 and closes that entry point, so the order is always scope, then provisioning, then code:

  • agent question opening and choose_driver print the scope screen until Step 0 is recorded. With the scope recorded, the same command is the setup question, unchanged.
  • A status read (bin/agent) reports next.kind: scope, with the scope screen as next.question, ahead of every Google and Iterable step (choose_driver, run_in_terminal, authenticate, choose_target, project_unreachable, approve_firebase, register_app, provision, iterable_keys). Device and proof steps are not gated, because the code exists by then.
  • Code still waits for provisioning. Preflight already routes provision ahead of integrate; that is unchanged.
  • Docs: iterable-provision/SKILL.md says Step 0 comes first and adds a scope row to the state table. INTENDED-FLOW.md W1 names the provisioning entry.

Version 26.10.9-beta.

How it was tested

  • tests/agent-scope.sh gains five checks: with no scope, question opening and question choose_driver are the features screen and nothing is written; a status read reports scope with the features screen; with the scope recorded, both return to the setup screens.
  • agent-questions, agent-transitions and text-surface test the setup screens themselves, so they now record a scope in their environment first (the step 4 wording check runs with no identity, as before).
  • Passing: agent-scope, agent-questions, agent-transitions, text-surface, agent-preflight, agent-next-action, no-bare-commands, android-userid-proof, plugin-manifests. The full tests/run-all.sh was not run.

The provisioning skill's first command, agent question opening, now prints the
scope screen until Step 0 is recorded, and a status read reports next.kind
scope ahead of every Google and Iterable step. Code still waits for
provisioning, as preflight already routes it. Plugin 26.10.9-beta.

Co-authored-by: Cursor <cursoragent@cursor.com>
@franco-zalamena-iterable
franco-zalamena-iterable merged commit 82b4011 into main Oct 25, 2026
2 checks passed
@franco-zalamena-iterable
franco-zalamena-iterable deleted the fix/scope-before-provision branch October 25, 2026 19:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant