thedotmack/claude-mem · warning
CLOCK_HEADER
CLOCK_HEADER
Error message
CLOCK_HEADER
What it means
CcsAlignRulesWalker.walkRules detects conflicts between layered prompt/rule files. The CLOCK_HEADER conflict fires when detectClockHeader() finds a top-of-prompt clock or a 'current time is' line in any layer, which violates the house rule that no clock may appear in the prompt prefix. This is a lint-style finding, not an exception.
Solutions
- Remove the clock/timestamp line from the flagged layer file at entry.file
- Disable whatever tool injects the timestamp header into the prompt/profile
- Regenerate or hand-edit the profile so the prefix contains no time information
- Re-run walkRules to confirm the conflict is gone
Example fix
// before (profile line) Current time is 2026-09-17 10:42:00. You are an assistant... // after (profile line) You are an assistant...
Defensive patterns
Strategy: validation
Validate before calling
const clockRe = /current time is|\d{4}-\d{2}-\d{2}[ T]\d{2}:\d{2}/i;
if (clockRe.test(profileText)) console.warn('CLOCK_HEADER detected before walk'); Prevention
- Never auto-inject timestamps into prompt/profile prefixes
- Lint profiles in CI with the same detectClockHeader pattern
- Treat CLOCK_HEADER conflicts as blocking in review
- Regenerate profiles from templates that exclude time headers
When it happens
Trigger: A layer (profile) file contains a line matching the clock-header detector, e.g. a timestamp header or 'Current time is ...' text, while walkRules iterates entry.lines.
Common situations: Prompt templates that auto-inject a clock/timestamp header; copied profiles carrying a date prefix; tools that stamp 'current time' at the top of generated profiles.
Understand the failure class
Background: Conflicting config options: "cannot be used together" — configuration validation errors across open-source libraries — this error's family across 162 libraries.
Related errors
AI-assisted analysis of thedotmack/claude-mem@d8bc9755e7 (2026-09-17).
Data as JSON: /api/errors/af9ed1ae2e1f63f3.
Report an issue: GitHub.
Appendix: source
Thrown at src/services/integrations/CcsAlignRulesWalker.ts:497
// Build all house+project lines for deny/allow cross-layer comparison
const houseProjectLines: string[] = [...allHouseLines];
for (const entry of project.entries) {
for (const line of entry.lines) {
const trimmed = line.trim();
if (trimmed.length > 0) houseProjectLines.push(trimmed);
}
}
const allLayers = [...house.entries, ...project.entries, ...seat.entries];
// Walk all entries, detecting conflicts
for (const entry of allLayers) {
for (const line of entry.lines) {
// CLOCK_HEADER: any layer
if (detectClockHeader(line)) {
conflicts.push({
code: 'CLOCK_HEADER',
layer: entry.layer,
file: entry.file,
line,
detail: 'Top-of-prompt clock or "current time is" in a profile (house rule: no clock in prefix)',
});
}
}
}
// Seat-layer specific conflict detection (against house)
const shadowPatchesByFile = new Map<string, Set<string>>();
for (const entry of seat.entries) {
for (const line of entry.lines) {
const trimmed = line.trim();
if (trimmed.length === 0) continue;
// SHADOW_HOUSE: leaf line also at house (or starts with "House rule")View on GitHub (pinned to d8bc9755e7)