Metadata-Version: 2.5
Name: sqi-submitter
Version: 0.4.0
Summary: DCC submitter framework for sqi (Maya, Houdini, Nuke, 3ds Max, VRED, Blender, Cinema 4D, After Effects, Unreal, Katana, KeyShot, Silhouette, Fusion, Modo) on top of sqi-sdk
Project-URL: Homepage, https://github.com/uberware/sqi
Project-URL: Repository, https://github.com/uberware/sqi
Project-URL: Documentation, https://github.com/uberware/sqi/blob/main/docs/dcc-submitters.md
Project-URL: Issues, https://github.com/uberware/sqi/issues
Author-email: Robin Scher <robin@uberware.net>
Maintainer-email: "Uberware Inc." <robin@uberware.net>
License-Expression: AGPL-3.0-or-later
License-File: LICENSE
Keywords: 3dsmax,aftereffects,blender,cinema4d,fusion,houdini,katana,keyshot,maya,modo,nuke,openjd,render-farm,silhouette,sqi,unreal,vfx,vred
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Typing :: Typed
Requires-Python: >=3.9
Requires-Dist: sqi-sdk>=0.1
Provides-Extra: dev
Requires-Dist: hatchling>=1.27; extra == 'dev'
Requires-Dist: mypy<2; extra == 'dev'
Requires-Dist: pytest; extra == 'dev'
Requires-Dist: pytest-cov; extra == 'dev'
Requires-Dist: pyyaml; extra == 'dev'
Requires-Dist: respx; extra == 'dev'
Requires-Dist: ruff; extra == 'dev'
Requires-Dist: types-pyyaml; extra == 'dev'
Provides-Extra: qt
Requires-Dist: pyside6; extra == 'qt'
Description-Content-Type: text/markdown

# sqi-submitter

DCC submitter framework for [`sqi`](https://github.com/uberware/sqi) — a distributed
task and render farm manager.

`sqi-submitter` is a Python framework for building DCC (Digital Content Creation)
integrations on top of [`sqi-sdk`](../python). It provides one Qt submit dialog,
host adapters for Maya, Houdini, Nuke, 3ds Max, and VRED, and a handoff for
Blender, Cinema 4D, After Effects, Unreal Engine, Katana, KeyShot, Silhouette,
Fusion, and Modo, for submitting OpenJD job templates to an `sqi` farm directly
from within your application.

Every host opens the same dialog. Maya, Houdini, Nuke, 3ds Max, and VRED open it
in their own process. The other nine write a small context file and start
`sqi-submit --context FILE`, which opens it; their host files (Python for all
but After Effects, which is ExtendScript, and Fusion, which is Lua) are
installed with `sqi-submit install-host`.

## Installation

```sh
pip install sqi-submitter              # core (requires sqi-sdk)
pip install "sqi-submitter[qt]"        # + PySide6 for standalone UI
```

For development (run from `clients/submitter/`):

```sh
pip install -e ../python -e '.[dev]'   # local sqi-sdk + submitter with test & lint tools
```

The checks CI runs (split there across three jobs), as one local chain:

```sh
ruff format --check . && ruff check . && mypy && mypy --python-version=3.13 tests && pytest -q
```

Run `mypy` bare, not `mypy src`: `pyproject.toml` lists `src` and the Cinema 4D
plugin (`sqi_submit.pyp`, which `mypy src` skips because it is not a `.py`
file). A bare `mypy` does not read the tests, so `mypy --python-version=3.13
tests` checks them separately; CI runs both.

## Authentication

When the target `sqi-server` has `auth.enabled=true` (see
[`docs/auth.md`](../../docs/auth.md)), a `SubmitterSession` needs an API key
to authenticate headlessly. It resolves one in this order: the `api_key`
argument passed to `SubmitterSession`, then the `$SQI_API_KEY` environment
variable, then the `api_key` value in `~/.sqi/submitter.json`
(`sqi_submitter.core.session.resolve_api_key`). Whatever is found is
forwarded to `SqiClient` as the Bearer token. Issue a key for yourself via
`POST /api/v1/api-keys` or the web Admin → API Keys page — see
[`docs/auth.md`](../../docs/auth.md#api-keys) for how keys work.

## Quick start

Open the standalone dialog (needs the `qt` extra, or a DCC-bundled PySide):

```sh
sqi-submit --server http://localhost:8080
```

Inside a DCC, wire the host's launch glue per
[`docs/dcc-submitters.md`](../../docs/dcc-submitters.md#installation-per-host).
For the handoff hosts, and for VRED's script plugin, install the host files
with:

```sh
sqi-submit install-host blender        # or cinema4d, aftereffects, unreal, katana,
                                       # keyshot, silhouette, fusion, modo, vred
```

Unreal, Katana, and Silhouette run a startup file whose name the host fixes
(`init_unreal.py`, `init.py`, `sfxuser.py`). `install-host` never overwrites one
of your own: it keeps it and prints the lines to append to it instead.

The handoff context file that those hosts write is documented in
[The handoff contract](../../docs/dcc-submitters.md#the-handoff-contract); its
JSON Schema is `src/sqi_submitter/core/context.schema.json`.

## Testing

Use the `fake_host_module` fixture to inject mock DCC modules:

```python
def test_with_maya(fake_host_module):
    maya_cmds = fake_host_module("maya.cmds")
    # maya.cmds resolves to the fake module from sys.modules
```

## Documentation

Full reference and integration guides: [`docs/dcc-submitters.md`](../../docs/dcc-submitters.md).

## License

AGPL-3.0-or-later. See the repository root for the full license text.
