Re: Permissions don't get translated in admin interface

2023-06-02 Thread Thibaud Colas
 without further input, I’m not quite sure what to do with this. We need this ticket re-opened so anyone actually considers working on a fix for this. For reference, the initial reason for closing this bug report was: > The permissions are stored in the database and don't get transla

Re: Drop CSRF middleware from the settings template

2023-06-02 Thread Deepak Sain
hello everyone i am deepak kumar sain new to tensorflow also new to opensource contributiuons , i am an student , i want to start my open source contribution journey can anyone helpme how can i contribute and what can i contribute am learning DSA in c++ and Flutter currently . thank you On

Re: Proposal on how add configuration options to Email Backends

2023-06-01 Thread Mariusz Felisiak
It seems we have a consensus here to support multiple email backends. Jacob, feel-free to create a new ticket. Best, Mariusz -- You received this message because you are subscribed to the Google Groups "Django developers (Contributions to Django itself)" group. To unsubscribe from this group

Re: Fellow Reports - May 2023

2023-05-23 Thread Mariusz Felisiak
Week ending May 21, 2023 *Triaged:* https://code.djangoproject.com/ticket/34565 - Add acheck_password() async method. (accepted) https://code.djangoproject.com/ticket/34563 - ManifestStaticFilesStorage support for CSS module scripts in Javascript files. (someday/maybe)

Re: Ticket #30382 force_insert flag is not passed when saving parents on inherited models

2023-05-18 Thread charettes
I left some notes on the PR but I think the crux of the issue here is that you are trying to change the meaning of Model.save(force_insert=True) from force the insert of the current model to force the insert of the model and all its bases. This is a problem not only for QuerySet.create but

Re: Ticket #34555 ModelBase prevents addition of model Fields via __init_subclass__

2023-05-16 Thread hottwaj
> > Changing these expectations could be done by moving most of the > ModelBase.__new__ logic to Model.__init_subclass__ but this would require a > massive re-enginering of meta programming logic that is remain unchanged > for years. > > Le vendredi 12 mai 2023 à 09:38:04 UTC-4, Ada

Re: Ticket #34555 ModelBase prevents addition of model Fields via __init_subclass__

2023-05-16 Thread charettes
-trivial use cases a class_prepared signal seems like it's still the best way to run code once the class is fully initialized. Changing these expectations could be done by moving most of the ModelBase.__new__ logic to Model.__init_subclass__ but this would require a massive re-enginering of meta

Re: Fellow Reports - May 2023

2023-05-16 Thread Mariusz Felisiak
Week ending May 14, 2023 *Triaged:* https://code.djangoproject.com/ticket/34546 - Failed migration yields to unmigratable app:""OperationalError: (1050, "Table '' already exists") (invalid) https://code.djangoproject.com/ticket/34547 - Deprecate DatabaseOperations.field_cast_sql().

Re: Fellow Reports - May 2023

2023-05-15 Thread natali...@gmail.com
Hello everyone! I've posted my fellow report in the forum: https://forum.djangoproject.com/t/django-fellow-report-natalia/20942 Following reports will be threaded in that topic \o/ Thank you! Natalia. On Monday, May 8, 2023 at 9:33:15 AM UTC-3 natali...@gmail.com wrote: > Week ending

Re: Added support for Database Level Cascades

2023-05-14 Thread jatin singh
signals ?.. On Sun, May 14, 2023 at 12:01 PM Harro wrote: > I have just one question, will this still trigger on delete signals for > cascaded models? > That's the main reason the cascade happens in Django and not in the > database. > > On Saturday, 13 May 2023 at 16:35:01 UTC+2 Akash Sen

Re: Added support for Database Level Cascades

2023-05-14 Thread Akash Sen
No it will not trigger the delete signals. The point is to delete an object with O(1) database queries instead of O(n), Have to add another warning message if the signals are being used with DB level cascading. On Sunday, May 14, 2023 at 11:45:56 AM UTC+5:30 Harro wrote: > I have just one

Re: Added support for Database Level Cascades

2023-05-14 Thread Harro
I have just one question, will this still trigger on delete signals for cascaded models? That's the main reason the cascade happens in Django and not in the database. On Saturday, 13 May 2023 at 16:35:01 UTC+2 Akash Sen wrote: > *Added support for Database Level Cascades* > > *PR link *:

Re: Deprecate CICharField, CIEmailField, CITextField

2023-05-12 Thread 'Johannes Maron' via Django developers (Contributions to Django itself)
Hi, Yes, I hope Django will continue to expand expression support. I worked so hard on the SQL compiler to facilitate those kinds of features. Anyhow, since db collations are not an adequate replacement for CI text, we will create an open-source backport of the CITEXT fields. Once we are done, I

