Add --create-change-set and --post-change-set option to dtc-subcommand auto-curate #34

Merged
cmo merged 39 commits from change-set-2 into master 2026-03-10 01:14:09 +00:00

2026-03-10

Christian Monch
create a virtual environment before running tests
All checks were successful
Test execution / Test-all (push) Successful in 30s
2026-03-10 02:11:47 +01:00
Christian Monch
install the package before running the tests
Some checks failed
Test execution / Test-all (push) Failing after 18s
2026-03-10 02:09:23 +01:00
Christian Monch
set up git identity before running tests
Some checks failed
Test execution / Test-all (push) Failing after 23s
2026-03-10 02:05:57 +01:00
Christian Monch
do not specify python version for tests explicitly
Some checks failed
Test execution / Test-all (push) Failing after 22s
This lets the runner select a version that is locally
available.
2026-03-10 02:01:18 +01:00
Christian Monch
use python version 3.11.2 for tests
Some checks failed
Test execution / Test-all (push) Failing after 13s
2026-03-10 02:00:11 +01:00
Christian Monch
fix test workflow
Some checks failed
Test execution / Test-all (push) Failing after 13s
2026-03-10 01:49:04 +01:00
Christian Monch
update locked package versions
Ensure that linkml 1.10.0 is used.
2026-03-10 01:49:04 +01:00
Christian Monch
ensure that tests work with additional records
This commit makes the tests robust against the
presence of other test artifacts in the test store
2026-03-10 01:49:04 +01:00
Christian Monch
add tests for --create-change-set
This commit adds tests for the create change
set-option of auto-curate.
2026-03-10 01:49:04 +01:00
Christian Monch
fix intra repo path and repo initialization
This commit fixes two errors in auto-curate
that are related to change set-creation. The
first error was that a git repository might not
be initialized. The second error was the faulty
calculation of the intra-repository path of
records.
2026-03-10 01:49:04 +01:00
Christian Monch
remove code duplication in test code
This commit factors out a function that reads
records from a dumpthings-recorddir backend.
2026-03-10 01:49:04 +01:00
Christian Monch
add tests for post-records and get-records
Add tests for post-records that check the
write-interface. Some tests use get-records
to fetch records for validation.

Add the `Document`-class to test schema.
2026-03-10 01:49:04 +01:00
Christian Monch
2026-03-10 01:49:03 +01:00
Christian Monch
add basic tests
This commit adds a basic test using `post-records`
and `get-records`.
2026-03-10 01:49:03 +01:00
Christian Monch
add dump-things-server test fixtures
This commit adds fixtures that generate a test
dump-things-server that contains one collection,
i.e., `collection_1`. The collection uses a
`record-dir`-backend and the schema
`pyclient_testschema.yaml`.
2026-03-10 01:49:03 +01:00
Christian Monch
2026-03-10 01:49:03 +01:00
Christian Monch
clean up auto-curate
This commit unifies the handling of "normal"
curation, change-set-creation and change-set-posting.
inbox inclusion- and exclusion-lists are now
honored in all three operation modes, i.e., in
curating, change-set-creation, and change-set-posting.

The commit also fixes some errors.
2026-03-10 01:49:03 +01:00
Christian Monch
rename --change-set to --create-change-set
Rename `--change-set` to `--create-change-set`. Improve
validity check to change-set operations when
`--list-records` or `--list-labels` is defined.
2026-03-10 01:49:03 +01:00
Christian Monch
store annotations in change sets
The annotations that are removed from incoming records
are now stored in change sets and can therefore be
added when the change set is posted. This keeps the
diff small and content-related, while preserveing the
annotations.
2026-03-10 01:49:03 +01:00
Christian Monch
2026-03-10 01:49:03 +01:00
Christian Monch
add change set creation
Create a changeset that contains a one-level
hierarchy. The first level is the `label` of the
inbox. Below that level all changes from the
respective inbox are stored in individual files.
The file names are created from the PIDs of the
incoming records by replacing `-` with `--` and
`/` with `-_`.

The double replacements is necessary to prevent
name collisions that could otherwise occur if
the replacement for `/` is part of a PID.
2026-03-10 01:49:03 +01:00