To-Do List App - Bug Report
This document lists the main issues found in the to-do list application. It is written to help track problems and fix them step by step.
1. Invalid Task Number
Description
The program does not handle cases where the user enters a task number that does not exist in the list.
How to Reproduce
- Add a few tasks
- Choose complete or delete task option
- Enter a number that is less than 1 or greater than the number of tasks
Expected Behavior
The program should show a message saying the input is invalid.
Actual Behavior
The program crashes with an index error.
2. Non-Numeric Input
Description
The program crashes when the user enters text instead of a number in menu options or task selection.
How to Reproduce
- Open the program
- Enter something like "abc" instead of a number
Expected Behavior
The program should handle invalid input and ask again.
Actual Behavior
The program throws a ValueError.
3. Empty Task Input
Description
The user can add an empty task.
How to Reproduce
- Select add task option
- Press enter without typing anything
Expected Behavior
The program should not accept empty tasks.
Actual Behavior
An empty task is added to the list.
4. Empty List Handling
Description
Some features do not behave properly when there are no tasks in the list.
How to Reproduce
- Run the program
- Do not add any tasks
- Try viewing, deleting, or completing tasks
Expected Behavior
The program should inform that there are no tasks.
Actual Behavior
Nothing happens or the program behaves unexpectedly.
5. Unsafe List Access
Description
The program directly accesses list elements without checking if the index is valid.
Problem Area
Accessing tasks[user_choice - 1] without validation
Expected Behavior
Index should always be checked before access.
Actual Behavior
The program may crash with index error.
6. Generic Exception Handling
Description
The program uses broad exception handling instead of specific errors.
Problem
Using "except:" without specifying the error type
Expected Behavior
Only expected errors should be caught.
Actual Behavior
All errors are hidden, making debugging harder.
7. Delete and Complete Task Issues
Description
Deleting or completing tasks can crash the program if invalid input is given.
How to Reproduce
Enter invalid task numbers during delete or complete operations
Expected Behavior
The program should handle invalid input safely.
Actual Behavior
The program crashes or behaves incorrectly.
8. No Data Persistence
Description
All tasks are lost when the program closes.
Expected Improvement
Tasks should be saved to a file and loaded when the program starts.
9. Input Confusion
Description
Some prompts are not clear for the user.
Expected Improvement
Prompts should clearly indicate what input is expected.
10. Missing Features
Description
Several useful features are not implemented.
Suggested Features
- Edit task
- Mark all tasks as completed
- Show only completed or pending tasks
- Save and load tasks from file
To-Do List App - Bug Report
This document lists the main issues found in the to-do list application. It is written to help track problems and fix them step by step.
1. Invalid Task Number
Description
The program does not handle cases where the user enters a task number that does not exist in the list.
How to Reproduce
Expected Behavior
The program should show a message saying the input is invalid.
Actual Behavior
The program crashes with an index error.
2. Non-Numeric Input
Description
The program crashes when the user enters text instead of a number in menu options or task selection.
How to Reproduce
Expected Behavior
The program should handle invalid input and ask again.
Actual Behavior
The program throws a ValueError.
3. Empty Task Input
Description
The user can add an empty task.
How to Reproduce
Expected Behavior
The program should not accept empty tasks.
Actual Behavior
An empty task is added to the list.
4. Empty List Handling
Description
Some features do not behave properly when there are no tasks in the list.
How to Reproduce
Expected Behavior
The program should inform that there are no tasks.
Actual Behavior
Nothing happens or the program behaves unexpectedly.
5. Unsafe List Access
Description
The program directly accesses list elements without checking if the index is valid.
Problem Area
Accessing tasks[user_choice - 1] without validation
Expected Behavior
Index should always be checked before access.
Actual Behavior
The program may crash with index error.
6. Generic Exception Handling
Description
The program uses broad exception handling instead of specific errors.
Problem
Using "except:" without specifying the error type
Expected Behavior
Only expected errors should be caught.
Actual Behavior
All errors are hidden, making debugging harder.
7. Delete and Complete Task Issues
Description
Deleting or completing tasks can crash the program if invalid input is given.
How to Reproduce
Enter invalid task numbers during delete or complete operations
Expected Behavior
The program should handle invalid input safely.
Actual Behavior
The program crashes or behaves incorrectly.
8. No Data Persistence
Description
All tasks are lost when the program closes.
Expected Improvement
Tasks should be saved to a file and loaded when the program starts.
9. Input Confusion
Description
Some prompts are not clear for the user.
Expected Improvement
Prompts should clearly indicate what input is expected.
10. Missing Features
Description
Several useful features are not implemented.
Suggested Features