-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
'Solution' #1751
base: master
Are you sure you want to change the base?
'Solution' #1751
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your hard work on this project! 😊 While your code meets most of the task requirements, there are a few critical issues that need to be addressed before we can approve the pull request:
-
Incorrect Class Definition in
bar.py
: TheCustomer
class should only be defined incustomer.py
within thepeople
package. Please remove the unnecessary definition inbar.py
. -
Static Method Return Type in
bar.py
: Thesell_product
method should not return astr
. It should only print the message as per the task requirements. -
Unnecessary Import in
hall.py
: The import statementimport app.people.cinema_staff
is redundant and can be removed. -
Missing Type Hint for
customers
inmain.py
: Please provide a more specific type hint for thecustomers
parameter, indicating it is a list of dictionaries.
These changes are essential to ensure the code fully complies with the task requirements. Once these are addressed, we can proceed with approval. Keep up the great work, and I look forward to your updated submission! 🚀
✨ Please rate this review in the Platform's notification center. I will be grateful for your feedback! ✨
🔄 Fix the issues, commit the changes, and then re-request my review using the Re-request review
button in the Reviewers tab.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great job on addressing most of the issues from the previous review! 🎉 Your code is almost there, with just a few minor adjustments needed:
-
Type Hint in
main.py
: Thecustomers
parameter in thecinema_visit
function should have a more specific type hint. Consider usinglist[dict]
orlist[dict[str, Any]]
to clearly indicate it is a list of dictionaries. -
Unnecessary Return Type Hint in
main.py
: The return type hint-> Any
is unnecessary since the function does not return any value. You can remove this type hint. -
Unnecessary Import in
hall.py
: The import statementfrom app.people.cinema_staff import Cleaner
is not needed and can be removed. -
Return Type Hint in
bar.py
: Thesell_product
method should not have a return type hint-> Any
. It should only print a message, as per the task requirements.
These changes will help improve the clarity and correctness of your code. Keep up the good work, and make sure to address these points in future revisions to enhance your coding skills! 🚀
✨ Please rate this review in the Platform's notification center. I will be grateful for your feedback! ✨
|
||
class CinemaBar: | ||
@staticmethod | ||
def sell_product(customer: Customer, product: str) -> Any: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The sell_product
method should not have a return type hint -> Any
. According to the task requirements, this method should only print a message and not return any value. Please remove the return type hint.
@@ -0,0 +1,18 @@ | |||
from __future__ import annotations | |||
from app.people.cinema_staff import Cleaner |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The import statement from app.people.cinema_staff import Cleaner
is unnecessary and can be removed. The task requirements do not specify the need for this import.
def cinema_visit(customers: list, hall_number: int, cleaner: str, movie: str): | ||
# write you code here | ||
pass | ||
def cinema_visit(customers: list, hall_number: int, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The customers
parameter should have a more specific type hint indicating it is a list of dictionaries. Consider using list[dict]
or list[dict[str, Any]]
for clarity.
# write you code here | ||
pass | ||
def cinema_visit(customers: list, hall_number: int, | ||
cleaner: str, movie: str) -> Any: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The return type hint -> Any
is unnecessary because the function does not return any value. You can remove this type hint.
No description provided.