[issue21650] add json.tool option to avoid alphabetic sort of fields

2014-06-03 Thread Pavel Kazlou
New submission from Pavel Kazlou: Currently when you use json.tool, fields are reordered alphabetically. In source code the value of sort_keys is hardcoded to be true. It should be easy to expose this option as command line parameter. -- components: Library (Lib) messages: 219675 nosy

[issue21650] add json.tool option to avoid alphabetic sort of fields

2014-06-03 Thread Pavel Kazlou
Pavel Kazlou added the comment: This is the line in module I'm talking about: json.dump(obj, outfile, sort_keys=True, indent=4) -- ___ Python tracker <http://bugs.python.org/is

[issue21650] add json.tool option to avoid alphabetic sort of fields

2014-06-06 Thread Pavel Kazlou
Pavel Kazlou added the comment: The idea is to keep the same order as in input. -- ___ Python tracker <http://bugs.python.org/issue21650> ___ ___ Python-bug

[issue21930] new assert raises syntax proposal

2014-07-07 Thread Pavel Tyslyatsky
New submission from Pavel Tyslyatsky: This proposal look preaty close to pep-463: http://legacy.python.org/dev/peps/pep-0463/, but in assertion context. Now python test libraries have different aproach for assertions, some try use own implementations, for example, for equality `assertEqual

[issue21930] new assert raises syntax proposal

2014-07-07 Thread Pavel Tyslyatsky
Pavel Tyslyatsky added the comment: Thanks for reply, I really missed many cases. I will try look deeper. -- ___ Python tracker <http://bugs.python.org/issue21

[issue20740] Remove invalid number from squares in introduction section

2014-02-22 Thread Pavel Kazakov
New submission from Pavel Kazakov: This is probably being nitpicky, but in the introduction section, the squares list include a 2: squares = [1, 2, 4, 9, 16, 25] However, 2 is not a square number (perfect square). So it should be: [1, 4, 9, 16, 25] I've included a patch that removes

[issue20740] Remove invalid number from squares in introduction section

2014-02-25 Thread Pavel Kazakov
Pavel Kazakov added the comment: > (Alternatively, we could redefine squares in Python. All other languages > just have the regular squares; Python has a super *extra* square 2! That > clearly makes squares in Python *better* than squares in other languages...) Heh. I initially wa

[issue4431] Distutils MSVC doesn't create manifest file (with fix)

2009-02-17 Thread Pavel Repin
Pavel Repin added the comment: I'd like to point out that on some configurations (at least mine), you really need to specify /MANIFEST option to the linker, even though MSDN documentation seems to imply that /MANIFEST behavior is ON by default. My config: beta version of Wind

[issue4431] Distutils MSVC doesn't create manifest file (with fix)

2009-02-17 Thread Pavel Repin
Pavel Repin added the comment: Hi Marc,I am pretty sure it helped on my particular configuration. I was trying to compile MySQL-python-1.2.2.tar.gz package from source and it was failing in mt.exe step because the manifest file was not there. I didn't do anything special on my machine. I h

[issue4431] Distutils MSVC doesn't create manifest file (with fix)

2009-02-17 Thread Pavel Repin
Pavel Repin added the comment: Marc-Andre, I can also repro this on Vista machine with the same Python & MSVS configuration. This is the build error stemming from missing manifest file (unnecessary details elided; note the absence of /MANIFEST option): C:\src\MySQL-python-1.2.2>python s

[issue4832] idle filename extension

2009-05-13 Thread Pavel Kosina
Pavel Kosina added the comment: Trying to patch the latest revision 72608 and it didnt work, here on winxp. C:\prg\Python30\Lib\idlelib>svn update Restored 'IOBinding.py' At revision 72608. C:\prg\Python30\Lib\idlelib>patch IOBinding.py defaultextension.patch --verbose Hmm.

[issue8938] Mac OS dialogs(Save As..., Load) translation

2010-06-08 Thread Pavel Denisow
New submission from Pavel Denisow : We have a problem with using native Mac OS dialogs (Save As..., Load) on Russian Mac: Dialogs are not translated even with file-translation. See attached screenshots. Same code in Linux works perfect. C++ QT project in Mac has translation in native dialogs

[issue9385] python-2.6.5 and 3.2.1 uses 'rwx' mmap() calls for the ctypes module

2010-07-26 Thread Pavel Labushev
Pavel Labushev added the comment: Note that the removing of PROT_EXEC flag doesn't break any ctypes test. -- nosy: +Arach ___ Python tracker <http://bugs.python.org/i

[issue29160] `pow` with three int arguments works like it had two arguments

