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

Function zap_clear_auth

webapp_modern.py:18246–18271  ·  view source on GitHub ↗

Clear all ZAP authentication configurations

()

Source from the content-addressed store, hash-verified

18244 devices = session.get_zigbee_devices()
18245 return jsonify({'devices': devices, 'total': len(devices)})
18246 except Exception as e:
18247 return jsonify({'error': str(e)}), 500
18248
18249
18250@app.route('/api/wardriving/backfill_gps', methods=['POST'])
18251def wardriving_backfill_gps():
18252 """Backfill missing GPS positions on networks / BT / cell rows from the
18253 session's gps_track table by interpolating each row's first_seen
18254 timestamp. Covers brief GPS dropouts and the warm-up window before TTFF.
18255
18256 Gated behind the `wardriving_allow_backfill` config flag (off by default)."""
18257 try:
18258 if not shared_data.config.get('wardriving_allow_backfill', False):
18259 return jsonify({
18260 'error': 'GPS backfill is disabled. Enable it in Config → Wardriving.'
18261 }), 403
18262 engine = _get_wardriving_engine()
18263 body = request.get_json(silent=True) or {}
18264 session_id = request.args.get('session_id') or body.get('session_id')
18265
18266 if session_id and (not engine.session or engine.session.session_id != session_id):
18267 from wardriving import WardrivingSession
18268 session = WardrivingSession(engine.data_dir, session_id=session_id)
18269 elif engine.session:
18270 session = engine.session
18271 else:
18272 return jsonify({'error': 'No session selected'}), 400
18273
18274 result = session.backfill_gps_from_track()

Callers

nothing calls this directly

Calls 3

zap_clear_authMethod · 0.80
errorMethod · 0.80

Tested by

no test coverage detected