(Feb-05-2018, 04:45 AM)micseydel Wrote: No, I'm saying you haven't provided enough information for us to identify the problem, let alone provide any solution. I can't run the code you provided and get the error you describe.
Let me list the whole code out
Unhandled exception in thread started by <function check_errors.<locals>.wrapper at 0x0000000003B4A7B8>
Traceback (most recent call last):
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\urls\resolvers.py", line 538, in url_patterns
iter(patterns)
TypeError: 'module' object is not iterable
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\utils\autoreload.py", line 225, in wrapper
fn(*args, **kwargs)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\management\commands\runserver.py", line 121, in inner_run
self.check(display_num_errors=True)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\management\base.py", line 364, in check
include_deployment_checks=include_deployment_checks,
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\management\base.py", line 351, in _run_checks
return checks.run_checks(**kwargs)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\checks\registry.py", line 73, in run_checks
new_errors = check(app_configs=app_configs)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\checks\urls.py", line 40, in check_url_namespaces_unique
all_namespaces = _load_all_namespaces(resolver)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\checks\urls.py", line 57, in _load_all_namespaces
url_patterns = getattr(resolver, 'url_patterns', [])
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\utils\functional.py", line 36, in __get__
res = instance.__dict__[self.name] = self.func(instance)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\urls\resolvers.py", line 545, in url_patterns
raise ImproperlyConfigured(msg.format(name=self.urlconf_name))
django.core.exceptions.ImproperlyConfigured: The included URLconf 'ProjectSubmission2.urls' does not appear to have any patterns in it. If you see valid patterns in the file then the issue is probably caused by a circular import.
Performing system checks...
Unhandled exception in thread started by <function check_errors.<locals>.wrapper at 0x0000000003B4A7B8>
Traceback (most recent call last):
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\utils\autoreload.py", line 225, in wrapper
fn(*args, **kwargs)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\management\commands\runserver.py", line 121, in inner_run
self.check(display_num_errors=True)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\management\base.py", line 364, in check
include_deployment_checks=include_deployment_checks,
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\management\base.py", line 351, in _run_checks
return checks.run_checks(**kwargs)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\checks\registry.py", line 73, in run_checks
new_errors = check(app_configs=app_configs)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\checks\urls.py", line 40, in check_url_namespaces_unique
all_namespaces = _load_all_namespaces(resolver)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\checks\urls.py", line 57, in _load_all_namespaces
url_patterns = getattr(resolver, 'url_patterns', [])
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\utils\functional.py", line 36, in __get__
res = instance.__dict__[self.name] = self.func(instance)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\urls\resolvers.py", line 536, in url_patterns
patterns = getattr(self.urlconf_module, "urlpatterns", self.urlconf_module)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\utils\functional.py", line 36, in __get__
res = instance.__dict__[self.name] = self.func(instance)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\urls\resolvers.py", line 529, in urlconf_module
return import_module(self.urlconf_name)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\importlib\__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 978, in _gcd_import
File "<frozen importlib._bootstrap>", line 961, in _find_and_load
File "<frozen importlib._bootstrap>", line 950, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 655, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 674, in exec_module
File "<frozen importlib._bootstrap_external>", line 781, in get_code
File "<frozen importlib._bootstrap_external>", line 741, in source_to_code
File "<frozen importlib._bootstrap>", line 205, in _call_with_frames_removed
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\ProjectSubmission2\urls.py", line 17
^
SyntaxError: EOF while scanning triple-quoted string literal
Performing system checks...
Unhandled exception in thread started by <function check_errors.<locals>.wrapper at 0x0000000003B4A7B8>
Traceback (most recent call last):
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\utils\autoreload.py", line 225, in wrapper
fn(*args, **kwargs)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\management\commands\runserver.py", line 121, in inner_run
self.check(display_num_errors=True)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\management\base.py", line 364, in check
include_deployment_checks=include_deployment_checks,
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\management\base.py", line 351, in _run_checks
return checks.run_checks(**kwargs)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\checks\registry.py", line 73, in run_checks
new_errors = check(app_configs=app_configs)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\checks\urls.py", line 40, in check_url_namespaces_unique
all_namespaces = _load_all_namespaces(resolver)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\core\checks\urls.py", line 57, in _load_all_namespaces
url_patterns = getattr(resolver, 'url_patterns', [])
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\utils\functional.py", line 36, in __get__
res = instance.__dict__[self.name] = self.func(instance)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\urls\resolvers.py", line 536, in url_patterns
patterns = getattr(self.urlconf_module, "urlpatterns", self.urlconf_module)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\utils\functional.py", line 36, in __get__
res = instance.__dict__[self.name] = self.func(instance)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\site-packages\django\urls\resolvers.py", line 529, in urlconf_module
return import_module(self.urlconf_name)
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\venv\lib\importlib\__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 978, in _gcd_import
File "<frozen importlib._bootstrap>", line 961, in _find_and_load
File "<frozen importlib._bootstrap>", line 950, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 655, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 674, in exec_module
File "<frozen importlib._bootstrap_external>", line 781, in get_code
File "<frozen importlib._bootstrap_external>", line 741, in source_to_code
File "<frozen importlib._bootstrap>", line 205, in _call_with_frames_removed
File "D:\stuff\Poly stuff\WP\ProjectSubmission2\ProjectSubmission2\urls.py", line 17
^
SyntaxError: EOF while scanning triple-quoted string literal
This is what came out after I ran the program.
urlpatterns = [
url(r'^admin/', admin.site.urls),
url('books/', include('library.urls')),
]
The code above also stated that I am missing closing triple quotes but the thing is I didnt use any in my coding.