Repository navigation
CLAUDE.md: adopt five coding rules from the #1132 review; add the Copilot mirror - #1144
Merged
Merged
Conversation
…ilot mirror Adds five rules after "Code Quality Standards", proposed in the review of #1132 and adopted by the maintainer: - `None` must name a value, not a gap - Keyword-only arguments - Import placement - Private names do not cross module boundaries - Named states are literals, not free text Adapted from the proposal: rule 5 has no UNKNOWN member, and a stored string that is not a member is rejected, not mapped to a fallback (the maintainer's decision for calibrations, #1141). Rule 4's NXstress file list names only files on `next`. A review pass corrected factual claims (existing functions already cross the keyword-only threshold; three deferred imports in _peaks.py; one source default, in HidraSetup), "Three things", and the examples' return type hints. Adds .github/copilot-instructions.md, which CLAUDE.md has always named as its mirror but which did not exist: the same text, with links relative to .github/. Refs #1132 Assisted-by: Claude Code
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars.
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## next #1144 +/- ##
=======================================
Coverage 87.12% 87.12%
=======================================
Files 106 106
Lines 16655 16655
=======================================
Hits 14510 14510
Misses 2145 2145
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This was referenced Nov 25, 2026
fanchercm
added a commit
that referenced
this pull request
Nov 25, 2026
Adopt next's CLAUDE.md on qa (includes #1144)
fanchercm
added a commit
that referenced
this pull request
Nov 25, 2026
Adopt next's CLAUDE.md on main (includes #1144)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adopts the five coding rules proposed in the review of #1132 into
CLAUDE.md, and creates.github/copilot-instructions.md, the mirrorCLAUDE.mdhas always referred to but which did not exist.The rules
Added as top-level sections after Code Quality Standards:
Nonemust name a value, not a gap. NoOptional[T] = Nonedefault where absence is a bug; "count the fillers".EnumorLiteral, imported everywhere it is used.They apply to code that is written or touched, with no retroactive sweep.
Changes from the proposed text
Rule 5:
CalibrationSourcehas noUNKNOWNmember;This follows the maintainer's decisions for calibrations in Calibration content hash: a calibration identifies itself and owns the "same calibration?" check #1141.
Rule 4: the list of NXstress private files names only files that exist on
next._runs.py,_workspace_key.py,_validation.py,_append.pyand_read.pyarrive with the NXstress phase-3 work.Corrections from a review pass:
mask_util.save_mantid_mask);_peaks.pyhas three uncommented deferred imports, not two;record.get("source", "none")default, inHidraSetup, not several;Copilot mirror
.github/copilot-instructions.mdhas the same text asCLAUDE.md, with its links rewritten relative to.github/and a note that tool names such asTodoWriteandAgentare Claude Code's. Keep the two in sync, asCLAUDE.mdsays.Testing
Documentation only. I checked every cited path, function and line against
next, and every relative link in the mirror resolves.Refs #1132
🤖 Generated with Claude Code