teratail header banner
teratail header banner
質問するログイン新規登録

質問編集履歴

1

エラー文追加しました。

2019/02/14 12:27

投稿

fetchup
fetchup

スコア11

title CHANGED
@@ -1,1 +1,1 @@
1
- OperationalError at /admin/auth/user/1/change/ラー
1
+ Django > createsuperuser > ローカルウザで編集すると保存できない
body CHANGED
@@ -22,4 +22,137 @@
22
22
  > '/Users/shin/dev/tryjango/lib/python3.7/lib-dynload',
23
23
  > '/anaconda3/lib/python3.7',
24
24
  > '/Users/shin/dev/tryjango/lib/python3.7/site-packages']
25
- > Server time: Thu, 14 Feb 2019 11:38:17 +0000
25
+ > Server time: Thu, 14 Feb 2019 11:38:17 +0000
26
+
27
+
28
+ > Environment:
29
+ >
30
+ >
31
+ > Request Method: POST
32
+ > Request URL: http://127.0.0.1:8000/admin/auth/user/1/change/
33
+ >
34
+ > Django Version: 2.0.7
35
+ > Python Version: 3.7.1
36
+ > Installed Applications:
37
+ > ['django.contrib.admin',
38
+ > 'django.contrib.auth',
39
+ > 'django.contrib.contenttypes',
40
+ > 'django.contrib.sessions',
41
+ > 'django.contrib.messages',
42
+ > 'django.contrib.staticfiles',
43
+ > 'products']
44
+ > Installed Middleware:
45
+ > ['django.middleware.security.SecurityMiddleware',
46
+ > 'django.contrib.sessions.middleware.SessionMiddleware',
47
+ > 'django.middleware.common.CommonMiddleware',
48
+ > 'django.middleware.csrf.CsrfViewMiddleware',
49
+ > 'django.contrib.auth.middleware.AuthenticationMiddleware',
50
+ > 'django.contrib.messages.middleware.MessageMiddleware',
51
+ > 'django.middleware.clickjacking.XFrameOptionsMiddleware']
52
+
53
+
54
+ > Traceback:
55
+ >
56
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/backends/utils.py" in _execute
57
+ > 85. return self.cursor.execute(sql, params)
58
+ >
59
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/backends/sqlite3/base.py" in execute
60
+ > 303. return Database.Cursor.execute(self, query, params)
61
+ >
62
+ > The above exception (no such table: main.auth_user__old) was the direct cause of the following exception:
63
+ >
64
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/core/handlers/exception.py" in inner
65
+ > 35. response = get_response(request)
66
+ >
67
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/core/handlers/base.py" in _get_response
68
+ > 128. response = self.process_exception_by_middleware(e, request)
69
+ >
70
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/core/handlers/base.py" in _get_response
71
+ > 126. response = wrapped_callback(request, *callback_args, **callback_kwargs)
72
+ >
73
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/contrib/admin/options.py" in wrapper
74
+ > 575. return self.admin_site.admin_view(view)(*args, **kwargs)
75
+ >
76
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/utils/decorators.py" in _wrapped_view
77
+ > 142. response = view_func(request, *args, **kwargs)
78
+ >
79
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/views/decorators/cache.py" in _wrapped_view_func
80
+ > 44. response = view_func(request, *args, **kwargs)
81
+ >
82
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/contrib/admin/sites.py" in inner
83
+ > 223. return view(request, *args, **kwargs)
84
+ >
85
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/contrib/admin/options.py" in change_view
86
+ > 1557. return self.changeform_view(request, object_id, form_url, extra_context)
87
+ >
88
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/utils/decorators.py" in _wrapper
89
+ > 62. return bound_func(*args, **kwargs)
90
+ >
91
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/utils/decorators.py" in _wrapped_view
92
+ > 142. response = view_func(request, *args, **kwargs)
93
+ >
94
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/utils/decorators.py" in bound_func
95
+ > 58. return func.__get__(self, type(self))(*args2, **kwargs2)
96
+ >
97
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/contrib/admin/options.py" in changeform_view
98
+ > 1451. return self._changeform_view(request, object_id, form_url, extra_context)
99
+ >
100
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/contrib/admin/options.py" in _changeform_view
101
+ > 1498. self.log_change(request, new_object, change_message)
102
+ >
103
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/contrib/admin/options.py" in log_change
104
+ > 790. change_message=message,
105
+ >
106
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/contrib/admin/models.py" in log_action
107
+ > 29. change_message=change_message,
108
+ >
109
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/models/manager.py" in manager_method
110
+ > 82. return getattr(self.get_queryset(), name)(*args, **kwargs)
111
+ >
112
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/models/query.py" in create
113
+ > 417. obj.save(force_insert=True, using=self.db)
114
+ >
115
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/models/base.py" in save
116
+ > 729. force_update=force_update, update_fields=update_fields)
117
+ >
118
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/models/base.py" in save_base
119
+ > 759. updated = self._save_table(raw, cls, force_insert, force_update, using, update_fields)
120
+ >
121
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/models/base.py" in _save_table
122
+ > 842. result = self._do_insert(cls._base_manager, using, fields, update_pk, raw)
123
+ >
124
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/models/base.py" in _do_insert
125
+ > 880. using=using, raw=raw)
126
+ >
127
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/models/manager.py" in manager_method
128
+ > 82. return getattr(self.get_queryset(), name)(*args, **kwargs)
129
+ >
130
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/models/query.py" in _insert
131
+ > 1125. return query.get_compiler(using=using).execute_sql(return_id)
132
+ >
133
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/models/sql/compiler.py" in execute_sql
134
+ > 1285. cursor.execute(sql, params)
135
+ >
136
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/backends/utils.py" in execute
137
+ > 100. return super().execute(sql, params)
138
+ >
139
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/backends/utils.py" in execute
140
+ > 68. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
141
+ >
142
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/backends/utils.py" in _execute_with_wrappers
143
+ > 77. return executor(sql, params, many, context)
144
+ >
145
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/backends/utils.py" in _execute
146
+ > 85. return self.cursor.execute(sql, params)
147
+ >
148
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/utils.py" in __exit__
149
+ > 89. raise dj_exc_value.with_traceback(traceback) from exc_value
150
+ >
151
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/backends/utils.py" in _execute
152
+ > 85. return self.cursor.execute(sql, params)
153
+ >
154
+ > File "/Users/shin/dev/tryjango/lib/python3.7/site-packages/django/db/backends/sqlite3/base.py" in execute
155
+ > 303. return Database.Cursor.execute(self, query, params)
156
+ >
157
+ > Exception Type: OperationalError at /admin/auth/user/1/change/
158
+ > Exception Value: no such table: main.auth_user__old