Change by Tim Graham :
--
pull_requests: +9424
___
Python tracker
<https://bugs.python.org/issue33899>
___
___
Python-bugs-list mailing list
Unsubscribe:
Change by Tim Graham :
--
pull_requests: +9423
stage: needs patch -> patch review
___
Python tracker
<https://bugs.python.org/issue31047>
___
___
Python-
Change by Tim Graham :
--
pull_requests: +9415
___
Python tracker
<https://bugs.python.org/issue33899>
___
___
Python-bugs-list mailing list
Unsubscribe:
Tim Graham added the comment:
I think this caused a behavior change:
Before (Python 3.6.6):
>>> from os.path import abspath
>>> abspath('/abc/')
'C:\\abc'
After (Python 3.6.7):
>>> abspath('/abc/')
'C:\\abc\\'
This causes a
Tim Graham added the comment:
Okay, I created #32775.
--
___
Python tracker
<https://bugs.python.org/issue30349>
___
___
Python-bugs-list mailing list
Unsub
New submission from Tim Graham :
As discussed in issue30349#msg311684, fnmatch.translate() can produce a pattern
which emits a nested set warning:
>>> import fnmatch, re
>>> re.compile(fnmatch.translate('[[]foo]'))
__main__:1: FutureWarning: Possible nested set at
Tim Graham added the comment:
It might be worth adding part of the problematic regex to the warning message.
For Django's tests, I see an error like "FutureWarning: Possible nested set at
position 17 return re.compile(res).match". It took some effort to track down
the sou
Tim Graham added the comment:
The last commit that added the deprecation warning needs to be added to the 3.7
branch.
--
nosy: +Tim.Graham
___
Python tracker
<https://bugs.python.org/issue25
Tim Graham added the comment:
This is appearing as a backwards incompatible change for Django because test
case class attributes are now evaluated at load time before setUpClass runs
(which initializes some things that those class attributes use). It's possible
to adapt Django for
Tim Graham added the comment:
Perhaps the reason for the undeprecation could use some clarification. In a
Python 3 only world (where Django's master branch is), I believe there's still
usefulness for inspect.getfullargspec() -- see
https://github.com/django/django/search?q=getfulla
Tim Graham added the comment:
Thanks, I'm not sure what that means exactly but I added the note to
https://github.com/numpy/numpy/issues/9391. Perhaps a note in the Python
release notes is warranted?
--
___
Python tracker
<http://bugs.py
Tim Graham added the comment:
Hi, I observed an error while trying to install numpy after
6969eaf4682beb01bc95eeb14f5ce6c01312e297.
gcc: numpy/random/mtrand/mtrand.c
numpy/random/mtrand/mtrand.c: In function ‘__Pyx_PyCFunction_FastCall’:
numpy/random/mtrand/mtrand.c:44374:5: error: too
Tim Graham added the comment:
Does it seems likely that getfullargspec() will be deprecated after Python 2 is
EOL? Django is currently reimplementing getargspec():
https://github.com/django/django/blob/8ab7ce8558792f41637d6f87f2a8a117e169dd18/django/utils/inspect.py#L4-L24
A pull request
Tim Graham added the comment:
I sent a pull request for this issue's dependency (issue 27657) and added a
second commit there with this patch. A test added in the first commit
demonstrates that removing this code no longer results in the behavior change
described in msg2
Tim Graham added the comment:
Based on discussion in issue 16932, I agree that reverting the parsing
decisions from issue 754016 (as Martin suggested in msg271719) seems
appropriate. I created a pull request that does that.
--
nosy: +Tim.Graham
Changes by Tim Graham :
--
pull_requests: +543
___
Python tracker
<http://bugs.python.org/issue27657>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Tim Graham :
--
pull_requests: +544
___
Python tracker
<http://bugs.python.org/issue754016>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Tim Graham :
--
pull_requests: +542
___
Python tracker
<http://bugs.python.org/issue16932>
___
___
Python-bugs-list mailing list
Unsubscribe:
Tim Graham added the comment:
Thanks Nick. Your suggestion does fix the issue for Django:
https://github.com/django/django/pull/7653.
--
___
Python tracker
<http://bugs.python.org/issue23
Tim Graham added the comment:
Hi, this causes a regression in Django and I'm not sure if Django or cpython is
at fault. For a simple model that uses super() rather than super(Model self) in
save():
from django.db import models
class Model(models.Model):
def save(self, *args, **k
Tim Graham added the comment:
Yes, that fixes the second test. Current warning (with stacklevel=3):
/home/tim/code/cpython/Lib/gettext.py:454: DeprecationWarning: Plural value
must be an integer, got 1.29
tmsg = self._catalog[(msgid1, self.plural(n))]
Possibly the stacklevel should instead
Tim Graham added the comment:
Thanks, that does fix that first test. There is one more that still fails:
$ python -Wall tests/runtests.py
humanize_tests.tests.HumanizeTests.test_i18n_intword
Testing against Django installed in '/home/tim/code/django/django' with up to 3
processe
Tim Graham added the comment:
Hi, this broke a couple tests with Django because it's passing number as a
float rather than an integer. For example:
==
ERROR: test_localized_fo
Tim Graham added the comment:
The patch is working well to identify warnings when running Django's test
suite. Thanks!
--
___
Python tracker
<http://bugs.python.org/is
Tim Graham added the comment:
As far as I can tell, this isn't an issue on Python 3. Can this be closed since
Python 2 is only receiving bug fixes now?
--
nosy: +Tim.Graham
___
Python tracker
<http://bugs.python.org/is
Tim Graham added the comment:
Based on the usage output, it looks like the subcommand is required, but I'm
not sure if there are cases where a subcommand could be optional. David, can
you advise?
usage: test_argparse.py [-h] command ...
--
nosy: +r.david.m
Tim Graham added the comment:
Here's the patch if we make the change in Django instead:
https://github.com/cjerdonek/django/commit/9c8d162f3f616e9d9768659a06fcf27bb389214b
--
___
Python tracker
<http://bugs.python.org/is
Tim Graham added the comment:
Is there opposition to changing the default output as outlined in the first
comment? If so, then I think this ticket should be closed or retitled to
reflect the intent.
--
nosy: +Tim.Graham
___
Python tracker
<h
Tim Graham added the comment:
The behavior change is from #10424. Do you believe the new behavior is
incorrect?
--
nosy: +Tim.Graham
___
Python tracker
<http://bugs.python.org/issue28
New submission from Tim Graham:
As requested by Nick [0], this is a usability issue against CPython 3.6 to
provide a better chained TypeError in this case:
class _TokenType(tuple):
parent = None
def __getattr__(self, name):
new = _TokenType(self + (name,))
setattr(self
Tim Graham added the comment:
Yes, I found that Django needs an update to support that syntax in URLpatterns.
Thanks.
--
___
Python tracker
<http://bugs.python.org/issue22
Tim Graham added the comment:
Eric, your patch was good enough to allow me to easily identify and fix all the
warnings in Django: https://github.com/django/django/pull/7254. Thanks!
--
___
Python tracker
<http://bugs.python.org/issue28
Tim Graham added the comment:
Adding an updated patch.
I guess the (?i:CaseInsensitive) syntax isn't merged yet? I tried it but it
didn't work. It might be premature to proceed with this deprecation if that
alternative isn't already present. Is there an issue for it?
--
Tim Graham added the comment:
I hope the message can be improved for Python 3.6 as the warnings I see when
running Django's test suite are rather useless to help find and fix the issues:
cpython/Lib/importlib/_bootstrap.py:205: DeprecationWarning: invalid escape
sequence '\:'
Tim Graham added the comment:
Looks like we could remove the '^', but it doesn't resolve the deprecation
warnings. The inline flags in `pattern` still need to be moved before `_prefix`.
--
___
Python tracker
<http://bugs.pyt
Tim Graham added the comment:
And on further investigation, I'm not sure how to fix the deprecation warnings
in Django. We have a urlpattern like this:
url(r'^(?i)CaseInsensitive/(\w+)', empty_view, name="insensitive"),
The regex string r'^(?i)CaseInsensitive/
Tim Graham added the comment:
Could we include the offending pattern in the deprecation message? I'm
attaching a proposed patch. With that patch I can more easily find the
offending pattern, whereas before I had no idea:
django/django/urls/resolvers.py:101: DeprecationWarning: Flags n
New submission from Tim Graham:
Python 2.7:
>>> from email.header import Header
>>> Header(' ').encode()
''
Python 3.2+ (I didn't check older versions of Python 3):
>>> Header(' ').encode()
Traceback (most recent call last):
Changes by Tim Graham :
--
nosy: +Tim.Graham
___
Python tracker
<http://bugs.python.org/issue27498>
___
___
Python-bugs-list mailing list
Unsubscribe:
Tim Graham added the comment:
I'll echo what Peter said and say that this breaks 5 tests in Django's test
suite which are checking error messages. If it stays, perhaps it could be added
to the release notes instead of just NEWS.
--
nosy: +
Changes by Tim Graham :
--
nosy: +Tim.Graham
___
Python tracker
<http://bugs.python.org/issue25935>
___
___
Python-bugs-list mailing list
Unsubscribe:
Tim Graham added the comment:
Given the inactivity here, I guess the patch won't be applied before Python 3.2
is end-of-life so I'm going to close the ticket.
--
resolution: -> wont fix
status: open -> closed
___
Pytho
Tim Graham added the comment:
Yes, when I have some time.
By the way, did you intentionally remove all the "Python 3.X" versions on the
issue?
--
___
Python tracker
<http://bugs.python.o
Tim Graham added the comment:
I had already proposed a test, see cookie-bracket-quotes-test.diff. What I
meant was that the fix and the test should be combined into a single patch.
--
___
Python tracker
<http://bugs.python.org/issue25
Tim Graham added the comment:
Could you please integrate my unit test into your patch?
You also need to sign the PSF Contributor Agreement:
https://www.python.org/psf/contrib/contrib-form/
--
___
Python tracker
<http://bugs.python.org/issue25
Tim Graham added the comment:
Sure, feel free to propose a patch.
--
___
Python tracker
<http://bugs.python.org/issue25228>
___
___
Python-bugs-list mailin
Tim Graham added the comment:
It might be a case of issue22983. I'll try to look into the details and offer a
patch next week.
For what it's worth, there are other regressions in Python 3.2 cookie parsing
that makes the latest patch release (3.2.6) unusable with Django (issue22758)
New submission from Tim Graham:
Regression in https://hg.python.org/cpython/rev/9e765e65e5cb (affects 2.7 and
3.2+), similar to issue22931 where inserting an invalid cookie value can cause
the rest of the cookie to be ignored. A test is attached, and here's a quick
demo:
Old:
>
Tim Graham added the comment:
It's fine with me.
--
___
Python tracker
<http://bugs.python.org/issue25137>
___
___
Python-bugs-list mailing list
Unsubscr
Tim Graham added the comment:
We can use an alternate approach in Django, if appropriate:
https://github.com/django/django/pull/5294
--
___
Python tracker
<http://bugs.python.org/issue25
Changes by Tim Graham :
--
nosy: +Tim.Graham
___
Python tracker
<http://bugs.python.org/issue25137>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Tim Graham :
--
nosy: -Tim.Graham
___
Python tracker
<http://bugs.python.org/issue14373>
___
___
Python-bugs-list mailing list
Unsubscribe:
Tim Graham added the comment:
Thanks, that does resolve the issue.
--
___
Python tracker
<http://bugs.python.org/issue14373>
___
___
Python-bugs-list mailin
Tim Graham added the comment:
This changed caused a problem in Django's test suite (bisected to
0d0989359bbb0).
File "/home/tim/code/django/django/db/models/options.py", line 709, in
_populate_directed_relation_graph
all_models = self.apps.get_models(include_auto_created=
Tim Graham added the comment:
Unfortunately, the revert wasn't merged to the 2.7 branch until after the
release of 2.7.10. I guess this regression wouldn't be considered serious
enough to warrant a 2.7.11 soon, correct?
--
___
Python trac
Tim Graham added the comment:
Patch rebased again after cookie fix from #22931.
--
___
Python tracker
<http://bugs.python.org/issue22758>
___
___
Python-bug
Changes by Tim Graham :
Added file: http://bugs.python.org/file39512/secure-httponly-3.2-backport.diff
___
Python tracker
<http://bugs.python.org/issue22758>
___
___
Pytho
Tim Graham added the comment:
I didn't find any problems while testing your proposed new patch for cpython
and your proposed patch for Django together.
--
___
Python tracker
<http://bugs.python.org/is
Tim Graham added the comment:
I noticed this is backwards incompatible for a small feature in Django. If you
want to leave this feature in Python 2.7 and 3.4, it'll break things unless we
push out a patch for Django; see https://github.com/django/django/pull/4637.
--
nosy: +Tim.G
Tim Graham added the comment:
Will this regression be fixed in Python 2.7, 3.2, and 3.3? If not, Django may
need to vendor Python's cookie class to workaround this bug to prevent users
from losing sessions and/or being unable to login to Django powered sites as
reported in
Tim Graham added the comment:
That last commit fixed compatibility with Django.
--
___
Python tracker
<http://bugs.python.org/issue23571>
___
___
Python-bug
Tim Graham added the comment:
Here's an exception in Django after the latest patch. The Django code block in
the last exception catches ValueError, but this doesn't seem to work any longer
since it's "wrapped" in SystemError. As Berker mentioned, some upgrade tips
Tim Graham added the comment:
Patch updated to fix conflict in NEWS. Could we have it committed to ensure it
gets fixed in the next 3.2 released?
--
Added file: http://bugs.python.org/file38609/secure-httponly-3.2-backport.diff
___
Python tracker
Changes by Tim Graham :
--
nosy: +Tim.Graham
___
Python tracker
<http://bugs.python.org/issue22931>
___
___
Python-bugs-list mailing list
Unsubscribe:
Tim Graham added the comment:
Django's test suite doesn't reveal any regressions. All the changes there are
expected as far as I can see.
--
___
Python tracker
<http://bugs.python.o
Tim Graham added the comment:
Security-wise? I don't know, I haven't really been in the loop on the original
issue.
--
___
Python tracker
<http://bugs.python.o
Changes by Tim Graham :
--
nosy: +Tim.Graham
___
Python tracker
<http://bugs.python.org/issue7559>
___
___
Python-bugs-list mailing list
Unsubscribe:
Tim Graham added the comment:
Django's test suite passes with the proposed patch after some updates:
https://github.com/django/django/pull/3455
--
___
Python tracker
<http://bugs.python.org/is
Tim Graham added the comment:
I also created #22796 for the lax parsing issue.
--
___
Python tracker
<http://bugs.python.org/issue22758>
___
___
Python-bugs-list m
New submission from Tim Graham:
As noted in the comments of #22758 by Georg Brandle:
* Django uses __init__(str()) roundtripping, which is not explicitly supported
by the library, and worked by accident with previous versions. That it works
again with 3.3+ is another accident, and a bug
Tim Graham added the comment:
The patch from #16611 applies cleanly to 3.2. I added a mention in Misc/NEWS
and confirmed that all tests pass.
--
Added file: http://bugs.python.org/file37127/secure-httponly-3.2-backport.diff
___
Python tracker
<h
Tim Graham added the comment:
Georg, how do want to proceed with this issue? Should we backport #16611
(support for parsing secure/httponly flag) to 3.2 to fix this regression and
then create a separate issue to fix the lax parsing issue on all versions
Tim Graham added the comment:
Cookie pickling issue should be fixed in #22775.
--
nosy: +Tim.Graham
___
Python tracker
<http://bugs.python.org/issue826
Tim Graham added the comment:
Updated patch per comments.
--
Added file:
http://bugs.python.org/file37114/cookie-pickling-all-protocols-2.diff
___
Python tracker
<http://bugs.python.org/issue22
Tim Graham added the comment:
Updated patch to test pickling of all protocols.
--
Added file: http://bugs.python.org/file37100/cookie-pickling-all-protocols.diff
___
Python tracker
<http://bugs.python.org/issue22
Tim Graham added the comment:
FYI, I created #22775 and submitted a patch for the issue that SimpleCookie
doesn't pickle properly with HIGHEST_PROTOCOL.
--
___
Python tracker
<http://bugs.python.org/is
Tim Graham added the comment:
By the way, this is my first patch for Python and I submitted a CLA 2 days ago.
--
___
Python tracker
<http://bugs.python.org/issue22
New submission from Tim Graham:
Expected:
>>> import pickle
>>> from http.cookies import SimpleCookie
>>> pickle.loads(pickle.dumps(SimpleCookie('hi=there'),2))
# Actual
Patch is based on the suggestion from Georg Brandl in #22758 (I added the
&quo
Tim Graham added the comment:
Thank-you Georg; I believe I was able to fix some of the failures by patching
Django as you suggested.
However, I think I found another issue due to #16611 (support for
httponly/secure cookies) not being backported to Python 3.2. The issue is that
any cookies
Tim Graham added the comment:
I wasn't sure if it was expected behavior or not. I'm attaching a file with the
list of failing tests on Django's master.
Perhaps more useful is a reference to the problematic usage in Django:
https://github.com/dja
New submission from Tim Graham:
I noticed some failing Django tests on Python 3.2.6 the other day. The
regression is caused by this change:
https://github.com/python/cpython/commit/572d9c59a1441c6f8ffb9308824c804856020e31
Behavior before that commit (and on other version of Python even after
81 matches
Mail list logo