[issue43323] UnicodeEncodeError: surrogates not allowed when parsing invalid charset

2022-03-28 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: > Awesome, thanks! I'll give it a try later today or tomorrow. I have applied the patch and the problem seems to have been fixed. \o/ -- ___ Python tracker <https://bugs.python.org/issu

[issue43323] UnicodeEncodeError: surrogates not allowed when parsing invalid charset

2022-03-27 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: Awesome, thanks! I'll give it a try later today or tomorrow. -- ___ Python tracker <https://bugs.python.org/issue43

[issue43323] UnicodeEncodeError: surrogates not allowed when parsing invalid charset

2022-03-27 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: Hi Serhiy! > The simple fix is to add UnicodeEncodeError to "except LookupError". But > there may be other places where we can get a similar error. They should be > fixed too. I would be very interested to test this as t

[issue44807] typing.Protocol silently overrides __init__ method of delivered class

2022-02-28 Thread Adrian Garcia Badaracco
Adrian Garcia Badaracco added the comment: I am not sure if that solves anything (other than the fact that __new__ is much less common to implement than __init__), but I may just be slow to pick up the implications of moving the check to __new__

[issue44807] typing.Protocol silently overrides __init__ method of delivered class

2022-02-28 Thread Adrian Garcia Badaracco
Adrian Garcia Badaracco added the comment: Guido, it looks like you replied while I was typing my reply out. Yurii can correct me here but I believe PR #27543 was an attempt to disallow defining `__init__` on a Protocol completely. What I proposed above is the opposite behavior, while still

[issue44807] typing.Protocol silently overrides __init__ method of delivered class

2022-02-28 Thread Adrian Garcia Badaracco
Adrian Garcia Badaracco added the comment: Agreed. What if we allow protocols that implement `__init__` but still disallow instantiating a protocol that does not? It's a 1 line change, all existing tests pass and it would still catch what I think was the original intention (trying

[issue44807] typing.Protocol silently overrides __init__ method of delivered class

2022-02-28 Thread Adrian Garcia Badaracco
Change by Adrian Garcia Badaracco : -- pull_requests: +29750 stage: test needed -> patch review pull_request: https://github.com/python/cpython/pull/31628 ___ Python tracker <https://bugs.python.org/issu

[issue44807] typing.Protocol silently overrides __init__ method of delivered class

2022-02-27 Thread Adrian Garcia Badaracco
Adrian Garcia Badaracco added the comment: Apologies if that was noise, I filed an issue on the MyPy issue tracker: https://github.com/python/mypy/issues/12261 -- ___ Python tracker <https://bugs.python.org/issue44

[issue44807] typing.Protocol silently overrides __init__ method of delivered class

2022-02-27 Thread Adrian Garcia Badaracco
Adrian Garcia Badaracco added the comment: While this is figured out, would it be possible to remove the silent overriding? This seems like something type checkers should be doing, not silent runtime modification of classes. Pyright already (correctly) checks this, so I think it would just

[issue31242] Add SSLContext.set_verify_callback()

2022-02-17 Thread Adrian Freund
Adrian Freund added the comment: I also need this feature for something I'm working on, so I looked into it a bit and pushed a small proof of concept implementation to GitHub (See PR 31391). I'm not sure if I'll have enough time to finish and clean up this implementation, but at least

[issue46779] Add ssl.CERT_REQUIRED_NO_VERIFY as possible value for ssl.SSLContext.verify_mode

2022-02-17 Thread Adrian Freund
New submission from Adrian Freund : Some networked applications might require connecting to client with invalid certificates but still requiring the client to send a certificate. ssl.SSLContext.verify_mode currently supports the following options: ssl.CERT_NONE: Don't require the client

[issue31242] Add SSLContext.set_verify_callback()

2022-02-17 Thread Adrian Freund
Change by Adrian Freund : -- keywords: +patch pull_requests: +29536 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/31391 ___ Python tracker <https://bugs.python.org/issu

[issue31242] Add SSLContext.set_verify_callback()

2022-02-17 Thread Adrian Freund
Change by Adrian Freund : -- nosy: +freundTech ___ Python tracker <https://bugs.python.org/issue31242> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue33017] Special set-cookie setting will bypass Cookielib

