Python [解决方法] error: Requested setting INSTALLED_APPS, but settings are not configured
来源:互联网 发布:淘宝旧版本5.1.0下载 编辑:程序博客网 时间:2024/06/08 02:16
今天在学习Django库
在创建项目的时候:
django-admin.py startproject [项目名称]
报错
error: Requested setting INSTALLED_APPS, but settings are not configured. You must either define the environment variable DJANGO_SETTINGS_MODULE or call settings.configure() before accessing settings.).
解决
经过各种折腾,最后找到解决方法
django-admin startproject [项目名称]
对,就是这么简单,把django-admin.py换成django-admin
分析
为什么这样:
我是用pip装的Django,而网上大部分的安装指南是手动安装的。
pip在安装Django的时候会自动生成一个django-admin的可运行文件。所以~
0 0
- Python [解决方法] error: Requested setting INSTALLED_APPS, but settings are not configured
- Requested setting TEMPLATE_DEBUG, but settings are not configured.
- pycharm 中的 Requested setting CACHES, but settings are not configured.
- Requested setting DEFAULT_INDEX_TABLESPACE, but settings are not configured
- django模板报错Requested setting TEMPLATE_DEBUG, but settings are not configured. You must either define
- [Django]引入模版之后报错Requested setting TEMPLATE_DEBUG, but settings are not configured.
- [Django]引入模版之后报错Requested setting TEMPLATE_DEBUG, but settings are not configured.
- django中执行py报错Requested setting DEFAULT_INDEX_TABLESPACE, but settings are not configured
- django.core.exceptions.ImproperlyConfigured: Requested setting TEMPLATE_DEBUG, but settings are not解
- django.core.exceptions.ImproperlyConfigured: Requested setting CACHES, but settings are not configur
- 3_ImproperlyConfigured Requested setting DEFAULT_INDEX_TABLESPACE, but settings
- Gradle settings for this project are not configured yet
- Whoops! Sorry, but you are not allowed to perform the action requested.
- Error: Read from storage 0 bytes, but requested 12 bytes 的解决方法
- django模板报错Requested setting TEMPLATE_DEBUG, but...
- BNE_UIX_PHYSICAL_DIRECTORY Is Not Configured Error
- (error) MISCONF Redis is configured to save RDB snapshots, but is currently not able to persist on d
- (error) MISCONF Redis is configured to save RDB snapshots, but is currently not able to persist on d
- VBRK-RFBSK - 会計への転記ステータス
- [Android]Cocos2d-x集成facebook sdk 4.x(一)
- HDU 5646 DZY Loves Partition(数学)
- python --类方法、对象方法、静态方法
- AMR文件格式分析
- Python [解决方法] error: Requested setting INSTALLED_APPS, but settings are not configured
- hdu 1890 Robotic Sort (Splay区间翻转)
- 配置NotePad++ 的java 开发环境
- oracle 10g中的几个概念(sid/db_name/server_name)
- 查看进程状态/proc/pid/stat
- Memcached 查看列出所有key方法
- 拓扑排序原理和实现
- 深入理解java异常处理机制
- echarts tooltip标签内容对齐