Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Markdown pre-commit checks #329

Merged
merged 6 commits into from
Jan 3, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
22 changes: 22 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,30 @@ repos:
- id: detect-private-key
- id: detect-aws-credentials
args: [ "--allow-missing-credentials" ]

- repo: https://github.com/psf/black
rev: 24.10.0
hooks:
- id: black
args: [ "--config", "./pyproject.toml" ]

- repo: https://github.com/codespell-project/codespell
rev: v2.2.4
hooks:
- id: codespell
exclude: tests/fixtures/mydocfile.md

- repo: https://github.com/igorshubovych/markdownlint-cli
rev: v0.41.0
hooks:
- id: markdownlint
args:
- "--disable=MD013" # disable line length
- "--disable=MD024" # disable multiple headings with the same content (CHANGELOG)
- "--disable=MD033" # disable no inline html (needed for analytics dead pixel)

- repo: https://github.com/tcort/markdown-link-check
rev: v3.13.6
hooks:
- id: markdown-link-check
args: [-q]
101 changes: 100 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# Changelog

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

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
Expand Down Expand Up @@ -41,6 +42,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [0.20.0] - 2024-10-22

### Added

- Support using envvar in config YAML by @tatiana in #236
- **Callback improvements**
- Support installed code via python callable string by @john-drews in #221
Expand All @@ -53,9 +55,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Support telemetry during DAG parsing emitting data to Scarf by @tatiana in #250.

### Fixed

- Build DAGs when there is an invalid YAML in the DAGs folder by @quydx and @tatiana in #184

### Others

- Development tools
- Fix make docker-run by @pankajkoti in #249
- Add vim dot files to .gitignore by @tatiana in #228
Expand Down Expand Up @@ -96,193 +100,288 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Remove duplicated operator in `README.md` by @brair in #263

### Breaking changes

- Removed support for Python 3.7
- The license was changed from MIT to Apache 2.0


## [0.19.0] - 2023-07-19

### Added

- Support for Airflow Datasets (data-aware scheduling)
- Support for inherited Operators

## [0.18.1] - 2023-04-28

### Fixed

- Set default value for `render_template_as_native_obj` to False

## [0.18.0] - 2023-04-11

### Added

- Support for dynamic task mapping
- Support for `render_template_as_native_obj`
- Support for `template_searchpath`

## [0.17.3] - 2023-03-27

### Added

- dag-factory specific `Exceptions` with more meaningful names

### Fixed

- Reverts allowing inheritance of `KubernetesPodOperator`
- Now passing CI for lint check

## [0.17.2] - 2023-03-26

### Changed

- Allow inheritance of `KubernetesPodOperator`

## [0.17.1] - 2023-01-21

### Changed

- Changed imports to support Kubernetes Provider > 5.0.0

## [0.17.0] - 2022-12-06

### Added

- Adds `sla_secs` in `default_args` to convert seconds to `timedelta` obj

### Changed

- Changed deprecated imports to support Airflow 2.5
- Removed support for Python 3.6

## [0.16.0] - 2022-11-13

### Added

- Function to scan recursively for YAML DAGs

### Changed

- Changed deprecated imports to support Airflow 2.4+

## [0.15.0] - 2022-09-09

### Added

- Support for string concatenation of variables in YAML

## [0.14.0] - 2022-08-22

### Added

- Cast `on_retry_callback` from `default_args` to `Callable`

## [0.13.0] - 2022-05-27

### Added

- Add support for custom `timetable`
- Add support for `python_callable_file` for `PythonSensor`

## [0.12.0] - 2022-02-07

### Added

- Allow `params` to be specified in YAML
- Add environment variables support for `python_callable_file`
- Adds support for `is_paused_upon_creation` flag
- Allow `python_callable` to be specified in YAML

## [0.11.1] - 2021-12-07

### Added

- Add support for `access_control` in DAG params

### Fixed

- Fixed tests for Airflow 1.10 by pinning `wtforms`

## [0.11.0] - 2021-10-16

### Added

- Add support success/failure callables in `SqlSensor`
- Add `sla_secs` option in task param to convert seconds to timedelta object

### Fixed

- Support Airflow 2.2

## [0.10.1] - 2021-08-24

### Added

- Add support for `response_check_lambda` option in `HttpSensor`

## [0.10.0] - 2021-08-20

### Added

- Add support for `HttpSensor`

## [0.9.1] - 2021-07-27

### Added

- Add support for `python_callable_file` for `BranchPythonOperator`

### Fixed

- Only try to use `import_string` for callbacks if they are strings

## [0.9.0] - 2021-07-25

### Added

- Allow callbacks from Python modules

## [0.8.0] - 2021-06-09

### Added

- Support for `TaskGroups` if using Airflow 2.0
- Separate DAG building and registering logic

## [0.7.2] - 2021-01-21

### Fixed

- Correctly set `dag.description` depending on Airflow version

## [0.7.1] - 2020-12-19

### Added

- Examples for using Custom Operator

### Fixed

- Handle `"None"` as `schedule_interval`

## [0.7.0] - 2020-12-19

### Added

- Support Airflow 2.0!

## [0.6.0] - 2020-11-16

### Added

- `catchup` added to DAG parameters
- Support for `ExternalTaskSensor`
- Run test suite against Python 3.8

## [0.5.0] - 2020-08-20

### Added

- Support for `KubernetesPodOperator`
- `doc_md` parameter at DAG level
- Import `doc_md` from a file or python callable

### Fixed

- `get_datetime` no longer removes time component

## [0.4.5] - 2020-06-17

### Fixed

- Do not include DAG `tags` parameter in Airflow versions that do not support it.

## [0.4.4] - 2020-06-12

### Fixed

- Use correct default for `tags` parameter

## [0.4.3] - 2020-05-24

### Added

- `execution_timeout` parse at task level
- `tags` parameter at DAG level

## [0.4.2] - 2020-03-28

### Added

- Method `clean_dags` to clean old dags that might not exist anymore

### Changed

- `airflow` version

## [0.4.1] - 2020-02-18

### Fixed

- Default `default_view` parameter to value from `airflow.cfg`

## [0.4.0] - 2020-02-12

### Added

- Support for additional DAG parameters

### Fixed

- Define Loader when loading YAML file

## [0.3.0] - 2019-10-11

### Added

- Support for PythonOperator tasks

### Changed

- Cleaned up testing suite and added pylint to builds

## [0.2.2] - 2019-09-08

### Changed

- `airflow` version

### Removed

- `piplock` and `pipfile` files

## [0.2.1] - 2019-02-26

### Added

- Python 3+ type-annotations

## [0.2.0] - 2018-11-28

### Added

- Added badges to README
- Support for timezone aware DAGs
- This CHANGELOG!

## [0.1.1] - 2018-11-20

### Removed

- Removed `logme` dependency

## [0.1.0] - 2018-11-20

- Initial release

[Unreleased]: https://github.com/ajbosco/dag-factory/compare/v0.19.0...HEAD
Expand Down
9 changes: 5 additions & 4 deletions PRIVACY_NOTICE.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,16 @@ security fixes. Additionally, this information supports key decisions related to

Deployments and individual users can opt-out of analytics by setting the configuration:

```
[dag_factory] enable_telemetry False
```ini
[dag_factory]
enable_telemetry False
```

As described in the [official documentation](https://docs.scarf.sh/gateway/#do-not-track), it is also possible to opt out by setting one of the following environment variables:

```commandline
DO_NOT_TRACK=True
SCARF_NO_ANALYTICS=True
DO_NOT_TRACK=True
SCARF_NO_ANALYTICS=True
```

In addition to Scarf's default data collection, DAG Factory collects the following information:
Expand Down
Loading
Loading