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

using 'search_pubs()' as stated in the docs raises a StopIteration Error #541

Open
elliotchung opened this issue Jun 24, 2024 · 5 comments · Fixed by #542
Open

using 'search_pubs()' as stated in the docs raises a StopIteration Error #541

elliotchung opened this issue Jun 24, 2024 · 5 comments · Fixed by #542
Labels

Comments

@elliotchung
Copy link

Describe the bug
using 'search_pubs()' as stated in the docs raises a StopIteration Error
i think another commenter in #517 mentioned a possible cause of the error:

To Reproduce

search_query = scholarly.search_pubs('Perception of physical stability and center of mass of 3D objects')
scholarly.pprint(next(search_query))
---------------------------------------------------------------------------
StopIteration                             Traceback (most recent call last)
Cell In[15], line 1
----> 1 scholarly.pprint(next(search_query))

File ~\miniconda3\Lib\site-packages\scholarly\publication_parser.py:93, in _SearchScholarIterator.__next__(self)
     91     return self.__next__()
     92 else:
---> 93     raise StopIteration

StopIteration:

Expected behavior
Returns the single search result of this publication

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • Proxy service: NIL
  • python version: 3.11.5
  • OS: Win10
  • Version 1.7.11

Do you plan on contributing?
No

@keko24
Copy link

keko24 commented Jun 24, 2024

Hey, I am currently working on a fix, but in the mean time search_single_pub works properly for this case.

@keko24
Copy link

keko24 commented Jul 4, 2024

Hey, this was fixed so it should be closed.

@gdudek
Copy link

gdudek commented Sep 10, 2024

I am still seeing this error with a fresh re-install of scholarly and dependencies.

@keko24
Copy link

keko24 commented Sep 11, 2024

This is because a new release has not been made and distributed, so if you are installing it through pip or conda-forge you are still getting the old version. Maybe @arunkannawadi can check this out. Although in the meantime, you can download the git repo and install the package from there, it should work.

@karl-chan
Copy link

When will a new release be made with the fix? It's been nearly 2 years since the last release. If this repo is no longer maintained could you please update the readme?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
4 participants