Re: Common objects for CLI commands with Typer

Liste des GroupesRevenir à cl python 
Sujet : Re: Common objects for CLI commands with Typer
De : barry (at) *nospam* barrys-emacs.org (Barry Scott)
Groupes : comp.lang.python
Date : 23. Sep 2024, 19:00:10
Autres entêtes
Message-ID : <mailman.5.1727114437.2990.python-list@python.org>
References : 1 2 3 4
User-Agent : Apple Mail (2.3818.100.11.1.3)


On 21 Sep 2024, at 11:40, Dan Sommers via Python-list <python-list@python.org> wrote:
 
Despite the fact that "everything is an object" in Python, you don't
have to put data or functions inside classes or objects.  I also know
nothing about Typer, but there's nothing wrong with functions in a
module.

Python is great in allowing you to pick your style.
A few lines in a module, a couple of functions or use classes.

But once your code gets big the disciple of using classes helps
maintenance. Code with lots of globals is problematic.

Barry


Date Sujet#  Auteur
20 Sep 24 * Common objects for CLI commands with Typer7Loris Bennett
20 Sep 24 +- Re: Common objects for CLI (Posting On Python-List Prohibited)1Lawrence D'Oliveiro
21 Sep 24 +- Re: Common objects for CLI commands with Typer1Barry
21 Sep 24 +- Re: Common objects for CLI commands with Typer12QdxY4RzWzUUiLuE
23 Sep 24 +- Re: Common objects for CLI commands with Typer1Barry Scott
23 Sep 24 +- Re: Common objects for CLI commands with Typer12QdxY4RzWzUUiLuE
16 Oct 24 `- Re: Common objects for CLI commands with Typer1Roland Müller

Haut de la page

Les messages affichés proviennent d'usenet.

NewsPortal