404 only in Chrome

337 views
Skip to first unread message

neridaj

unread,
Dec 9, 2011, 8:33:41 PM12/9/11
to Django users
Hello,

For some reason I'm getting a 404 in google chrome when I visit /
portfolio/. The url entered is /portfolio/ but it returns as a 404 at /
portfolio/undefined/ in the chrome developer tools window. I read a
post about some issues with chrome handling errors and to resolve it
by unchecking "Use a web service to help resolve navigation errors"
but this didn't help with my problem. I'm not sure why undefined is
being appended to the url, any ideas?

urls.py:

(r'^portfolio/', include('project.urls.web')),

project/urls/web.py:

urlpatterns = patterns('django.views.generic.list_detail',
(r'^$', 'object_list', web_project_info_dict,
'project_web_archive_index'),
(r'^(?P<slug>[-\w]+)/$', 'object_detail', web_project_info_dict),
)

If it was a real 404 why isn't my error page displayed i.e., when I
visit /portfolio/non-existent-slug, I get the proper 404 page.

>>> django.VERSION
(1, 2, 0, 'alpha', 0)

Thanks for any help!

Furbee

unread,
Dec 9, 2011, 8:41:05 PM12/9/11
to django...@googlegroups.com
In urls.py:

Change:
(r'^portfolio/', include('project.urls.web')),

To:
(r'^portfolio/$', include('project.urls.web')),

The dollar sign makes it the end of the regular expression string. Without it, /portfolio/ will match with /portfolio/funstuff, /portfolio/?my_hax_rock, etc. See if that helps.

Furbee


--
You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django...@googlegroups.com.
To unsubscribe from this group, send email to django-users...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.


neridaj

unread,
Dec 9, 2011, 8:52:08 PM12/9/11
to Django users
Thanks for the reply but that didn't help.

Bruno Tikami

unread,
Dec 10, 2011, 8:05:54 AM12/10/11
to django...@googlegroups.com
Hi,

don't know if that helps but when I was working with app engine there were errors that would only occur while using the "Incognito" windows.

Cheers,

Tkm

Tomasz Zieliński

unread,
Dec 10, 2011, 10:36:18 AM12/10/11
to django...@googlegroups.com
Can it be a browser caching issue: http://www.google.pl/support/forum/p/Chrome/thread?tid=3bb0a94bfb063745&hl=en ?

Best,
Tomasz Zielinski

neridaj

unread,
Dec 10, 2011, 3:30:45 PM12/10/11
to Django users
I think it might be related to a jquery plugin i'm using. It appears
that the plugin is not finding an attribute on an image, and is
therefore appending the undefined status to the url in developer
tools. If I comment out the plugin the error is gone.

On Dec 10, 7:36 am, Tomasz Zieliński
<tomasz.zielin...@pyconsultant.eu> wrote:
> Can it be a browser caching issue:http://www.google.pl/support/forum/p/Chrome/thread?tid=3bb0a94bfb0637...
>  ?
>
> Best,
> Tomasz Zielinski

Reply all
Reply to author
Forward
0 new messages