After designing with the designer among anaconda, I saved the ui file in the lib folder and ran it on main.py, and it says there is no module. Why is that?
# -*- coding: utf-8 -*-
from PyQt5.QtCore import pyqtSlot, pyqtSignal, QUrl
from lib.extractWordLayout import Ui_MainWindow
from PyQt5.QtWidgets import *
from PyQt5 import QtCore
from bs4 import BeautifulSoup
import urllib.request as request
import urllib.error as err
import urllib.parse as parse
import datetime
import codecs
import time
import sys
import io
import os
Create a _init__.py
file in the lib directory
The _init__.py
file must exist to recognize it as a package.
It doesn't matter if it's a blank (empty) file.
© 2024 OneMinuteCode. All rights reserved.