← Commit history

Contributing guide: checkout, change, test on your own box, send a pull request, review and approval

John Lauer ·fe510163ce ·2d ago ·parent a721e84
4 files changed +66−13
CONTRIBUTING.md+49−4
@@ -3,8 +3,8 @@ The Fusion bridge is open, and contributing back is part of the product. Its wiki page is the repository: every release pushes the whole source tree (the Rust exe, the Fusion add-in, the verb contract, the skills, the tests) to [adom/fusion-bridge](https://wiki.adom.inc/adom/fusion-bridge),-and pull requests are reviewed there. A GitHub mirror under adom-inc is linked from the page. The-wiki repo is canonical.+and pull requests are reviewed there. The wiki repo is the one canonical, public copy, MIT-licensed;+you do not need GitHub for anything below.  If your AI just worked around the bridge instead of using it, that workaround is a contribution waiting to happen: file it, or fix it and send the change back. Both take minutes with the@@ -13,6 +13,20 @@ in the package (`skills/fusion-contributing/SKILL.md`). Every failing reply from `_contribute` field with the same pointer, and `fusion_describe` carries a `contribute` block, so nobody has to find this file first. +## Before you start++You need three things. All are free.++1. **An Adom Wiki account.** Sign in at [wiki.adom.inc](https://wiki.adom.inc); issues, branches and+   pull requests are tied to it.+2. **The `adom-wiki` CLI.** Install it with+   `bash <(curl -fsSL https://wiki.adom.inc/static/bootstrap.sh)`, or download a binary from the+   Releases tab of [adom/adom-wiki-cli](https://wiki.adom.inc/adom/adom-wiki-cli). Check it with+   `adom-wiki whoami`.+3. **A Windows box with Fusion and Adom Bridge**, only if you want to run your change against real+   Fusion before sending it. Adom Bridge ships with [Hydrogen](https://wiki.adom.inc/adom/hydrogen),+   which is free. Reading the code, filing issues and sending small fixes need none of this.+ ## Two-way street  - **You can extend this bridge** (a dialog rule, a hint, a verb, a skill, support for a new Fusion@@ -58,8 +72,11 @@ Where things live:  - **A dialog the bridge could not answer** (the reply was `blocked_by_dialog` with the box's text   and buttons): add a rule to `rust/core/src/dialog_rules.json` (`needles` from the text, a-  `category`, a `resolution` that names the safe button) and the parity entry in-  `handlers/dialog_classify.py`. Add a case to the tests in `rust/core/src/dialogs.rs`.+  `category`, a `resolution` that names the safe button) and a case to the tests in+  `rust/core/src/dialogs.rs`. The JSON is the only rule table the exe reads; the Python+  `handlers/dialog_classify.py` belongs to the retired Python bridge and no longer needs a matching+  entry. Never make the bridge close a window that is not plainly a dialog: Fusion's own panels+  (a floating Browser is titled "Fusion360") close documents when closed. - **A wrong or missing hint**: hints are plain strings next to the reply that carries them (`_hint`   in the Rust or the Python handler). Say what to do next, not what went wrong twice. - **A new verb**: a handler in `addin/AdomBridge/commands/`, its name in `commands/__init__.py`@@ -93,6 +110,21 @@ adom-bridge --target <box> --ai-thread <you> bridge_dev_mode '{"name":"fusion360 An add-in change (`addin/`) also needs the add-in folder copied into the cache and a Fusion restart (`fusion_restart_for_addin {save:true}`), because Fusion loads add-ins at launch. +**Your local build is unsigned.** Released builds are code-signed as Adom Industries, Inc. by the+maintainers. On Windows 11 with Smart App Control on, an unsigned exe can be blocked ("Part of this+app has been blocked"). Test on a machine where Smart App Control is off, or say so on your pull+request and a maintainer will run a signed build for you.++**Run the verb suite against your box** before you send a change that touches behavior. It drives+every daily-tier verb the way an AI does and prints a scorecard:++```bash+python3 tests/run_verb_tests.py --target <box> --tier daily            # the whole daily tier, about 10 minutes+python3 tests/run_verb_tests.py --target <box> --only fusion_show_schematic,fusion_export_eagle_source+```++A new verb needs its own `t(...)` line in that file, or the coverage check turns the run red.+ ## 5. Send the pull request  ```bash@@ -107,6 +139,19 @@ In `pr.md`: the issue it answers, what changed, and how you verified it (box, Fu verb call and its reply before and after). Add a CHANGELOG entry at the top of `CHANGELOG.md` under the next version. House style: plain sentences, no em-dashes. +## Review, revisions and approval++- **Who reviews.** The maintainer thread for this bridge. It reads the change, runs it, and answers+  on the pull request, usually within a day.+- **Asked for changes?** Push more commits to the same branch with+  `adom-wiki repo push adom/fusion-bridge --branch fix/<short-name> ...`. The pull request updates;+  there is no need to open a new one. Reply on it with what you changed.+- **What gets a fast yes.** One concern per pull request, the evidence (the call and its reply+  before and after), a test when the change is testable, and a CHANGELOG entry.+- **What gets a no.** A change that makes the bridge foreground Fusion, type a password, discard+  someone's unsaved work, or hide a failure. We will explain why, and you keep your fork.+- **Credit.** Your commits are kept as authored, and the CHANGELOG entry names the change.+ ## How shipping works  The maintainer thread reviews the pull request and merges it into master (a true merge, history
README.md+3−3
@@ -42,7 +42,7 @@ Short version below, full detail in each guide. | [Sign-in, sessions and updates](docs/sign-in-and-updates.md) | Multi-profile Autodesk sign-in, SSO without passwords, one login covering APS, the `needs_signin` short-circuit, `restartPolicy`, and silent auto-updates. | | [Autodesk's Fusion MCP server](docs/fusion-mcp-server.md) | Proxy Autodesk + Anthropic's local MCP server (text-to-CAD, Electronics object model) so a cloud AI can reach it, and turn it on for the user. | | [Driving Fusion's preferences](docs/fusion-preferences.md) | Reach ANY Fusion preference, not just the thin API slice, by driving the Preferences dialog. |-| [Contributing](CONTRIBUTING.md) | The wiki page is the repo: file an issue with evidence, clone, build the exe, try it behind a dev pin, and send a pull request with `adom-wiki`. |+| [Contributing](CONTRIBUTING.md) | Check out the source, change it, test it on your own box, and send a pull request for review. Account and CLI setup, the dialog rules, unsigned local builds, the verb suite, and how review and approval work. |   ## New since 1.10@@ -352,7 +352,7 @@ promptly with `statusVerb: fusion_get_app_state` - the AI polls instead of block fab checks. The rule packs live on the wiki page [adom/pcb-design-rules](https://wiki.adom.inc/adom/pcb-design-rules) (JLCPCB, PCBWay, OSH Park, Seeed, Eurocircuits, Aisler, Elecrow, Advanced Circuits, Sierra, MacroFab, NextPCB, ALLPCB and-the 3rd party fab), one `.edru` per vendor, process and layer count.+Adom InstaPCB), one `.edru` per vendor, process and layer count.  ```bash adom-bridge fusion_set_design_rules '{"action":"list"}'                 # every fab, process, layers row (no Fusion needed)@@ -360,7 +360,7 @@ adom-bridge fusion_set_design_rules '{"fab":"jlcpcb","layers":"2"}'     # fetch, adom-bridge fusion_set_design_rules '{"druPath":"C:/tmp/house.edru"}'   # a local rule file as-is ``` -With no `fab` the bundled 3rd party fab rules load, and `layers` auto-detects from the open board.+With no `fab` the bundled Adom InstaPCB rules load, and `layers` auto-detects from the open board. The reply carries `ruleWarnings` when the profile has a same-signal Copper Clearance rule over an all/all or trace scope, which native DRC reports as Overlap warnings at every pad entry and trace joint. Confirm the load with `fusion_alerts`: a refused file is an in-canvas toast, never a dialog.
rust/core/src/dialogs.rs+3−3
@@ -1,6 +1,6 @@-//! Fusion's blocking dialogs, classified by title (or body text) exactly as-//! `handlers/dialog_classify.py` does. The rule table is `dialog_rules.json`, generated from the-//! Python source by the golden script so the two shells cannot drift; the goldens in+//! Fusion's blocking dialogs, classified by title (or body text). The rule table is+//! `dialog_rules.json`, the only one the exe reads: it was first generated from the retired Python+//! bridge's `handlers/dialog_classify.py` and is edited directly now. The goldens in //! `tests/golden/dialog_titles.json` pin the result for a spread of real titles.  use serde_json::Value;
skills/fusion-contributing/SKILL.md+11−3
@@ -9,7 +9,7 @@ description: "How to contribute to the Fusion bridge when you hit a bug, a missi The Fusion bridge is open. Its wiki page is the repository: every release pushes the whole source tree (the Rust exe, the Fusion add-in, the verb contract, the skills, the tests) to [adom/fusion-bridge](https://wiki.adom.inc/adom/fusion-bridge), and pull requests are reviewed-there. A GitHub mirror under adom-inc is linked from the page; the wiki repo is canonical. If your AI just worked+there. The wiki repo is the one canonical, public copy (MIT); no GitHub account is needed. If your AI just worked around the bridge instead of using it, that workaround is a contribution waiting to happen: file it, or fix it and send the change back. Both take minutes with the `adom-wiki` CLI you already have.@@ -51,8 +51,8 @@ Where things live:  - **A dialog the bridge could not answer** (the reply was `blocked_by_dialog` with the box's   text and buttons): add a rule to `rust/core/src/dialog_rules.json` (`needles` from the text,-  a `category`, a `resolution` that names the safe button) and the parity entry in-  `handlers/dialog_classify.py`; add a case to the tests in `rust/core/src/dialogs.rs`.+  a `category`, a `resolution` that names the safe button), and a case to the tests in `rust/core/src/dialogs.rs`. That JSON is the only rule table the exe reads; the retired Python+  bridge's `handlers/dialog_classify.py` needs no matching entry. - **A wrong or missing hint**: hints are plain strings next to the reply that carries them   (`_hint` in the Rust or the Python handler). Say what to do next, not what went wrong twice. - **A new verb**: a handler in `addin/AdomBridge/commands/`, its name in@@ -102,3 +102,11 @@ the verb call and its reply before and after). Add a CHANGELOG entry at the top maintainer thread reviews, merges into master (a true merge, history kept) and ships it in the next insiders release, then public after the pre-production gate; you will see the version on the issue. A PR that comes with its evidence merges fast.++## Two things that trip up a first contribution++- **Local builds are unsigned.** Releases are code-signed by the maintainers; on Windows 11 with Smart App+  Control on, your own build can be blocked. Test where it is off, or ask on the pull request for a signed+  test build.+- **Never make the bridge close a window that is not plainly a dialog.** Fusion's floating Browser panel is+  titled "Fusion360", and closing it closes documents. CONTRIBUTING.md has the review and approval steps.