@openengio/cli 0.44.0 → 0.48.0

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openengio/cli",
3
- "version": "0.44.0",
3
+ "version": "0.48.0",
4
4
  "license": "Apache-2.0",
5
5
  "type": "module",
6
6
  "engines": {
@@ -21,6 +21,18 @@ their own. Before you send a generated command (`objects-sdk`, `branches-sdk` an
21
21
  `<module> <method>` commands), run `openeng help <module> <method>`. It prints the fields, the kinds a
22
22
  field may take, the selector keys and one example input, and needs no sign-in.
23
23
 
24
+ ## File feedback
25
+
26
+ File feedback when a route fails in a way its docs do not explain, a refusal is unclear, help or docs are missing or wrong, a request shape is unknown, or a feature is missing. Include the route name, correlation id, an outline of what was sent, what came back, what you expected, and the project when applicable. Never include secrets, tokens or credentials. The title is 1 to 200 characters after trimming and the body 1 to 8,000. A filing is not idempotent, so a retry files a second entry. A filer may file 100 entries in any 24 hours in one organisation; the next is refused `bound-exceeded` naming `feedback-per-filer`. An agent-mode filing waits for the person to confirm it in the browser.
27
+
28
+ Use `openeng feedback bug --title <text> --body-file -` or `openeng feedback feature`; `openeng admin-sdk listFeedback` lists entries.
29
+
30
+ `listFeedback` returns one page of up to 20 entries by default (a `limit` from 1 to 50 is available) and a continuation token. Pass the token to the next request and repeat until it is null.
31
+
32
+ ```sh
33
+ openeng admin-sdk listFeedback --input '{"continuation":"<token from the previous answer>"}'
34
+ ```
35
+
24
36
  ## Read a route's policy
25
37
 
26
38
  Generated route help prints `actors` (the caller categories allowed) and `step-up` (whether user confirmation is required) from the route table's current `policy` (access rules).
@@ -79,7 +91,7 @@ not admitted. `upload-not-found` means completion found no upload for this calle
79
91
  start the upload again. These refusals are printed through the ordinary CLI refusal output.
80
92
 
81
93
  For a top-level object property declared with kind `attachment`, use
82
- `openeng attachment add <object> <property> <file> --project <id> --ref <ref>` to upload a file and
94
+ `openeng attachment add <object> <property> <file> --project <id> --ref <ref> --reason <text>` to upload a file and
83
95
  save its descriptor, `openeng attachment list <object> --project <id> --ref <ref>` to read its
84
96
  attachment properties, and `openeng attachment get <object> <property> [--out <path>]` with the
85
97
  project and ref flags to download it. The `get` command uses the descriptor's file name when `--out`
@@ -95,7 +107,7 @@ read) and `too-many-links` (the chain exceeds its bound). Bounds have their own
95
107
  Aggregates also show coverage and hidden or missing counts. Numeric output shows its unit.
96
108
 
