pep8 example code

[CI skip]
This commit is contained in:
Hugo 2017-02-04 11:15:06 +02:00 committed by GitHub
parent b747916147
commit eff3f882f6

View file

@ -51,8 +51,8 @@ API_SECRET = "425b55975eed76058ac220b7b4e8a054"
username = "your_user_name" username = "your_user_name"
password_hash = pylast.md5("your_password") password_hash = pylast.md5("your_password")
network = pylast.LastFMNetwork(api_key = API_KEY, api_secret = network = pylast.LastFMNetwork(api_key=API_KEY, api_secret=API_SECRET,
API_SECRET, username = username, password_hash = password_hash) username=username, password_hash=password_hash)
# Now you can use that object everywhere # Now you can use that object everywhere
artist = network.get_artist("System of a Down") artist = network.get_artist("System of a Down")
@ -63,8 +63,8 @@ track = network.get_track("Iron Maiden", "The Nomad")
track.love() track.love()
track.add_tags(("awesome", "favorite")) track.add_tags(("awesome", "favorite"))
# Type help(pylast.LastFMNetwork) or help(pylast) in a Python interpreter to get more help # Type help(pylast.LastFMNetwork) or help(pylast) in a Python interpreter
# about anything and see examples of how it works # to get more help about anything and see examples of how it works
``` ```
More examples in <a href="https://github.com/hugovk/lastfm-tools">hugovk/lastfm-tools</a> and [test_pylast.py](test_pylast.py). More examples in <a href="https://github.com/hugovk/lastfm-tools">hugovk/lastfm-tools</a> and [test_pylast.py](test_pylast.py).