Skip to content

Sync TapHouse v8: tidy.sh checks each file once; STYLE.md's banner line - #53

Merged
tap merged 2 commits into
mainfrom
ccr-daa69fda-lj5z0o
Nov 23, 2026
Merged

tap merged 2 commits into
mainfrom
ccr-daa69fda-lj5z0o

Conversation

@tap

@tap tap commented Nov 23, 2026

Copy link
Copy Markdown
Owner

What this changes

This re-syncs TapHouse v8 (8c0e101) with scripts/sync.sh --icon PythonTap and moves the drift check's pin from v7 to v8.

Why

clang-tidy -p build <file> already checks every compile command the database holds for that file, so one call per database entry checked a file compiled n times n² times. This repo's CI gate loops over named sources rather than database entries, so the gate is unaffected. The local sweep, and macOS bash 3.2 support for it, are what change.

Verification

  • sync.sh reported exactly three changed files: tidy.sh, STYLE.md and style.yml's pin. The icons are unchanged.
  • The drift job on this PR checks the synced copies against TapHouse v8.

Notes for the reviewer

  • Style configs come from a TapHouse sync, not a hand-edit.

Generated by Claude Code

scripts/sync.sh from TapHouse v8 (8c0e101) and the drift check's pin
moved from v7 to v8 in .github/workflows/style.yml:
- scripts/tidy.sh: the no-argument sweep checks each file in the compile
  database once (clang-tidy -p checks all of a file's compile commands in
  one call, so one call per entry checked a file compiled n times n^2
  times), and builds its list without mapfile, so macOS bash 3.2 runs it
  (tap/TapHouse#14).
- STYLE.md: the per-file banner template states the family's copyright
  line, "Copyright <year> Timothy Place and the <Library> contributors"
  (tap/TapHouse#13).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016GKzq1VSdcMYCRMhddiMaf

tap commented Nov 23, 2026 •

Copy link
Copy Markdown
Owner Author

Update: fixed on this branch by 5a85af2. The glue's TSan row now builds with Clang, and configuring it with GCC 14+ under TSan stops with an explanation. Every check is green on that head, linux-max-glue (tsan) included. The original diagnosis follows.


linux-max-glue (tsan) fails on this PR, and not because of it. The PR changes only STYLE.md, scripts/tidy.sh and style.yml's TapHouse pin. The job fails compiling a third-party header.

Confirmed red on main too. A run of main (ddfdb31) on today's image fails the same job at its build step, with every other job green: https://github.com/tap/PythonTap/actions/runs/45223624655 (job linux-max-glue (tsan)).

What fails. The min-api submodule's include/readerwriterqueue/atomicops.h (pinned at a500a29) has:

#define AE_NO_TSAN __attribute__((no_sanitize("thread")))   // when __has_feature(thread_sanitizer)
AE_FORCEINLINE void compiler_fence(memory_order order) AE_NO_TSAN { … }

GCC 15, on the current ubuntu-latest image, rejects an attribute in that position ("attributes are not allowed on a function-definition"). The macro only expands under -fsanitize=thread when the compiler reports the thread_sanitizer feature, which is why only the TSan glue job breaks. main last ran this workflow on 2026-10-10, before the runner image moved to GCC 15.

The fix exists upstream. cameron314/readerwriterqueue reworked this. Under C++17 and later, AE_NO_TSAN expands to nothing and it uses TSan annotations instead. A min-api revision carrying it would let the row go back to GCC.


Generated by Claude Code

ubuntu-latest moved to Ubuntu 26.04 and GCC 15, and linux-max-glue (tsan) stopped compiling, on
main as on every branch: "attributes are not allowed on a function-definition", 14 times in each
of the glue test's two TUs, all from min-api's readerwriterqueue. min-api pins it at a500a29, whose
atomicops.h asks __has_feature(thread_sanitizer) and then puts AE_NO_TSAN,
__attribute__((no_sanitize("thread"))), after the declarator of function definitions: a place
Clang accepts and GCC refuses. GCC had no __has_feature before 14, so under GCC 13 the macro was
empty and the row built. readerwriterqueue fixed it in 5904a29; min-api's tip still pins a500a29.

The macro is used on atomicops.h's own definitions too, so nothing force-included ahead of it can
empty it without redefining a builtin. The row builds with Clang instead (the image has 20-22),
installing Clang's sanitizer runtimes when the image lacks them (a recommends in Ubuntu, not a
depends); the release and asan-ubsan rows name gcc/g++, as they ran before. Configuring the glue
test for TSan with GCC 14 or later now stops with a message that says this and what to use, until
the pinned atomicops.h knows __SANITIZE_THREAD__ (5904a29's test), when the check retires itself.

Checked locally: GCC 14 + TSan reproduces CI's errors and now stops at configure; GCC 13 + TSan
and GCC 14 + ASan/UBSan configure as before; Clang 18 + TSan builds and the glue test passes
(233 assertions in 17 test cases, no TSan report); the GCC release build passes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FaMFrPxB5YeqohNoxCyuLM
@tap
tap merged commit 39abc02 into main Nov 23, 2026
24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants