livery-extensions-ty 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Willem Kokke
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,28 @@
1
+ Metadata-Version: 2.4
2
+ Name: livery-extensions-ty
3
+ Version: 0.1.0
4
+ Summary: ty as a check of the livery workshop: the type checker over every platform at once, configured by the root ty.toml.
5
+ Author: Willem Kokke
6
+ Author-email: Willem Kokke <mail@willem.net>
7
+ License-Expression: MIT
8
+ License-File: LICENSE
9
+ Classifier: Development Status :: 3 - Alpha
10
+ Classifier: Programming Language :: Python :: 3
11
+ Classifier: Programming Language :: Python :: 3 :: Only
12
+ Classifier: Typing :: Typed
13
+ Requires-Dist: livery-toolroom>=0.11.0
14
+ Requires-Dist: livery-workshop>=0.7.0
15
+ Requires-Python: >=3.11
16
+ Project-URL: Repository, https://github.com/willemkokke/livery
17
+ Description-Content-Type: text/markdown
18
+
19
+ <!-- Seeded from the package-python seeds at
20
+ birth; this file is the workspace's own. Edit it directly:
21
+ nothing rewrites it.
22
+ -->
23
+ # livery-extensions-ty
24
+
25
+ ty as a check of the livery workshop. Listed as `ty` in a workspace's
26
+ `[workspace] extensions`, it registers `typecheck.ty`, which checks every
27
+ platform at once, and writes the root `ty.toml` the check and a bare `ty`
28
+ read.
@@ -0,0 +1,10 @@
1
+ <!-- Seeded from the package-python seeds at
2
+ birth; this file is the workspace's own. Edit it directly:
3
+ nothing rewrites it.
4
+ -->
5
+ # livery-extensions-ty
6
+
7
+ ty as a check of the livery workshop. Listed as `ty` in a workspace's
8
+ `[workspace] extensions`, it registers `typecheck.ty`, which checks every
9
+ platform at once, and writes the root `ty.toml` the check and a bare `ty`
10
+ read.
@@ -0,0 +1,36 @@
1
+ [build-system]
2
+ requires = ["uv_build>=0.11,<0.13"]
3
+ build-backend = "uv_build"
4
+
5
+ [project]
6
+ name = "livery-extensions-ty"
7
+ version = "0.1.0"
8
+ description = "ty as a check of the livery workshop: the type checker over every platform at once, configured by the root ty.toml."
9
+ readme = "README.md"
10
+ license = "MIT"
11
+ license-files = ["LICENSE"]
12
+ requires-python = ">=3.11"
13
+ classifiers = [
14
+ "Development Status :: 3 - Alpha",
15
+ "Programming Language :: Python :: 3",
16
+ "Programming Language :: Python :: 3 :: Only",
17
+ "Typing :: Typed",
18
+ ]
19
+ dependencies = [
20
+ "livery-toolroom>=0.11.0",
21
+ "livery-workshop>=0.7.0",
22
+ ]
23
+
24
+ [[project.authors]]
25
+ name = "Willem Kokke"
26
+ email = "mail@willem.net"
27
+
28
+ [project.urls]
29
+ Repository = "https://github.com/willemkokke/livery"
30
+
31
+ [project.entry-points."workshop.extensions"]
32
+ ty = "livery.extensions.ty"
33
+
34
+ [tool.uv.build-backend]
35
+ module-name = "livery.extensions.ty"
36
+ namespace = true
@@ -0,0 +1,43 @@
1
+ # Seeded from the package-python seeds at
2
+ # birth; this file is the workspace's own. Edit it directly:
3
+ # nothing rewrites it.
4
+ [build-system]
5
+ requires = ["uv_build>=0.11,<0.13"]
6
+ build-backend = "uv_build"
7
+
8
+ [project]
9
+ name = "livery-extensions-ty"
10
+ version = "0.1.0"
11
+ description = "ty as a check of the livery workshop: the type checker over every platform at once, configured by the root ty.toml."
12
+ readme = "README.md"
13
+ license = "MIT"
14
+ license-files = ["LICENSE"]
15
+ requires-python = ">=3.11"
16
+ authors = [{ name = "Willem Kokke", email = "mail@willem.net" }]
17
+ classifiers = [
18
+ "Development Status :: 3 - Alpha",
19
+ "Programming Language :: Python :: 3",
20
+ "Programming Language :: Python :: 3 :: Only",
21
+ "Typing :: Typed",
22
+ ]
23
+
24
+ dependencies = [
25
+ "livery-toolroom>=0.11.0",
26
+ "livery-workshop>=0.7.0",
27
+ ]
28
+
29
+ [project.urls]
30
+ Repository = "https://github.com/willemkokke/livery"
31
+
32
+ # The name a workspace lists in [workspace] extensions, and the package
33
+ # whose extension.toml the workshop mounts it from. Nothing else: the
34
+ # extension adds no verb of its own, and nothing activates by being
35
+ # installed.
36
+ [project.entry-points."workshop.extensions"]
37
+ ty = "livery.extensions.ty"
38
+
39
+ [tool.uv.build-backend]
40
+ # PEP 420 namespace: the importable package is livery.extensions.ty and
41
+ # there is no livery/__init__.py anywhere in this repository.
42
+ module-name = "livery.extensions.ty"
43
+ namespace = true
@@ -0,0 +1,42 @@
1
+ <!-- Seeded from the package-base seeds at
2
+ birth; this file is the workspace's own. Edit it directly:
3
+ nothing rewrites it.
4
+ -->
5
+ # livery-extensions-ty
6
+
7
+ ty as a check of the workshop: `typecheck.ty` type-checks the python
8
+ packages' sources on every platform at once. A workspace turns it on by
9
+ listing the extension:
10
+
11
+ ```toml
12
+ [workspace]
13
+ extensions = ["ty"]
14
+ ```
15
+
16
+ `fm typecheck` then runs it, and `fm check` runs it with the rest of the
17
+ gate. A run checks what the configuration includes whatever the run
18
+ reaches: a run costs seconds, and the configuration pins the platforms.
19
+ `fm typecheck.ty -- --output-format concise` hands `ty check` the words
20
+ after `--`.
21
+
22
+ ## The configuration
23
+
24
+ `fm sync` writes the root `ty.toml`, and a bare `ty` in the repository
25
+ reads the same file the check does. It includes each python member's
26
+ `src` directory, or `tasks.py` in a workspace without one, checks every
27
+ platform at the python version the workspace supports, and reads the
28
+ tool stubs in `typings/`.
29
+
30
+ The file is the extension's: an edit outside its region is drift, which
31
+ `fm check --fix` puts back. The repository's own tables go inside the
32
+ region at the end:
33
+
34
+ ```toml
35
+ # -- workshop: region tables, yours to edit; the render keeps it --
36
+ [rules]
37
+ possibly-unresolved-reference = "warn"
38
+ # -- workshop: end tables --
39
+ ```
40
+
41
+ A workspace that lists the extension recommends ty's editor extension,
42
+ `astral-sh.ty`, in `.vscode/extensions.json`.
@@ -0,0 +1,12 @@
1
+ # This package's section of the workspace site, hand-authored.
2
+ # Labels map to pages relative to this docs/ tree, or to nested
3
+ # lists. Every authored page must appear here, and every entry must
4
+ # name a real page. A generator owns a block between `# nav:begin
5
+ # <name>` and `# nav:end <name>` markers (tasks, tools); the emitter's
6
+ # own sections, changelog, coverage and api, are blocks too: place a
7
+ # pair where one belongs, and a section without one lands after the
8
+ # authored entries, changelog and coverage ahead of the tasks block,
9
+ # api last.
10
+ nav = [
11
+ { "Index" = "index.md" },
12
+ ]
@@ -0,0 +1,19 @@
1
+ # Written by `{{ prog }} sync` from the ty extension; the gate keeps it
2
+ # matching. Edit inside the region at the end, which is the repository's
3
+ # own; an edit anywhere else is drift.
4
+ #
5
+ # The scope is the packages themselves; the tests are read as consumer
6
+ # code by the type checkers that narrow by paths.
7
+ [src]
8
+ include = [{% if py %}{% for package in py %}"packages/{{ package.dir }}/src"{% if not loop.last %}, {% endif %}{% endfor %}{% else %}"tasks.py"{% endif %}]
9
+
10
+ [environment]
11
+ # Every platform at once (ty checks the union), {{ python_floor }} floor.
12
+ python-platform = "all"
13
+ python-version = "{{ python_floor }}"
14
+ # The tool stubs `{{ runner_prog }} toolroom.restub` writes.
15
+ extra-paths = ["typings"]
16
+
17
+ # The repository's own tables.
18
+ # -- workshop: region tables, yours to edit; the render keeps it --
19
+ # -- workshop: end tables --
@@ -0,0 +1,20 @@
1
+ # The ty extension: the type checker over every platform at once. The
2
+ # check is ty's words over what ty.toml includes, whatever a run reaches:
3
+ # a run costs seconds, and the file pins every platform at once.
4
+
5
+ [extension]
6
+ api-version = 1
7
+ # Listed in the workspace's list alone: one configuration for every member.
8
+ levels = ["workspace"]
9
+
10
+ [checks.ty.typecheck]
11
+ judge = ["ty", "check"]
12
+ kinds = ["python"]
13
+ tools = ["ty"]
14
+ arguments = true
15
+ editor-extension = "astral-sh.ty"
16
+ claims = [
17
+ { category = "source", suffixes = [".py", ".pyi"] },
18
+ { category = "test", suffixes = [".py", ".pyi"] },
19
+ { category = "test-support", suffixes = [".py", ".pyi"] },
20
+ ]