Repository navigation
plane black box: one runner boots the real binary against every linked door's case files - #1024
Merged
Merged
Conversation
…d door's case files A plane door crate states its black-box cases beside its root cells under the same `links` name (`cargo::metadata=blackbox=<dir>`); the root's build.rs resolves them identically for a path dependency and a pinned one (DOOR_BLACKBOX) and states BUSBAR_LINKED_AXES as data. tests/plane_blackbox.rs reads every case (schema blackbox/1: requires, files, vars, unset, credentials, a scripted JSON-RPC far end, steps validate | boot | session | call | admin | mint | upstream_set | upstream_counts), boots CARGO_BIN_EXE_busbar and holds every answer to the case. The Rust knows JSON, HTTP/1.1 and JSON-RPC 2.0 framing only; it names no plane, dialect or instance. The rigs the line-served and integrity suites carried move to tests/common (credentials, lines, upstream) and both suites use them. REDs: a malformed case is refused naming the plane crate and the case file; a mismatch fails naming the plane crate, the case and the step; a black-box directory with no case fails; the far end answers what the case states and counts it. The a2a door states its directory with one seed case. Ledger: busbar auth 49 -> 47, plane 772 -> 771, transport 200 -> 195.
A case's oracle cell is read from the 1.5.5 golden and its last status-stating step is held to it: the stated status to the cell's status, every stated body or line to the cell's recorded body and stderr (line_eq a whole line, contains in it, lacks not in it, admin json_eq the recorded value). A citation stating no byte is refused. Any difference fails naming the plane crate, the case and the cell. RED: a_cited_cell_whose_bytes_differ_fails_naming_the_plane_the_case_and_the_cell (a wrong line, a wrong status, no byte stated; the cell's own bytes hold as the control). The a2a seed case cites cli|--version.
…axis is absent, every reply answers its own request - boot: `exit` is accepted (a boot that states it expects to exit); `exit` beside `expect: listening` is refused. - unless: [<axis>] (top level): a build linking any of them does not apply to the case. Axes are named as the manifest's linked-axes rows name them (body-ingress), for requires.axes too, matched against BUSBAR_LINKED_AXES' cfgs. - reply ids: a call's JSON-RPC replies (the body, or each event-stream data line) and every repeat round's reply carry the request's id; on always, no opt-out. REDs: a_boot_step_is_held_to_the_exit_it_states, unless_runs_a_case_only_where_the_axis_is_absent, a_reply_under_a_foreign_id_fails_the_call.
Law 7 (core loads a plugin iff its configuration section is present), for the agent plane, as two black-box cases in its own crate: a 1.5.5 config leaves every agent admin path answering as an unmounted path, the overlay list without the agent section and the agent door to the catch-all; the same config with an `agents:` section serves the admin paths, lists the section and answers the door as a plane door (401, RFC 6750). These are the agent rows of the root's law7 fixtures (law7_plane_sections.yaml, law7_plane_doors.txt), which go once every linked door states its own cases.
…redential's row (they boot its identity provider), as the tool plane's do
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #1006 (draft until it lands, rule 19).
What
DEP_<LINKS>_BLACKBOXfor every enabled plane door, using the samelinksname as the cells, so a path dependency and a pinned dependency resolve the same way.DOOR_BLACKBOX: &[(crate, dir)]intodoor_cells_files.rs.BUSBAR_LINKED_AXESas data.CARGO_BIN_EXE_busbar, drives it, and holds every answer to the case.tests/common/{credentials,lines,upstream}.rshold whatmcp_stdio_serve.rsandqa_mcp_integrity.rscarried privately; both suites now use them.blackbox=<crate>/tests/blackboxwith one seed case, so the resolution path runs in CI.Schema blackbox/1 (case file, JSON)
Top-level fields:
schema(required),case(required),oracle?(a 1.5.5 golden cell id). The cited cell is COMPARED: its recorded bytes are read fromgolden/1.5.5/cells/<id with | as __>.json, and the case's last status-stating step is held to them. The status must equal the cell'sstatus. Every stated body or line must match the cell'sbody.text/body.jsonandeffects.stderr: a_line_eqis a whole line of the record, a_containsis in it, a_lacksis not, and an adminjson_eqholds the recorded value. A citation that states no byte is refused. Any difference fails naming the plane, the case and the cellrequires?{sections,axes,features}: a build lacking any of these makes the case N/A. Axes are named as the manifest'slinked-axesrows name them, e.g.body-ingress.unless?[axis]: a build linking any of these axes makes the case N/A, so the case runs only where the axis is absent.files?{name: text},vars?{NAME: value},unset?[NAME]credentials?{auth_plugin?{module,alias,first_party?}, issuer?, signing_key?}upstream?{methods:{m: {result}|{echo:{from,into,base?,format?}}}}steps[]Steps:
validate{args?,exit?,stdout_contains?,stderr_contains?,output_contains?,output_lacks?,stdout_line_eq?,stderr_line_eq?}boot{args?,expect: listening|exit,exit? (implies expect: exit; refused beside expect: listening),listening?[data|admin],within_secs?,exit?,output_contains?,output_lacks?}session{flag,credential_var?,credential?,expect: served|refused,script?[send|recv{method?,pointer_eq?,has?,contains?}|repeat{max,send,elicitation?{method,message_pointer?,message?,answer},served_has?,served_contains?,refused_contains?,min_served?,elicitations_equal_served?}|eof{exit?,within_secs?}],no_frames?,output_contains?,output_lacks?}call{port?,method?,path,headers?,bearer?,body?,status?,body_contains?,body_lacks?}. Every JSON-RPC reply, whether the body or an event-streamdata:line, must carry its request'sid; this is always on, with no opt-out. The same check runs on everyrepeatround.admin{method?,path,body?,status?,json_eq?}mint{path?,body?,bind_audience?}upstream_set{method,result|echo}upstream_counts{since: last|start,counts:{m: "+N"|"=N"|">0"}}Placeholders:
{dir},{plugins_dir},{data_port},{admin_port},{admin_token},{upstream_url}{token:<aud>},{issuer_settings:<indent>:<aud>}{signing_key_file},{signing_key_hex},{minted}{i}, insiderepeat.sendonlyAn unknown field, step or placeholder is refused.
REDs
a_malformed_case_is_refused_naming_the_plane_and_the_case: unknown field, unknown step, missing name, wrong schema, unknown step field.a_mismatch_fails_naming_the_plane_and_the_case:--versionexpected nonzero fails atstep 0 (validate); the exit-0 control runs clean.a_door_stating_a_black_box_directory_with_no_cases_fails.the_scripted_far_end_answers_what_the_case_states_and_counts_it.a_boot_step_is_held_to_the_exit_it_states.unless_runs_a_case_only_where_the_axis_is_absent.a_reply_under_a_foreign_id_fails_the_call.a_cited_cell_whose_bytes_differ_fails_naming_the_plane_the_case_and_the_cell: a wrong line, a wrong status, and no byte stated all fail; the cell's own bytes hold (the control). The a2a seed case citescli|--version.Ledger
busbarauth 49 -> 47, plane 772 -> 771, transport 200 -> 195. The moved rigs no longer name instances; the new files measure 0.