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
11 changes: 9 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,19 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.

## Unreleased
## 2.0.0-beta.4

* **Breaking:** Remove the deprecated beta validation annotation aliases and
their generic `kind` and `value` getters. Use the Is/Has rule annotations.

* **Breaking:** Finalize the 2.0 public API. Built-in constraint keys are
snake_case, `constrain` replaces `withConstraint`, `SchemaError.toString()`
prints `path: message` lines, string lengths count code points, and
schema-first fields are lowerCamelCase. The migration guide lists every
change.
* Regenerate model parts with `ack` and `ack_generator` at 2.0.0-beta.4.
Upgrade the five packages together.
* Add the Ack skills plugin for Claude, Codex, and Cursor (#264).
* Include the notes in each package's beta.4 changelog.

## 2.0.0-beta.3

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@
[![Documentation](https://img.shields.io/badge/docs-documentation-blue)](https://concepta.dev/ack)
[![llms.txt](https://img.shields.io/badge/llms.txt-available-8A2BE2)](https://concepta.dev/documentation/ack/reference/llms-txt)

Ack validates data in Dart and Flutter. This branch documents **2.0.0-beta.3**;
Ack validates data in Dart and Flutter. This branch documents **2.0.0-beta.4**;
see the [migration guide](docs/getting-started/migration-guide.mdx) for 1.x changes.

## Start here

Install the version documented on this branch:

```bash
dart pub add ack:^2.0.0-beta.3
dart pub add ack:^2.0.0-beta.4
```

```dart compile=body
Expand Down
2 changes: 1 addition & 1 deletion docs.json
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@
],
"variables": {
"versions": {
"default": "2.0.0-beta.3",
"default": "2.0.0-beta.4",
"isPrerelease": true
}
},
Expand Down
2 changes: 1 addition & 1 deletion docs/core-concepts/typesafe-schemas.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ runtime type returned by factories such as `Ack.string()` and `Ack.object()`.
## Install the generator

```bash
dart pub add ack:^2.0.0-beta.3 dev:ack_generator:^2.0.0-beta.3 dev:build_runner
dart pub add ack:^2.0.0-beta.4 dev:ack_generator:^2.0.0-beta.4 dev:build_runner
```

Every annotated library needs the generated part:
Expand Down
8 changes: 4 additions & 4 deletions docs/getting-started/installation.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ Add Ack to your project using the Dart CLI:

```bash
# For Dart projects
dart pub add ack:^2.0.0-beta.3
dart pub add ack:^2.0.0-beta.4

# For Flutter projects
flutter pub add ack:^2.0.0-beta.3
flutter pub add ack:^2.0.0-beta.4
```

These docs describe the 2.0.0-beta.3 prerelease. An unversioned
These docs describe the 2.0.0-beta.4 prerelease. An unversioned
`dart pub add ack` selects the latest stable release instead.

## Optional code generator
Expand All @@ -32,7 +32,7 @@ To generate models from Ack schemas or Ack schemas from hand-written models,
add `ack` and the generator package:

```bash
dart pub add ack:^2.0.0-beta.3 dev:ack_generator:^2.0.0-beta.3 dev:build_runner
dart pub add ack:^2.0.0-beta.4 dev:ack_generator:^2.0.0-beta.4 dev:build_runner
```

Annotate a class or a top-level schema with `@Schemable()`.
Expand Down
2 changes: 1 addition & 1 deletion docs/getting-started/migration-guide.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ This guide lists what changed in Ack 2.0 and 1.7, and the replacement for every

## Before you upgrade

- 2.0.0-beta.3 requires Dart `>=3.13.0`, and Flutter `>=3.47.0` (the first release that bundles Dart 3.13.0). Ack 1.7.1 supported Dart 3.9 and Flutter 3.35. Upgrade to the new floors before moving to Ack 2.0.
- Ack 2.0 requires Dart `>=3.13.0`, and Flutter `>=3.47.0` (the first release that bundles Dart 3.13.0). Ack 1.7.1 supported Dart 3.9 and Flutter 3.35. Upgrade to the new floors before moving to Ack 2.0.
- Update `ack` and `ack_generator` together to the same version.
- Rerun `dart run build_runner build` to regenerate every model part.

Expand Down
4 changes: 2 additions & 2 deletions example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ environment:


dependencies:
ack: ^2.0.0-beta.3
ack: ^2.0.0-beta.4

dev_dependencies:
ack_generator: ^2.0.0-beta.3
ack_generator: ^2.0.0-beta.4
build_runner: ^2.4.0
test: ^1.25.15
# Override dependencies to use local packages
Expand Down
2 changes: 1 addition & 1 deletion llms.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

> Dart/Flutter schema validation, codecs, JSON Schema, and optional code generation.

This checkout documents Ack 2.0.0-beta.3. Read the local files linked below so
This checkout documents Ack 2.0.0-beta.4. Read the local files linked below so
examples match the checked-out version. Package `pubspec.yaml` files own SDK
and dependency constraints.

Expand Down
2 changes: 1 addition & 1 deletion packages/ack/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Unreleased
## 2.0.0-beta.4

* Document the stable URI, list, string length, date codec, constraint error,
and JSON Schema export behavior in the guides and agent skills.
Expand Down
2 changes: 1 addition & 1 deletion packages/ack/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Ack is a schema validation library for Dart and Flutter. Ack is short for "ackno
## Install

```bash
dart pub add ack:^2.0.0-beta.3
dart pub add ack:^2.0.0-beta.4
```

## Example
Expand Down
2 changes: 1 addition & 1 deletion packages/ack/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: ack
description: Schema validation and bidirectional codecs for Dart and Flutter
version: 2.0.0-beta.3
version: 2.0.0-beta.4
repository: https://github.com/btwld/ack
issue_tracker: https://github.com/btwld/ack/issues
homepage: https://concepta.dev/ack
Expand Down
2 changes: 1 addition & 1 deletion packages/ack_firebase_ai/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Unreleased
## 2.0.0-beta.4

### Changed

Expand Down
4 changes: 2 additions & 2 deletions packages/ack_firebase_ai/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ Firebase AI (Gemini) structured-output adapter for [Ack](https://pub.dev/package

```yaml
dependencies:
ack: ^2.0.0-beta.2
ack_firebase_ai: ^2.0.0-beta.3
ack: ^2.0.0-beta.4
ack_firebase_ai: ^2.0.0-beta.4
firebase_ai: ^3.12.2
```

Expand Down
4 changes: 2 additions & 2 deletions packages/ack_firebase_ai/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: ack_firebase_ai
description: Firebase AI (Gemini) schema converter for the Ack validation library
version: 2.0.0-beta.3
version: 2.0.0-beta.4
repository: https://github.com/btwld/ack
issue_tracker: https://github.com/btwld/ack/issues
resolution: workspace
Expand All @@ -17,7 +17,7 @@ environment:


dependencies:
ack: ^2.0.0-beta.2
ack: ^2.0.0-beta.4
flutter:
sdk: flutter

Expand Down
2 changes: 1 addition & 1 deletion packages/ack_generator/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Unreleased
## 2.0.0-beta.4

### Breaking

Expand Down
2 changes: 1 addition & 1 deletion packages/ack_generator/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ When keeping build_runner 2.16, use a compatible Analyzer 13.x release from
## Installation

```sh
dart pub add ack:^2.0.0-beta.3 dev:ack_generator:^2.0.0-beta.3 dev:build_runner
dart pub add ack:^2.0.0-beta.4 dev:ack_generator:^2.0.0-beta.4 dev:build_runner
```

## Schema-first
Expand Down
4 changes: 2 additions & 2 deletions packages/ack_generator/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: ack_generator
description: Generates immutable models from Ack schemas and validated schemas from Dart classes
version: 2.0.0-beta.3
version: 2.0.0-beta.4
repository: https://github.com/btwld/ack
issue_tracker: https://github.com/btwld/ack/issues
resolution: workspace
Expand All @@ -16,7 +16,7 @@ environment:

dependencies:
# Ack packages (versions are overridden locally by Melos)
ack: ^2.0.0-beta.3
ack: ^2.0.0-beta.4
# Core code generation dependencies
analyzer: '>=13.3.0 <15.0.0'
build: '>=4.0.0 <6.0.0'
Expand Down
2 changes: 1 addition & 1 deletion packages/ack_json_schema_builder/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Unreleased
## 2.0.0-beta.4

### Breaking

Expand Down
6 changes: 3 additions & 3 deletions packages/ack_json_schema_builder/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ Adapter between [Ack](https://pub.dev/packages/ack) schemas and [`json_schema_bu

```yaml
dependencies:
ack: ^2.0.0-beta.2
ack_json_schema_builder: ^2.0.0-beta.3
ack: ^2.0.0-beta.4
ack_json_schema_builder: ^2.0.0-beta.4
json_schema_builder: ^0.1.3
```

This package needs `ack: ^2.0.0-beta.2` and `json_schema_builder: ^0.1.3`. Report [compatibility issues](https://github.com/btwld/ack/issues).
This package needs `ack: ^2.0.0-beta.4` and `json_schema_builder: ^0.1.3`. Report [compatibility issues](https://github.com/btwld/ack/issues).

## Usage

Expand Down
4 changes: 2 additions & 2 deletions packages/ack_json_schema_builder/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: ack_json_schema_builder
description: JSON Schema Builder converter for the Ack validation library
version: 2.0.0-beta.3
version: 2.0.0-beta.4
repository: https://github.com/btwld/ack
issue_tracker: https://github.com/btwld/ack/issues
resolution: workspace
Expand All @@ -14,7 +14,7 @@ environment:


dependencies:
ack: ^2.0.0-beta.2
ack: ^2.0.0-beta.4
json_schema_builder: ^0.1.3

dev_dependencies:
Expand Down
2 changes: 1 addition & 1 deletion packages/ack_mcp_dart/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Unreleased
## 2.0.0-beta.4

### Breaking

Expand Down
6 changes: 3 additions & 3 deletions packages/ack_mcp_dart/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ Transport, negotiation, cancellation, and lifecycle remain in `mcp_dart`.

```yaml
dependencies:
ack: ^2.0.0-beta.2
ack_mcp_dart: ^2.0.0-beta.3
ack: ^2.0.0-beta.4
ack_mcp_dart: ^2.0.0-beta.4
mcp_dart: ^2.4.2
```

Expand Down Expand Up @@ -140,7 +140,7 @@ For the keyword mapping, see [JSON Schema Integration](https://concepta.dev/docu
| Component | Supported / exercised |
| --- | --- |
| Dart | `>=3.13.0 <4.0.0` |
| Ack | `^2.0.0-beta.2` |
| Ack | `^2.0.0-beta.4` |
| mcp_dart | `^2.4.2` |
| MCP stable discovery | `2026-07-28` |
| MCP initialization | `2025-11-25`, `2025-06-18` |
Expand Down
4 changes: 2 additions & 2 deletions packages/ack_mcp_dart/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: ack_mcp_dart
description: MCP tool schemas and typed argument validation for Ack and mcp_dart
version: 2.0.0-beta.3
version: 2.0.0-beta.4
repository: https://github.com/btwld/ack
issue_tracker: https://github.com/btwld/ack/issues
resolution: workspace
Expand All @@ -15,7 +15,7 @@ environment:


dependencies:
ack: ^2.0.0-beta.2
ack: ^2.0.0-beta.4
mcp_dart: ^2.4.2

dev_dependencies:
Expand Down
2 changes: 1 addition & 1 deletion plugins/ack/.claude-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ack",
"version": "2.0.0-beta.3",
"version": "2.0.0-beta.4",
"description": "Agent skills for Ack 2.0, the Dart schema validation library: runtime schemas, @Schemable data classes, and schemas for MCP and Gemini.",
"author": { "name": "Ack contributors" },
"homepage": "https://github.com/btwld/ack",
Expand Down
2 changes: 1 addition & 1 deletion plugins/ack/.codex-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ack",
"version": "2.0.0-beta.3",
"version": "2.0.0-beta.4",
"description": "Agent skills for Ack 2.0, the Dart schema validation library: runtime schemas, @Schemable data classes, and schemas for MCP and Gemini.",
"author": {
"name": "Ack contributors"
Expand Down
2 changes: 1 addition & 1 deletion plugins/ack/.cursor-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "ack",
"displayName": "Ack",
"version": "2.0.0-beta.3",
"version": "2.0.0-beta.4",
"description": "Agent skills for Ack 2.0, the Dart schema validation library: runtime schemas, @Schemable data classes, and schemas for MCP and Gemini.",
"author": { "name": "Ack contributors" },
"homepage": "https://github.com/btwld/ack",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Gemini structured output via Firebase AI (ack_firebase_ai)

Source: [Firebase AI adapter README](https://github.com/btwld/ack/blob/v2.0.0-beta.3/packages/ack_firebase_ai/README.md). Flutter only; replace `<constraint>` with the matching 2.x constraint from [the Ack version check](../../using-ack/SKILL.md#1-check-the-installed-version-first).
Source: [Firebase AI adapter README](https://github.com/btwld/ack/blob/v2.0.0-beta.4/packages/ack_firebase_ai/README.md). Flutter only; replace `<constraint>` with the matching 2.x constraint from [the Ack version check](../../using-ack/SKILL.md#1-check-the-installed-version-first).

```bash
flutter pub add 'ack:<constraint>' 'ack_firebase_ai:<constraint>' firebase_ai firebase_core http
Expand Down
2 changes: 1 addition & 1 deletion plugins/ack/skills/ack-provider-schemas/references/mcp.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# MCP tools with ack_mcp_dart

Source: [MCP adapter README](https://github.com/btwld/ack/blob/v2.0.0-beta.3/packages/ack_mcp_dart/README.md) (examples use `mcp_dart` 2.4.x).
Source: [MCP adapter README](https://github.com/btwld/ack/blob/v2.0.0-beta.4/packages/ack_mcp_dart/README.md) (examples use `mcp_dart` 2.4.x).

Replace `<constraint>` with the matching 2.x constraint from [the Ack version check](../../using-ack/SKILL.md#1-check-the-installed-version-first).

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Custom field types in @Schemable classes

Owning guide: [Type-safe schemas](https://github.com/btwld/ack/blob/v2.0.0-beta.3/docs/core-concepts/typesafe-schemas.mdx) ("Custom schemas and types that own their schema").
Owning guide: [Type-safe schemas](https://github.com/btwld/ack/blob/v2.0.0-beta.4/docs/core-concepts/typesafe-schemas.mdx) ("Custom schemas and types that own their schema").

A field whose type the generator can't infer needs a schema that **produces that type**, usually a codec. Ack looks for one in this order:

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Schema-first models and .schema.json codegen

Owning docs: [Type-safe schemas](https://github.com/btwld/ack/blob/v2.0.0-beta.3/docs/core-concepts/typesafe-schemas.mdx) and the [generator README](https://github.com/btwld/ack/blob/v2.0.0-beta.3/packages/ack_generator/README.md).
Owning docs: [Type-safe schemas](https://github.com/btwld/ack/blob/v2.0.0-beta.4/docs/core-concepts/typesafe-schemas.mdx) and the [generator README](https://github.com/btwld/ack/blob/v2.0.0-beta.4/packages/ack_generator/README.md).

## @Schemable on a top-level schema

Expand Down
2 changes: 1 addition & 1 deletion plugins/ack/skills/using-ack/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ description: Ack 2.0 runtime schemas for Dart. Use when validating JSON or maps

## 1. Check the installed version first

Use `^2.0.0-beta.3` or any later 2.x constraint. Keep `ack` and the `ack_*` packages you use on the same release. The examples were checked against the release in the [tagged API index](https://github.com/btwld/ack/blob/v2.0.0-beta.3/llms.txt); for a newer install, use the docs and SDK requirements for the installed release. The baseline requires Dart >=3.13 (Flutter >=3.47 for Flutter apps).
Use `^2.0.0-beta.4` or any later 2.x constraint. Keep `ack` and the `ack_*` packages you use on the same release. The examples were checked against the release in the [tagged API index](https://github.com/btwld/ack/blob/v2.0.0-beta.4/llms.txt); for a newer install, use the docs and SDK requirements for the installed release. The baseline requires Dart >=3.13 (Flutter >=3.47 for Flutter apps).

Run `dart pub deps --style=compact | grep -E '^- ack'` (or read `pubspec.lock`).

Expand Down
2 changes: 1 addition & 1 deletion plugins/ack/skills/using-ack/references/json-schema.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# JSON Schema export and import

Owning guide: [JSON Schema integration](https://github.com/btwld/ack/blob/v2.0.0-beta.3/docs/guides/json-schema-integration.mdx).
Owning guide: [JSON Schema integration](https://github.com/btwld/ack/blob/v2.0.0-beta.4/docs/guides/json-schema-integration.mdx).

## Export

Expand Down
2 changes: 1 addition & 1 deletion plugins/ack/skills/using-ack/references/migrate-1x.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Migrating Ack 1.x and earlier 2.0 prereleases

Upgrade only after the user confirms the target in [the version check](../SKILL.md#1-check-the-installed-version-first). “Latest” alone does not confirm a prerelease; leave dependencies and source unchanged while you wait for the answer. See the [migration guide](https://github.com/btwld/ack/blob/v2.0.0-beta.3/docs/getting-started/migration-guide.mdx) for every substitution.
Upgrade only after the user confirms the target in [the version check](../SKILL.md#1-check-the-installed-version-first). “Latest” alone does not confirm a prerelease; leave dependencies and source unchanged while you wait for the answer. See the [migration guide](https://github.com/btwld/ack/blob/v2.0.0-beta.4/docs/getting-started/migration-guide.mdx) for every substitution.

## Steps

Expand Down
Loading