The technical issue is that a URL like this:
http://domain.tld/script/path
is split into these two variables by Lighttpd:
SCRIPT_NAME: /script
PATH_INFO: /path
and Django wants this:
SCRIPT_NAME:
PATH_INFO: /script/path
Your example is a bit misleading/lacking. Both o
Antonis,
Well truth be told I'm with uwsgi only because of the snowball effect
you're alluding to, namely we have so many options I'm like looking
on-line for what the most popular and recommended one is, and uwsgi has
a huge fan base. As to server, I opted for lighttpd only because I
alread
That particular issue may be a lighttpd issue, but my question is more general.
Unfortunately I don't remember the kind of trouble I was having with uwsgi.
Are there any people who have used both uwsgi and gunicorn and have a preference
for the former? What benefits have they seen?
Antonis Christ
You're missing the fact that it's the scgi module of lighttpd is what
is causing it. uwsgi shouldn't fix it, as it has no idea if this is
intentional, for example when using mounts [1].
As can be seen in the WSGI spec, the WSGI client (uwsgi / gunicorn /
whathaveyou) should trust what is provided h
> Alas it's a tad complicated and I'll try and publish a module with the fix
> some time soon (it relates to lighttpd, uwsgi, django interactions and the
> management of SCRIPT_NAME and PATH_INFO environment variables which lighttpd
> doesn't do to Django's satisfaction and so it needs tweaking and
Well, not a lot of insight from the broader community on this one, but a
warm thank you to Melvyn Sopacua who took the time to think about it a
bit and apply his experience which led me to:
/usr/local/lib/python3.5/dist-packages/django/urls/base.py
where I could instrument Django a bit and
Humor me and call it list_view in the pattern and template references.
--
Melvyn Sopacua
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to django-users+unsubscr
OK, I've more or less solved my original problems in deploying in this
space. Well I've deployed and am happy.
BUT, I am still bamboozled by something and wonder if anyone has any
clue or insights to share?
I have these two urlpatterns defined:
url(r'^list/(?P\w+)', views.view_List.as_vi
James, you da man! Fixed it at last.
The problem in the end was indeed lighttpd and is explained here:
https://searchcode.com/codesearch/view/12783344/
Essentially lighttpd splits REQUEST_URI into SCRIPT_NAME and PATH_INFO
and passes those three along with a host of other values in the
enviro
On Aug 31, 2017 4:28 AM, "James Schneider" wrote:
What I want to understand is why this "app" suddenly appears in my URLs and
how I can control it (remove it ideally). But I have looked at urls.py long
enough and scratched my head and not found it. settings.py is right next to
if you need to in
On Fri, Sep 1, 2017 at 5:44 PM, mohammad k wrote:
> when you use the url tage in templates
> you have to used like that {% url 'polls:edit' parameters %}: polls is the
> app or controller and the edit is view or method
No you don't *have* to. And polls isn't the app or controller. Please review:
when you use the url tage in templates
you have to used like that {% url 'polls:edit' parameters %}: polls is the
app or controller and the edit is view or method
On Thu, Aug 31, 2017 at 4:46 PM, Melvyn Sopacua
wrote:
> You may have a reverse proxy on port 80 that incorrectly rewrites
> /(.*) to
You may have a reverse proxy on port 80 that incorrectly rewrites
/(.*) to / both ways.
On Thu, Aug 31, 2017 at 2:10 PM, Bernd Wechner wrote:
> Tom,
>
> So I did a quick test now before retiring after all. And I am pulling my
> hair out now. If I restart lighttpd on port 8000 (the last step to ap
Tom,
So I did a quick test now before retiring after all. And I am pulling my
hair out now. If I restart lighttpd on port 8000 (the last step to
apparent convergence) it works. I access both development and webserve
sites on:
http://127.0.0.1:8000/
with server local browsers (Chrome on
Daniel,
it's a red herring. I agree, that's where I'd suspect the issue lies,
but I'm still confident it's a red herring. But because I'm stuck even
the seemingly impossible needs to be revisited I guess. It's hard to
share everything about a webservers config of course in an email, but
there
Tom,
I will credit you there with stating the obvious in a sense, that I was
reluctant to accept. Because it seems frankly impossible. But when
nothing seems possible, we do need to revisit the "apparently"
impossible, so I pulled a sweet trick and tried identical code in
devlopment and deplo
On Thursday, 31 August 2017 10:51:22 UTC+1, Tom Evans wrote:
>
> On Thu, Aug 31, 2017 at 2:09 AM, Bernd Wechner > wrote:
> > Daniel,
> >
> > Yes, I have deployed, that is the problem in a sense. URLs are clean in
> dev
> > and suddenly contain an app_name when deployed.
> >
> > Not sure wha
On Thu, Aug 31, 2017 at 2:09 AM, Bernd Wechner wrote:
> Daniel,
>
> Yes, I have deployed, that is the problem in a sense. URLs are clean in dev
> and suddenly contain an app_name when deployed.
>
> Not sure what you mean by configuration? The Django settings are here:
>
> https://github.com/be
What I want to understand is why this "app" suddenly appears in my URLs and
how I can control it (remove it ideally). But I have looked at urls.py long
enough and scratched my head and not found it. settings.py is right next to
if you need to inspect it.
Out of sheer curiosity, what is the actual
Mohammad,
> you have to use app_name in url.py in each app
I think you have misunderstood or misread my issue below. Clearly I do
not have to use app_name in url.py, because I don't and it works fine.
The problem is the complete inverse, namely I have not asked for the
app_name to appear in t
Daniel,
Yes, I have deployed, that is the problem in a sense. URLs are clean in
dev and suddenly contain an app_name when deployed.
Not sure what you mean by configuration? The Django settings are here:
https://github.com/bernd-wechner/CoGs/blob/master/CoGs/settings.py
The rest of the config
you have Different app in your project yes ?
you have to use app_name in url.py in each app
On Wed, Aug 30, 2017 at 4:11 PM, Bernd Wechner
wrote:
> This has bamboozled me some. And the best thing I've found on-line doesn't
> seem to apply:
>
> https://stackoverflow.com/questions/26944908/dja
i can't do that sorry man
Tell me more clearly, so I may help you better
On Wed, Aug 30, 2017 at 5:16 PM, Daniel Roseman
wrote:
> On Wednesday, 30 August 2017 12:42:01 UTC+1, Bernd Wechner wrote:
>>
>> This has bamboozled me some. And the best thing I've found on-line
>> doesn't seem to apply:
>
from django.conf.urls import url
from . import views
app_name = 'polls'
urlpatterns = [
url(r'^$', views.IndexView.as_view(), name='index'),
url(r'^(?P[0-9]+)/$', views.DetailView.as_view(), name='detail'),
url(r'^(?P[0-9]+)/results/$', views.ResultView.as_view(),
name='results'),
and in url.py beside settings.py use code like that :
url('^polls/',include('polls.urls')),
On Wed, Aug 30, 2017 at 4:29 PM, mohammad k wrote:
> from django.conf.urls import url
> from . import views
>
> app_name = 'polls'
> urlpatterns = [
> url(r'^$', views.IndexView.as_view(), name='index
like that :
app_name = 'polls' in polls folder and in url.py
On Wed, Aug 30, 2017 at 4:26 PM, mohammad k wrote:
> you have Different app in your project yes ?
> you have to use app_name in url.py in each app
>
> On Wed, Aug 30, 2017 at 4:11 PM, Bernd Wechner
> wrote:
>
>> This has bamboozled me
On Wednesday, 30 August 2017 12:42:01 UTC+1, Bernd Wechner wrote:
>
> This has bamboozled me some. And the best thing I've found on-line doesn't
> seem to apply:
>
>
> https://stackoverflow.com/questions/26944908/django-url-mapping-how-to-remove-app-name-from-url-paths
>
> Let me summarise.
>
This has bamboozled me some. And the best thing I've found on-line
doesn't seem to apply:
https://stackoverflow.com/questions/26944908/django-url-mapping-how-to-remove-app-name-from-url-paths
Let me summarise.
I have a site that I've been building and testing with djangos
development server o
28 matches
Mail list logo