老师 安装captach之后的 执行migirate的时候报错

来源:6-7 用户注册-1

Lee1

2017-11-03

HINT: MySQL's Strict Mode fixes many data integrity problems in MySQL, such as data truncation upon insertion, by escalating warnings into errors. It is strongly recommended you activate it. See: https://docs.djangoproject.com/en/1.11/ref/databases/#mysql-sql-mode


Operations to perform:


  Apply all migrations: admin, auth, captcha, contenttypes, courses, operation, organization, sessions, users, xadmin


Running migrations:


  Applying captcha.0001_initial... OK


  Applying courses.0002_auto_20171103_1448... OK


  Applying organization.0002_auto_20171103_1448...C:\Users\Administrator\Envs\mxonline_env\lib\site-packages\django\db\models\fields\__init__.py:1451: RuntimeWarning: DateTimeField CityDict.add_time received a naive datetime (2017-11-03 14:49:08.543383) while time zone support is active.


  RuntimeWarning)


C:\Users\Administrator\Envs\mxonline_env\lib\site-packages\django\db\models\fields\__init__.py:1451: RuntimeWarning: DateTimeField CityDict.add_time received a naive datetime (2017-11-03 14:49:09.390748) while time zone support is active.


  RuntimeWarning)


C:\Users\Administrator\Envs\mxonline_env\lib\site-packages\django\db\models\fields\__init__.py:1451: RuntimeWarning: DateTimeField CourseOrg.add_time received a naive datetime (2017-11-03 14:49:09.675498) while time zone support is active.


  RuntimeWarning)


C:\Users\Administrator\Envs\mxonline_env\lib\site-packages\django\db\models\fields\__init__.py:1451: RuntimeWarning: DateTimeField Teacher.add_time received a naive datetime (2017-11-03 14:49:09.695523) while time zone support is active.


  RuntimeWarning)


 OK


  Applying users.0004_auto_20171103_1448...C:\Users\Administrator\Envs\mxonline_env\lib\site-packages\django\db\models\fields\__init__.py:1451: RuntimeWarning: DateTimeField EmailVerifyRecord.send_time received a naive datetime (2017-11-03 14:49:09.809446) while time zone support is active.


  RuntimeWarning)


C:\Users\Administrator\Envs\mxonline_env\lib\site-packages\django\db\models\fields\__init__.py:1451: RuntimeWarning: DateTimeField EmailVerifyRecord.send_time received a naive datetime (2017-11-03 14:49:09.810448) while time zone support is active.


  RuntimeWarning)


 OK


这是不是时间格式出问题了啊 ?是不是在model里的操作日期字段的时候使用了本地时间,而不是一个UTC时间.需要如何改啊???


HINT: MySQL's Strict Mode fixes many data integrity problems in MySQL, such as data truncation upon insertion, by escalating warnings into errors. It is strongly recommended you activate it. See: https://docs.djangoproject.com/en/1.11/ref/databases/#mysql-sql-mode 

 还有这个是什么意思啊

  

写回答

1回答

bobby

2017-11-06

你给我发个qq消息 我给你看看

0
1
Lee1
给你发了qq消息
2017-11-06
共1条回复

Python3.6+django+xadmin,打造在线教育平台

【毕设】Python 2.7到3.6 完美适配,Django升级2.0

3677 学习 · 4038 问题

查看课程