Revise Typing - #3798
Conversation
Added type checks and categorized variables into mutable and immutable lists.
Add variable type checks and sorting by mutability
mateacademy-ai-mentor
left a comment
There was a problem hiding this comment.
Review Summary
Your solution is approved. The implementation meets the task requirements: the sorted_variables dictionary uses the exact keys "mutable" and "immutable", and all eight variables are correctly classified by mutability (lists, dicts, sets as mutable; int, float, bool, str, tuple as immutable). Functionality appears correct and complete.
Minor note for cleanup: the linter reports a style issue at app/main.py:29 with E501 (line too long, 91 > 79). While this doesn’t affect correctness, please wrap or split that line to ≤79 characters. For example, break long strings with implicit concatenation or split long function calls across lines inside parentheses. This will ensure CI passes cleanly.
Nice work—clear, accurate, and aligned with the requirements!
✨ Please rate this review in the Platform's notification center1. I will be grateful for your feedback! ✨
Important
Fix the issues, commit the changes, and then re-request my review using the Re-request review button2 in the Reviewers tab.
Tip
If you have any comments about this review, please leave a message in the Add a comment section below and mention me with the @mateacademy-ai-mentor tag3.
I will read your message during my next review of your pull request. Please do not reply directly to my comments, as that feature is not supported yet.
Caution
Do not close the pull request until the review is complete. Closing it early can lead to unexpected behavior and disrupt the review process.
Footnotes
Format lists of mutable and immutable variables
mateacademy-ai-mentor
left a comment
There was a problem hiding this comment.
Review Summary
Your solution correctly implements the required functionality: the sorted_variables dictionary contains the exact keys "mutable" and "immutable", and all eight variables are classified according to Python mutability. Functionally, everything appears accurate and complete for the task.
There are minor style issues flagged by flake8 that block CI, but they are not functional problems. Specifically, remove trailing whitespace at: app/main.py:29:24, 30:11, 34:18, 35:8, 36:27, and 37:10. Cleaning these up will let the checks pass; you can configure your editor to trim trailing spaces on save or run a quick command to strip them.
Overall, nice work meeting the requirements. Address the whitespace to get CI green and you’ll be good to go.
✨ Please rate this review in the Platform's notification center1. I will be grateful for your feedback! ✨
Important
Fix the issues, commit the changes, and then re-request my review using the Re-request review button2 in the Reviewers tab.
Tip
If you have any comments about this review, please leave a message in the Add a comment section below and mention me with the @mateacademy-ai-mentor tag3.
I will read your message during my next review of your pull request. Please do not reply directly to my comments, as that feature is not supported yet.
Caution
Do not close the pull request until the review is complete. Closing it early can lead to unexpected behavior and disrupt the review process.
Footnotes
Fix formatting of variable lists in main.py
mateacademy-ai-mentor
left a comment
There was a problem hiding this comment.
Review Summary
Your solution is approved. You correctly organized all eight variables into sorted_variables with the exact keys "mutable" and "immutable", and accurately classified types according to Python’s mutability rules. This meets the task requirements cleanly and clearly.
What you did well:
- Clear separation of mutable types (list, dict, set) and immutable types (int, float, bool, string, tuple)
- Correct key names and complete coverage of all variables
Nice work—concise, correct, and easy to read. Keep it up!
✨ Please rate this review in the Platform's notification center1. I will be grateful for your feedback! ✨
No description provided.