Re: [Technical Board?] Project Ideas, and beginning GSoC 2023.

2022-11-26 Thread Shai Berger
Hi,

Adding to the above, I have two migration-related ideas.

The first is quite down-to-earth: Support for moving models between
apps. This is a long-standing problem, esp. in enterprise-y or just
long-running projects. I have expressed my dissatisfaction with the
current state of things a couple of years ago[1], and maybe it's time
to change that.

The second is a bit of a pie-in-the-sky: Allow auto-detection of custom
migration operations. The auto-detector has its change-detection mostly
hard-coded into it[2], and it doesn't seem easy or even possible to
allow third-party code to intervene. But I dream...

Note: These two are quite independent. Auto-detection of the fact that
a model has moved between apps is not required, supporting such moves
with flags to makemigrations or even a dedicated management-command
would be completely satisfactory as far as I'm concerned.

Thanks,
Shai.


[1] https://forum.djangoproject.com/t/why-do-we-need-apps/827/20
[2] 
https://github.com/django/django/blob/main/django/db/migrations/autodetector.py#L104

-- 
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 emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/20221126180231.372b01a2.shai%40platonix.com.


Using comment in Django

2022-11-26 Thread Tawfeeq Zaghlool
I have two models Profile and Post; I want to allow the user to add 
comments on any of them without repeating the code. 
In other words, the Profile and the Post components contain a comment 
field, and the user who views the Profile wants to add comments, or who 
views Posts intends to add a comment.
I have created another component (class) for the comments and assigned the 
comments as a foreign key inside Profile and Post.

Do I have another solution?

-- 
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 emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/20f8929b-59a5-4379-beb1-def34419682bn%40googlegroups.com.


Re: Using comment in Django

2022-11-26 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
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
to answer your support query with their limited time and energy.

For support, please follow the "Getting Help" page:
https://docs.djangoproject.com/en/stable/faq/help/ . This will help you
find people who are willing to support you, and to ask your question in a
way that makes it easy for them to answer.

Thanks for your understanding and all the best,

Adam

On Sat, Nov 26, 2022 at 10:55 AM Tawfeeq Zaghlool <
tawfeeq.zaghl...@gmail.com> wrote:

> I have two models Profile and Post; I want to allow the user to add
> comments on any of them without repeating the code.
> In other words, the Profile and the Post components contain a comment
> field, and the user who views the Profile wants to add comments, or who
> views Posts intends to add a comment.
> I have created another component (class) for the comments and assigned the
> comments as a foreign key inside Profile and Post.
>
> Do I have another solution?
>
> --
> 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 emails from it, send an
> email to django-developers+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/20f8929b-59a5-4379-beb1-def34419682bn%40googlegroups.com
> 
> .
>

-- 
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 emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CAMyDDM29kdr5%3DADmJ9ckWtMusCZ_Y9VQb-y2Jd0MqJDht1SOgA%40mail.gmail.com.