Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-flake8-builtins for 
openSUSE:Factory checked in at 2023-01-03 15:05:04
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-flake8-builtins (Old)
 and      /work/SRC/openSUSE:Factory/.python-flake8-builtins.new.1563 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-flake8-builtins"

Tue Jan  3 15:05:04 2023 rev:6 rq:1046240 version:2.1.0

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/python-flake8-builtins/python-flake8-builtins.changes
    2022-12-16 17:51:53.772098403 +0100
+++ 
/work/SRC/openSUSE:Factory/.python-flake8-builtins.new.1563/python-flake8-builtins.changes
  2023-01-03 15:05:18.906492262 +0100
@@ -1,0 +2,6 @@
+Mon Jan  2 16:38:17 UTC 2023 - Dirk Müller <[email protected]>
+
+- update to 2.1.0:
+  * Honor `--builtins` option from flake8
+
+-------------------------------------------------------------------

Old:
----
  flake8-builtins-2.0.1.tar.gz

New:
----
  flake8-builtins-2.1.0.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-flake8-builtins.spec ++++++
--- /var/tmp/diff_new_pack.SCsSAc/_old  2023-01-03 15:05:21.506507437 +0100
+++ /var/tmp/diff_new_pack.SCsSAc/_new  2023-01-03 15:05:21.514507484 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package python-flake8-builtins
 #
-# Copyright (c) 2022 SUSE LLC
+# Copyright (c) 2023 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -19,7 +19,7 @@
 %{?!python_module:%define python_module() python-%{**} python3-%{**}}
 %define skip_python2 1
 Name:           python-flake8-builtins
-Version:        2.0.1
+Version:        2.1.0
 Release:        0
 Summary:        Flake8 Builtins plugin
 License:        GPL-2.0-only
@@ -29,10 +29,10 @@
 BuildRequires:  %{python_module setuptools}
 BuildRequires:  fdupes
 BuildRequires:  python-rpm-macros
-Requires:       python-flake8 >= 6.0.0
+Requires:       python-flake8 >= 5.0.4
 BuildArch:      noarch
 # SECTION test requirements
-BuildRequires:  %{python_module flake8 >= 6.0.0}
+BuildRequires:  %{python_module flake8 >= 5.0.4}
 BuildRequires:  %{python_module hypothesis}
 BuildRequires:  %{python_module hypothesmith}
 BuildRequires:  %{python_module pytest}

++++++ flake8-builtins-2.0.1.tar.gz -> flake8-builtins-2.1.0.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flake8-builtins-2.0.1/CHANGES.rst 
new/flake8-builtins-2.1.0/CHANGES.rst
--- old/flake8-builtins-2.0.1/CHANGES.rst       2022-11-01 12:27:38.000000000 
+0100
+++ new/flake8-builtins-2.1.0/CHANGES.rst       2022-12-23 00:42:50.000000000 
+0100
@@ -3,6 +3,12 @@
 Changelog
 =========
 
+2.1.0 (2022-12-23)
+------------------
+
+- Honor `--builtins` option from flake8 #73.
+  [gforcada]
+
 2.0.1 (2022-11-01)
 ------------------
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flake8-builtins-2.0.1/PKG-INFO 
new/flake8-builtins-2.1.0/PKG-INFO
--- old/flake8-builtins-2.0.1/PKG-INFO  2022-11-01 12:27:39.000000000 +0100
+++ new/flake8-builtins-2.1.0/PKG-INFO  2022-12-23 00:42:50.000000000 +0100
@@ -1,13 +1,12 @@
 Metadata-Version: 2.1
 Name: flake8-builtins
-Version: 2.0.1
+Version: 2.1.0
 Summary: Check for python builtins being used as variables or parameters.
 Home-page: https://github.com/gforcada/flake8-builtins
 Author: Gil Forcada
 Author-email: [email protected]
 License: GPL version 2
 Keywords: pep8 flake8 python
-Platform: UNKNOWN
 Classifier: Development Status :: 5 - Production/Stable
 Classifier: Environment :: Console
 Classifier: Framework :: Flake8
@@ -104,7 +103,7 @@
 -------
 Install with pip::
 
-    $ pip install flake8-builtins
+    $ python -m pip install flake8-builtins
 
 Options
 -------
@@ -128,6 +127,12 @@
 Changelog
 =========
 
