commit 43272414fe538a762ed2c611420e44a8011525b1
Merge: d69214adf 0db0eed99
Author: Colin Watson <cjwatson@debian.org>
Date: Tue Mar 17 14:38:44 2026 +0000
Revert debci workarounds (MR !2864)
This reverts commits c228b32308efeee7d6ed58b897b7432b834346d3 and
f3bebdcbd69c0b4c1f8b592b83de1e64c9ce1e81, since debci 3.14.1 fixed the
underlying problems.
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2864
commit 0db0eed99306bb96683e73a54d5eef8700a3b639
Author: Colin Watson <cjwatson@debian.org>
Date: Tue Mar 17 13:34:07 2026 +0000
Revert debci workarounds
This reverts commits c228b32308efeee7d6ed58b897b7432b834346d3 and
f3bebdcbd69c0b4c1f8b592b83de1e64c9ce1e81, since debci 3.14.1 fixed the
underlying problems.
commit d69214adfc604e419e078818a3926921149fd0fe
Merge: 2d603265f 78ace5aaa
Author: Colin Watson <cjwatson@debian.org>
Date: Mon Mar 16 23:41:25 2026 +0000
Optimize mtime checks (MR !2862)
It's relatively rare for files to be orphaned (in storage but not in the
database), and checking the mtime requires an extra system call for
local stores. That means that it makes more sense to only check mtimes
for files after checking that they're orphaned.
Part of #724.
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2862
commit 78ace5aaa149c2128cef8aa14b5cc0986345e41e
Author: Colin Watson <cjwatson@debian.org>
Date: Mon Mar 16 18:02:35 2026 +0000
Remove useless sort
commit 16f2e49a321ca0773182d5e4b1af56d790f9267c
Author: Colin Watson <cjwatson@debian.org>
Date: Wed Mar 11 10:21:28 2026 +0000
Optimize mtime checks
It's relatively rare for files to be orphaned (in storage but not in the
database), and checking the mtime requires an extra system call for
local stores. That means that it makes more sense to only check mtimes
for files after checking that they're orphaned.
Part of #724.
commit 2d603265f071ee4069c08c1b480032cb839d5084
Merge: b2de2c3d2 a312708e4
Author: Stefano Rivera <stefanor@debian.org>
Date: Mon Mar 16 16:12:10 2026 +0000
Rename SECRET_KEY prefix from `default` to `django-insecure-` (MR !2861)
* Rename SECRET_KEY prefix from `default` to `django-insecure-`
* Delete `secret_key_not_default_in_debug_0` method
Fixes: https://salsa.debian.org/freexian-team/debusine/-/issues/55
Closes #55
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2861
commit b2de2c3d2cd47e8c4ef29efc452bd6956a250570
Merge: be2a6fec8 8af5f3695
Author: Colin Watson <cjwatson@debian.org>
Date: Mon Mar 16 14:50:53 2026 +0000
Upgrade to ruff 0.15.6 (MR !2860)
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2860
commit be2a6fec8b182c5a31e53d7440808e70a27bdb00
Merge: 274e1f4f4 687b91349
Author: Stefano Rivera <stefanor@debian.org>
Date: Mon Mar 16 14:04:35 2026 +0000
Restrict the websocket to external (and signing) workers (MR !2858)
In preparation for #523
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2858
commit a312708e4c5d2cebfd4d4ca7dac91f0129af644b
Author: elkal98 <khalid.alhaddad98@gmail.com>
Date: Mon Mar 16 13:34:53 2026 +0000
Rename SECRET_KEY prefix from `default` to `django-insecure-`
commit 274e1f4f4e49071ca6caf5fb1e5e5c0d8e916dad
Merge: b685c9254 ef6ac71e3
Author: Stefano Rivera <stefanor@debian.org>
Date: Mon Mar 16 13:07:34 2026 +0000
Restrict access to the asset-permission-check endpoint to signing workers. (MR !2856)
Part of a permissions audit for #523
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2856
commit 8af5f3695c91081052830b664c34bed0b4cbabdd
Author: Colin Watson <cjwatson@debian.org>
Date: Mon Mar 16 13:05:29 2026 +0000
Upgrade to ruff 0.15.6
commit ef6ac71e310b4ad0666c17c5d17a625057fa8830
Author: Stefano Rivera <stefano@freexian.com>
Date: Sun Mar 15 10:59:27 2026 -0400
Restrict access to the asset-permission-check endpoint to signing workers.
commit 687b91349646db6d95df988234c2ac23832acf33
Author: Stefano Rivera <stefano@freexian.com>
Date: Tue Mar 3 17:09:27 2026 -0400
Restrict the websocket to external (and signing) workers
commit b685c92547d9f52449a4a8bd2e725876411bd8e1
Merge: 55775cecc c60207df6
Author: Enrico Zini <enrico@debian.org>
Date: Mon Mar 16 10:20:47 2026 +0000
Use new test helpers also for workflow tests. Fixes: #1343 (MR !2853)
Closes #1343
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2853
commit 55775cecc5a6552f7e8b29ad82ff7cb456ae3256
Merge: 1def08baf 41f6f3a49
Author: Carles Pina i Estany <carles@pina.cat>
Date: Mon Mar 16 09:56:46 2026 +0000
BaseDynamicTaskData.get_input_artifacts_ids: return artifact ids if available (MR !2827)
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2827
commit 41f6f3a49ea200e5db1484db4d55326cdd7dd499
Author: Carles Pina i Estany <carles@pina.cat>
Date: Mon Mar 16 09:56:46 2026 +0000
BaseDynamicTaskData.get_input_artifacts_ids: return artifact ids if available
commit c60207df62e3a168d9634242ef0794f5ca3abae0
Author: Enrico Zini <enrico@enricozini.org>
Date: Mon Mar 16 09:25:27 2026 +0100
Do not set context_artifact in the common case
commit 304c1934486f52c6741d11aaed7343eb77044677
Author: Enrico Zini <enrico@enricozini.org>
Date: Sat Mar 14 15:18:35 2026 +0100
Made test methods stricter, now that all tests follow the same pattern
commit ea84e1bc60a9942bb38c80e90b0a61dc081e0ac1
Author: Enrico Zini <enrico@enricozini.org>
Date: Sat Mar 14 14:51:04 2026 +0100
Use new infrastructure in workflow tests
commit ee0a42dc85d4f2dc7940f2fa2c54dd707927c794
Author: Enrico Zini <enrico@enricozini.org>
Date: Sat Mar 14 14:13:36 2026 +0100
Share test assets across tests
commit 130ca75f621d7dba824096a018632073ab65a2fb
Author: Enrico Zini <enrico@enricozini.org>
Date: Sat Mar 14 14:07:45 2026 +0100
Use self.work_request instead of self.task.work_request
commit 597c73f97af955f166d1d4bc985e797865f7a56f
Author: Enrico Zini <enrico@enricozini.org>
Date: Fri Mar 13 20:55:21 2026 +0100
Update task test helpers to support testing workflows
commit 1def08bafb9c1bb1a5667df53b0162cb61bd2ddf
Merge: 07d7f12ac 64336b644
Author: Enrico Zini <enrico@debian.org>
Date: Mon Mar 16 09:31:55 2026 +0000
Use for server and wait task tests the same patterns used for external task tests (#1343) (MR !2850)
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2850
commit 64336b644edf11f3d9e449f95aaa6ae5b696010f
Author: Enrico Zini <enrico@enricozini.org>
Date: Fri Mar 13 20:18:15 2026 +0100
Common base for server and wait task tests
commit b690ed6a667f281cd7ad94ae7ed829192060d197
Author: Enrico Zini <enrico@enricozini.org>
Date: Fri Mar 13 15:12:20 2026 +0100
Use for server task tests the same patterns used for external task tests
commit 07d7f12ace9d41d666421f3415bd551cbdde557f
Merge: fea708bae 93f0630cd
Author: Enrico Zini <enrico@debian.org>
Date: Mon Mar 16 08:56:58 2026 +0000
Merge test helpers for external tasks (#1343) (MR !2849)
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2849
commit 93f0630cd46a303d84020c87ff2a1ffbc0b15c61
Author: Enrico Zini <enrico@enricozini.org>
Date: Fri Mar 13 12:05:25 2026 +0100
Unify the rest of worker and signing task helpers
commit 31c38e1692d924232d47340c46ebf0059a579acc
Author: Enrico Zini <enrico@enricozini.org>
Date: Fri Mar 13 11:36:27 2026 +0100
Unify the way external tasks are being tested, and allow direct edit of task data before instantiation
commit 2e0dd42b138841cc1908828cf321bac0736e3847
Author: Enrico Zini <enrico@enricozini.org>
Date: Fri Mar 13 10:41:10 2026 +0100
Common SAMPLE_TASK_DATA for all external task helpers
commit a2e6cff8c8bf1cd051410765473a15173f55ee8a
Author: Enrico Zini <enrico@enricozini.org>
Date: Fri Mar 13 10:39:48 2026 +0100
Instantiate field resolver in base helper class
commit 26a78c5afeeade23eeaa798ff804983bbd8487c9
Author: Enrico Zini <enrico@enricozini.org>
Date: Fri Mar 13 10:23:11 2026 +0100
Renamed task_db to resolver for task tests
No code changes besides renames
commit b6c4ef85c577b363ce6173534a3b4817e4f7a5c2
Author: Enrico Zini <enrico@enricozini.org>
Date: Fri Mar 13 10:00:02 2026 +0100
Renamed debusine.tasks.tests.helper_mixin to debusine.tasks.tests.helpers
No code changes besides renames
commit fea708bae5b3f3b6d08b68010f952d5e39b87ac1
Merge: 628b8ce30 522b9e0d8
Author: Enrico Zini <enrico@debian.org>
Date: Mon Mar 16 08:15:54 2026 +0000
Restrict tasks providing task:source-package tags to the SYSTEM provenance. Fixes: #1381 (MR !2846)
This is interesting in that it's technically the user deciding the source package to build, and therefore its name. However it does come from database queries, and we do want to prevent the user from specifying it in any other way
Closes #1381
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2846
commit 522b9e0d8f099e954106128173951d3c24385d52
Author: Enrico Zini <enrico@enricozini.org>
Date: Thu Mar 12 11:12:59 2026 +0100
Restrict tasks providing task:source-package tags to the SYSTEM provenance.
commit 628b8ce3058de97e63e53d6d11ea15f86c8889de
Merge: c128e94cd feaf522b6
Author: Enrico Zini <enrico@debian.org>
Date: Mon Mar 16 07:40:02 2026 +0000
Use a single compute_scheduler_tags to compute task provided/required scheduler tags (#326) (MR !2845)
This replaces !2805
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2845
commit feaf522b6a228261abec5a3461a080c5a653e9c4
Author: Enrico Zini <enrico@enricozini.org>
Date: Thu Mar 12 10:50:21 2026 +0100
Document the change
commit b2b3b00b2d266de4e478b025837846ec2c846103
Author: Enrico Zini <enrico@enricozini.org>
Date: Thu Mar 12 10:46:40 2026 +0100
Merge compute_system_required_tags, get_user_provided_tags and get_provided_worker_tags into compute_scheduler_tags
commit 0172768dcf60753974891db98267d22f2b32c1f3
Author: Enrico Zini <enrico@enricozini.org>
Date: Thu Mar 12 10:30:08 2026 +0100
Refactored tests to test compute_scheduler_tags instead of the old methods
This introduces a common base for all task test helpers, small prelude to #1343
commit 87de0a2f187d1f5400d382f8f47ff7c6f60b3b7d
Author: Enrico Zini <enrico@enricozini.org>
Date: Wed Mar 11 10:08:49 2026 +0100
Redesigned server-side computation of task provided/required tags to use a single method
commit c128e94cdbd8850d9b78fcd1bbfcadb56ff24b20
Merge: c03f5994a ffa0309a2
Author: Stefano Rivera <stefanor@debian.org>
Date: Sun Mar 15 19:14:00 2026 +0000
add: pre-commit hook for trailing whitespace and end of file new line (MR !2855)
Added pre-commit hooks to remove trailing whitespaces and extra new lines at the end of files.
Ran pre-commit on entire repo to fix pre-existing inconsistencies.
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2855
commit ffa0309a20a4dc98e44154d4cfb099afdb35f674
Author: Nikil Paul S <snikilpaul@gmail.com>
Date: Sun Mar 15 16:01:39 2026 +0000
add: pre-commit hook for trailing whitespace and end of file new line
commit c03f5994a8ebd6094cfa7ba8d6036abfff4ce307
Merge: 9f2184845 cd9f83d74
Author: Colin Watson <cjwatson@debian.org>
Date: Sun Mar 15 10:47:08 2026 +0000
Don't stop/start timer units on upgrade (MR !2854)
This avoids running slow regular jobs as part of the upgrade. They can
wait until their usual time.
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2854
commit 9f2184845459a916b9b499181adc2889be55a962
Merge: 9313094ef e697dab86
Author: Colin Watson <cjwatson@debian.org>
Date: Sat Mar 14 22:22:45 2026 +0000
delete_expired: Take much less aggressive locks (#473) (MR !2851)
The `ACCESS EXCLUSIVE` table locks were here to avoid problems where
parallel transactions create new references to rows that are in the
process of being expired. However, taking those locks means that almost
nothing else in Debusine can do anything while expiry is running, which
caused serious operational problems.
We can avoid the new-references problem in a much gentler way: since
creating those new references would involve taking `FOR KEY SHARE` locks
on the referenced rows, we can explicitly take `FOR UPDATE` locks on the
rows that are being expired and rely on that lock mode conflicting with
`FOR KEY SHARE`. To ensure that expiry can run in most situations, we
skip rows that are already locked by another transaction. In the case
of artifacts, we must then recompute the set of artifacts to expire,
since keeping more artifacts than were initially marked to keep might
prevent the expiry of some additional artifacts due to relation chains.
Closes #473
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2851
commit 9313094ef5170d1ff68e5cad00ba7b77c171abd2
Merge: 0cb5e2e77 1ad8fa367
Author: Stefano Rivera <stefanor@debian.org>
Date: Fri Mar 13 23:38:54 2026 +0000
Restrict submission to the open-metrics API endpoints to Celery workers. (MR !2848)
Locking down worker token usage in preparation for #523
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2848
commit 0cb5e2e77b16e88a44e90002bc9e4728d89fc8e4
Merge: c68d189f2 d5c770cc5
Author: Enrico Zini <enrico@debian.org>
Date: Fri Mar 13 20:25:15 2026 +0000
Restrict worker provided worker type tags to the system provenance (MR !2837)
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2837
commit c68d189f295aa48b011faee3d37104698d23f254
Merge: e61c985d2 e2800c9db
Author: Enrico Zini <enrico@debian.org>
Date: Fri Mar 13 20:09:53 2026 +0000
Make task input fields task-agnostic (#1357) (MR !2833)
This is a partial refactoring: more input field resolution implementations can be ported to `DBFieldResolver`, simplifying them by allowing them to use the Django ORM directly instead of interface methods.
This could potentially make them more efficient: `ExtraRepositoriesInput` now has one less query per debusine repository, as it can reuse the collection to lookup its signing keys.
My goal here however was to allow task input fields to be used for containers that are not `BaseExternalTask`, so that server tasks and workflows could make use of them, too. Building from this MR it should be possible to make it happen
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2833
commit d5c770cc5dd2a5533ad08f23878959020be1448e
Author: Enrico Zini <enrico@enricozini.org>
Date: Wed Mar 11 08:56:16 2026 +0100
Announce the change
commit 53ca90833503d961f02c7bef70f2991e9962757c
Author: Enrico Zini <enrico@enricozini.org>
Date: Wed Mar 11 08:39:43 2026 +0100
Restrict worker provided worker type tags to the system provenance
commit e2800c9dbf2d9151f31556a8b3a8253cd2518b81
Author: Enrico Zini <enrico@enricozini.org>
Date: Fri Mar 13 20:35:45 2026 +0100
Look up archive collection in the same workspace as the suite collection
commit feea05bf14886de0da0ccdf0c90a76e32cca9fa5
Author: Enrico Zini <enrico@enricozini.org>
Date: Tue Mar 10 16:05:24 2026 +0100
Ported ExtraRepositoriesInput resolution to FieldResolver.
This allows to do it cleanly with Django's ORM, getting rid of the lookup_single_collection interface
commit 0e8d7e5549c9b8ed2ba78fff54f2777fe7b43669
Author: Enrico Zini <enrico@enricozini.org>
Date: Tue Mar 10 14:31:49 2026 +0100
Add a specific fieldresolver method to resolve SuiteArchiveInput
commit ba4acc4dc19350468d085c3c6fac8904e720cd83
Author: Enrico Zini <enrico@enricozini.org>
Date: Tue Mar 10 11:54:40 2026 +0100
Make task input fields API agnostic on the TaskFieldContainer type
commit a9bd0010fc11517966855149e8d8a461502e6227
Author: Enrico Zini <enrico@enricozini.org>
Date: Tue Mar 10 11:49:20 2026 +0100
Moved MockFieldResolver from task test helpers to debusine.tasks.inputs
commit d844dba578abdccff7ac1697c0ef3c24f5316df9
Author: Enrico Zini <enrico@enricozini.org>
Date: Mon Mar 9 16:44:09 2026 +0100
Move environment resolution to FieldResolver, to avoid having fields API depend on tasks
commit 29a46195d64e987ba387f54b713523a4f13741ad
Author: Enrico Zini <enrico@enricozini.org>
Date: Mon Mar 9 13:56:03 2026 +0100
Take a DBTask instead of a WorkRequest to instantiate a DBFieldResolver
commit e697dab8626bf39afc06af5cf623fe4199e24eaf
Author: Colin Watson <cjwatson@debian.org>
Date: Fri Mar 13 15:49:47 2026 +0000
Merge RunInParallelTransaction and RunInThreadAndCloseDBConnections
These did somewhat similar things, and on the whole
`RunInParallelTransaction` is more useful. I just added a one-shot
variant to it for convenience.
commit 6196e0f79128c54bea2a39a3235f1928670c6f77
Author: Colin Watson <cjwatson@debian.org>
Date: Fri Mar 13 14:12:29 2026 +0000
delete_expired: Take much less aggressive locks
The `ACCESS EXCLUSIVE` table locks were here to avoid problems where
parallel transactions create new references to rows that are in the
process of being expired. However, taking those locks means that almost
nothing else in Debusine can do anything while expiry is running, which
caused serious operational problems.
We can avoid the new-references problem in a much gentler way: since
creating those new references would involve taking `FOR KEY SHARE` locks
on the referenced rows, we can explicitly take `FOR UPDATE` locks on the
rows that are being expired and rely on that lock mode conflicting with
`FOR KEY SHARE`. To ensure that expiry can run in most situations, we
skip rows that are already locked by another transaction. In the case
of artifacts, we must then recompute the set of artifacts to expire,
since keeping more artifacts than were initially marked to keep might
prevent the expiry of some additional artifacts due to relation chains.
Fixes: #473
commit 92b090e21e3149bc25a0913f94bd1de77cf0c94f
Author: Colin Watson <cjwatson@debian.org>
Date: Fri Mar 13 11:24:04 2026 +0000
debusine.db.tests.utils: Use ThreadPoolExecutor in all cases
This means that any exception raised in the worker thread is re-raised
in the main thread, which can be useful for debugging.
commit 2cbc4b1dfdcf437affcfa5bf06b74db841ea7bea
Author: Colin Watson <cjwatson@debian.org>
Date: Thu Mar 12 16:31:55 2026 +0000
delete_expired: Use REPEATABLE READ isolation level
In general, it seems a bad idea to allow these "figure out what to
delete, then delete it" algorithms to encounter nonrepeatable reads,
which the PostgreSQL documentation defines as: "A transaction re-reads
data it has previously read and finds that data has been modified by
another transaction (that committed since the initial read)."
For now, I've omitted retries in most cases, as there's relatively
little harm in just failing and trying again on the next run. We can
revisit this decision later if need be.
commit 1ad8fa36719d52103603cb95dfdd792de9190816
Author: Stefano Rivera <stefano@freexian.com>
Date: Thu Mar 12 21:10:53 2026 -0400
Restrict submission to the open-metrics API endpoints to Celery workers.
commit e61c985d21b16c83d0edb5b7b424fc1f50c74b25
Merge: 5e3ec74ce 2a7bd41b3
Author: Colin Watson <cjwatson@debian.org>
Date: Thu Mar 12 15:17:12 2026 +0000
Upgrade to ruff 0.15.5, codespell 2.4.2, and vulture 2.15 (MR !2843)
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2843
commit 5e3ec74ceb1203b562037629cede384f9e20edc7
Merge: 552a09ccc 628502975
Author: Carles Pina i Estany <carles@pina.cat>
Date: Thu Mar 12 13:21:13 2026 +0000
PiupartsWorkflow: create/include Piuparts task for each available architecture and test "all" packages (related #1174) (MR !2758)
PiupartsWorkflow: create/include Piuparts task for each available architecture and test "all" packages
Previously, "all" packages were tested separately in
"arch_all_build_architecture"
Related #1174
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2758
commit 62850297527da7c1212e9f63f42a12247825a9b7
Author: Carles Pina i Estany <carles@pina.cat>
Date: Thu Mar 12 13:21:13 2026 +0000
PiupartsWorkflow: create/include Piuparts task for each available architecture and test "all" packages
Previously, "all" packages were tested separately in
"arch_all_build_architecture"
Related #1174
commit 552a09ccc6d4ce7f03d04802b249dbaa2b87a942
Merge: 98104f46d 199f242aa
Author: Colin Watson <cjwatson@debian.org>
Date: Thu Mar 12 12:12:17 2026 +0000
Re-optimize DeleteExpiredArtifacts._mark_to_keep (MR !2847)
Searching for reverse "extends" relations turned this into a three-way
join, causing PostgreSQL to have to think about a gigantic intermediate
table. An inner CTE makes things much better, making this take about
four seconds on debusine.debian.net rather than hours.
I added an empty news fragment since this fixes a regression I
introduced in bad9ce881a82a99c6810090761663e7c267db05d, which was since
the last release.
Fixes: #1383
Closes #1383
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2847
commit 2a7bd41b317ff7f9163e67e677c7472153867555
Author: Colin Watson <cjwatson@debian.org>
Date: Thu Mar 12 11:53:53 2026 +0000
Revert "Work around setuptools 72 incompatibilities in some dependencies"
This reverts commit 8c340e446f77c9b5525a4c7e5f35bf44dab466e3, which
shouldn't be needed any more.
commit 98104f46dc546a27a0326d5ef728ac7f426c430a
Merge: f38610fa8 647a576d4
Author: Stefano Rivera <stefanor@debian.org>
Date: Thu Mar 12 11:51:55 2026 +0000
Restrict artifact relation creation and deletion (MR !2836)
Only read-only permissions were being checked, allowing anonymous users to create and delete relationships between public artifacts.
Pre-requisite for: #523
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2836
commit f38610fa85d9b824fb3c3d8a8490d81cd9398287
Merge: f8a1efc41 fd087b065
Author: Colin Watson <cjwatson@debian.org>
Date: Thu Mar 12 11:49:07 2026 +0000
work-request-completed: Set isolation level and retry deadlocks (MR !2842)
As shown in #1382, it's sometimes possible for
`UpdateWorkRequestAsCompletedView` to hit a deadlock. This is
unfortunate because it means we end up retrying the work request from
scratch, which could easily amount to throwing away hours of work.
Completely preventing this is a more complicated project (e.g. #1362
would likely help), but we can at least retry deadlock errors a few
times.
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2842
commit 199f242aa04eadc05532d7bd8d10b5deb1965293
Author: Colin Watson <cjwatson@debian.org>
Date: Thu Mar 12 11:32:51 2026 +0000
Flush output from DeleteOperation immediately
Patch from Raphaël Hertzog in
https://salsa.debian.org/freexian-team/debusine/-/issues/1383#note_734323.
commit 245da466778ab1fc51748f5d903893159ea1b697
Author: Colin Watson <cjwatson@debian.org>
Date: Thu Mar 12 11:31:18 2026 +0000
Re-optimize DeleteExpiredArtifacts._mark_to_keep
Searching for reverse "extends" relations turned this into a three-way
join, causing PostgreSQL to have to think about a gigantic intermediate
table. An inner CTE makes things much better, making this take about
four seconds on debusine.debian.net rather than hours.
I added an empty news fragment since this fixes a regression I
introduced in bad9ce881a82a99c6810090761663e7c267db05d, which was since
the last release.
Fixes: #1383
commit 3787fd22e787aa34df130f8612e5e162f117ec96
Author: Colin Watson <cjwatson@debian.org>
Date: Wed Mar 11 20:58:35 2026 +0000
Upgrade to ruff 0.15.5, codespell 2.4.2, and vulture 2.15
commit cd9f83d74325dc4d2d3a26671be27f3a66c76abb
Author: Colin Watson <cjwatson@debian.org>
Date: Wed Mar 11 18:12:29 2026 +0000
Don't stop/start timer units on upgrade
This avoids running slow regular jobs as part of the upgrade. They can
wait until their usual time.
commit f8a1efc41a6d6b281e7a03a701bc36515878767d
Merge: 241b44feb c2070a45d
Author: Stefano Rivera <stefanor@debian.org>
Date: Wed Mar 11 17:41:16 2026 +0000
Rename DRF permissions (MR !2841)
Consistent naming, before we introduce another one.
Pre-refactoring for: #523
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2841
commit 241b44febca087b276a32ce028ef01775d739e33
Merge: f4c6c03e3 94be33003
Author: Stefano Rivera <stefanor@debian.org>
Date: Wed Mar 11 17:32:49 2026 +0000
Break WorkspaceArtifactViewTests into their own class (MR !2840)
And factor out common code.
Pre-refactoring for: #523
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2840
commit f4c6c03e33c125306a570718506ced439801c6b8
Merge: 4528db805 4b86a6c0d
Author: Stefano Rivera <stefanor@debian.org>
Date: Wed Mar 11 17:29:17 2026 +0000
Test most WorkRequest get and list views with a user token (MR !2839)
Workers don't need to go looking at arbitrary work requests, only the one they've been assigned.
Pre-requisite for: #523
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2839
commit fd087b06557f4765789d78a766c94b5d291433a7
Author: Colin Watson <cjwatson@debian.org>
Date: Wed Mar 11 17:00:41 2026 +0000
work-request-completed: Set isolation level and retry deadlocks
As shown in #1382, it's sometimes possible for
`UpdateWorkRequestAsCompletedView` to hit a deadlock. This is
unfortunate because it means we end up retrying the work request from
scratch, which could easily amount to throwing away hours of work.
Completely preventing this is a more complicated project (e.g. #1362
would likely help), but we can at least retry deadlock errors a few
times.
commit d3aa15ba838c9c90d2f629a8a9965275ff557f14
Author: Colin Watson <cjwatson@debian.org>
Date: Wed Mar 11 16:49:46 2026 +0000
Configure pgtransaction to retry automatically
This requires working around
https://github.com/AmbitionEng/django-pgtransaction/issues/25.
commit c2070a45d628aede580f331a5c5c0b90f5560a7e
Author: Stefano Rivera <stefano@freexian.com>
Date: Tue Mar 3 18:16:04 2026 -0400
@override decorate DRF permission methods
commit f95ccda22059446d75196b17bb3d9f9c5a576739
Author: Stefano Rivera <stefano@freexian.com>
Date: Tue Feb 24 19:55:36 2026 -0400
Rename IsWorkerAuthenticated -> IsWorkerTokenAuthenticated.
commit ba54b1f0613bd43b2bbda7fb0c8fa0d27ef13b5d
Author: Stefano Rivera <stefano@freexian.com>
Date: Tue Feb 24 19:50:55 2026 -0400
Rename IsTokenUserAuthenticated -> IsUserTokenAuthenticated
commit 94be3300393001fea981588160d2c05a45976070
Author: Stefano Rivera <stefano@freexian.com>
Date: Sat Mar 7 18:38:52 2026 -0400
Break WorkspaceArtifactViewTests into their own class
And factor out common code.
commit 4528db805d436ea9e954d4a82c49837f1391ceef
Merge: 3fbb9c86b 4b51a3622
Author: Enrico Zini <enrico@debian.org>
Date: Wed Mar 11 15:16:32 2026 +0000
Reorganised task input fields and DBTask code in submodules (MR !2823)
This MR contains just code being moved or renamed, no other code changes.
This MR is probably best reviewed on a commit by commit basis
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2823
commit 4b86a6c0d198f700fe281bb3a19247f672db4c99
Author: Stefano Rivera <stefano@freexian.com>
Date: Tue Mar 3 18:58:16 2026 -0400
Test most WorkRequest get and list views with a user token
Workers don't need to go looking at arbitrary work requests, only the
one they've been assigned.
Pre-requisite for: #523
commit 3fbb9c86bdef284f487a0b5d48c6fef2268fc9b0
Merge: af062e2f2 b19f1bec7
Author: Colin Watson <cjwatson@debian.org>
Date: Wed Mar 11 14:46:22 2026 +0000
GetNextWorkRequestView: Don't disturb parent workflows (MR !2838)
If we find that we need to retry some running work requests when getting
the next pending work request for a worker, do so in a way that doesn't
cause parent workflows to be incorrectly marked as completed.
Fixes: #1081
Closes #1081
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2838
commit b19f1bec7959bd943bd299d25d6628f0436f80ff
Author: Colin Watson <cjwatson@debian.org>
Date: Wed Mar 11 11:11:55 2026 +0000
GetNextWorkRequestView: Don't disturb parent workflows
If we find that we need to retry some running work requests when getting
the next pending work request for a worker, do so in a way that doesn't
cause parent workflows to be incorrectly marked as completed.
Fixes: #1081
commit 4b51a362292623c2f0ade1a710071adfd81c57da
Author: Enrico Zini <enrico@enricozini.org>
Date: Tue Mar 10 09:31:22 2026 +0100
Renamed MockTaskDatabase to MockFieldResolver
commit a612ef4c78d5f7504885992fd4cd959bf8cd39c5
Author: Enrico Zini <enrico@enricozini.org>
Date: Mon Mar 9 13:59:46 2026 +0100
Rename task_database to field_resolver in argument and variable names.
No other code changes
commit 2b6e1088f63835ecd46bedbfc28e2352edf93f55
Author: Enrico Zini <enrico@enricozini.org>
Date: Mon Mar 9 13:40:10 2026 +0100
Move debusine.db.models.tasks to debusine.db.tasks, and debusine.db.models.task_field_resolver to debusine.db.tasks.resolver.
No other code changes
commit ad60816977d94a97cf2689cbcd491af260f2c6d1
Author: Enrico Zini <enrico@enricozini.org>
Date: Mon Mar 9 13:15:35 2026 +0100
Renamed TaskDatabaseInterface/TaskDatabase to FieldResolver/DBFieldResolver
No other code changes.
commit a3ea27de945feccc6469264f8aee75882841bf93
Author: Enrico Zini <enrico@enricozini.org>
Date: Mon Mar 9 13:06:56 2026 +0100
Reorganised task input fields code as a submodule.
This has no other code change besides code being moved.
commit af062e2f225cf6e9a3d86ded0b7add22caa0194f
Merge: 34c0c7d0a e64526fda
Author: Enrico Zini <enrico@debian.org>
Date: Wed Mar 11 09:42:30 2026 +0000
Contribute scheduler tags from task configuration in workspace (#326) (MR !2822)
This MR is probably best reviewed on a commit by commit basis
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2822
commit e64526fdabfde4e212801d5c10e892320092bb7a
Author: Enrico Zini <enrico@enricozini.org>
Date: Wed Mar 11 09:02:31 2026 +0100
Announce the change
commit 96f3475c31149c054f427d2d0d68436a3768d113
Author: Enrico Zini <enrico@enricozini.org>
Date: Mon Mar 9 11:06:41 2026 +0100
Contribute scheduler tags from task configuration
commit ab4d658a28fefe54e9855742971f29bebc102ae4
Author: Enrico Zini <enrico@enricozini.org>
Date: Mon Mar 9 11:05:07 2026 +0100
Implemented computing the set of tags to contribute from task configuration
commit 92a1b5ec6694ce55cb5445d6ab19199bbc2ca127
Author: Enrico Zini <enrico@enricozini.org>
Date: Mon Mar 9 10:59:18 2026 +0100
Use enums for tag provenances
commit 5af37a8559531845f45a0bab1711b2b8a7572264
Author: Enrico Zini <enrico@enricozini.org>
Date: Fri Mar 6 12:48:04 2026 +0100
Added tag-contributing fields to DebusineTaskConfiguration
commit 34c0c7d0afb2e354575366033709439f4cb4220d
Merge: d67b6ea21 7a3edd6ce
Author: Enrico Zini <enrico@debian.org>
Date: Wed Mar 11 08:32:12 2026 +0000
Allow to match task configuration entries by task tags (#1231) (MR !2821)
This could potentially obsolete `configuration_context`
Merge-Request: https://salsa.debian.org/freexian-team/debusine/-/merge_requests/2821
commit 7a3edd6cee354f86ed88a505fdd099e5bc666eb4
Author: Enrico Zini <enrico@enricozini.org>
Date: Wed Mar 11 08:53:46 2026 +0100
Announce the change
commit 5df67acdc9d176cd9db57f81796738fb38278258
Author: Enrico Zini <enrico@enricozini.org>
Date: Fri Mar 6 13:45:00 2026 +0100
Filter task configuration collection items using scheduler tags
commit ef6109685d4ed784027fe181f5c3437d3c0a6f14
Author: Enrico Zini <enrico@enricozini.org>
Date: Fri Mar 6 12:48:04 2026 +0100
Added tag-related fields to DebusineTaskConfiguration
commit a0f2de74a3e433d38b9e8846b9eba819e6fe61c4
Author: Enrico Zini <enrico@enricozini.org>
Date: Fri Mar 6 12:38:22 2026 +0100
Documented tag provenances and moved more of the tag blueprint to the main documentation
Automatic checks made by the Debian l10n team found some issues with the translations contained in this package. You should check the l10n status report for more information.
Issues can be things such as missing translations, problematic translated strings, outdated PO files, unknown languages, etc.