On Thu, Apr 2, 2020 at 7:37 AM Rhodri James <rho...@kynesim.co.uk> wrote: > > On 01/04/2020 21:22, Abdur-Rahmaan Janhangeer wrote: > > Greetings list, > > > > I have a custom package. > > > >>>> import package > >>>> package > > <module 'package' from '<path>'> > > > > what do i have to modify from my package to have like > > > >>>> package > > Hi! > > Do you mean "How do I override the str() or repr() of a module"? I > don't think you can. >
Not easily. It is possible but only by replacing the module as you're importing it. Also, I'm not sure why you would even need/want to do this - Abdur, can you elaborate on the use-case here? ChrisA -- https://mail.python.org/mailman/listinfo/python-list