v1.3.0
A misspelt key was silently ignored: "quailty": 60 meant the default quality,
with nothing said about it, and the first sign was output that looked wrong.
Added
- A JSON Schema for the config, shipped in the
package atschema/poops-images.schema.json. Point$schemaat it and the
editor completes and checks the whole config as you type — see the Config
file section of the README for both the local and the GitHub URL. - Unknown config keys are named as they load:
[info] unknown key "quailty" — ignored. Valid: …, with the path for nested ones (in sizes[0]). Key names
only; a wrong type still throws where it always did. A schema file that
cannot be read leaves the config to load unadvised rather than taking the run
down over a warning.
Changed
- The config is validated once, in the
ImageProcessorconstructor, which is
the one place that cannot trust what it is handed — a library caller can
build a config without going through the file loader at all.loadConfig()
now returns the file as read, so anything reading a default off its result
before handing it to the processor seesundefinedwhere it used to see the
default. The CLI and the documentednew ImageProcessor(config)path behave
as they did, minus the duplicate warnings.
Full Changelog: v1.2.1...v1.3.0