Benjamin Dell
Benjamin Dell

Reputation: 3041

Changes to .py file cause Django site to throw error the first time it is loaded

I'm having a weird issue. Whenever i make changes to a .py file, the immediate refresh of a page in the browser throws up an invalid filter or some other similar error. Refresh again and it works. Does anyone know why this might be happening?

A little vague i know, but does any potential reason for this jump out at you?

Happy to provide any information on request.

UPDATE: One of the error messages can be seen here http://pastebin.com/0vK9kmEU - Please note that this is not always the error message i get, but is one of the most common ones. As mentioned, all i need to do to replicate this is make a single change to a .py file. Click save and then refresh the browser. But refresh a second time and the page always loads properly. Thanks

Upvotes: 0

Views: 72

Answers (1)

KevinDTimm
KevinDTimm

Reputation: 14376

post the error for a better chance at a good response - but, a first guess tells me that there is a conflict between the .py and the .pyc (so, delete the .pyc when you copy the new .py into place)

Upvotes: 2

Related Questions