Hi,

I couldn't upload any file because I get HTTP 0 error (An HTTP error 0 occurred.
/web/ca/upload/js). But in other drupal installations, in the same server, I can do it. The reason? I have devel module, without logs but with query time and memory info (the error is present with any of this options checked).

Files are uploaded (you don't think it because you get the error, but after saving the node, you can see them). Is, then, only a annoying error, but not suitable for endless users).

I've read this:

http://drupal.org/user/35821

When I uncheck these 2 options, I can upload files.

Ps.: drupal core version: 6.16

Ps.: I've got the error with devel 6.x.1.22 and 6.x.1.21

Ps.: sometimes I get this web page
http://delaterra.net/web/ca/upload/js

{ "status": true, "data": "\x3ctable id=\"upload-attachments\" class=\"sticky-enabled\"\x3e\n \x3cthead\x3e\x3ctr\x3e\x3cth\x3e\x3c/th\x3e\x3cth\x3eSuprimeix\x3c/th\x3e\x3cth\x3eLlista\x3c/th\x3e\x3cth\x3eDescripció\x3c/th\x3e\x3cth\x3ePes\x3c/th\x3e\x3cth\x3eMida\x3c/th\x3e \x3c/tr\x3e\x3c/thead\x3e\n\x3ctbody\x3e\n \x3ctr class=\"draggable odd\"\x3e\x3ctd\x3e\x3c/td\x3e\x3ctd\x3e\x3cdiv class=\"form-item\" id=\"edit-files-179-remove-wrapper\"\x3e\n \x3cinput type=\"checkbox\" name=\"files[179][remove]\" id=\"edit-files-179-remove\" value=\"1\" class=\"form-checkbox\" /\x3e\n\x3c/div\x3e\n\x3c/td\x3e\x3ctd\x3e\x3cdiv class=\"form-item\" id=\"edit-files-179-list-wrapper\"\x3e\n \x3cinput type=\"checkbox\" name=\"files[179][list]\" id=\"edit-files-179-list\" value=\"1\" checked=\"checked\" class=\"form-checkbox\" /\x3e\n\x3c/div\x3e\n\x3c/td\x3e\x3ctd\x3e\x3cdiv class=\"form-item\" id=\"edit-files-179-description-wrapper\"\x3e\n \x3cinput type=\"text\" maxlength=\"256\" name=\"files[179][description]\" id=\"edit-files-179-description\" size=\"60\" value=\"new_logo_organic_farming_en.jpg\" class=\"form-text\" /\x3e\n \x3cdiv class=\"description\"\x3e\x3csmall\x3ehttp://delaterra.net/web/sites/default/files/new_logo_organic_farming_en...\x3c/small\x3e\x3c/div\x3e\n\x3c/div\x3e\n\x3c/td\x3e\x3ctd\x3e\x3cdiv class=\"form-item\" id=\"edit-files-179-weight-wrapper\"\x3e\n \x3cselect name=\"files[179][weight]\" class=\"form-select upload-weight\" id=\"edit-files-179-weight\" \x3e\x3coption value=\"-2\"\x3e-2\x3c/option\x3e\x3coption value=\"-1\"\x3e-1\x3c/option\x3e\x3coption value=\"0\" selected=\"selected\"\x3e0\x3c/option\x3e\x3coption value=\"1\"\x3e1\x3c/option\x3e\x3coption value=\"2\"\x3e2\x3c/option\x3e\x3c/select\x3e\n\x3c/div\x3e\n\x3c/td\x3e\x3ctd\x3e5.96 KB\x3c/td\x3e \x3c/tr\x3e\n \x3ctr class=\"draggable even\"\x3e\x3ctd\x3e\x3c/td\x3e\x3ctd\x3e\x3cdiv class=\"form-item\" id=\"edit-files-183-remove-wrapper\"\x3e\n \x3cinput type=\"checkbox\" name=\"files[183][remove]\" id=\"edit-files-183-remove\" value=\"1\" class=\"form-checkbox\" /\x3e\n\x3c/div\x3e\n\x3c/td\x3e\x3ctd\x3e\x3cdiv class=\"form-item\" id=\"edit-files-183-list-wrapper\"\x3e\n \x3cinput type=\"checkbox\" name=\"files[183][list]\" id=\"edit-files-183-list\" value=\"1\" checked=\"checked\" class=\"form-checkbox\" /\x3e\n\x3c/div\x3e\n\x3c/td\x3e\x3ctd\x3e\x3cdiv class=\"form-item\" id=\"edit-files-183-description-wrapper\"\x3e\n \x3cinput type=\"text\" maxlength=\"256\" name=\"files[183][description]\" id=\"edit-files-183-description\" size=\"60\" value=\"Contorno (2).jpg\" class=\"form-text\" /\x3e\n \x3cdiv class=\"description\"\x3e\x3csmall\x3ehttp://delaterra.net/web/sites/default/files/Contorno (2)_4.jpg\x3c/small\x3e\x3c/div\x3e\n\x3c/div\x3e\n\x3c/td\x3e\x3ctd\x3e\x3cdiv class=\"form-item\" id=\"edit-files-183-weight-wrapper\"\x3e\n \x3cselect name=\"files[183][weight]\" class=\"form-select upload-weight\" id=\"edit-files-183-weight\" \x3e\x3coption value=\"-2\"\x3e-2\x3c/option\x3e\x3coption value=\"-1\"\x3e-1\x3c/option\x3e\x3coption value=\"0\" selected=\"selected\"\x3e0\x3c/option\x3e\x3coption value=\"1\"\x3e1\x3c/option\x3e\x3coption value=\"2\"\x3e2\x3c/option\x3e\x3c/select\x3e\n\x3c/div\x3e\n\x3c/td\x3e\x3ctd\x3e4.48 KB\x3c/td\x3e \x3c/tr\x3e\n\x3c/tbody\x3e\n\x3c/table\x3e\n\x3cdiv class=\"form-item\" id=\"edit-upload-wrapper\"\x3e\n \x3clabel for=\"edit-upload\"\x3eAdjunta un fitxer nou: \x3c/label\x3e\n \x3cinput type=\"file\" name=\"files[upload]\" class=\"form-file\" id=\"edit-upload\" size=\"40\" /\x3e\n\n \x3cdiv class=\"description\"\x3eLa mida màxima d\'una pujada és \x3cem\x3e1 MB\x3c/em\x3e. Sols els fitxers amb les següents extensions poden ser pujats: \x3cem\x3ejpg jpeg gif png txt doc xls pdf ppt pps odt ods odp\x3c/em\x3e. \x3c/div\x3e\n\x3c/div\x3e\n\x3cinput type=\"submit\" name=\"attach\" id=\"edit-attach\" value=\"Adjunta\" class=\"form-submit\" /\x3e\n" }
Memory usage:
Memory used at: devel_init()=3.64 MB, devel_shutdown()=24.24 MB.

Comments

calbasi’s picture

Sorry, I've post the wrong link.

Bad link: http://drupal.org/user/35821

Good link: http://drupal.org/node/473760#comment-1797236

salvis’s picture

Category: bug » support

Interesting. Apparently you are very close to some limit on your server, and enabling the two options is enough to push you over that limit.

Installing Views (if you don't have it yet) or OG or some other sizable module might also push you over that limit. Any functionality that you enable will increase consumption of all sorts of resources, but that doesn't mean it's that functionality which is at fault. You could just as well disable some other feature (which happens to consume the same type of resource) and the problem will go away, too.

After reading on in the thread that you mentioned, I see no indication that it's actually Devel that's causing the problem.

djdevin’s picture

Hi,

I can verify calbasi's claims. It has nothing to do with resource limits but that devel is adding it's own information (memory usage) even though the content being outputted is Javascript (so it errors out).

For example: (test1234 is a persistent URL to a group)

/test1234/upload/js (fails, inside context of group/purl)

{ "status": true, "data": "\x3cdiv class=\"messages error\"\x3e\nValidation error, please try again. If this error persists, please contact the site administrator.\x3c/div\x3e\n" }
Queries taking longer than 5 ms and queries executed more than once, are highlighted. Page execution time was 1845.17 ms.
Memory usage:

Memory used at: devel_init()=3.82 MB, devel_shutdown()=53.11 MB.

/upload/js (works, outside context of group/purl)
{ "status": true, "data": "\x3cdiv class=\"messages error\"\x3e\nValidation error, please try again. If this error persists, please contact the site administrator.\x3c/div\x3e\n\x3cdiv class=\"messages warning\"\x3e\nFor easier theme development, the theme registry is being rebuilt on every page request. It is \x3cem\x3eextremely\x3c/em\x3e important to \x3ca href=\"/admin/build/themes/settings/oh2\"\x3eturn off this feature\x3c/a\x3e on production websites.\x3c/div\x3e\n" }

Either devel, upload or PURL could be the problem. Haven't narrowed it down yet.

crifi’s picture

This problem is maybe caused by a wrong configuration of $base_url and should be prevented by inserting a warning message to the requirements system. Therefore I created a new issue #1046682: Install/Update process fails if $base_url is set to a wrong URL. Please close this bug as a duplicate, if this solves your issue. Thanks!

Jalandhar’s picture

I installed the jquery update module and its fixed.

Install the jquery update from:
http://drupal.org/project/jquery_update

salvis’s picture

Status: Active » Fixed

Wow, thanks for that, Jalandhar!

Status: Fixed » Closed (fixed)
Issue tags: -HTTP 0 error

Automatically closed -- issue fixed for 2 weeks with no activity.