How to tell what methods are available in a installed module

How to tell what methods are available in a installed module

If I do a&nbsp;<code>print(dir(pychromecast))</code>&nbsp;at a Python prompt, I get the list at the bottom of this message. Which of the methods are supposed to work? Because some do, like&nbsp;<code>pychromecast.get_device_status()</code>&nbsp;But others like&nbsp;<code>_get_chromecast_from_host</code>&nbsp;or&nbsp;<code>get_chromecasts</code>throw an attribute error like:

If I do a print(dir(pychromecast)) at a Python prompt, I get the list at the bottom of this message. Which of the methods are supposed to work? Because some do, like pychromecast.get_device_status() But others like _get_chromecast_from_host or get_chromecaststhrow an attribute error like:

AttributeError: module 'pychromecast' has no attribute 'get_chromehosts'

Is it that I am doing/understanding something fundamentally wrong? Does the _ before the name play into it?

As promised, here is the output of dir:

['APP_BACKDROP', 'APP_DASHCAST', 'APP_MEDIA_RECEIVER', 'APP_PLEX',
 'APP_SPOTIFY', 'APP_YOUTUBE', 'CAST_TYPES', 'CAST_TYPE_CHROMECAST',
 'Chromecast', 'ChromecastConnectionError', 'ControllerNotRegistered',
 'DeviceStatus', 'IDLE_APP_ID', 'IGNORE_CEC', 'LaunchError',
 'MultipleChromecastsFoundError', 'NoChromecastFoundError', 'NotConnected',
 'PyChromecastError', 'PyChromecastStopped', 'STREAM_TYPE_BUFFERED', 
 'UnsupportedNamespace', '_LOGGER', '__all__', '__builtins__', '__cached__',
 '__doc__', '__file__', '__loader__', '__name__', '__package__', 
 '__path__', '__spec__', '__version__', '__version_info__', 
 '_get_chromecast_from_host', '_get_chromecast_from_service', 
 'cast_channel_pb2', 'config', 'controllers', 'dial', 
 'discover_chromecasts', 'discovery', 'error', 'fnmatch', 'get_app_config', 
 'get_chromecasts', 'get_device_status', 'get_possible_app_ids', 'json', 
 'logging', 'reboot', 'requests', 'socket_client', 'start_discovery',
 'stop_discovery', 'threading']


Angular 9 Tutorial: Learn to Build a CRUD Angular App Quickly

What's new in Bootstrap 5 and when Bootstrap 5 release date?

Brave, Chrome, Firefox, Opera or Edge: Which is Better and Faster?

How to Build Progressive Web Apps (PWA) using Angular 9

What is new features in Javascript ES2020 ECMAScript 2020

Top Python Development Companies | Hire Python Developers

After analyzing clients and market requirements, TopDevelopers has come up with the list of the best Python service providers. These top-rated Python developers are widely appreciated for their professionalism in handling diverse projects. When...

Python GUI Programming Projects using Tkinter and Python 3

Python GUI Programming Projects using Tkinter and Python 3

Guide to Python Programming Language

Guide to Python Programming Language