[issue36210] correct AIX logic in setup.py for (non-existant) optional extensions

2019-09-25 Thread Michael Felt
Michael Felt added the comment: Added a backport for 3.8. p.s. - what is the file "name of the past"? -- ___ Python tracker <https://bugs.python.o

[issue36210] correct AIX logic in setup.py for (non-existant) optional extensions

2019-09-25 Thread Michael Felt
Change by Michael Felt : -- pull_requests: +15955 pull_request: https://github.com/python/cpython/pull/16376 ___ Python tracker <https://bugs.python.org/issue36

[issue36210] correct AIX logic in setup.py for (non-existant) optional extensions

2019-09-24 Thread Michael Felt
Michael Felt added the comment: Hi all, Now that I have finally noticed that the 3.8 branches are active for AIX bots I see something that I had always thought was in the 3.8 branch, but is not yet. https://github.com/python/cpython/pull/12202 Seems the backport never succeeded. Although

[issue38101] Update devguide triaging keywords

2019-09-22 Thread Ido Michael
Ido Michael added the comment: Thanks Karthikeyan! Found it, so for the last one pep3121, would you like to describe PEP in general or Extension Module Initialization and Finalization? Ido -- ___ Python tracker <https://bugs.python.

[issue15436] __sizeof__ is not documented

2019-09-22 Thread Ido Michael
Ido Michael added the comment: I can add those changes if someone didn't take it already? Ido -- nosy: +Ido Michael ___ Python tracker <https://bugs.python.org/issue15

[issue27873] multiprocessing.pool.Pool.map should take more than one iterable

2019-09-22 Thread Ido Michael
Ido Michael added the comment: Hey, Is it still open? What else needs to be done? Ido -- nosy: +Ido Michael ___ Python tracker <https://bugs.python.org/issue27

[issue36947] [Good first issue] Fix 3.3.3.1 Metaclasses Documentation

2019-09-22 Thread Ido Michael
Ido Michael added the comment: Hey, Is someone working on this issue? Can I take it? Ido -- nosy: +Ido Michael ___ Python tracker <https://bugs.python.org/issue36

[issue38101] Update devguide triaging keywords

2019-09-22 Thread Ido Michael
Ido Michael added the comment: Hi Lisa, I can take this (first commit), where can I edit the dev guide? I could see someone did update the easy keyword in it? Ido -- nosy: +Ido Michael ___ Python tracker <https://bugs.python.org/issue38

[issue30256] Adding a SyncManager Queue proxy to a SyncManager dict or Namespace proxy raises an exception

2019-09-21 Thread Michael Tippie
Michael Tippie added the comment: I am getting this error now, too. I'm not sure what's causing it - when I use multiprocessing with a Manager.Queue, if I am passing around an object on the queue stack, I get this error. Would really like it to "just work". -- nos

Re: Python shows error on line 15 that i cant fix

2019-09-21 Thread Michael Torrie
On 9/21/19 12:51 PM, Dave Martin wrote: > You seem to have the expectation that you know more about coding than > me and that you can insult me without me retaliating. If I were you, > I would leave this forum and never respond to another person question > again, if you think that you can rudely

[issue27071] unittest.TestCase.assertCountEqual is a very misleading name

2019-09-16 Thread Michael Foord
Michael Foord added the comment: I like assertPermutation (with or without the Is, slight preference for without). -- ___ Python tracker <https://bugs.python.org/issue27

Re: What about idea of making a "Pythonic Lisp"...i.e. a Lisp that more closely resembles the syntax of Python?

2019-09-15 Thread Michael Torrie
On 9/15/19 9:10 AM, Christian Seberino wrote: > Say if I may ask a tangential question...I've always wondered whether it > would be not too hard to compile Python source code to a Lisp like source > code? How hard would it be to say compile Python source to Clojure source? I'm sure a compiler

Re: What about idea of making a "Pythonic Lisp"...i.e. a Lisp that more closely resembles the syntax of Python?

2019-09-15 Thread Michael Torrie
On 9/14/19 8:19 PM, Louis Valence wrote: > I had to read this twice. It confused the hell out of me. Anyhow, I > suppose you should take a look at > > https://github.com/hylang/hy Yup that's probably exactly the opposite of what the OP was asking about. Neat, though. --

