Skip to content

Commit c7fa11b

Browse files
committed
add hint in quickstart to look at dac-example-energy for a usage example
1 parent d81aadd commit c7fa11b

3 files changed

Lines changed: 56 additions & 38 deletions

File tree

.pre-commit-config.yaml

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -12,19 +12,26 @@ repos:
1212
- id: check-json
1313
- id: check-toml
1414
- id: check-yaml
15-
- repo: https://github.com/pre-commit/mirrors-mypy
16-
rev: v1.15.0
17-
hooks:
18-
- id: mypy
19-
exclude: test/data/schema/wrong_syntax.py
20-
- repo: https://github.com/dosisod/refurb
21-
rev: v2.0.0
15+
- repo: https://github.com/executablebooks/mdformat
16+
rev: 0.7.22
2217
hooks:
23-
- id: refurb
24-
exclude: test/data/schema/wrong_syntax.py
18+
- id: mdformat
19+
args: ["--wrap", "120"]
20+
additional_dependencies:
21+
- mdformat-tables
2522
- repo: https://github.com/astral-sh/ruff-pre-commit
2623
rev: v0.11.4
2724
hooks:
2825
- id: ruff
2926
args: [--fix, --exit-non-zero-on-fix]
3027
exclude: test/data/schema/wrong_syntax.py
28+
- repo: https://github.com/dosisod/refurb
29+
rev: v2.0.0
30+
hooks:
31+
- id: refurb
32+
exclude: test/data/schema/wrong_syntax.py
33+
- repo: https://github.com/pre-commit/mirrors-mypy
34+
rev: v1.15.0
35+
hooks:
36+
- id: mypy
37+
exclude: test/data/schema/wrong_syntax.py

CHANGELOG.md

Lines changed: 30 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -2,77 +2,84 @@
22

33
All notable changes to this project will be documented in this file.
44