+2.1.0 (2022-12-23)
+------------------
+
+- Honor `--builtins` option from flake8 #73.
+  [gforcada]
+
 2.0.1 (2022-11-01)
 ------------------
 
@@ -356,5 +361,3 @@
 - Drop support for python 3.3, only python 2.7 and python 3.4 are tested.
   [gforcada]
 
-
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flake8-builtins-2.0.1/README.rst 
new/flake8-builtins-2.1.0/README.rst
--- old/flake8-builtins-2.0.1/README.rst        2022-11-01 12:27:38.000000000 
+0100
+++ new/flake8-builtins-2.1.0/README.rst        2022-12-23 00:42:50.000000000 
+0100
@@ -71,7 +71,7 @@
 -------
 Install with pip::
 
-    $ pip install flake8-builtins
+    $ python -m pip install flake8-builtins
 
 Options
 -------
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/flake8-builtins-2.0.1/flake8_builtins.egg-info/PKG-INFO 
new/flake8-builtins-2.1.0/flake8_builtins.egg-info/PKG-INFO
--- old/flake8-builtins-2.0.1/flake8_builtins.egg-info/PKG-INFO 2022-11-01 
12:27:38.000000000 +0100
+++ new/flake8-builtins-2.1.0/flake8_builtins.egg-info/PKG-INFO 2022-12-23 
00:42:50.000000000 +0100
@@ -1,13 +1,12 @@
 Metadata-Version: 2.1
 Name: flake8-builtins
-Version: 2.0.1
+Version: 2.1.0
 Summary: Check for python builtins being used as variables or parameters.
 Home-page: https://github.com/gforcada/flake8-builtins
 Author: Gil Forcada
 Author-email: [email protected]
 License: GPL version 2
 Keywords: pep8 flake8 python
-Platform: UNKNOWN
 Classifier: Development Status :: 5 - Production/Stable
 Classifier: Environment :: Console
 Classifier: Framework :: Flake8
@@ -104,7 +103,7 @@
 -------
 Install with pip::
 
-    $ pip install flake8-builtins
+    $ python -m pip install flake8-builtins
 
 Options
 -------
@@ -128,6 +127,12 @@
 Changelog
 =========
 
+2.1.0 (2022-12-23)
+------------------
+
+- Honor `--builtins` option from flake8 #73.
+  [gforcada]
+
 2.0.1 (2022-11-01)
 ------------------
 
@@ -356,5 +361,3 @@
 - Drop support for python 3.3, only python 2.7 and python 3.4 are tested.
   [gforcada]
 
-
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/flake8-builtins-2.0.1/flake8_builtins.egg-info/entry_points.txt 
new/flake8-builtins-2.1.0/flake8_builtins.egg-info/entry_points.txt
--- old/flake8-builtins-2.0.1/flake8_builtins.egg-info/entry_points.txt 
2022-11-01 12:27:38.000000000 +0100
+++ new/flake8-builtins-2.1.0/flake8_builtins.egg-info/entry_points.txt 
2022-12-23 00:42:50.000000000 +0100
@@ -1,3 +1,2 @@
 [flake8.extension]
 A00 = flake8_builtins:BuiltinsChecker
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flake8-builtins-2.0.1/flake8_builtins.py 
new/flake8-builtins-2.1.0/flake8_builtins.py
--- old/flake8-builtins-2.0.1/flake8_builtins.py        2022-11-01 
12:27:38.000000000 +0100
+++ new/flake8-builtins-2.1.0/flake8_builtins.py        2022-12-23 
00:42:50.000000000 +0100
@@ -48,6 +48,9 @@
         cls.names = {
             a[0] for a in inspect.getmembers(builtins) if a[0] not in 
cls.ignore_list
         }
+        flake8_builtins = getattr(options, 'builtins', None)
+        if flake8_builtins:
+            cls.names.update(flake8_builtins)
 
     def run(self):
         tree = self.tree
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flake8-builtins-2.0.1/requirements-lint.txt 
new/flake8-builtins-2.1.0/requirements-lint.txt
--- old/flake8-builtins-2.0.1/requirements-lint.txt     2022-11-01 
12:27:38.000000000 +0100
+++ new/flake8-builtins-2.1.0/requirements-lint.txt     2022-12-23 
00:42:50.000000000 +0100
@@ -12,7 +12,7 @@
     # via -r requirements-lint.in
 black==22.10.0
     # via -r requirements-lint.in
-certifi==2022.9.24
+certifi==2022.12.7
     # via requests
 charset-normalizer==2.1.1
     # via requests
@@ -83,12 +83,8 @@
     #   flake8-isort
 mccabe==0.7.0
     # via flake8
-mypy==0.982
-    # via -r requirements-lint.in
 mypy-extensions==0.4.3
-    # via
-    #   black
-    #   mypy
+    # via black
 packaging==21.3
     # via pytest
 pathspec==0.10.1
@@ -131,19 +127,16 @@
     # via
     #   black
     #   coverage
-    #   mypy
     #   pytest
 typed-ast==1.5.4 ; python_version < "3.8"
     # via
     #   -r requirements-lint.in
     #   black
-    #   mypy
 typing-extensions==4.4.0
     # via
     #   black
     #   gitpython
     #   importlib-metadata
-    #   mypy
 urllib3==1.26.12
     # via requests
 zipp==3.10.0 ; python_version < "3.8"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flake8-builtins-2.0.1/requirements.txt 
new/flake8-builtins-2.1.0/requirements.txt
--- old/flake8-builtins-2.0.1/requirements.txt  2022-11-01 12:27:38.000000000 
+0100
+++ new/flake8-builtins-2.1.0/requirements.txt  2022-12-23 00:42:50.000000000 
+0100
@@ -6,7 +6,7 @@
 #
 attrs==22.1.0
     # via pytest
-certifi==2022.9.24
+certifi==2022.12.7
     # via requests
 charset-normalizer==2.1.1
     # via requests
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flake8-builtins-2.0.1/run_tests.py 
new/flake8-builtins-2.1.0/run_tests.py
--- old/flake8-builtins-2.0.1/run_tests.py      2022-11-01 12:27:38.000000000 
+0100
+++ new/flake8-builtins-2.1.0/run_tests.py      2022-12-23 00:42:50.000000000 
+0100
@@ -10,13 +10,16 @@
 
 class FakeOptions:
     builtins_ignorelist = []
+    builtins = None
 
-    def __init__(self, ignore_list=''):
+    def __init__(self, ignore_list='', builtins=None):
         if ignore_list:
             self.builtins_ignorelist = ignore_list
+        if builtins:
+            self.builtins = builtins
 
 
-def check_code(source, expected_codes=None, ignore_list=None):
+def check_code(source, expected_codes=None, ignore_list=None, builtins=None):
     """Check if the given source code generates the given flake8 errors
 
     If `expected_codes` is a string is converted to a list,
@@ -24,6 +27,9 @@
 
     If `ignore_list` is provided, it should be a list of names
     that will be ignored if found, as if they were a builtin.
+
+    If `builtins` is provided, it should be a list of names
+    that will be reported if found, as if they were a builtin.
     """
     if isinstance(expected_codes, str):
         expected_codes = [expected_codes]
@@ -33,7 +39,7 @@
         ignore_list = []
     tree = ast.parse(textwrap.dedent(source))
     checker = BuiltinsChecker(tree, '/home/script.py')
-    checker.parse_options(FakeOptions(ignore_list=ignore_list))
+    checker.parse_options(FakeOptions(ignore_list=ignore_list, 
builtins=builtins))
     return_statements = list(checker.run())
 
     assert len(return_statements) == len(expected_codes)
@@ -212,6 +218,11 @@
     check_code(source, ignore_list=('copyright',))
 
 
+def test_flake8_builtins():
+    source = 'consider_this_builtin = 4'
+    check_code(source, ['A001'], builtins=('consider_this_builtin',))
+
+
 def test_for_loop_variable():
     source = """
     for format in (1, 2, 3):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/flake8-builtins-2.0.1/setup.py 
new/flake8-builtins-2.1.0/setup.py
--- old/flake8-builtins-2.0.1/setup.py  2022-11-01 12:27:38.000000000 +0100
+++ new/flake8-builtins-2.1.0/setup.py  2022-12-23 00:42:50.000000000 +0100
@@ -17,7 +17,7 @@
 
 setup(
     name='flake8-builtins',
-    version='2.0.1',
+    version='2.1.0',
     description=short_description,
     long_description=long_description,
     # Get more from https://pypi.org/classifiers/

Reply via email to