[DRE-maint] Bug#876768: ruby-pygments.rb: fails to run if RLIMIT_NOFILE is very high

James Cowgill jcowgill at debian.org
Mon Sep 25 16:44:57 UTC 2017


Package: ruby-pygments.rb
Version: 0.6.3-2
Severity: important
Control: affects -1 src:asciidoctor src:weechat
X-Debbugs-CC: weechat at packages.debian.org

Hi,

weechat recently FTBFS due to asciidoctor dying:
https://buildd.debian.org/status/fetch.php?pkg=weechat&arch=mips64el&ver=1.9.1-1&stamp=1506204287&raw=0

This happens because:
- The RLIMIT_NOFILE hard limit is set to a large value (eg 1048576).
- On startup, ruby-pygments's mentos.py attempts to close all files.
- Since RLIMIT_NOFILE is large, it will attempt to close 1 million file
  descriptors.
- The mips64el buildds are not powerful enough to complete this in the
  timeout time set in popen.rb (default 8 seconds).
- The pygments call fails, returns nil, and causes asciidoctor to crash.

I can occasionally reproduce this on an amd64 machine, but only under
heavy load (most of the time it's fast enough).

I think either the number of files to be closed should be limited, or
the piece of code which closes files should be removed altogether.

Thanks,
James

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-ruby-extras-maintainers/attachments/20170925/acbadb11/attachment.sig>


More information about the Pkg-ruby-extras-maintainers mailing list