From solipsis at pitrou.net Sun Jan 1 04:09:52 2017 From: solipsis at pitrou.net (solipsis at pitrou.net) Date: Sun, 01 Jan 2017 09:09:52 +0000 Subject: [Python-checkins] Daily reference leaks (ad06f9acff92): sum=-3 Message-ID: <20170101090952.25906.14332.36FCCA76@psf.io> results for ad06f9acff92 on branch "default" -------------------------------------------- test_collections leaked [0, 0, -7] memory blocks, sum=-7 test_functools leaked [0, 3, 1] memory blocks, sum=4 Command line was: ['./python', '-m', 'test.regrtest', '-uall', '-R', '3:3:/home/psf-users/antoine/refleaks/reflogstmTec', '--timeout', '7200'] From python-checkins at python.org Sun Jan 1 12:08:27 2017 From: python-checkins at python.org (serhiy.storchaka) Date: Sun, 01 Jan 2017 17:08:27 +0000 Subject: [Python-checkins] =?utf-8?b?Y3B5dGhvbiAoMi43KTogSXNzdWUgIzI5MDk0?= =?utf-8?q?=3A_Offsets_in_a_ZIP_file_created_with_extern_file_object_and_m?= =?utf-8?q?odes?= Message-ID: <20170101170826.25630.68510.3C0707A8@psf.io> https://hg.python.org/cpython/rev/342bc734f523 changeset: 105919:342bc734f523 branch: 2.7 parent: 105917:1d5b4426fe87 user: Serhiy Storchaka date: Sun Jan 01 19:04:09 2017 +0200 summary: Issue #29094: Offsets in a ZIP file created with extern file object and modes "w" now are relative to the start of the file. files: Lib/zipfile.py | 2 +- Misc/NEWS | 3 +++ 2 files changed, 4 insertions(+), 1 deletions(-) diff --git a/Lib/zipfile.py b/Lib/zipfile.py --- a/Lib/zipfile.py +++ b/Lib/zipfile.py @@ -772,7 +772,7 @@ # set the modified flag so central directory gets written # even if no files are added to the archive self._didModify = True - self._start_disk = self.fp.tell() + self._start_disk = 0 elif key == 'a': try: # See if file is a zip file diff --git a/Misc/NEWS b/Misc/NEWS --- a/Misc/NEWS +++ b/Misc/NEWS @@ -15,6 +15,9 @@ Library ------- +- Issue #29094: Offsets in a ZIP file created with extern file object and mode + "w" now are relative to the start of the file. + - Issue #13051: Fixed recursion errors in large or resized curses.textpad.Textbox. Based on patch by Tycho Andersen. -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 12:08:27 2017 From: python-checkins at python.org (serhiy.storchaka) Date: Sun, 01 Jan 2017 17:08:27 +0000 Subject: [Python-checkins] =?utf-8?b?Y3B5dGhvbiAoMy41KTogSXNzdWUgIzI5MDk0?= =?utf-8?q?=3A_Offsets_in_a_ZIP_file_created_with_extern_file_object_and_m?= =?utf-8?q?odes?= Message-ID: <20170101170826.10284.71332.9018FE07@psf.io> https://hg.python.org/cpython/rev/f5aa1c9c2b7e changeset: 105918:f5aa1c9c2b7e branch: 3.5 parent: 105914:bb64ae455490 user: Serhiy Storchaka date: Sun Jan 01 19:00:30 2017 +0200 summary: Issue #29094: Offsets in a ZIP file created with extern file object and modes "w" and "x" now are relative to the start of the file. files: Lib/zipfile.py | 5 +++-- Misc/NEWS | 3 +++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Lib/zipfile.py b/Lib/zipfile.py --- a/Lib/zipfile.py +++ b/Lib/zipfile.py @@ -1028,11 +1028,12 @@ # set the modified flag so central directory gets written # even if no files are added to the archive self._didModify = True + self._start_disk = 0 try: - self.start_dir = self._start_disk = self.fp.tell() + self.start_dir = self.fp.tell() except (AttributeError, OSError): self.fp = _Tellable(self.fp) - self.start_dir = self._start_disk = 0 + self.start_dir = 0 self._seekable = False else: # Some file-like objects can provide tell() but not seek() diff --git a/Misc/NEWS b/Misc/NEWS --- a/Misc/NEWS +++ b/Misc/NEWS @@ -140,6 +140,9 @@ Library ------- +- Issue #29094: Offsets in a ZIP file created with extern file object and modes + "w" and "x" now are relative to the start of the file. + - Issue #13051: Fixed recursion errors in large or resized curses.textpad.Textbox. Based on patch by Tycho Andersen. -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 12:08:29 2017 From: python-checkins at python.org (serhiy.storchaka) Date: Sun, 01 Jan 2017 17:08:29 +0000 Subject: [Python-checkins] =?utf-8?b?Y3B5dGhvbiAobWVyZ2UgMy41IC0+IDMuNik6?= =?utf-8?q?_Issue_=2329094=3A_Offsets_in_a_ZIP_file_created_with_extern_fi?= =?utf-8?q?le_object_and_modes?= Message-ID: <20170101170828.54628.49.8E8802DB@psf.io> https://hg.python.org/cpython/rev/f36f9bce997d changeset: 105920:f36f9bce997d branch: 3.6 parent: 105915:0331420d6cba parent: 105918:f5aa1c9c2b7e user: Serhiy Storchaka date: Sun Jan 01 19:05:29 2017 +0200 summary: Issue #29094: Offsets in a ZIP file created with extern file object and modes "w" and "x" now are relative to the start of the file. files: Lib/zipfile.py | 5 +++-- Misc/NEWS | 3 +++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Lib/zipfile.py b/Lib/zipfile.py --- a/Lib/zipfile.py +++ b/Lib/zipfile.py @@ -1102,11 +1102,12 @@ # set the modified flag so central directory gets written # even if no files are added to the archive self._didModify = True + self._start_disk = 0 try: - self.start_dir = self._start_disk = self.fp.tell() + self.start_dir = self.fp.tell() except (AttributeError, OSError): self.fp = _Tellable(self.fp) - self.start_dir = self._start_disk = 0 + self.start_dir = 0 self._seekable = False else: # Some file-like objects can provide tell() but not seek() diff --git a/Misc/NEWS b/Misc/NEWS --- a/Misc/NEWS +++ b/Misc/NEWS @@ -40,6 +40,9 @@ Library ------- +- Issue #29094: Offsets in a ZIP file created with extern file object and modes + "w" and "x" now are relative to the start of the file. + - Issue #29085: Allow random.Random.seed() to use high quality OS randomness rather than the pid and time. -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 18:43:23 2017 From: python-checkins at python.org (serhiy.storchaka) Date: Sun, 01 Jan 2017 23:43:23 +0000 Subject: [Python-checkins] =?utf-8?q?cpython_=28merge_3=2E6_-=3E_default?= =?utf-8?q?=29=3A_Issue_=2329094=3A_Offsets_in_a_ZIP_file_created_with_ext?= =?utf-8?q?ern_file_object_and_modes?= Message-ID: <20170101234323.123978.5306.73DDB252@psf.io> https://hg.python.org/cpython/rev/a80c14ace927 changeset: 105921:a80c14ace927 parent: 105916:ad06f9acff92 parent: 105920:f36f9bce997d user: Serhiy Storchaka date: Mon Jan 02 01:43:02 2017 +0200 summary: Issue #29094: Offsets in a ZIP file created with extern file object and modes "w" and "x" now are relative to the start of the file. files: Lib/zipfile.py | 5 +++-- Misc/NEWS | 3 +++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Lib/zipfile.py b/Lib/zipfile.py --- a/Lib/zipfile.py +++ b/Lib/zipfile.py @@ -1101,11 +1101,12 @@ # set the modified flag so central directory gets written # even if no files are added to the archive self._didModify = True + self._start_disk = 0 try: - self.start_dir = self._start_disk = self.fp.tell() + self.start_dir = self.fp.tell() except (AttributeError, OSError): self.fp = _Tellable(self.fp) - self.start_dir = self._start_disk = 0 + self.start_dir = 0 self._seekable = False else: # Some file-like objects can provide tell() but not seek() diff --git a/Misc/NEWS b/Misc/NEWS --- a/Misc/NEWS +++ b/Misc/NEWS @@ -208,6 +208,9 @@ Library ------- +- Issue #29094: Offsets in a ZIP file created with extern file object and modes + "w" and "x" now are relative to the start of the file. + - Issue #29079: Prevent infinite loop in pathlib.resolve() on Windows - Issue #13051: Fixed recursion errors in large or resized -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 21:22:06 2017 From: python-checkins at python.org (terry.reedy) Date: Mon, 02 Jan 2017 02:22:06 +0000 Subject: [Python-checkins] =?utf-8?q?cpython_=28merge_3=2E6_-=3E_default?= =?utf-8?q?=29=3A_Merge_with_3=2E6?= Message-ID: <20170102022206.21525.89726.757ED010@psf.io> https://hg.python.org/cpython/rev/91c15294a0ab changeset: 105923:91c15294a0ab parent: 105921:a80c14ace927 parent: 105922:62d3c0336df6 user: Terry Jan Reedy date: Sun Jan 01 21:21:54 2017 -0500 summary: Merge with 3.6 files: Lib/idlelib/colorizer.py | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Lib/idlelib/colorizer.py b/Lib/idlelib/colorizer.py --- a/Lib/idlelib/colorizer.py +++ b/Lib/idlelib/colorizer.py @@ -21,8 +21,7 @@ # 1st 'file' colorized normal, 2nd as builtin, 3rd as string builtin = r"([^.'\"\\#]\b|^)" + any("BUILTIN", builtinlist) + r"\b" comment = any("COMMENT", [r"#[^\n]*"]) - stringprefix = (r"(\br|R|u|U|f|F|fr|Fr|fR|FR|rf|rF|Rf|RF" - "|b|B|br|Br|bR|BR|rb|rB|Rb|RB)?") + stringprefix = r"(?i:\br|u|f|fr|rf|b|br|rb)?" sqstring = stringprefix + r"'[^'\\\n]*(\\.[^'\\\n]*)*'?" dqstring = stringprefix + r'"[^"\\\n]*(\\.[^"\\\n]*)*"?' sq3string = stringprefix + r"'''[^'\\]*((\\.|'(?!''))[^'\\]*)*(''')?" @@ -262,10 +261,11 @@ top = Toplevel(parent) top.title("Test ColorDelegator") x, y = map(int, parent.geometry().split('+')[1:]) - top.geometry("600x200+%d+%d" % (x + 100, y + 175)) + top.geometry("700x250+%d+%d" % (x + 20, y + 175)) source = ("# Following has syntax errors\n" "if True: then int 1\nelif False: print 0\nelse: float(None)\n" - "#unicode and byte strings, valid prefixes should be colored\n" + "if iF + If + IF: 'keywork matching must respect case'\n" + "# All valid prefixes for unicode and byte strings should be colored\n" "'x', '''x''', \"x\", \"\"\"x\"\"\"\n" "r'x', u'x', R'x', U'x', f'x', F'x', ur'is invalid'\n" "fr'x', Fr'x', fR'x', FR'x', rf'x', rF'x', Rf'x', RF'x'\n" -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 21:22:06 2017 From: python-checkins at python.org (terry.reedy) Date: Mon, 02 Jan 2017 02:22:06 +0000 Subject: [Python-checkins] =?utf-8?b?Y3B5dGhvbiAoMy42KTogSXNzdWUgIzI5MDcx?= =?utf-8?q?=3A_Use_local_flags_for_IDLE_colorizer_string_prefix_matcher=2E?= Message-ID: <20170102022206.25736.52190.EEE3F5DF@psf.io> https://hg.python.org/cpython/rev/62d3c0336df6 changeset: 105922:62d3c0336df6 branch: 3.6 parent: 105920:f36f9bce997d user: Terry Jan Reedy date: Sun Jan 01 21:21:39 2017 -0500 summary: Issue #29071: Use local flags for IDLE colorizer string prefix matcher. Revised re by Serhiy Storchaka. files: Lib/idlelib/colorizer.py | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Lib/idlelib/colorizer.py b/Lib/idlelib/colorizer.py --- a/Lib/idlelib/colorizer.py +++ b/Lib/idlelib/colorizer.py @@ -21,8 +21,7 @@ # 1st 'file' colorized normal, 2nd as builtin, 3rd as string builtin = r"([^.'\"\\#]\b|^)" + any("BUILTIN", builtinlist) + r"\b" comment = any("COMMENT", [r"#[^\n]*"]) - stringprefix = (r"(\br|R|u|U|f|F|fr|Fr|fR|FR|rf|rF|Rf|RF" - "|b|B|br|Br|bR|BR|rb|rB|Rb|RB)?") + stringprefix = r"(?i:\br|u|f|fr|rf|b|br|rb)?" sqstring = stringprefix + r"'[^'\\\n]*(\\.[^'\\\n]*)*'?" dqstring = stringprefix + r'"[^"\\\n]*(\\.[^"\\\n]*)*"?' sq3string = stringprefix + r"'''[^'\\]*((\\.|'(?!''))[^'\\]*)*(''')?" @@ -262,10 +261,11 @@ top = Toplevel(parent) top.title("Test ColorDelegator") x, y = map(int, parent.geometry().split('+')[1:]) - top.geometry("600x200+%d+%d" % (x + 100, y + 175)) + top.geometry("700x250+%d+%d" % (x + 20, y + 175)) source = ("# Following has syntax errors\n" "if True: then int 1\nelif False: print 0\nelse: float(None)\n" - "#unicode and byte strings, valid prefixes should be colored\n" + "if iF + If + IF: 'keywork matching must respect case'\n" + "# All valid prefixes for unicode and byte strings should be colored\n" "'x', '''x''', \"x\", \"\"\"x\"\"\"\n" "r'x', u'x', R'x', U'x', f'x', F'x', ur'is invalid'\n" "fr'x', Fr'x', fR'x', FR'x', rf'x', rF'x', Rf'x', RF'x'\n" -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 21:43:11 2017 From: python-checkins at python.org (berker.peksag) Date: Mon, 02 Jan 2017 02:43:11 +0000 Subject: [Python-checkins] =?utf-8?b?Y3B5dGhvbiAoMy41KTogSXNzdWUgIzI5MDI0?= =?utf-8?q?=3A_Add_Kivy_entry_to_GUI_FAQ?= Message-ID: <20170102024311.10302.93650.0B54748E@psf.io> https://hg.python.org/cpython/rev/d41aa32f7f3c changeset: 105924:d41aa32f7f3c branch: 3.5 parent: 105918:f5aa1c9c2b7e user: Berker Peksag date: Mon Jan 02 05:44:49 2017 +0300 summary: Issue #29024: Add Kivy entry to GUI FAQ Patch by inclement. files: Doc/faq/gui.rst | 10 ++++++++++ 1 files changed, 10 insertions(+), 0 deletions(-) diff --git a/Doc/faq/gui.rst b/Doc/faq/gui.rst --- a/Doc/faq/gui.rst +++ b/Doc/faq/gui.rst @@ -77,6 +77,16 @@ The older PyGtk bindings for the `Gtk+ 2 toolkit `_ have been implemented by James Henstridge; see . +Kivy +---- + +`Kivy `_ is a cross-platform GUI library supporting both +desktop operating systems (Windows, macOS, Linux) and mobile devices (Android, +iOS). It is written in Python and Cython, and can use a range of windowing +backends. + +Kivy is free and open source software distributed under the MIT license. + FLTK ---- -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 21:43:11 2017 From: python-checkins at python.org (berker.peksag) Date: Mon, 02 Jan 2017 02:43:11 +0000 Subject: [Python-checkins] =?utf-8?b?Y3B5dGhvbiAobWVyZ2UgMy41IC0+IDMuNik6?= =?utf-8?q?_Issue_=2329024=3A_Merge_from_3=2E5?= Message-ID: <20170102024311.10323.93925.D35CCE08@psf.io> https://hg.python.org/cpython/rev/ee25895d9d65 changeset: 105925:ee25895d9d65 branch: 3.6 parent: 105922:62d3c0336df6 parent: 105924:d41aa32f7f3c user: Berker Peksag date: Mon Jan 02 05:45:16 2017 +0300 summary: Issue #29024: Merge from 3.5 files: Doc/faq/gui.rst | 10 ++++++++++ 1 files changed, 10 insertions(+), 0 deletions(-) diff --git a/Doc/faq/gui.rst b/Doc/faq/gui.rst --- a/Doc/faq/gui.rst +++ b/Doc/faq/gui.rst @@ -77,6 +77,16 @@ The older PyGtk bindings for the `Gtk+ 2 toolkit `_ have been implemented by James Henstridge; see . +Kivy +---- + +`Kivy `_ is a cross-platform GUI library supporting both +desktop operating systems (Windows, macOS, Linux) and mobile devices (Android, +iOS). It is written in Python and Cython, and can use a range of windowing +backends. + +Kivy is free and open source software distributed under the MIT license. + FLTK ---- -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 21:43:11 2017 From: python-checkins at python.org (berker.peksag) Date: Mon, 02 Jan 2017 02:43:11 +0000 Subject: [Python-checkins] =?utf-8?q?cpython_=28merge_3=2E6_-=3E_default?= =?utf-8?q?=29=3A_Issue_=2329024=3A_Merge_from_3=2E6?= Message-ID: <20170102024311.10601.27700.2D7FE7FF@psf.io> https://hg.python.org/cpython/rev/4eb4cf6ac154 changeset: 105926:4eb4cf6ac154 parent: 105923:91c15294a0ab parent: 105925:ee25895d9d65 user: Berker Peksag date: Mon Jan 02 05:45:37 2017 +0300 summary: Issue #29024: Merge from 3.6 files: Doc/faq/gui.rst | 10 ++++++++++ 1 files changed, 10 insertions(+), 0 deletions(-) diff --git a/Doc/faq/gui.rst b/Doc/faq/gui.rst --- a/Doc/faq/gui.rst +++ b/Doc/faq/gui.rst @@ -77,6 +77,16 @@ The older PyGtk bindings for the `Gtk+ 2 toolkit `_ have been implemented by James Henstridge; see . +Kivy +---- + +`Kivy `_ is a cross-platform GUI library supporting both +desktop operating systems (Windows, macOS, Linux) and mobile devices (Android, +iOS). It is written in Python and Cython, and can use a range of windowing +backends. + +Kivy is free and open source software distributed under the MIT license. + FLTK ---- -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 21:49:03 2017 From: python-checkins at python.org (berker.peksag) Date: Mon, 02 Jan 2017 02:49:03 +0000 Subject: [Python-checkins] =?utf-8?q?cpython_=28merge_3=2E6_-=3E_default?= =?utf-8?q?=29=3A_Issue_=2329129=3A_Merge_from_3=2E6?= Message-ID: <20170102024903.55444.81009.80E5DADF@psf.io> https://hg.python.org/cpython/rev/337d78a4a7bf changeset: 105928:337d78a4a7bf parent: 105926:4eb4cf6ac154 parent: 105927:5698d84d0187 user: Berker Peksag date: Mon Jan 02 05:51:31 2017 +0300 summary: Issue #29129: Merge from 3.6 files: Doc/library/enum.rst | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/Doc/library/enum.rst b/Doc/library/enum.rst --- a/Doc/library/enum.rst +++ b/Doc/library/enum.rst @@ -773,7 +773,7 @@ Using :class:`auto` """"""""""""""""""" -Using :class:`object` would look like:: +Using :class:`auto` would look like:: >>> class Color(NoValue): ... RED = auto() -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 21:49:03 2017 From: python-checkins at python.org (berker.peksag) Date: Mon, 02 Jan 2017 02:49:03 +0000 Subject: [Python-checkins] =?utf-8?b?Y3B5dGhvbiAoMy42KTogSXNzdWUgIzI5MTI5?= =?utf-8?q?=3A_Fix_typo_in_=22Using_auto=22_section?= Message-ID: <20170102024903.28368.90374.99ECDE3E@psf.io> https://hg.python.org/cpython/rev/5698d84d0187 changeset: 105927:5698d84d0187 branch: 3.6 parent: 105925:ee25895d9d65 user: Berker Peksag date: Mon Jan 02 05:51:04 2017 +0300 summary: Issue #29129: Fix typo in "Using auto" section files: Doc/library/enum.rst | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/Doc/library/enum.rst b/Doc/library/enum.rst --- a/Doc/library/enum.rst +++ b/Doc/library/enum.rst @@ -773,7 +773,7 @@ Using :class:`auto` """"""""""""""""""" -Using :class:`object` would look like:: +Using :class:`auto` would look like:: >>> class Color(NoValue): ... RED = auto() -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 21:59:02 2017 From: python-checkins at python.org (berker.peksag) Date: Mon, 02 Jan 2017 02:59:02 +0000 Subject: [Python-checkins] =?utf-8?b?Y3B5dGhvbiAoMy41KTogSXNzdWUgIzI5MDEy?= =?utf-8?q?=3A_Remove_outdated_information_about_=5F=5Fbases=5F=5F?= Message-ID: <20170102025902.9772.47313.8A23E621@psf.io> https://hg.python.org/cpython/rev/721df314d45a changeset: 105929:721df314d45a branch: 3.5 parent: 105924:d41aa32f7f3c user: Berker Peksag date: Mon Jan 02 06:00:35 2017 +0300 summary: Issue #29012: Remove outdated information about __bases__ Patch by Jim Fasarakis-Hilliard. files: Doc/reference/datamodel.rst | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/Doc/reference/datamodel.rst b/Doc/reference/datamodel.rst --- a/Doc/reference/datamodel.rst +++ b/Doc/reference/datamodel.rst @@ -765,7 +765,7 @@ Special attributes: :attr:`~definition.__name__` is the class name; :attr:`__module__` is the module name in which the class was defined; :attr:`~object.__dict__` is the dictionary containing the class's namespace; :attr:`~class.__bases__` is a - tuple (possibly empty or a singleton) containing the base classes, in the + tuple (possibly a singleton) containing the base classes, in the order of their occurrence in the base class list; :attr:`__doc__` is the class's documentation string, or ``None`` if undefined. -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 21:59:02 2017 From: python-checkins at python.org (berker.peksag) Date: Mon, 02 Jan 2017 02:59:02 +0000 Subject: [Python-checkins] =?utf-8?b?Y3B5dGhvbiAobWVyZ2UgMy41IC0+IDMuNik6?= =?utf-8?q?_Issue_=2329012=3A_Merge_from_3=2E5?= Message-ID: <20170102025902.10196.20156.34DC6B11@psf.io> https://hg.python.org/cpython/rev/019125fb6d66 changeset: 105930:019125fb6d66 branch: 3.6 parent: 105927:5698d84d0187 parent: 105929:721df314d45a user: Berker Peksag date: Mon Jan 02 06:01:07 2017 +0300 summary: Issue #29012: Merge from 3.5 files: Doc/reference/datamodel.rst | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/Doc/reference/datamodel.rst b/Doc/reference/datamodel.rst --- a/Doc/reference/datamodel.rst +++ b/Doc/reference/datamodel.rst @@ -788,7 +788,7 @@ Special attributes: :attr:`~definition.__name__` is the class name; :attr:`__module__` is the module name in which the class was defined; :attr:`~object.__dict__` is the dictionary containing the class's namespace; :attr:`~class.__bases__` is a - tuple (possibly empty or a singleton) containing the base classes, in the + tuple (possibly a singleton) containing the base classes, in the order of their occurrence in the base class list; :attr:`__doc__` is the class's documentation string, or ``None`` if undefined; :attr:`__annotations__` (optional) is a dictionary containing -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 21:59:03 2017 From: python-checkins at python.org (berker.peksag) Date: Mon, 02 Jan 2017 02:59:03 +0000 Subject: [Python-checkins] =?utf-8?q?cpython_=28merge_3=2E6_-=3E_default?= =?utf-8?q?=29=3A_Issue_=2329012=3A_Merge_from_3=2E6?= Message-ID: <20170102025902.54764.46479.5991E68A@psf.io> https://hg.python.org/cpython/rev/454426dbff83 changeset: 105931:454426dbff83 parent: 105928:337d78a4a7bf parent: 105930:019125fb6d66 user: Berker Peksag date: Mon Jan 02 06:01:27 2017 +0300 summary: Issue #29012: Merge from 3.6 files: Doc/reference/datamodel.rst | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/Doc/reference/datamodel.rst b/Doc/reference/datamodel.rst --- a/Doc/reference/datamodel.rst +++ b/Doc/reference/datamodel.rst @@ -788,7 +788,7 @@ Special attributes: :attr:`~definition.__name__` is the class name; :attr:`__module__` is the module name in which the class was defined; :attr:`~object.__dict__` is the dictionary containing the class's namespace; :attr:`~class.__bases__` is a - tuple (possibly empty or a singleton) containing the base classes, in the + tuple (possibly a singleton) containing the base classes, in the order of their occurrence in the base class list; :attr:`__doc__` is the class's documentation string, or ``None`` if undefined; :attr:`__annotations__` (optional) is a dictionary containing -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 22:12:13 2017 From: python-checkins at python.org (berker.peksag) Date: Mon, 02 Jan 2017 03:12:13 +0000 Subject: [Python-checkins] =?utf-8?b?Y3B5dGhvbiAoMy41KTogSXNzdWUgIzI5MDEz?= =?utf-8?q?=3A_Fix_allowZip64_documentation?= Message-ID: <20170102031213.10484.18558.E32D8A74@psf.io> https://hg.python.org/cpython/rev/4685cd33087b changeset: 105932:4685cd33087b branch: 3.5 parent: 105929:721df314d45a user: Berker Peksag date: Mon Jan 02 06:13:42 2017 +0300 summary: Issue #29013: Fix allowZip64 documentation Zip files can be larger than 4 GiB if allowZip64 is true (default since Python 3.4) files: Doc/library/zipfile.rst | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/Doc/library/zipfile.rst b/Doc/library/zipfile.rst --- a/Doc/library/zipfile.rst +++ b/Doc/library/zipfile.rst @@ -152,7 +152,7 @@ (:mod:`zlib`, :mod:`bz2` or :mod:`lzma`) is not available, :exc:`RuntimeError` is also raised. The default is :const:`ZIP_STORED`. If *allowZip64* is ``True`` (the default) zipfile will create ZIP files that use the ZIP64 - extensions when the zipfile is larger than 2 GiB. If it is false :mod:`zipfile` + extensions when the zipfile is larger than 4 GiB. If it is false :mod:`zipfile` will raise an exception when the ZIP file would require ZIP64 extensions. If the file is created with mode ``'w'``, ``'x'`` or ``'a'`` and then -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 22:12:13 2017 From: python-checkins at python.org (berker.peksag) Date: Mon, 02 Jan 2017 03:12:13 +0000 Subject: [Python-checkins] =?utf-8?q?cpython_=28merge_3=2E6_-=3E_default?= =?utf-8?q?=29=3A_Issue_=2329013=3A_Merge_from_3=2E6?= Message-ID: <20170102031213.28527.32827.D6193934@psf.io> https://hg.python.org/cpython/rev/6ca0f3fcf82f changeset: 105934:6ca0f3fcf82f parent: 105931:454426dbff83 parent: 105933:7c5075a14459 user: Berker Peksag date: Mon Jan 02 06:14:39 2017 +0300 summary: Issue #29013: Merge from 3.6 files: Doc/library/zipfile.rst | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/Doc/library/zipfile.rst b/Doc/library/zipfile.rst --- a/Doc/library/zipfile.rst +++ b/Doc/library/zipfile.rst @@ -152,7 +152,7 @@ (:mod:`zlib`, :mod:`bz2` or :mod:`lzma`) is not available, :exc:`RuntimeError` is raised. The default is :const:`ZIP_STORED`. If *allowZip64* is ``True`` (the default) zipfile will create ZIP files that use the ZIP64 - extensions when the zipfile is larger than 2 GiB. If it is false :mod:`zipfile` + extensions when the zipfile is larger than 4 GiB. If it is false :mod:`zipfile` will raise an exception when the ZIP file would require ZIP64 extensions. If the file is created with mode ``'w'``, ``'x'`` or ``'a'`` and then -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 22:12:13 2017 From: python-checkins at python.org (berker.peksag) Date: Mon, 02 Jan 2017 03:12:13 +0000 Subject: [Python-checkins] =?utf-8?b?Y3B5dGhvbiAobWVyZ2UgMy41IC0+IDMuNik6?= =?utf-8?q?_Issue_=2329013=3A_Merge_from_3=2E5?= Message-ID: <20170102031213.55068.7017.4C61ECC4@psf.io> https://hg.python.org/cpython/rev/7c5075a14459 changeset: 105933:7c5075a14459 branch: 3.6 parent: 105930:019125fb6d66 parent: 105932:4685cd33087b user: Berker Peksag date: Mon Jan 02 06:14:12 2017 +0300 summary: Issue #29013: Merge from 3.5 files: Doc/library/zipfile.rst | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/Doc/library/zipfile.rst b/Doc/library/zipfile.rst --- a/Doc/library/zipfile.rst +++ b/Doc/library/zipfile.rst @@ -152,7 +152,7 @@ (:mod:`zlib`, :mod:`bz2` or :mod:`lzma`) is not available, :exc:`RuntimeError` is raised. The default is :const:`ZIP_STORED`. If *allowZip64* is ``True`` (the default) zipfile will create ZIP files that use the ZIP64 - extensions when the zipfile is larger than 2 GiB. If it is false :mod:`zipfile` + extensions when the zipfile is larger than 4 GiB. If it is false :mod:`zipfile` will raise an exception when the ZIP file would require ZIP64 extensions. If the file is created with mode ``'w'``, ``'x'`` or ``'a'`` and then -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 22:35:42 2017 From: python-checkins at python.org (berker.peksag) Date: Mon, 02 Jan 2017 03:35:42 +0000 Subject: [Python-checkins] =?utf-8?q?cpython=3A_Issue_=2328985=3A_Update_a?= =?utf-8?q?uthorizer_constants_in_sqlite3_module?= Message-ID: <20170102033541.55068.75321.59C86DC8@psf.io> https://hg.python.org/cpython/rev/b9c4139a1309 changeset: 105935:b9c4139a1309 user: Berker Peksag date: Mon Jan 02 06:38:10 2017 +0300 summary: Issue #28985: Update authorizer constants in sqlite3 module Dates and version information from the changelog: * 2006-08-12 (3.3.7) added SQLITE_CREATE_VTABLE, SQLITE_DROP_VTABLE * 2006-10-09 (3.3.8) added SQLITE_FUNCTION * 2009-01-12 (3.6.8) added SQLITE_SAVEPOINT * 2014-02-03 (3.8.3) added SQLITE_RECURSIVE Patch by Dingyuan Wang. files: Misc/NEWS | 3 +++ Modules/_sqlite/module.c | 13 +++++++++++++ 2 files changed, 16 insertions(+), 0 deletions(-) diff --git a/Misc/NEWS b/Misc/NEWS --- a/Misc/NEWS +++ b/Misc/NEWS @@ -208,6 +208,9 @@ Library ------- +- Issue #28985: Update authorizer constants in sqlite3 module. + Patch by Dingyuan Wang. + - Issue #29094: Offsets in a ZIP file created with extern file object and modes "w" and "x" now are relative to the start of the file. diff --git a/Modules/_sqlite/module.c b/Modules/_sqlite/module.c --- a/Modules/_sqlite/module.c +++ b/Modules/_sqlite/module.c @@ -303,6 +303,19 @@ #if SQLITE_VERSION_NUMBER >= 3003000 {"SQLITE_ANALYZE", SQLITE_ANALYZE}, #endif +#if SQLITE_VERSION_NUMBER >= 3003007 + {"SQLITE_CREATE_VTABLE", SQLITE_CREATE_VTABLE}, + {"SQLITE_DROP_VTABLE", SQLITE_DROP_VTABLE}, +#endif +#if SQLITE_VERSION_NUMBER >= 3003008 + {"SQLITE_FUNCTION", SQLITE_FUNCTION}, +#endif +#if SQLITE_VERSION_NUMBER >= 3006008 + {"SQLITE_SAVEPOINT", SQLITE_SAVEPOINT}, +#endif +#if SQLITE_VERSION_NUMBER >= 3008003 + {"SQLITE_RECURSIVE", SQLITE_RECURSIVE}, +#endif {(char*)NULL, 0} }; -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 22:58:06 2017 From: python-checkins at python.org (berker.peksag) Date: Mon, 02 Jan 2017 03:58:06 +0000 Subject: [Python-checkins] =?utf-8?b?Y3B5dGhvbiAobWVyZ2UgMy41IC0+IDMuNik6?= =?utf-8?q?_Issue_=2315812=3A_Merge_from_3=2E5?= Message-ID: <20170102035806.54556.60312.47DFE24E@psf.io> https://hg.python.org/cpython/rev/410caf255a09 changeset: 105937:410caf255a09 branch: 3.6 parent: 105933:7c5075a14459 parent: 105936:15454cad5f27 user: Berker Peksag date: Mon Jan 02 06:59:12 2017 +0300 summary: Issue #15812: Merge from 3.5 files: Lib/inspect.py | 2 +- Lib/test/test_inspect.py | 5 +++++ Misc/NEWS | 3 +++ 3 files changed, 9 insertions(+), 1 deletions(-) diff --git a/Lib/inspect.py b/Lib/inspect.py --- a/Lib/inspect.py +++ b/Lib/inspect.py @@ -1416,7 +1416,7 @@ except OSError: lines = index = None else: - start = max(start, 1) + start = max(start, 0) start = max(0, min(start, len(lines) - context)) lines = lines[start:start+context] index = lineno - 1 - start diff --git a/Lib/test/test_inspect.py b/Lib/test/test_inspect.py --- a/Lib/test/test_inspect.py +++ b/Lib/test/test_inspect.py @@ -402,6 +402,11 @@ # Check filename override self.assertEqual(inspect.getmodule(None, modfile), mod) + def test_getframeinfo_get_first_line(self): + frame_info = inspect.getframeinfo(self.fodderModule.fr, 50) + self.assertEqual(frame_info.code_context[0], "# line 1\n") + self.assertEqual(frame_info.code_context[1], "'A module docstring.'\n") + def test_getsource(self): self.assertSourceEqual(git.abuse, 29, 39) self.assertSourceEqual(mod.StupidGit, 21, 51) diff --git a/Misc/NEWS b/Misc/NEWS --- a/Misc/NEWS +++ b/Misc/NEWS @@ -40,6 +40,9 @@ Library ------- +- Issue #15812: inspect.getframeinfo() now correctly shows the first line of + a context. Patch by Sam Breese. + - Issue #29094: Offsets in a ZIP file created with extern file object and modes "w" and "x" now are relative to the start of the file. -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 22:58:06 2017 From: python-checkins at python.org (berker.peksag) Date: Mon, 02 Jan 2017 03:58:06 +0000 Subject: [Python-checkins] =?utf-8?b?Y3B5dGhvbiAoMy41KTogSXNzdWUgIzE1ODEy?= =?utf-8?q?=3A_inspect=2Egetframeinfo=28=29_now_correctly_shows_the_first_?= =?utf-8?q?line_of_a?= Message-ID: <20170102035806.10425.64732.5A83F0BC@psf.io> https://hg.python.org/cpython/rev/15454cad5f27 changeset: 105936:15454cad5f27 branch: 3.5 parent: 105932:4685cd33087b user: Berker Peksag date: Mon Jan 02 06:57:43 2017 +0300 summary: Issue #15812: inspect.getframeinfo() now correctly shows the first line of a context Patch by Sam Breese. files: Lib/inspect.py | 2 +- Lib/test/test_inspect.py | 5 +++++ Misc/NEWS | 3 +++ 3 files changed, 9 insertions(+), 1 deletions(-) diff --git a/Lib/inspect.py b/Lib/inspect.py --- a/Lib/inspect.py +++ b/Lib/inspect.py @@ -1416,7 +1416,7 @@ except OSError: lines = index = None else: - start = max(start, 1) + start = max(start, 0) start = max(0, min(start, len(lines) - context)) lines = lines[start:start+context] index = lineno - 1 - start diff --git a/Lib/test/test_inspect.py b/Lib/test/test_inspect.py --- a/Lib/test/test_inspect.py +++ b/Lib/test/test_inspect.py @@ -391,6 +391,11 @@ # Check filename override self.assertEqual(inspect.getmodule(None, modfile), mod) + def test_getframeinfo_get_first_line(self): + frame_info = inspect.getframeinfo(self.fodderModule.fr, 50) + self.assertEqual(frame_info.code_context[0], "# line 1\n") + self.assertEqual(frame_info.code_context[1], "'A module docstring.'\n") + def test_getsource(self): self.assertSourceEqual(git.abuse, 29, 39) self.assertSourceEqual(mod.StupidGit, 21, 51) diff --git a/Misc/NEWS b/Misc/NEWS --- a/Misc/NEWS +++ b/Misc/NEWS @@ -140,6 +140,9 @@ Library ------- +- Issue #15812: inspect.getframeinfo() now correctly shows the first line of + a context. Patch by Sam Breese. + - Issue #29094: Offsets in a ZIP file created with extern file object and modes "w" and "x" now are relative to the start of the file. -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 22:58:06 2017 From: python-checkins at python.org (berker.peksag) Date: Mon, 02 Jan 2017 03:58:06 +0000 Subject: [Python-checkins] =?utf-8?q?cpython_=28merge_3=2E6_-=3E_default?= =?utf-8?q?=29=3A_Issue_=2315812=3A_Merge_from_3=2E6?= Message-ID: <20170102035806.10789.98464.BA1CEFB4@psf.io> https://hg.python.org/cpython/rev/803c3c21c3bc changeset: 105938:803c3c21c3bc parent: 105935:b9c4139a1309 parent: 105937:410caf255a09 user: Berker Peksag date: Mon Jan 02 07:00:29 2017 +0300 summary: Issue #15812: Merge from 3.6 files: Lib/inspect.py | 2 +- Lib/test/test_inspect.py | 5 +++++ Misc/NEWS | 3 +++ 3 files changed, 9 insertions(+), 1 deletions(-) diff --git a/Lib/inspect.py b/Lib/inspect.py --- a/Lib/inspect.py +++ b/Lib/inspect.py @@ -1416,7 +1416,7 @@ except OSError: lines = index = None else: - start = max(start, 1) + start = max(start, 0) start = max(0, min(start, len(lines) - context)) lines = lines[start:start+context] index = lineno - 1 - start diff --git a/Lib/test/test_inspect.py b/Lib/test/test_inspect.py --- a/Lib/test/test_inspect.py +++ b/Lib/test/test_inspect.py @@ -399,6 +399,11 @@ # Check filename override self.assertEqual(inspect.getmodule(None, modfile), mod) + def test_getframeinfo_get_first_line(self): + frame_info = inspect.getframeinfo(self.fodderModule.fr, 50) + self.assertEqual(frame_info.code_context[0], "# line 1\n") + self.assertEqual(frame_info.code_context[1], "'A module docstring.'\n") + def test_getsource(self): self.assertSourceEqual(git.abuse, 29, 39) self.assertSourceEqual(mod.StupidGit, 21, 51) diff --git a/Misc/NEWS b/Misc/NEWS --- a/Misc/NEWS +++ b/Misc/NEWS @@ -208,6 +208,9 @@ Library ------- +- Issue #15812: inspect.getframeinfo() now correctly shows the first line of + a context. Patch by Sam Breese. + - Issue #28985: Update authorizer constants in sqlite3 module. Patch by Dingyuan Wang. -- Repository URL: https://hg.python.org/cpython From python-checkins at python.org Sun Jan 1 23:04:19 2017 From: python-checkins at python.org (benjamin.peterson) Date: Mon, 02 Jan 2017 04:04:19 +0000 Subject: [Python-checkins] =?utf-8?q?cpython_=282=2E7=29=3A_ring_in_2017_f?= =?utf-8?q?or_Python?= Message-ID: <20170102040419.9948.65114.2B7A77D0@psf.io> https://hg.python.org/cpython/rev/97ca7631eed5 changeset: 105939:97ca7631eed5 branch: 2.7 parent: 105919:342bc734f523 user: Benjamin Peterson date: Sun Jan 01 22:04:13 2017 -0600 summary: ring in 2017 for Python files: Doc/license.rst | 2 +- LICENSE | 2 +- Lib/idlelib/help.html | 2 +- Mac/BuildScript/resources/License.rtf | 4 ++-- Mac/IDLE/Info.plist.in | 2 +- Mac/PythonLauncher/Info.plist.in | 2 +- Mac/Resources/app/Info.plist.in | 2 +- Mac/Resources/framework/Info.plist.in | 4 ++-- PC/python_nt.rc | 2 +- Python/getcopyright.c | 2 +- README | 3 ++- 11 files changed, 14 insertions(+), 13 deletions(-) diff --git a/Doc/license.rst b/Doc/license.rst --- a/Doc/license.rst +++ b/Doc/license.rst @@ -87,7 +87,7 @@ analyze, test, perform and/or display publicly, prepare derivative works, distribute, and otherwise use Python |release| alone or in any derivative version, provided, however, that PSF's License Agreement and PSF's notice of - copyright, i.e., "Copyright ?? 2001-2016 Python Software Foundation; All Rights + copyright, i.e., "Copyright ?? 2001-2017 Python Software Foundation; All Rights Reserved" are retained in Python |release| alone or in any derivative version prepared by Licensee. diff --git a/LICENSE b/LICENSE --- a/LICENSE +++ b/LICENSE @@ -74,7 +74,7 @@ distribute, and otherwise use Python alone or in any derivative version, provided, however, that PSF's License Agreement and PSF's notice of copyright, i.e., "Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, -2011, 2012, 2013, 2014, 2015, 2016 Python Software Foundation; All Rights +2011, 2012, 2013, 2014, 2015, 2016, 2017 Python Software Foundation; All Rights Reserved" are retained in Python alone or in any derivative version prepared by Licensee. diff --git a/Lib/idlelib/help.html b/Lib/idlelib/help.html --- a/Lib/idlelib/help.html +++ b/Lib/idlelib/help.html @@ -700,7 +700,7 @@