Python – ImportError: No module named django.utils
When I follow the tutorial – App Engine Series #4 – I got this error for Ajax.py:
1 |
ImportError: No module named django.utils |
According to this article,
Continue readingchrislee.kr – Personal blog as bookshelves
When I follow the tutorial – App Engine Series #4 – I got this error for Ajax.py:
1 |
ImportError: No module named django.utils |
According to this article,
Continue readingWhen I follow the tutorial – App Engine Series #4 – I kept getting the error like below:
1 |
ImportError: No module named controllers |
It is
Continue readingGoogle App Engine의 Datastore 튜토리얼 소스를 실행시 한글을 방명록 이름(Guestbook name)필드에 입력하면 다음과 같은 에러가 발생한다.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
Traceback (most recent call last): File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/lib/webapp2-2.5.2/webapp2.py", line 1535, in __call__ rv = self.handle_exception(request, response, e) File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/lib/webapp2-2.5.2/webapp2.py", line 1529, in __call__ rv = self.router.dispatch(request, response) File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/lib/webapp2-2.5.2/webapp2.py", line 1278, in default_dispatcher return route.handler_adapter(request, response) File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/lib/webapp2-2.5.2/webapp2.py", line 1102, in __call__ return handler.dispatch() File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/lib/webapp2-2.5.2/webapp2.py", line 572, in dispatch return self.handle_exception(e, self.app.debug) File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/lib/webapp2-2.5.2/webapp2.py", line 570, in dispatch return method(*args, **kwargs) File "/Applications/MAMP/htdocs/google_app_engines/datastore/main.py", line 65, in get sign_query_params = urllib.urlencode({'guestbook_name': guestbook_name}) File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/dist27/urllib.py", line 1307, in urlencode v = quote_plus(str(v)) UnicodeEncodeError: 'ascii' codec can't encode characters in position 0-2: ordinal not in range(128) |
UnicodeEncodeError: ‘ascii’ codec
Continue reading한글로 코멘트를 남겼는데 다음과 같은 서버 에러가 발생했다.
1 |
HTTP Error 500 (Internal Server Error): An unexpected condition was encountered while the server was attempting to fulfill the request. |
검색해서 Using Python with Chinese, Japanese and Korean 라는 글을 찾았고, 코드를
Continue readingIn the video, it provides the code as below
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
#!/usr/bin/env python import os import wsgiref.handlers from google.appengine.ext import webapp from google.appengine.ext.webapp import template class MyHandler(webapp.RequestHandler): def get(self): self.response.out.write(template.render('main.html', {})) def main(): app = webapp.WSGIApplication([ (r'.*', MyHandler)], debug= True) wsgiref.handlers.CGIHandler().run(app); if __name__ == "__main__": main() |
However, it gives the error as below:
1 2 3 4 5 6 7 8 |
Traceback (most recent call last): File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/wsgiref/handlers.py", line 86, in run self.finish_response() File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/wsgiref/handlers.py", line 127, in finish_response self.write(data) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/wsgiref/handlers.py", line 202, in write assert type(data) is StringType,"write() argument must be string" AssertionError: write() argument must be string |
To fix
Continue reading
Recent Comments