Re: Management of static assets

2020-07-05 Thread David Smith
Hi All,

Thank you all for your time taken to read and respond to this topic. 

Based on the conversation I'll try and summarise to try and gain wider 
approval. 

-  There is a valid use case for form media so it should not be deprecated
-  The name is wrong so we should proceed with the rename
-  There are some areas where the current feature can be improved and we 
should progress with these (some items noted on this thread + other open 
tickets on trac)
-  If we wish to 'do more' it requires much more thought and a DEP. A DEP 
should most likely focus on building blocks rather than a full solution. 

The key thing here in the short term is the name change. If there are no 
objections to this I am happy to look at an implementation. Could then come 
back to the mailing list before it's merged, especially as it will be a 
breaking change?

Kind Regards

David



On Saturday, 9 May 2020 21:39:51 UTC+1, Aymeric Augustin wrote:
>
> Thanks David for investigating the topic thoroughly! I wasn't expecting 
> all that when I filed a one-line ticket six years ago :-) So, here's a 
> bunch of opinions.
>
>
> Before I start, I'd like to quote the intro to the Media class 
> :
>
> *Rendering an attractive and easy-to-use Web form requires more than just 
> HTML - it also requires CSS stylesheets, and if you want to use fancy 
> « Web2.0 » widgets, you may also need to include some JavaScript on each 
> page. The exact combination of CSS and JavaScript that is required for any 
> given page will depend upon the widgets that are in use on that page.*
>
>
> That was the reasonable thing to do before single-page apps, asset 
> pipelines, bundlers and code splitting. It's still a fairly reasonable 
> thing to do on a website that relies on good old HTML forms but would 
> benefit from "*fancy « Web2.0 » widgets".*
>
>
> *1. Django shouldn't do anything* (besides what 
> django.contrib.staticfiles already does)* for projects that use webpack *(or 
> any other bundler)
>
> The correct approach with a bundler is to bundle all JavaScript code and, 
> if needed, to optimize with code splitting. Attempting to include only 
> what's needed on each page, like Media does, will usually be 
> counterproductive, because it will general different bundle for different 
> pages and defeat caching by the browser.
>
> Then I know two techniques for integrating the frontend code with Django:
>
> - the single page app 
> 
>  (website 
> and API on separate domains) — this is clearly out of scope of this 
> discussion as Django only provides an API in this scenario
> - what I call the hybrid app 
> 
>  (website 
> and API on the same domain) — here django.contrib.staticfiles helps; it 
> comes after the JavaScript bundler in the deployment pipeline (and I prefer 
> plain django.contrib.staticfiles over django-webpack-loader, but that's 
> another story)
>
> (NB: while the blog posts I just linked to focus on create-react-app, the 
> concepts apply to any modern JavaScript toolchain.)
>
> Regardless, Django already provides more than we need. For example, both 
> webpack and django.contrib.staticfiles add hashes to file names to ensure 
> cache invalidation.
>
> So my answer to questions 3, 4 and 5 is "no, except maybe documentation".
>
> Now, let's leave this brave new world and remember the jQuery era.
>
>
> *2. Media makes sense*
>
> Although pluggable apps are fantastic, the concept doesn't work well for 
> templates, which is where  and 

Facing issue in Django

2020-07-05 Thread vernit jain
Dear All,

I tried to make a simple Personal-Portfolio for learning purpose and I have
deployed my application in Python anywhere, website is working fine but it
gives me an error while clicking on the "blog button", error is "500", and
it is working fine in local system.

Please find the below link for website
https://vernitjain.pythonanywhere.com/

Please do let me know the solution for this, if anyone is able to find the
error.

Thanks and Regards,
Vernit Jain
Contact No: +919045879597
Mail to : vernit.ja...@gmail.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/CAGwyXOGvV1xWPxnutzcGxqFsPFzcqhcPxZBdsp7s2hyxPx7TFA%40mail.gmail.com.


Re: Facing issue in Django

2020-07-05 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
to answer your support query with their limited time and energy.

For support, please follow the "Getting Help" page:
https://docs.djangoproject.com/en/3.0/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 Sun, 5 Jul 2020 at 07:33, vernit jain  wrote:

