ipython / ipython/ipykernel

Customizable hook for pinfo (?) akin to _ipython_display_

Aberta
#1,005 1 comentário 0 reações 0 responsáveis Ver no GitHub
Linguagem predominante
Python
Estrelas
734
Forks
412
Merge médio
1d 5h
PRs com merge (30d)
8

Descrição

[Related to https://github.com/jupyterlab/jupyterlab/issues/13217]

This is mostly applicable to working in a notebook or lab environment, but I would like to be able to customize what happens when I call `?` on the classes and objects in the libraries I write. This kind of hook already exists for displaying objects through `_ipython_display_` and now I would just like it to also work for calling like `?MyNiceClass`

In principle, this should be easy as `?` just calls into the `pinfo` magic which could check for the existence of some hook like `_ipython_pinfo_` or something similar, although two variants might be required, one for instances and one for classes

Guia de contribuição

Abrir o guia de contribuição

Avaliação

Esta issue ainda não foi avaliada.

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.