Sujet : Re: Common objects for CLI commands with Typer
De : 2QdxY4RzWzUUiLuE (at) *nospam* potatochowder.com
Groupes : comp.lang.pythonDate : 23. Sep 2024, 20:51:49
Autres entêtes
Message-ID : <mailman.6.1727121120.2990.python-list@python.org>
References : 1 2 3 4 5
On 2024-09-23 at 19:00:10 +0100,
Barry Scott <
barry@barrys-emacs.org> wrote:
On 21 Sep 2024, at 11:40, Dan Sommers via Python-list <python-list@python.org> wrote:
But once your code gets big the disciple of using classes helps
maintenance. Code with lots of globals is problematic.
Even before your code gets big, discipline helps maintenance. :-)
Every level of your program has globals. An application with too many
classes is no better (or worse) than a class with too many methods, or a
module with too many functions. Insert your own definitions of (and
tolerances for) "too many," which will vary in flexibility.
(And as was alluded to elsewhere in this thread, you could probably
deduce the original and/or preferred programming languages of people
with certain such definitions. But I digress.)
$ python -m this|grep Namespaces
Namespaces are one honking great idea -- let's do more of those!