2022-02-10 Thread Adrian Chaves
Adrian Chaves added the comment: So, PoC shows how an empty domain attribute (Domain=) is erroneously turned into a dot (.). I want to add that a dot (Domain=.) should be turned into an empty string (the specification asks to remove a leading dot if found). -- nosy: +adrian2

[issue43323] UnicodeEncodeError: surrogates not allowed when parsing invalid charset

2022-01-12 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: I'm running into exactly this issue when using 'offlineimap' which is written in Python. -- nosy: +glaubitz ___ Python tracker <https://bugs.python.org/issue43

[issue17005] Add a topological sort algorithm

2021-11-29 Thread Adrian Garcia Badaracco
Adrian Garcia Badaracco added the comment: As part of working on a tool that deals with dependencies, I was building my own topological sort. I iterated through various APIs (iterable of tasks, iterable of parallelizable groups of tasks, etc.) until I found the (now stdlib) version which

[issue26175] Fully implement IOBase abstract on SpooledTemporaryFile

2021-11-16 Thread Adrian Garcia Badaracco
Change by Adrian Garcia Badaracco : -- nosy: +adriangb ___ Python tracker <https://bugs.python.org/issue26175> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue44834] contextvars.Context.run w/ coroutines gives inconsistent behavior

2021-08-04 Thread Adrian Garcia Badaracco
Change by Adrian Garcia Badaracco : -- nosy: +yselivanov ___ Python tracker <https://bugs.python.org/issue44834> ___ ___ Python-bugs-list mailing list Unsub

[issue42815] new thread doesn't copy context of the parent thread

2021-08-04 Thread Adrian Garcia Badaracco
Change by Adrian Garcia Badaracco : -- nosy: +adriangb ___ Python tracker <https://bugs.python.org/issue42815> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue44834] contextvars.Context.run w/ coroutines gives inconsistent behavior

2021-08-04 Thread Adrian Garcia Badaracco
New submission from Adrian Garcia Badaracco : I recently tried to use `contextvars.Context.run` w/ coroutines, expecting the same behavior as with regular functions, but it seems that `contextvars.Context.run` does not work w/ coroutines. I'm sorry if this is something obvious to do with how

[issue43994] change representation of match as / capture as `Name(..., ctx=Store())`

