main loop, which executes commands
(self)
| 126 | self.setuplock.wait() |
| 127 | |
| 128 | def run(self): |
| 129 | """main loop, which executes commands""" |
| 130 | convert = self._checkVersion() #returns None or current version |
| 131 | |
| 132 | self.conn = sqlite3.connect("files.db") |
| 133 | chmod("files.db", 0600) |
| 134 | |
| 135 | self.c = self.conn.cursor() #compatibility |
| 136 | |
| 137 | if convert is not None: |
| 138 | self._convertDB(convert) |
| 139 | |
| 140 | self._createTables() |
| 141 | self._migrateUser() |
| 142 | |
| 143 | self.conn.commit() |
| 144 | |
| 145 | self.setuplock.set() |
| 146 | |
| 147 | while True: |
| 148 | j = self.jobs.get() |
| 149 | if j == "quit": |
| 150 | self.c.close() |
| 151 | self.conn.close() |
| 152 | break |
| 153 | j.processJob() |
| 154 | |
| 155 | @style.queue |
| 156 | def shutdown(self): |
nothing calls this directly
no test coverage detected