私はこのエラーを完全に理解していません。私はdjango-nonrelを使い、manage.pyで自分のアプリケーションにアップロードします。パスと間違っている何Googleアプリケーションエンジンのdjangoへのパス
<type 'exceptions.AttributeError'>: 'Settings' object has no attribute 'DATABASE_ROUTERS'
Traceback (most recent call last):
File "/base/data/home/apps/appid/3.347077242893060339/execute.py", line 2, in <module>
from djapp import queue_controller
File "/base/data/home/apps/appid/3.347077242893060339/djapp/queue_controller.py", line 5, in <module>
from djapp.models import Operation
File "/base/data/home/apps/appid/3.347077242893060339/djapp/models.py", line 3, in <module>
from django.db import models
File "/base/data/home/apps/appid/3.347077242893060339/django/db/__init__.py", line 66, in <module>
router = ConnectionRouter(settings.DATABASE_ROUTERS)
File "/base/python_runtime/python_lib/versions/third_party/django-0.96/django/conf/__init__.py", line 32, in __getattr__
return getattr(self._target, name)
または
<type 'exceptions.ImportError'>: No module named files.uploadhandler
Traceback (most recent call last):
File "/base/data/home/apps/appid/3.347067228745038183/djangoappengine/main/main.py", line 28, in <module>
from django.core.handlers.wsgi import WSGIHandler
File "/base/python_runtime/python_lib/versions/third_party/django-0.96/django/core/handlers/wsgi.py", line 1, in <module>
from django.core.handlers.base import BaseHandler
File "/base/python_runtime/python_lib/versions/third_party/django-0.96/django/core/handlers/base.py", line 3, in <module>
from django import http
File "/base/data/home/apps/appid/3.347067228745038183/django/http/__init__.py", line 28, in <module>
from django.http.multipartparser import MultiPartParser
File "/base/data/home/apps/appid/3.347067228745038183/django/http/multipartparser.py", line 14, in <module>
from django.core.files.uploadhandler import StopUpload, SkipFile, StopFutureHandlers
:そして、時にはは、私はこれを持っていますか?なぜこれが起こるのですか?最初のパスは "/base/data/home/apps/app-id/3.347046818251769742/django/"で、 "/base/python_runtime/python_lib/versions/third_party/django-0.96/django/"です。
このエラーを回避するにはどうすればよいですか?
私はのsys.pathをチェックしているが、私はdb/__init__.py
がfrom django.conf import Settings
のような何かをすることを推測し、どんな理由であれ、それは時々だ、新しいジャンゴを数回アップロードしたすべての不要なファイルを削除し、私は失われています:(
sys.path = ['/base/data/home/apps/appid/3.347077364008022180',
'/base/data/home/apps/appid/3.347077364008022180/djangoappengine/lib',
'/base/python_runtime/python_dist/lib/python25.zip',
'/base/python_runtime/python_dist/lib/python2.5/',
'/base/python_runtime/python_dist/lib/python2.5/plat-linux2',
'/base/python_runtime/python_dist/lib/python2.5/lib-tk',
'/base/python_runtime/python_dist/lib/python2.5/lib-dynload',
'/base/python_runtime/python_lib/versions/1',
'/base/data/home/apps/appid/3.347077364008022180/']
あなたはappstatsを使用していますか?この種のことは、インスタンスがnonrelがそのインスタンスで使用される前にデフォルトのDjangoをロードするときに起こると思われます。 – geoffspear
djangoを読み込んだ「appengine console」アプリケーションをアップロードしてから削除しました。私のアプリケーションにはdjango-nonrelとwaveのロボットAPIしかありません。インスタンスはデフォルトのDjangoをどのようにロードしますか? – shmakova