GWAY
GWAY is a lightweight project manager and command dispatcher for the Arthexis/GWAY ecosystem.
The 1.x generation discovers and manages projects from GitHub and exposes each project's commands through a common gway <project> <command> interface. Framework-specific command discovery is provided by adapters, including Python function introspection and Django management commands.
Install the released package with:
python -m pip install gway
GWAY also keeps a first-class Python API. The intended stable import is:
from gway import gway as gw
# Mirrors the CLI namespace once the relevant managed projects are installed.
gw.wireguard.status()
gw.arthexis.check()
from gway import gw remains available as a compatibility alias. The Python facade uses the same registry, adapter, dispatcher, and runner as the CLI rather than bypassing managed project isolation.
Sigils on the CLI
gway-sigils is GWAY's single runtime dependency and provides the sigils Python package used as part of the command-value language. Project names and command paths stay literal for predictable routing; argument values are interpolated before adapter parsing.
Because Sigils is a required GWAY runtime component, installing GWAY already installs it into the same Python environment. The short GWAY-facing name remains sigils, so this is an idempotent runtime install/verification command rather than a second managed-project checkout:
gway install sigils
# installed sigils gway-sigils@0.4.4
The PyPI distribution name gway-sigils is therefore an implementation/distribution detail; users do not need to type the gway- prefix through GWAY. The command refers to the environment that owns the gway executable: a global GWAY installation gives Sigils the same global scope, while virtualenv or pipx installations remain scoped to that environment.
gway web build --output "[project.path]/dist"
gway ocpp connect --label "%[cwd]-[project.name]"
%[...] expressions are captured eagerly before project-provided lazy context is requested. [...] expressions resolve immediately before the selected adapter parses the command arguments.
The built-in GWAY context includes:
[cwd]and[home][gway.config_dir]and[gway.data_dir][project.name],[project.path],[project.adapter],[project.aliases],[project.repository],[project.revision], and[project.environment][command.name]and[command.path]
Adapters may add lazy-only top-level roots through the optional SigilContextAdapter capability. Added roots cannot replace GWAY's reserved cwd, home, gway, project, or command namespaces.
Django projects can configure an explicit provider in gway.toml:
[adapter]
type = "django"
manage = "manage.py"
settings = "config.settings"
sigils = "apps.sigils.gway:context"
The provider is imported after django.setup() and is called as:
def context(*, project, command_path):
return {"NODE": ...}
It must return a mapping. For model-backed data, prefer sigils.SafeNamespace so only explicitly exposed keys may be traversed and resolution cannot fall through to arbitrary attributes, callables, or Sigils tools.
All regular Sigils built-ins remain available outside protected namespaces, including the environment tool and eager/lazy recursive semantics supplied by the sigils library itself.
The pre-1.0 implementation has been preserved in arthexis/gway-legacy. Legacy bundled projects, recipes, shared mutable context, and application-specific dependencies are intentionally not part of this codebase.
See PLAN.md for the architecture and implementation sequence. gway-epaper is now explicitly scheduled immediately after the Django/Arthexis end-to-end milestone; see PLAN-EPAPER.md for that roadmap extension.
For a reproducible bridge validation before enabling a real ORM-backed provider, see MANUAL-SIGIL-CONTEXT.md.
System / appliance installation
GWAY 1.x can be installed or upgraded as a system command without changing the operating system's default python3:
curl -fsSL https://raw.githubusercontent.com/arthexis/gway/main/install.sh | sudo bash
The bootstrap installer:
- selects an available Python 3.11 or newer interpreter;
- installs GWAY into
/opt/gway/venv; - creates system state under
/etc/gwayand/var/lib/gway; - installs
/usr/local/bin/gwayas the system dispatcher; - automatically archives an existing unmanaged
/usr/local/bin/gwayas/usr/local/bin/gway-legacybefore replacement; - preserves additional differing legacy commands with collision-safe timestamped archive names;
- can be rerun safely to upgrade an existing managed GWAY installation.
Validate prerequisites without changing the machine:
curl -fsSL https://raw.githubusercontent.com/arthexis/gway/main/install.sh -o /tmp/gway-install.sh
bash /tmp/gway-install.sh --check
After installation, managed projects can be installed directly, for example:
sudo gway install wireguard
sudo gway wireguard --help
Upgrading GWAY and managed projects
GWAY owns the lifecycle of projects installed through gway install. Upgrade one managed project with:
sudo gway upgrade wireguard
Upgrade all managed projects while leaving GWAY itself unchanged:
sudo gway upgrade --all
Upgrade only GWAY in the Python environment that owns the current gway executable:
sudo gway upgrade --self
A bare upgrade performs both operations in order: GWAY itself first, then every managed project:
sudo gway upgrade
Managed project upgrades normally require a clean checkout whose origin still matches the trusted repository recorded by GWAY. Normal upgrades use git pull --ff-only, refresh the project's isolated Python environment, re-read gway.toml, and record the new revision. Locally registered projects created with gway register are not modified by --all; naming one explicitly is rejected.
For appliance recovery, --force deliberately discards local managed-checkout changes after validating the registered origin and current branch. It fetches the trusted upstream, resets the checkout to origin/<branch>, and removes ordinary untracked files/directories; ignored files are preserved. It can target one project or all managed projects:
sudo gway upgrade wireguard --force
sudo gway upgrade --all --force
sudo gway upgrade --force
The last form upgrades GWAY itself normally, then force-resets and upgrades all managed projects.
Development
python -m pip install -e '.[dev]'
python -m gway --help
gway --help
pytest
The package and executable remain named gway; the stable 1.x line starts at version 1.0.0.
Metadata
Release files for gway 1.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| gway-1.0.1.tar.gz | 35.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| gway-1.0.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 65.0 kB
Release files / gway-1.0.1.tar.gz
| Download URL | gway-1.0.1.tar.gz |
|---|---|
| Size | 35.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
cd3edcf47f482f6ca06e415748a98020b1afe584742fec453a05e2f493bb78c6
|
|
BLAKE2b-256 checksum How to use checksums |
eb14b42acbe11bb4d3c9b7a56133f6b1e3ace109a191c6427ff3e6ff78acd55c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 8, 2026.
Transparency logRelease files / gway-1.0.1-py3-none-any.whl
| Download URL | gway-1.0.1-py3-none-any.whl |
|---|---|
| Size | 29.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
86e16c8595db3af06c2cdf5816ebe3a3c2b8f323bf1ffae1d61c76ca605597e5
|
|
BLAKE2b-256 checksum How to use checksums |
eefad3f2bc39382381d6e6446b4c98493c3863635d95198fba1899ed0d8c50ef
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 8, 2026.
Transparency log