datacook-app 2.13.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.
Files changed (97) hide show
  1. datacook_app-2.13.0/LICENSE +22 -0
  2. datacook_app-2.13.0/PKG-INFO +141 -0
  3. datacook_app-2.13.0/README.md +101 -0
  4. datacook_app-2.13.0/pyproject.toml +431 -0
  5. datacook_app-2.13.0/pyproject.toml.orig +452 -0
  6. datacook_app-2.13.0/src/datacook/__init__.py +6 -0
  7. datacook_app-2.13.0/src/datacook/allocator.py +80 -0
  8. datacook_app-2.13.0/src/datacook/app/README.md +141 -0
  9. datacook_app-2.13.0/src/datacook/app/__init__.py +23 -0
  10. datacook_app-2.13.0/src/datacook/app/__main__.py +7 -0
  11. datacook_app-2.13.0/src/datacook/app/actions.py +273 -0
  12. datacook_app-2.13.0/src/datacook/app/application.py +185 -0
  13. datacook_app-2.13.0/src/datacook/app/bridge.py +119 -0
  14. datacook_app-2.13.0/src/datacook/app/commands.py +220 -0
  15. datacook_app-2.13.0/src/datacook/app/controllers/__init__.py +15 -0
  16. datacook_app-2.13.0/src/datacook/app/controllers/app.py +143 -0
  17. datacook_app-2.13.0/src/datacook/app/controllers/command.py +108 -0
  18. datacook_app-2.13.0/src/datacook/app/controllers/node.py +207 -0
  19. datacook_app-2.13.0/src/datacook/app/controllers/preview.py +254 -0
  20. datacook_app-2.13.0/src/datacook/app/controllers/project.py +448 -0
  21. datacook_app-2.13.0/src/datacook/app/docks/__init__.py +1 -0
  22. datacook_app-2.13.0/src/datacook/app/docks/code.py +160 -0
  23. datacook_app-2.13.0/src/datacook/app/docks/dataview.py +369 -0
  24. datacook_app-2.13.0/src/datacook/app/docks/messages.py +329 -0
  25. datacook_app-2.13.0/src/datacook/app/docks/nodetree.py +588 -0
  26. datacook_app-2.13.0/src/datacook/app/docks/params.py +323 -0
  27. datacook_app-2.13.0/src/datacook/app/docks/recipes.py +656 -0
  28. datacook_app-2.13.0/src/datacook/app/docks/schema.py +320 -0
  29. datacook_app-2.13.0/src/datacook/app/eventqueue.py +148 -0
  30. datacook_app-2.13.0/src/datacook/app/jobs.py +187 -0
  31. datacook_app-2.13.0/src/datacook/app/mainwindow.py +200 -0
  32. datacook_app-2.13.0/src/datacook/app/pins.py +65 -0
  33. datacook_app-2.13.0/src/datacook/app/protocols.py +130 -0
  34. datacook_app-2.13.0/src/datacook/app/settings.py +60 -0
  35. datacook_app-2.13.0/src/datacook/app/slots.py +145 -0
  36. datacook_app-2.13.0/src/datacook/app/state.py +148 -0
  37. datacook_app-2.13.0/src/datacook/app/style.py +277 -0
  38. datacook_app-2.13.0/src/datacook/app/testing.py +498 -0
  39. datacook_app-2.13.0/src/datacook/app/uimodules.py +67 -0
  40. datacook_app-2.13.0/src/datacook/app/widgets/__init__.py +1 -0
  41. datacook_app-2.13.0/src/datacook/app/widgets/columnchooser.py +355 -0
  42. datacook_app-2.13.0/src/datacook/app/widgets/memoryindicator.py +133 -0
  43. datacook_app-2.13.0/src/datacook/app/widgets/overlay.py +99 -0
  44. datacook_app-2.13.0/src/datacook/app/widgets/readerdialog.py +151 -0
  45. datacook_app-2.13.0/src/datacook/constants/__init__.py +0 -0
  46. datacook_app-2.13.0/src/datacook/constants/iconnames.py +128 -0
  47. datacook_app-2.13.0/src/datacook/core/__init__.py +0 -0
  48. datacook_app-2.13.0/src/datacook/core/application.py +42 -0
  49. datacook_app-2.13.0/src/datacook/engine/__init__.py +28 -0
  50. datacook_app-2.13.0/src/datacook/engine/cache.py +121 -0
  51. datacook_app-2.13.0/src/datacook/engine/categories.py +30 -0
  52. datacook_app-2.13.0/src/datacook/engine/codegen.py +124 -0
  53. datacook_app-2.13.0/src/datacook/engine/events.py +35 -0
  54. datacook_app-2.13.0/src/datacook/engine/formats.py +205 -0
  55. datacook_app-2.13.0/src/datacook/engine/frames.py +112 -0
  56. datacook_app-2.13.0/src/datacook/engine/node.py +39 -0
  57. datacook_app-2.13.0/src/datacook/engine/ops/__init__.py +38 -0
  58. datacook_app-2.13.0/src/datacook/engine/ops/base.py +492 -0
  59. datacook_app-2.13.0/src/datacook/engine/ops/categorical.py +125 -0
  60. datacook_app-2.13.0/src/datacook/engine/ops/code.py +73 -0
  61. datacook_app-2.13.0/src/datacook/engine/ops/columns.py +500 -0
  62. datacook_app-2.13.0/src/datacook/engine/ops/combine.py +229 -0
  63. datacook_app-2.13.0/src/datacook/engine/ops/dates.py +260 -0
  64. datacook_app-2.13.0/src/datacook/engine/ops/estimators.py +955 -0
  65. datacook_app-2.13.0/src/datacook/engine/ops/missing.py +331 -0
  66. datacook_app-2.13.0/src/datacook/engine/ops/reshape.py +228 -0
  67. datacook_app-2.13.0/src/datacook/engine/ops/rows.py +258 -0
  68. datacook_app-2.13.0/src/datacook/engine/ops/series.py +539 -0
  69. datacook_app-2.13.0/src/datacook/engine/ops/sources.py +258 -0
  70. datacook_app-2.13.0/src/datacook/engine/ops/stats.py +336 -0
  71. datacook_app-2.13.0/src/datacook/engine/ops/strings.py +419 -0
  72. datacook_app-2.13.0/src/datacook/engine/ops/timeseries.py +704 -0
  73. datacook_app-2.13.0/src/datacook/engine/ops/values.py +141 -0
  74. datacook_app-2.13.0/src/datacook/engine/parser.py +261 -0
  75. datacook_app-2.13.0/src/datacook/engine/project.py +75 -0
  76. datacook_app-2.13.0/src/datacook/engine/recipes.py +585 -0
  77. datacook_app-2.13.0/src/datacook/engine/registry.py +76 -0
  78. datacook_app-2.13.0/src/datacook/engine/restructure.py +70 -0
  79. datacook_app-2.13.0/src/datacook/engine/session.py +720 -0
  80. datacook_app-2.13.0/src/datacook/engine/timecol.py +76 -0
  81. datacook_app-2.13.0/src/datacook/i18n.py +78 -0
  82. datacook_app-2.13.0/src/datacook/locales/datacook.pot +2654 -0
  83. datacook_app-2.13.0/src/datacook/locales/de/LC_MESSAGES/datacook.mo +0 -0
  84. datacook_app-2.13.0/src/datacook/locales/de/LC_MESSAGES/datacook.po +4424 -0
  85. datacook_app-2.13.0/src/datacook/py.typed +0 -0
  86. datacook_app-2.13.0/src/datacook/resources/darktheme.qss +994 -0
  87. datacook_app-2.13.0/src/datacook/resources/datetime.parquet +0 -0
  88. datacook_app-2.13.0/src/datacook/resources/fonts/RobotoMono-Regular.ttf +0 -0
  89. datacook_app-2.13.0/src/datacook/resources/icon.ico +0 -0
  90. datacook_app-2.13.0/src/datacook/resources/icon.svg +39 -0
  91. datacook_app-2.13.0/src/datacook/resources/icons/128x128.png +0 -0
  92. datacook_app-2.13.0/src/datacook/resources/icons/16x16.png +0 -0
  93. datacook_app-2.13.0/src/datacook/resources/icons/24x24.png +0 -0
  94. datacook_app-2.13.0/src/datacook/resources/icons/256x256.png +0 -0
  95. datacook_app-2.13.0/src/datacook/resources/icons/32x32.png +0 -0
  96. datacook_app-2.13.0/src/datacook/resources/icons/48x48.png +0 -0
  97. datacook_app-2.13.0/src/datacook/resources/icons/64x64.png +0 -0
@@ -0,0 +1,22 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026, Philipp Temminghoff
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.
22
+
@@ -0,0 +1,141 @@
1
+ Metadata-Version: 2.4
2
+ Name: datacook-app
3
+ Version: 2.13.0
4
+ Summary: Qt desktop tool for pandas data analysis that records every transformation as replayable Python code
5
+ Keywords: data analysis,data science,dataframe,gui,pandas,qt,statistics
6
+ Author: Philipp Temminghoff
7
+ Author-email: Philipp Temminghoff <philipptemminghoff@gmail.com>
8
+ License-Expression: MIT
9
+ License-File: LICENSE
10
+ Classifier: Development Status :: 3 - Alpha
11
+ Classifier: Environment :: X11 Applications :: Qt
12
+ Classifier: Intended Audience :: Science/Research
13
+ Classifier: Operating System :: OS Independent
14
+ Classifier: Programming Language :: Python
15
+ Classifier: Programming Language :: Python :: 3
16
+ Classifier: Programming Language :: Python :: 3 :: Only
17
+ Classifier: Topic :: Scientific/Engineering :: Information Analysis
18
+ Requires-Dist: pyside6
19
+ Requires-Dist: cutepandas>=0.6.2
20
+ Requires-Dist: epregistry>=2.0.5
21
+ Requires-Dist: numpy
22
+ Requires-Dist: pandas
23
+ Requires-Dist: platformdirs
24
+ Requires-Dist: prettyqt>=1.65.0
25
+ Requires-Dist: psutil>=7.2.2
26
+ Requires-Dist: pyarrow>=26.0.1
27
+ Requires-Dist: pydantic
28
+ Requires-Dist: openpyxl>=3.1.5 ; extra == 'excel'
29
+ Requires-Dist: scikit-learn>=1.9 ; extra == 'sklearn'
30
+ Maintainer: Philipp Temminghoff
31
+ Maintainer-email: Philipp Temminghoff <philipptemminghoff@gmail.com>
32
+ Requires-Python: >=3.14
33
+ Project-URL: Code coverage, https://app.codecov.io/gh/phil65/datacook
34
+ Project-URL: Documentation, https://phil65.github.io/datacook/
35
+ Project-URL: Issues, https://github.com/phil65/datacook/issues
36
+ Project-URL: Source, https://github.com/phil65/datacook
37
+ Provides-Extra: excel
38
+ Provides-Extra: sklearn
39
+ Description-Content-Type: text/markdown
40
+
41
+ # DataCook
42
+
43
+ DataCook is a desktop tool for exploring and transforming tables. Every operation you apply is
44
+ recorded as a step in a tree, so an analysis can be branched, replayed, saved as a project or
45
+ exported as a Python script (and the script can be edited and read back).
46
+
47
+ > **Status: being rebuilt** (phase 3 of the plan done: the new app). The new Qt app runs on
48
+ > a Qt-free engine (`datacook.engine`): a tree of typed operation records, frames computed
49
+ > on demand under a memory budget (pandas 3 with pyarrow dtypes), code generated from the
50
+ > records and parsed back. The op catalogue is a starter set (24 ops, basic readers and
51
+ > writers); porting the rest of the old catalogue in [`legacy/`](legacy/README.md) is next.
52
+
53
+ ## The app
54
+
55
+ ```bash
56
+ uv sync --all-extras
57
+ uv run datacook # or: uv run python -m datacook.app
58
+ uv run datacook project.datacook # open a project
59
+ uv run datacook data.csv # open a data file (reader dialog)
60
+ uv run python tools/demo_data.py demo # sample data + a demo project in ./demo
61
+ ```
62
+
63
+ **Concept.** A project is a tree of *steps*. A root step reads a file; every other step is one
64
+ operation (filter, rename, group, merge, ...) applied to its parent(s). Adding a step to a step
65
+ that already has children creates a *branch*; a merge takes a second table as its other input.
66
+ The steps are stored as typed records (operation + parameters), not as data: tables are
67
+ computed when you look at them and kept in a cache under a memory budget, so a long tree of a
68
+ large table does not cost a copy per step. The **code** of every step is generated from its
69
+ record; the whole tree (or the path to one step) exports as a plain pandas script.
70
+
71
+ **Docks** (all follow the selected step; View menu to show / hide them):
72
+
73
+ | Dock | What |
74
+ |---|---|
75
+ | Steps (left) | the tree: name, shape, size; badges for in memory / in use / computing / error. Right-click: rename, comment, branch, delete |
76
+ | Data (center) | the table of the selected step, or the preview of the step being edited. Header click = display-only sort (a row order, no copy); "Add as sort step" turns it into a real step |
77
+ | Parameters (right) | form of the step being added or edited, with a **live preview** of the first rows; Apply commits, Cancel / Esc discards |
78
+ | Columns (right, tab) | columns of the shown table (type, missing values, size) and statistics of the selected column |
79
+ | Code (bottom) | the generated script; the selected step's lines are highlighted |
80
+ | Messages (bottom, tab) | errors of failing steps (click: go to the step), loads, exports, log |
81
+ | Status bar | memory: frame cache / budget and process RSS; click for the cached steps and "Free memory" |
82
+
83
+ **Memory model.** Only the selected step and its inputs are *pinned* (kept in memory while
84
+ shown); every other computed table stays in the LRU cache until the budget (25 % of RAM by
85
+ default) needs the room or you free it. Views never copy a table: the data view reads windows
86
+ of the cached frame, previews hold only their first rows, the column statistics are computed
87
+ on a worker. Undo / redo recompute what they need.
88
+
89
+ **Keyboard shortcuts.**
90
+
91
+ | Keys | Action |
92
+ |---|---|
93
+ | Ctrl+Shift+P | command palette: every operation by name |
94
+ | Ctrl+E | edit the selected step (parameters + preview) |
95
+ | Esc | cancel the preview |
96
+ | F2 / Del (in the tree) | rename / delete the selected step (with its subtree) |
97
+ | Ctrl+Z / Ctrl+Shift+Z | undo / redo |
98
+ | Ctrl+N / Ctrl+O / Ctrl+S / Ctrl+Shift+S | new / open / save / save as project |
99
+ | Ctrl+Shift+O | open a data file |
100
+
101
+ The UI is available in English and German (View > Language, switches at runtime).
102
+
103
+ ## Engine example
104
+
105
+ ```python
106
+ from datacook.engine import Session
107
+ from datacook.engine.ops import missing, rows, sources
108
+
109
+ with Session() as session:
110
+ data = {"a": [3, None, 1], "b": [4, 5, 6]}
111
+ src = session.add(sources.InlineData.record(data=data), name="raw")
112
+ filled = session.add(missing.FillForward.record(), [src])
113
+ branch = session.add(rows.SortRows.record(by=["a"]), [filled])
114
+ other = session.add(rows.Head.record(n=2), [filled]) # a second branch
115
+
116
+ print(session.materialize(branch.id)) # computed on demand, cached
117
+ print(session.code()) # the script for the whole tree
118
+ session.update(filled.id, params=missing.FillForward.Params(limit=1))
119
+ # -> `filled`, `branch` and `other` are invalidated and recomputed on request
120
+ ```
121
+
122
+ `session.import_script(text)` parses a script back into nodes (statements it does not
123
+ recognise become "custom code" steps); `datacook.engine.project` saves and loads the tree as
124
+ JSON, and `datacook.engine.formats.FormatRegistry` maps file extensions to readers and
125
+ writers.
126
+
127
+ ## Development
128
+
129
+ ```bash
130
+ git clone https://github.com/phil65/datacook
131
+ cd datacook
132
+ uv sync --all-extras # Python 3.14
133
+ uv run pytest
134
+ uv run ruff check . && uv run ty check
135
+ ```
136
+
137
+ `uv run pytest` runs the app tests offscreen (`QT_QPA_PLATFORM=offscreen`), including a smoke
138
+ test of the whole window (`tests/app/test_smoke.py`). See [AGENTS.md](AGENTS.md) for the
139
+ layout and the rebuild status, [`src/datacook/app/README.md`](src/datacook/app/README.md) for
140
+ the app's internals. [`docs/feature-inventory.md`](docs/feature-inventory.md) lists every
141
+ feature of the old app (git tag `pre-rework`) and where it went in the rework.
@@ -0,0 +1,101 @@
1
+ # DataCook
2
+
3
+ DataCook is a desktop tool for exploring and transforming tables. Every operation you apply is
4
+ recorded as a step in a tree, so an analysis can be branched, replayed, saved as a project or
5
+ exported as a Python script (and the script can be edited and read back).
6
+
7
+ > **Status: being rebuilt** (phase 3 of the plan done: the new app). The new Qt app runs on
8
+ > a Qt-free engine (`datacook.engine`): a tree of typed operation records, frames computed
9
+ > on demand under a memory budget (pandas 3 with pyarrow dtypes), code generated from the
10
+ > records and parsed back. The op catalogue is a starter set (24 ops, basic readers and
11
+ > writers); porting the rest of the old catalogue in [`legacy/`](legacy/README.md) is next.
12
+
13
+ ## The app
14
+
15
+ ```bash
16
+ uv sync --all-extras
17
+ uv run datacook # or: uv run python -m datacook.app
18
+ uv run datacook project.datacook # open a project
19
+ uv run datacook data.csv # open a data file (reader dialog)
20
+ uv run python tools/demo_data.py demo # sample data + a demo project in ./demo
21
+ ```
22
+
23
+ **Concept.** A project is a tree of *steps*. A root step reads a file; every other step is one
24
+ operation (filter, rename, group, merge, ...) applied to its parent(s). Adding a step to a step
25
+ that already has children creates a *branch*; a merge takes a second table as its other input.
26
+ The steps are stored as typed records (operation + parameters), not as data: tables are
27
+ computed when you look at them and kept in a cache under a memory budget, so a long tree of a
28
+ large table does not cost a copy per step. The **code** of every step is generated from its
29
+ record; the whole tree (or the path to one step) exports as a plain pandas script.
30
+
31
+ **Docks** (all follow the selected step; View menu to show / hide them):
32
+
33
+ | Dock | What |
34
+ |---|---|
35
+ | Steps (left) | the tree: name, shape, size; badges for in memory / in use / computing / error. Right-click: rename, comment, branch, delete |
36
+ | Data (center) | the table of the selected step, or the preview of the step being edited. Header click = display-only sort (a row order, no copy); "Add as sort step" turns it into a real step |
37
+ | Parameters (right) | form of the step being added or edited, with a **live preview** of the first rows; Apply commits, Cancel / Esc discards |
38
+ | Columns (right, tab) | columns of the shown table (type, missing values, size) and statistics of the selected column |
39
+ | Code (bottom) | the generated script; the selected step's lines are highlighted |
40
+ | Messages (bottom, tab) | errors of failing steps (click: go to the step), loads, exports, log |
41
+ | Status bar | memory: frame cache / budget and process RSS; click for the cached steps and "Free memory" |
42
+
43
+ **Memory model.** Only the selected step and its inputs are *pinned* (kept in memory while
44
+ shown); every other computed table stays in the LRU cache until the budget (25 % of RAM by
45
+ default) needs the room or you free it. Views never copy a table: the data view reads windows
46
+ of the cached frame, previews hold only their first rows, the column statistics are computed
47
+ on a worker. Undo / redo recompute what they need.
48
+
49
+ **Keyboard shortcuts.**
50
+
51
+ | Keys | Action |
52
+ |---|---|
53
+ | Ctrl+Shift+P | command palette: every operation by name |
54
+ | Ctrl+E | edit the selected step (parameters + preview) |
55
+ | Esc | cancel the preview |
56
+ | F2 / Del (in the tree) | rename / delete the selected step (with its subtree) |
57
+ | Ctrl+Z / Ctrl+Shift+Z | undo / redo |
58
+ | Ctrl+N / Ctrl+O / Ctrl+S / Ctrl+Shift+S | new / open / save / save as project |
59
+ | Ctrl+Shift+O | open a data file |
60
+
61
+ The UI is available in English and German (View > Language, switches at runtime).
62
+
63
+ ## Engine example
64
+
65
+ ```python
66
+ from datacook.engine import Session
67
+ from datacook.engine.ops import missing, rows, sources
68
+
69
+ with Session() as session:
70
+ data = {"a": [3, None, 1], "b": [4, 5, 6]}
71
+ src = session.add(sources.InlineData.record(data=data), name="raw")
72
+ filled = session.add(missing.FillForward.record(), [src])
73
+ branch = session.add(rows.SortRows.record(by=["a"]), [filled])
74
+ other = session.add(rows.Head.record(n=2), [filled]) # a second branch
75
+
76
+ print(session.materialize(branch.id)) # computed on demand, cached
77
+ print(session.code()) # the script for the whole tree
78
+ session.update(filled.id, params=missing.FillForward.Params(limit=1))
79
+ # -> `filled`, `branch` and `other` are invalidated and recomputed on request
80
+ ```
81
+
82
+ `session.import_script(text)` parses a script back into nodes (statements it does not
83
+ recognise become "custom code" steps); `datacook.engine.project` saves and loads the tree as
84
+ JSON, and `datacook.engine.formats.FormatRegistry` maps file extensions to readers and
85
+ writers.
86
+
87
+ ## Development
88
+
89
+ ```bash
90
+ git clone https://github.com/phil65/datacook
91
+ cd datacook
92
+ uv sync --all-extras # Python 3.14
93
+ uv run pytest
94
+ uv run ruff check . && uv run ty check
95
+ ```
96
+
97
+ `uv run pytest` runs the app tests offscreen (`QT_QPA_PLATFORM=offscreen`), including a smoke
98
+ test of the whole window (`tests/app/test_smoke.py`). See [AGENTS.md](AGENTS.md) for the
99
+ layout and the rebuild status, [`src/datacook/app/README.md`](src/datacook/app/README.md) for
100
+ the app's internals. [`docs/feature-inventory.md`](docs/feature-inventory.md) lists every
101
+ feature of the old app (git tag `pre-rework`) and where it went in the rework.
@@ -0,0 +1,431 @@
1
+ [project]
2
+ name = "datacook-app"
3
+ version = "2.13.0"
4
+ description = "Qt desktop tool for pandas data analysis that records every transformation as replayable Python code"
5
+ readme = "README.md"
6
+ requires-python = ">=3.14"
7
+ license = "MIT"
8
+ license-files = ["LICENSE"]
9
+ keywords = [
10
+ "data analysis",
11
+ "data science",
12
+ "dataframe",
13
+ "gui",
14
+ "pandas",
15
+ "qt",
16
+ "statistics",
17
+ ]
18
+ classifiers = [
19
+ "Development Status :: 3 - Alpha",
20
+ "Environment :: X11 Applications :: Qt",
21
+ "Intended Audience :: Science/Research",
22
+ "Operating System :: OS Independent",
23
+ "Programming Language :: Python",
24
+ "Programming Language :: Python :: 3",
25
+ "Programming Language :: Python :: 3 :: Only",
26
+ "Topic :: Scientific/Engineering :: Information Analysis",
27
+ ]
28
+ dependencies = [
29
+ "PySide6",
30
+ "cutepandas>=0.6.2",
31
+ "epregistry>=2.0.5",
32
+ "numpy",
33
+ "pandas",
34
+ "platformdirs",
35
+ "prettyqt>=1.65.0",
36
+ "psutil>=7.2.2",
37
+ "pyarrow>=26.0.1",
38
+ "pydantic",
39
+ ]
40
+
41
+ [[project.authors]]
42
+ name = "Philipp Temminghoff"
43
+ email = "philipptemminghoff@gmail.com"
44
+
45
+ [[project.maintainers]]
46
+ name = "Philipp Temminghoff"
47
+ email = "philipptemminghoff@gmail.com"
48
+
49
+ [project.urls]
50
+ "Code coverage" = "https://app.codecov.io/gh/phil65/datacook"
51
+ Documentation = "https://phil65.github.io/datacook/"
52
+ Issues = "https://github.com/phil65/datacook/issues"
53
+ Source = "https://github.com/phil65/datacook"
54
+
55
+ [project.gui-scripts]
56
+ datacook = "datacook.app:main"
57
+
58
+ [project.entry-points."datacook.ops"]
59
+ read_csv = "datacook.engine.ops.sources:ReadCsv"
60
+ read_parquet = "datacook.engine.ops.sources:ReadParquet"
61
+ read_feather = "datacook.engine.ops.sources:ReadFeather"
62
+ read_json = "datacook.engine.ops.sources:ReadJson"
63
+ read_excel = "datacook.engine.ops.sources:ReadExcel"
64
+ read_clipboard = "datacook.engine.ops.sources:ReadClipboard"
65
+ read_sqlite = "datacook.engine.ops.sources:ReadSqlite"
66
+ inline_data = "datacook.engine.ops.sources:InlineData"
67
+ select_columns = "datacook.engine.ops.columns:SelectColumns"
68
+ drop_columns = "datacook.engine.ops.columns:DropColumns"
69
+ rename_columns = "datacook.engine.ops.columns:RenameColumns"
70
+ astype = "datacook.engine.ops.columns:ChangeDtypes"
71
+ move_columns = "datacook.engine.ops.columns:MoveColumns"
72
+ sort_columns = "datacook.engine.ops.columns:SortColumns"
73
+ add_prefix = "datacook.engine.ops.columns:AddPrefix"
74
+ add_suffix = "datacook.engine.ops.columns:AddSuffix"
75
+ select_dtypes = "datacook.engine.ops.columns:SelectDtypes"
76
+ convert_dtypes = "datacook.engine.ops.columns:ConvertDtypes"
77
+ downcast = "datacook.engine.ops.columns:Downcast"
78
+ duplicate_columns = "datacook.engine.ops.columns:DuplicateColumns"
79
+ combine_columns = "datacook.engine.ops.columns:CombineColumns"
80
+ calculate_columns = "datacook.engine.ops.columns:CalculateColumns"
81
+ filter_rows = "datacook.engine.ops.rows:FilterRows"
82
+ sort_rows = "datacook.engine.ops.rows:SortRows"
83
+ head = "datacook.engine.ops.rows:Head"
84
+ sample = "datacook.engine.ops.rows:Sample"
85
+ drop_duplicates = "datacook.engine.ops.rows:DropDuplicates"
86
+ tail = "datacook.engine.ops.rows:Tail"
87
+ nlargest = "datacook.engine.ops.rows:NLargest"
88
+ nsmallest = "datacook.engine.ops.rows:NSmallest"
89
+ slice_rows = "datacook.engine.ops.rows:SliceRows"
90
+ filter_isin = "datacook.engine.ops.rows:FilterIsIn"
91
+ reset_index = "datacook.engine.ops.rows:ResetIndex"
92
+ fill_missing = "datacook.engine.ops.missing:FillMissing"
93
+ ffill = "datacook.engine.ops.missing:FillForward"
94
+ bfill = "datacook.engine.ops.missing:FillBackward"
95
+ drop_missing = "datacook.engine.ops.missing:DropMissing"
96
+ fill_statistic = "datacook.engine.ops.missing:FillWithStatistic"
97
+ interpolate = "datacook.engine.ops.missing:Interpolate"
98
+ drop_missing_columns = "datacook.engine.ops.missing:DropMissingColumns"
99
+ isna = "datacook.engine.ops.missing:IsMissing"
100
+ filter_missing = "datacook.engine.ops.missing:FilterMissing"
101
+ nan_to_missing = "datacook.engine.ops.missing:NanToMissing"
102
+ abs = "datacook.engine.ops.values:Abs"
103
+ clip = "datacook.engine.ops.values:Clip"
104
+ replace_values = "datacook.engine.ops.values:ReplaceValues"
105
+ cat_add_categories = "datacook.engine.ops.categorical:AddCategories"
106
+ cat_remove_categories = "datacook.engine.ops.categorical:RemoveCategories"
107
+ cat_rename_categories = "datacook.engine.ops.categorical:RenameCategories"
108
+ cat_reorder_categories = "datacook.engine.ops.categorical:ReorderCategories"
109
+ cat_set_categories = "datacook.engine.ops.categorical:SetCategories"
110
+ cat_as_ordered = "datacook.engine.ops.categorical:AsOrdered"
111
+ cat_as_unordered = "datacook.engine.ops.categorical:AsUnordered"
112
+ cat_remove_unused = "datacook.engine.ops.categorical:RemoveUnusedCategories"
113
+ merge = "datacook.engine.ops.combine:Merge"
114
+ groupby_aggregate = "datacook.engine.ops.combine:GroupByAggregate"
115
+ concat = "datacook.engine.ops.combine:Concat"
116
+ unpivot = "datacook.engine.ops.reshape:Unpivot"
117
+ pivot = "datacook.engine.ops.reshape:Pivot"
118
+ crosstab = "datacook.engine.ops.reshape:Crosstab"
119
+ transpose = "datacook.engine.ops.reshape:Transpose"
120
+ describe = "datacook.engine.ops.stats:Describe"
121
+ var = "datacook.engine.ops.stats:Variance"
122
+ cov = "datacook.engine.ops.stats:Covariance"
123
+ corr = "datacook.engine.ops.stats:Correlation"
124
+ corrwith = "datacook.engine.ops.stats:CorrelationWith"
125
+ mode = "datacook.engine.ops.stats:Mode"
126
+ value_counts = "datacook.engine.ops.stats:ValueCounts"
127
+ rank = "datacook.engine.ops.stats:Rank"
128
+ cut = "datacook.engine.ops.stats:Bin"
129
+ fit_transform = "datacook.engine.ops.estimators:FitTransform"
130
+ pca = "datacook.engine.ops.estimators:PCA"
131
+ cluster = "datacook.engine.ops.estimators:Cluster"
132
+ apply_model = "datacook.engine.ops.estimators:ApplyModel"
133
+ custom_code = "datacook.engine.ops.code:CustomCode"
134
+ detect_gaps = "datacook.engine.ops.timeseries:DetectGaps"
135
+ diff = "datacook.engine.ops.timeseries:Diff"
136
+ dt_parts = "datacook.engine.ops.dates:DatetimeParts"
137
+ dt_round = "datacook.engine.ops.dates:RoundTime"
138
+ dt_strftime = "datacook.engine.ops.dates:Strftime"
139
+ expanding = "datacook.engine.ops.timeseries:Expanding"
140
+ filter_text = "datacook.engine.ops.strings:FilterText"
141
+ float_year_to_datetime = "datacook.engine.ops.dates:FloatYearToDatetime"
142
+ pct_change = "datacook.engine.ops.timeseries:PctChange"
143
+ resample = "datacook.engine.ops.timeseries:Resample"
144
+ rolling = "datacook.engine.ops.timeseries:Rolling"
145
+ seconds_since_start = "datacook.engine.ops.timeseries:SecondsSinceStart"
146
+ set_time_column = "datacook.engine.ops.timeseries:SetTimeColumn"
147
+ shift = "datacook.engine.ops.timeseries:Shift"
148
+ str_case = "datacook.engine.ops.strings:ChangeCase"
149
+ str_extract = "datacook.engine.ops.strings:Extract"
150
+ str_len = "datacook.engine.ops.strings:Length"
151
+ str_pad = "datacook.engine.ops.strings:Pad"
152
+ str_repeat = "datacook.engine.ops.strings:Repeat"
153
+ str_replace = "datacook.engine.ops.strings:Replace"
154
+ str_slice = "datacook.engine.ops.strings:Slice"
155
+ str_split = "datacook.engine.ops.strings:Split"
156
+ str_strip = "datacook.engine.ops.strings:Strip"
157
+ str_test = "datacook.engine.ops.strings:Test"
158
+ to_datetime = "datacook.engine.ops.dates:ToDatetime"
159
+ tolerance_bands = "datacook.engine.ops.timeseries:ToleranceBands"
160
+ tz_convert = "datacook.engine.ops.dates:TzConvert"
161
+ tz_localize = "datacook.engine.ops.dates:TzLocalize"
162
+ upsample = "datacook.engine.ops.timeseries:Upsample"
163
+
164
+ [project.entry-points."datacook.writers"]
165
+ csv = "datacook.engine.formats:WriteCsv"
166
+ parquet = "datacook.engine.formats:WriteParquet"
167
+ excel = "datacook.engine.formats:WriteExcel"
168
+ script = "datacook.engine.formats:WriteScript"
169
+ project = "datacook.engine.formats:WriteProject"
170
+
171
+ [project.optional-dependencies]
172
+ excel = ["openpyxl>=3.1.5"]
173
+ sklearn = ["scikit-learn>=1.9"]
174
+
175
+ [dependency-groups]
176
+ dev = [
177
+ "deptry",
178
+ "devtools",
179
+ "pyreadline3",
180
+ "pytest",
181
+ "pytest-cov",
182
+ "pytest-qt",
183
+ ]
184
+ benchmark = ["pyinstrument"]
185
+ docs = [
186
+ "mkdocstrings[python]",
187
+ "mknodes>=4.0.0",
188
+ ]
189
+ lint = [
190
+ "ruff==0.17.6",
191
+ "ty==0.0.110",
192
+ ]
193
+
194
+ [build-system]
195
+ requires = ["uv_build>=0.8.22"]
196
+ build-backend = "uv_build"
197
+
198
+ [tool.coverage.report]
199
+ exclude_lines = [
200
+ "pragma: no cover",
201
+ "if TYPE_CHECKING:",
202
+ "@overload",
203
+ "except ImportError",
204
+ 'if __name__ == "__main__":',
205
+ ]
206
+
207
+ [tool.mknodes]
208
+ allowed-commit-types = [
209
+ "fix",
210
+ "feat",
211
+ "refactor",
212
+ "docs",
213
+ "test",
214
+ "build",
215
+ "chore",
216
+ ]
217
+ docstring-style = "google"
218
+
219
+ [tool.pyright]
220
+ venvPath = "."
221
+ venv = ".venv"
222
+ pythonVersion = "3.14"
223
+ pythonPlatform = "All"
224
+ typeCheckingMode = "basic"
225
+ deprecateTypingAliases = true
226
+ reportMissingTypeStubs = false
227
+ reportUnusedCallResult = false
228
+ reportUnknownVariableType = false
229
+ reportAny = false
230
+ reportImplicitOverride = false
231
+ reportUnusedFunction = false
232
+ reportImplicitStringConcatenation = false
233
+ reportIgnoreCommentWithoutRule = false
234
+ reportUnannotatedClassAttribute = false
235
+ reportSelfClsParameterName = false
236
+ reportPrivateImportUsage = false
237
+
238
+ [tool.pytest]
239
+ addopts = [
240
+ "-p",
241
+ "no:logfire",
242
+ ]
243
+ log_cli = true
244
+ log_date_format = "%Y-%m-%d %H:%M:%S"
245
+ log_format = "%(asctime)s %(levelname)s %(message)s"
246
+ markers = ["slow: long-running scenario, opt-in via an environment variable (not in CI)"]
247
+ minversion = "9.0"
248
+ norecursedirs = [
249
+ "dist",
250
+ "legacy",
251
+ ]
252
+ testpaths = ["tests/"]
253
+ asyncio_mode = "auto"
254
+ qt_api = "pyside6"
255
+
256
+ [tool.ruff]
257
+ line-length = 100
258
+ extend-exclude = [
259
+ "docs",
260
+ "legacy",
261
+ ]
262
+ force-exclude = true
263
+ target-version = "py314"
264
+
265
+ [tool.ruff.lint]
266
+ select = [
267
+ "A",
268
+ "B",
269
+ "BLE",
270
+ "C",
271
+ "C4",
272
+ "COM",
273
+ "D",
274
+ "E",
275
+ "EM",
276
+ "EXE",
277
+ "F",
278
+ "FLY",
279
+ "G",
280
+ "I",
281
+ "ICN",
282
+ "INP",
283
+ "INT",
284
+ "ISC",
285
+ "N",
286
+ "PERF",
287
+ "PIE",
288
+ "PLE",
289
+ "PLC",
290
+ "PLR",
291
+ "PT",
292
+ "PTH",
293
+ "PYI",
294
+ "Q",
295
+ "RET",
296
+ "RSE",
297
+ "RUF",
298
+ "SIM",
299
+ "SLF",
300
+ "SLOT",
301
+ "T10",
302
+ "TC",
303
+ "TID",
304
+ "TRY",
305
+ "UP",
306
+ "W",
307
+ "YTT",
308
+ ]
309
+ ignore = [
310
+ "C408",
311
+ "B905",
312
+ "C901",
313
+ "COM812",
314
+ "D100",
315
+ "D101",
316
+ "D102",
317
+ "D103",
318
+ "D104",
319
+ "D105",
320
+ "D106",
321
+ "D107",
322
+ "D203",
323
+ "D204",
324
+ "D213",
325
+ "D215",
326
+ "D400",
327
+ "D401",
328
+ "D404",
329
+ "D406",
330
+ "D407",
331
+ "D408",
332
+ "D409",
333
+ "D413",
334
+ "EM101",
335
+ "EM102",
336
+ "ISC001",
337
+ "PLC0415",
338
+ "PLR0912",
339
+ "PLR0913",
340
+ "PLR0915",
341
+ "PLR0917",
342
+ "SLF001",
343
+ "TRY003",
344
+ "TC006",
345
+ ]
346
+
347
+ [tool.ruff.lint.flake8-quotes]
348
+ docstring-quotes = "double"
349
+
350
+ [tool.ruff.lint.flake8-type-checking]
351
+ runtime-evaluated-base-classes = [
352
+ "datacook.engine.ops.base.Params",
353
+ "pydantic.BaseModel",
354
+ "sqlalchemy.orm.DeclarativeBase",
355
+ "schemez.Schema",
356
+ "sqlmodel.SQLModel",
357
+ ]
358
+ runtime-evaluated-decorators = [
359
+ "pydantic.validate_call",
360
+ "fastapi.FastAPI.get",
361
+ "fastapi.FastAPI.post",
362
+ "fastmcp.FastMCP.tool",
363
+ "typer.Typer.command",
364
+ ]
365
+
366
+ [tool.ruff.lint.flake8-tidy-imports.banned-api."__future__.annotations"]
367
+ msg = "Python 3.14+ evaluates annotations lazily (PEP 649); drop the import."
368
+
369
+ [tool.ruff.lint.isort]
370
+ lines-after-imports = 2
371
+ force-sort-within-sections = true
372
+ combine-as-imports = true
373
+
374
+ [tool.ruff.lint.mccabe]
375
+ max-complexity = 15
376
+
377
+ [tool.ruff.lint.per-file-ignores]
378
+ "__init__.py" = [
379
+ "E402",
380
+ "I001",
381
+ ]
382
+ "scripts/*" = ["INP001"]
383
+ "tools/*" = ["INP001"]
384
+ "*tests/*" = [
385
+ "D100",
386
+ "PLR2004",
387
+ ]
388
+
389
+ [tool.ruff.format]
390
+ preview = true
391
+
392
+ [tool.ty.environment]
393
+ python-version = "3.14"
394
+ python-platform = "all"
395
+
396
+ [tool.ty.src]
397
+ include = ["src"]
398
+ exclude = ["legacy"]
399
+
400
+ [tool.ty.analysis]
401
+ allowed-unresolved-imports = []
402
+
403
+ [tool.ty.rules]
404
+ incompatible-mutable-override = "ignore"
405
+ incompatible-attribute-override = "ignore"
406
+
407
+ [tool.uv]
408
+ default-groups = [
409
+ "dev",
410
+ "lint",
411
+ "docs",
412
+ ]
413
+
414
+ [tool.uv.build-backend]
415
+ module-name = "datacook"
416
+ wheel-exclude = [
417
+ ".mypy_cache/**",
418
+ "__pycache__/**",
419
+ "*.pyc",
420
+ "*.pyo",
421
+ ".pytest_cache/**",
422
+ ".ruff_cache/**",
423
+ ]
424
+ source-exclude = [
425
+ ".mypy_cache/**",
426
+ "__pycache__/**",
427
+ "*.pyc",
428
+ "*.pyo",
429
+ ".pytest_cache/**",
430
+ ".ruff_cache/**",
431
+ ]