Re: async_unsafe's get_event_loop usage leads to "Too many open files" in tests

2020-10-09 Thread Adam Johnson
> > That's why we need the RuntimeError check, no? I don't see how RuntimeError can be raised. The docs I spoke about say get_ *running*_loop() cannot be used synchronously, not get_event_loop() . On Thu, 8 Oct 2020 at 22:44, Patrick Arminio wrote: > > > On Thu, 8 Oct 2020 at 22:28, Adam Johns

Fine calculation

2020-10-09 Thread ahadjon abdullaev
Hi everyone i am creating library management system but i cant do fine calculation can somebody help me -- You received this message because you are subscribed to the Google Groups "Django developers (Contributions to Django itself)" group. To unsubscribe from this group and stop receiving em

Re: Proposal: Drop dependency on pytz in favor of zoneinfo

2020-10-09 Thread Kevin Henry
I think that the simplest approach—the one that would result in the least amount of total work for both Django and its users—would be to adopt Nick's suggestion and just switch to zoneinfo in 4.0. The problem is that it's very hard to square that with Django's stability policy: "We’ll only break

Re: Fine calculation

2020-10-09 Thread Adam Johnson
Hi! I think you've found the wrong mailing list for this post. This mailing list is for discussing the development of Django itself, not for support using Django. This means the discussions of bugs and features in Django itself, rather than in your code using it. People on this list are unlikely t

Re: Proposal: Drop dependency on pytz in favor of zoneinfo

2020-10-09 Thread Carlton Gibson
The reason I suggested going with Paul's shim is that it allows folks to update without having to stop there and then to make code changes. Yes, they'll need to review the deprecation warnings, and there's the issue with datetimes over offset changes, but we can call that out in the release not

Re: Proposal: Drop dependency on pytz in favor of zoneinfo

2020-10-09 Thread Paul Ganssle
> Before looking at alternatives, I wonder if we can just change the > shims package to make it fully backwards compatible? Right now the > shims version of normalize() >

Re: Proposal: Drop dependency on pytz in favor of zoneinfo

2020-10-09 Thread Adam Johnson
> > The deprecation route using pytz_deprecation_shim in 4.0 changing to > zoneinfo in 5.0 I'm in favour of this plan, with the feature flag to use zoneinfo. As Carlton wrote, a hard change that requires modification of code will stop users from upgrading, and that's not great. Another option is

Re: Redirect from own login to admin login func of Django

2020-10-09 Thread Adam Johnson
*Hi! I think you've found the wrong mailing list for this post. This mailing list is for discussing the development of Django itself, not for support using Django. This means the discussions of bugs and features in Django itself, rather than in your code using it. People on this list are unlikely

Re: Async Django Cache - Redis Complete

2020-10-09 Thread Adam Johnson
Hi Andrew THank you for making this. This looks like a great start. I made a small PR regarding the cache.close method. Since signals are synchronous (for now?) I think you do need the wrapper. What about implementations of the sync methods? You could make them raise an exception (async only) o

Re: Proposal: Drop dependency on pytz in favor of zoneinfo

2020-10-09 Thread Kevin Henry
> It is not really possible to make the shims work the same way because there's not enough information available to determine whether an adjustment needs to be made. But since you're shimming pytz, don't you, by definition, have access to the all the same information that it has? So, for examp

Re: Proposal: Drop dependency on pytz in favor of zoneinfo

2020-10-09 Thread Paul Ganssle
On 10/9/20 2:46 PM, Kevin Henry wrote: > > It is not really possible to make the shims work the same way > because there's not enough information available to determine whether > an adjustment needs to be made. > > But since you're shimming pytz, don't you, by definition, have access > to the all

Re: Proposal: Drop dependency on pytz in favor of zoneinfo

2020-10-09 Thread Jure Erznožnik
Sorry guys for asking a really stupid question, but : I just made a search for pytz in Django master and found 17 occurrences in 5 files. More in docs and tests though. But still. Isn't what we're debating here moot since Django itself doesn't really depend on pytz all that heavily? I mean, I