def check_new_version(): need_upgrade = False try: if upgrader.require_upgrade(): need_upgrade = True except: pass return jsonify(require_upgrade=need_upgrade, current_version=upgrader.get_current_version(), last_stable_version=upgrader.get_stable_version())
def check_new_version(): need_upgrade = False try: if upgrader.require_upgrade(): need_upgrade = True except: pass return jsonify( require_upgrade=need_upgrade, current_version=upgrader.get_current_version(), last_stable_version=upgrader.get_stable_version() )
def current_version(): return upgrader.get_current_version()
def test_version(self): self.assertEqual(get_current_version(), qpanel.__version__) self.assertNotEqual(get_current_version(), '0.11.0')
def test_version(self): version = '0.10' self.assertEqual(get_current_version(), qpanel.__version__) self.assertNotEqual(get_current_version(), '0.11.0')
def current_version(): return upgrader.get_current_version()