~ knotless Search/
↑↓ move↵ open⇧↵ all results

chadtmiller.com/knotless

git that lives in your Atmosphere account

knotless.dev
1 collaborator

knotless 0.13.0 Latest 2 packages, 1 image

1
10

Exclusive labels with no scope displace each other

Closed
Closed chadtmiller.com opened this issue 0 comments
kind/bugarea/cliarea/lexiconsarea/triage

What happened

The docs say a label name with no / is in no scope (collaboration.md, Labels). But Label::scope() returns None for such a name (crates/knotless/src/records.rs). The exclusivity checks compare other.scope() == label.scope(): labelled (crates/knotless/src/forge.rs, about line 489), label (about line 1398) and the triage rival check (crates/knotless/src/triage.rs, about line 139). Two unscoped labels both give None, which compares equal. So every exclusive label without a scope competes with every other one, as if they shared a scope. Nothing refuses --exclusive on an unscoped label.

How to see it

  1. knotless labels <url> add urgent --exclusive and knotless labels <url> add blocked --exclusive.
  2. Put urgent on an issue, then blocked.
  3. urgent is taken off, and readers keep only the newer of the two.

What you expected

Either an unscoped exclusive label displaces nothing, or exclusive is refused on a label with no scope. The scope compare should match only Some(a) == Some(b).

Where

Client and triage, on main at b191acef. Found by the docs audit.

🤖 Generated with Claude Code