fix: Debug PluginsView loading and add to UI exports

- Added debug output to diagnose why PluginsView isn't loading
- Added PluginsView and WidgetsView to core/ui/__init__.py exports
- Removed plugin_manager check that was causing fallback
- Will show console output to diagnose the issue
This commit is contained in:
LemonNexus 2026-02-16 00:34:18 +00:00
parent cfdf21ea6d
commit bd23fc5c65
2 changed files with 17 additions and 3 deletions

View File

@ -1002,12 +1002,24 @@ class PerfectMainWindow(QMainWindow):
def _create_plugins_view(self) -> QWidget:
"""Create the Plugins view."""
# Debug info
print(f"[PerfectUX] Creating plugins view...")
print(f"[PerfectUX] PLUGINS_VIEW_AVAILABLE: {PLUGINS_VIEW_AVAILABLE}")
print(f"[PerfectUX] plugin_manager: {self.plugin_manager}")
# Try to use the actual PluginsView if available
if PLUGINS_VIEW_AVAILABLE and self.plugin_manager:
if PLUGINS_VIEW_AVAILABLE:
try:
return PluginsView(self)
print("[PerfectUX] Creating PluginsView...")
view = PluginsView(self)
print("[PerfectUX] PluginsView created successfully!")
return view
except Exception as e:
import traceback
print(f"[PerfectUX] Failed to create PluginsView: {e}")
traceback.print_exc()
else:
print("[PerfectUX] PluginsView not available, using fallback")
# Fallback to placeholder
container = QWidget()

View File

@ -7,5 +7,7 @@ Built-in UI views that are part of the framework.
from .settings_view import SettingsView
from .dashboard_view import DashboardView
from .search_view import UniversalSearchView
from .plugins_view import PluginsView
from .widgets_view import WidgetsView
__all__ = ['SettingsView', 'DashboardView', 'UniversalSearchView']
__all__ = ['SettingsView', 'DashboardView', 'UniversalSearchView', 'PluginsView', 'WidgetsView']