lordmauve/pgzero

Add __dir__() to built-in objects

Open

#101 aperta il 29 lug 2018

Vedi su GitHub
 (2 commenti) (0 reazioni) (0 assegnatari)Python (185 fork)batch import
enhancementgood first issue

Metriche repository

Star
 (472 star)
Metriche merge PR
 (Nessuna PR mergiata in 30 g)

Descrizione

The REPL added in #80 has built-in autocompletion:

autocompletion

However various built-in objects do not take full advantage of this:

  • Actor does not have autocompletion for attributes delegated to the ZRect
  • Loaders do not have autocompletion for the objects that can be loaded
  • more?

We should implement __dir__() on these classes and others to ensure that autocompletion lists all valid attributes.

Guida contributor