Re: Conclusion of ticket #26761

2023-05-12 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
I have replied on the ticket with an example using arbitrary HTML as required. On Wed, May 10, 2023 at 10:30 AM Carsten Fuchs wrote: > Hello, > > ticket #26761 was closed as wontfix, however I don't understand the reason. > https://code.djangoproject.com/ticket/26761#comment:19 > > The ticket's

Re: Ticket #34555 ModelBase prevents addition of model Fields via __init_subclass__

2023-05-12 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
ed. I was asked to bring the issue here for wider review before the > ticket is re-opened (if that is what people agree to do) > > For reference, links to the ticket and PR are: > https://code.djangoproject.com/ticket/34555 > https://github.com/django/django/pull/16849 > > The i

Re: Deprecate CICharField, CIEmailField, CITextField

2023-05-12 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
> What I am struggling now with is whenever I specify > `db_collation="case_insensitive"` on the field and this field is used in > `ModelAdmin.search_fields` - Django simply breaks (as it by default uses > `icontains` lookup). > That is quite unfortunate for the big projects, as I have to come up

Re: Can we move the activity on this list to the Forum now?

2023-05-08 Thread natali...@gmail.com
15:19, Arthur Rio wrote: >> >> Yes please! >> >> >> >> On May 3, 2023 at 11:19:12 PM, jure.er...@gmail.com (jure.er...@gmail.com) >> wrote: >> >> >> +1 >> >> >> >> *From:* django-d...@googlegroups.com *On >&

Re: Deprecate CICharField, CIEmailField, CITextField

2023-05-06 Thread 'Johannes Maron' via Django developers (Contributions to Django itself)
Hello again, I trust Mariusz' assessment regarding the maintainability. In that case, I presume a separate package from a 3rd party with commercial interest might be the best option going forward. Thanks for all the considerations and explanations. Cheers! Joe On Wed, Apr 19, 2023 at 3:48 PM

Re: Can we move the activity on this list to the Forum now?

2023-05-06 Thread Carlton Gibson
ps.com> *On Behalf Of *natali...@gmail.com > *Sent:* sreda, 03. maj 2023 20:10 > *To:* Django developers (Contributions to Django itself) < > django-developers@googlegroups.com> > *Subject:* Re: Can we move the activity on this list to the Forum now? > > > >

Re: Drop CSRF middleware from the settings template

2023-05-05 Thread 'Ryan Hiebert' via Django developers (Contributions to Django itself)
I've been working on setting up a new project that's never going to see the light of production, so I went down the road of just disabling CSRF for that purpose. I notably found that the Django admin still requires CSRF, even when the middleware has been removed from the MIDDLEWARE setting. I

Re: Can we move the activity on this list to the Forum now?

2023-05-04 Thread Ken Whitesell
ions to Django itself) *Subject:* Re: Can we move the activity on this list to the Forum now? Hello everyone! I was wondering if we could make a decision about this topic. On the one hand, and as far as I understand, the forum is the preferred channel of communication

Re: Can we move the activity on this list to the Forum now?

2023-05-04 Thread Tim Graham
t of the community. > > -- > Curtis > > On Thu, 4 May 2023, at 15:19, Arthur Rio wrote: > > Yes please! > > > > On May 3, 2023 at 11:19:12 PM, jure.er...@gmail.com (jure.er...@gmail.com) > wrote: > > > +1 > > > > *From:* django-d...@google

Re: Can we move the activity on this list to the Forum now?

2023-05-04 Thread Carsten Fuchs
;>>>   >>>> >>>> *From:*django-developers@googlegroups.com >>>> *On Behalf Of *natali...@gmail.com >>>> *Sent:* sreda, 03. maj 2023 20:10 >>>> *To:* Django developers (Contributions to Django itself) >>>> >>>> *Subject

Re: Can we move the activity on this list to the Forum now?

2023-05-03 Thread Jure Erznožnik
ers@googlegroups.com *On Behalf Of *natali...@gmail.com *Sent:* sreda, 03. maj 2023 20:10 *To:* Django developers (Contributions to Django itself) *Subject:* Re: Can we move the activity on this list to the Forum now? Hello everyone! I was wondering if we could make a decision about thi

Re: Can we move the activity on this list to the Forum now?

2023-05-03 Thread Curtis Maloney
> (jure.erznoz...@gmail.com) wrote: > >> >> +1 >> >> *From:* django-developers@googlegroups.com >> *On Behalf Of *natali...@gmail.com >> *Sent:* sreda, 03. maj 2023 20:10 >> *To:* Django developers (Contributions to Django itself) >> >

RE: Can we move the activity on this list to the Forum now?

2023-05-03 Thread Arthur Rio
lopers (Contributions to Django itself) < django-developers@googlegroups.com> *Subject:* Re: Can we move the activity on this list to the Forum now? Hello everyone! I was wondering if we could make a decision about this topic. On the one hand, and as far as I understand, the forum is the prefe

RE: Can we move the activity on this list to the Forum now?

2023-05-03 Thread jure.erznoznik
+1 From: django-developers@googlegroups.com On Behalf Of natali...@gmail.com Sent: sreda, 03. maj 2023 20:10 To: Django developers (Contributions to Django itself) Subject: Re: Can we move the activity on this list to the Forum now? Hello everyone! I was wondering if we could make

Re: Can we move the activity on this list to the Forum now?

2023-05-03 Thread natali...@gmail.com
Hello everyone! I was wondering if we could make a decision about this topic. On the one hand, and as far as I understand, the forum is the preferred channel of communication. On the other hand, having multiple channels of communication can spread important discussions too thin, making it

Re: Fellow Reports - April 2023

2023-05-02 Thread Natalia Bidart
Week ending 2023-04-30 (Week 18) Triaged: https://code.djangoproject.com/ticket/34523 - update_or_create not work in parallel insertion https://code.djangoproject.com/ticket/34520 - ModelAdmin.fields: wrapping in tuples does not have any effect (each field on separate line) (invalid)

Re: Issue in admin and sites

2023-05-02 Thread Mohamed El-Kalioby
Here it is https://code.djangoproject.com/ticket/34526 On Tue, 2 May 2023, 18:32 אורי, wrote: > Can you link to the ticket? > אורי > u...@speedy.net > > > On Tue, May 2, 2023 at 5:28 PM Mohamed El-Kalioby > wrote: > >> Hello everyone, >> >> >> I’ve opened this issue on the issue tracker, and

Re: Issue in admin and sites

2023-05-02 Thread אורי
Can you link to the ticket? אורי u...@speedy.net On Tue, May 2, 2023 at 5:28 PM Mohamed El-Kalioby wrote: > Hello everyone, > > > I’ve opened this issue on the issue tracker, and was asked to post here > for the sake of discussion. > > In SaaS product, we have set of organizations (customers),

Re: Fellow Reports - April 2023

2023-05-01 Thread Mariusz Felisiak
Week ending April 30, 2023 *Triaged:* https://code.djangoproject.com/ticket/34229 - "no such column" when combining FilteredRelation and multi-table inheritance models (accepted) https://code.djangoproject.com/ticket/34515 - Translatable URL patterns raise 404 for non-English default

Re: A different approach for the auto-reloader

