Skip to content

One export pipeline: rvt-ifc, Python, wasm and the MCP server run the same function #1331

Closed

Description

@DrunkOnJava

rvt-ifc (src/bin/rvt_ifc.rs), the Python bindings (rvt-py/src/lib.rs), the WebAssembly bindings (rvt-wasm/src/lib.rs) and the MCP server (#1324, rvt-mcp/src/pipeline.rs) each repeat the export's steps in their own code:

  • the document exporter;
  • the saved-mesh bodies and their default scope;
  • the optional Revit property sets and set placement;
  • leaving out base quantities;
  • recounting after each post-pass;
  • recording unread streams.

Each new option has to be added in four places, and a surface that misses one exports a different file from the same input. --phase (#1328) is the next such option.

Change

One library function that runs the whole export from options, with limits and WalkerControl, returning the model, its diagnostics and the notes the CLI prints. rvt-ifc, rvt-py, rvt-wasm and rvt-rs-mcp call it. Defaults follow rvt-ifc with no switches.

Done when

  • Every caller uses the function, and no copy of the steps remains.
  • Measure, unfiltered with base=main, shows every ifc.sha256 unchanged.
  • The MCP E2E shows the server's export still equals rvt-ifc's byte for byte.
  • The Python and viewer tests pass unchanged.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:ifcpriority:P1type:feature

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions