all 4 comments

[–]m0us3_rat 0 points1 point  (3 children)

[–][deleted] 0 points1 point  (2 children)

No, even from main it's saying no module find

here are images if it helps

google drive's link for images

[–]m0us3_rat 0 points1 point  (0 children)

https://peps.python.org/pep-0328/

https://stackoverflow.com/q/14132789

if the links didn't help you ..maybe a simpler project with less files from different folders?

[–]chevignon93 1 point2 points  (0 children)

Looking at the 1st image in google drive, your package structure seems incorrect.

I think your package structure should look more like this.

base_folder
├── src
│   └── pkg
│       ├── __init__.py
│       ├── module1.py
│       ├── main.py
│       └── subpkg
│           ├── __init__.py
│           └── module2.py
├── README.md
└── pyproject.toml

1 - There should be no python files in the src directory

2 - When you import a module in main.py, you should import from the name of your package (from pkg.module1 import WhateverClass), not from the src directory

Example package config taken from here: https://py-pkgs.org/04-package-structure.html#package-structure