On Sunday 25 October 2009 13:24:42 you wrote: > On Fri, 23 Oct 2009 09:36:53 -0500 Joseph Rawson wrote: > > Hi Joseph, > thanks for reporting this issue. > np :)
> [...] > > > I got this error while upgrading to sid today: > > > > /usr/lib/ruby/1.8/debian.rb:905:in `initialize': regular expression too > > big: (a long list of packages, separated with "|", then) > > > > > > (RegexpError) > > from /usr/lib/ruby/1.8/debian.rb:905:in `new' > > from /usr/lib/ruby/1.8/debian.rb:905:in `initialize' > > from /usr/sbin/apt-listbugs:995:in `new' > > from /usr/sbin/apt-listbugs:995:in `create' > > from /usr/sbin/apt-listbugs:1375 > > E: Sub-process /usr/sbin/apt-listbugs apt || exit 10 returned an error > > code (10) > > E: Failure running script /usr/sbin/apt-listbugs apt || exit 10 > > A package failed to install. Trying to recover: > > By looking at the error message you received, it seems that the large > number of packages to be upgraded caused an attempt to build too big a > regular expression. > How many packages were you trying to upgrade in one single step? > It was a bit over 3000 packages. I was upgrading from lenny to sid. > I don't think that the Ruby Regexp class has some hard-coded limitation > for the regular expression length. Can it be that it failed because it > went out of available memory? > What is the total capacity of the main memory on your system? > I have 3G of ram, and 4G of swap. Enough to hibernate if I ever get it working right on this laptop. Before running aptitude, I quit most of the applications and had plenty of spare ram. There was less than 500M in swap, also. > By looking at the code, the line of code that causes the issue is > basically > /usr/sbin/apt-listbugs:995 > (in apt-listbugs/0.0.89) > which is now moved to > /usr/share/apt-listbugs/apt-listbugs/logic.rb:806 > (in apt-listbugs/0.1.0 and in master branch on the git repository) > but is unchanged, as the substance of the rest of the create() method. > This means that upgrading to current apt-listbugs/0.1.0 won't probably > help in solving the issue. > > However, the error is actually generated by > /usr/lib/ruby/1.8/debian.rb:905 > (in package libdpkg-ruby1.8/0.3.2). > > I think that, if there's a way to cope with this issue (maybe by > splitting too long regular expressions into partial regular expressions > based on shorter package sub-lists?), it should be implemented at the > libdpkg-ruby1.8 level, rather than at the apt-listbugs level. > The regex created by apt-listbugs is a long concatenation of "or's", and it should be easy to split those up. I would assume it would be more difficult to split an arbitrary regex on the ruby level because it would be difficult to determine where to split the regex, or even if it was possible to do so. I'm no expert here, just adding my two cents. :) > I would like to hear from Ryan (the other co-maintainer of > apt-listbugs): if Ryan agrees with this analysis, I think the bug > should be re-assigned to libdpkg-ruby1.8 version 0.3.2 and fixed there. > > Ryan, what do you think? > -- Thanks: Joseph Rawson
signature.asc
Description: This is a digitally signed message part.