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

Update sentiment.py #10

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

shreyaa2904
Copy link

Error Handling for File Operations:

Added a try-except block around the CSV file reading section to catch FileNotFoundError. This provides a clear error message if the file is not found, guiding the user to check the path. Included a general exception handler to catch any other errors that might occur during the file reading process.

Updated the usage message in the main() function to inform users about the expected command-line arguments, including the path to the CSV file.

These changes enhance the overall user experience and make the code more resilient against common file-related issue

Error Handling for File Operations:

Added a try-except block around the CSV file reading section to catch FileNotFoundError. This provides a clear error message if the file is not found, guiding the user to check the path.
Included a general exception handler to catch any other errors that might occur during the file reading process.
Usage Information:

Updated the usage message in the main() function to inform users about the expected command-line arguments, including the path to the CSV file.

These changes enhance the overall user experience and make the code more resilient against common file-related issue
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.

1 participant