martomi / chiadog

A watch dog providing a peace in mind that your Chia farm is running smoothly 24/7.
MIT License
457 stars 120 forks source link

ImportError: attempted relative import beyond top-level package - Windows 10 #247

Closed HououinKyouma01 closed 3 years ago

HououinKyouma01 commented 3 years ago

Describe the bug

(venv) PS C:\Users\Farma\chiadog> .\start.cmd
Traceback (most recent call last):
  File "C:\Users\Farma\chiadog\main.py", line 12, in <module>
    from src.chia_log.handlers.daily_stats.stats_manager import StatsManager
  File "C:\Users\Farma\chiadog\src\__init__.py", line 5, in <module>
    from ...parsers.finished_signage_point_parser import FinishedSignagePointMessage
ImportError: attempted relative import beyond top-level package
(venv) PS C:\Users\Farma\chiadog>

Tried without venv too. All requirements installed. Config checked few times. Tried starting with python.exe main.py --config 'C:\Users\Farma\chiadog\config.yaml' python.exe main.py --config config.yaml

Same error. Environment:

pieterhelsen commented 3 years ago

Try a full reinstall of git repo? It's trying to go up three folders from src/__init__.py which is not possible. It seems your install got corrupted somehow.

martomi commented 3 years ago

Agree with @pieterhelsen's suggestion. Closing for inactivity.