Replaces Renovate PR #317, which bumped package.json alone and so failed
scripts/install-bun.sh. Move every pin together: packageManager, @types/bun,
the installer's version and four SHA-256 values (from the release's
SHASUMS256.txt), and both Docker stages to oven/bun:1.4.5-alpine, which also
ends the 1.4.4 drift the separate Docker update left in the Dockerfile.
Renovate now groups these packages in one PR without automerge.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0192He3CzBZP96zgTG9hCgLw
The repository allows only rebase and fast-forward merges, so Renovate's
merge-commit automerge failed ("Merging of PR failed" on the dashboard) and
left green minor updates such as #369 open. Document rebase as the merge method.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0192He3CzBZP96zgTG9hCgLw
The default rules scenario now carries the reserve of five: 2.90 s, 0.85 of the calibration, against a multiplier of 1.25 that did not change. The saved-rules section describes the version-2 envelope and the single migration that gives the supplied Samedi Malin its reserve.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0192He3CzBZP96zgTG9hCgLw
Adds the #375 record with the comparison before the rebuild (4,953 of 5,000 seeded requests identical, one worse on a real objective, explained), the seven multi-year requests and the benchmark protocol, lists the rebuild from 1e06fe2 in the frozen-engine table, and notes in ADR 0012 that the loss it accepted behind loss prevention is lifted in the rule's own stage.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0192He3CzBZP96zgTG9hCgLw
ADR 0015 for #374: why the reserve follows the stricter reading of the
staff-representative report of 13 October 2026, which readings were rejected,
and what changes for saved rules and share links.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0192He3CzBZP96zgTG9hCgLw
Record ADR 0014 and the Rule set glossary term for issue #363: a link
carries the whole ordered rule set in its own versioned envelope,
validated all or nothing, and replaces the recipient's rules after
confirmation without touching balances, declared days or the horizon.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0192He39ydEEMnJJQHagHvB2
The summary tiles and the statistics dialog now show leave days placed out
of those the plan could use, unplaced and lost days, total days off with
the weekends and public holidays as a detail, the number of time-off
periods and the longest, the longest stretch without leave, and bridged
public holidays out of the weekday holidays. Units sit next to the number
instead of in the label, and a tile and the dialog share one label.
The two averages are no longer displayed. Earned leave appears only when a
rule earns some, and names a single rule once. Weeks with one workday,
delivered by #69 on main only, are brought back as a dated warning.
Figures are derived in one tested helper; the planning engine is unchanged.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Show the product name VacOptimizer in the header, round plan statistics to one
decimal in the active locale, lay the statistics tiles out in two columns when
the dialog is wide enough, and attach the calculation date to the results
heading and status instead of a free paragraph.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
An absent or unreadable saved list now starts empty; no quantity is
generated. With no leave balance and no declared non-working day there
is nothing to plan: no calculation starts on load, Calculate is disabled
with the reason exposed through aria-describedby, and the results panel
shows the planning horizon's calendar with an invitation. Declared days
alone still calculate, so earned-leave chains keep working.
ADR 0012 records the decision and supersedes the random defaults of
ADR 0005. Tests now state their balances explicitly.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The benchmark has eight scenarios since the default-rules one. The #349 record
no longer says the stage ran for hours, which nothing measured, and separates
its rule-order survey from the named requests. The #350 record mentions the
seventh fixed request added later.
Comparing random long requests before the pull request found a request where
a Samedi Malin occurrence can fund an obligation: the obligations stage then
takes 10 of 11.8 seconds and 3.2 GB. It joins the runner's named requests and
the open points of the #347 record.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0192He3Dca4aadeFoaGp2jB7
Four rebuilds in a row had turned the origin of the frozen engine into one
long sentence; it is now a table, latest first. The #347, #348 and #349
records name the runner that holds their requests, and the README shows how
to use it. The #347 record no longer attributes to #349 the question of
whether loss prevention should leave room for a Samedi Malin pattern.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Record what the Christmas and holiday-week stages did behind Samedi Malin,
with per-stage passes, candidates and kept improvements for the 2027 year
and the issue's request, the four exact changes and why they keep every
plan, the times before and after, the comparison made before rebuilding the
frozen engine, the new benchmark scenario, and the search changes tried and
not committed. Update the benchmark README for the frozen engine's origin,
the seventh fixed request, the check's run time and the default-rules
scenario; point the #321 finding at the record; describe the reuse and the
new prunes in the planning objectives contract; and note in the planning
duration model that the IF_THEN weight needs a refit.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Record issue #347 in docs/benchmark/issue-347.md: the cause, the rule, the
times of the runner's requests before and after 52059dc, and the comparison
before the frozen-engine rebuild. The 5,000 seeded requests and the cancelled
comparisons are identical; the multi-year request with a TIME_WINDOW
obligation and three longer runner requests are worse on Samedi Malin, with
every later objective equal or better.
Name 52059dc as the frozen engine's origin and update the check's run time in
the benchmark README, point the #321 finding to the record, and state the
multi-year result and the measuring machines in ADR 0012.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Record the maintainer's decision on issue #347 as ADR 0012 and state, in the
"Obligation solution" entry of CONTEXT.md, the one exception to "before any
preference rule applies": the pattern of an IF_THEN preference occurrence
whose earned leave can fund a later obligation date.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
The record gave the desktop of the earlier records; its comparison and timings
ran on the development laptop, like those of the #349 record.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Record why loss prevention behind another preference searched relocation
chains without end, the exact skip that replaces them, the before and after
times and memory of the requests of #349, and the comparison made before
rebuilding the frozen engine. Update the benchmark README, which said that
one year of 25 CP and 12 RTT with Samedi Malin ahead of loss prevention does
not finish and named ea2feaf as the frozen engine's origin, and note that a
change removing steps needs a rebuild for the cancelled comparisons. Point
the #321 finding at the record and describe the skip in the planning
objectives contract.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Add the record of issue #350: the cause of the difference, the comparison over
the 5,000 seeded requests before the rebuild, the four placements that differed
on the request of the issue, the failure of the new test against the previous
bundle and the added run time. Update the benchmark README with the new origin
of the frozen engine and the fixed multi-year requests, and point the issue
#321 findings to the record.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
After #321 the prior overstated requests without calendar rules. It also
understated the default rules: Samedi Malin made multi-year requests up
to four times slower than the estimate, beyond the top of the displayed
range.
- The prior is refitted to 38 planning times of one to five years on
Bun, with and without the default calendar rules: a linear horizon
term, a placement power of 1.4 and a weight of 4 per IF_THEN rule.
Measured time now lies between 0.59 and 2.26 times the estimate,
against 0.43 to 4.12.
- The current form is scaled by the median ratio of its similar past
calculations, those with the same rule weight and an initial estimate
within a factor of two, before falling back to the median of all
eight. A slow configuration is therefore predicted from its own wait
on the next calculation, where the overall median kept
underestimating it.
The measurements are planning times in the core, not rendered waits; the
fixed 400 ms for transport and rendering is unmeasured since planning
moved to the server. Obligation weights are unchanged and remain
unreliable (#347).
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
On Bun, the benchmark's loaded year spent 57% of its time scoring
candidate plans. Freezing a 40-element array costs about 50 times the
map that builds it, and a frozen array reads about 12 times slower.
- The lists that plan observations build per candidate plan are no
longer frozen. Their elements stay frozen and their types readonly;
work sequences reuse one frozen object per distinct sequence.
- An optimization is scored in one loop, without intermediate arrays.
Balance and placement observations are built on first read, a
TIME_WINDOW preference stops counting at its requested quantity, and
the expiry tie-break sorts without a comparator.
- A finalized candidate's objective vector no longer counts unsatisfied
obligations again. The retained plan's state key is built once. An
earned entitlement's merged period is found without materializing
every period, and its date arithmetic runs once per period.
- A candidate already worse on a protected objective is still rejected
before finalization when a rule can earn leave, as long as finalizing
it cannot touch an earned balance. Samedi Malin used to switch this
pruning off.
Loaded year 6.31 s to 2.70 s, three years 3.55 s to 1.66 s, two years
1.10 s to 0.54 s. Every outcome, stable explanation and final state is
unchanged: the frozen-engine differential check passes, and 26 requests
of one to four years match the previous engine, cancelled runs included.
The benchmark budgets follow at about 1.5 times the new ratios. The
record lists four search behaviors found on the way and left as they
are (#347, #348, #349, #350).
Closes#321
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
A standards review and a spec review of the ten tickets found no blocking
defect. This applies what they did find.
- A request that is not an object reaches the planner again, which
reports what it lacks, where the lifecycle answered that it could not
be cloned.
- The Compare dates button moves into the date-comparison component, so
the page reads none of its state.
- The numeric changes of a comparison are computed by one function in
the labels module for the placement explanation and the dialog.
- The explanation error of a calculation is typed as an interruption
reason up to the page.
- The two new components use OnPush, as every component but the page.
- The page's date helper loses its Date branch, dead since planning
dates are strings.
- README and the verification notes describe where a calculation is
created, what the worker entry does and which requests are answered
before a job starts. A moved comment says planning stage, not phase.
Refs #335
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
The calculation entry point had three paths: the worker path, one for a
window without a Worker, and an in-process one for no window with its own
cancellation, replacement and explanation flags. Date analysis had a
main-thread fallback too. Only the worker path remains, on the job the
caller passes or the default selection, so every rule of an incomplete
calculation is decided once.
- The lifecycle module no longer checks the window or imports the planner
core at runtime; browsers load the core only in the worker bundle.
- One registry holds the live supersession callbacks, the latest
calculation identity and the latest date analysis.
- A browser with a window but no Worker now reports worker-unavailable
even for an invalid request, where it reported invalid input first.
- The build forces Angular's chunk optimization: with the lazy core chunk
gone the build fell under Angular's three-lazy-chunk threshold and the
initial bundle was split and grew.
Refs #339
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
A planning socket that closes after the server's first message now gives
a connection-lost incomplete calculation, shown as a warning with the
best valid plan kept, instead of the planner error alert. Closes the
server sends for a failed worker or a protocol violation (1003, 1007,
1008, 1009, 1011) and unparseable messages stay worker-error. Only the
close event decides, since an error event always precedes it and carries
no code. The liveness watchdog is unchanged.
Refs #330
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Rename TERMINAL to TERMINAL_MESSAGES and the shared error handler to
internalError, which no longer shadows its parameter. Describe the
browser cancellation check for server planning and its local fallback.
Refs #319
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Mark ADR 0011 as implemented, cite it where docs/statistics.md still
named the client-side planner as a constraint, and say that development
runs calculate locally because they have no build identifier.
Refs #319
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Each worker job (a plan, an incomplete-checkpoint explanation or a
counterfactual analysis) opens one same-origin socket at /api/planning
that carries the existing worker protocol as JSON. The Bun server runs
the unchanged planner worker in a Bun Worker per socket and terminates it
when the socket closes. The production build ships the worker as its own
entry point next to server.js.
On the client the socket is a second worker job, so liveness,
cancellation, checkpoints, explanations and supersession are unchanged.
Until the server first answers, a socket that fails, does not open
within 5 seconds or is closed falls back to a local worker and replays
the messages posted so far. A connection lost afterwards gives an
incomplete calculation with the retained plan, without a retry. Request
dates go out as Europe/Paris dates, as the core reads a Date.
Closes#320
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
When the repository owner comments @claude on a PR, run Claude Code
headless with the checked-in code-review skill and post its review as a
PR comment. Claude gets read-only tools and never holds the Gitea token.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Record ADR 0011 for issue #319: the Bun server runs the planner over a
WebSocket carrying the existing worker protocol, with the browser engine
as a fallback. Mark ADR 0002 and ADR 0006's in-browser requirement as
superseded.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Every commit on a branch with an open PR ran the whole pipeline twice, once
for the push and once for the pull_request event, in separate concurrency
groups. Filter the push trigger to develop, main and v* tags so other
branches run CI and publish their images only through their PR. Tags are
listed explicitly because a branch filter alone stops tag pushes.
Update the trigger, benchmark and image prose in the README and the Gitea
Actions guide to match.
Refs #309
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The expected wait sits near the middle of recent waits, so about half of
all runs pass it. Between the expected wait and the top of the range
shown before Calculate, the percentage now holds at 95% with no
remaining-time line; "Taking longer than expected" appears and is
announced only past that top.
Refs #300
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The overlay percentage now rises linearly to 95% at the expected wait
captured at Calculate, holds there, and shows 100% only when the planner
completes. Beneath the status, one line names the current planning stage
(with the rule name for rule stages) and another shows the approximate
remaining time, or "Taking longer than expected" once the wait is
exceeded, announced once through the live status. Cancel freezes the
percentage and hides both lines.
PlanningCalculationService reports the stage and submitted request
instead of fixed per-stage percentages; PlanningDurationService owns the
wait progress on a 250 ms tick.
Closes#300
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The relative gate calibrated once before the scenarios, so load that
started afterwards (the push and pull_request runs of one commit overlap
on the same runner, next to the test, build and image jobs) slowed the
scenarios but not the yardstick. A pull_request run failed `two years`
at 1653.1 ms against a 1648.7 ms budget this way.
The spec now repeats the calibration after the protocol and uses the
slower of the two values. The budgets can only loosen, never tighten,
and the log reprints the table with the budgets actually applied when
they change.
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Rendered waits after #302, in throttled headless Chromium, were well
below the shown ranges: two years waited 1.9 s against 3-24 s, three
years 4.5 s against 11-68 s, and the loaded year 4.0 s against 4-26 s.
The prior keeps its structure with refitted, rounded constants,
400 + 250 x (D/365.25)^0.5 x (P/30)^1.5 x R, which stays within about
1.2 times of all six measured configurations. Five years with 30 days
per year now shows 6-37 s instead of 44-265 s. Local refinement is
unchanged.
The 4x CPU throttle slows only the main thread, not the planning
worker, so phones can still wait longer than these desktop samples.
Part of #302.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A standing "no worse than the previous engine" check is not added to
CI: the differential check already fails on unintended changes, and a
fixed acceptance threshold would need renegotiating with every
deliberate change. Instead, the rebuild procedure now runs the
comparison while the frozen engine is still the previous one, and
records it with the change. The runner compares against the frozen
engine by default and takes `calibration` to reproduce the #302 record.
Part of #302.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Since assigning a date shares unchanged activations with the parent
state, counterfactual analysis edited an activation it shared with the
final plan, so a later alternative date could inherit an earlier one's
dates and be judged eligible. It now replaces the moved activation.
Every counterfactual over seeds 280000-289999 matches the engine before
the sharing step again.
When every one of several obligation solutions fails earned-entitlement
chronology, the planner again reports the obligation conflict, as when
every preview failed. No seeded request reaches that path, so the
frozen engine is unchanged.
Also marks the ranking's known limit as a shortcut and fixes stale
documentation found in review.
Part of #302.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
After #302, the development machine's protocol takes about 41 seconds
instead of 232. The budget multipliers now add about 1.5 times headroom
to the new ratios (0.1 for typed obligations, which leaves room for
runner jitter), and the hang guard drops from 600 to 240 seconds, with
a 210-second test timeout: about three times the expected run on
srvhome, which is about 1.9 times slower than nessar-desktop.
Part of #286 and #302. The gate still needs a passing CI benchmark on
two runners.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The frozen engine of the differential check is rebuilt from 8168137,
which plans from the best-ranked obligation solution, with the
documented build command. The check passes again, including its
cancelled asynchronous comparisons and generator-coverage assertions.
The calibration engine stays at a871f8f.
Part of #302.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With several obligation solutions, the planner ran the whole preference
chain on candidate solutions as previews: every solution after a
complete enumeration, or the eight best-ranked after a truncated window
search. It now orders all solutions by the existing pre-preference
ranking (active objectives, then tie-breaks, of each obligation-only
plan; equal ranks keep enumeration order) and runs the preference
stages once, on the first. If that run ends with earned leave available
only after its final merged time-off period, the stages restart on the
next solution, so a request that planned before never becomes a
conflict.
The loaded year drops from 43 to 5.5 seconds and typed obligations from
3.3 to 0.1 seconds, with byte-identical benchmark plans. Over the 5,000
seeded requests, 23 plans become worse (9 on a real objective) and 1
better; over 50 loaded-year-sized requests, 4 become worse on a real
objective. ADR 0010 records the decision; docs/benchmark/issue-302.md
records the comparison and the opt-in runner that reproduces it.
The frozen-engine check fails until the frozen engine is rebuilt from
this commit in the next one.
Part of #302.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Assigning a date copied every balance and every earned activation.
Balances and activations are only edited right after a state copies
them, so the new state now shares them with its parent, except the
balance it debits. Placement copying is unchanged.
Part of #302.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Every objective evaluation revalidated its optimization configuration.
Rule normalization already validates each configuration once per
calculation and keeps its own copy, the presets are constant, and the
summed variant of a valid configuration stays valid, so the core now
scores them without revalidating. evaluateOptimization still validates
for other callers.
Part of #302.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Each slice of the asynchronous adapter waited for a zero-delay timer:
about 1.1 ms in Bun, and at least 4 ms in browsers once timers nest.
Browsers now yield through a message-channel task. Bun runs port
messages ahead of timers and incoming worker messages, which starved
cancellation and heartbeats, so it yields with setImmediate. Both still
let queued cancellation and heartbeat tasks run between slices.
Part of #302.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Retaining a better valid plan reconciled its optimization provenance,
which evaluated every active objective once per credited placement with
that placement released. Only the credited objectives are compared, so
the released plan now evaluates just those and skips observing the
others. Retention also stops computing quality metrics that nothing
read. The retained plan and what Cancel returns are unchanged.
Part of #302.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The holiday-week stage ranked every placement as a donor once per
public-holiday week, although the ranking depends only on the plan. The
weeks of one plan now share each placement's released objectives; each
week still skips its own dates and walks the placements in the same
order with the same yields.
Part of #302.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The differential check's frozen bundle will be rebuilt for #302; the
relative gate keeps timing the unchanged a871f8f bundle so its ratios
stay comparable with the recorded history.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The generated HTML and Cobertura reports no longer show unmeasured
branch and function coverage as 100%. Poll and waitFor deadlines use
performance.now so frozen dates cannot make them loop forever, the
malformed-configuration test covers undefined again next to the empty
array, compose health checks honor PORT, and the migration spec lists
only what is still open.
Refs #291, #292, #293
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Pin Bun 1.4.3 with packageManager, and force every bun run script onto
the Bun runtime through bunfig so ng, ESLint and Prettier never fall
back to an installed Node. Type checking uses bun check for the
application and test projects, next to the Angular build.
CI jobs install the pinned release from a checksum-verified download
instead of npm and run project steps in a shell without Node on PATH,
which stays available only for the checkout and upload actions. The
image test's fake docker runs on Bun.
Refs #290, #293
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Angular's server build needs Node loader hooks that Bun does not apply,
and every route is client-rendered, so Angular now builds a client-only
bundle and a small Bun.serve server delivers it: hashed assets with the
one-year cache, index.html revalidated, extension-less routes falling
back to index.html, missing assets 404, traversal and malformed paths
rejected, and other methods 405. Express, @angular/ssr and the unused
hydration provider are removed. Both Docker stages use the pinned
oven/bun:1.4.3-alpine image without Node, and the health checks use
Bun's fetch.
Refs #292
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Replace Vitest with bun test across the whole suite. A preload compiles
components through Angular's JIT transform with inlined templates, sets
up jsdom, TestBed and zoneless change detection, and a small shim covers
the Vitest APIs bun:test lacks. Files run isolated, real-worker specs
spawn the running Bun, and line coverage from lcov is converted to the
existing HTML and Cobertura reports. The CI benchmark replaces its heap
cap with a container memory limit. Vitest, Jest, Nx and their Vite
configuration are removed.
Refs #291
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>