c:\DemoBlog\blog_system>manage.py syncdb
Traceback (most recent call last):
File "C:\DemoBlog\blog_system\manage.py", line 10, in <module>
execute_from_command_line(sys.argv)
File "C:\Python34\lib\site-packages\django\core\management\__init__.py", line
399, in execute_from_command_line
utility.execute()
File "C:\Python34\lib\site-packages\django\core\management\__init__.py", line 392, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "C:\Python34\lib\site-packages\django\core\management\base.py", line 242,
in run_from_argv
self.execute(*args, **options.__dict__)
File "C:\Python34\lib\site-packages\django\core\management\base.py", line 280,
in execute
translation.activate('en-us')
File "C:\Python34\lib\site-packages\django\utils\translation\__init__.py", lin
e 130, in activate
return _trans.activate(language)
File "C:\Python34\lib\site-packages\django\utils\translation\trans_real.py", l
ine 188, in activate
_active.value = translation(language)
File "C:\Python34\lib\site-packages\django\utils\translation\trans_real.py", l
ine 177, in translation
default_translation = _fetch(settings.LANGUAGE_CODE)
File "C:\Python34\lib\site-packages\django\utils\translation\trans_real.py", l
ine 159, in _fetch
app = import_module(appname)
File "C:\Python34\lib\importlib\__init__.py", line 104, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 2231, in _gcd_import
File "<frozen importlib._bootstrap>", line 2214, in _find_and_load
File "<frozen importlib._bootstrap>", line 2189, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 321, in _call_with_frames_removed
File "<frozen importlib._bootstrap>", line 2231, in _gcd_import
File "<frozen importlib._bootstrap>", line 2214, in _find_and_load
File "<frozen importlib._bootstrap>", line 2203, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 1200, in _load_unlocked
File "<frozen importlib._bootstrap>", line 1129, in _exec
File "<frozen importlib._bootstrap>", line 1448, in exec_module
File "<frozen importlib._bootstrap>", line 321, in _call_with_frames_removed
File "C:\Python34\lib\site-packages\file_picker\__init__.py", line 4, in <modu
le>
from file_picker.views import FilePickerBase, ImagePickerBase
File "C:\Python34\lib\site-packages\file_picker\views.py", line 73
except Exception, e:
^
SyntaxError: invalid syntax
何が問題なのかわかりません。しかし、settings.pyをきれいにすると
INSTALLED_APPS = (
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'file_picker',
'file_picker.uploads',
'file_picker.wymeditor',
'bootstrap_toolkit',
'blog',
)
そして、ファイルピッカーとブートストラップに接続されているすべてをやってのける-それは動作します、助けてください................................. ................................................................... ................................................................... ...................................................................
except Exception as e
もう一度試したよりも修正しました-それは示しました
c:\DemoBlog\blog_system>manage.py syncdb
C:\Python34\lib\importlib\_bootstrap.py:321: DeprecationWarning: django.utils.si
mplejson is deprecated; use json instead.
return f(*args, **kwds)
Traceback (most recent call last):
File "C:\DemoBlog\blog_system\manage.py", line 10, in <module>
execute_from_command_line(sys.argv)
File "C:\Python34\lib\site-packages\django\core\management\__init__.py", line
399, in execute_from_command_line
utility.execute()
File "C:\Python34\lib\site-packages\django\core\management\__init__.py", line
392, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "C:\Python34\lib\site-packages\django\core\management\base.py", line 242,
in run_from_argv
self.execute(*args, **options.__dict__)
File "C:\Python34\lib\site-packages\django\core\management\base.py", line 280,
in execute
translation.activate('en-us')
File "C:\Python34\lib\site-packages\django\utils\translation\__init__.py", lin
e 130, in activate
return _trans.activate(language)
File "C:\Python34\lib\site-packages\django\utils\translation\trans_real.py", l
ine 188, in activate
_active.value = translation(language)
File "C:\Python34\lib\site-packages\django\utils\translation\trans_real.py", l
ine 177, in translation
default_translation = _fetch(settings.LANGUAGE_CODE)
File "C:\Python34\lib\site-packages\django\utils\translation\trans_real.py", l
ine 159, in _fetch
app = import_module(appname)
File "C:\Python34\lib\importlib\__init__.py", line 104, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 2231, in _gcd_import
File "<frozen importlib._bootstrap>", line 2214, in _find_and_load
File "<frozen importlib._bootstrap>", line 2189, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 321, in _call_with_frames_removed
File "<frozen importlib._bootstrap>", line 2231, in _gcd_import
File "<frozen importlib._bootstrap>", line 2214, in _find_and_load
File "<frozen importlib._bootstrap>", line 2203, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 1200, in _load_unlocked
File "<frozen importlib._bootstrap>", line 1129, in _exec
File "<frozen importlib._bootstrap>", line 1448, in exec_module
File "<frozen importlib._bootstrap>", line 321, in _call_with_frames_removed
File "C:\Python34\lib\site-packages\file_picker\__init__.py", line 4, in <modu
le>
from file_picker.views import FilePickerBase, ImagePickerBase
File "C:\Python34\lib\site-packages\file_picker\views.py", line 17, in <module>
from sorl.thumbnail.main import DjangoThumbnail
File "C:\Python34\lib\site-packages\sorl\thumbnail\main.py", line 4, in <module>
from django.utils.encoding import iri_to_uri, force_unicode
ImportError: cannot import name 'force_unicode'
................................................................... ................................................................... ................................................................... ................................ sorl-thumnail をインストールする前に、redis、Pillow、pgmagick などの要件をインストールする必要がありましたとワンド。
私だけがpgmagickをインストールできませんでした-ここにエラーがあります
C:\Users\www>pip install pgmagick
Downloading/unpacking pgmagick
Downloading pgmagick-0.5.7.tar.gz
Running setup.py (path:C:\TEMP\pip_build_www\pgmagick\setup.py) egg_info for p
ackage pgmagick
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "C:\TEMP\pip_build_www\pgmagick\setup.py", line 74, in <module>
raise Exception("Magick++ not found")
Exception: Magick++ not found
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 17, in <module>
File "C:\TEMP\pip_build_www\pgmagick\setup.py", line 74, in <module>
raise Exception("Magick++ not found")
Exception: Magick++ not found
----------------------------------------
Cleaning up...
Command python setup.py egg_info failed with error code 1 in C:\TEMP\pip_build_w
ww\pgmagick
Storing debug log for failure in C:\Users\www\pip\pip.log
................................................................... ................................................................... .......私は sorl-thumbnail をインストールしましたが、何も起こらず、再試行しました -
c:\site>manage.py syncdb
C:\Python34\lib\importlib\_bootstrap.py:321: DeprecationWarning: django.utils.si
mplejson is deprecated; use json instead.
return json
Traceback (most recent call last):
File "C:\site\manage.py", line 10, in <module>
execute_from_command_line(sys.argv)
File "C:\Python34\lib\site-packages\django\core\management\__init__.py", line
399, in execute_from_command_line
utility.execute()
File "C:\Python34\lib\site-packages\django\core\management\__init__.py", line
392, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "C:\Python34\lib\site-packages\django\core\management\base.py", line 242,
in run_from_argv
self.execute(*args, **options.__dict__)
File "C:\Python34\lib\site-packages\django\core\management\base.py", line 280,
in execute
translation.activate('en-us')
File "C:\Python34\lib\site-packages\django\utils\translation\__init__.py", lin
e 130, in activate
return _trans.activate(language)
File "C:\Python34\lib\site-packages\django\utils\translation\trans_real.py", l
ine 188, in activate
_active.value = translation(language)
File "C:\Python34\lib\site-packages\django\utils\translation\trans_real.py", l
ine 177, in translation
default_translation = _fetch(settings.LANGUAGE_CODE)
File "C:\Python34\lib\site-packages\django\utils\translation\trans_real.py", l
ine 159, in _fetch
app = import_module(appname)
File "C:\Python34\lib\importlib\__init__.py", line 104, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 2231, in _gcd_import
File "<frozen importlib._bootstrap>", line 2214, in _find_and_load
File "<frozen importlib._bootstrap>", line 2189, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 321, in _call_with_frames_removed
File "<frozen importlib._bootstrap>", line 2231, in _gcd_import
File "<frozen importlib._bootstrap>", line 2214, in _find_and_load
File "<frozen importlib._bootstrap>", line 2203, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 1200, in _load_unlocked
File "<frozen importlib._bootstrap>", line 1129, in _exec
File "<frozen importlib._bootstrap>", line 1448, in exec_module
File "<frozen importlib._bootstrap>", line 321, in _call_with_frames_removed
File "C:\Python34\lib\site-packages\file_picker\__init__.py", line 4, in <modu
le>
from file_picker.views import FilePickerBase, ImagePickerBase
File "C:\Python34\lib\site-packages\file_picker\views.py", line 17, in <module>
from sorl.thumbnail.main import DjangoThumbnail
ImportError: No module named 'sorl.thumbnail.main'