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

False positive on continue in finally block (Python 3.8) #3612

Closed
ethan-leba opened this issue May 11, 2020 · 0 comments
Closed

False positive on continue in finally block (Python 3.8) #3612

ethan-leba opened this issue May 11, 2020 · 0 comments

Comments

@ethan-leba
Copy link
Contributor

Steps to reproduce

Run pylint on the follow code:

for i in range(3):
    try:
        raise Exception()
    except Exception:
        pass
    finally:
        continue

Current behavior

Produces error: E0116: 'continue' not supported inside 'finally' clause (continue-in-finally)

Expected behavior

https://docs.python.org/3/whatsnew/3.8.html
As of Python 3.8, the above code will no longer throw a SyntaxError, so no error should be produced.

pylint --version output

pylint 2.5.2
astroid 2.4.1
Python 3.8.2 (default, Mar 11 2020, 00:29:30)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants