Skip to content

Commit df2ed72

Browse files
committed
collect CLI arguments into a dataclass
Using library "clickdc", collect CLI arguments into a "cli_args" dataclass. A small amount of reordering was done, which affects the output of the helpdoc, but the intention is for this to introduce no other functional changes. The properties in "cli_args" are sometimes mutated, for example when reading comparable values from a DSN. But mutating the properties is debatable. New tests are introduced for the crucial user/host/port/socket coordinates, but we stop short of adding new tests for every single CLI argument. Motivations * clarity * click_entrypoint() had too many positional arguments * adding an CLI argument required adding both a decorator and a matching positional argument to click_entrypoint() * this work can be a step toward breaking up massive main.py and test_main.py Another related step would be gathering disparate runtime settings into a self.settings property.
1 parent c1ef3d8 commit df2ed72

File tree

4 files changed

+887
-309
lines changed

4 files changed

+887
-309
lines changed

changelog.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
Upcoming (TBD)
2+
==============
3+
4+
Internal
5+
---------
6+
* Collect CLI arguments into a dataclass.
7+
8+
19
1.66.0 (2026/03/21)
210
==============
311

0 commit comments

Comments
 (0)