Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
d606d36
TEMP.
tobiasraabe Mar 12, 2024
d528796
Merge branch 'main' into typed-settings-v2
tobiasraabe Mar 20, 2024
31c8631
Progress on build command.
tobiasraabe Mar 23, 2024
639b603
FIx.
tobiasraabe Mar 23, 2024
35ba3fb
Merge remote-tracking branch 'origin/main' into typed-settings-v2
tobiasraabe Mar 23, 2024
986f364
temp commit.
tobiasraabe Mar 24, 2024
d51d043
fix.
tobiasraabe Mar 24, 2024
a47f536
Merge branch 'main' into typed-settings-v2
tobiasraabe Apr 10, 2024
c76d127
fix.
tobiasraabe Apr 10, 2024
c643eb0
fix issue with base class.
tobiasraabe Apr 10, 2024
dd08ab9
Fix all type issues preliminary.
tobiasraabe Apr 20, 2024
6576671
One settings object for each command.
tobiasraabe Apr 21, 2024
f7ba983
Preliminary solution for build function.
tobiasraabe Apr 21, 2024
6070085
Rename config_file to config.
tobiasraabe Apr 21, 2024
f5238da
fix.
tobiasraabe Apr 21, 2024
64f9898
Merge branch 'main' into typed-settings-v2
tobiasraabe Apr 21, 2024
812779c
Temp
tobiasraabe Apr 23, 2024
756431c
Merge branch 'main' into typed-settings-v2
tobiasraabe May 8, 2024
78e4ebc
fix some issues.
tobiasraabe May 8, 2024
a61cd7d
[pre-commit.ci] auto fixes from pre-commit.com hooks
pre-commit-ci[bot] May 8, 2024
f74f0a3
Filter also context.
tobiasraabe May 14, 2024
a0091dc
Merge branch 'typed-settings-v2' of https://github.com/pytask-dev/pyt…
tobiasraabe May 14, 2024
2be45e2
Merge remote-tracking branch 'origin/main' into typed-settings-v2
tobiasraabe May 14, 2024
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
1 change: 1 addition & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ repos:
rev: v2.0.0
hooks:
- id: refurb
additional_dependencies: [typed-settings]
- repo: https://github.com/executablebooks/mdformat
rev: 0.7.17
hooks:
Expand Down
1 change: 1 addition & 0 deletions docs/source/changes.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ releases are available on [PyPI](https://pypi.org/project/pytask) and
- {pull}`579` fixes an interaction with `--pdb` and `--trace` and task that return. The
debugging modes swallowed the return and `None` was returned. Closes {issue}`574`.
- {pull}`581` simplifies the code for tracebacks and unpublishes some utility functions.
- {pull}`582` use typed-settings to parse configuration files and create the CLI.
- {pull}`586` improves linting.
- {pull}`587` improves typing of `capture.py`.
- {pull}`588` resets class variables of `ExecutionReport` and `Traceback`.
Expand Down
1 change: 0 additions & 1 deletion docs/source/reference_guides/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ pytask offers the following functionalities.
```{eval-rst}
.. autoclass:: pytask.ColoredCommand
.. autoclass:: pytask.ColoredGroup
.. autoclass:: pytask.EnumChoice
```

## Compatibility
Expand Down
17 changes: 0 additions & 17 deletions docs/source/reference_guides/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,23 +42,6 @@ are welcome to also support macOS.

````

````{confval} database_url

pytask uses a database to keep track of tasks, products, and dependencies over runs. By
default, it will create an SQLite database in the project's root directory called
`.pytask/pytask.sqlite3`. If you want to use a different name or a different dialect
[supported by sqlalchemy](https://docs.sqlalchemy.org/en/latest/core/engines.html#backend-specific-urls),
use either {option}`pytask build --database-url` or `database_url` in the config.

```toml
database_url = "sqlite:///.pytask/pytask.sqlite3"
```

Relative paths for SQLite databases are interpreted as either relative to the
configuration file or the root directory.

````

````{confval} editor_url_scheme

Depending on your terminal, pytask is able to turn task ids into clickable links to the
Expand Down
6 changes: 3 additions & 3 deletions docs/source/tutorials/visualizing_the_dag.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ To visualize the {term}`DAG` of the project, first, install
[graphviz](https://graphviz.org/). For example, you can both install with conda

```console
$ conda install -c conda-forge pygraphviz
conda install -c conda-forge pygraphviz
```

After that, pytask offers two interfaces to visualize your project's {term}`DAG`.
Expand All @@ -15,7 +15,7 @@ After that, pytask offers two interfaces to visualize your project's {term}`DAG`
You can quickly create a visualization with this command.

```console
$ pytask dag
pytask dag
```

It generates a `dag.pdf` in the current working directory.
Expand All @@ -26,7 +26,7 @@ file-ending. Select any format supported by
[graphviz](https://graphviz.org/docs/outputs/).

```console
$ pytask dag -o dag.png
pytask dag -o dag.png
```

You can change the graph's layout by using the {option}`pytask dag --layout` option. Its
Expand Down
20 changes: 16 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ dependencies = [
"sqlalchemy>=2",
'tomli>=1; python_version < "3.11"',
'typing-extensions; python_version < "3.9"',
"typed-settings[option-groups]",
"universal-pathlib>=0.2.2",
]

Expand Down Expand Up @@ -113,6 +114,9 @@ source = "vcs"
[tool.hatch.metadata]
allow-direct-references = true

[tool.setuptools_scm]
version_file = "src/_pytask/_version.py"

[tool.ruff]
target-version = "py38"
fix = true
Expand Down Expand Up @@ -184,6 +188,7 @@ disallow_untyped_defs = true
no_implicit_optional = true
warn_redundant_casts = true
warn_unused_ignores = true
plugins = ["typed_settings.mypy"]

[[tool.mypy.overrides]]
module = "tests.*"
Expand All @@ -194,14 +199,14 @@ ignore_errors = true
module = ["click_default_group", "networkx"]
ignore_missing_imports = true

[[tool.mypy.overrides]]
module = ["_pytask.coiled_utils"]
disable_error_code = ["import-not-found"]

[[tool.mypy.overrides]]
module = ["_pytask.hookspecs"]
disable_error_code = ["empty-body"]

[[tool.mypy.overrides]]
module = ["_pytask.coiled_utils"]
disable_error_code = ["import-untyped", "import-not-found"]

[tool.codespell]
skip = "*.js,*/termynal.css"

Expand All @@ -219,3 +224,10 @@ exclude_also = [
[tool.mdformat]
wrap = 88
end_of_line = "keep"


[tool.pytask]
debug_pytask = 1

[tool.pytask.ini_options]
capture = "all"
Loading