#1118371 Add guidance for file locking; transition from existence-based locking and /var/lock to file locking

#1118371#3
Date:
2025-10-18 18:23:01 UTC
From:
To:
Originally discussed at
https://lists.debian.org/debian-policy/2025/10/msg00023.html .

I've attached a git patch implementing the Policy changes discussed in
that thread.

Based on #1115317, the Technical Committee called for a transition on
locking, and an update to Policy. In general, Policy updates tend to be
lagging indicators, updating after most packages are already compliant.
In this case, most packages already *do* use file locking, rather than
existence-based lockfiles, so I think it'd be reasonable to capture this
in Policy (as a "should" initially, making it a *normal* bug to do
otherwise) *concurrently* with porting the remaining software over to
file locking (per the transitional mechanism this documents in Policy).

Almost all of this is a "should", constituting a "normal" bug. The only
"must" language is around *new* requirements for handling both file
locking and traditional locking while avoiding deadlocks, and the
statement that "`/dev`` and ``/run`` and ``$XDG_RUNTIME_DIR`` *must*
support file locking".

#1118371#8
Date:
2025-12-24 22:16:35 UTC
From:
To:
Following up on this patch. What would be the next steps for applying
this? Are there any further refinements needed to the text?

- Josh Triplett

#1118371#13
Date:
2025-12-27 12:24:56 UTC
From:
To:
Hello,

Thanks.  It needs review from someone who maintains a package that deals
in these mechanisms heavily.  Would you be able to suggest someone?