Skip to content

Commit a980b66

Browse files
authored
Merge pull request #32 from thisisthepy/work/delete-dead-material3
Chore: Delete the dead material3 records, the empty placeholders and wrapper/
2 parents 7beabf8 + cadda45 commit a980b66

39 files changed

Lines changed: 54 additions & 620 deletions

‎PROJECT.md‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,14 +35,14 @@ Compose(`androidx.compose.*`)를 파이썬에서 쓰기 위한 pip 패키지 **`
3535

3636
```
3737
python3 -m pytest tests -q
38-
PythonMultiplatform 체크아웃 없음 55 passed, 56 skipped
39-
python-multiplatform develop ba4c6f49+ 111 passed
38+
PythonMultiplatform 체크아웃 없음 53 passed, 56 skipped
39+
python-multiplatform develop ba4c6f49+ 109 passed
4040
그보다 오래된 체크아웃 같은 수, 그중 5 개 건너뜀 (member resolver 없음)
4141
```
4242

4343
member resolver(python-multiplatform `ba4c6f49`)가 없는 바인더에서는 proxy 의 snake_case 메서드를 부르는
4444
5 개가 건너뛴다. 건너뜀은 통과가 아니다.
45-
체크아웃 없이 통과하는 55 개 중 다수는 *부재*(옛 토큰·삭제된 파일이 없음)를 확인하는 것이라 기능 진척으로 세지
45+
체크아웃 없이 통과하는 53 개 중 다수는 *부재*(옛 토큰·삭제된 파일이 없음)를 확인하는 것이라 기능 진척으로 세지
4646
않는다.
4747

4848
### 마일스톤
@@ -70,7 +70,7 @@ pythonx/compose/ import 패키지 (현재 대부분 독스트링만 있
7070
_reexport.py 매니페스트 모듈 전체에 적용되는 재노출 규칙 하나
7171
ui/ modifier.py (빈 Modifier 등록 지점), alignment.py
7272
layout/ arrangement.py
73-
material3/ icon.py, color_scheme.py (호출 불가 기록용), 빈 파일 28 개
73+
material3/ __init__.py 하나 (위젯은 모두 재노출 규칙으로)
7474
lite/ 2024 JPype 프로토타입 (은퇴, 바이너리 97 개 추적 중)
7575
native/ 서브모듈 → thisisthepy/swing-graalvm-demo
7676
tests/ pytest (unittest 스타일)

‎docs/SPEC.md‎

Lines changed: 16 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -20,16 +20,16 @@ Run from a worktree with `python3 -m pytest tests -q` (pytest 8, CPython 3.13):
2020

2121
| Environment | Result |
2222
|---|---|
23-
| No `PythonMultiplatform` checkout found | **55 passed, 56 skipped**, 67 subtests passed |
24-
| python-multiplatform `develop` at `ba4c6f49` or later (has `add_member_resolver`) | **111 passed**, 73 subtests passed |
23+
| No `PythonMultiplatform` checkout found | **53 passed, 56 skipped**, 66 subtests passed |
24+
| python-multiplatform `develop` at `ba4c6f49` or later (has `add_member_resolver`) | **109 passed**, 72 subtests passed |
2525
| an older checkout, without `add_member_resolver` | the same, with 5 of them skipped |
2626

2727
Without a checkout, the 56 tests that install the binder's layers through `tests/adapter.py` skip.
2828
Against a binder older than `ba4c6f49`, the 5 that call a snake_case method on a proxy the binder
2929
returned skip, because that needs its member resolver (python-multiplatform #17). A skip is not a
3030
pass.
3131

32-
Of the 55 that pass without a checkout, most assert **absence** (a retired token, a deleted file, a docstring that
32+
Of the 53 that pass without a checkout, most assert **absence** (a retired token, a deleted file, a docstring that
3333
exists). Those are listed in §9 and are not counted as features.
3434

3535
---
@@ -163,13 +163,13 @@ toggle family, `TextField`, `Checkbox` and `Switch` are meant to be reached thro
163163
host binds no material3 declaration, so no test here exercises one; the render proof per widget
164164
is issue #9.
165165

166-
### S5.3 `Icon` and colour schemes — `partial`
166+
### S5.3 `Icon` and colour schemes — `planned`
167167

168-
`pythonx/compose/material3/icon.py` and `color_scheme.py` import without raising
169-
(`tests/test_material3_module.py::TheTwoUnreachableWrappersLoadWithoutCrashing`) but are **not
170-
callable**: `Icon` needs an `ImageBitmap` / `ImageVector` / `Painter` nothing bound can produce, and
171-
the two colour-scheme factories take 36 `Color` parameters. The notebook uses `Icon` and
172-
`DefaultIcons` (§8).
168+
`Icon` needs an `ImageBitmap` / `ImageVector` / `Painter`, and nothing bound produces one until the
169+
binder walks `material-icons-core` (python-multiplatform #37; then `DefaultIcons` is
170+
`Icons.Default`, INTENT §5.7). The two colour-scheme factories take 36 `Color` parameters against
171+
the binding's omission cap (python-multiplatform `a6742a1c`). The hand-written `icon.py` /
172+
`color_scheme.py` that recorded this were dead code and are deleted (#31).
173173

174174
## 6. Modifiers — extension functions as methods
175175

@@ -258,9 +258,11 @@ name)` (python-multiplatform #36; issue #9).
258258

259259
These tests pass and assert that retired 2024 mechanisms are gone. They are not features:
260260

261-
- `tests/test_legacy_modules.py` (7 tests): no chaquopy / JPype tokens or dead relative imports in
262-
`layout/__init__.py`, `lite/*.py`, `test/main.py`, `ui/unit/__init__.py`, `wrapper/__init__.py`,
261+
- `tests/test_legacy_modules.py` (6 tests): no chaquopy / JPype tokens or dead relative imports in
262+
`layout/__init__.py`, `lite/*.py`, `test/main.py`, `ui/unit/__init__.py`,
263263
`material3/__init__.py`; each retired module carries a real docstring.
264+
- `tests/test_material3_module.py::TheDeadFilesAreGone` (2 tests): `material3/` holds only its
265+
`__init__.py`, and `wrapper/` is gone (#31).
264266
- `tests/test_ui_init_module.py::TheChaquopyUiInitMechanismIsGone` (1 test).
265267

266268
---
@@ -282,15 +284,9 @@ Found in the repository; not covered by `docs/INTENT.md`, or in conflict with it
282284
4. **Two spellings for one module.** The manifest maps both `pythonx.compose.layout` and
283285
`pythonx.compose.foundation.layout` (plus `pythonx.compose.foundation` and `pythonx.compose`)
284286
"while the spelling settles".
285-
5. **A removed mechanism kept as a record.** `material3/icon.py` and `color_scheme.py` still import
286-
`androidx.compose.material3.IconKt` and scan for mangled JVM names (`"Icon-"`), the reflection
287-
approach INTENT §3 excludes.
288-
The package no longer imports them: star-importing them made `import pythonx.compose.material3`
289-
fail wherever `androidx.compose.material3` was not bound, and shadowed the binder's `Icon`.
290-
Whether the files stay is still open.
287+
5. *(Resolved, #31.)* `material3/icon.py` and `color_scheme.py`, dead reflection code, are deleted.
291288
6. *(Decided, INTENT §5.3.)* Grouped alignment constants: both spellings are to be served; the grouped one is not built yet (§7).
292-
7. **28 empty `material3/*.py` files** (`checkbox.py`, `switch.py`, `scaffold.py`, ...), and the
293-
submodule `pythonx/compose/native` → `thisisthepy/swing-graalvm-demo`, which INTENT does not
294-
mention.
289+
7. The submodule `pythonx/compose/native` → `thisisthepy/swing-graalvm-demo`, which INTENT does not
290+
mention. (The 29 empty `material3/*.py` files are deleted, #31.)
295291
8. **The `test/` directory** — a 2023–2024 Kotlin Multiplatform sample (`pycomposeui`, chaquopy
296292
era). Kept as-is pending the maintainer's decision (INTENT §4.2).

‎docs/guide/getting-started.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ <h2><span data-lang="en">1. Get the source</span><span data-lang="ko">1. 소스
4343
<section>
4444
<h2><span data-lang="en">2. Run the tests</span><span data-lang="ko">2. 테스트 실행</span></h2>
4545
<pre><code class="language-bash">python3 -m pytest tests -q</code></pre>
46-
<p data-lang="en">Expect <strong>55 passed, 56 skipped</strong>. The skipped tests drive the binder's adaptation layer and need a <a href="https://github.com/thisisthepy/python-multiplatform">python-multiplatform</a> checkout beside this one, or:</p><p data-lang="ko"><strong>55 passed, 56 skipped</strong> 가 정상입니다. 건너뛴 테스트는 바인더의 적응 계층을 구동하며, 옆에 <a href="https://github.com/thisisthepy/python-multiplatform">python-multiplatform</a> 체크아웃이 있거나 다음이 필요합니다:</p>
46+
<p data-lang="en">Expect <strong>53 passed, 56 skipped</strong>. The skipped tests drive the binder's adaptation layer and need a <a href="https://github.com/thisisthepy/python-multiplatform">python-multiplatform</a> checkout beside this one, or:</p><p data-lang="ko"><strong>53 passed, 56 skipped</strong> 가 정상입니다. 건너뛴 테스트는 바인더의 적응 계층을 구동하며, 옆에 <a href="https://github.com/thisisthepy/python-multiplatform">python-multiplatform</a> 체크아웃이 있거나 다음이 필요합니다:</p>
4747
<pre><code class="language-bash">PYTHONMULTIPLATFORM_HOME=/path/to/python-multiplatform python3 -m pytest tests -q</code></pre>
4848
<p data-lang="en">With a current one (<code>ba4c6f49</code> or later) all pass; an older one skips 5 that call a snake_case method on a proxy the binder returned. That is expected and recorded.</p><p data-lang="ko">최신 체크아웃(<code>ba4c6f49</code> 이후)이면 전부 통과하고, 오래된 체크아웃은 바인더가 돌려준 proxy 의 snake_case 메서드를 부르는 5 개를 <strong>건너뜁니다</strong>. 예상된 상태이며 기록되어 있습니다.</p>
4949
</section>

‎docs/guide/status.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
<thead><tr><th><span data-lang="en">State</span><span data-lang="ko">상태</span></th><th><span data-lang="en">Item</span><span data-lang="ko">항목</span></th></tr></thead>
3737
<tbody><tr><td><span class="chip ok"><span data-lang="en">implemented</span><span data-lang="ko">구현</span></span></td><td><span data-lang="en">Mapping manifest <code>pythonx-map.toml</code></span><span data-lang="ko">매핑 매니페스트 <code>pythonx-map.toml</code></span></td></tr><tr><td><span class="chip ok"><span data-lang="en">implemented</span><span data-lang="ko">구현</span></span></td><td><span data-lang="en"><code>@Composable</code> identity decorator</span><span data-lang="ko"><code>@Composable</code> 항등 데코레이터</span></td></tr><tr><td><span class="chip partial"><span data-lang="en">partial</span><span data-lang="ko">부분</span></span></td><td><span data-lang="en">Distribution as <code>pythonx-compose</code> — configured; no stubs yet, manifest outside the package directory</span><span data-lang="ko"><code>pythonx-compose</code> 배포 — 설정됨; 스텁 없음, 매니페스트가 패키지 디렉터리 밖</span></td></tr><tr><td><span class="chip ok"><span data-lang="en">implemented</span><span data-lang="ko">구현</span></span></td><td><span data-lang="en"><code>Modifier</code> chains, overload dispatch, <code>Dp</code> as a number</span><span data-lang="ko"><code>Modifier</code> 체인, 오버로드 디스패치, 숫자 <code>Dp</code></span></td></tr><tr><td><span class="chip partial"><span data-lang="en">partial</span><span data-lang="ko">부분</span></span></td><td><span data-lang="en">Snake-case names, keywords and signatures — done for modules and method names; method keywords are still Kotlin's</span><span data-lang="ko">snake_case 이름·키워드·시그니처 — 모듈과 메서드 이름 완료, 메서드 키워드는 아직 Kotlin 이름</span></td></tr><tr><td><span class="chip partial"><span data-lang="en">partial</span><span data-lang="ko">부분</span></span></td><td><span data-lang="en">Material 3 widgets — re-exported by rule; render proofs per widget pending (#9)</span><span data-lang="ko">Material 3 위젯 — 규칙으로 재노출됨; 위젯별 렌더 증거 대기(#9)</span></td></tr><tr><td><span class="chip partial"><span data-lang="en">partial</span><span data-lang="ko">부분</span></span></td><td><span data-lang="en"><code>Icon</code>, colour schemes — importable, not callable</span><span data-lang="ko"><code>Icon</code>, 색 스킴 — import 가능, 호출 불가</span></td></tr><tr><td><span class="chip partial"><span data-lang="en">partial</span><span data-lang="ko">부분</span></span></td><td><span data-lang="en"><code>Alignment</code> / <code>Arrangement</code> constants — reached from <code>pythonx</code>; grouped spelling pending</span><span data-lang="ko"><code>Alignment</code> / <code>Arrangement</code> 상수 — <code>pythonx</code> 에서 읽힘; 묶음 표기 대기</span></td></tr><tr><td><span class="chip ok"><span data-lang="en">implemented</span><span data-lang="ko">구현</span></span></td><td><span data-lang="en"><code>pythonx</code> as a real on-disk package re-exporting <code>androidx.compose.*</code> by one rule</span><span data-lang="ko"><code>androidx.compose.*</code> 를 규칙 하나로 재노출하는 실제 디스크 패키지 <code>pythonx</code></span></td></tr><tr><td><span class="chip planned"><span data-lang="en">planned</span><span data-lang="ko">계획</span></span></td><td><span data-lang="en"><code>.pyi</code> stubs in the wheel</span><span data-lang="ko">wheel 안의 <code>.pyi</code> 스텁</span></td></tr><tr><td><span class="chip planned"><span data-lang="en">planned</span><span data-lang="ko">계획</span></span></td><td><span data-lang="en"><code>remember_saveable</code>, <code>DefaultIcons</code>, coroutine scopes</span><span data-lang="ko"><code>remember_saveable</code>, <code>DefaultIcons</code>, 코루틴 스코프</span></td></tr></tbody>
3838
</table></div>
39-
<p data-lang="en" class="muted">Test baseline: <code>55 passed, 56 skipped</code> without a python-multiplatform checkout; <code>111 passed</code> with a current one.</p><p data-lang="ko" class="muted">테스트 기준선: python-multiplatform 체크아웃이 없으면 <code>55 passed, 56 skipped</code>, 최신 체크아웃이면 <code>111 passed</code>.</p>
39+
<p data-lang="en" class="muted">Test baseline: <code>53 passed, 56 skipped</code> without a python-multiplatform checkout; <code>109 passed</code> with a current one.</p><p data-lang="ko" class="muted">테스트 기준선: python-multiplatform 체크아웃이 없으면 <code>53 passed, 56 skipped</code>, 최신 체크아웃이면 <code>109 passed</code>.</p>
4040
</section>
4141
<section>
4242
<h2>FAQ</h2>

0 commit comments

Comments
 (0)