[issue5396] os.read not handling O_DIRECT flag

2019-09-13 Thread Michael Mol
Michael Mol added the comment: I wound up writing it in C++ instead, and my then-employer eventually opened my code. https://github.com/VirtualInterconnect/diskstress -- ___ Python tracker <https://bugs.python.org/issue5

[issue38136] Remove AsyncMock.assert_awaited_*

2019-09-12 Thread Michael Foord
Michael Foord added the comment: I'm particularly concerned that we have call_count "sane" for AsyncMock and avoid adding "await_count" if possible. I think we've decided on that. I'm more agnostic on the assert_await* methods. I agree they're a nice API. I don't mind

[issue25597] unittest.mock does not wrap dunder methods (__getitem__ etc)

2019-09-12 Thread Michael Foord
Michael Foord added the comment: The previous behaviour was unspecified and clearly due to missing functionality, so the advantages of fixing it outweigh any potential compatibility issues. But I'd see it as a feature enhancement for 3.9

[issue25597] unittest.mock does not wrap dunder methods (__getitem__ etc)

2019-09-12 Thread Michael Foord
Michael Foord added the comment: As discussed with Karthik, I think this is a nice feature enhancement for the wraps functionality and worth fixing. It has the great advantage that the fix is nice and isolated and simple. -- ___ Python tracker

[issue36871] Misleading error from unittest.mock's assert_has_calls

