我有一個非常非常重要的問題需要請教大家,真的已經是沒有辦法了
原因是這樣的,我在實習公司裡有一個項目,是直接打包遠程在客戶電腦上安裝的,項目沒有問題,因為我想多了解一下這個項目,所以我在我自己的電腦和公司電腦上也安裝了我這個項目包,結果我突然發現一個問題:
就是在我的安裝這個項目之後我的django就不能運行了,我的猜測是公司的項目文件的問題,因為公司的項目也是基於django來完成的
以下是我的操作以及報錯
C:\Users\Double\Desktop>md django3C:\Users\Double\Desktop>cd django3C:\Users\Double\Desktop\django3>django-admin startproject mypro3C:\Users\Double\Desktop\django3>cd mypro3C:\Users\Double\Desktop\django3\mypro3>python manage.py startapp app03C:\Users\Double\Desktop\django3\mypro3>python manage.py runserverTraceback (most recent call last): File "D:\Program Files\Python38\lib\site-packages\django\core\management\base.py", line 323, in run_from_argv self.execute(*args, **cmd_options) File "D:\Program Files\Python38\lib\site-packages\django\core\management\commands\runserver.py", line 60, in execute super().execute(*args, **options) File "D:\Program Files\Python38\lib\site-packages\django\core\management\base.py", line 364, in execute output = self.handle(*args, **options) File "D:\Program Files\Python38\lib\site-packages\django\core\management\commands\runserver.py", line 67, in handle if not settings.DEBUG and not settings.ALLOWED_HOSTS: File "D:\Program Files\Python38\lib\site-packages\django\conf\__init__.py", line 79, in __getattr__ self._setup(name) File "D:\Program Files\Python38\lib\site-packages\django\conf\__init__.py", line 66, in _setup self._wrapped = Settings(settings_module) File "D:\Program Files\Python38\lib\site-packages\django\conf\__init__.py", line 157, in __init__ mod = importlib.import_module(self.SETTINGS_MODULE) File "D:\Program Files\Python38\lib\importlib\__init__.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "<frozen importlib._bootstrap>", line 1014, in _gcd_import File "<frozen importlib._bootstrap>", line 991, in _find_and_load File "<frozen importlib._bootstrap>", line 961, in _find_and_load_unlocked File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed File "<frozen importlib._bootstrap>", line 1014, in _gcd_import File "<frozen importlib._bootstrap>", line 991, in _find_and_load File "<frozen importlib._bootstrap>", line 973, in _find_and_load_unlockedModuleNotFoundError: No module named 'ZK3'During handling of the above exception, another exception occurred:Traceback (most recent call last): File "manage.py", line 21, in <module> main() File "manage.py", line 17, in main execute_from_command_line(sys.argv) File "D:\Program Files\Python38\lib\site-packages\django\core\management\__init__.py", line 381, in execute_from_command_line utility.execute() File "D:\Program Files\Python38\lib\site-packages\django\core\management\__init__.py", line 375, in execute self.fetch_command(subcommand).run_from_argv(self.argv) File "D:\Program Files\Python38\lib\site-packages\django\core\management\base.py", line 336, in run_from_argv connections.close_all() File "D:\Program Files\Python38\lib\site-packages\django\db\utils.py", line 219, in close_all for alias in self: File "D:\Program Files\Python38\lib\site-packages\django\db\utils.py", line 213, in __iter__ return iter(self.databases) File "D:\Program Files\Python38\lib\site-packages\django\utils\functional.py", line 80, in __get__ res = instance.__dict__[self.name] = self.func(instance) File "D:\Program Files\Python38\lib\site-packages\django\db\utils.py", line 147, in databases self._databases = settings.DATABASES File "D:\Program Files\Python38\lib\site-packages\django\conf\__init__.py", line 79, in __getattr__ self._setup(name) File "D:\Program Files\Python38\lib\site-packages\django\conf\__init__.py", line 66, in _setup self._wrapped = Settings(settings_module) File "D:\Program Files\Python38\lib\site-packages\django\conf\__init__.py", line 157, in __init__ mod = importlib.import_module(self.SETTINGS_MODULE) File "D:\Program Files\Python38\lib\importlib\__init__.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "<frozen importlib._bootstrap>", line 1014, in _gcd_import File "<frozen importlib._bootstrap>", line 991, in _find_and_load File "<frozen importlib._bootstrap>", line 961, in _find_and_load_unlocked File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed File "<frozen importlib._bootstrap>", line 1014, in _gcd_import File "<frozen importlib._bootstrap>", line 991, in _find_and_load File "<frozen importlib._bootstrap>", line 973, in _find_and_load_unlockedModuleNotFoundError: No module named 'ZK3'
我知道我們公司的項目名稱就叫做ZK3,但是按道理我之後創建的django項目是不會有所影響的啊,不知道有沒有人能幫我解決以下這個問題,我之前的電腦是可以正常使用的,但是就是在安裝了這個安裝後就不能了,我不知道應該怎麼樣去修改才能正常使用