Skip to content

fix imagemagick command try#214

Merged
eylles merged 8 commits intomasterfrom
fix-wal-command-try
Jan 31, 2026
Merged

fix imagemagick command try#214
eylles merged 8 commits intomasterfrom
fix-wal-command-try

Conversation

@eylles
Copy link
Owner

@eylles eylles commented Jan 30, 2026

This ought to now make this work correctly as the first imagemagick command invokation with a successful color generation will break the loop.

yes the fix was this simple...

fixes #198, #205, #212 without impacting #190 and #195

This ought to now make this work correctly as the first imagemagick command
invokation with a successful color generation will break the loop.
NecRaul and others added 7 commits January 30, 2026 17:14
- Rename `try_gen_in_range` to `gen_colors_with_command`.
- Replace hardcoded loop values with `beginning_color_count` and `iteration_count`.
- Use `max_color_count` for clearer error logging logic.
- Pre-compile hex regex pattern for better performance.
- Move hex extraction and validation logic from gen_colors to gen_colors_with_command.
- Use list.extend() for palette concatenation.
- Simplify return value to provide hex colors directly.
- Swap if/else logic to handle intermediate retries vs. final exhaustion.
- Improve logging messages by including the specific magick_command used.
- Change conditional check in the concatenation loop to use len(hex_colors) < 16.
- Remove unnecessary try/except block around color generation.
- Return hex colors immediately upon successful generation.
- Raise a RuntimeError if all ImageMagick commands fail to produce a palette.
- Clean up redundant logging and flow control.
This keeps pylint and pyslp happy
That library is not used in the backend at all
@eylles eylles merged commit 2cce762 into master Jan 31, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Some images don't work properly

2 participants