2021-04-30 Thread Adrian Freund
Adrian Freund added the comment: I already brought this up on the main pattern matching issue some time ago (https://bugs.python.org/issue42128#msg388554), where the consensus was that not using a Name is consistent with other parts of the ast, such as `import ... as identifier`, `except

[issue43892] Make match patterns explicit in the AST

2021-04-20 Thread Adrian Freund
Change by Adrian Freund : -- nosy: +freundTech ___ Python tracker <https://bugs.python.org/issue43892> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue43761] Documenting dataclass and namedtuple changes for structural pattern matching

2021-04-10 Thread Adrian Freund
Adrian Freund added the comment: I think for namedtuple a short mention in the opening paragraph, where it also mentions the generation of a docstring and __repr__ method should be enough. -- ___ Python tracker <https://bugs.python.org/issue43

[issue43761] Documenting dataclass and namedtuple changes for structural pattern matching

2021-04-09 Thread Adrian Freund
Adrian Freund added the comment: I agree that __match_args__ shouldn't have to be added to the documentation of any class that supports it, however dataclass and (maybe to a lesser extend) NamedTuple aren't themselves classes, but aid in creating own classes. Their effects on classes

[issue43764] Turning off generation of __match_args__ for dataclasses

2021-04-09 Thread Adrian Freund
Adrian Freund added the comment: > I assume the OP wants to have a class that doesn't allow positional patterns. > The right way to spell that is indeed to add > >__match_args__ = () > >to the class, there's no need to add another flag to @dataclass. The same however is

[issue43761] Documenting dataclass and namedtuple changes for structural pattern matching

2021-04-07 Thread Adrian Freund
Adrian Freund added the comment: Ok. I created https://bugs.python.org/issue43764 for that. -- ___ Python tracker <https://bugs.python.org/issue43761> ___ ___

[issue43764] Turning off generation of __match_args__ for dataclasses

2021-04-07 Thread Adrian Freund
New submission from Adrian Freund : The dataclass decorator can take multiple parameters to enable or disable the generation of certain methods. PEP 634 Structural Pattern Matching extends dataclasses to also generate a __match_args__ attribute. I think adding a parameter to enable

[issue43761] Documenting dataclass and namedtuple changes for structural pattern matching

2021-04-07 Thread Adrian Freund
New submission from Adrian Freund : PEP 634 structural pattern matching adds an auto-generated __match_args__ attribute to classes with the dataclass decorator and to namedtuples. This change is currently not documented in the dataclass and namedtuple documentation, nor is it mentioned

[issue43179] Remove 31/32-bit s390 Linux support (s390-linux-gnu triplet)

2021-03-19 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: I think there is one productive result of this discussion which is this patch by Jessica Clark which gets rid of architecture-specific alignment code: > https://github.com/python/cpython/pull/24624 Unfortunately, it has not seen any posit

[issue43531] Turtle module does not work

2021-03-17 Thread Adrian LeDeaux
Adrian LeDeaux added the comment: OK. -- ___ Python tracker <https://bugs.python.org/issue43531> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue43531] Turtle module does not work

2021-03-17 Thread Adrian LeDeaux
Adrian LeDeaux added the comment: That fixed it. -- ___ Python tracker <https://bugs.python.org/issue43531> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue43531] Turtle module does not work

2021-03-17 Thread Adrian LeDeaux
Adrian LeDeaux added the comment: Oh, OK. I am not an expert on python so I did not understand the error. Thanks for the help, and I will update you if the problems continue. -- ___ Python tracker <https://bugs.python.org/issue43

[issue43531] Turtle module does not work

2021-03-17 Thread Adrian LeDeaux
New submission from Adrian LeDeaux : So when I try to do the command "import turtle" all I get back is: Traceback (most recent call last): File "", line 1, in import turtle File "/Users/Virsatech/Documents/turtle.py", line 2, in t = turtle.P

[issue43489] Can't install, nothing to install

2021-03-14 Thread Adrian LeDeaux
Adrian LeDeaux added the comment: Alright! Thanks for the help! I will try that. -- ___ Python tracker <https://bugs.python.org/issue43489> ___ ___ Python-bug

[issue43489] Can't install, nothing to install

2021-03-13 Thread Adrian LeDeaux
Adrian LeDeaux added the comment: The main reason I am trying to install this is because I want to use pygame. Is pygame compatible with version 2.7.28? -- ___ Python tracker <https://bugs.python.org/issue43

[issue43489] Can't install, nothing to install

2021-03-13 Thread Adrian LeDeaux
Adrian LeDeaux added the comment: First, I am not asking for guesses. I am getting the installers from the www.python.org website, and I am running them with the MacOS installer app. The format is .mpkg -- Added file: https://bugs.python.org/file49874/Screen Shot 2021-03-13

[issue43490] IDLE freezes at random

2021-03-13 Thread Adrian LeDeaux
Adrian LeDeaux added the comment: My processor is Intel core 2 duo. -- ___ Python tracker <https://bugs.python.org/issue43490> ___ ___ Python-bugs-list mailin

[issue43490] IDLE freezes at random

2021-03-13 Thread Adrian LeDeaux
Adrian LeDeaux added the comment: Only when using the turtle module does it happen. -- type: -> behavior versions: -Python 3.10 ___ Python tracker <https://bugs.python.org/issu

[issue43490] IDLE freezes at random

2021-03-13 Thread Adrian LeDeaux
New submission from Adrian LeDeaux : My IDLE shell keeps freezing when using the turtle module. I am using MacOS High Sierra 13.10.6. It says it is fine, but I can't get the window open. I have to restart the shell entirely. I can't type or do anything. I have to do the [command]+[Q

[issue43489] Can't install, nothing to install

2021-03-13 Thread Adrian LeDeaux
New submission from Adrian LeDeaux : Python 2.7 won't install. I get the error "there is nothing to install" or something to that effect. I am using MacOS High Sierra 10.13.6. I tried both installer downloads. None worked. And I got the same error every time. Anyone have any ide

[issue42128] Structural Pattern Matching (PEP 634)

2021-03-12 Thread Adrian Freund
Adrian Freund added the comment: Thanks for the response. Looks like I overlooked the imports, global, nonlocal, ... because I only searched for usages of identifier, but they use lists of identifiers. In that case I agree that it isn't inconsistent

[issue42128] Structural Pattern Matching (PEP 634)

2021-03-12 Thread Adrian Freund
Adrian Freund added the comment: For the last few days I've been working with pattern matching and it's ast for a bit, while trying to add support for it to mypy. During this I noticed an inconsistency in the ast: ast.MatchAs has an attribute name which is of type identifier (in C) and type

[issue43374] Apple refuses apps written in Python

2021-03-05 Thread Adrian
Adrian added the comment: Terry, After opening issues on this and other mailing lists (PyObjc) Apple validated our app without a comment. Adrian > On 5 Mar 2021, at 21:51, Terry J. Reedy wrote: > > > Terry J. Reedy added the comment: > > Adrian, when respondin

[issue43374] Apple refuses apps written in Python

2021-03-02 Thread Adrian
New submission from Adrian : My company maintains several Python related projects, one of them being an application published for many years in the Mac App Store. During the submittion of the last update for the app, we were refused by Apple to publish the software with the following reason

[issue43374] Apple refuses apps written in Python

2021-03-02 Thread Adrian
Adrian added the comment: Hi Ned, Yes, I have submitted Python apps to Mac App Store since 2009, for 12 years. Each new push opens a new pandoras box with different questions asked than previously. There is no learning curve, is just walls with more walls behind each submission

[issue43374] Apple refuses apps written in Python

2021-03-02 Thread Adrian
Adrian added the comment: Hi Ned, I have a ticket opened with Apple. They refuse the software as it, they are in a position of absolute power, to reject and drop many years of work on a dime. What am I suppose to do? I can fix my own software, but then there are dependencies like Python

[issue43374] Apple refuses apps written in Python

2021-03-02 Thread Adrian
Adrian added the comment: My apologies, you may disregard any libraries not downloaded from python.org <http://python.org/> I am strictly speaking about the following items related to this mailing list: • Contents/Frameworks/Python.framework/Versions/3.9/lib/libformw.5.dylib/_wadd_w

[issue43374] Apple refuses apps written in Python

2021-03-02 Thread Adrian
Adrian added the comment: My apologies, you may disregard any libraries not downloaded from python.org <http://python.org/> I am strictly speaking about the following items related to this mailing list: • Contents/Frameworks/Python.framework/Versions/3.9/lib/libformw.5.dylib/_wadd_w

[issue43179] Remove 31/32-bit s390 Linux support (s390-linux-gnu triplet)

2021-02-21 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: Oh, and LLVM is currently gaining support M68k which you consider "legacy": > https://reviews.llvm.org/D95315 It might be a good idea to do some research first before making su

[issue43179] Remove 31/32-bit s390 Linux support (s390-linux-gnu triplet)

2021-02-21 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: > "Move support of legacy platforms/architectures outside Python" > https://mail.python.org/archives/list/python-...@python.org/thread/F5BXISYP7RAINXUMYJSEYG7GCFRFAENF/ Motorola 68k isn't a 16-bit architecture, it's a 32-bit archit

[issue43179] Remove 31/32-bit s390 Linux support (s390-linux-gnu triplet)

2021-02-18 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: > But I don't see the benefit of annoying and discouraging users who want to > experiment with Python and with Linux on Z in 31 bit mode. Fully agree. > Yes, maintenance theoretically is a burden, but there have been no recent > issu

[issue43179] Remove 31/32-bit s390 Linux support (s390-linux-gnu triplet)

2021-02-18 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: > To get a platform supported by Python, we also need a volunteer to fix issues > specific to the 31 bit s390 platform: see PEP 11. You do not need to support every platform. Just allow your users to use them. If something breaks down

[issue43179] Remove 31/32-bit s390 Linux support (s390-linux-gnu triplet)

2021-02-17 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: > What is the use case or benefit of building Python for 32-bit rather than > 64-bit? That's not really the question. The question is whether an upstream project should prevent downstreams from using unsupported target configurations and I

[issue43179] Remove 31/32-bit s390 Linux support (s390-linux-gnu triplet)

2021-02-16 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: > Are you sure about that? It seems SLE-12 support s390x not s390. Maybe it's > multilib support in a similar manner that I've mentioned about RHEL7? I work at SUSE. I looked at the internal build system. Debian also still build s390 mu

[issue43179] Remove 32-bit s390 Linux support (s390-linux-gnu triplet)

2021-02-16 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: > This thread is an excellent example why ignoring platforms comes at a cost. > It will only get worse when are going to introduce platform and architecture > specific code for optimizations and features. Which is purely hyp

[issue43179] Remove 32-bit s390 Linux support (s390-linux-gnu triplet)

2021-02-16 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: > So IMO it's fine to remove the support. You are not removing "support". You're just disallowing users to use the Python interpreter - which works perfectly fine on all architectures we have in current and previous releases - on D

[issue43179] Remove 32-bit s390 Linux support (s390-linux-gnu triplet)

2021-02-16 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: > The guidelines for platform support are explained in PEP 11 > (https://www.python.org/dev/peps/pep-0011/#supporting-platforms). We don't > support platforms unless we have maintainers and CI (builtbots) in place for > the platform

[issue43179] Remove 32-bit s390 Linux support (s390-linux-gnu triplet)

2021-02-15 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: > Moving forward, s390 will be unambiguously unsupported as we cannot test > against this platform. Unless we get a buildbot provided for this purpose, > as well as somebody willing to fix broken builds on that buildbot long-term, >

[issue43179] Remove 32-bit s390 Linux support (s390-linux-gnu triplet)

2021-02-15 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: > I want to make it obvious that the platform has been dropped half a decade > ago. That's a political statement, not a technical one. The change has zero functional impact on the other targets. It just makes the use of Python in a pot

[issue43179] Remove 32-bit s390 Linux support (s390-linux-gnu triplet)

2021-02-15 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: s390 is a 31-bit platform, not a 32-bit platform. I also don't see what this change achieves other than making the use of Python 3.10 on s390 harder. It's not like the removal of support for non-threaded builds which actually saved quite some

[issue43179] Remove s390 support

2021-02-15 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: > I opened this ticket after a user told me that they grepped the source code > of Python, found the string "s390", and concluded that s390 is still > supported by us. Because one user was surprised by a few lines in configure

[issue43179] Remove s390 support

2021-02-15 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: That's an argument I have personally never heard before and I have been dealing with a lot of architecture support in many packages. FWIW, lots of upstream projects have targets which are officially supported and others which

[issue43179] Remove s390 support

2021-02-15 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: And, FWIW, I generally don't quite understand what the problem with old triplet definitions in configure.ac are. I assume they don't hurt anyone, do they? You never know what usecases your users have and as long as a code snippet doesn't

[issue43179] Remove s390 support

2021-02-15 Thread John Paul Adrian Glaubitz
John Paul Adrian Glaubitz added the comment: I'm a Debian Developer and maintainer for multiple Debian Ports architectures. Please don't remove support for Alpha, HPPA, m68k, ia64, PowerPC, SuperH, SPARC as we're still maintaining these in Debian. Here are the latest build results

[issue43127] Unable to install Python 3.9.1 - Windows 10

2021-02-04 Thread Adrian Lloyd
New submission from Adrian Lloyd : I get the following error when I try to install Python 3.9.1 on windows 10 0x80070659 The installation is forbidden by system policy. The log gives more information: [13A0:0FC0][2021-02-04T16:41:04]e000: Error 0x80070659: Failed to install MSI package

[issue42405] Add distutils mvsccompiler support for Windows ARM64 build

2020-11-20 Thread Adrian Vladu
Adrian Vladu added the comment: Thank you for the suggestion, I will update the PR accordingly to change the __msvccompiler.py. I just need to find a good candidate that uses that implementation to check if the compilation gets fixed

[issue42405] Add distutils mvsccompiler support for Windows ARM64 build

2020-11-19 Thread Adrian Vladu
Adrian Vladu added the comment: This fix is __required__ to build a lot of important packages in the python ecosystem, like numpy, pandas, pywin32 and probably a lot more, as most of these important packages have not migrated to setuptools and usually maintain support for multiple python

[issue42405] Add distutils mvsccompiler support for Windows ARM64 build

2020-11-19 Thread Adrian Vladu
Change by Adrian Vladu : -- keywords: +patch pull_requests: +22291 stage: -> patch review pull_request: https://github.com/python/cpython/pull/23399 ___ Python tracker <https://bugs.python.org/issu

[issue42405] Add distutils mvsccompiler support for Windows ARM64 build

2020-11-19 Thread Adrian Vladu
New submission from Adrian Vladu : To add support for building packages that have C extensions on Windows ARM64, some fixes are required in the integrated distutils wrapper for Visual Studio compiler (Lib/distutils/msvc9compiler.py) This is a hardcoded fix that needs to be improved so

[issue39875] urllib.request.urlopen sends POST data as query string

2020-03-06 Thread Adrian Petrescu
Adrian Petrescu added the comment: (Oops, that was a bad paste! I meant this link: https://docs.python.org/2/library/urllib.html#urllib.urlopen) -- ___ Python tracker <https://bugs.python.org/issue39

[issue39875] urllib.request.urlopen sends POST data as query string

2020-03-06 Thread Adrian Petrescu
Adrian Petrescu added the comment: This is not a bug, you've just misunderstood the urllib API. If you want to pass POST data as a payload, it's the second `data` parameter to `urlopen`: https://bugs.python.org/?@action=confrego=KX9AqsI0JnOLkplIY1AGKXAmDKa38COy -- nosy: +apetresc

[issue35448] ConfigParser .read() - handling of nonexistent files

2019-10-22 Thread Adrian Wielgosik
Adrian Wielgosik added the comment: Yeah, I lost steam on this issue, sorry. Go ahead :) -- ___ Python tracker <https://bugs.python.org/issue35448> ___ ___ Pytho

[issue35448] ConfigParser .read() - handling of nonexistent files

2018-12-09 Thread Adrian Wielgosik
New submission from Adrian Wielgosik : Documentation of ConfigParser says: > If a file named in filenames cannot be opened, that file will be ignored. > This is designed so that you can specify an iterable of potential > configuration file locations (for example, the current

[issue34918] Python 3 tkinter measurement problem

2018-10-06 Thread Adrian Keister
New submission from Adrian Keister : tkinter.Tk().winfo_screenmmwidth() and tkinter.Tk().winfo_screenmmheight() give manifestly incorrect values in Windows. This does not appear to be an issue in Linux. I have not tested a Mac. The values reported in Windows are too large by as much as 58

[issue34334] QueueHandler logs exc_info twice

2018-08-04 Thread Adrian Dries
New submission from Adrian Dries : Since Python 3.7 logging.handlers.QueueHandler logs tracebacks twice:: >>> import logging >>> from logging.handlers import QueueHandler, QueueListener >>> from queue import Queue >>> q = Queue() >>>

[issue33094] dataclasses: ClassVar attributes are not working properly

2018-03-20 Thread Adrian Stachlewski
Adrian Stachlewski <adrian.stachlew...@gmail.com> added the comment: There's nothing to do, thanks for help one more again. -- status: pending -> open ___ Python tracker <rep...@bugs.python.org> <https://bugs.pyt

[issue33100] dataclasses and __slots__ - non-default argument (member_descriptor)

2018-03-19 Thread Adrian Stachlewski
Adrian Stachlewski <adrian.stachlew...@gmail.com> added the comment: There's also another major problem. Because Base.x has value, __init__ is not prepared correctly (member_descriptor is passed as default). @dataclass class Base: __slots__ = ('x',) x: Any Base() # No Typ

[issue33100] dataclasses and __slots__ - non-default argument (member_descriptor)

2018-03-19 Thread Adrian Stachlewski
Adrian Stachlewski <adrian.stachlew...@gmail.com> added the comment: I don't really get your point. @dataclass class Base: __slots__ = ('x',) x: Any This case is described in PEP 557 as correct, so I don't understand why you want to generate error. Also inheritance without de

[issue33094] dataclasses: ClassVar attributes are not working properly

2018-03-19 Thread Adrian Stachlewski
Adrian Stachlewski <adrian.stachlew...@gmail.com> added the comment: Once more same mistake. 'x' should be declared as: - x: ClassVar[set] = set() - x: ClassVar[Set[Any]] = set() -- ___ Python tracker <rep...@bugs.python.or

[issue33100] dataclasses and __slots__ - non-default argument (member_descriptor)

2018-03-18 Thread Adrian Stachlewski
New submission from Adrian Stachlewski <adrian.stachlew...@gmail.com>: I've tried to declare two classes @dataclass class Base: __slots__ = ('x',) x: Any @dataclass class Derived(Base): x: int y: int As long as I correctly understood PEP 557 (inheritance part), changin

[issue33094] dataclasses: ClassVar attributes are not working properly

2018-03-18 Thread Adrian Stachlewski
Adrian Stachlewski <adrian.stachlew...@gmail.com> added the comment: Thanks for explaining. I was trying to do something like @dataclass class A: x: ClassVar = set() and thanks to you I know it should be @dataclass class A: x: ClassVar[Set] = set() If you are looking for improved

[issue33094] dataclasses: ClassVar attributes are not working properly

2018-03-17 Thread Adrian Stachlewski
New submission from Adrian Stachlewski <adrian.stachlew...@gmail.com>: Class variables should behave in the same way whether with or without ClassVar annotation. Unfortunately there are not. class A: __slots__ = () x: ClassVar = set() A() # it's ok @dataclass class B: __s

[issue31453] Debian Sid/Buster: Cannot enable TLS 1.0/1.1 with PROTOCOL_TLS

2017-09-13 Thread Adrian Vollmer
Adrian Vollmer added the comment: I have a workaround for now: versions = [ssl.PROTOCOL_TLSv1, ssl.PROTOCOL_TLSv1_1, ssl.PROTOCOL_TLSv1_2, ] firstbytes = s.recv(16, socket.MSG_PEEK) ss = ssl.wrap_socket

[issue31453] ssl.PROTOCOL_TLS only select TLSv1.2

2017-09-13 Thread Adrian Vollmer
Adrian Vollmer added the comment: Okay, thanks for your time! -- ___ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue31453> ___ ___ Pyth

[issue31453] ssl.PROTOCOL_TLS only select TLSv1.2

2017-09-13 Thread Adrian Vollmer
Adrian Vollmer added the comment: Doesn't seem to do anything: >>> ctx.options 2181170175L >>> ctx.options & ~(ssl.OP_NO_TLSv1 | ssl.OP_NO_TLSv1_1) 2181170175L -- ___ Python tracker <rep...@bugs.python.org> <htt

[issue31453] ssl.PROTOCOL_TLS only select TLSv1.2

2017-09-13 Thread Adrian Vollmer
Adrian Vollmer added the comment: I read about that, but I don't understand. If I use openssl s_server -port , I can connect using either one of the three protocols. Even if that's the new default, is there no way now to get python on Buster/Sid to use OpenSSL in a non-default mode

[issue31453] ssl.PROTOCOL_TLS only select TLSv1.2

2017-09-13 Thread Adrian Vollmer
Adrian Vollmer added the comment: Debian buster/sid -- ___ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue31453> ___ ___ Python-bugs-

[issue31453] ssl.PROTOCOL_TLS only select TLSv1.2

2017-09-13 Thread Adrian Vollmer
New submission from Adrian Vollmer: According to the documentation (https://docs.python.org/2/library/ssl.html#ssl.PROTOCOL_TLS), using ssl_version = ssl.PROTOCOL_TLS in a server socket should offer all TLS/SSL versions. However, it only offers TLSv1_2. I attached a proof of concept

[issue24700] array compare is hideously slow

2017-08-06 Thread Adrian Wielgosik
Adrian Wielgosik added the comment: Added a PR with a fast path that triggers when compared arrays store values of the same type. In this fast path, no Python objects are created. For big arrays the runtime reduction can reach 50-100x. It's possible to optimize the comparison loop a bit more

[issue24700] array compare is hideously slow

2017-08-06 Thread Adrian Wielgosik
Changes by Adrian Wielgosik <adrian.wielgo...@gmail.com>: -- pull_requests: +3042 ___ Python tracker <rep...@bugs.python.org> <http://bugs.python

[issue30545] Enum equality across modules: comparing objects instead of values

2017-06-05 Thread Adrian Wan
Changes by Adrian Wan <adrianw...@gmail.com>: -- nosy: +adrianwan2 status: pending -> open ___ Python tracker <rep...@bugs.python.org> <http://bugs.pyt

[issue29586] Cannot run pip in fresh install of py 3.5.3

2017-02-20 Thread Adrian Chan
Adrian Chan added the comment: Ah, I'd forgotten about that. When I first tried to run python I got an error complaining about a missing api-ms-win-crt-runtime-l1-1.0.dll I installed the necessary VC redistributable and it solved that problem. So that's why I could successfully ensurepip

[issue29586] Cannot run pip in fresh install of py 3.5.3

2017-02-17 Thread Adrian Chan
Adrian Chan added the comment: Install logs attached. First set from initial install, second set from repair. -- Added file: http://bugs.python.org/file46645/py_install_logs.tar.gz ___ Python tracker <rep...@bugs.python.org> <http://bugs.p

[issue29586] Cannot run pip in fresh install of py 3.5.3

2017-02-17 Thread Adrian Chan
Adrian Chan added the comment: It's all working fine now, thanks. If one of the installer/windows guys wants to dig more into why this didn't install properly I'm happy to run things in my environment as necessary. -- ___ Python tracker <

[issue29586] Cannot run pip in fresh install of py 3.5.3

2017-02-17 Thread Adrian Chan
Adrian Chan added the comment: Thanks, but I know how to drive a terminal ;) Your hunch was basically correct though. I ran again with `python -v -m pip` (see with_pip_dir.txt), and see that python is attempting to import pip from my user directory (C:\Users\amc2\pip). This is an empty

[issue29586] Cannot run pip in fresh install of py 3.5.3

2017-02-17 Thread Adrian Chan
Adrian Chan added the comment: There is no traceback, that is the entirety of the output of the command. Python bin is C:\Python\Python35-32\python.exe PYTHONHOME is not set. PYTHONPATH is C:\python27\lib\site-packages\ I don't know why PYTHONPATH was set. I cleared it but it made

[issue29586] Cannot run pip in fresh install of py 3.5.3

2017-02-17 Thread Adrian Chan
New submission from Adrian Chan: I uninstalled python 2.7 and 3.4, then performed a fresh install of 3.5.3. Running pip with `python -m pip` as per https://docs.python.org/3.5/installing gives the following error: C:\Python\Python35-32\python.exe: No module named pip.__main__; 'pip

[issue28813] Remove unneeded folded consts after peephole

2016-11-27 Thread Adrian Wielgosik
Adrian Wielgosik added the comment: Attached squashed patch. > But moving constant folding from the peephole optimizer to the AST level > (...) would totally eliminate the need in your patch. I'm aware of that and I'm okay with it. I chose an unfortunate moment for implem

[issue28813] Remove unneeded folded consts after peephole

2016-11-27 Thread Adrian Wielgosik
Changes by Adrian Wielgosik <adrian.wielgo...@gmail.com>: Added file: http://bugs.python.org/file45662/clean_co_consts.patch ___ Python tracker <rep...@bugs.python.org> <http://bugs.python

[issue28813] Remove unneeded folded consts after peephole

2016-11-27 Thread Adrian Wielgosik
Changes by Adrian Wielgosik <adrian.wielgo...@gmail.com>: -- keywords: +patch Added file: http://bugs.python.org/file45661/indices_tweak.patch ___ Python tracker <rep...@bugs.python.org> <http://bugs.python

  1   2   >