5-
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6-
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
5+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to
6+
[Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

88
**IMPORTANT**: Currently the project is in the initial development phase, this is why releases are marked as `0.z.y`.
99
(following [semantic versioning 2.0.0](https://semver.org/): "Major version zero (0.y.z) is for initial development.
10-
Anything MAY change at any time. The public API SHOULD NOT be considered stable.").
11-
While in this phase, we will denote breaking changes with a minor increase.
10+
Anything MAY change at any time. The public API SHOULD NOT be considered stable."). While in this phase, we will denote
11+
breaking changes with a minor increase.
1212

1313
## 0.4.3
1414

1515
### Added
1616

17-
* Added support for python `3.12` and `3.13`
17+
- Added support for python `3.12` and `3.13`
1818

1919
### Changed
2020

21-
* Bump all dependencies to the latest version and introduce necessary adaptation in the source code (affecting only `dac info`):
22-
* `build~=0.9` -> `build~=1.2`
23-
* `toml~=0.10` -> `toml~=0.10.2`
24-
* `typer[all]~=0.7` -> `typer~=0.15.2`
25-
* `wheel~=0.38` -> `wheel~=0.45`
26-
* Prevent installation with python > `3.13`
21+
- Bump all dependencies to the latest version and introduce necessary adaptation in the source code (affecting only
22+
`dac info`):
23+
- `build~=0.9` -> `build~=1.2`
24+
- `toml~=0.10` -> `toml~=0.10.2`
25+
- `typer[all]~=0.7` -> `typer~=0.15.2`
26+
- `wheel~=0.38` -> `wheel~=0.45`
27+
- Prevent installation with python > `3.13`
2728

2829
## 0.4.2
2930

3031
### Fixed
3132

32-
* `dac next-version` is able to find the existing version of a package irrespectively of the use of `-` or `_` as a separator.
33+
- `dac next-version` is able to find the existing version of a package irrespectively of the use of `-` or `_` as a
34+
separator.
3335

3436
## 0.4.1
3537

3638
### Added
3739

38-
* Introduce `dac next-version` command, that allows to find the next minor release for a given python package and (optionally) a given major version.
40+
- Introduce `dac next-version` command, that allows to find the next minor release for a given python package and
41+
(optionally) a given major version.
3942

4043
## 0.4.0
4144

4245
### Changed
4346

44-
* The `load` function in `load.py` can contain optional arguments. Previously no arguments were allowed.
45-
* `load.py` and `schema.py` are publicly accessible under `dac_pkg_name.load` and `dac_pkg_name.schema` respectively. Previously they were marked as private modules, under `dac_pkg_name._load` and `dac_pkg_name._schema`.
46-
* `Schema` does not have to be a `pandera.DataFrameModel` anymore, but any class that implements a `validate` method (see the `_input.interface.Validator` protocol).
47-
* `dac` does not rely on [`pydantic`](https://pypi.org/project/pydantic/) anymore, and uses [`dataclass`](https://docs.python.org/3/library/dataclasses.html#) instead.
48-
Changes affect `PackConfig` and `PyProjectConfig`.
47+
- The `load` function in `load.py` can contain optional arguments. Previously no arguments were allowed.
48+
- `load.py` and `schema.py` are publicly accessible under `dac_pkg_name.load` and `dac_pkg_name.schema` respectively.
49+
Previously they were marked as private modules, under `dac_pkg_name._load` and `dac_pkg_name._schema`.
50+
- `Schema` does not have to be a `pandera.DataFrameModel` anymore, but any class that implements a `validate` method
51+
(see the `_input.interface.Validator` protocol).
52+
- `dac` does not rely on [`pydantic`](https://pypi.org/project/pydantic/) anymore, and uses
53+
[`dataclass`](https://docs.python.org/3/library/dataclasses.html#) instead. Changes affect `PackConfig` and
54+
`PyProjectConfig`.
4955

5056
## 0.3.3
5157

5258
### Fixed
5359

54-
* Cleanup
60+
- Cleanup
5561

5662
## 0.3.2
5763

5864
### Changed
5965

60-
* Extend compatibility to pydantic v1. Now `dac` works with both v1 and v2 of pydantic
66+
- Extend compatibility to pydantic v1. Now `dac` works with both v1 and v2 of pydantic
6167

6268
## 0.3.1
6369

6470
### Changed
6571

66-
* Update code to be compatible with pydantic v2 (no retro-compatibility with v1)
72+
- Update code to be compatible with pydantic v2 (no retro-compatibility with v1)
6773

6874
## 0.3.0
6975

7076
### Changed
7177

72-
* Dependencies passed in CLI `--pkg-dependencies` or `PyProjectConfig` must be separated by `;` or newline (previously was `,` or newline)
78+
- Dependencies passed in CLI `--pkg-dependencies` or `PyProjectConfig` must be separated by `;` or newline (previously
79+
was `,` or newline)
7380

7481
## 0.2.0
7582

7683
### Added
7784

78-
* First release of `dac`
85+
- First release of `dac`

README.md

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66

77
**IMPORTANT**: Currently the project is in the initial development phase, this is why releases are marked as `0.z.y`.
88
(following [semantic versioning 2.0.0](https://semver.org/): "Major version zero (0.y.z) is for initial development.
9-
Anything MAY change at any time. The public API SHOULD NOT be considered stable.").
10-
While in this phase, we will denote breaking changes with a minor increase.
9+
Anything MAY change at any time. The public API SHOULD NOT be considered stable."). While in this phase, we will denote
10+
breaking changes with a minor increase.
1111

1212
## Quickstart
1313

@@ -18,33 +18,37 @@ python -m pip install dac
1818
```
1919

2020
Then use the integrated help to find out its functionalities
21+
2122
```sh
2223
dac --help
2324
```
2425

26+
If you want to see a usage example, you can have a look at how `dac` is used to build the `dac-example-energy` DaC
27+
python package [here](https://gitlab.com/data-as-code/energy-dac-example) (look at `.gitlab-ci.yml`).
28+
2529
## Setup development environment (for contributors only)
2630

27-
* Create a virtual environment and activate it
31+
- Create a virtual environment and activate it
2832

2933
```shell
3034
python -m venv venv
3135
. venv/bin/activate
3236
```
3337

34-
* Install the developer dependencies
38+
- Install the developer dependencies
3539

3640
```shell
3741
python -m pip install -U pip wheel setuptools
3842
python -m pip install -r requirements-dev.txt
3943
```
4044

41-
* Enable the pre-commits
45+
- Enable the pre-commits
4246

4347
```shell
4448
pre-commit install
4549
```
4650

47-
* To run all the tests
51+
- To run all the tests
4852

4953
```shell
5054
pytest --run-slow

0 commit comments

Comments
 (0)