JobEngine claims queued jobs atomically, persists progress at most every
checkpoint interval, stops a handler when its job is cancelled or paused
elsewhere and requeues jobs a crash left running.
Also installs the SQLite import resolver under a lock so a concurrent
first caller cannot reach a P/Invoke before the resolver is in place.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
- SQLite restore holds every pool slot instead of the write lock first,
removing a lock-order deadlock with sessions that begin to write.
- PostgreSQL sessions always return their connection on dispose, a
rollback while disposing never masks the original exception, and a
busy session keeps its transaction until it is discarded.
- The pool disposes a connection whose health check the caller cancels.
- Listener commands keep their lock until the server answers and never
tear a write with the caller's token; closing and pending no longer race.
- Tag replacement locks the sequence and the tag row; unused-tag cleanup
locks candidates and re-checks them with a fresh snapshot; render
counts and stats refreshes lock the sequence row on PostgreSQL.
- Sequence upserts keep rendered_count, which renders maintain.
- AuthenticationOk after an unfinished SCRAM exchange is rejected.
- Oversized read buffers are released; failed backups leave no .tmp;
a zero idle lifetime is rejected.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
Windows-only tests load the real theme on an STA dispatcher, render each
control in both themes, check the card fits the default grid slot, the
wrap panel keeps containers bounded over half a million items, preview
zoom modes and segment positions, and asynchronous filmstrip loading.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
Pin bytea_output=hex and standard_conforming_strings=on in the startup
packet instead of tracking ParameterStatus values nobody read, so the
legacy bytea escape decoder goes away. A PostgreSQL connection now
refuses a new command while a row stream is still open, and the pool
discards such a connection. Drop unused SQLite declarations.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
EncodeRow8/16 reuse one pooled scratch row for RGB-to-gray output
instead of allocating per row; drop unused JPEG marker constants; the
24 MP timing test skips itself when the JIT optimiser is disabled.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
Single-strip uncompressed files (Photoshop's default) exceed
TiffReader's bounded read; such strips are now read in pieces, the
uncompressed path skips a copy, and hostile strip/tile counts are
rejected up front.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
Two-pass Lanczos3 (downscale, support stretched by the reduction) and
Catmull-Rom (upscale) with normalised, edge-folded weights; exact
area-average box path for thumbnails; pass order chosen by cost,
Vector<float> inner loops, parallel rows. Tests cover constant images,
energy preservation, step ringing against the kernel's exact discrete
bound, Exif orientations and dithering.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
Shared abstract suites run against in-memory/temp-file SQLite and, with
TITANO_TEST_PG, a private PostgreSQL schema per test: migration
idempotency and version refusal, keyset paging with ties for every sort,
statistics, exclusive job claiming under 8 concurrent claimers, and the
100k-frame bulk insert under 15 s.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
16-bit LinearRaw DNG 1.4 with tiles (lossless JPEG or uncompressed),
ColorMatrix1 = XYZ(D65) to linear sRGB, ForwardMatrix1 to XYZ(D50),
D65 illuminant, neutral AsShotNeutral, WhiteLevel 65535 and optional
Exif. LibRaw renders test patches back to the exact source values.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
TiffImageReader decodes strips and tiles (chunky or planar) with none,
LZW (old-style bit order tolerated), Deflate, PackBits and JPEG
compression (JPEGTables, YCbCr or RGB, lossless SOF3 tiles reshaped as
DNG writes them), predictors 2/3 and the DNG x2/x4 variants, 1-16 bit
integer and 16/32-bit float samples; tiles decode in parallel. Output
is a raw TiffRaster or a linear ImageBuffer. JPEG strips match libtiff
bit for bit.
TiffWriter writes 8/16-bit gray/RGB/RGBA, uncompressed or Deflate with
horizontal predictor, and embeds capture metadata from an Exif block.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
CR3 and HEIC/AVIF parsing (irot/imir orientation table, multi-extent
XMP), the box walker's edge cases, RAF/WebP/PNG/GIF/BMP/JPEG XL/JPEG XR,
ExifWriter round trips through MetadataReader, and robustness: 200
truncations plus 500 seeded corruptions per fixture with no exception
or parser fault, previews always inside the file, 50 MB DNG and CR3
read with well under 512 KB, 2,000 JPEG headers under 2 s,
cancellation and shared file access.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
Signature table for every format and tie-break; every FrameMetadata
field from JPEG in both byte orders; timestamp fallbacks (digitized,
XMP, GPS, file time), sub-seconds and offsets, orientation, ISO and
APEX rules, GPS validation; XMP attribute/element forms, priority, DTD
refusal, size cap and extended-XMP reassembly; CR2/NEF/DNG/ARW/ORF/RW2
main-image selection, previews with real sizes and MakerNote fallbacks.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
IfdSpec/TiffFile emit TIFF structures in either byte order with child
IFDs, data blobs and position-dependent MakerNote IFDs; JpegBuilder
emits SOI/APPn/MPF/SOF/SOS/EOI with extended XMP; Box helpers build
ISO-BMFF, RIFF and PNG chunks. Fixtures cover JPEG, CR2, NEF, DNG,
ARW, ORF, RW2, CR3, HEIC, AVIF, RAF, WebP and PNG around one canonical
camera, plus sparse and counting streams for I/O-bound tests.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
Extracted files land in a staging folder inside the target and are moved into
place with backups of replaced files; a failed move rolls everything back.
Removal deletes only logged payload paths and prunes folders left empty.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
Installer payload appended to the setup program: JSON manifest (components,
files with size/SHA-256/offsets/mtime, shortcuts, file types) plus deflate or
stored entries and a 64-byte footer with the manifest hash. The reader finds
the footer before an Authenticode table, validates every offset, rejects
unsafe paths and bounds inflation by the declared size; the writer is
deterministic, deduplicates identical content and strips a signed stub.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
The flow median filter runs the odd-even transposition network on
Vector<float> blocks in the interior (shared with the temporal median),
which removes the dominant cost of Best-quality flow. The stabiliser
analyses its nine patches in parallel with one correlator each and
gathers results in patch order, so output stays deterministic. Adds
brute-force reference tests for the median, box and binomial kernels.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
Metadata steps are verified against the detrended measured jump; only
received steps are removed, the step-free series deflickered and the
steps restored as smoothstep transitions that lengthen until no frame
step exceeds 0.3 EV.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
Horizon from the strongest column-averaged row step (median over
frames), refined per column by a dynamic-programming path and feathered;
Otsu luminance fallback with morphology; confidences for both. Region
deflicker fits sky and land separately and blends through the mask.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
Robust LOWESS target curve with intentional exposure offsets removed,
blended by Tukey weight and surviving-window fraction; flicker spectrum
from the autocorrelation of detrended luminance recommends a window of
four periods.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
Known-answer fixtures: brightness ramp, seeded global/sky/land flicker,
metadata and pixel exposure steps, horizon split, colour temperature
drift and white-balance jitter, star field, black/white/duplicate
frames, gaps and clock shifts. Covers frame statistics (CCT against
exact blackbody chromaticities) and the light analyzer with it.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
Shared session tests run on SQLite and PostgreSQL (types, nulls,
placeholders, transactions, constraint errors, COPY/bulk escaping,
cancellation). PostgreSQL tests cover SCRAM/MD5/cleartext/trust auth,
TLS, result decoding, bytea, LISTEN/NOTIFY, error mapping, pooling and
broken-connection recovery, and the statement cache. In-memory SQLite
now pools shared-cache connections and retries SQLITE_LOCKED.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
Every colour type and bit depth (1/2/4/8/16), PLTE + tRNS (palette alpha
and colour keys), Adam7, all five filters, zlib via ZLibStream; CRC
mismatches and truncated data are tolerated with warnings. PngEncoder
gains an additive ImageBuffer overload (8/16-bit sRGB with sRGB chunk)
and the Palette colour type for decoding.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
SleepBlocker requests ES_CONTINUOUS | ES_SYSTEM_REQUIRED (optionally the
display) from a dedicated thread, because the execution state belongs to the
calling thread; disposing from any thread clears it.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
DwmWindow sets dark mode (attribute 20, 19 on older Windows 10), Mica/none
backdrop, corner preference and caption/border colours, returning false for
null or stale windows and unsupported builds. SystemTheme reads
AppsUseLightTheme and the accent colour (DWM AccentColor, else
DwmGetColorizationColor); SystemThemeWatcher raises Changed from a
RegNotifyChangeKeyValue thread when either value actually changes.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
Dpapi.Protect/Unprotect wrap CryptProtectData/CryptUnprotectData in the
current-user scope with optional entropy and no UI; decrypted native buffers
are zeroed before LocalFree. String helpers return Base64 for JSON settings.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC