From d6fb6fe3aef0b48670c080d83626be7455c94fdc Mon Sep 17 00:00:00 2001 From: Tyler Goodlet Date: Fri, 11 Nov 2022 13:19:24 -0500 Subject: [PATCH] Just drop the pretty repr from our struct for now --- piker/data/types.py | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/piker/data/types.py b/piker/data/types.py index 4bdb8063..1359526c 100644 --- a/piker/data/types.py +++ b/piker/data/types.py @@ -42,16 +42,17 @@ class Struct( for f in self.__struct_fields__ } - def __repr__(self): - # only turn on pprint when we detect a python REPL - # at runtime B) - if ( - hasattr(sys, 'ps1') - # TODO: check if we're in pdb - ): - return self.pformat() + # Lul, doesn't seem to work that well.. + # def __repr__(self): + # # only turn on pprint when we detect a python REPL + # # at runtime B) + # if ( + # hasattr(sys, 'ps1') + # # TODO: check if we're in pdb + # ): + # return self.pformat() - return super().__repr__() + # return super().__repr__() def pformat(self) -> str: return f'Struct({pformat(self.to_dict())})'