2017-01-04 Thread Pavel Chuvakhov
New submission from Pavel Chuvakhov: Standard `pow` function of three integer arguments should result in a reminder `(x**y) % z`. It seems that `pow(x,y,z)` ignores `%z` operation if type(z) is not `int`. This happens also in the cases when `z` has type numpy.int32, numpy.int64, etc. I

[issue29160] pow with three int arguments works like it had two arguments

2017-01-04 Thread Pavel Chuvakhov
Pavel Chuvakhov added the comment: Sorry about script, n1 should be n, and n2 should be m. Updated script is attached. Ofc mpz is a way out. One also could cast int( np.int32 ) explicitly. I just wanted to underline that the best way is to hide all this stuff from a user and not make the

[issue27587] Issues, reported by PVS-Studio static analyzer

2016-07-22 Thread Pavel Belikov
New submission from Pavel Belikov: To demonstrate the capabilities of our analyzer, we regularly perform analysis of open source projects. We had recently checked the CPython project. Here is the link to the article about it: http://www.viva64.com/en/b/0414/ Official page of the analyzer: http

[issue4431] Distutils MSVC doesn't create manifest file

2015-01-07 Thread Pavel Repin
Changes by Pavel Repin : -- nosy: -paxan ___ Python tracker <http://bugs.python.org/issue4431> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue16786] argparse doesn't offer localization interface for "version" action

2015-02-20 Thread Pavel Roskin
Pavel Roskin added the comment: I have tested the patch. It fixes the problem for me. You are right, new programs would just supply translated help to the version action. No effort would be saved. But the programs updated from the deprecated syntax may rely on a separate string list for

[issue25303] py_compile disregards PYTHONDONTWRITEBYTECODE and -B

2015-10-02 Thread Pavel Roskin
New submission from Pavel Roskin: $ echo "'''Simple script'''" >simple-script $ PYTHONDONTWRITEBYTECODE=1 python3 -B -m py_compile simple-script $ ls __pycache__ simple-scriptcpython-35.pyc py_compile should recognize when the user doesn't want t

[issue25303] Add option to py_compile to compile for syntax checking without writing bytecode

2015-10-09 Thread Pavel Roskin
Pavel Roskin added the comment: That's what I have now: check: $(PYTHON) -m py_compile $(SOURCES) rm -f $(addsuffix c, $(SOURCES)) make check python -m py_compile redacted-build redacted-git-diff redacted-git-gc redacted-git-status redacted-init redacted-s

[issue25303] Add option to py_compile to compile for syntax checking without writing bytecode

2015-10-10 Thread Pavel Roskin
Pavel Roskin added the comment: Thank you for the comments. I was annoyed by py_compile making files with names very similar to the original scripts, names that could not even be recognized by shell patterns in .gitignore unless scripts ending with "c" are banned. But that

[issue25403] urllib.parse.urljoin is broken in python 3.5

2015-10-14 Thread Pavel Ivanov
New submission from Pavel Ivanov: urllib.parse.urljoin does not conform the RFC 1808 in case of joining relative URL’s containing ‘..’ path components anymore. Examples: Python 3.4: >>> urllib.parse.urljoin('http://a.com', '..') 'http://a.com/..' Pyt

[issue23766] json.dumps: solidus ("/") should be escaped

2015-03-24 Thread Pavel Strashkin
New submission from Pavel Strashkin: According to http://www.json.org/ and https://tools.ietf.org/html/rfc7159#section-7, the solidus ("/") should be escaped ("\/") and currently it's not. -- messages: 239170 nosy: xaka priority: normal severity: normal statu

[issue28486] Wrong end index and subgroup for group match

2016-10-20 Thread Pavel Cisar
Changes by Pavel Cisar : -- versions: +Python 3.5 ___ Python tracker <http://bugs.python.org/issue28486> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue28486] Wrong end index and subgroup for group match

2016-10-20 Thread Pavel Cisar
New submission from Pavel Cisar: Hi, python re returns wrong end index of searched group and also subgroup itself. Example: In: price_string = u"1 307 000,00 Kč" In: match = re.search(r"([,\.]00)\s?.*$", price_string) In: print price_string, "|", matc

[issue28054] Diff for visually comparing actual with expected in mock.assert_called_with.

2016-10-24 Thread Pavel Savchenko
Pavel Savchenko added the comment: An implementation of this exists in pytest-mock. Recently an idea was brought up to shift the development of PR #57 into mock directly for everyone's benefit. https://github.com/pytest-dev/pytest-mock https://github.com/pytest-dev/pytest-mock/pu

<    1   2