• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

thumbor / thumbor-plugins / 40602683860
99%

Build:
DEFAULT BRANCH: master
Ran 27 Oct 2026 11:31PM UTC
Jobs 7
Files 14
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

27 Oct 2026 11:31PM UTC coverage: 99.387% (+0.04%) from 99.349%
40602683860

push

github

web-flow
fix(mozjpeg): run cjpeg without a shell and survive failures (#127)

The optimizer ran cjpeg through subprocess.call(shell=True) with a formatted
string and a shell redirect, ignoring the exit status. Nothing from the request
reaches that string (thumbor supplies the temp file names and the rest comes
from thumbor.conf), but the shell was unnecessary and a failure left
output_file empty, which thumbor turns into a 500 instead of serving the
unoptimized JPEG. There was no timeout either, and with the default
ENGINE_THREADPOOL_SIZE of 0 a slow run blocks the event loop.

cjpeg now runs as an argument list with -outfile instead of a redirect, under
MOZJPEG_TIMEOUT (default 30 seconds, 0 disables). A non-zero exit, an empty
output or a timeout logs a warning and copies the input over the output so
thumbor serves the original, and the TGA intermediate is removed in a finally
block so the timeout path cleans it up too. The timeout is converted when the
optimizer is built, since a quoted thumbor.conf value or --use-environment
yields a string, and a negative, infinite or non-numeric value disables the
optimizer with an error. Unit tests use a real temp directory and a fake
subprocess.run instead of patching os.path.isfile, os.access and os.unlink;
tearDown stopped the os.access and os.unlink mocks rather than their patchers,
so those patches were never undone.

24 of 24 new or added lines in 2 files covered. (100.0%)

324 of 326 relevant lines covered (99.39%)

0.99 hits per line

Jobs
ID Job ID Ran Files Coverage
1 run-optimizers/jp2 - 40602683860.1 27 Oct 2026 11:31PM UTC 2
91.67
GitHub Action Run
2 run-optimizers/pngcrush - 40602683860.2 27 Oct 2026 11:31PM UTC 2
100.0
GitHub Action Run
3 run-optimizers/gifv - 40602683860.3 27 Oct 2026 11:32PM UTC 2
100.0
GitHub Action Run
4 run-optimizers/pngquant - 40602683860.4 27 Oct 2026 11:32PM UTC 2
100.0
GitHub Action Run
5 run-optimizers/optipng - 40602683860.5 27 Oct 2026 11:32PM UTC 2
100.0
GitHub Action Run
6 run-optimizers/jpegrecompress - 40602683860.6 27 Oct 2026 11:32PM UTC 2
100.0
GitHub Action Run
7 run-optimizers/mozjpeg - 40602683860.7 27 Oct 2026 11:32PM UTC 2
100.0
GitHub Action Run
Source Files on build 40602683860
  • Tree
  • List 14
  • Changed 2
  • Source Changed 2
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #40602683860
  • e8cf217a on github
  • Prev Build on master (#40602467120)
  • Next Build on master (#40602763284)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc