This will get us the program's directory, even if we are frozen using py2exe
()
| 101 | sys.exit("\r[%s] [CRITICAL] %s" % (time.strftime("%X"), errMsg)) |
| 102 | |
| 103 | def modulePath(): |
| 104 | """ |
| 105 | This will get us the program's directory, even if we are frozen |
| 106 | using py2exe |
| 107 | """ |
| 108 | |
| 109 | try: |
| 110 | _ = sys.executable if weAreFrozen() else __file__ |
| 111 | except NameError: |
| 112 | _ = inspect.getsourcefile(modulePath) |
| 113 | |
| 114 | return getUnicode(os.path.dirname(os.path.realpath(_)), encoding=sys.getfilesystemencoding() or UNICODE_ENCODING) |
| 115 | |
| 116 | def checkEnvironment(): |
| 117 | try: |
no test coverage detected
searching dependent graphs…