Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AttributeError: 'listiterator' object has no attribute 'next' #1408

ghost opened this issue Mar 14, 2016 · 2 comments

AttributeError: 'listiterator' object has no attribute 'next' #1408

ghost opened this issue Mar 14, 2016 · 2 comments


Copy link

@ghost ghost commented Mar 14, 2016

Originally reported by: Anonymous

While stopping service cherrypy logged error:

ERR 2016-03-12 20:48:32,460 cherrypy.error.140129365106640 11286 'CP Server Thread-7' : [12/Mar/2016:20:48:32]  Traceback (most recent call last):
  File "site-packages/cherrypy/", line 180, in trap
  File "site-packages/cherrypy/", line 277, in next
AttributeError: 'listiterator' object has no attribute 'next'

@ghost ghost added minor bug engine labels Apr 30, 2016
Copy link

@jaraco jaraco commented May 1, 2016

I'm surprised that this would happen - it seems by my reading of the code that attribute .next is only accessed on Python 2, and even on Python 2.7.10, a listiterator does have the next attribute. Still, now that Python 2.6 is required, this issue should be straightforward to fix.

@jaraco jaraco closed this in 0202bb1 May 1, 2016
Copy link

@capitalterefe capitalterefe commented Dec 31, 2017

use __next__() instead if you are on Python 3

@cherrypy cherrypy locked as resolved and limited conversation to collaborators Dec 31, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.