On Wed, Oct 21, 2015 at 8:00 PM, Luis San Martin <lsanmart...@gmail.com> wrote: > Hello, > > It seems asyncio syntax is not considered for python 3.5. I couldn't > find any reported issue regarding this > > i.e. > > I'm on flake8 (2.4.1) with python 3.5.0. Just cloned > https://github.com/dabeaz/curio.git and got this. > > pathcl@sid:~/src/curio$ flake8 ./curio/file.py > > Traceback (most recent call last): > File "/home/pathcl/.pyenv/versions/3.5.0/bin/flake8", line 11, in <module> > sys.exit(main()) > File > "/home/pathcl/.pyenv/versions/3.5.0/lib/python3.5/site-packages/flake8/main.py", > line 33, in main > report = flake8_style.check_files() > File > "/home/pathcl/.pyenv/versions/3.5.0/lib/python3.5/site-packages/pep8.py", > line 1672, in check_files > runner(path) > File > "/home/pathcl/.pyenv/versions/3.5.0/lib/python3.5/site-packages/flake8/engine.py", > line 95, in input_file > return fchecker.check_all(expected=expected, line_offset=line_offset) > File > "/home/pathcl/.pyenv/versions/3.5.0/lib/python3.5/site-packages/pep8.py", > line 1412, in check_all > self.check_ast() > File > "/home/pathcl/.pyenv/versions/3.5.0/lib/python3.5/site-packages/pep8.py", > line 1358, in check_ast > checker = cls(tree, self.filename) > File > "/home/pathcl/.pyenv/versions/3.5.0/lib/python3.5/site-packages/flake8/_pyflakes.py", > line 43, in __init__ > withDoctest=self.withDoctest) > File > "/home/pathcl/.pyenv/versions/3.5.0/lib/python3.5/site-packages/pyflakes/checker.py", > line 294, in __init__ > self.handleChildren(tree) > File > "/home/pathcl/.pyenv/versions/3.5.0/lib/python3.5/site-packages/pyflakes/checker.py", > line 547, in handleChildren > self.handleNode(node, tree) > File > "/home/pathcl/.pyenv/versions/3.5.0/lib/python3.5/site-packages/pyflakes/checker.py", > line 589, in handleNode > handler(node) > File > "/home/pathcl/.pyenv/versions/3.5.0/lib/python3.5/site-packages/pyflakes/checker.py", > line 812, in CLASSDEF > self.handleNode(stmt, node) > File > "/home/pathcl/.pyenv/versions/3.5.0/lib/python3.5/site-packages/pyflakes/checker.py", > line 588, in handleNode > handler = self.getNodeHandler(node.__class__) > File > "/home/pathcl/.pyenv/versions/3.5.0/lib/python3.5/site-packages/pyflakes/checker.py", > line 458, in getNodeHandler > self._nodeHandlers[node_class] = handler = getattr(self, nodeType) > AttributeError: 'FlakesChecker' object has no attribute 'ASYNCFUNCTIONDEF' > > What is going wrong?
Flake8 takes the somewhat controversial stance of being stable rather than being able to handle all the things in one version. The 2.4.x series of Flake8 restricts itself to known working versions of pep8 and pyflakes (neither of which can handle 3.5 or the new syntax added in it). Flake8 2.5.0 will raise the cap on pyflakes to allow this to work but there is no current release of pep8 that is compatible with the version specifier that Flake8 carries for stability and will also work with Python 3.5.0 (note, you will merely see a Deprecation Warning due to currently released versions of pep8 using inspect.getargspec which is fixed in master). Because of how late in the week it is, I'm going to put off a Flake8 2.5.0 release until Monday so that in the event this causes people's continuous integration to fail, they're not scrambling to do it tomorrow or over the weekend. (See also responsible release practices.) Cheers, Ian _______________________________________________ code-quality mailing list code-quality@python.org https://mail.python.org/mailman/listinfo/code-quality