title: ModuleNotFoundError: Trying to import model from models folder into a view in views folder
body: <p>I am new to the Django framework and I have some questions regarding importing of modules. Below is my file structure:</p>
  
  <pre><code>MyLife
  - MyLife
    - finance
      - models
        - __init__.py
        - category.py
      - views
        - __init__.py
        - category.py
  </code></pre>
  
  <p>I am trying to import the models.category into my views.category.</p>
  
  <p><code>models.__init__.py</code>:</p>
  
  <pre><code>from .base_model import BaseModel
  from .category import Category
  from .client import Client
  from .entry import Entry
  from .rule import Rule
  from .wish_list_item import WishListItem
  
  __all__ = ['BaseModel', 'Category', 'Client', 'Entry', 'Rule', 'WishListItem']
  </code></pre>
  
  <p>views.category.py:</p>
  
  <pre><code>from django.shortcuts import render
  
  from MyLife.finance.models import Category
  
  
  def category(request):
      all_categories = Category.objects.all()
      return render(request, 'finance/category.html', {'list_categories': all_categories})
  </code></pre>
  
  <p>models.category.py:</p>
  
  <pre><code>from django.db import models
  from .base_model import BaseModel
  
  
  class Category(BaseModel):
      description = models.CharField(max_length=50)
  
      def __str__(self):
         return self.description
  </code></pre>
  
  <p>Here is my stack trace error:</p>
  
  <pre><code>  File "/Users/AKJ/Coding/MyLife/MyLife/finance/urls.py", line 3, in &lt;module&gt;
      from . import views
    File "/Users/AKJ/Coding/MyLife/MyLife/finance/views/__init__.py", line 3, in &lt;module&gt;
      from . category import category
    File "/Users/AKJ/Coding/MyLife/MyLife/finance/views/category.py", line 3, in &lt;module&gt;
      from MyLife.finance.models import Category
  ModuleNotFoundError: No module named 'MyLife.finance'
  </code></pre>
  
  <p>I am not sure what is wrong and if i am missing something out. I heard a lot about <strong>init</strong>.py to help reduce the namespace, however, i seem to have problems and i do not really understand the other stackoverflow explanations. </p>
  
  <p>Also, should i rename my models.category into category_model.py and the views.category into category_views.py?</p>
  
  <p>Any help is appreciated! Thank you!</p>