{
 "number": 36241,
 "repo": "bitcoin/bitcoin",
 "url": "https://github.com/bitcoin/bitcoin/pull/36241",
 "title": "build, doc: Warn on unprivileged Guix daemon usage",
 "author": "Ronin95",
 "author_association": "FIRST_TIME_CONTRIBUTOR",
 "created_at": "2026-09-14T05:00:37Z",
 "updated_at": "2026-09-14T11:18:30Z",
 "age_days": 3,
 "draft": true,
 "labels": [],
 "milestone": null,
 "base": "master",
 "head_sha": "8a8c383f91d99ebbcc0061b4f820266f829e27ee",
 "head_ref": "guix-warn-unprivileged",
 "head_repo": "Ronin95/bitcoin-core",
 "head_history": [],
 "additions": 57,
 "deletions": 0,
 "changed_files": 2,
 "commit_count": 2,
 "size_bucket": "S",
 "mergeable_state": "clean",
 "bot": {
  "drahtbot": {
   "present": true,
   "reviews": {},
   "conflicts": []
  }
 },
 "acks_parsed": {},
 "acks_tally": {
  "ack": 0,
  "stale_ack": 0,
  "concept_ack": 0,
  "approach_ack": 0,
  "nack": 0,
  "concept_nack": 0,
  "approach_nack": 0
 },
 "reviews": {
  "approved": 0,
  "changes_requested": 0,
  "distinct_reviewers": [
   "hebasto"
  ]
 },
 "signals": {
  "needs_rebase": false,
  "ci_failed": false,
  "mergeable_state": "clean",
  "last_author_activity": "2026-09-13T20:29:22Z",
  "last_reviewer_activity": "2026-09-14T11:14:14Z",
  "last_reviewer": "hebasto",
  "author_silent_days": 3,
  "waiting_on_author_days": 3,
  "days_since_update": 3
 },
 "refs": {
  "mentioned": [
   36239
  ],
  "depends_on": [],
  "fixes": [],
  "linked_issues": [],
  "references": [
   {
    "number": 36239,
    "type": "issue",
    "state": "open",
    "merged": false,
    "merged_at": null,
    "title": "RFC: Hazards of the modern unprivileged Guix daemon configuration"
   }
  ],
  "conflicts": []
 },
 "stack": {
  "shares_commits_with": [],
  "based_on": [],
  "base_for": []
 },
 "review_paths": [],
 "body": "**Motivation and Developer Experience Improvement**\nThis PR addresses issue [#36239](https://github.com/bitcoin/bitcoin/issues/36239). Developers who use Guix to build Bitcoin Core locally may run into confusing dependency build failures, such as errors when compiling `python-distlib` or `node`, if their Guix daemon is running as an unprivileged user.\n\nRecent unprivileged Guix installations use Linux user namespaces. These can cause some packages to fail when building locally without substitutes because the build environment has different permissions. For example, `/etc` may be unexpectedly writable, or builds may fail with UID/GID errors.\n\nThe problem is that developers only discover this after a long build has already failed, often with error messages that do not clearly point to the real cause.\n\nThis PR improves the developer experience by:\n\n1. Adding a check to `contrib/guix/guix-build` that detects when `guix-daemon` is running as a non-root user and shows a warning before the build starts.\n2. Updating `contrib/guix/INSTALL.md` with clear instructions for changing an unprivileged Guix daemon back to a privileged (`root`) configuration.\n\nBy catching this configuration issue before the build starts, we save developers hours of wasted compilation time and reduce the support burden on maintainers diagnosing environmental build failures.\n\n**Testing**\nBecause this check depends on the local system environment, no new automated tests were added.\nThe changes to `guix-build` were tested manually on Ubuntu 26.04. The check correctly detects when the daemon is running as an unprivileged user and does not report false positives when the Guix daemon is running normally as `root`.",
 "commits": [
  {
   "sha": "f1ab5a7fc2f52a77b7bc4c7d2420e30a92d38f40",
   "date": "2026-09-13T20:27:44Z",
   "message": "guix:warn on unprivileged daemon (RFC #36239)"
  },
  {
   "sha": "8a8c383f91d99ebbcc0061b4f820266f829e27ee",
   "date": "2026-09-13T20:29:22Z",
   "message": "doc: document unprivileged to privileged guix daemon migration"
  }
 ],
 "timeline": [
  {
   "t": "2026-09-14T11:14:14Z",
   "kind": "comment",
   "who": "hebasto",
   "assoc": "MEMBER",
   "text": "I suggest keeping this PR as a draft until the ongoing discussion in #36239 reaches a rough consensus."
  }
 ],
 "labels_log": [],
 "state_log": [
  {
   "t": "2026-09-14T11:18:30Z",
   "kind": "convert_to_draft",
   "who": "fanquake"
  }
 ],
 "text_chars": 1962,
 "text_tokens_estimate": 490,
 "changed_paths": [
  "contrib/guix/INSTALL.md",
  "contrib/guix/guix-build"
 ],
 "files": [
  {
   "path": "contrib/guix/INSTALL.md",
   "add": 37,
   "del": 0
  },
  {
   "path": "contrib/guix/guix-build",
   "add": 20,
   "del": 0
  }
 ],
 "test_lines": 57,
 "git": {
  "head": "8a8c383f91d99ebbcc0061b4f820266f829e27ee",
  "head_matches_backup": true,
  "base": "17817818da3cb67c95320b7a5d4d69bd649c1fbf",
  "commits": [
   {
    "sha": "f1ab5a7fc2",
    "subject": "guix:warn on unprivileged daemon (RFC #36239)",
    "files": 1,
    "add": 20,
    "del": 0
   },
   {
    "sha": "8a8c383f91",
    "subject": "doc: document unprivileged to privileged guix daemon migration",
    "files": 1,
    "add": 37,
    "del": 0
   }
  ],
  "patch_truncated": false
 },
 "input_hash": "bc8bfe69ddcad331",
 "extracted_at": "2026-09-17T16:15:31+00:00"
}