-
Notifications
You must be signed in to change notification settings - Fork 1k
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' #1109
base: master
Are you sure you want to change the base?
'Solution' #1109
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.
Great job on implementing the models and main function! 🎉 While there are a few minor spelling errors and a typo in the initial data, these don't critically impact the functionality of your code. Just keep an eye on those details in the future to make your code even more efficient. Keep up the good work! 😊
✨ Please rate this review in the Platform's notification center. I will be grateful for your feedback! ✨
|
||
|
||
def main() -> QuerySet: | ||
pass | ||
genres = ["Western", "Action", "Dramma"] |
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 genre 'Dramma' seems to be a typo. It is later updated to 'Drama', but it would be better to correct it initially to avoid unnecessary updates.
for genre in genres: | ||
Genre.objects.create(name=genre) | ||
|
||
actors = ["George Klooney", |
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 name 'George Klooney' is misspelled. It should be 'George Clooney'. This is corrected later, but it would be more efficient to use the correct name initially.
Genre.objects.create(name=genre) | ||
|
||
actors = ["George Klooney", | ||
"Kianu Reaves", |
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 name 'Kianu Reaves' is misspelled. It should be 'Keanu Reeves'. This is corrected later, but it would be more efficient to use the correct name initially.
"Jaden Smith", | ||
"Scarlett Johansson"] | ||
for actor in actors: | ||
first_name, last_name = actor.split() |
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.
Ensure that all actor names in the list have exactly two parts (first and last name) to avoid errors when splitting the string. If any name has more than two parts, this line will raise a ValueError.
No description provided.