Skip to content
This repository has been archived by the owner on Nov 26, 2019. It is now read-only.

Makes the codebase PEP8 compliant #19

Closed
wants to merge 0 commits into from
Closed

Makes the codebase PEP8 compliant #19

wants to merge 0 commits into from

Conversation

agarwalrounak
Copy link

Fixes #17

Changes:

  • The codebase is PEP8 compliant
  • The variables have meaningful names

imdb.py Outdated


def info_movie():
name = raw_input('\nEnter the title of the movie: ')
t = name.replace(' ','%20')
url = 'https://api.themoviedb.org/3/search/movie?api_key=ffb07b773769d55c36ccd83845385205&language=en-US&query='+str(t)+'&page=1&include_adult=false'
web_name = name.replace(' ', '%20')
Copy link
Member

Choose a reason for hiding this comment

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

Make it movie_name

imdb.py Outdated
t = name.replace(' ','%20')
url = 'https://api.themoviedb.org/3/search/movie?api_key=ffb07b773769d55c36ccd83845385205&language=en-US&query='+str(t)+'&page=1&include_adult=false'
web_name = name.replace(' ', '%20')
url = 'https://api.themoviedb.org/3/search/movie?api_key=ffb07b773769d55c36ccd83845385205&language=en-US&query=' + str(web_name) + '&page=1&include_adult=false'
Copy link
Member

Choose a reason for hiding this comment

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

Write meaningful names for url and url2

imdb.py Outdated
u = json.loads(response.text)
results = u['results']
results_json = json.loads(response.text)
results = results_json['results']
id = results[0]['id']
Copy link
Member

Choose a reason for hiding this comment

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

movie_id

imdb.py Outdated
duration = details['runtime']
plot = details['overview']

url3 = 'http://www.imdb.com/title/' + str(imdb_id)
Copy link
Member

Choose a reason for hiding this comment

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

Rename it

@agarwalrounak
Copy link
Author

@akshatnitd This PR got accidentally closed while rebasing. I just can't understand how. I will send a new PR soon.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants