Commit Graph
2 Commits
Author SHA1 Message Date
Hanif Koh fa1bd33511 Print the Comparison as UTF-8 and Fix Two Fingerprint Script Tests
compare now prints its report as UTF-8 with LF line ends on every
platform, as fingerprint already did. Redirected output on Windows uses
the ANSI code page, so the report was not UTF-8 there, and a slice name
outside that code page made compare fail as if its input were bad.
Standard output is switched only when something is written to it, so an
output file and an error message still work without one.

Two tests could not do their job. One created a file name with a
carriage return, which Windows refuses; it now fakes the folder listing.
The standard output test passed on Linux even without the code it
covers; it now prints a name outside ASCII to a Latin-1 standard output.

The docstrings no longer say the config block differs between two runs
of the same sources: it changes when an option is added.

None of this has run on Windows: CI runs these tests on Linux only.
2026-11-28 22:08:47 +08:00
Hanif Koh 5fd70d3301 Add a Script That Fingerprints Sweep G-code and Compares Two Sweeps
OrcaSlicer_profile_validator -s -o saves one G-code file per shipped
printer preset. gcode_fingerprint.py hashes each file without the lines
that differ between two runs of the same sources (the timestamp, the
config block and the object ids taken from a process-wide counter), and
reports which slices changed between two sweeps.

A slice whose output cannot repeat yet (fuzzy skin, random infill
rotation) is listed as not compared. A slice present in one sweep only
is listed and does not count as changed.
2026-11-28 22:08:47 +08:00