> Dear All,
>
> I tried to make a simple Personal-Portfolio for learning purpose and I
> have deployed my application in Python anywhere, website is working fine
> but it gives me an error while clicking on the "blog button", error is
> "500", and it is working fine in local system.
>
> Please find the below link for website
> https://vernitjain.pythonanywhere.com/
>
> Please do let me know the solution for this, if anyone is able to find the
> error.
>
> Thanks and Regards,
> Vernit Jain
> Contact No: +919045879597
> Mail to : vernit.ja...@gmail.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/CAGwyXOGvV1xWPxnutzcGxqFsPFzcqhcPxZBdsp7s2hyxPx7TFA%40mail.gmail.com
> 
> .
>


-- 
Adam

-- 
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/CAMyDDM0_Sc0ycZNsru2By1PmfAPNUebnM%3DpcEvjnFpGimVkt3A%40mail.gmail.com.


Re: Facing issue in Django

2020-07-05 Thread Sampad Kumar
Me also getting same error

On Sun, 5 Jul, 2020, 4:15 pm vernit jain,  wrote:

> Dear All,
>
> I tried to make a simple Personal-Portfolio for learning purpose and I
> have deployed my application in Python anywhere, website is working fine
> but it gives me an error while clicking on the "blog button", error is
> "500", and it is working fine in local system.
>
> Please find the below link for website
> https://vernitjain.pythonanywhere.com/
>
> Please do let me know the solution for this, if anyone is able to find the
> error.
>
> Thanks and Regards,
> Vernit Jain
> Contact No: +919045879597
> Mail to : vernit.ja...@gmail.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/CAGwyXOGvV1xWPxnutzcGxqFsPFzcqhcPxZBdsp7s2hyxPx7TFA%40mail.gmail.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/CAMc%3DVvfWi3-CAUz-ARmOOmEb8KUYJ82BV%3DRZXDr2yfNpVCo9vQ%40mail.gmail.com.


Welcome email

2020-07-05 Thread Arvind Nedumaran
Hey everyone,

I notice that people who try to find support on using Django mistakenly post in 
this list and sometime usually has to write an explanation about how this is 
the wrong place.

Could we possibly as a welcome email whenever someone joins the group?

Just a suggestion.

Best,
Arvind

-- 
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/BYAPR14MB29181EBF50C845052F69E5E1A3680%40BYAPR14MB2918.namprd14.prod.outlook.com.


Re: Welcome email

2020-07-05 Thread אורי
I think because this list is called Django developers and what we call
"Django users" are also developers who use Django. But they are developers.

אורי
u...@speedy.net


On Sun, Jul 5, 2020 at 5:59 PM Arvind Nedumaran 
wrote:

> Hey everyone,
>
> I notice that people who try to find support on using Django mistakenly
> post in this list and sometime usually has to write an explanation about
> how this is the wrong place.
>
> Could we possibly as a welcome email whenever someone joins the group?
>
> Just a suggestion.
>
> Best,
> Arvind
>
> --
> 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/BYAPR14MB29181EBF50C845052F69E5E1A3680%40BYAPR14MB2918.namprd14.prod.outlook.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/CABD5YeH0WySFuBnzyXENnMt-5bN5hawS4HYoNUVeGFG8TLG0qw%40mail.gmail.com.


Re: Welcome email

2020-07-05 Thread Arvind Nedumaran
Oh I understand. I meant we could include the distinction in the welcome email 
and possibly a link to the other list.

That may reduce the number of people who may be looking for help but end up 
here mistakenly?

Get Outlook for Android


From: django-developers@googlegroups.com  
on behalf of אורי 
Sent: Sunday, July 5, 2020 8:39:22 PM
To: Django developers (Contributions to Django itself) 

Subject: Re: Welcome email

I think because this list is called Django developers and what we call "Django 
users" are also developers who use Django. But they are developers.

אורי
u...@speedy.net


On Sun, Jul 5, 2020 at 5:59 PM Arvind Nedumaran 
mailto:arvindamir...@gmail.com>> wrote:
Hey everyone,

I notice that people who try to find support on using Django mistakenly post in 
this list and sometime usually has to write an explanation about how this is 
the wrong place.

Could we possibly as a welcome email whenever someone joins the group?

Just a suggestion.

Best,
Arvind

--
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/BYAPR14MB29181EBF50C845052F69E5E1A3680%40BYAPR14MB2918.namprd14.prod.outlook.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/CABD5YeH0WySFuBnzyXENnMt-5bN5hawS4HYoNUVeGFG8TLG0qw%40mail.gmail.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/BYAPR14MB291816DB21661EDBBC954AB5A3680%40BYAPR14MB2918.namprd14.prod.outlook.com.


Re: Welcome email

