MCPcopy
hub / github.com/pyload/pyload / system_check

Method system_check

module/setup.py:184–261  ·  view source on GitHub ↗

make a systemcheck and return the results

(self)

Source from the content-addressed store, hash-verified

182 return True
183
184 def system_check(self):
185 """ make a systemcheck and return the results"""
186 print _("## System Check ##")
187
188 if sys.version_info[:2] > (2, 7):
189 print _("Your python version is too new, Please use Python 2.6/2.7")
190 python = False
191 elif sys.version_info[:2] < (2, 5):
192 print _("Your python version is too old, Please use at least Python 2.5")
193 python = False
194 else:
195 print _("Python Version: OK")
196 python = True
197
198 curl = self.check_module("pycurl")
199 self.print_dep("pycurl", curl)
200
201 sqlite = self.check_module("sqlite3")
202 self.print_dep("sqlite3", sqlite)
203
204 basic = python and curl and sqlite
205
206 print ""
207
208 crypto = self.check_module("Crypto")
209 self.print_dep("pycrypto", crypto)
210
211 ssl = self.check_module("OpenSSL")
212 self.print_dep("py-OpenSSL", ssl)
213
214 print ""
215
216 pil = self.check_module("Image") or self.check_module("PIL")
217 self.print_dep("py-imaging", pil)
218
219 if os.name == "nt":
220 tesser = self.check_prog([os.path.join(pypath, "tesseract", "tesseract.exe"), "-v"])
221 else:
222 tesser = self.check_prog(["tesseract", "-v"])
223
224 self.print_dep("tesseract", tesser)
225
226 captcha = pil and tesser
227
228 print ""
229
230 gui = self.check_module("PyQt4")
231 self.print_dep("PyQt4", gui)
232
233 print ""
234 jinja = True
235
236 try:
237 import jinja2
238
239 v = jinja2.__version__
240 if v and "unknown" not in v:
241 if not v.startswith("2.5") and not v.startswith("2.6"):

Callers 1

startMethod · 0.95

Calls 5

check_moduleMethod · 0.95
print_depMethod · 0.95
check_progMethod · 0.95
joinMethod · 0.80
_Function · 0.50

Tested by

no test coverage detected