97
109
  After reviewing the upstream, run `openeng links clear <link> --version <upstreamVersion>
98
- --project <id> --ref <ref>`. Take the opaque version from the status answer. For an atomic batch,
110
+ --project <id> --ref <ref> --reason <text>`. Take the opaque version from the status answer. For an atomic batch,
99
111
  list up to 100 link ids and repeat `--version` once per link in the same order. On
100
112
  `upstream-changed`, read status and review before sending its new version; do not replace the
101
113
  precondition blindly. `upstream-not-readable` requires upstream read access. There is no
@@ -287,7 +299,7 @@ project's `main`. Use a branch and review when a rule protects the branch or the
287
299
  selector keys and an example each.
288
300
  2. When a branch is needed, `openeng branches-sdk createBranch` makes one in the project. It
289
301
  answers the branch's full name, written `<project id>/<name>`.
290
- 3. `openeng objects-sdk mutate` creates, changes or deletes an object or an edge on that branch. The `ref` field in
302
+ 3. `openeng objects-sdk mutate` creates, changes or deletes an object or an edge on that branch. Every save carries a `reason`; see "The save reason" below. The `ref` field in
291
303
  a selector takes one of three forms: the organisation trunk is the bare `main`; a project
292
304
  branch is its full name, `<project id>/<name>`; an organisation branch or baseline is its bare name.
293
305
  `--ref` takes a branch (`main` or `<projectId>/<branch>`) or a baseline for commands that admit organisation names.
@@ -318,6 +330,20 @@ In `--input` JSON, a branch's optional `from` is `{ "kind": "ref", "ref": "main"
318
330
  A mutation, batch, verb or merge answers a commit with `kind` `committed` and its `hash`, or
319
331
  `kind` `no-change`. Read the generated help before constructing these values.
320
332
 
333
+ ### The save reason
334
+
335
+ Send a `reason` with every save: in the `--input` JSON of `mutate`, `mutateBatch`, `executeVerb`,
336
+ `promoteDraft`, `clearLinks` and `setObjectLock`, and with `--reason <text>` on
337
+ `openeng attachment add`, `openeng links clear` and `openeng locks set`, which refuse a missing
338
+ reason before any call. A merge keeps its required `message`. The host writes the reason first in
339
+ the save's commit message, exactly as sent, so the history says why the change was made.
340
+
341
+ Write a reason that says why, in one or two sentences: the purpose of the change and what it
342
+ serves, not a restatement of the operation. "Raise the brake requirement after the review" says why;
343
+ "update object" does not. A batch's reason describes every change the batch makes, because the
344
+ batch is one commit with one message. The host refuses a reason that is empty after trimming white
345
+ space, or that holds a NUL character or a lone UTF-16 surrogate, as `invalid-request` with the field `input.reason`.
346
+
321
347
  ### Draft and comment routes
322
348
 
323
349
  The Objects SDK transport also exposes `acquireDraft`, `saveDraft`, `promoteDraft`, `releaseDraft`,
@@ -389,7 +415,9 @@ grant access to its title, type or properties. Any cursor that is not a current
389
415
  and no matching rule restricts deletions, or when no rule matches even with a pending proposal.
390
416
  Otherwise the caller must be on every matching rule's bypass list. A bypass member may dispose
391
417
  with or without a proposal, including under restricted deletions, with write access to all affected
392
- projects. Success discards the pending proposal after the engine disposal succeeds.
418
+ projects. A person's bypass counts only from a web session or a CLI session in human mode: an
419
+ agent-mode CLI session, or a session with no recorded channel, takes no bypass for a merge, a
420
+ disposal or a direct edit. Success discards the pending proposal after the engine disposal succeeds.
393
421
 
394
422
  Merge and disposal admit people, services and client apps. Agent runs and hosted apps are refused
395
423
  `token-kind-not-admitted`. With no rule matching the merge target, a writer of all affected projects
@@ -413,6 +441,8 @@ differently, each `{ blockId, base, ours, theirs }` with the text of the common
413
441
  the source branch (null where a side has no such block). Reconcile the changes on the source branch, then submit a new merge
414
442
  with the reviewed head; reading conflicts makes no changes.
415
443
 
444
+ A merge is refused `merge-preview-approximate` when the branch's history criss-crosses its target, in either direction. Nothing is merged. Start a new branch from the target, redo the change there, and merge that branch. A branch that an earlier release left criss-crossed cannot be merged.
445
+
416
446
  A rule has extent `ref` for every row on a matching ref or `rows` for its project's rows.
417
447
  Project `ref` rules are `<project>/` and a glob; `rows` may also name `main`. In a glob `*` stops at
418
448
  `/`, `**` is any characters, `/` included, `?` is one character other than `/`, and `[]` is a set
@@ -443,8 +473,11 @@ no named approvers and Owner/Maintainer bypass. Deletion restriction defaults to
443
473
  `ref` rules only; only those rules may enable it. Positive approvals need a proposal and either
444
474
  a minimum role or a named approver. The server validates named members without revealing identities
445
475
  outside the home. Refusals are `invalid-rule-pattern`, `invalid-rule-setting` and `unknown-rule-member`.
446
- A repeated rule add returns the existing rule without changing it. Changing a rule’s consequence
447
- to one another rule on that pattern already has is refused `duplicate-rule`; the rule stays unchanged.
476
+ An add with the same owner, case-insensitive pattern, extent and consequence returns the existing rule without
477
+ an audit write if its settings are identical; otherwise it is refused with duplicate-rule. A different
478
+ consequence can create a separate rule.
479
+ Changing a rule’s consequence to one another rule on that pattern already has is also refused
480
+ `duplicate-rule`.
448
481
 
449
482
  ## Organisation rules, branches and baselines, locks and agent ceilings
450
483
 
@@ -467,10 +500,13 @@ capability; read the help line before asking the person to seek permission.
467
500
  Creating, deleting and marking need `administer projects` in the attached organisation;
468
501
  listing needs read on a project in the organisation.
469
502
  - The person sets or lifts an object's lock with
470
- `openeng locks set --project <id> --ref <ref> --object <objectId> --lock <none|merge-only|frozen>`.
503
+ `openeng locks set --project <id> --ref <ref> --object <objectId> --lock <none|merge-only|frozen> --reason <text>`.
471
504
  `none` lifts it. The lock also applies to its existing structural child edges in the selected
472
505
  project. New children on a writable branch are not thereby frozen. Use a baseline
473
506
  to preserve a fixed snapshot. This needs `lock objects` on the selected project.
507
+ - The person renames a project with `openeng projects rename --project <id> --name <text>`. It needs
508
+ `administer projects` on the project, and the route is refused to agents, so never rename a project yourself.
509
+ Check the project id in `openeng projects list` before asking.
474
510
  - `openeng ceiling show --project <id>` reads the maximum agent role. The person sets it with
475
511
  `openeng ceiling set --project <id> --ceiling <contributor|maintainer>`.
476
512
  Showing needs `read`; setting needs `administer projects` on the selected project.
@@ -645,23 +681,52 @@ project roles. Re-issuing keeps the roles; revoking removes the invitation from
645
681
  Acceptance skips and audits a project role when the project ended, the person already holds an
646
682
  equal or higher project role, or the inviter lost the required standing. Sign-in continues.
647
683
 
648
- Membership roles are `owner`, `maintainer`, `contributor` and `reader`. They grant, respectively:
684
+ Membership roles are read from the deployment ladder. Its built-in roles are `owner`, `maintainer`,
685
+ `contributor`, `reader` and `none`. They grant, respectively:
649
686
 
650
687
  - `owner`: administer members, projects and service identities; write refs and read.
651
688
  - `maintainer`: write refs and read.
652
689
  - `contributor`: write refs and read, including direct merges where no rule matches the target.
653
690
  Matching rules and bypass entries decide how each ref may change.
654
691
  - `reader`: read.
692
+ - `none` (No role): organisation standing with no capability. Use a project role for project access.
655
693
 
656
694
  A membership can be scoped to an organisation or a project. An organisation role supplies its
657
695
  capabilities in each project of that organisation too; a project role applies to its named project.
658
696
  For a project-specific exception, grant the role on that project rather than assuming a membership
659
- in one project applies to another.
697
+ in one project applies to another. Every project membership requires an organisation membership;
698
+ use `none` when the person needs only specific projects. Invite them with that organisation role
699
+ before granting a project role. A new service identity already holds an organisation row at `none`;
700
+ change that row with `changeMembershipRole` for organisation access, or grant a project role.
701
+ The role options returned by `listMembers` include sorted capabilities; an empty list means no capability.
660
702
 
661
703
  An unknown role on an invitation or membership grant answers `unknown-role` with `roleKeys`, the
662
704
  deployment's role keys. Choose one of those keys. A known role above your own answers
663
705
  `above-caller-role`.
664
706
 
707
+ ### Change or leave membership
708
+
709
+ Use `openeng admin-sdk grantMembership` with `principalId`, `scopeKind`, `scopeId` and `roleKey`.
710
+ `changeMembershipRole` takes those same four fields; `revokeMembership` takes the first three.
711
+ Use `leaveMembership` for the signed-in person's departure, with only the scope:
712
+
713
+ ```sh
714
+ openeng admin-sdk leaveMembership --input \
715
+ '{"scopeKind":"project","scopeId":"<project-id>"}' --json
716
+ ```
717
+
718
+ `scopeKind` is `organisation` or `project`. Granting or changing another person's role and
719
+ revoking another membership require `administer members`. A person may lower their own role or
720
+ leave using their membership alone. Self-grants and own-role raises are refused as
721
+ `membership-own-role` (P3608); equal-rank grants to another person are allowed.
722
+
723
+ A hidden or absent scope answers `not-found` (database OE067), identically in both cases.
724
+ A missing membership at a visible scope answers `no-such-membership` (OE006).
725
+ `last-administrator` (OE004) protects the organisation's last eligible administrator, not a
726
+ separate administrator in every project. Removing an organisation membership also removes that
727
+ person's project memberships in that organisation and ends their work there. Leaving an ended
728
+ project is allowed. These membership writes take no idempotency key and have no recovery route.
729
+
665
730
  ## Recover an interrupted operation
666
731
 
667
732
  `openeng objects-sdk recover` checks the record of a mutation or verb whose result was unknown. Give
@@ -675,6 +740,8 @@ Recovery can report a committed change and its hash, and finish the recovery rec
675
740
  the original mutation again. If the saved evidence still cannot establish an outcome, it returns
676
741
  `unknown`; it cannot undo a successful write, restore a deleted object, or retry a failed operation.
677
742
 
743
+ A client with the `branches.proposalSubmit` grant may submit a proposal under the person's
744
+ project permissions. That grant alone permits no other branch write.
678
745
  ## Builds
679
746
 
680
747
  Save a step and its immutable output declarations with the objects SDK's `saveStep`, then check
@@ -729,6 +796,7 @@ A step run's log is plain text; show it as text and never as markup.
729
796
 
730
797
  An `outputs-already-current` refusal includes current/stale counts and writes nothing. Ask the user
731
798
  which explicit choice to send; the notice grants no permission to choose `run-all` or `run-stale`.
799
+ A start is refused `build-too-large` when the plan would create more than 20 new step runs; the limit is fixed for each request, so split it. A start is refused `build-limit-reached` when the organisation is at its limit.
732
800
  A start returns `kind: started` with identifiers, or `kind: unchanged` with counts and no build ID.
733
801
  `run-all` reruns upstream work too; `run-stale` reuses complete upstream work with source-run/output
734
802
  provenance. Compile can run once while simulation expands sweep points. Engine registration is an