Skip to content

feat(cli)!: take --local-registry, --remote-registry and --auto-build - #669

Merged
karhu merged 3 commits into
tnet-157/15-defaultsfrom
tnet-157/16-cli-flags
Nov 10, 2026
Merged

karhu merged 3 commits into
tnet-157/15-defaultsfrom
tnet-157/16-cli-flags

Conversation

@karhu

@karhu karhu commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

The Stack

This stack covers refactoring the internal logic of how releases are resolved during read, download & build, in particular also in the context of parent releases / parent datasets. On top of that it refactors the public TimeNet APIs and CLI interfaces around these actions, to streamline the behavior across them.

This PR

timenet list, search, info and download take --local-registry, --remote-registry and --auto-build/--no-auto-build. They replace --registry.

Details

The consumer CLI had one flag for the list of sources: --registry named the registry after the store. The store and the installed connectors came only from the environment, so a command cannot move the store or leave out the connectors.

  • Each flag matches one variable of the default list and overrides it. If a flag is not given, the variable applies.
  • The commands make the list with default_sources(). An empty value raises TimeFValidationError and never means the current directory. The error names the variable. If the variable has a flag, the error names the flag too.
  • timenet local info and timenet local clear take only --local-registry, because they work on the store and the cache alone. timenet local cache info and timenet local cache clear take no flag.
  • The flags live in the new module timenet.cli.options, so that the build CLI can take the same flags with the same help.
  • Size: about 250 changed lines.

Design decisions

  • The flags sit in a shared module, because the build CLI must take the same flags with the same help. A second copy can drift.
  • The commands use default_sources() and not their own parsing, so a flag and its variable follow the same checks.
  • local info and local clear take no other flags, because they never read a registry after the store.

Breaking changes

  • timenet list, search, info and download take --local-registry, --remote-registry and --auto-build/--no-auto-build instead of --registry.
  • timenet local info and timenet local clear take --local-registry.

Stack

Changes later in the stack:

Merge message

feat(cli)!: take --local-registry, --remote-registry and --auto-build

timenet list, search, info and download take --local-registry,
--remote-registry and --auto-build/--no-auto-build, so that one
command can move the local registry or leave out the installed
connectors.

- Each flag overrides one variable of the default list. If a flag is
  not given, its variable applies.
- The commands make the list with default_sources(), so a flag and its
  variable follow the same checks. An empty value is an error that
  names the flag and the variable.
- timenet local info and timenet local clear take only
  --local-registry.
- The flags live in timenet.cli.options, so that the build CLI can
  share them.

BREAKING CHANGE: timenet list, search, info and download lose
--registry and -r. Use --remote-registry.

@karhu
karhu added this pull request to stack #650 November 4, 2026 20:04
This was referenced Nov 4, 2026
@karhu
karhu force-pushed the tnet-157/16-cli-flags branch from 8ca6084 to 9cda287 Compare November 5, 2026 07:24
@karhu
karhu force-pushed the tnet-157/16-cli-flags branch from 9cda287 to 098dc45 Compare November 5, 2026 08:16
@karhu
karhu force-pushed the tnet-157/16-cli-flags branch from 098dc45 to 23292cc Compare November 5, 2026 10:57
@karhu
karhu force-pushed the tnet-157/16-cli-flags branch from 23292cc to 7d61be1 Compare November 5, 2026 14:05
@karhu
karhu force-pushed the tnet-157/16-cli-flags branch from d64e5e4 to cad0ed0 Compare November 7, 2026 15:20
@karhu
karhu force-pushed the tnet-157/16-cli-flags branch from cad0ed0 to 59eb3e3 Compare November 7, 2026 16:27
@karhu
karhu force-pushed the tnet-157/16-cli-flags branch from 59eb3e3 to 0e9d806 Compare November 7, 2026 17:40
@karhu
karhu force-pushed the tnet-157/16-cli-flags branch 2 times, most recently from 0d0234d to 3fd4fd8 Compare November 7, 2026 22:40
@karhu
karhu force-pushed the tnet-157/16-cli-flags branch from 3fd4fd8 to 1d20f8f Compare November 9, 2026 13:56
@karhu
karhu force-pushed the tnet-157/16-cli-flags branch from 1d20f8f to 85c5a3c Compare November 9, 2026 16:18
@karhu
karhu force-pushed the tnet-157/16-cli-flags branch from 85c5a3c to 56dd4be Compare November 10, 2026 14:39

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nothing blocking. The comments below are optional suggestions. There is no need to push a fix for them before merging.

Comment thread packages/timenet/src/timenet/cli/app.py Resolved
@karhu
karhu force-pushed the tnet-157/16-cli-flags branch from 56dd4be to c1291e6 Compare November 10, 2026 15:50

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code review found no issues

No high-confidence issues detected in this change.

@karhu
karhu removed this pull request from stack #699 November 10, 2026 15:58
@karhu
karhu force-pushed the tnet-157/16-cli-flags branch from c1291e6 to 71a370c Compare November 10, 2026 16:24
@karhu
karhu added this pull request to stack #772 November 10, 2026 16:24

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Code review skipped: your organization has reached its API usage limit, so Code Review can't run right now.

An organization admin can review the limit in your organization's usage and billing settings.

Once the limit resets or is raised, someone with write access to this repository can comment @claude review on this pull request to trigger a review.

The consumer CLI had one flag for the list of sources: --registry named
the registry after the local registry. The local registry and the
installed connectors came only from the environment, so a command could
not move the local registry or leave out the connectors.

Now list, search, info and download take three flags, one for each
variable of the default list. --local-registry places the local
registry, --remote-registry names the registry after it, and
--auto-build/--no-auto-build puts the installed connectors last or
leaves them out. Each flag overrides its variable. If a flag is not
given, the variable applies. The commands make the list with
default_sources(), so an empty value raises TimeFValidationError and
never means the current directory. The error names the variable and, if
the variable has one, its flag.

timenet local info and timenet local clear take only --local-registry,
because they work on the local registry and the cache alone. timenet
local cache info and clear take no flag.

The flags are in the new module timenet.cli.options, so that the
build CLI can take the same flags with the same help.

BREAKING CHANGE: timenet list, search, info and download take
--local-registry, --remote-registry and --auto-build/--no-auto-build
instead of --registry.

Part of TNET-157.
Shorter docstrings for the code that this change adds or changes.

Part of TNET-157.
Drop tests that cannot fail or repeat other tests, and sharpen the rest.

Part of TNET-157.
@karhu
karhu force-pushed the tnet-157/16-cli-flags branch from 71a370c to 29cb245 Compare November 10, 2026 17:41
@karhu
karhu merged commit dfc2f6b into main Nov 10, 2026
8 of 12 checks passed
@karhu
karhu deleted the tnet-157/16-cli-flags branch November 10, 2026 18:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants