xrdarc
A pure Python 3 client for NorduGrid ARC computing elements. It submits, monitors, retrieves and manages jobs over A-REX's REST interface, with the grid's X.509/VOMS proxies or WLCG bearer tokens. It needs no ARC C++ libraries, no Globus and no compiler.
$ xrdarc proxy -S atlas # arcproxy -S atlas
$ xrdarc sub -C ce.example.org job.xrsl # arcsub
Job submitted with jobid: https://ce.example.org:443/arex/rest/1.0/jobs/7855c3ea9869
$ xrdarc stat -a # arcstat -a
$ xrdarc get -a -D results # arcget
import xrdarc
with xrdarc.ARCClient() as arc:
[sub] = arc.submit("ce.example.org", '&(executable="/bin/hostname")(stdout="out.txt")')
[done] = arc.wait([sub.job], interval=30)
print(done.job.state, done.job.exit_code)
arc.get([done.job], "results")
It is built on the grid libraries shared with the storage clients (xrdclient, xgfalclient), and on no client: xrdsec finds the credentials (ARC's own search order), builds the TLS context, issues proxies and fetches VOMS attributes; xrdcore supplies safe XML parsing, the versioned JSON/XML report format, backoff, cancellation and log redaction. How the pieces fit is in docs/architecture.md.
Install
$ pip install xrdarc
Requires Python 3.11+. Runtime dependencies are xrdcore, xrdsec
(with asn1crypto), xrdhttp (without its s3 extra) and cryptography, all of which install
from wheels on Linux (glibc and musl) and macOS. Windows is not supported
yet (see
docs/platforms.md).
Commands
One program, xrdarc, whose subcommands are ARC's client tools with ARC's
option spellings. They are not installed under ARC's own names, so both can
be on one machine; alias arcstat='xrdarc stat' works for most uses.
| xrdarc | ARC | does |
|---|---|---|
xrdarc proxy [-S vo[:fqan]] [-I] [-r] |
arcproxy |
make an RFC 3820 proxy, with VOMS attributes; inspect or remove one |
xrdarc info -C ce [-l] |
arcinfo |
endpoints, queues (and VO shares), runtime environments |
xrdarc sub -C ce file... [-e text] [-q queue] [-o idfile] [--dry-run] |
arcsub |
delegate, submit, upload local inputs, record the jobs |
xrdarc stat [jobs|-a] [-s state] [-l] |
arcstat |
job states, exit codes, errors, usage |
xrdarc wait [jobs|-a] |
poll until every job has finished | |
xrdarc get [jobs|-a] [-D dir] [-k] [-J] [--diagnose] |
arcget |
download results (and gmlog), then clean |
xrdarc cat [-o|-e|-l|-f path] jobs |
arccat |
stdout, stderr, A-REX's job log, or any file, even while running |
xrdarc ls job [dir] |
list the session directory with sizes | |
xrdarc diagnose job [item...] |
A-REX's per-job control files: failed, errors, diag, local, ... |
|
xrdarc kill, clean, resume, renew |
arckill ... |
the bulk job actions |
xrdarc sync -C ce [-T] |
arcsync |
add the CE's jobs to the job list |
Every subcommand takes --json or --xml and then emits one versioned
report document (the storage-client-report schema shared with xrdclient
and xgfalclient), with one record per job and numeric error codes.
Exit codes come from one fixed table: 0 success, 1 some jobs failed, 2 a
usage error, 3-7 fatal credential, description, CE, local and timeout
errors, 130 interrupted, 141 a closed pipe (see
docs/compatibility.md).
Bearer tokens are best given with --token-file PATH or --token -
(standard input), which keep them out of the process list.
Compatible with ARC's own tools
- The job list is ARC's. Jobs go into
~/.arc/jobs.datin ARC's SQLite format, soarcstatshows jobs submitted here andxrdarc statshows jobs submitted witharcsub. Both directions have been checked against ARC 7. - Configuration is ARC's.
~/.arc/client.conf(and-z) supplies[computing/<alias>]services, default CEs, the proxy and CA paths, the timeout and the download directory. - Credentials are found where ARC finds them.
X509_USER_PROXY, thenproxypath, then/tmp/x509up_u<uid>(and under$TMPDIR), then the user certificate from the environment,client.conf,~/.arcor~/.globus. Tokens are found by WLCG bearer-token discovery. Trust anchors come fromX509_CERT_DIR,cacertificatesdirectory,~/.arc/certificates,~/.globus/certificatesor/etc/grid-security/certificates;X509_CERT_POLICY=anyadds the system store, as in ARC. - Job descriptions are xRSL (
&, and+for several jobs) or ADL. xRSL is parsed client side with ARC's grammar: quoting,(* comments *),rsl_substitution/$(VAR), and user-dialect times in minutes. It is converted to the dialect A-REX expects, and implicit inputs and outputs (the executable, stdin, stdout, stderr, gmlog) are added asarcsubadds them.
Where xrdarc deliberately differs from ARC is listed in docs/compatibility.md.
Status
Tested end to end against ARC 7 A-REX with a SLURM back end:
- proxy creation;
- delegation, checked with
openssl verifyon the worker node; - input upload and output download, checked by checksum;
- failing, killed and resumed jobs;
- renewal,
cat,ls,diagnose,sync; - job list interchange with
arcstat/arcsub.
The hermetic suite runs against an in-process fake A-REX (xrdarc.testing.arex)
and holds the package at 100% line and branch coverage. See
docs/DEVELOPING.md for running the interop suite against
a CE of your own.
Licence
LGPL-3.0-or-later.
Metadata
Release files for xrdarc 0.4.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| xrdarc-0.4.0.tar.gz | 276.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| xrdarc-0.4.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 470.4 kB
Release files / xrdarc-0.4.0.tar.gz
| Download URL | xrdarc-0.4.0.tar.gz |
|---|---|
| Size | 276.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
171ef867b5c875d73590bfa95988347cb72f7306ee9015a2f809aa2b0909ec97
|
|
BLAKE2b-256 checksum How to use checksums |
947665bb4f59d3fffedfa25436199534e7cf3be0ba877dea382ade15a0114867
|
| 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 Oct 19, 2026.
Transparency logRelease files / xrdarc-0.4.0-py3-none-any.whl
| Download URL | xrdarc-0.4.0-py3-none-any.whl |
|---|---|
| Size | 193.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
71fef6fa63944bc750ad80b906cb6927a0874e11b30dfd7114cd55843ec9e643
|
|
BLAKE2b-256 checksum How to use checksums |
79d7c7de6eb48051aa305b44772e5315044130845575f2247318aacdc6e6aed8
|
| 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 Oct 19, 2026.
Transparency log