# Debugging

To debug Javascript, set webview.start(debug=True)

import webview

webview.create_window('Woah dude!', 'https://pywebview.flowrl.com/hello')

This will enable web inspector on macOS, GTK and QT (QTWebEngine only). To open the web inspector on macOS, right click on the page and select Inspect. To disable auto-opening of DevTools, set webview.settings['OPEN_DEVTOOLS_IN_DEBUG'] = False before invoking webview.start().

Debugging Python code on Android is not possible apart from printing message to logcat. Use adb -s <DEVICE_ID> logcat | grep python for displaying log messages related to Python. Frontend code can be debugged with WebView remote debugging. Refer to this guide (opens new window) for details.

There is no way to attach an external debugger to MSHTML. The debug flag enables Javascript error reporting and right-click context menu.