-
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
Merge pull request #117 from mate-academy/add-checkphrases #520
base: master
Are you sure you want to change the base?
Conversation
added checklist.md
main.py
Outdated
Genre.objects.create( | ||
name="Western", | ||
) | ||
Genre.objects.create( | ||
name="Action", | ||
) | ||
Genre.objects.create( | ||
name="Dramma", | ||
) | ||
Actor.objects.create( | ||
first_name="George", | ||
last_name="Klooney", | ||
) | ||
Actor.objects.create( | ||
first_name="Kianu", | ||
last_name="Reaves", | ||
) | ||
Actor.objects.create( | ||
first_name="Scarlett", | ||
last_name="Keegan", | ||
) | ||
Actor.objects.create( | ||
first_name="Will", | ||
last_name="Smith", | ||
) | ||
Actor.objects.create( | ||
first_name="Jaden", | ||
last_name="Smith", | ||
) | ||
Actor.objects.create( | ||
first_name="Scarlett", | ||
last_name="Johansson", | ||
) |
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.
DRY
use loop
# Conflicts: # main.py
db/migrations/0001_initial.py
Outdated
|
||
operations = [ | ||
migrations.CreateModel( | ||
name='Actor', |
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.
change ' to ", use Black
main.py
Outdated
|
||
|
||
def main() -> QuerySet: | ||
pass | ||
genre_list = ["Western", "Action", "Dramma"] | ||
for objec_list in genre_list: |
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.
objec_list???
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.
use more readable name
main.py
Outdated
["Jaden", "Smith"], | ||
["Scarlett", "Johansson"] | ||
] | ||
for objec1_list in actor_list: |
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 same
main.py
Outdated
|
||
|
||
def main() -> QuerySet: | ||
pass | ||
genre_list = ["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.
genre_list = ["Western", "Action", "Dramma"] | |
genres= ["Western", "Action", "Dramma"] |
main.py
Outdated
|
||
|
||
def main() -> QuerySet: | ||
pass | ||
genre_list = ["Western", "Action", "Dramma"] | ||
for data_genre in genre_list: |
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.
for data_genre in genre_list: | |
for genre in genres: |
main.py
Outdated
["Jaden", "Smith"], | ||
["Scarlett", "Johansson"] | ||
] | ||
for data_actor in actor_list: |
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.
for data_actor in actor_list: | |
for first_name, last_name in actors: |
added checklist.md