Skip to content
Prev Previous commit
Next Next commit
Update __all__
  • Loading branch information
lukelbd committed Jan 20, 2020
commit 934a60afac03772d90c1d1c89e85800342c434dc
7 changes: 6 additions & 1 deletion proplot/subplots.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@
ic = lambda *a: None if not a else (a[0] if len(a) == 1 else a) # noqa

__all__ = [
'subplot_grid', 'close', 'show', 'subplots', 'Figure',
'subplot_grid', 'close', 'figure', 'show', 'subplots',
'EdgeStack', 'Figure', 'GeometrySolver',
'GridSpec', 'SubplotSpec',
]

Expand Down Expand Up @@ -326,6 +327,10 @@ def __getattr__(self, attr):
... paxs.format(...) # calls "format" on all panels

"""
# TODO: Consider getting rid of __getattr__ override because it is
# too much of a mind fuck for new users? Could just have bulk format
# function and colorbar, legend, and text functions for drawing
# spanning content.
if not self:
raise AttributeError(
f'Invalid attribute {attr!r}, axes grid {self!r} is empty.'
Expand Down