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

Jingju get_* functions not working #35

Open
genisplaja opened this issue Jan 20, 2021 · 2 comments
Open

Jingju get_* functions not working #35

genisplaja opened this issue Jan 20, 2021 · 2 comments

Comments

@genisplaja
Copy link
Contributor

Hello,

I am trying to retrieve the entire available content in the Dunya's Jingju collection but some of the functions listed here in the documentation: https://dunya.compmusic.upf.edu/docs/jingju.html are not working.

I can retrieve the artists using compmusic.dunya.jingju.get_artists(), but the functions compmusic.dunya.jingju.get_recordings() and compmusic.dunya.jingju.get_releases() are returning an empty list [].
I have tried to run these functions in different collections and they actually work, so I think this problem is just for the Jingju collection.

@alastair
Copy link
Member

I tried the API and it seems to work fine for me. Can you give an example of how you're running it (make sure you don't copy the token into a comment)

@genisplaja
Copy link
Contributor Author

Thanks for the reply @alastair! Here's the code snippet I am running:

from compmusic import dunya
dunya.set_token("my_token")
recordings = dunya.makam.get_recordings()

And when I run that, recordings is a massive dictionary containing all the available makam recordings.
However, when I run the following snippet:

from compmusic import dunya
dunya.set_token("my_token")
recordings = dunya.jingju.get_recordings()

Then recordings is an empty list [].

"my_token" refers to a string containing my token, which gives me access to the restricted content of Dunya! Am I running the wrong code? Thank you!

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

No branches or pull requests

2 participants