index file Error 500 - server error Prestashop - prestashop

My shop works perfect, it has nice response, quick loading times, etc....
except for homepage, index or whatever you call it. It always (after loooong loading) finishes with Error 500 - Server error.
Rest of the website works really well.
Did I mess up something?
Thanks

Related

Odoo - Long process leads to XmlHttpRequestError BAD REQUEST error

In odoo while I am doing any long process such as getting data from
amazon and process those data in odoo and after 5-10 min I am getting
this error don't know the reason why this happen.
XmlHttpRequestError BAD REQUEST
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<title>400 Bad Request</title>
<h1>Bad Request</h1>
Invalid JSON data: ''
The process seems running in background in server but I am getting this error every time. This leads users into the wrong direction.
I am wondering why I am always getting this error? Is that a normal behavior ?
Even data processing will be done properly even after getting this
error, so I am not getting the meaning why this error pop out only in
long process.
Is there timeout issue happen with web server ?
Where I need to look out for that ?
UPDATE
I have did this process from different system and it seems everything
working fine over there.
So what my guess is "It is something related to browser end only"
May be browser is not able to manage such idle requests (may be any
request time out settings needs to be updated)
Solution:
It wasn’t clear at first but the tracing telling me exactly what the problem is “cookie”.
The problem was due to a cookie that has become corrupted. Not sure
how it got that way but it seems that the last time it was generated
something went wrong. The easy solution is to delete all your
cookies of that particular domain or should do this from private
window (incognito mode).

python - HTTP Error 503 Service Unavailable

I am trying to scrape data from google and linkedin. Somehow it gave me this error:
*** httperror_seek_wrapper: HTTP Error 503: Service Unavailable
Can someone help advice how I solve this?
Google is simply detecting your query as automated. You would need a captcha solver to get unlimited results. The following link might be helpful.
https://support.google.com/websearch/answer/86640?hl=en
Bypassing Captcha using an OCR Engine:
http://www.debasish.in/2012/01/bypass-captcha-using-python-and.html
Simple Approach:
An even simpler approach is to simply use sleep() a few times and to generate random queries. This way google will not spot that you are using an automated system. But the system is far slower ...
Error Handling:
To simply get remove the error message use try and except
I encountered the same situation and tried using the sleep() function before every request to spread the requests a little. It looked like it was working fine but failed soon enough even with a delay of 2 seconds. What solved it finally was using:
with contextlib.closing(urllib.urlopen(urlToOpen)) as x:
#do stuff with x.
This I did because I thought opening too many requests keeps it open and had to closed. Nevertheless, it worked quite consistently with as less as 0.5s delay time.

Constant 500 Errors on Heroku

I recently switched from Heroku's Bamboo stack to the Cedar one (Rails 3.1.4, Ruby 1.9.2, Thin gem for web server). Since then I keep getting 500 errors such as this, where it seems that the query is not acting right:
207 <13>1 2012-05-06T16:10:51+00:00 d. app web.1 - - ActiveRecord::StatementInvalid (Mysql::Error: : SELECT `foos`.* FROM `foos` WHERE `foos`.`id` = ? LIMIT 1)
It's not an error in the code though because the page eventually renders successfully (ie status 200) when I refresh the page. Sometimes it is 1 refresh, but can get up to 4 refreshes before I get a 200.
I thought it was the database because I was on ClearDB's free plan, but I upgraded to ClearDB's next plan with better I/O performance and it still happens
this never happened when I was on Bamboo
it happens on just about every page that does queries on the DB
it doesn't always happen, but I'd say it happens on at least 1 in 5 pages views
the model/query doesn't matter, the same error occurs (just indicating a different model/fields then the example above)
Do you get the same errors if you are in console heroku run console ? I've never seen this before. Try upgrading your Mysql gem, which one are you using http://api.rubyonrails.org/classes/ActiveRecord/StatementInvalid.html i think the correct one is mysql2 https://rubygems.org/gems/mysql2

how to clear cache and cached template pages in Coldfusion8 (Apache 2.2)

I'm going insane here... my first day with Coldfusion/MySQL running on a local Apache 2.2.0 webserver.
I have an
index.cfm
file, which I took and modified, replacing 20k of code with just
<p>HELLO WORLD</p>
But when I refresh the browser, the old index.cfm keeps coming up. No matter what I do...
- empty the file altogether
- disable browser cache
- clear ColdFusion Admin Panel Cache
- rename index.cfm to wtf.cfm
If I refresh.... same old index.cfm.
All other files are updated once I change them.
Question:
What am I missing? Must be Apache, because everything else makes no sense, doesn't it?
THANKS for ending my index.cfm-misery...!
EDIT:
I removed the whole application besides index.cfm. Refreshing now gives me hello world. I then added the Application.cfm, refreshed and I'm back to my full index.cfm...
Application.cfm looks like this:
...
<CF_callLogin
datasource="dtb"
TableName="table"
UserField="user"
...
BGColor="FFFFFF">
So I guess this calls callLogin.cfm and passes along above parameters. Still I also deleted the callLogin.cfm after trying to edit it forever, so there shouldn't be anything.
Still clueless...
EDIT2:
Could be a cf cache_pages?
I now removed all files in wwwroot\WEB-INF\cfclasses as per http://www.houseoffusion.com/groups/cf-talk/thread.cfm/threadid:54088 let'see if this helps.... doesn't :-(
EDIT3:
Could be a cached template? - http://blogs.sanmathi.org/ashwin/2006/07/12/tangling-with-the-template-cache/ It is... See my answer below
Wasted half a day...
It is a cached template and CF or Apache just seem to not give a *%&/$ if you edit or delete the file.
Here is the hack that worked for me:
http://www.bennadel.com/blog/673-Force-ColdFusion-Server-To-Recompile-A-ColdFusion-Template.htm
= Generate a loong text, append it to the template, save, refresh and violá, all of a sudden your template is updated, as the file size changed enough to finally warrant an update of the template.
You also could try turning this off in development using the CF-Admin > Server Setting > Caching, but this did not work at all in my case (first place I started trying to delete...)
Anyway, maybe this saves someone else a day :-)
Restart Apache then see if resolved, then CF and see if resolved. I haven't run into an issue like this in CF that wasn't resolved after the CF service was restarted.

Classic ASP - Error Catching

I'm working on a site and to help catch errors that we may not hear about, I've created a custom 500 error page.
This page basically records information about the current situation and logs it including the following:
Request.Servervariables("URL")
But, the log seem to actually be providing information about the location of the error.asp file instead of the actual file causing the error. And it doesn't seem to pick up Server.GetLastError().
Any ideas on how to ensure these scripts pick up the errors and deatils about the page causing the error and not the page that is used for 500 errors?
NOTE: When there's an error, the url in the address bar is always the address fo the page causing the error, but the log shows the error handler page 'error.asp'.
I would follow what Dee said, but also be aware that there was something finicky with IIS7 (or 7.5). I can't remember exactly, but you have to do something special to make sure it works on IIS7. Check out this article. IIS7 breaks the server.getlasterror and there is a workaround provided.
Also a cool thing to do is to email yourself those errors. So in your custom 500 asp script just fire off an email with the details. Depends on how critical errors are to your program, but it's good to be in the loop rather than have another log to worry about.