Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,28 @@ jobs:
- run: uv run pytest packages/discolike/tests -q
- run: uv run pytest packages/discolike-cli/tests -q

# uv.lock pins one version of every dependency; users resolve fresh from the
# pyproject ranges. Test both ends of those ranges and the built wheels.
test-resolution:
runs-on: ubuntu-latest
strategy:
matrix:
include:
- resolution: highest
python-version: '3.14'
- resolution: lowest-direct
python-version: '3.10'
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v5
with:
python-version: ${{ matrix.python-version }}
- run: uv sync --all-packages --upgrade --resolution ${{ matrix.resolution }}
- run: uv run --no-sync pytest packages/discolike/tests -q
- run: uv run --no-sync pytest packages/discolike-cli/tests -q
- run: uv build --all-packages -o dist
- run: uv run --no-project --isolated --resolution ${{ matrix.resolution }} --find-links dist --with dist/discolike_cli-*.whl discolike --version

# 3.15 is still prerelease; non-blocking until 3.15.0 final, when it moves
# into the matrix above and gets a classifier.
test-prerelease:
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## 0.4.1 (2026-09-23)

- CLI: fix `ImportError: cannot import name 'Abort' from 'typer._click.exceptions'` on every command in a fresh 0.4.0 install. Typer 0.27 moved `Abort`; the CLI now imports the public `typer.Abort` and requires `typer>=0.26.1,<0.28`, since it still relies on Typer's vendored Click for its error envelope and help formatting.

## 0.4.0 (2026-09-23)

- SDK: `validate_icp` can run without an LLM key. Pass `integration_id=NATIVE_ICP_ENGINE` (exported from `discolike`, the string `"native-icp"`) to score with DiscoLike's own ICP-fit model instead of your BYOK LLM: no LLM cost, no LLM key, and no web search on that run. The same sentinel works on `discogen.process` for a prompt that already carries the validation structure. Two new errors are specific to it: a 400 `ValidationError` when the ICP text does not yield a Mandatory / Reject if / Nice-to-have prompt, and a 503 `ServerError` when no ICP-fit engine is available. Task lifecycle, polling and statuses are unchanged.
Expand Down
6 changes: 3 additions & 3 deletions packages/discolike-cli/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,16 @@ build-backend = "hatchling.build"

[project]
name = "discolike-cli"
version = "0.4.0"
version = "0.4.1"
description = "Official CLI for the DiscoLike API"
readme = "README.md"
license = "MIT"
license-files = ["LICENSE"]
requires-python = ">=3.10"
authors = [{ name = "DiscoLike", email = "support@discolike.com" }]
dependencies = [
"discolike==0.4.0",
"typer>=0.12",
"discolike==0.4.1",
"typer>=0.26.1,<0.28",
"rich>=13.0",
]
keywords = ["discolike", "cli", "business-data", "enrichment"]
Expand Down
2 changes: 1 addition & 1 deletion packages/discolike-cli/src/discolike_cli/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from typing import Any

import typer
from typer._click.exceptions import Abort
from typer import Abort
from typer._click.exceptions import ClickException
from typer._click.exceptions import NoArgsIsHelpError
from typer._click.exceptions import UsageError
Expand Down
6 changes: 3 additions & 3 deletions packages/discolike-cli/tests/test_entrypoint.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ def _run(argv: list[str], capsys: pytest.CaptureFixture[str]) -> tuple[int, str,
("argv", "fragment"),
[
(["count", "--nope"], "--nope"),
(["discover", "--max-records", "abc"], "not a valid integer"),
(["discogen", "status"], "TASK_ID"),
(["discover", "--max-records", "abc"], "--max-records"),
(["discogen", "status"], "task_id"),
(["auth", "login", "--method", "bogus"], "--method"),
],
)
Expand All @@ -37,7 +37,7 @@ def test_parser_errors_use_the_json_envelope(
assert payload["code"] == "validation_error"
assert payload["error"] == "ValidationError"
assert payload["exit_code"] == 2
assert fragment in payload["message"]
assert fragment.lower() in payload["message"].lower()


def test_help_still_renders(capsys: pytest.CaptureFixture[str]) -> None:
Expand Down
2 changes: 1 addition & 1 deletion packages/discolike/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ classifiers = [
]

[project.optional-dependencies]
cli = ["discolike-cli==0.4.0"]
cli = ["discolike-cli==0.4.1"]

[project.urls]
Homepage = "https://www.discolike.com"
Expand Down
2 changes: 1 addition & 1 deletion packages/discolike/src/discolike/_version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "0.4.0"
__version__ = "0.4.1"
Comment thread
yudelevi marked this conversation as resolved.
2 changes: 1 addition & 1 deletion packages/discolike/tests/test_package.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@


def test_version() -> None:
assert discolike.__version__ == "0.4.0"
assert discolike.__version__ == "0.4.1"
4 changes: 2 additions & 2 deletions uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading