Hi,
I changed the line to
But the same results,
Thanks
On Wednesday, 27 January 2016 19:21:16 UTC, ofeyofey wrote:
-- I changed the line to
updated = models.DateTimeField(auto_now_add = False, auto_now = True, null=True)
But the same results,
[pi@Huawei-HG658c-instalacion src]$ python manage.py makemigrations
/home/pi/src/djangoTest/urls.py:20: RemovedInDjango110Warning: Support for string view arguments to url() is deprecated and will be removed in Django 1.10 (got news.views.home). Pass the callable instead.
url(r'^$', 'news.views.home', name='home'),
Migrations for 'news':
0003_auto_20160127_2109.py:
- Alter field updated on signup
[pi@Huawei-HG658c-instalacion src]$ python manage.py migrate
/home/pi/src/djangoTest/urls.py:20: RemovedInDjango110Warning: Support for string view arguments to url() is deprecated and will be removed in Django 1.10 (got news.views.home). Pass the callable instead.
url(r'^$', 'news.views.home', name='home'),
Operations to perform:
Apply all migrations: admin, news, contenttypes, auth, sessions
Running migrations:
Rendering model states... DONE
Applying news.0002_signup_updated...Traceback (most recent call last):
File "manage.py", line 10, in <module>
...........
File "/usr/lib/python2.7/site-packages/django/db/models/fields/__init__.py", line 1399, in to_python
parsed = parse_datetime(value)
File "/usr/lib/python2.7/site-packages/django/utils/dateparse.py", line 93, in parse_datetime
match = datetime_re.match(value)
TypeError: expected string or buffer
Thanks
On Wednesday, 27 January 2016 19:21:16 UTC, ofeyofey wrote:
Hi,
I forgot to add a field to a model and wish to add it now.
I added the line to models.py but makemigrations and migrate aren't working now.
Is this possible in Django or do i need to go directly tp the sqlite DB and do it using SQL?
Thanks
Currently following this tutorial https://www.youtube.com/watch?v=g0tvJsUAx7g
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/79a24585-2e34-460c-8b94-5764eac4bad9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
No comments:
Post a Comment