diff options
-rw-r--r-- | README.md | 2 | ||||
-rwxr-xr-x | kcc-c2e.py | 2 | ||||
-rwxr-xr-x | kcc.py | 2 | ||||
-rw-r--r-- | kcc/KCC_gui.py | 4 | ||||
-rw-r--r-- | requirements.txt | 4 |
5 files changed, 5 insertions, 9 deletions
diff --git a/README.md b/README.md index fc258b6..a5ec720 100644 --- a/README.md +++ b/README.md @@ -43,7 +43,7 @@ You can find the latest released binary at the following links: - Python 3.3 - [PyQt5](http://www.riverbankcomputing.co.uk/software/pyqt/download5) - [Pillow](http://pypi.python.org/pypi/Pillow/) 2.3.0+ -- [psutil](https://pypi.python.org/pypi/psutil) +- [psutil](https://pypi.python.org/pypi/psutil) 2.0+ - [python-slugify](http://pypi.python.org/pypi/python-slugify) On Debian based distributions these two commands should install all dependencies: diff --git a/kcc-c2e.py b/kcc-c2e.py index e906c7b..3288560 100755 --- a/kcc-c2e.py +++ b/kcc-c2e.py @@ -32,7 +32,7 @@ if sys.version_info[0] != 3: missing = [] try: # noinspection PyUnresolvedReferences - from psutil import TOTAL_PHYMEM, Popen + from psutil import virtual_memory, Popen except ImportError: missing.append('psutil') try: diff --git a/kcc.py b/kcc.py index e333714..a41d3c5 100755 --- a/kcc.py +++ b/kcc.py @@ -37,7 +37,7 @@ except ImportError: missing.append('PyQt5') try: # noinspection PyUnresolvedReferences - from psutil import TOTAL_PHYMEM, Popen + from psutil import virtual_memory, Popen except ImportError: missing.append('psutil') try: diff --git a/kcc/KCC_gui.py b/kcc/KCC_gui.py index f86b7f6..6c822c6 100644 --- a/kcc/KCC_gui.py +++ b/kcc/KCC_gui.py @@ -36,7 +36,7 @@ from subprocess import STDOUT, PIPE from PyQt5 import QtGui, QtCore, QtWidgets from xml.dom.minidom import parse from html.parser import HTMLParser -from psutil import TOTAL_PHYMEM, Popen +from psutil import virtual_memory, Popen from .shared import md5Checksum from . import comic2ebook from . import kindlesplit @@ -338,7 +338,7 @@ class WorkerThread(QtCore.QThread): self.kindlegenErrorCode = [0] self.workerOutput = [] # Let's make sure that we don't fill the memory - availableMemory = TOTAL_PHYMEM/1000000000 + availableMemory = virtual_memory().total/1000000000 if availableMemory <= 2: self.threadNumber = 1 elif 2 < availableMemory <= 4: diff --git a/requirements.txt b/requirements.txt deleted file mode 100644 index 05d69ff..0000000 --- a/requirements.txt +++ /dev/null @@ -1,4 +0,0 @@ -Pillow==2.3.0 -Unidecode==0.04.14 -psutil==1.2.1 -python-slugify==0.0.7 |