2020-07-05 Thread Adam Johnson
I can't find a google groups feature that would allow this. Do you know of
one? It might otherwise require a custom bot.

On Sun, 5 Jul 2020 at 16:14, Arvind Nedumaran 
wrote:

> Oh I understand. I meant we could include the distinction in the welcome
> email and possibly a link to the other list.
>
> That may reduce the number of people who may be looking for help but end
> up here mistakenly?
>
> Get Outlook for Android 
>
> --
> *From:* django-developers@googlegroups.com <
> django-developers@googlegroups.com> on behalf of אורי 
> *Sent:* Sunday, July 5, 2020 8:39:22 PM
> *To:* Django developers (Contributions to Django itself) <
> django-developers@googlegroups.com>
> *Subject:* Re: Welcome email
>
> I think because this list is called Django developers and what we call
> "Django users" are also developers who use Django. But they are developers.
>
> אורי
> u...@speedy.net
>
>
> On Sun, Jul 5, 2020 at 5:59 PM Arvind Nedumaran 
> wrote:
>
> Hey everyone,
>
> I notice that people who try to find support on using Django mistakenly
> post in this list and sometime usually has to write an explanation about
> how this is the wrong place.
>
> Could we possibly as a welcome email whenever someone joins the group?
>
> Just a suggestion.
>
> Best,
> Arvind
>
> --
> 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/BYAPR14MB29181EBF50C845052F69E5E1A3680%40BYAPR14MB2918.namprd14.prod.outlook.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/CABD5YeH0WySFuBnzyXENnMt-5bN5hawS4HYoNUVeGFG8TLG0qw%40mail.gmail.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/BYAPR14MB291816DB21661EDBBC954AB5A3680%40BYAPR14MB2918.namprd14.prod.outlook.com
> 
> .
>


-- 
Adam

-- 
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/CAMyDDM2YJpza4URzW%2BrcDZi_7crJcqOz4QrCd7W45PZeR71%3DNA%40mail.gmail.com.


Re: Welcome email

2020-07-05 Thread Ahmad A. Hussein
+1 on this. Here's the relevant feature
 I found.


Ahmad

On Sun, Jul 5, 2020 at 7:58 PM Adam Johnson  wrote:

> I can't find a google groups feature that would allow this. Do you know of
> one? It might otherwise require a custom bot.
>
> On Sun, 5 Jul 2020 at 16:14, Arvind Nedumaran 
> wrote:
>
>> Oh I understand. I meant we could include the distinction in the welcome
>> email and possibly a link to the other list.
>>
>> That may reduce the number of people who may be looking for help but end
>> up here mistakenly?
>>
>> Get Outlook for Android 
>>
>> --
>> *From:* django-developers@googlegroups.com <
>> django-developers@googlegroups.com> on behalf of אורי 
>> *Sent:* Sunday, July 5, 2020 8:39:22 PM
>> *To:* Django developers (Contributions to Django itself) <
>> django-developers@googlegroups.com>
>> *Subject:* Re: Welcome email
>>
>> I think because this list is called Django developers and what we call
>> "Django users" are also developers who use Django. But they are developers.
>>
>> אורי
>> u...@speedy.net
>>
>>
>> On Sun, Jul 5, 2020 at 5:59 PM Arvind Nedumaran 
>> wrote:
>>
>> Hey everyone,
>>
>> I notice that people who try to find support on using Django mistakenly
>> post in this list and sometime usually has to write an explanation about
>> how this is the wrong place.
>>
>> Could we possibly as a welcome email whenever someone joins the group?
>>
>> Just a suggestion.
>>
>> Best,
>> Arvind
>>
>> --
>> 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/BYAPR14MB29181EBF50C845052F69E5E1A3680%40BYAPR14MB2918.namprd14.prod.outlook.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/CABD5YeH0WySFuBnzyXENnMt-5bN5hawS4HYoNUVeGFG8TLG0qw%40mail.gmail.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/BYAPR14MB291816DB21661EDBBC954AB5A3680%40BYAPR14MB2918.namprd14.prod.outlook.com
>> 
>> .
>>
>
>
> --
> Adam
>
> --
> 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/CAMyDDM2YJpza4URzW%2BrcDZi_7crJcqOz4QrCd7W45PZeR71%3DNA%40mail.gmail.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/CAJNa-uPEnskA_seJhscuJ1%2B%3DcR17-OfFM26HpWDDGS7bqv1o0g%40mail.gmail.com.