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

'solution' #1614

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

'solution' #1614

wants to merge 3 commits into from

Conversation

pr-ruslan
Copy link

No description provided.

Copy link

@mateacademy-ai-mentor mateacademy-ai-mentor left a 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 Pull Request! 😊 While your implementation is mostly correct and aligns with the task requirements, there are a couple of critical issues that need to be addressed before we can approve it:

  1. Static Method Usage: The sell_product method of the CinemaBar class should be used as a static method. Currently, it seems like there might be confusion in how it's being called. Please ensure that you are not creating an instance of CinemaBar to call this method, as per the task description.

  2. Variable Overwriting: The cleaner parameter is being overwritten by a Cleaner instance on line 14. This can lead to confusion and potential errors. It's important to use a different variable name for the Cleaner instance to maintain clarity and avoid overwriting the parameter.

Once these issues are resolved, your code should work as expected. Keep up the great work, and I look forward to seeing the updated version! 🚀

✨ 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.

pass
def cinema_visit(customers: list,
hall_number: int,
cleaner: str,

Choose a reason for hiding this comment

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

The cleaner parameter is being overwritten by a Cleaner instance on line 14. Consider using a different variable name for the Cleaner instance to avoid confusion and potential errors.

cleaner = Cleaner(cleaner)

for customer in customer_list:
CinemaBar.sell_product(customer.food, customer)

Choose a reason for hiding this comment

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

Ensure that the sell_product method of CinemaBar is used correctly as a static method. According to the task description, you should not create an instance of CinemaBar to call this method.

Copy link

@mateacademy-ai-mentor mateacademy-ai-mentor left a comment

Choose a reason for hiding this comment

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

Review Summary

Great job on your implementation! 🎉 Your code meets the task requirements and constraints, and the overall structure is well-aligned with the task description. Here are some key points and suggestions for improvement:

  1. Static Method Usage: The sell_product method in the CinemaBar class is correctly implemented and used as a static method. Ensure this usage is consistent throughout your codebase to adhere to the task requirements.

  2. Variable Overwriting: There is a critical issue with variable overwriting in the CinemaHall class. Make sure to address this to prevent potential bugs. Additionally, in the cinema_visit function, avoid using the cleaning_staff parameter as a Cleaner instance. Instead, use a different variable name to maintain clarity and avoid confusion.

  3. Class Implementations: The Cleaner and Customer class implementations are correct and require no changes. Keep up the good work!

Your code is approved to help you move forward with your learning journey. However, please review the comments and address the critical issues mentioned to improve your code quality and avoid similar problems in the future. Keep learning and refining your skills! 🚀

✨ Please rate this review in the Platform's notification center. I will be grateful for your feedback! ✨

def movie_session(self,
movie_name: str,
customers: list,
cleaning_staff: Cleaner

Choose a reason for hiding this comment

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

The cleaning_staff parameter is being used as a Cleaner instance. This can lead to confusion and potential errors. It's important to use a different variable name for the Cleaner instance to maintain clarity and avoid overwriting the parameter. Consider renaming the parameter to something like cleaner to avoid this issue.

cleaner_person = Cleaner(cleaner)

for customer in customer_list:
CinemaBar.sell_product(customer.food, customer)

Choose a reason for hiding this comment

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

The sell_product method of the CinemaBar class is correctly used as a static method here. Ensure that this usage is consistent throughout your codebase, as per the task requirements.

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.

2 participants