[OpenStack-Infra] Regression in JJB 1.4.0 maximum recursion depth exceeded

Thanh Ha thanh.ha at linuxfoundation.org
Fri Jan 8 21:45:22 UTC 2016


(I truncated some of the repetitive output below)

I just tried with the -o argument and seems like it passes. I guess it only
affects stdout output, good to know.

We're using python 2.7.5 in production. I did some testing today with
Python 3.4.3 and it seems the 3.4.x stream at least doesn't run into this
issue so I'm guessing this only affects Python 2.7.x.

Regards,

Thanh


On 8 January 2016 at 12:44, Wayne Warren <wayne at puppetlabs.com> wrote:

> Hey Thanh,
>
> Looking at that stack trace and the command that causes it, it appears
> that the object whose encoding is being accessed is "sys.stdout" [1]
>
> I would suggest trying to pass a specific "-o" argument to the "test"
> subcommand to see if the stream.encoding __getattr__ recursion happens
> there also.
>
> Also, what specific minor version of Python are you using?
>
> [1]
> https://review.openstack.org/gitweb?p=openstack-infra/jenkins-job-builder.git;a=blob;f=jenkins_jobs/cmd.py;h=efafdf05fa35f93a00633489dde160c06930641d;hb=b023d7e23f77e4de33e740dcc37af911e36fb189#l115
>
> On Thu, Jan 7, 2016 at 5:40 PM, Thanh Ha <thanh.ha at linuxfoundation.org>
> wrote:
> > Hi JJB Devs,
> >
> > We discovered what seems to be a regression with JJB 1.4.0 which after
> some
> > git bisecting found it was caused by this patch [1]. My Jenkins verify
> > builds are failing to pass due to python runtime error:
> >
> >     RuntimeError: maximum recursion depth exceeded
> >
> > This error follows what seems to be a recursive loop of python codecs
> > __getattr__ attempts. I've pasted the full traceback below. This issue
> seems
> > to only affect the command "jenkins-jobs test --recursive /path/to/jobs"
> and
> > when as part of a Jenkins verify job. Oddly enough running "jenkins-jobs
> > update --recursive /path/to/jobs" seems to pass just fine.
> >
> > Any ideas how to fix or workaround this issue?  (This issue is
> preventing us
> > from upgrading to JJB 1.4.0)
> >
> > Thanks,
> >
> > Thanh
> >
> > [1] https://review.openstack.org/183939/
> >
> >
> > Traceback (most recent call last):
> >   File "/tmp/jjbtest/jjb/bin/jenkins-jobs", line 11, in <module>
> >     sys.exit(main())
> >   File
> "/tmp/jjbtest/jjb/lib/python2.7/site-packages/jenkins_jobs/cmd.py",
> > line 172, in main
> >     execute(options, config)
> >   File
> "/tmp/jjbtest/jjb/lib/python2.7/site-packages/jenkins_jobs/cmd.py",
> > line 337, in execute
> >     output=options.output_dir)
> >   File
> > "/tmp/jjbtest/jjb/lib/python2.7/site-packages/jenkins_jobs/builder.py",
> line
> > 326, in update_job
> >     output = utils.wrap_stream(output)
> >   File
> "/tmp/jjbtest/jjb/lib/python2.7/site-packages/jenkins_jobs/utils.py",
> > line 25, in wrap_stream
> >     stream_enc = stream.encoding
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> >   File "/tmp/jjbtest/jjb/lib64/python2.7/codecs.py", line 828, in
> > __getattr__
> >     return getattr(self.stream, name)
> > ...
> > RuntimeError: maximum recursion depth exceeded
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-infra/attachments/20160108/7863f19c/attachment.html>


More information about the OpenStack-Infra mailing list