MCPcopy Create free account
hub / github.com/PierreGode/Ragnar / _toggle_scan_interface

Function _toggle_scan_interface

webapp_modern.py:11250–11269  ·  view source on GitHub ↗
(enable: bool)

Source from the content-addressed store, hash-verified

11248 _kiosk_install_and_start()
11249 except subprocess.TimeoutExpired:
11250 logger.error("[kiosk] repair timed out")
11251 _kiosk_task_set(phase='failed', error='Kiosk repair timed out.')
11252 except Exception as exc:
11253 logger.error(f"[kiosk] repair error: {exc}")
11254 _kiosk_task_set(phase='failed', error=str(exc))
11255 finally:
11256 with _kiosk_task_lock:
11257 _kiosk_task['busy'] = False
11258
11259 # Remember the intent, so a reboot mid-repair still comes up with the kiosk.
11260 if not shared_data.config.get('kiosk_enabled'):
11261 shared_data.config['kiosk_enabled'] = True
11262 try:
11263 shared_data.save_config()
11264 except Exception as exc:
11265 logger.warning(f"[kiosk] could not persist kiosk_enabled during repair: {exc}")
11266
11267 threading.Thread(target=worker, daemon=True).start()
11268 return jsonify({'success': True, 'message': 'Reinstalling and starting the kiosk…'})
11269
11270
11271@app.route('/api/kiosk/diagnose', methods=['POST'])
11272def kiosk_diagnose():

Callers 2

enable_wifi_scan_controlFunction · 0.85

Calls 7

is_multi_mode_enabledMethod · 0.80
update_scan_modeMethod · 0.80
warningMethod · 0.80
set_scan_enabledMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected