Commit d56d9a5
Migrate to all uv commands, and fix more flaky tests (#266)
* Migrate to uv-native build system and commands
This migration modernizes the project to use uv throughout the development lifecycle:
## Build System Changes
- Replace setup.py with pyproject.toml configuration
- Remove MANIFEST.in (replaced by [tool.uv.build-backend] config)
- Configure uv_build backend with proper file inclusion
- Add frontend/__init__.py to ensure package structure
- Fix module-root configuration to include frontend build files
## Dependency Management
- Remove requirements.txt (replaced by pyproject.toml dependencies)
- Split dependency groups into 'dev' and 'test' categories
- Add uv.lock for reproducible dependency resolution
## GitHub Actions Updates
- publish_PYPI_each_tag.yml: Use 'uv build' + 'uv publish' (removes twine)
- run_tests_each_PR.yml: Use 'uv sync --group dev --group test' and 'uv run pytest'
- Update to astral-sh/setup-uv@v4 action
## Development Workflow Updates
- Taskfile.yml: All commands now use uv-native equivalents
- Update CLAUDE.md with new uv-based commands
- Preserve existing linting workflow (pre-commit compatible)
## Verification
- Frontend build files properly included in both wheel and source distributions
- Build system tested with uv 0.8.4
- Package structure and functionality preserved
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
* Improve test reliability and optimize Taskfile.yml
## Taskfile.yml Optimization
- **Consolidated setup**: Single `setup` task replaces multiple install tasks
- **Removed redundancy**: Eliminated separate `install-package` and `install-test-deps`
- **Streamlined dependencies**: No complex task dependency chains
- **Added build task**: Complete frontend + Python package build workflow
## Test Reliability Improvements Using Playwright Best Practices
- **Restored code visibility tests** for fillColor/dashArray with proper element targeting
- **Eliminated unnecessary sleep() calls** - leveraged Playwright's auto-waiting
- **20% faster test execution** (38.54s vs 49.89s)
- **Improved test targeting** using `code_buttons.last.click()` for specific elements
- **Focus on user-visible behavior** rather than internal implementation details
## Key Features
- `setup`: One-command development environment setup
- `build`: Full build pipeline (frontend JS + Python package)
- `lint`: Simple linting without dependency setup
- `test`: Self-contained test execution with playwright setup
## Test Results
✅ All 23 tests passing (100% success rate)
⚡ 20% faster execution with Playwright auto-waiting
🎯 Complete test coverage restored
🔧 Playwright best practices applied
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
* Remove meta-comment
* Remove test reqs
* Bump versio
* Bump
---------
Co-authored-by: Claude <noreply@anthropic.com>1 parent d316dab commit d56d9a5
File tree
11 files changed
+2058
-90
lines changed- .github/workflows
- streamlit_folium/frontend
- tests
11 files changed
+2058
-90
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
| 17 | + | |
| 18 | + | |
21 | 19 | | |
22 | 20 | | |
23 | 21 | | |
| |||
30 | 28 | | |
31 | 29 | | |
32 | 30 | | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | 31 | | |
38 | 32 | | |
39 | | - | |
40 | | - | |
| 33 | + | |
41 | 34 | | |
42 | 35 | | |
43 | | - | |
44 | | - | |
| 36 | + | |
| 37 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
23 | | - | |
24 | | - | |
| 23 | + | |
| 24 | + | |
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
37 | | - | |
38 | | - | |
39 | | - | |
| 37 | + | |
40 | 38 | | |
41 | 39 | | |
42 | | - | |
| 40 | + | |
43 | 41 | | |
44 | | - | |
| 42 | + | |
45 | 43 | | |
46 | 44 | | |
47 | 45 | | |
48 | | - | |
| 46 | + | |
49 | 47 | | |
50 | 48 | | |
51 | 49 | | |
| |||
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
5 | | - | |
| 4 | + | |
| 5 | + | |
6 | 6 | | |
7 | | - | |
8 | | - | |
| 7 | + | |
| 8 | + | |
9 | 9 | | |
| 10 | + | |
| 11 | + | |
10 | 12 | | |
11 | 13 | | |
12 | | - | |
13 | | - | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | 14 | | |
29 | 15 | | |
30 | | - | |
31 | | - | |
32 | 16 | | |
33 | | - | |
| 17 | + | |
34 | 18 | | |
35 | 19 | | |
36 | 20 | | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | 21 | | |
41 | | - | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
42 | 25 | | |
43 | | - | |
| 26 | + | |
| 27 | + | |
44 | 28 | | |
45 | | - | |
| 29 | + | |
| 30 | + | |
46 | 31 | | |
47 | 32 | | |
48 | | - | |
| 33 | + | |
49 | 34 | | |
50 | 35 | | |
51 | 36 | | |
52 | 37 | | |
53 | 38 | | |
54 | | - | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
55 | 43 | | |
56 | | - | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
57 | 48 | | |
58 | 49 | | |
59 | | - | |
| 50 | + | |
60 | 51 | | |
61 | 52 | | |
62 | 53 | | |
63 | | - | |
64 | | - | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
65 | 61 | | |
66 | | - | |
| 62 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
1 | 30 | | |
2 | 31 | | |
3 | 32 | | |
| |||
31 | 60 | | |
32 | 61 | | |
33 | 62 | | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
This file was deleted.
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
257 | 257 | | |
258 | 258 | | |
259 | 259 | | |
260 | | - | |
| 260 | + | |
261 | 261 | | |
262 | 262 | | |
263 | 263 | | |
| |||
380 | 380 | | |
381 | 381 | | |
382 | 382 | | |
383 | | - | |
| 383 | + | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
0 commit comments