python Django 报错 SyntaxError: Generator expression must be parenthesized 解决方法

本文介绍了在使用Python Django时遇到的SyntaxError:Generator expression must be parenthesized错误的原因和解决方法。该错误可能是由于Django 1.11与Python 3.7版本不兼容导致。解决方案包括删除引发错误的逗号或升级到Django 2.0及以上版本。
摘要由CSDN通过智能技术生成

Django 报错 SyntaxError: Generator expression must be parenthesized

Traceback (most recent call last):
  File "manage.py", line 22, in <module>
    execute_from_command_line(sys.argv)
  File "D:\lijingwen\Python\Python37\lib\site-packages\django\core\management\__init__.py", line 364, in execute_from_command_line
    utility.execute()
  File "D:\lijingwen\Python\Python37\lib\site-packages\django\core\management\__init__.py", line 338, in execute
    django.setup()
  File "D:\lijingwen\Python\Python37\lib\site-packages\django\__init__.py", line 27, in setup
    apps.populate(settings.INSTALLED_APPS)
  File "D:\lijingwen\Python\Python37\lib\site-packages\django\apps\registry.py", line 85, in populate
    app_config = AppConfig.create(entry)
  File "D:\lijingwen\Python\Python37\lib\site-packages\django\apps\config.py", line 94, in creat
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值