Quando rodo o runserver, aparece o erro django.core.exceptions.ImproperlyConfigured: The included URLconf 'cedimfinanceiro'projeto.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.
Já pesquisei e tentei várias coisas que encontrei, mas nada está funcionando. Se alguém puder ajudar agradeço.
Traceback completo:
Exception in thread django-main-thread: Traceback (most recent call last): File "/home/ringa/anaconda3/envs/cedim-financeiro/lib/python3.5/site-packages/django/urls/resolvers.py", line 581, 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 "/home/ringa/anaconda3/envs/cedim-financeiro/lib/python3.5/threading.py", line 914, in _bootstrap_inner self.run() File "/home/ringa/anaconda3/envs/cedim-financeiro/lib/python3.5/threading.py", line 862, in run self._target(*self._args, **self._kwargs) File "/home/ringa/anaconda3/envs/cedim-financeiro/lib/python3.5/site-packages/django/utils/autoreload.py", line 54, in wrapper fn(*args, **kwargs) File "/home/ringa/anaconda3/envs/cedim-financeiro/lib/python3.5/site-packages/django/core/management/commands/runserver.py", line 117, in inner_run self.check(display_num_errors=True) File "/home/ringa/anaconda3/envs/cedim-financeiro/lib/python3.5/site-packages/django/core/management/base.py", line 390, in check include_deployment_checks=include_deployment_checks, File "/home/ringa/anaconda3/envs/cedim-financeiro/lib/python3.5/site-packages/django/core/management/base.py", line 377, in _run_checks return checks.run_checks(**kwargs) File "/home/ringa/anaconda3/envs/cedim-financeiro/lib/python3.5/site-packages/django/core/checks/registry.py", line 72, in run_checks new_errors = check(app_configs=app_configs) File "/home/ringa/anaconda3/envs/cedim-financeiro/lib/python3.5/site-packages/django/core/checks/urls.py", line 13, in check_url_config return check_resolver(resolver) File "/home/ringa/anaconda3/envs/cedim-financeiro/lib/python3.5/site-packages/django/core/checks/urls.py", line 23, in check_resolver return check_method() File "/home/ringa/anaconda3/envs/cedim-financeiro/lib/python3.5/site-packages/django/urls/resolvers.py", line 398, in check for pattern in self.url_patterns: File "/home/ringa/anaconda3/envs/cedim-financeiro/lib/python3.5/site-packages/django/utils/functional.py", line 80, in get res = instance.dict[self.name] = self.func(instance) File "/home/ringa/anaconda3/envs/cedim-financeiro/lib/python3.5/site-packages/django/urls/resolvers.py", line 588, in url_patterns raise ImproperlyConfigured(msg.format(name=self.urlconf_name)) django.core.exceptions.ImproperlyConfigured: The included URLconf 'cedimfinanceiro.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.
from django.db import models
class Expense(models.Model):
TYPE = (
('Type1', 'Type1'),
('Type2', 'Type2'),
('Type3', 'Type3'),
('Outros', 'Outros') #abre um campo para digitar
)
type = models.CharField(max_length=10, choices=TYPE, null=True, blank=True) #foreign key do cedimtech
value = models.FloatField(null=True, blank=True)
num_installments = models.IntegerField(null=True, blank=True) #parcelas
day_installments = models.IntegerField(null=True, blank=True) #dia de pagamento de cada parcela