This commit is contained in:
dgtlmoon
2025-11-24 16:42:08 +01:00
parent b2f2c0c50d
commit c8ece47d27

View File

@@ -267,14 +267,17 @@ def get_fetcher_capabilities(watch, datastore):
} }
# Try to get from plugin-provided fetchers # Try to get from plugin-provided fetchers
fetchers = collect_content_fetchers() # Query all plugins for registered fetchers
for name, fetcher_class in fetchers: plugin_fetchers = plugin_manager.hook.register_content_fetcher()
if name == fetcher_name: for fetcher_registration in plugin_fetchers:
return { if fetcher_registration:
'supports_browser_steps': getattr(fetcher_class, 'supports_browser_steps', False), name, fetcher_class = fetcher_registration
'supports_screenshots': getattr(fetcher_class, 'supports_screenshots', False), if name == fetcher_name:
'supports_xpath_element_data': getattr(fetcher_class, 'supports_xpath_element_data', False) return {
} 'supports_browser_steps': getattr(fetcher_class, 'supports_browser_steps', False),
'supports_screenshots': getattr(fetcher_class, 'supports_screenshots', False),
'supports_xpath_element_data': getattr(fetcher_class, 'supports_xpath_element_data', False)
}
# Default: no capabilities # Default: no capabilities
return { return {