Registry / devops / annexremote

annexremote

JSON →
library1.6.6pypypi✓ verified 80d ago

A Python library to implement git-annex external special remotes. It provides a base class that handles the protocol between git-annex and the remote, making it easy to develop custom remotes. Current version: 1.6.6. Release cadence: irregular, latest release August 2024.

pip install annexremote
INSTALL
IMPORT
SIG · ANNEXREMOTE
A
annexremote
devopspythonv1.6.6
Install
1.6s avg
Import
Disk
16MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v1.6.6 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.95 runs
installs and imports cleanly · install 0.0s · import 0.000s · 17.9MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 1.6s · import 0.000s · 18MB
16MB installed
● package 16MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

SpecialRemote
from annexremote import SpecialRemote
from annexremote import AnnexRemote
Master
from annexremote import Master
ExportRemote
from annexremote import ExportRemote

Minimal custom remote that listens for git-annex commands.

import os from annexremote import AnnexRemote class MyRemote(AnnexRemote): def initremote(self, kwargs): pass def prepare(self, kwargs): pass def transfer_store(self, key, path, progress_callback=None): pass def transfer_retrieve(self, key, path, progress_callback=None): pass def checkpresent(self, key): return False def remove(self, key): pass remote = MyRemote() remote.listen()
Debug
Known issues
breakingPython 2 support dropped in v1.6.0. If you are using Python 2, pin to annexremote<1.6.0.
fix
Upgrade to Python 3 or pin annexremote<1.6.0
affects: >=1.6.0
gotchaInitializing the remote with `remote = MyRemote()` does not automatically set up the protocol; you must call `remote.listen()` after instantiation.
fix
Always call `.listen()` on the remote object to start communicating with git-annex.
affects: all
gotchaIn `transfer_store` and `transfer_retrieve`, the `progress_callback` should be called with the number of bytes transferred, not the total size. Common mistake: calling `progress_callback(total)` instead of incremental bytes.
fix
Use `progress_callback(bytes_transferred)` where bytes_transferred is the cumulative bytes processed so far.
affects: all
Upgrade
Version history
1.6.6latest on PyPI · released Sep 16, 2024
Audit
Dependencies

No dependency data recorded yet.

Agent activity
30 hits · last 30 days
node
26
OpenAI (training)
1
Resources
annexremote — pip install annexremote · libregistry