Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #12789
| From | Tim Roberts <timr@probo.com> |
|---|---|
| Newsgroups | comp.lang.python |
| Subject | Re: Best way to print a module? |
| Date | 2011-09-05 13:07 -0700 |
| Organization | Providenza & Boekelheide, Inc. |
| Message-ID | <traa67hlthgbqrinmvpectcvd4la9lfams@4ax.com> (permalink) |
| References | <00c3e9d0-9c15-4d69-8b7f-ee0e6ecff508@m4g2000pri.googlegroups.com> |
Martin De Kauwe <mdekauwe@gmail.com> wrote: > >If I wanted to print an entire module, skipping the attributes >starting with "__" is there an *optimal* way? Your question is somewhat ambiguous. When I read "print an entire module", I assumed you were asking for a way to print the source code, perhaps with syntax coloring. Surely there is no reason to have an "optimal" method of doing this -- this is never going to be in an inner loop. If you have a method that works, there is little justification to optimize... -- Tim Roberts, timr@probo.com Providenza & Boekelheide, Inc.
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Best way to print a module? Martin De Kauwe <mdekauwe@gmail.com> - 2011-09-05 08:06 -0700
Re: Best way to print a module? rantingrick <rantingrick@gmail.com> - 2011-09-05 09:30 -0700
Re: Best way to print a module? Tim Roberts <timr@probo.com> - 2011-09-05 13:07 -0700
Re: Best way to print a module? Martin De Kauwe <mdekauwe@gmail.com> - 2011-09-05 16:02 -0700
Re: Best way to print a module? Martin De Kauwe <mdekauwe@gmail.com> - 2011-09-05 16:20 -0700
Re: Best way to print a module? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2011-09-06 09:46 +1000
csiph-web