title: Django 2.0 Tutorial - Error when executing python3 manage.py makemigrations
body: <p>i am interested in learning Django for python. Therefore i followed their Tutorial - yet now i am stuck at the following point of the second tutorial element:</p>
  
  <p>Problem: According to the tutorial i shall run a "Database Migration" by using the following codes:</p>
  
  <pre><code>python3 manage.py makemigrations
  python3 manage.py migratecode
  </code></pre>
  
  <p>I do receive the following error message on execution of the first command (makemigrations):</p>
  
  <pre><code>&gt; (django_second_test) sebastian@sebastian-Lenovo-Y50-70
  &gt; ~/Dokumente/py_virtualenv/django_virtualenv/django_second_test/locallibrary/locallibrary
  &gt; $ python3 manage.py makemigrations Traceback (most recent call last): 
  &gt; File "manage.py", line 15, in &lt;module&gt;
  &gt;     execute_from_command_line(sys.argv)   File "/home/sebastian/Dokumente/py_virtualenv/django_virtualenv/django_second_test/lib/python3.5/site-packages/django/core/management/__init__.py", line 371, in execute_from_command_line
  &gt;     utility.execute()   File "/home/sebastian/Dokumente/py_virtualenv/django_virtualenv/django_second_test/lib/python3.5/site-packages/django/core/management/__init__.py", line 365, in execute
  &gt;     self.fetch_command(subcommand).run_from_argv(self.argv)   File "/home/sebastian/Dokumente/py_virtualenv/django_virtualenv/django_second_test/lib/python3.5/site-packages/django/core/management/base.py",
  &gt; line 288, in run_from_argv
  &gt;     self.execute(*args, **cmd_options)   File "/home/sebastian/Dokumente/py_virtualenv/django_virtualenv/django_second_test/lib/python3.5/site-packages/django/core/management/base.py",
  &gt; line 332, in execute
  &gt;     self.check()   File "/home/sebastian/Dokumente/py_virtualenv/django_virtualenv/django_second_test/lib/python3.5/site-packages/django/core/management/base.py",
  &gt; line 364, in check
  &gt;     include_deployment_checks=include_deployment_checks,   File "/home/sebastian/Dokumente/py_virtualenv/django_virtualenv/django_second_test/lib/python3.5/site-packages/django/core/management/base.py",
  &gt; line 351, in _run_checks
  &gt;     return checks.run_checks(**kwargs)   File "/home/sebastian/Dokumente/py_virtualenv/django_virtualenv/django_second_test/lib/python3.5/site-packages/django/core/checks/registry.py",
  &gt; line 73, in run_checks
  &gt;     new_errors = check(app_configs=app_configs)   File "/home/sebastian/Dokumente/py_virtualenv/django_virtualenv/django_second_test/lib/python3.5/site-packages/django/core/checks/urls.py",
  &gt; line 40, in check_url_namespaces_unique
  &gt;     all_namespaces = _load_all_namespaces(resolver)   File "/home/sebastian/Dokumente/py_virtualenv/django_virtualenv/django_second_test/lib/python3.5/site-packages/django/core/checks/urls.py",
  &gt; line 57, in _load_all_namespaces
  &gt;     url_patterns = getattr(resolver, 'url_patterns', [])   File "/home/sebastian/Dokumente/py_virtualenv/django_virtualenv/django_second_test/lib/python3.5/site-packages/django/utils/functional.py",
  &gt; line 36, in __get__
  &gt;     res = instance.__dict__[self.name] = self.func(instance)   File "/home/sebastian/Dokumente/py_virtualenv/django_virtualenv/django_second_test/lib/python3.5/site-packages/django/urls/resolvers.py",
  &gt; line 536, in url_patterns
  &gt;     patterns = getattr(self.urlconf_module, "urlpatterns", self.urlconf_module)   File
  &gt; "/home/sebastian/Dokumente/py_virtualenv/django_virtualenv/django_second_test/lib/python3.5/site-packages/django/utils/functional.py",
  &gt; line 36, in __get__
  &gt;     res = instance.__dict__[self.name] = self.func(instance)   File "/home/sebastian/Dokumente/py_virtualenv/django_virtualenv/django_second_test/lib/python3.5/site-packages/django/urls/resolvers.py",
  &gt; line 529, in urlconf_module
  &gt;     return import_module(self.urlconf_name)   File "/usr/lib/python3.5/importlib/__init__.py", line 126, in import_module
  &gt;     return _bootstrap._gcd_import(name[level:], package, level)   File "&lt;frozen importlib._bootstrap&gt;", line 986, in _gcd_import   File
  &gt; "&lt;frozen importlib._bootstrap&gt;", line 969, in _find_and_load   File
  &gt; "&lt;frozen importlib._bootstrap&gt;", line 958, in _find_and_load_unlocked 
  &gt; File "&lt;frozen importlib._bootstrap&gt;", line 673, in _load_unlocked  
  &gt; File "&lt;frozen importlib._bootstrap_external&gt;", line 665, in
  &gt; exec_module   File "&lt;frozen importlib._bootstrap&gt;", line 222, in
  &gt; _call_with_frames_removed   File "/home/sebastian/Dokumente/py_virtualenv/django_virtualenv/django_second_test/locallibrary/locallibrary/locallibrary/urls.py",
  &gt; line 20, in &lt;module&gt;
  &gt;     url(r'^admin/', admin.site.urls),  NameError: name 'url' is not defined
  </code></pre>
  
  <p>I have rechecked my code and even copy_pasted it according to the tutorial specifications - but as a beginner (also in Python) i do struggle to understand what is going on.</p>
  
  <p>Link to tutorial page:
  <a href="https://developer.mozilla.org/en-US/docs/Learn/Server-side/Django/skeleton_website" rel="nofollow noreferrer">Link to second part of Django Tutorial</a></p>
  
  <p>Other information: virtual environment is active (activated via "source activate"); Python3.5 is in virtual environment. Fist part of tutoriual (setup of virtual env and python and installment of django via pip3 was successful). I am on mint linux.</p>
  
  <p>Thank you all for your help!</p>
  
  <p>Sebastian</p>