From: Petr Lautrbach <plautrba@redhat.com>
To: selinux@vger.kernel.org
Cc: Nicolas Iooss <nicolas.iooss@m4x.org>
Subject: Re: [large PATCH on GitHub] python/sepolgen: upgrade ply to release 3.11
Date: Fri, 04 Jan 2019 21:56:26 +0100 [thread overview]
Message-ID: <pjdmuogta4l.fsf@redhat.com> (raw)
In-Reply-To: <CAJfZ7=kwP5YkjSQssxLR9--uZgfa3MgyM7m4Dv9_Z34cac3HTQ@mail.gmail.com> (Nicolas Iooss's message of "Fri, 21 Dec 2018 21:53:42 +0100")
Nicolas Iooss <nicolas.iooss@m4x.org> writes:
> Hi,
> I tried to send a large patch to the mailing list but it did not seem
> to work. Therefore I opened
> https://github.com/SELinuxProject/selinux/pull/117 and send now a
> smaller version below.
> Cheers,
> Nicolas
I've ran several tests on this and since everything worked for me, I've
merged it. Thanks!
> ----------------
>
> PLY (Python Lex-Yacc) 3.11 has been released in February 2018:
> - http://www.dabeaz.com/ply/index.html
> - https://github.com/dabeaz/ply/releases/tag/3.11
>
> Copy lex.py and yacc.py from this new release.
>
> This fixes the following warning from "make test":
>
> python run-tests.py
> ../src/./sepolgen/lex.py:634: DeprecationWarning: Using or importing
> the ABCs from 'collections' instead of from 'collections.abc' is
> deprecated, and in 3.8 it will stop working
> if isinstance(t, collections.Callable):
>
> (Python 3.3 moved collections.Callable to collections.abc.Callable)
>
> Signed-off-by: Nicolas Iooss <nicolas.iooss@m4x.org>
> ---
> python/sepolgen/src/sepolgen/lex.py | 1298 ++++---
> python/sepolgen/src/sepolgen/yacc.py | 4930 ++++++++++++++++----------
> scripts/run-flake8 | 4 +-
> 3 files changed, 3872 insertions(+), 2360 deletions(-)
>
> diff --git a/python/sepolgen/src/sepolgen/lex.py
> b/python/sepolgen/src/sepolgen/lex.py
> index c13acef0507a..f95bcdbf1bb5 100644
> --- a/python/sepolgen/src/sepolgen/lex.py
> +++ b/python/sepolgen/src/sepolgen/lex.py
> [Diff available on https://github.com/SELinuxProject/selinux/pull/117/files ]
>
> diff --git a/python/sepolgen/src/sepolgen/yacc.py
> b/python/sepolgen/src/sepolgen/yacc.py
> index afef174849f2..88188a1e8ead 100644
> --- a/python/sepolgen/src/sepolgen/yacc.py
> +++ b/python/sepolgen/src/sepolgen/yacc.py
> [Diff available on https://github.com/SELinuxProject/selinux/pull/117/files ]
>
> diff --git a/scripts/run-flake8 b/scripts/run-flake8
> index 207edd20dd89..6ad029fa6852 100755
> --- a/scripts/run-flake8
> +++ b/scripts/run-flake8
> @@ -17,10 +17,8 @@ IGNORE_LIST="$IGNORE_LIST,E101" # indentation
> contains mixed spaces and tabs
> IGNORE_LIST="$IGNORE_LIST,E711" # comparison to None should be 'if
> cond is not None:'
> IGNORE_LIST="$IGNORE_LIST,E712" # comparison to False should be 'if
> cond is False:' or 'if not cond:'
> IGNORE_LIST="$IGNORE_LIST,E722" # do not use bare 'except'
> -IGNORE_LIST="$IGNORE_LIST,E999" # TabError: inconsistent use of tabs
> and spaces in indentation
>
> IGNORE_LIST="$IGNORE_LIST,F401" # module imported but unused
> -IGNORE_LIST="$IGNORE_LIST,F812" # list comprehension redefines 'f',
> in lex.py and yacc.py
> IGNORE_LIST="$IGNORE_LIST,F841" # local variable '...' is assigned to
> but never used
>
>
> @@ -75,4 +73,4 @@ IGNORE_LIST="$IGNORE_LIST,F405" # '...' may be
> undefined, or defined from star i
> IGNORE_LIST="$IGNORE_LIST,F811" # redefinition of unused ...
>
>
> -exec flake8 --max-line-length=120
> --builtins='_,unicode,lextab,parsetab' --ignore=",$IGNORE_LIST" "$@"
> +exec flake8 --max-line-length=120 --builtins='_,basestring,unicode'
> --ignore=",$IGNORE_LIST" "$@"
> --
prev parent reply other threads:[~2019-01-04 20:56 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-21 20:53 [large PATCH on GitHub] python/sepolgen: upgrade ply to release 3.11 Nicolas Iooss
2019-01-04 20:56 ` Petr Lautrbach [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=pjdmuogta4l.fsf@redhat.com \
--to=plautrba@redhat.com \
--cc=nicolas.iooss@m4x.org \
--cc=selinux@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox