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

Script running but no data returned #778

Open
haubnee opened this issue Jan 24, 2023 · 7 comments
Open

Script running but no data returned #778

haubnee opened this issue Jan 24, 2023 · 7 comments

Comments

@haubnee
Copy link

haubnee commented Jan 24, 2023

I'm attempting to run some sample scripts as outlined in the examples. I'm not getting any errors but there is no data returning at all.

from sportsipy.mlb.teams import Teams
teams = Teams()
for team in teams:
print(team.name, team.abbreviation)

I expect team names and abbreviations to print but they are not.

image

Desktop (please complete the following information):

  • OS: 64-bit Windows 10
  • Sportsipy Version: 0.6.0

Please help!

@ianstack
Copy link

I have the same issues :(

@macgormain
Copy link

Same issue here. I went to the sportsreference site and it seems to have created other websites that hold the actual information. This project may have just been torpedo'd because of it.

@davidjkrause
Copy link

Ran into this error and found after some investigating I had updated my packages to include pyquery=2.0.0, instead of 1.4.0. This new version of pyquery requires explicit identifcation of URLs. (Note: In my personal project I needed the later pyquery for other code I was also running along with sportsipy.)

This commit worked for me to get schedules for various leagues, and I updated the rest of the code where it appeared URL identification was needed as well.

I could probably turn this into a pull request, but I'm not sure this project is being actively updated now.

bcd92b5

The specific branch this commit is on is:

https://github.com/davidjkrause/sportsipy/tree/pyquery2

Interested to hear if this helps anyone get by the issues mentioned above.

@Duck-m-a-n
Copy link

Duck-m-a-n commented Mar 8, 2023

Your fix did the job I can't thank you enough! Just had to include url=

@swisi
Copy link

swisi commented Mar 12, 2023

Will the solution of @davidjkrause be implemented?

@davidjkrause
Copy link

My patch for pyquery2 breaks many existing tests. Note that many of the current tests already don't pass, but the pyquery change breaks more.

I'm working on fixing all the test cases, and will update my branch. Some need fixing for the pyquery change, others are broken in base, and others don't fail but will if the locally stored HTML is updated because the source site has change format.

This is all a pretty big effort, but I'm making solid progress on this and plan to get my fork of this repo at least mostly working in the next few days. I've made many changes to fix issues, but the best approach would be to break the work into separate related patches, rather than just a bulk update.

@davidjkrause
Copy link

https://github.com/davidjkrause/sportsipy/tree/pyquery2 is updated with all tests fixed, and a number of other fixes for recent data format changes.

Planning to continue working on my branch / fork to bring in other PRs which fix data issues and have been sitting for a while.

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

6 participants