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

papyri ascii fails with RuntimeError #311

Closed
melissawm opened this issue Oct 27, 2023 · 0 comments · Fixed by #329
Closed

papyri ascii fails with RuntimeError #311

melissawm opened this issue Oct 27, 2023 · 0 comments · Fixed by #329
Labels
bug Something isn't working

Comments

@melissawm
Copy link
Collaborator

melissawm commented Oct 27, 2023

To reproduce:

  • Follow the development installation instructions;
  • Run papyri ascii numpy.linspace (numpy:linspace doesn't work either)

Output:

✗ papyri ascii numpy:linspace

  ___                    _
 | _ \__ _ _ __ _  _ _ _(_)
 |  _/ _` | '_ \ || | '_| |
 |_| \__,_| .__/\_, |_| |_|
          |_|   |__/

0.0.8
Traceback (most recent call last):
  File "/home/melissa/projects/papyri/papyri/render.py", line 1281, in ascii_render
    key = next(iter(gstore.glob((None, None, "module", "papyri.examples"))))
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
StopIteration

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/melissa/micromamba/envs/papyri/bin/papyri", line 8, in <module>
    sys.exit(app())
             ^^^^^
  File "/home/melissa/micromamba/envs/papyri/lib/python3.11/site-packages/typer/main.py", line 328, in __call__
    raise e
  File "/home/melissa/micromamba/envs/papyri/lib/python3.11/site-packages/typer/main.py", line 311, in __call__
    return get_command(self)(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/melissa/micromamba/envs/papyri/lib/python3.11/site-packages/click/core.py", line 1157, in __call__
    return self.main(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/melissa/micromamba/envs/papyri/lib/python3.11/site-packages/typer/core.py", line 778, in main
    return _main(
           ^^^^^^
  File "/home/melissa/micromamba/envs/papyri/lib/python3.11/site-packages/typer/core.py", line 216, in _main
    rv = self.invoke(ctx)
         ^^^^^^^^^^^^^^^^
  File "/home/melissa/micromamba/envs/papyri/lib/python3.11/site-packages/click/core.py", line 1688, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/melissa/micromamba/envs/papyri/lib/python3.11/site-packages/click/core.py", line 1434, in invoke
    return ctx.invoke(self.callback, **ctx.params)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/melissa/micromamba/envs/papyri/lib/python3.11/site-packages/click/core.py", line 783, in invoke
    return __callback(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/melissa/micromamba/envs/papyri/lib/python3.11/site-packages/typer/main.py", line 683, in wrapper
    return callback(**use_params)  # type: ignore
           ^^^^^^^^^^^^^^^^^^^^^^
  File "/home/melissa/projects/papyri/papyri/__init__.py", line 527, in ascii
    trio.run(ascii_render, name)
  File "/home/melissa/micromamba/envs/papyri/lib/python3.11/site-packages/trio/_core/_run.py", line 2093, in run
    raise runner.main_task_outcome.error
RuntimeError: coroutine raised StopIteration 
@melissawm melissawm added the bug Something isn't working label Oct 27, 2023
Carreau added a commit to Carreau/papyri that referenced this issue Nov 9, 2023
Some cleanup and removal of useless code while looking how to have a
cleaner fix for jupyter#311
Carreau added a commit to Carreau/papyri that referenced this issue Nov 9, 2023
Some cleanup and removal of useless code while looking how to have a
cleaner fix for jupyter#311
Carreau added a commit that referenced this issue Nov 17, 2023
This fixes `papyri ascii <object>`.

Closes #311
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant