22 lines
713 B
Python
22 lines
713 B
Python
#!/usr/bin/env python3
|
|
"""Test script to check if user module imports correctly"""
|
|
import sys
|
|
import os
|
|
|
|
# Add current directory to path
|
|
sys.path.insert(0, os.path.dirname(os.path.abspath(__file__)))
|
|
|
|
try:
|
|
from secnex.app.user import user
|
|
print(f"Type of user: {type(user)}")
|
|
print(f"Has registered_commands: {hasattr(user, 'registered_commands')}")
|
|
if hasattr(user, 'registered_commands'):
|
|
print(f"registered_commands: {user.registered_commands}")
|
|
else:
|
|
print("ERROR: user does not have registered_commands attribute")
|
|
print(f"user attributes: {dir(user)}")
|
|
except Exception as e:
|
|
print(f"Error importing user: {e}")
|
|
import traceback
|
|
traceback.print_exc()
|