2023-04-28 Thread Salomon Roberto Herrera Navarro
files requests very >>>> quickly, which would lead to stating all files 20x redundantly. >>> >>> >>> Indeed, maybe this could be solved with a re-stat cooldown? >>> >>> >>>> 2. How would we handle (potentially

Re: A different approach for the auto-reloader

2023-04-28 Thread David Arredondo
ly hard to know where a request is going at this level, so we >>> could end up with a page view triggering 20 static files requests very >>> quickly, which would lead to stating all files 20x redundantly. >> >> >> Indeed, maybe this could be solved with a re

Re: A different approach for the auto-reloader

2023-04-28 Thread natali...@gmail.com
lead to stating all files 20x redundantly. > > > Indeed, maybe this could be solved with a re-stat cooldown? > > >> 2. How would we handle (potentially ridiculous) things like code imported >> from a thread during app ready? In general wouldn’t we need some kind of

Re: Django behavior on translatable URL patterns (i18n_patterns) when prefix_default_language=False is used.

2023-04-27 Thread Mariusz Felisiak
Anthony, please don't start the same discussion on multiple channels. If anyone wants to add a comment, please do so in the forum . -- You received

Re: Fellow Reports - April 2023

2023-04-24 Thread Natalia Bidart
Week ending 2023-04-23 (Week 17) Triaged: https://code.djangoproject.com/ticket/34506 - Visual regressions in admin's clearable file input. (accepted) https://code.djangoproject.com/ticket/34507 - AttributeError: Can't pickle local object 'convert_exception_to_response..inner' (needsinfo)

Re: Fellow Reports - April 2023

2023-04-23 Thread Mariusz Felisiak
Week ending April 23, 2023 *Triaged:* https://code.djangoproject.com/ticket/34488 - ClearableFileInput widget forgets "Clear" selection when form is not valid. (accepted) https://code.djangoproject.com/ticket/34500 - use annotate return feild, Error capture does not work (duplicate)

Re: Django 5.x Technical Board Candidate Registration

2023-04-22 Thread Katie McLaughlin
With apologies from the Secretary, the above information is incorrect regarding the candidacy requirements for this election. The new post with the updated details has been posted here: https://groups.google.com/g/django-developers/c/ZjkbmE5bIoE Regards, Katie McLaughlin Secretary Django

Re: Oracle 23c released earlier this month

2023-04-21 Thread David Sanders
Looks like python-oracledb is making updates to be compatible with 23c: https://python-oracledb.readthedocs.io/en/latest/release_notes.html#oracledb-1-3-1-tbd 1.3.1 isn't released yet but the fact that updates are being made so soon is encouraging  On Monday, 17 April 2023 at 22:06:57 UTC+10

Re: Drop CSRF middleware from the settings template

2023-04-20 Thread Florian Apolloner
On Thursday, April 20, 2023 at 1:00:05 PM UTC+2 Jure Erznožnik wrote: OK, I'll bite: For the first issue, my problem revolved around this code: @property def POST(self): # Ensure that request.POST uses our request parsing. if not _hasattr(self, '_data'): self._load_data_and_files() if

Re: Drop CSRF middleware from the settings template

2023-04-20 Thread Jure Erznožnik
OK, I'll bite: For the first issue, my problem revolved around this code: @property def POST(self): # Ensure that request.POST uses our request parsing. if not _hasattr(self, '_data'): self._load_data_and_files() if is_form_media_type(self.content_type): return self._data return

Re: Django's automatic admin interface.

2023-04-20 Thread Dipankar
; “SPA-feel” by using HTML over the wire or htmx, which requires minimal > JavaScript. > > > > *From:* django-developers@googlegroups.com < > django-developers@googlegroups.com> *On Behalf Of *Tom Carrick > *Sent:* Wednesday, April 19, 2023 5:07 AM > *To:* django-develop

Re: Drop CSRF middleware from the settings template

2023-04-20 Thread Florian Apolloner
Hi, On Tuesday, April 18, 2023 at 10:57:55 PM UTC+2 jure.er...@gmail.com wrote: Well, TBH, I've just completed dealing with CSRF form in my projects. I ended up exempting the particular view from CSRF because I didn't know how to get the stuff to work. The problem was that django parsed the

Re: Production Django use and "real ip"

2023-04-20 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
> Are there any deployment scenarios where META.REMOTE_ADDR is ever even correct? Yes, when running a WSGI server that faces the internet, with no intermediate proxies. On Wed, Apr 19, 2023 at 3:51 PM Arthur Pemberton wrote: > At this point, I'm not even suggesting that Django handle this

Re: Production Django use and "real ip"

2023-04-19 Thread Arthur Pemberton
At this point, I'm not even suggesting that Django handle this internally. I'm suggesting that the behaviour/expectation be documented, at least in the deployment guide. Are there any deployment scenarios where META.REMOTE_ADDR is ever even correct? Arthur Pemberton On Wed, Apr 19, 2023 at 3:37 

RE: Django's automatic admin interface.

2023-04-19 Thread Matthew Pava
@googlegroups.com Subject: Re: Django's automatic admin interface. IMO, if we were going to modernise the admin (which is laudable), it wouldn't be by using JS frameworks or Tailwind, but by simplifying things further, by removing the last bits of JQuery, simplifying the HTML and making it more semantic

Re: Deprecate CICharField, CIEmailField, CITextField

2023-04-19 Thread fly.a...@gmail.com
Hey everyone! Thanks for the discussion. And special thanks @Adam, for the great article, helped us with the migration. What I am struggling now with is whenever I specify `db_collation="case_insensitive"` on the field and this field is used in `ModelAdmin.search_fields` - Django simply

Re: Django's automatic admin interface.

2023-04-19 Thread Tom Carrick
IMO, if we were going to modernise the admin (which is laudable), it wouldn't be by using JS frameworks or Tailwind, but by simplifying things further, by removing the last bits of JQuery, simplifying the HTML and making it more semantic, and rewriting the CSS to use a grid based layout and cut

Re: Django's automatic admin interface.

2023-04-19 Thread Dipankar
Sorry if my question is wrong.. .. Not exactly technology I wanted to know about the frontend framework like tailwindCSS,react or Vue. In nutshell I want admin interface with tailwindCSS/React/Vue. any suggestion ? On Wed, Apr 19, 2023 at 3:01 PM David Sanders wrote: > Hi Dipankar, > > Not

Re: Django's automatic admin interface.

2023-04-19 Thread David Sanders
Hi Dipankar, Not being rude but serious question: What's the latest front end technology? :) On Wed, 19 Apr 2023, 7:27 pm Dipankar, wrote: > Is there any plan to replace Django's automatic admin interface with the > latest front end technology? > There are several packages available but what

Re: Production Django use and "real ip"

2023-04-19 Thread 'st...@jigsawtech.co.uk' via Django developers (Contributions to Django itself)
As someone whose worked on various projects in different languages over the last 15 years that heavily involved deciphering IP sent in headers to try to determine the "real" IP address of a connection, I would urge caution with anything around determining a "real IP". There is no standard in

RE: Drop CSRF middleware from the settings template

2023-04-18 Thread jure.erznoznik
developers (Contributions to Django itself) Subject: Re: Drop CSRF middleware from the settings template In my experience, even SameSite None is not sufficient to use cookies in cross-site iframes. Safari doesn't allow those cookies to be sent unless you visit the site directly first. I've

Re: Drop CSRF middleware from the settings template

2023-04-18 Thread Stratos Moros
In my experience, even SameSite None is not sufficient to use cookies in cross-site iframes. Safari doesn't allow those cookies to be sent unless you visit the site directly first. I've heard movements for Firefox and/or Chrome having similar behavior, but I haven't been working with iframes

Re: Drop CSRF middleware from the settings template

2023-04-18 Thread 'Ryan Hiebert' via Django developers (Contributions to Django itself)
On Tuesday, April 18, 2023 at 8:34:14 AM UTC-5 Stratos Moros wrote: [...] In my experience there are legitimate cases for setting SameSite=None, especially concerning iframes. Specifically, when developing a web app intended to be embedded as an iframe by a different top-level origin, you

Re: Drop CSRF middleware from the settings template

2023-04-18 Thread Jacob Rief
In such cases, you really do need Django's current CSRF protection. Personally I wouldn't mind it being off by default, since SameSite=Lax seems to be enough for most cases, but this could be a footgun for some people. This could be handled by the configuration checker, which runs after

Re: Drop CSRF middleware from the settings template

2023-04-18 Thread Stratos Moros
Hello Everyone, Looks like lax will do the trick, but it's not like there aren't legit cases for same-site policy to be set to something less restrictive. I agree. In my experience there are legitimate cases for setting SameSite=None, especially concerning iframes. Specifically, when

Re: Deprecate CICharField, CIEmailField, CITextField

2023-04-18 Thread 'Johannes Maron' via Django developers (Contributions to Django itself)
Thanks Adam, of course I read your well-written article before diving into this topic, thanks for sharing. However, I don't agree about the index. The best solution is using the CITEXT db type, which is very much alive. Should Django to deprecate support for the db type, a 3rd party package

Re: Oracle 23c released earlier this month

2023-04-17 Thread charettes
Thanks for sharing the news David! Support for true BOOLEAN type and GROUP BY position are effectively very welcome changes as they account for a few hacks. I do wonder if that's paving the way for grouping by subquery in future versions. Best, Simon Le lundi 17 avril 2023 à 08:06:57 UTC-4,

Re: Fellow Reports - April 2023

2023-04-17 Thread Natalia Bidart
Week ending 2023-04-16 (Week 16) Triaged: https://code.djangoproject.com/ticket/34490 - Tests with mirror database not working as expected (invalid) https://code.djangoproject.com/ticket/34489 - feature: Support for PostgreSQL table partitioning (needsinfo) Reviewed:

Re: Oracle 23c released earlier this month

2023-04-17 Thread Mariusz Felisiak
Hi, Thanks! Also, they finally update VM: https://www.oracle.com/database/technologies/databaseappdev-vm.html We still have to wait for a compatible driver, cx_Oracle and python-oracledb don't support it yet. Best, Mariusz -- You received this message because you are subscribed to the

Re: Select API choice when starting new project.

2023-04-17 Thread Daniel Azubuine
thank you i didn't know. On Mon, Apr 17, 2023 at 8:26 AM Florian Apolloner wrote: > Hi, this is something which is already supported via the template argument > to startproject/startapp. > > Cheers, > florian > > On Sunday, April 16, 2023 at 11:47:44 PM UTC+2 Daniel Azubuine wrote: > >> When

Re: Fellow Reports - April 2023

2023-04-17 Thread Mariusz Felisiak
Week ending April 16, 2023 *Triaged:* https://code.djangoproject.com/ticket/34480 - Annotating with Chr raises ValueError (accepted) https://code.djangoproject.com/ticket/34481 - Admin check for reversed foreign key used in "list_display" (accepted)

Re: Drop CSRF middleware from the settings template

2023-04-17 Thread Jure Erznožnik
https://security.stackexchange.com/questions/262245/are-csrf-attacks-a-thing-of-the-past Looks like lax will do the trick, but it's not like there aren't legit cases for same-site policy to be set to something less restrictive. LP, Jure On 17. 04. 23 09:24, Jacob Rief wrote: On Monday,

Re: Select API choice when starting new project.

2023-04-17 Thread Florian Apolloner
Hi, this is something which is already supported via the template argument to startproject/startapp. Cheers, florian On Sunday, April 16, 2023 at 11:47:44 PM UTC+2 Daniel Azubuine wrote: > When starting a new Django project, the user can select if he wants to > build an API or use the Django

Re: Proposal: Constructing urls outside the request cycle

2023-04-17 Thread Florian Apolloner
On Sunday, April 16, 2023 at 10:21:20 AM UTC+2 Adam Johnson wrote: One question though, how will we support projects that are served at multiple domains? Would Django only support the "main" site through BASE_URL and require you to perform URL construction for other domains as required? As

Re: Drop CSRF middleware from the settings template

2023-04-17 Thread Jacob Rief
On Monday, April 17, 2023 at 8:45:16 AM UTC+2 Curtis Maloney wrote: Are you implying that all CSRF attacks protected by Django's current machinery are entirely mitigated by SameSite=Lax on the _session_ cookiue? Yes. Therefore imho, the CSRF protection is just some nasty legacy, developers

Re: Drop CSRF middleware from the settings template

2023-04-17 Thread Curtis Maloney
On Mon, 17 Apr 2023, at 04:25, 'Ryan Hiebert' via Django developers (Contributions to Django itself) wrote: > I've recently been working with other new frameworks, particularly Remix. > Coming from Django, which has had excellent CSRF for many years, one of my > first questions was how to

Re: Drop CSRF middleware from the settings template

2023-04-17 Thread Jacob Rief
Actually, I attempted to forge POST requests on Django with disabled CSRF protection – and failed. Maybe I wasn't creative enough, but modern browsers do indeed have a good protection against this attack vector. I therefore welcome this proposal, unless someone can show how to bypass this

Re: Proposal: Check constraints at the model field level

2023-04-16 Thread David Sanders
Hi Adam, Mariusz & Simon, > The only thing I'm not a fan of in your proposal is repeating the field name within the check expression, like "price" in > ... 8< ... > Perhaps we could support only a special name instead, like “self” or the shorter “f”? I was thinking the same thing +1 I wanted to

Re: Proposal: Constructing urls outside the request cycle

2023-04-16 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
A setting isn't so mad. Many Django projects I've seen use a similar custom setting for constructing URLs outside of requests. One question though, how will we support projects that are served at multiple domains? Would Django only support the "main" site through BASE_URL and require you to

Re: Deprecate CICharField, CIEmailField, CITextField

2023-04-14 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
Just to note, for anyone that finds it useful, that I wrote a blog post on migrating to collations: https://adamj.eu/tech/2023/02/23/migrate-django-postgresql-ci-fields-case-insensitive-collation/ But yes, I have also been thinking like Tom that indexing UPPER("email") seems to be the path of

Re: Production Django use and "real ip"

2023-04-14 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
It's surprisingly complex to interpret x-forwarded-for: https://www.brainonfire.net/blog/2022/03/04/understanding-using-xff/ . We will never be able to safely add automated handling. I *guess* we could add a note to the deployment guide like "check your HTTP_X_FORWARDED_FOR setting". I'm

Re: Deprecate CICharField, CIEmailField, CITextField

2023-04-13 Thread Tom Carrick
Hi, I wrote most of the code for collation support, and I also argued (softly) against deprecating citext support for the reasons you stated. However, I've changed my mind on this now. As you can't index the citext column for LIKE queries, doing these types of searches on any real amount of data

Re: Deprecate CICharField, CIEmailField, CITextField

2023-04-12 Thread Mariusz Felisiak
Hi > Unless we want to drop support for the CITEXT extension, ... What do you mean by that? As far as I'm now, we don't do anything special to support CITEXT extension 樂. > I'd caution to revert the deprecation and keep support ... I'm obviously biased as the author of this proposition and

Re: Deprecate CICharField, CIEmailField, CITextField

2023-04-12 Thread 'Johannes Maron' via Django developers (Contributions to Django itself)
Hi there, I am sorry that I missed this in the alpha. But to the best of my knowledge, CITEXT and non-deterministic collations are not the same. They don't support the same operations and their string comparison operations are similar, yet not identical. Furthermore, PostgreSQL doesn't

Re: Fellow Reports - April 2023

2023-04-11 Thread Paolo Melchiorre
Welcome Natalia 珞 On Tue, Apr 11, 2023, 17:04 Natalia Bidart wrote: > Week ending April 9, 2023 > > Hello! I'm Natalia (AKA nessita), the new Django Fellow. I officially > started on April 1st (really :-)) though I had a slow start since I had a > long-time planned vacation. > > So far I have

Re: Django "makemigrations -- update" donot working

2023-04-11 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
Indeed, David is right. The --update flag is intended for developing a feature branch and adding extra changes to a work-in-progress migration. This is why it requires the migration to not be applied. On Sun, Apr 9, 2023 at 9:20 PM David Wobrock wrote: > Hi, > > As you can see, the error

Re: Fellow Reports - April 2023

2023-04-11 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
Welcome Natalia  On Tue, Apr 11, 2023 at 2:52 PM Natalia Bidart wrote: > Week ending April 9, 2023 > > Hello! I'm Natalia (AKA nessita), the new Django Fellow. I officially > started on April 1st (really :-)) though I had a slow start since I had a > long-time planned vacation. > > So far I

Re: Doc make error: make: *** [Makefile:59: html] Error 127

2023-04-10 Thread Ezekiel Adetoro
I have installed the requirement.txt but didn't work. I was able to get by with apt-get install python3-sphinx On Mon, Apr 10, 2023 at 11:27 AM Tim Graham wrote: > It looks like Sphinx isn't installed. Did you `pip install > docs/requirements.txt`? > On Monday, April 10, 2023 at 9:12:48 AM

Re: Doc make error: make: *** [Makefile:59: html] Error 127

2023-04-10 Thread Tim Graham
It looks like Sphinx isn't installed. Did you `pip install docs/requirements.txt`? On Monday, April 10, 2023 at 9:12:48 AM UTC-4 Ezekiel Adetoro wrote: > I want to generate the documentation for Django, I have the folloe error > > sphinx-build -b djangohtml -n -d _build/doctrees -D language=en

Re: Django "makemigrations -- update" donot working

2023-04-09 Thread David Wobrock
Hi, As you can see, the error message seems quite clear: > Cannot update applied migration 'authentication.0001_initial'. One cannot edit a migration that has already been applied. To update it, you can undo it by running "migrate authentication zero" and then run "makemigrations --update" again.

Re: Opensource Django Project

2023-04-08 Thread Tim Graham
Yes. See https://docs.djangoproject.com/en/dev/internals/contributing/new-contributors/ On Saturday, April 8, 2023 at 10:50:17 AM UTC-4 Naresh Pahariya wrote: > Me too... > > I think there is a documentation for django contribution. > > Thanks, > Naresh > > On Sat, 8 Apr, 2023, 3:51 pm

Re: The problem of versioning a large project.

2023-04-08 Thread Christian González
asad: Why not use a mono repo? *From:* django-developers@googlegroups.com on behalf of Alex Sonar *Sent:* Sunday, April 2, 2023 10:21:33 PM *To:* Django developers (Contributions to Django itself) *Subject:* Re: The problem

Re: Django "makemigrations -- update" donot working

2023-04-08 Thread Muhammad Juwaini Abdul Rahman
Do you need that '--update' parameter? On Fri, 7 Apr 2023 at 05:57, Saifullah Shahen wrote: > in my custom user model, initially, my model looks like this > > class User(AbstractUser, BaseModelWithUUID): > phone = models.CharField(max_length=11, > validators=[validate_phone_number]) > I do

Re: Opensource Django Project

2023-04-08 Thread Naresh Pahariya
Me too... I think there is a documentation for django contribution. Thanks, Naresh On Sat, 8 Apr, 2023, 3:51 pm Dipankar, wrote: > Hi All, > > I want to contribute to the Open Source Django Project as a developer. > Can anybody help me please? > > -- > Warm Regards, > Dipankar B. > > -- >

Re: Django "makemigrations -- update" donot working

2023-04-07 Thread Dipankar
Please follow https://docs.djangoproject.com/en/4.1/topics/auth/customizing/ On Fri, Apr 7, 2023 at 3:27 AM Saifullah Shahen wrote: > in my custom user model, initially, my model looks like this > > class User(AbstractUser, BaseModelWithUUID): > phone = models.CharField(max_length=11, >

Re: Implement Ruff Linter

2023-04-06 Thread charettes
Strong agree with Adam here. If Ruff current offer is enhanced speed at the cost of a less mature ecosystem I don't think that it's a tradeoff Django should make at the time being. Simon Le jeudi 6 avril 2023 à 08:16:00 UTC-4, Adam Johnson a écrit : > I don't think we should adopt Ruff. It's

Re: Proposal: Check constraints at the model field level

2023-04-06 Thread charettes
Small clarification here. > it should be noted that SQL has both CHECK on the field and table level, >From my understanding CREATE TABLE / ADD COLUMN checks on the field level are really just syntactic sugar for checks at the table level like just like `REFERENCES` usage is syntactic sugar for

Re: Implement Ruff Linter

2023-04-06 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
I don't think we should adopt Ruff. It's a new, somewhat experimental project. It wouldn't provide any gains except speed, but that is not really a concern since it still takes a handful of seconds to lint Django with Flake8 and co. On Mon, Apr 3, 2023 at 1:59 PM Jerome Obi wrote: > Hi ! > I

Re: Stalebot on djangoproject.com issues

2023-04-06 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
clean. As there are not that many issues open in djangoproject.com > and all issues will have been re-validated, I think it makes sense to > remove it to reduce this additional burden/frustration. > > There are configurations around stale PR closing which I think makes more > sense in general (maybe not

Re: Stalebot on djangoproject.com issues

2023-04-06 Thread Sarah Boyce
>From what it sounds, I guess the main value was prompting a one time spring clean. As there are not that many issues open in djangoproject.com and all issues will have been re-validated, I think it makes sense to remove it to reduce this additional burden/frustration. There are configurati

Re: Proposal: Check constraints at the model field level

2023-04-05 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
Mariusz, I agree with the burden, but it should be noted that SQL has both CHECK on the field and table level, and CheckConstraint only defines table-level constraints. This is not true for unique constraints or indices. Also, what do you think of a way for custom field classes to add

Re: Proposal: Check constraints at the model field level

2023-04-05 Thread Mariusz Felisiak
Hi, This proposal is not really nice from a maintenance point of view as we will end with the same complicated situation we currently have with uniqueness checks or indexes i.e. many ways to define the same: - Field.unique/index - Meta.unique_together/index_together - Meta.constraints/indexes

Re: Proposal: Check constraints at the model field level

2023-04-05 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
I agree this feature would be useful, at least to allow bundling check constraints with custom field classes. As you point out the PositiveIntegerField classes do this within Django, and doubtless many custom fields have used the db_check() method. The only thing I'm not a fan of in your proposal

Re: Issue with get_FOO_display not working in Django admin

2023-04-05 Thread David Sanders
At this point I'll let others chime in with their opinion on whether this is something that needs to change because: 1. I rarely use admin 2. I've never really had the need to override a choice's display over those supplied via `choices` :) On Wed, 5 Apr 2023 at 19:05, 'Ibrahim Abou

Re: Issue with get_FOO_display not working in Django admin

2023-04-05 Thread 'Ibrahim Abou Elenein' via Django developers (Contributions to Django itself)
Isn't this some sort of duplication? why not just use it instead of writing its logic again? On Wednesday, April 5, 2023 at 7:12:48 AM UTC+2 David Sanders wrote: > Hi Ibrahim, > > get_FOO_display() isn't intended to be overridden like that, it's just a > convenience method for use in

Re: Issue with get_FOO_display not working in Django admin

2023-04-04 Thread David Sanders
Hi Ibrahim, get_FOO_display() isn't intended to be overridden like that, it's just a convenience method for use in templates/whatever that refers to the underlying flatchoices. For clarity, please see the documentation:

Re: The problem of versioning a large project.

2023-04-04 Thread Piyush Prasad
Why not use a mono repo? From: django-developers@googlegroups.com on behalf of Alex Sonar Sent: Sunday, April 2, 2023 10:21:33 PM To: Django developers (Contributions to Django itself) Subject: Re: The problem of versioning a large project. It is about one

Re: Fellow Reports - March 2023

2023-04-03 Thread Mariusz Felisiak
Week ending April 2, 2023 *Triaged:* https://code.djangoproject.com/ticket/34438 - UserCreationForm.clean_username() crashes with a custom user model. (accepted) https://code.djangoproject.com/ticket/34439 - mod_wsgi for django with conda environment in Windows doesn't work (invalid)

<    1   2   3   4   5   6   7   8   9   10   >