Spaces:
Running
Running
#!/usr/bin/env python3 | |
"""Check AGNO tools submodules""" | |
import pkgutil | |
import agno.tools | |
print("π Checking agno.tools submodules...") | |
try: | |
# Check agno.tools submodules | |
for importer, modname, ispkg in pkgutil.iter_modules(agno.tools.__path__, agno.tools.__name__ + '.'): | |
print(f"π¦ Submodule: {modname}") | |
# Try to import and check contents | |
try: | |
module = __import__(modname, fromlist=['']) | |
contents = [item for item in dir(module) if not item.startswith('_')] | |
if contents: | |
print(f" π Contents: {contents[:5]}...") # Show first 5 items | |
except Exception as e: | |
print(f" β Error importing {modname}: {e}") | |
# Specifically look for YouTube-related tools | |
print("\nπ₯ Looking for YouTube tools...") | |
youtube_modules = [mod for mod in pkgutil.iter_modules(agno.tools.__path__, agno.tools.__name__ + '.') | |
if 'youtube' in mod[1].lower()] | |
if youtube_modules: | |
for importer, modname, ispkg in youtube_modules: | |
print(f"β Found YouTube module: {modname}") | |
try: | |
module = __import__(modname, fromlist=['']) | |
youtube_classes = [item for item in dir(module) if 'youtube' in item.lower() or 'YouTube' in item] | |
print(f" π§ YouTube classes: {youtube_classes}") | |
except Exception as e: | |
print(f" β Error importing {modname}: {e}") | |
else: | |
print("β No YouTube modules found") | |
except Exception as e: | |
print(f"β Error checking agno.tools: {e}") |