Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix empty episode table in 'tooluse' command #20

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

mentatbot[bot]
Copy link
Contributor

@mentatbot mentatbot bot commented Nov 12, 2024

Resolved issue where the 'tooluse' command displayed an empty table by adding checks for valid RSS feed entries. Improved error handling and user feedback for RSS feed parsing and episode display. Updated README with clearer command descriptions and added new features.

Closes #19

…back

The changes in this commit improve the error handling and user feedback in the RSS feed parsing and playback functionality of the tool. Specifically:

1. The `fetch_rss_feed` function now checks if the feed is in a "bozo" state (i.e., there was an error parsing the feed) and prints a clear error message if that's the case.
2. The `display_episodes` function now checks if the feed has any entries and prints a message if there are none.
3. The `play_mp3` function now provides more detailed debug information if the audio playback fails, including a suggestion to check the RSS feed URL and internet connection.
4. The `main` function now checks if the feed is valid and has entries before proceeding with the main loop, and prints a message if there are no episodes found.

These improvements should help users better understand what went wrong if there are issues with the RSS feed or audio playback, and provide them with more guidance on how to troubleshoot the problem.
@mentatbot mentatbot bot requested a review from MikeBirdTech November 12, 2024 01:33
@MikeBirdTech
Copy link
Collaborator

Can you also allow the user to select contact after they type tooluse so they can do the same as if they ran tooluse contact?

Copy link
Contributor Author

@mentatbot mentatbot bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you also allow the user to select contact after they type tooluse so they can do the same as if they ran tooluse contact?

I understand you want to add the contact functionality as an option when running the tooluse command. I can modify the code to add this feature by creating a menu that lets users choose between RSS feed and contact functionality when they first run the command.

I'll update the code to add a main menu where users can choose between RSS feed and contact functionality. This will make the tooluse command more versatile and consistent with the existing contact feature.

Thanks for using MentatBot. Give comments a 👍 or 👎 to help me improve!

mentatbot bot added 2 commits November 26, 2024 23:07
The commit message should be:

Add contact functionality to Tool Use podcast player

This change adds a new option to the main menu of the Tool Use podcast player, allowing users to contact the podcast creators. The new "Contact Tool Use" option calls the `contact.main()` function, which presumably handles the contact functionality.

Additionally, the code has been refactored to better organize the main loop and handle the different options (podcast, contact, exit) more cleanly.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

When I enter 'tooluse' into the terminal, the table showing the episodes is empty
1 participant