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

Move github provider to new structure #46211

Merged
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
5 changes: 1 addition & 4 deletions .github/boring-cyborg.yml
Original file line number Diff line number Diff line change
Expand Up @@ -185,10 +185,7 @@ labelPRBasedOnFilePath:
- providers/ftp/**

provider:github:
- providers/src/airflow/providers/github/**/*
- docs/apache-airflow-providers-github/**/*
- providers/tests/github/**/*
- providers/tests/system/github/**/*
- providers/github/**

provider:google:
- providers/src/airflow/providers/google/**/*
Expand Down
1 change: 1 addition & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ apache-airflow-providers-edge
apache-airflow-providers-exasol
apache-airflow-providers-facebook
apache-airflow-providers-ftp
apache-airflow-providers-github
apache-airflow-providers-http
apache-airflow-providers-influxdb
apache-airflow-providers-mongo
Expand Down
25 changes: 0 additions & 25 deletions docs/apache-airflow-providers-github/changelog.rst

This file was deleted.

62 changes: 62 additions & 0 deletions providers/github/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@

.. Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
.. http://www.apache.org/licenses/LICENSE-2.0
.. Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
.. NOTE! THIS FILE IS AUTOMATICALLY GENERATED AND WILL BE OVERWRITTEN!
.. IF YOU WANT TO MODIFY TEMPLATE FOR THIS FILE, YOU SHOULD MODIFY THE TEMPLATE
`PROVIDER_README_TEMPLATE.rst.jinja2` IN the `dev/breeze/src/airflow_breeze/templates` DIRECTORY
Package ``apache-airflow-providers-github``

Release: ``2.8.0``


`GitHub <https://www.github.com/>`__


Provider package
----------------

This is a provider package for ``github`` provider. All classes for this provider package
are in ``airflow.providers.github`` python package.

You can find package information and changelog for the provider
in the `documentation <https://airflow.apache.org/docs/apache-airflow-providers-github/2.8.0/>`_.

Installation
------------

You can install this package on top of an existing Airflow 2 installation (see ``Requirements`` below
for the minimum Airflow version supported) via
``pip install apache-airflow-providers-github``

The package supports the following python versions: 3.9,3.10,3.11,3.12

Requirements
------------

================== ==================
PIP package Version required
================== ==================
``apache-airflow`` ``>=2.9.0``
``PyGithub`` ``>=2.1.1``
================== ==================

The changelog for the provider package can be found in the
`changelog <https://airflow.apache.org/docs/apache-airflow-providers-github/2.8.0/changelog.html>`_.
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ You can further process the result using

An example of Listing all Repositories owned by a user, **client.get_user().get_repos()** can be implemented as following:

.. exampleinclude:: /../../providers/tests/system/github/example_github.py
.. exampleinclude:: /../../providers/github/tests/system/github/example_github.py
:language: python
:dedent: 4
:start-after: [START howto_operator_list_repos_github]
Expand All @@ -43,7 +43,7 @@ An example of Listing all Repositories owned by a user, **client.get_user().get_

An example of Listing Tags in a Repository, **client.get_repo(full_name_or_id='apache/airflow').get_tags()** can be implemented as following:

.. exampleinclude:: /../../providers/tests/system/github/example_github.py
.. exampleinclude:: /../../providers/github/tests/system/github/example_github.py
:language: python
:dedent: 4
:start-after: [START howto_operator_list_tags_github]
Expand All @@ -64,7 +64,7 @@ a Tag in `GitHub <https://www.github.com/>`__.

An example for tag **v1.0**:

.. exampleinclude:: /../../providers/tests/system/github/example_github.py
.. exampleinclude:: /../../providers/github/tests/system/github/example_github.py
:language: python
:dedent: 4
:start-after: [START howto_tag_sensor_github]
Expand All @@ -73,7 +73,7 @@ An example for tag **v1.0**:
Similar Functionality can be achieved by directly using
:class:`~from airflow.providers.github.sensors.github.GithubSensor`.

.. exampleinclude:: /../../providers/tests/system/github/example_github.py
.. exampleinclude:: /../../providers/github/tests/system/github/example_github.py
:language: python
:dedent: 4
:start-after: [START howto_sensor_github]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,6 @@ name: Github
description: |
`GitHub <https://www.github.com/>`__
dependencies:
- apache-airflow>=2.9.0
- PyGithub>=2.1.1

state: ready
source-date-epoch: 1734533986
# note that those versions are maintained by release manager - do not update them manually
Expand Down
78 changes: 78 additions & 0 deletions providers/github/pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.

# NOTE! THIS FILE IS AUTOMATICALLY GENERATED AND WILL BE OVERWRITTEN!

# IF YOU WANT TO MODIFY THIS FILE EXCEPT DEPENDENCIES, YOU SHOULD MODIFY THE TEMPLATE
# `pyproject_TEMPLATE.toml.jinja2` IN the `dev/breeze/src/airflow_breeze/templates` DIRECTORY
[build-system]
requires = ["flit_core==3.10.1"]
build-backend = "flit_core.buildapi"

[project]
name = "apache-airflow-providers-github"
version = "2.8.0"
description = "Provider package apache-airflow-providers-github for Apache Airflow"
readme = "README.rst"
authors = [
{name="Apache Software Foundation", email="[email protected]"},
]
maintainers = [
{name="Apache Software Foundation", email="[email protected]"},
]
keywords = [ "airflow-provider", "github", "airflow", "integration" ]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Environment :: Web Environment",
"Intended Audience :: Developers",
"Intended Audience :: System Administrators",
"Framework :: Apache Airflow",
"Framework :: Apache Airflow :: Provider",
"License :: OSI Approved :: Apache Software License",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Topic :: System :: Monitoring",
]
requires-python = "~=3.9"

# The dependencies should be modified in place in the generated file
# Any change in the dependencies is preserved when the file is regenerated
dependencies = [
"apache-airflow>=2.9.0",
"PyGithub>=2.1.1",
]

[project.urls]
"Documentation" = "https://airflow.apache.org/docs/apache-airflow-providers-github/2.8.0"
"Changelog" = "https://airflow.apache.org/docs/apache-airflow-providers-github/2.8.0/changelog.html"
"Bug Tracker" = "https://github.com/apache/airflow/issues"
"Source Code" = "https://github.com/apache/airflow"
"Slack Chat" = "https://s.apache.org/airflow-slack"
"Twitter" = "https://x.com/ApacheAirflow"
"YouTube" = "https://www.youtube.com/channel/UCSXwxpWZQ7XZ1WL3wqevChA/"

[project.entry-points."apache_airflow_provider"]
provider_info = "airflow.providers.github.get_provider_info:get_provider_info"

[tool.flit.module]
name = "airflow.providers.github"

[tool.pytest.ini_options]
ignore = "tests/system/"
Loading