Граф коммитов

186 Коммитов

Автор SHA1 Сообщение Дата
Jarek Potiuk ad2a030b9e
Introduces separate runtime provider schema (#13488)
The provider.yaml contains more information that required at
runtime (specifically about documentation building). Those
fields are not needed at runtime and their presence is optional.
Also the runtime check for provider information should be more
relexed and allow for future compatibility (with
additional properties set to false). This way we can add new,
optional fields to provider.yaml without worrying about breaking
future-compatibility of providers with future airflow versions.

This changei restores 'additionalProperties': false in the
main, development-focused provider.yaml schema and introduced
new runtime schema that is used to verify the provider info when
providers are discovered by airflow.

This 'runtime' version should change very rarely as change to
add a new required property in it breaks compatibility of
providers with already released versions of Airflow.

We also trim-down the provider.yaml file when preparing provider
packages to only contain those fields that are required in the
runtime schema.
2021-01-11 23:10:44 +01:00
Ash Berlin-Taylor f115983550
Run "third party" github actions from submodules instead (#13514)
Rather than having to mirror all the repos we can instead use
git submodules to pull in the third party actions we want to use - with
recent(ish) changes in review for submodules on GitHub we still get the
same "review/audit" visibility for changes, but this way we don't have
to either "pollute" our repo with the actions code, nor do we have to
maintain a fork of the third party action.
2021-01-11 11:38:15 +01:00
Kaxil Naik 10c84b5cb2
Upgrade pre-commit hooks (#13465)
`doctoc` -> 1.4 to 2.0
`pre-commit-hooks` -> 3.3 to 3.4
2021-01-04 21:13:24 +00:00
Jarek Potiuk 0d214575a1
Refactored setup.py to better reflect changes in providers (#13314)
This is a complete refactor of the setup.py providers/dependencies.

It much better reflects the current setup where we have most of
the extras 1-1 reflecting providers but also some extras that do
not have their own providers.

The pre-commits that were verifying setup versus documentation
can now be vastly simplified (no more need to parse the
comments so we can import setup.py variables directly rather
than parse it via regexps. Also we can better categorize the
extras - separate out (and verify) whether we correctly
described deprecated extras and to mark extras that install
additional providers as such.

Fixes: #13309
2020-12-28 19:10:27 +01:00
dstandish 91acdbea05
Add pre-commit hook limiting hook name length (#13319)
* When hook names are too long, pre-commit dispay becomes very ugly with many blank lines

Co-authored-by: Daniel Standish <dstandish@techstyle.com>
2020-12-26 11:24:27 +01:00
dstandish f7b9ba8189
Rename second pylint pre-commit hook to distinguish it from first (#13303) 2020-12-24 13:24:52 +01:00
John Bampton 2e28ab6324
Remove duplicate pre-commit checks (#13167)
- Sort INTHEWILD.md alphabetically
- Lint Helm Chart
2020-12-19 00:14:08 +00:00
Jarek Potiuk 7ce2bd4e74
Skip identity pre-commit in ci and always display it first (#13106) 2020-12-16 14:14:20 +01:00
Ruben Laguna 99c2e03da9
Add identity pre-commit hook (#13089) 2020-12-16 09:03:48 +01:00
Sam Wheating 1dc36d8704
Add schema validation for config.yml (#13025)
* Adding schema validation for config.yml

* Update airflow/config_templates/config.yml.schema.json

Co-authored-by: Kamil Breguła <mik-laj@users.noreply.github.com>

Co-authored-by: Kamil Breguła <mik-laj@users.noreply.github.com>
2020-12-16 02:49:06 +01:00
Kamil Breguła 81a1305bb9
Trigger provider-yamls check on docs change (#12998) 2020-12-10 22:45:51 +01:00
Kaxil Naik 4fe156f98a
Remove unused pre-commit and Fix CI (#12964) 2020-12-09 18:44:10 +00:00
dstandish 53c48471a6
shorten name of hook re imports of provide_session and create_session (#12936) 2020-12-09 06:27:11 +01:00
Jarek Potiuk 4d24c5ee55
Update comments in setup.py (#12903)
Updates comments in setup.py according to the latest 2.0 agreements
about semver and clarifies use for arrays defined in setup.py.

We will refactor those after 2.0 further, but for now we keep
the current structure.
2020-12-08 15:59:37 +01:00
Ash Berlin-Taylor 2936c13a44
Get airflow version from importlib.metadata rather than hard-coding (#12786)
One less thing to change, and one less pre-commit step needed :)
2020-12-04 16:42:25 +00:00
Kamil Breguła 6878a7baad
Add more json-schama checks + display all errors (#12805) 2020-12-04 16:51:59 +01:00
Kamil Breguła 027fd743d6
Fix static checks - #12715 (#12729) 2020-12-01 11:10:54 +00:00
Jarek Potiuk 2037303eef
Adds support for Connection/Hook discovery from providers (#12466)
* Adds support for Hook discovery from providers

This PR extends providers discovery with the mechanism
of retrieving mapping of connections from type to hook.

Fixes #12456

* fixup! Adds support for Hook discovery from providers

* fixup! fixup! Adds support for Hook discovery from providers
2020-11-29 15:31:49 +01:00
Kamil Breguła 08bc62b64d
Validate JSON schema files with JSON Schema (#12682) 2020-11-28 12:12:54 +01:00
Kamil Breguła de3b1e687b
Move connection guides to provider documentation packages (#12653) 2020-11-28 08:09:53 +01:00
Tomek Urbaszek 456a1c5dc9
Restructure the extras in setup.py and described them (#12548)
Closes: #12544

Co-authored-by: Ash Berlin-Taylor <ash_github@firemirror.com>
Co-authored-by: Kaxil Naik <kaxilnaik@gmail.com>
2020-11-27 15:34:47 +01:00
Jarek Potiuk 58e21ed949
Adds missing licence headers (#12593) 2020-11-25 00:58:01 +01:00
Kamil Breguła 8e1a6e17e6
Fix build on RTD (#12551) 2020-11-23 09:52:24 +01:00
Kamil Breguła c34ef853c8
Separate out documentation building per provider (#12444)
* POC

* fixup! POC
2020-11-20 15:35:56 +01:00
Kaxil Naik 4f0d6a687d
Upgrade pyupgrade to v2.7.4 (#12434)
https://github.com/asottile/pyupgrade/compare/v2.7.3...v2.7.4
2020-11-18 07:20:54 +01:00
Kamil Breguła 2cda2f2a0a
Add missing pre-commit definition - provider-yamls (#12393) 2020-11-17 15:44:46 +01:00
Kamil Breguła 6889a333cf
Improvements for operators and hooks ref docs (#12366) 2020-11-15 00:50:30 +01:00
Jarek Potiuk 1b77ebc84d
Visually separate pre-commits which require CI image (#12367) 2020-11-14 12:23:23 +01:00
Jarek Potiuk 648dd7cd29
Restructure documentation for releasing Airflow/Providers (#12350) 2020-11-13 23:04:09 +01:00
Kamil Breguła 7825e8f590
Docs installation improvements (#12304)
* Improvements for installation docs
2020-11-13 09:38:54 +01:00
Jarek Potiuk 348510f86b
Providers in extras are properly configured and verified (#12265)
* Providers in extras are properly configured and verified

This fixes #12255 - where we published beta2 release with some
extras pulling non-existing providers.

The exact list of providers that had problems:

Wrongly named extras/providers:

* apache.presto: it was badly named -> renamed to 'presto'
* spark (badly pointing to spark instead of apache.spark)
* yandexcloud (the name remains there but we've also added 'yandex' extra to correspond 1-1 with 'yandex' provider

Extras that were wrongly marked as having providers, where they had
none:

* dask
* rabbitmq
* sentry
* statsd
* tableau
* virtualenv

* Update scripts/ci/pre_commit/pre_commit_check_extras_have_providers.py

Co-authored-by: Kaxil Naik <kaxilnaik@gmail.com>

* Update scripts/ci/pre_commit/pre_commit_check_extras_have_providers.py

Co-authored-by: Kaxil Naik <kaxilnaik@gmail.com>

Co-authored-by: Kaxil Naik <kaxilnaik@gmail.com>
2020-11-11 17:13:57 +01:00
Tomek Urbaszek 0cd1c846b2
Remove providers imports from core examples (#12252)
Core example DAGs should not depend on any non-core dependency
like providers packages.

closes: #12247

Co-authored-by: Xiaodong DENG <xd.deng.r@gmail.com>
2020-11-10 22:49:08 +01:00
John Bampton 7463b6bcc7
Add Markdown linting to pre-commit (#11465) 2020-11-10 03:37:45 +01:00
Kaxil Naik 08d67add52
Beautify Output of setup-installation pre-commit (#12218) 2020-11-10 00:54:47 +00:00
Jarek Potiuk b2a28d1590
Moves provider packages scripts to dev (#12082)
The change #10806 made airflow works with implicit packages
when "airflow" got imported. This is a good change, however
it has some unforeseen consequences. The 'provider_packages'
script copy all the providers code for backports in order
to refactor them to the empty "airflow" directory in
provider_packages folder. The #10806 change turned that
empty folder in 'airflow' package because it was in the
same directory as the provider_packages scripts.

Moving the scripts to dev solves this problem.
2020-11-09 13:27:10 +01:00
Kaxil Naik dcdf324dbc
Upgrade pygrep-hooks to 1.7.0 (#12124)
https://github.com/pre-commit/pygrep-hooks/releases/tag/v1.7.0
2020-11-06 02:06:24 +00:00
Kamil Breguła 91a64db505
Format all files (without excepions) by black (#12091) 2020-11-04 20:33:07 +01:00
Kaxil Naik 4e8f9cc8d0
Enable Black - Python Auto Formmatter (#9550) 2020-11-03 23:51:54 +00:00
Kaxil Naik 8c42cf1b00
Use PyUpgrade to use Python 3.6 features (#11447)
Use features like `f-strings` instead of format across the code-base.
More details: https://github.com/asottile/pyupgrade
2020-11-03 21:53:59 +00:00
SZN 2354bd2be3
Checks if all the libraries in setup.py are listed in installation.rst file (#12023) 2020-11-02 14:17:41 +01:00
Kamil Breguła 9322f3e46c
Migrate from helm-unittest to python unittest (#11827)
* Migrate from helm-unittest to python unittest

* fixup! Migrate from helm-unittest to python unittest

* fixup! fixup! Migrate from helm-unittest to python unittest
2020-10-30 07:48:22 -07:00
Daniel Imberman 0d1ad6648e
Add Python Helm testing framework (#11693)
* Helm Python Testing

* helm change

* add back args
2020-10-27 18:29:47 -07:00
Daniel Imberman c204a2ed89
Updating 2.0 docs (#11842)
* Separate 2.0 upgrade steps into their own file

* shell script

* more changes
2020-10-27 12:54:11 -07:00
Jarek Potiuk 872b1566a1
Generated backport providers readmes/setup for 2020.10.29 (#11826) 2020-10-25 19:45:50 +01:00
Kaxil Naik 9c6f9de796
Update to latest isort & pre-commit-hooks (#11813) 2020-10-24 04:25:15 +01:00
Kamil Breguła 53e6062105
Enforce strict rules for yamllint (#11709) 2020-10-21 12:24:32 +02:00
Katsunori Kanda 349b0811c3
Add D200 pydocstyle check (#11688) 2020-10-20 22:33:54 +02:00
Jarek Potiuk 9a90ebeabe
Bats tests should be much faster now for pre-commits. (#11662)
For pre-commit run of the tests only the corresponding tests
for changed .sh files and changed .bats files should be run
2020-10-20 09:21:28 +02:00
Kaxil Naik 63a1633d8a
Update order for pre-commits to fail fast (#11636)
`shellcheck` is slow if a Bash Script is changed, hence it is moved down in the order.

The following pre-commits are quick so moved them up the order:
- pre-commit-descriptions
- sort-in-the-wild
- helm-lint
2020-10-18 18:15:53 +01:00
Ryan Hamilton 8372ab1375
Add/implement Webpack plugin to minify CSS files on-compile (#11564) 2020-10-16 08:59:09 +01:00