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 #1428

Closed
wants to merge 1 commit into from
Closed

Solution #1428

wants to merge 1 commit into from

Conversation

Vladlubeka
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 code is mostly on the right track, there are a few critical issues that need to be addressed before we can approve it:

  1. Critical Issue with remove_dead Method: The test_when_health_less_than_zero function does not ensure that the remove_dead method is called correctly. This is crucial for the functionality of removing dead animals from the Animal.alive list. Please verify and adjust the logic in the bite method of the Carnivore class to ensure it aligns with the expected behavior.

  2. Type Annotations: Adding type annotations will greatly improve the clarity of your code. This is a requirement that needs to be fulfilled.

  3. Magic Method for Printing: Implement the feature that allows Animal.alive to be printed in the specified format. This is part of the task requirements.

Once these issues are resolved, your code will be in great shape! Keep up the good work, and don't hesitate to reach out if you need any help. 🌟

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

Comment on lines +22 to +24
lion.bite(rabbit)
assert rabbit.health == 0, "Здоровье кролика должно быть 0 после укуса"
assert rabbit not in Animal.alive, "Мёртвые животные не должны быть в 'Animal.alive'"

Choose a reason for hiding this comment

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

Ensure that the remove_dead method is correctly called within the bite method of the Carnivore class. If the test fails, it might be due to the remove_dead method not being triggered correctly. Verify that the bite method logic aligns with the expected behavior of removing dead animals from the Animal.alive list.

@Vladlubeka Vladlubeka closed this by deleting the head repository Dec 11, 2024
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