[issue14046] argparse: assertion failure if optional argument has square/round brackets in metavar

2012-02-17 Thread Mansour
New submission from Mansour : I have a web server written in python which takes an optional argument telling it what IP and port to bind to. Here's the definition: parser.add_argument( '-b', '--bind', metavar="[ip]:port", type=unicode, help=&qu

[issue44539] Imghdr JPG Quantized

2021-06-30 Thread Mohamad Mansour
New submission from Mohamad Mansour : Previous method to check JPG images was using the following command (h[6:10] in (b'JFIF', b'Exif')) However, its not always the case as some might start with b'\xff\xd8\xff\xdb' header. Reference: https://www.digicamsoft

[issue44539] Imghdr JPG Quantized

2021-06-30 Thread Mohamad Mansour
Change by Mohamad Mansour : -- components: +Library (Lib) -C API ___ Python tracker <https://bugs.python.org/issue44539> ___ ___ Python-bugs-list mailin

[issue44539] Imghdr JPG Quantized

2021-06-30 Thread Mohamad Mansour
Change by Mohamad Mansour : -- keywords: +patch pull_requests: +25529 stage: -> patch review pull_request: https://github.com/python/cpython/pull/26964 ___ Python tracker <https://bugs.python.org/issu

[issue26607] Rename a parameter in the function PyFile_FromFile

2016-03-21 Thread Mansour Moufid
New submission from Mansour Moufid: Hi, The last parameter of the function PyFile_FromFile is named 'close', but is a pointer to a function with the prototype of the 'fclose' function in libc. The mismatch causes confusion for some static analysis tools. This patch rena