2019-09-12 Thread Michael Foord
Michael Foord added the comment: (The code that generated functions was originally borrowed from the decorator module by Michele Simionato. When I first started in Python, around 2002, I was impressed by the Python community as it had two very prominent women amongst the part

[issue36871] Misleading error from unittest.mock's assert_has_calls

2019-09-12 Thread Michael Foord
Michael Foord added the comment: The code around whether or not to swallow self is hairy. Even if the original spec object is a class we may still be mocking an instance of the class (we don't want users to have to create an instance just to be able to use it as a spec). So we have to carry

[issue38122] AsyncMock force always creating an AsyncMock for child mocks

2019-09-12 Thread Michael Foord
Michael Foord added the comment: That may change though, right? In general I dislike the proliferation of keyword arguments if it's at all possible to avoid. I added way too many of them originally and the mock API is really big. -- ___ Python

[issue30587] Mock with spec object does not ensure method call signatures

2019-09-10 Thread Michael Foord
Michael Foord added the comment: This will affect spec and spec_set. -- ___ Python tracker <https://bugs.python.org/issue30587> ___ ___ Python-bugs-list mailin

[issue30587] Mock with spec object does not ensure method call signatures

2019-09-10 Thread Michael Foord
Michael Foord added the comment: I'd like spec to have signature validation. I don't think the use case for "attribute validation only" (current spec behaviour) is very strong and I'd rather not add new keywords. The mock API is already too complex. I'll take the existing PR

[issue24564] shutil.copytree fails when copying NFS to NFS

2019-09-09 Thread Michael Burt
Michael Burt added the comment: This is still a problem when shutil gets a errno.ENOSYS I hit this bug on Microsoft Azure when I mount an Azure File (managed NFS) into an AKS cluster (managed Kubernetes offering) and try to copy a file from the NFS over to the local disk on the node using

[issue34596] [unittest] raise error if @skip is used with an argument that looks like a test method

2019-09-09 Thread Michael Foord
Change by Michael Foord : -- assignee: -> michael.foord components: +Extension Modules -Library (Lib), Tests resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python

[issue34596] [unittest] raise error if @skip is used with an argument that looks like a test method

2019-09-09 Thread Michael Foord
Michael Foord added the comment: I'm in favour of a default and "Unconditionally skipped" is fine with me. Although "Skipped" would also be fine. Making @skip work with no arguments is fine. Having to pass in arguments message arguments you don't want is a pain and ther

[issue38021] pep425 tag for AIX is inadequate

2019-09-08 Thread Michael Felt
Michael Felt added the comment: When testing the PR with --with-pydebug I started getting the following error: root@x066:[/data/prj/python/git/pr-test]./python '-X' 'tracemalloc' -m test test_venv Run tests sequentially 0:00:00 [1/1] test_venv test test_venv failed -- Traceback (most recent

Re: 3 cubes that sum to 42

2019-09-08 Thread Michael F. Stemper
amazing! In fact, I ended up writing a tiny program to cube its arguments and report the sum. Took about 40 ms to run, no matter the size of the arguments, which tells me that the only cost is the fixed overhead. -- Michael F. Stemper This sentence no verb. -- https://mail.python.org/mailman/listinfo/python-list

Re: Renaming an import

2019-09-05 Thread Michael Speer
pkg/graph.py: from graphing_module_b import plot, axis pkg/foobar.py: from .graph import plot, axis Would it be sufficient to use a file for indirection? On Thu, Sep 5, 2019 at 7:11 PM Rob Gaddi wrote: > I'm trying to figure out how to rename an import globally for an entire >

Re: "How to protect the python code"

2019-09-05 Thread Michael Torrie
On 9/5/19 2:48 AM, Saba Kauser wrote: > I am looking for ways available to protect the python source code > from being available to users for write/modify. Is it a good idea to > think that python source code can be protected? In general, no, not with an interpreted language. Intellectual

[issue38021] pep425 tag for AIX is inadequate

2019-09-04 Thread Michael Felt
Change by Michael Felt : -- keywords: +patch pull_requests: +15337 stage: -> patch review pull_request: https://github.com/python/cpython/pull/15678 ___ Python tracker <https://bugs.python.org/issu

[issue38021] pep425 tag for AIX is inadequate

2019-09-04 Thread Michael Felt
Michael Felt added the comment: Thank you Ned. Not a justification perhaps, but a way to specify that it is support. Three+ years ago when I first worked on something for Lib/ctypes to get find_library() et al working for AIX I was also asked to add it as _aix.py similar to the macos

[issue38021] pep425 tag for AIX is inadequate

2019-09-03 Thread Michael Felt
New submission from Michael Felt : PEP425 stats the platform tag is what distutils.util.get_platform() (and sysconfig.get_platform()) returns. By that definition - anything is okay, as long as something is returned. However, in practice, it is insufficient. Simplest case

[issue38013] AsyncGenerator breaks when not iterated fully with RuntimeError("can't send non-None value to a just-started coroutine")

2019-09-02 Thread Michael Yoo
New submission from Michael Yoo : Version: Python 3.7.3 When I run this code: import asyncio class TestAsyncGenerator: def __init__(self): pass async def aiter(self): yield 1 yield 2 async def main(): gen = TestAsyncGenerator() async for number

Re: if STREAM.isatty():

2019-08-30 Thread Michael Torrie
On Fri, Aug 30, 2019, 05:02 Hongyi Zhao On Fri, 30 Aug 2019 17:53:02 +1000, Chris Angelico wrote: > > (Also, why the sleep? Seems unnecessary.) > > Because without using sleep, the stuff on screen will display very > shortly and then disappear. Is this not your testing result? No it is not.

Re: Style suggestions/critiques

2019-08-23 Thread Michael F. Stemper
On 20/08/2019 21.57, DL Neil wrote: > On 21/08/19 9:11 AM, Michael F. Stemper wrote: >> I recently wrote a couple of modules (more to come) to help me >> use the tikz package in TeX/LaTeX. Since it's all to do with >> drawing, I have a lot of points in R^2. Being unimagin

Re: How should we use global variables correctly?

2019-08-22 Thread Michael Torrie
On 8/22/19 10:00 AM, Windson Yang wrote: > I can 'feel' that global variables are evil. I also read lots of articles > proves that (http://wiki.c2.com/?GlobalVariablesAreBad). However, I found > CPython Lib use quite a lot of `global` keyword. So how should we use > `global` keyword correctly?

[issue37917] Warning regarding collections ABCs still present in 3.9

2019-08-22 Thread Michael Anckaert
New submission from Michael Anckaert : When importing an ABC from the collections module in Python 3.9 there is a warning that this is deprecated since Python 3.3 and will stop working in Python 3.9. Should this warning be removed and lead to an ImportError? Python 3.9.0a0 (heads

[issue37914] class timedelta, support the method hours and minutes in field accessors

2019-08-22 Thread Michael Anckaert
Michael Anckaert added the comment: Thank you for the clarification Paul. It makes sense to me now to not include those accessors. On Thu, 22 Aug 2019 at 17:46, Paul Ganssle wrote: > > Paul Ganssle added the comment: > > > I would support this addition. The timedelta cl

[issue17306] Improve the way abstract base classes are shown in help()

2019-08-22 Thread Michael Anckaert
Michael Anckaert added the comment: I would be very interested and motivated to work on this. I'll start by taking a look at the pointers Raymond gave. If anyone can chime in with some more information / guidance that would be awesome. -- nosy: +michaelanckaert

[issue37914] class timedelta, support the method hours and minutes in field accessors

2019-08-22 Thread Michael Anckaert
Michael Anckaert added the comment: I would support this addition. The timedelta class already has accessors for days and seconds, why not for hours and minutes? The implementation should make use of the idiomatic way as Serhiy mentioned. >>> timedelta(hours=25).seconds

[issue19820] docs are missing info about module attributes

2019-08-21 Thread Michael Anckaert
Change by Michael Anckaert : -- keywords: +patch pull_requests: +15071 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/15359 ___ Python tracker <https://bugs.python.org/issu

Style suggestions/critiques

2019-08-20 Thread Michael F. Stemper
spattered all over. Although this is simple enough, I find it aesthetically unappealing. Is there some better idiom that I should be using, or is this really in accord with The Zen of Python? [1] (I could have done sets, I suppose, but orientation might be useful at some point.) -- Michael F

[issue37877] MacOS crash appJar 3.7.3

2019-08-16 Thread Michael Hearn
Michael Hearn added the comment: Hopefully apple will fix this. https://medium.com/@michaeljosephhearn/macos-mojave-crash-6fd1e69d3d34 -- ___ Python tracker <https://bugs.python.org/issue37

[issue37877] MacOS crash appJar 3.7.3

2019-08-16 Thread Michael Hearn
Change by Michael Hearn : -- resolution: -> third party stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue37877] MacOS crash appJar 3.7.3

2019-08-16 Thread Michael Hearn
Michael Hearn added the comment: Thanks for the fast response it uses appJar which is a very similar GUI package but not the same one. AppJar is based of it but I don’t believe it was built off it. On Fri, Aug 16, 2019 at 3:55 PM Ronald Oussoren wrote: > > Ronald Oussoren added the c

[issue37877] MacOS crash appJar 3.7.3

2019-08-16 Thread Michael Hearn
New submission from Michael Hearn : macOS 10.14.6 -anaconda install Python 3.7.3 pip install appJar (0.94.0) On start of app with app.go() a crash will occur causing mac to logout. Python 3.7.2 does not show this behavior Will document on medium. https://raw.githubusercontent.com

[issue37877] MacOS crash appJar 3.7.3

2019-08-16 Thread Michael Hearn
Change by Michael Hearn : -- components: macOS nosy: Michael Hearn, ned.deily, ronaldoussoren priority: normal severity: normal status: open title: MacOS crash appJar 3.7.3 versions: Python 3.7 ___ Python tracker <https://bugs.python.org/issue37

[issue19820] docs are missing info about module attributes

2019-08-14 Thread Michael Anckaert
Michael Anckaert added the comment: @emmanuel: thanks for offering your help. I made a first attempt at improving the docs in this branch: https://github.com/MichaelAnckaert/cpython/tree/bpo-19820 -- ___ Python tracker <https://bugs.python.

[issue1823] Possible to set invalid Content-Transfer-Encoding on email.mime.multipart.MIMEMultipart

2019-08-14 Thread Michael Anckaert
Michael Anckaert added the comment: This issue is still present on Python 3.7 and above. As David suggested set_charset could be turned into a no-op on MIMEMultipart. I traced set_charset back to inheritance from email.message.Message, would overriding set_charset (and possibly raising

[issue19820] docs are missing info about module attributes

2019-08-14 Thread Michael Anckaert
Michael Anckaert added the comment: As far as I can tell there is at least some information missing from the 'Types and members' section. Not all attributes are listed in the table. For example the attribute __cached__ is missing from the module type but it is documented in the inspect

[issue37823] Telnet documentation: fix the link to open()

2019-08-14 Thread Michael Anckaert
Michael Anckaert added the comment: I created a PR for this issue (PR 15281). If any changes are required I'm more than happy to make them. -- nosy: +michaelanckaert ___ Python tracker <https://bugs.python.org/issue37

[issue37823] Telnet documentation: fix the link to open()

2019-08-14 Thread Michael Anckaert
Change by Michael Anckaert : -- keywords: +patch pull_requests: +15005 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/15281 ___ Python tracker <https://bugs.python.org/issu

[issue23885] urllib.quote horribly mishandles unicode as second parameter

2019-08-14 Thread Michael Sander
Michael Sander added the comment: Couldn't this be fixed in a backwards compatible way by clearing the cache when this type of error occurs? We can do this by wrapping the offending line with a try/except, then checking to see if the cache is corrupted. If it is, then we clear the cache

Re: Web framework for static pages

2019-08-12 Thread Michael Torrie
On 8/12/19 1:14 AM, morphex wrote: > What frameworks are there for generating static web pages in Python? What are > the features of each? A quick google search reveals a number of them. Pelican, Hyde, etc. -- https://mail.python.org/mailman/listinfo/python-list

Re: help with tkinter

2019-08-09 Thread Michael Torrie
On 8/9/19 4:52 AM, Peter J. Holzer wrote: > On 2019-08-09 10:34:34 +0300, Ahmad Adam Kabbara wrote: >> so when I write from >> tkinter import* >> t=Tk() >> tkinter.colorchooser.askcolor() >> I get this error message >> Traceback (most recent call last): >> File "C:\Users\kabba\Desktop\color and

[issue26131] Raise ImportWarning when loader.load_module() is used

2019-08-09 Thread Michael Anckaert
Michael Anckaert added the comment: Clarification: the imp module shows a DeprecationWarning when imported. Was this what was meant? -- ___ Python tracker <https://bugs.python.org/issue26

[issue26131] Raise ImportWarning when loader.load_module() is used

2019-08-09 Thread Michael Anckaert
Michael Anckaert added the comment: I checked out the source (Lib/imp.py:219) and only see the docstring marking this method als Deprecated. No exceptions are being raised. I would like to work on this issue. -- nosy: +michaelanckaert ___ Python

[issue37796] ModuleFinder does not resolve ".." correctly

2019-08-08 Thread Michael Kleehammer
New submission from Michael Kleehammer : The modulefinder module does not handle relative directories properly. The error I found is when one subpackage attempts to import from a sibling subpackage using the form from ..language import ( DirectiveDefinitionNode

[issue35545] asyncio.base_events.create_connection doesn't handle scoped IPv6 addresses

2019-08-05 Thread Michael Felt
Michael Felt added the comment: I did not ask back in June - but could this also be backported to 3.7. I am trying very hard to have all tests also passing on 3.7. as @asvetlov is ok with a skipped test for AIX - see https://bugs.python.org/issue35545#msg344003 I can make the backport

[issue36273] test_thread leaks a core dump on PPC64 AIX 3.x

2019-08-03 Thread Michael Felt
Michael Felt added the comment: correction - issue18049 was related to test_threading. cannot say for sure that "this" is resolved by 18049. apologies for noise. -- ___ Python tracker <https://bugs.python.o

[issue36273] test_thread leaks a core dump on PPC64 AIX 3.x

2019-08-03 Thread Michael Felt
Michael Felt added the comment: resolved via issue18049 -- ___ Python tracker <https://bugs.python.org/issue36273> ___ ___ Python-bugs-list mailing list Unsub

[issue37733] Fail to build _curses module of Python 3.7.4 on AIX 7.1 using gcc

2019-08-02 Thread Michael Felt
Michael Felt added the comment: Issue36210 needs a back-port to 3.7 and 3.6. -- ___ Python tracker <https://bugs.python.org/issue37733> ___ ___ Python-bug

[issue18049] Re-enable threading test on macOS

2019-08-02 Thread Michael Felt
Change by Michael Felt : -- pull_requests: +14827 pull_request: https://github.com/python/cpython/pull/15081 ___ Python tracker <https://bugs.python.org/issue18

[issue18049] Re-enable threading test on macOS

2019-08-02 Thread Michael Felt
Michael Felt added the comment: On 02/08/2019 11:57, Michael Felt wrote: > On 02/08/2019 11:48, Ronald Oussoren wrote: >> Ronald Oussoren added the comment: >> >> That code is only called if THREAD_STACK_SIZE is defined. The block I >> mention defin

[issue18049] Re-enable threading test on macOS

2019-08-02 Thread Michael Felt
Michael Felt added the comment: On 02/08/2019 11:48, Ronald Oussoren wrote: > Ronald Oussoren added the comment: > > That code is only called if THREAD_STACK_SIZE is defined. The block I mention > defines it for macOS and FreeBSD, but not for other platforms. I therefo

[issue18049] Re-enable threading test on macOS

2019-08-02 Thread Michael Felt
Michael Felt added the comment: Going to take a stab in the dark - the the issue lies here: "./Python/errors.c" #ifndef Py_NORMALIZE_RECURSION_LIMIT #define Py_NORMALIZE_RECURSION_LIMIT 32 #endif As there is not enough memory for this to run in the default memory model. Howeve

[issue18049] Re-enable threading test on macOS

2019-08-02 Thread Michael Felt
Michael Felt added the comment: *** Looking in ./Python/thread_pthread.h" +252 #if defined(THREAD_STACK_SIZE) +253 PyThreadState *tstate = _PyThreadState_GET(); +254 size_t stacksize = tstate ? tstate->interp->pythread_stacksize : 0; +255 tss = (sta

[issue18049] Re-enable threading test on macOS

2019-08-02 Thread Michael Felt
Michael Felt added the comment: @Ronald - thanks. Gives me something to work from. Would not have found this so easily! But - where to put it... :) -- nosy: +Michael.Felt ___ Python tracker <https://bugs.python.org/issue18

[issue36273] test_thread leaks a core dump on PPC64 AIX 3.x

2019-08-01 Thread Michael Felt
Michael Felt added the comment: On 01/08/2019 11:15, STINNER Victor wrote: > FAILED (failures=1) > Warning -- files was modified by test_threading > Before: [] > After: ['core'] Thanks. I'll look again (on my bot) and other test systems. What I assume has not been cl

Re: Boolean comparison & PEP8

2019-07-29 Thread Michael F. Stemper
On 29/07/2019 12.56, Rob Gaddi wrote: > On 7/29/19 10:44 AM, Michael F. Stemper wrote: >> On 28/07/2019 19.04, Chris Angelico wrote: >>> On Mon, Jul 29, 2019 at 9:48 AM Michael Torrie >>> wrote: >>>> Yet the recommended solution to the problem of wanting a

Re: Boolean comparison & PEP8

2019-07-29 Thread Michael F. Stemper
On 28/07/2019 19.04, Chris Angelico wrote: > On Mon, Jul 29, 2019 at 9:48 AM Michael Torrie wrote: >> >> On 7/28/19 5:55 AM, Jonathan Moules wrote: >>> But this appears to be explicitly called out as being "Worse" in PEP8: >>> >>> "&

[issue37690] Simplify linking of shared libraries on the AIX OS

2019-07-29 Thread Michael Felt
Michael Felt added the comment: David gives several reasons why this PR should not be used. And, in reading them - while I follow them at face value, there may be things I miss due to ignorance or being naive (more the system admin than tool developer). Isn't there an configure --enable

Re: Boolean comparison & PEP8

2019-07-28 Thread Michael Torrie
On 7/28/19 6:04 PM, Chris Angelico wrote: > This is a fairly unusual case, though. More commonly, the default > would be None, not False, and "if bar is None:" is extremely well > known and idiomatic. Ahh yes, true. > This analysis is correct, but the situations where you *actually* want > to

Re: Boolean comparison & PEP8

2019-07-28 Thread Michael Torrie
On 7/28/19 5:55 AM, Jonathan Moules wrote: > But this appears to be explicitly called out as being "Worse" in PEP8: > > """ > Don't compare boolean values to True or False using ==. > > Yes:   if greeting: > No:    if greeting == True: > Worse: if greeting is True: > """ Yet the recommended

Re: Definite or indefinite article for non-singletons?

2019-07-28 Thread Michael F. Stemper
indeed "a" set, but it's the only set that has the same elements as T. Therefore, once you've let T be some specific non-empty set, it is *the* set T. -- Michael F. Stemper Life's too important to take seriously. -- https://mail.python.org/mailman/listinfo/python-list

[issue36674] "unittest.TestCase.debug" should honour "skip" (and other test controls)

2019-07-28 Thread Michael Foord
Michael Foord added the comment: "I don't know why run() returns None for skipIf cases instead of returning a TestResult with non-empty skipped, as it does for skipTest, or if the None is a separate bug." That does sound

[issue37668] Allow individual test to be specified by "#" or "."

2019-07-28 Thread Michael Foord
Change by Michael Foord : -- resolution: -> rejected stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue37668> ___ ___

[issue37669] Make mock_open return per-file content

2019-07-28 Thread Michael Foord
Michael Foord added the comment: Can you suggest an API for doing this? -- ___ Python tracker <https://bugs.python.org/issue37669> ___ ___ Python-bugs-list m

Re: Proper shebang for python3

2019-07-24 Thread Michael Torrie
On 7/24/19 4:20 PM, Cameron Simpson wrote: > That is some progress, hooray. Then there's just sbin -> bin to go. I suppose in the olden days sbin was for static binaries, usable in single user mode for recovering the system without the main drive mounted. In more recent times, binaries that are

Re: Creating time stamps

2019-07-22 Thread Michael F. Stemper
On 22/07/2019 16.00, Stefan Ram wrote: > "Michael F. Stemper" writes: >> The first seems a little clunky with its accessing of multiple >> attributes, but the second has an additional import. Is there >> any reason to prefer one over the o

Re: Creating time stamps

2019-07-22 Thread Michael F. Stemper
On 22/07/2019 15.58, Chris Angelico wrote: > On Tue, Jul 23, 2019 at 6:34 AM Michael F. Stemper > wrote: >> >> I have some code that generates a time-stamp as follows: >> >> from datetime import datetime >> tt = datetime.now() >> timestamp = &qu

Creating time stamps

2019-07-22 Thread Michael F. Stemper
ime from time import strftime timestamp = datetime.now().strftime( "%Y-%m-%d %H:%M" ) The first seems a little clunky with its accessing of multiple attributes, but the second has an additional import. Is there any reason to prefer one over the other? -- Michael F. Stemper Ther

Re: How to print out html tags excluding the attributes

2019-07-21 Thread Michael F. Stemper
s: > print(a) > > > the output is : > > > > > > > > > But I just want the tag, not the attributes Try this: for a in tags: a = re.sub( " .*>", ">", a ) print(a) (The two statements could be combined.) -- Michael F. Stemper Galatians 3:28 -- https://mail.python.org/mailman/listinfo/python-list

Re: Proper shebang for python3

2019-07-20 Thread Michael Speer
You may want to use `#!/usr/bin/env python3` instead. There is a concept in python called the virtual environment. This used to be done with a tool called virtualenv in python2, and is now done mainly through a venv module in python3. A virtual environment goes into a directory of your choosing

[issue35495] argparse does not honor default argument for nargs=argparse.REMAINDER argument

2019-07-18 Thread Michael Blahay
Michael Blahay added the comment: Ryan, I like option A as well, but it is a breaking change. Unlike in a compiled language where we could output a warning, making the proposed change could bring some software to a grinding halt. For now I'm going to make the documentation change

[issue28009] core logic of uuid.getnode() needs refresh

2019-07-15 Thread Michael Felt
Michael Felt added the comment: On 14/07/2019 22:28, Tal Einat wrote: > Tal Einat added the comment: > >>> The current code and proposed changes use 'netstat -ia' to find the node >>> however if netstat needs to perform a reverse DNS query to resolve some >>

load extention spatialite in sqlite on windows

2019-07-10 Thread MICHAEL LANE via Python-list
OsError 0xc1 (193) (Background on this error at: http://sqlalche.me/e/e3q8) My directory contain the unzip of: http://www.gaia-gis.it/gaia-sins/windows-bin-x86/mod_spatialite-4.3.0a-win-x86.7z The directory is set in %PATH% Any hint will be appreciated. Thanks Michael -- https://mail.python.org/mailman/listinfo/python-list

Re: What's wrong on using Popen's communicate method?

2019-07-05 Thread Michael Torrie
On 07/05/2019 09:03 PM, jf...@ms4.hinet.net wrote: > From Vista to Win10? That's a three generation gap! Buy a new PC might be > a better solution:-) Maybe. Windows 10 would probably run okay on that machine. It might be 10 years old, but if it's 64-bit, Win 10 should run on it. You could

Re: Do I need a parser?

2019-07-02 Thread Michael Torrie
On 07/02/2019 12:47 PM, Thomas Jollans wrote: > Obviously, as Cameron points out, using Python instead of a custom > scripting language has security implications, that go with the increased > power that the user has. I've always found this kind of thing to be a bit strange. I do understand where

Re: Handle foreign character web input

2019-06-30 Thread Michael Torrie
On 06/30/2019 06:21 AM, Richard Damon wrote: > On 6/30/19 4:00 AM, moi wrote: >> Unfortunately not. >> >> The only thing Python succeeds to propose is a mechanism >> which does the opposite of UTF-8 when it comes to handle >> memory *and* - at the same time - which also does the opposite >> of

Re: How do you insert an item into a dictionary (in python 3.7.2)?

2019-06-29 Thread Michael Torrie
On 06/28/2019 09:06 AM, CrazyVideoGamez wrote: > How do you insert an item into a dictionary? For example, I make a dictionary > called "dictionary". > > dictionary = {1: 'value1', 2: 'value3'} > > What if I wanted to add a value2 in the middle of value1 and value3? How about: dict[1.5] =

Re: Use global, or not

2019-06-29 Thread Michael Torrie
On 06/29/2019 05:42 AM, Cecil Westerhof wrote: > That was the other possibility I was thinking about. And that would be > maybe better. Because I now do things like: > global_dict['messages']['created'].format(len(filepathArr)) > > much better would be: >

[issue37166] inspect.findsource doesn't handle shortened files gracefully

2019-06-28 Thread Michael Bejda
Michael Bejda added the comment: I don't think linecache.checkcache helps here. In your example, it would detect the modification, but I don't see how it could persist data if the compilation and execution are different processes. -- ___ Python

[issue37166] inspect.findsource doesn't handle shortened files gracefully

2019-06-28 Thread Michael Bejda
Michael Bejda added the comment: I do not believe it is specific to the way we package things: $ cat a.py: import inspect def foo(): pass inspect.getsource(foo) $ python3 -m compileall -b a.py $ black a.py # to remove the empty lines $ python3 a.pyc # Index error Traceback (most

[issue34373] test_time errors on AIX

2019-06-19 Thread Michael Felt
Change by Michael Felt : -- pull_requests: +14077 pull_request: https://github.com/python/cpython/pull/14242 ___ Python tracker <https://bugs.python.org/issue34

[issue34720] Fix test_importlib.test_bad_traverse for AIX

2019-06-19 Thread Michael Felt
Change by Michael Felt : -- pull_requests: +14074 pull_request: https://github.com/python/cpython/pull/14238 ___ Python tracker <https://bugs.python.org/issue34

[issue11192] test_socket error on AIX

2019-06-19 Thread Michael Felt
Change by Michael Felt : -- pull_requests: +14073 pull_request: https://github.com/python/cpython/pull/14237 ___ Python tracker <https://bugs.python.org/issue11

[issue34347] AIX: test_utf8_mode.test_cmd_line fails

2019-06-19 Thread Michael Felt
Change by Michael Felt : -- pull_requests: +14069 pull_request: https://github.com/python/cpython/pull/14233 ___ Python tracker <https://bugs.python.org/issue34

[issue37336] os.sendfile() support missing for AIX platform

2019-06-19 Thread Michael Felt
New submission from Michael Felt : In AIX "sendfile()" is named send_file(). During testing I learned, unexpectedly, that AIX platform has never provided support of os.sendfile(). This is correct that oversight. >From this (and older) documentation - it seems all th

[issue37243] test_sendfile in asyncio crashes when os.sendfile() is not supported

2019-06-19 Thread Michael Felt
Michael Felt added the comment: Closed. Not a bug in test_sendfile. -- stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/i

<    4   5   6   7   8   9   10   11   12   13   >