apache-airflow-providers-postgres 5.5.0rc2__tar.gz → 5.5.1rc1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {apache-airflow-providers-postgres-5.5.0rc2/apache_airflow_providers_postgres.egg-info → apache-airflow-providers-postgres-5.5.1rc1}/PKG-INFO +23 -7
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/README.rst +19 -3
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/airflow/providers/postgres/__init__.py +1 -1
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/airflow/providers/postgres/get_provider_info.py +1 -0
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/airflow/providers/postgres/hooks/postgres.py +20 -20
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/airflow/providers/postgres/operators/postgres.py +1 -1
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1/apache_airflow_providers_postgres.egg-info}/PKG-INFO +23 -7
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/pyproject.toml +6 -5
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/setup.cfg +4 -4
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/setup.py +1 -1
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/LICENSE +0 -0
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/MANIFEST.in +0 -0
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/NOTICE +0 -0
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/airflow/providers/postgres/hooks/__init__.py +0 -0
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/airflow/providers/postgres/operators/__init__.py +0 -0
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/apache_airflow_providers_postgres.egg-info/SOURCES.txt +0 -0
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/apache_airflow_providers_postgres.egg-info/dependency_links.txt +0 -0
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/apache_airflow_providers_postgres.egg-info/entry_points.txt +0 -0
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/apache_airflow_providers_postgres.egg-info/not-zip-safe +0 -0
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/apache_airflow_providers_postgres.egg-info/requires.txt +0 -0
- {apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/apache_airflow_providers_postgres.egg-info/top_level.txt +0 -0
@@ -1,13 +1,13 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: apache-airflow-providers-postgres
|
3
|
-
Version: 5.5.
|
3
|
+
Version: 5.5.1rc1
|
4
4
|
Summary: Provider for Apache Airflow. Implements apache-airflow-providers-postgres package
|
5
5
|
Home-page: https://airflow.apache.org/
|
6
6
|
Download-URL: https://archive.apache.org/dist/airflow/providers
|
7
7
|
Author: Apache Software Foundation
|
8
8
|
Author-email: dev@airflow.apache.org
|
9
9
|
License: Apache License 2.0
|
10
|
-
Project-URL: Documentation, https://airflow.apache.org/docs/apache-airflow-providers-postgres/5.5.
|
10
|
+
Project-URL: Documentation, https://airflow.apache.org/docs/apache-airflow-providers-postgres/5.5.1/
|
11
11
|
Project-URL: Bug Tracker, https://github.com/apache/airflow/issues
|
12
12
|
Project-URL: Source Code, https://github.com/apache/airflow
|
13
13
|
Project-URL: Slack Chat, https://s.apache.org/airflow-slack
|
@@ -21,12 +21,12 @@ Classifier: Intended Audience :: System Administrators
|
|
21
21
|
Classifier: Framework :: Apache Airflow
|
22
22
|
Classifier: Framework :: Apache Airflow :: Provider
|
23
23
|
Classifier: License :: OSI Approved :: Apache Software License
|
24
|
-
Classifier: Programming Language :: Python :: 3.7
|
25
24
|
Classifier: Programming Language :: Python :: 3.8
|
26
25
|
Classifier: Programming Language :: Python :: 3.9
|
27
26
|
Classifier: Programming Language :: Python :: 3.10
|
27
|
+
Classifier: Programming Language :: Python :: 3.11
|
28
28
|
Classifier: Topic :: System :: Monitoring
|
29
|
-
Requires-Python: ~=3.
|
29
|
+
Requires-Python: ~=3.8
|
30
30
|
Description-Content-Type: text/x-rst
|
31
31
|
Provides-Extra: amazon
|
32
32
|
Provides-Extra: common.sql
|
@@ -54,7 +54,7 @@ License-File: NOTICE
|
|
54
54
|
|
55
55
|
Package ``apache-airflow-providers-postgres``
|
56
56
|
|
57
|
-
Release: ``5.5.
|
57
|
+
Release: ``5.5.1rc1``
|
58
58
|
|
59
59
|
|
60
60
|
`PostgreSQL <https://www.postgresql.org/>`__
|
@@ -67,7 +67,7 @@ This is a provider package for ``postgres`` provider. All classes for this provi
|
|
67
67
|
are in ``airflow.providers.postgres`` python package.
|
68
68
|
|
69
69
|
You can find package information and changelog for the provider
|
70
|
-
in the `documentation <https://airflow.apache.org/docs/apache-airflow-providers-postgres/5.5.
|
70
|
+
in the `documentation <https://airflow.apache.org/docs/apache-airflow-providers-postgres/5.5.1/>`_.
|
71
71
|
|
72
72
|
|
73
73
|
Installation
|
@@ -77,7 +77,7 @@ You can install this package on top of an existing Airflow 2 installation (see `
|
|
77
77
|
for the minimum Airflow version supported) via
|
78
78
|
``pip install apache-airflow-providers-postgres``
|
79
79
|
|
80
|
-
The package supports the following python versions: 3.
|
80
|
+
The package supports the following python versions: 3.8,3.9,3.10,3.11
|
81
81
|
|
82
82
|
Requirements
|
83
83
|
------------
|
@@ -136,6 +136,22 @@ Dependent package
|
|
136
136
|
Changelog
|
137
137
|
---------
|
138
138
|
|
139
|
+
5.5.1
|
140
|
+
.....
|
141
|
+
|
142
|
+
.. note::
|
143
|
+
This release dropped support for Python 3.7
|
144
|
+
|
145
|
+
Misc
|
146
|
+
~~~~
|
147
|
+
|
148
|
+
* ``Add note about dropping Python 3.7 for providers (#32015)``
|
149
|
+
|
150
|
+
.. Below changes are excluded from the changelog. Move them to
|
151
|
+
appropriate section above if needed. Do not delete the lines(!):
|
152
|
+
* ``Improve docstrings in providers (#31681)``
|
153
|
+
* ``Add D400 pydocstyle check - Providers (#31427)``
|
154
|
+
|
139
155
|
5.5.0
|
140
156
|
.....
|
141
157
|
|
{apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/README.rst
RENAMED
@@ -19,7 +19,7 @@
|
|
19
19
|
|
20
20
|
Package ``apache-airflow-providers-postgres``
|
21
21
|
|
22
|
-
Release: ``5.5.
|
22
|
+
Release: ``5.5.1rc1``
|
23
23
|
|
24
24
|
|
25
25
|
`PostgreSQL <https://www.postgresql.org/>`__
|
@@ -32,7 +32,7 @@ This is a provider package for ``postgres`` provider. All classes for this provi
|
|
32
32
|
are in ``airflow.providers.postgres`` python package.
|
33
33
|
|
34
34
|
You can find package information and changelog for the provider
|
35
|
-
in the `documentation <https://airflow.apache.org/docs/apache-airflow-providers-postgres/5.5.
|
35
|
+
in the `documentation <https://airflow.apache.org/docs/apache-airflow-providers-postgres/5.5.1/>`_.
|
36
36
|
|
37
37
|
|
38
38
|
Installation
|
@@ -42,7 +42,7 @@ You can install this package on top of an existing Airflow 2 installation (see `
|
|
42
42
|
for the minimum Airflow version supported) via
|
43
43
|
``pip install apache-airflow-providers-postgres``
|
44
44
|
|
45
|
-
The package supports the following python versions: 3.
|
45
|
+
The package supports the following python versions: 3.8,3.9,3.10,3.11
|
46
46
|
|
47
47
|
Requirements
|
48
48
|
------------
|
@@ -101,6 +101,22 @@ Dependent package
|
|
101
101
|
Changelog
|
102
102
|
---------
|
103
103
|
|
104
|
+
5.5.1
|
105
|
+
.....
|
106
|
+
|
107
|
+
.. note::
|
108
|
+
This release dropped support for Python 3.7
|
109
|
+
|
110
|
+
Misc
|
111
|
+
~~~~
|
112
|
+
|
113
|
+
* ``Add note about dropping Python 3.7 for providers (#32015)``
|
114
|
+
|
115
|
+
.. Below changes are excluded from the changelog. Move them to
|
116
|
+
appropriate section above if needed. Do not delete the lines(!):
|
117
|
+
* ``Improve docstrings in providers (#31681)``
|
118
|
+
* ``Add D400 pydocstyle check - Providers (#31427)``
|
119
|
+
|
104
120
|
5.5.0
|
105
121
|
.....
|
106
122
|
|
@@ -37,8 +37,7 @@ CursorType = Union[DictCursor, RealDictCursor, NamedTupleCursor]
|
|
37
37
|
|
38
38
|
|
39
39
|
class PostgresHook(DbApiHook):
|
40
|
-
"""
|
41
|
-
Interact with Postgres.
|
40
|
+
"""Interact with Postgres.
|
42
41
|
|
43
42
|
You can specify ssl parameters in the extra field of your connection
|
44
43
|
as ``{"sslmode": "require", "sslcert": "/path/to/cert.pem", etc}``.
|
@@ -146,8 +145,8 @@ class PostgresHook(DbApiHook):
|
|
146
145
|
return self.conn
|
147
146
|
|
148
147
|
def copy_expert(self, sql: str, filename: str) -> None:
|
149
|
-
"""
|
150
|
-
|
148
|
+
"""Executes SQL using psycopg2's ``copy_expert`` method.
|
149
|
+
|
151
150
|
Necessary to execute COPY command without access to a superuser.
|
152
151
|
|
153
152
|
Note: if this method is called with a "COPY FROM" statement and
|
@@ -169,8 +168,8 @@ class PostgresHook(DbApiHook):
|
|
169
168
|
conn.commit()
|
170
169
|
|
171
170
|
def get_uri(self) -> str:
|
172
|
-
"""
|
173
|
-
|
171
|
+
"""Extract the URI from the connection.
|
172
|
+
|
174
173
|
:return: the extracted uri.
|
175
174
|
"""
|
176
175
|
conn = self.get_connection(getattr(self, self.conn_name_attr))
|
@@ -179,18 +178,19 @@ class PostgresHook(DbApiHook):
|
|
179
178
|
return uri
|
180
179
|
|
181
180
|
def bulk_load(self, table: str, tmp_file: str) -> None:
|
182
|
-
"""Loads a tab-delimited file into a database table"""
|
181
|
+
"""Loads a tab-delimited file into a database table."""
|
183
182
|
self.copy_expert(f"COPY {table} FROM STDIN", tmp_file)
|
184
183
|
|
185
184
|
def bulk_dump(self, table: str, tmp_file: str) -> None:
|
186
|
-
"""Dumps a database table into a tab-delimited file"""
|
185
|
+
"""Dumps a database table into a tab-delimited file."""
|
187
186
|
self.copy_expert(f"COPY {table} TO STDOUT", tmp_file)
|
188
187
|
|
189
188
|
@staticmethod
|
190
189
|
def _serialize_cell(cell: object, conn: connection | None = None) -> Any:
|
191
|
-
"""
|
192
|
-
|
193
|
-
|
190
|
+
"""Serialize a cell.
|
191
|
+
|
192
|
+
PostgreSQL adapts all arguments to the ``execute()`` method internally,
|
193
|
+
hence we return the cell without any conversion.
|
194
194
|
|
195
195
|
See http://initd.org/psycopg/docs/advanced.html#adapting-new-types for
|
196
196
|
more information.
|
@@ -202,10 +202,11 @@ class PostgresHook(DbApiHook):
|
|
202
202
|
return cell
|
203
203
|
|
204
204
|
def get_iam_token(self, conn: Connection) -> tuple[str, str, int]:
|
205
|
-
"""
|
206
|
-
|
207
|
-
|
208
|
-
|
205
|
+
"""Get the IAM token.
|
206
|
+
|
207
|
+
This uses AWSHook to retrieve a temporary password to connect to
|
208
|
+
Postgres or Redshift. Port is required. If none is provided, the default
|
209
|
+
5432 is used.
|
209
210
|
"""
|
210
211
|
try:
|
211
212
|
from airflow.providers.amazon.aws.hooks.base_aws import AwsBaseHook
|
@@ -242,8 +243,7 @@ class PostgresHook(DbApiHook):
|
|
242
243
|
return login, token, port
|
243
244
|
|
244
245
|
def get_table_primary_key(self, table: str, schema: str | None = "public") -> list[str] | None:
|
245
|
-
"""
|
246
|
-
Helper method that returns the table primary key
|
246
|
+
"""Get the table's primary key.
|
247
247
|
|
248
248
|
:param table: Name of the target table
|
249
249
|
:param schema: Name of the target schema, public by default
|
@@ -267,9 +267,9 @@ class PostgresHook(DbApiHook):
|
|
267
267
|
def _generate_insert_sql(
|
268
268
|
cls, table: str, values: tuple[str, ...], target_fields: Iterable[str], replace: bool, **kwargs
|
269
269
|
) -> str:
|
270
|
-
"""
|
271
|
-
|
272
|
-
The REPLACE variant is specific to PostgreSQL syntax.
|
270
|
+
"""Generate the INSERT SQL statement.
|
271
|
+
|
272
|
+
The REPLACE variant is specific to the PostgreSQL syntax.
|
273
273
|
|
274
274
|
:param table: Name of the target table
|
275
275
|
:param values: The row to insert into the table
|
@@ -28,7 +28,7 @@ from airflow.providers.common.sql.operators.sql import SQLExecuteQueryOperator
|
|
28
28
|
|
29
29
|
class PostgresOperator(SQLExecuteQueryOperator):
|
30
30
|
"""
|
31
|
-
Executes sql code in a specific Postgres database
|
31
|
+
Executes sql code in a specific Postgres database.
|
32
32
|
|
33
33
|
:param sql: the SQL code to be executed as a single string, or
|
34
34
|
a list of str (sql statements), or a reference to a template file.
|
@@ -1,13 +1,13 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: apache-airflow-providers-postgres
|
3
|
-
Version: 5.5.
|
3
|
+
Version: 5.5.1rc1
|
4
4
|
Summary: Provider for Apache Airflow. Implements apache-airflow-providers-postgres package
|
5
5
|
Home-page: https://airflow.apache.org/
|
6
6
|
Download-URL: https://archive.apache.org/dist/airflow/providers
|
7
7
|
Author: Apache Software Foundation
|
8
8
|
Author-email: dev@airflow.apache.org
|
9
9
|
License: Apache License 2.0
|
10
|
-
Project-URL: Documentation, https://airflow.apache.org/docs/apache-airflow-providers-postgres/5.5.
|
10
|
+
Project-URL: Documentation, https://airflow.apache.org/docs/apache-airflow-providers-postgres/5.5.1/
|
11
11
|
Project-URL: Bug Tracker, https://github.com/apache/airflow/issues
|
12
12
|
Project-URL: Source Code, https://github.com/apache/airflow
|
13
13
|
Project-URL: Slack Chat, https://s.apache.org/airflow-slack
|
@@ -21,12 +21,12 @@ Classifier: Intended Audience :: System Administrators
|
|
21
21
|
Classifier: Framework :: Apache Airflow
|
22
22
|
Classifier: Framework :: Apache Airflow :: Provider
|
23
23
|
Classifier: License :: OSI Approved :: Apache Software License
|
24
|
-
Classifier: Programming Language :: Python :: 3.7
|
25
24
|
Classifier: Programming Language :: Python :: 3.8
|
26
25
|
Classifier: Programming Language :: Python :: 3.9
|
27
26
|
Classifier: Programming Language :: Python :: 3.10
|
27
|
+
Classifier: Programming Language :: Python :: 3.11
|
28
28
|
Classifier: Topic :: System :: Monitoring
|
29
|
-
Requires-Python: ~=3.
|
29
|
+
Requires-Python: ~=3.8
|
30
30
|
Description-Content-Type: text/x-rst
|
31
31
|
Provides-Extra: amazon
|
32
32
|
Provides-Extra: common.sql
|
@@ -54,7 +54,7 @@ License-File: NOTICE
|
|
54
54
|
|
55
55
|
Package ``apache-airflow-providers-postgres``
|
56
56
|
|
57
|
-
Release: ``5.5.
|
57
|
+
Release: ``5.5.1rc1``
|
58
58
|
|
59
59
|
|
60
60
|
`PostgreSQL <https://www.postgresql.org/>`__
|
@@ -67,7 +67,7 @@ This is a provider package for ``postgres`` provider. All classes for this provi
|
|
67
67
|
are in ``airflow.providers.postgres`` python package.
|
68
68
|
|
69
69
|
You can find package information and changelog for the provider
|
70
|
-
in the `documentation <https://airflow.apache.org/docs/apache-airflow-providers-postgres/5.5.
|
70
|
+
in the `documentation <https://airflow.apache.org/docs/apache-airflow-providers-postgres/5.5.1/>`_.
|
71
71
|
|
72
72
|
|
73
73
|
Installation
|
@@ -77,7 +77,7 @@ You can install this package on top of an existing Airflow 2 installation (see `
|
|
77
77
|
for the minimum Airflow version supported) via
|
78
78
|
``pip install apache-airflow-providers-postgres``
|
79
79
|
|
80
|
-
The package supports the following python versions: 3.
|
80
|
+
The package supports the following python versions: 3.8,3.9,3.10,3.11
|
81
81
|
|
82
82
|
Requirements
|
83
83
|
------------
|
@@ -136,6 +136,22 @@ Dependent package
|
|
136
136
|
Changelog
|
137
137
|
---------
|
138
138
|
|
139
|
+
5.5.1
|
140
|
+
.....
|
141
|
+
|
142
|
+
.. note::
|
143
|
+
This release dropped support for Python 3.7
|
144
|
+
|
145
|
+
Misc
|
146
|
+
~~~~
|
147
|
+
|
148
|
+
* ``Add note about dropping Python 3.7 for providers (#32015)``
|
149
|
+
|
150
|
+
.. Below changes are excluded from the changelog. Move them to
|
151
|
+
appropriate section above if needed. Do not delete the lines(!):
|
152
|
+
* ``Improve docstrings in providers (#31681)``
|
153
|
+
* ``Add D400 pydocstyle check - Providers (#31427)``
|
154
|
+
|
139
155
|
5.5.0
|
140
156
|
.....
|
141
157
|
|
@@ -26,6 +26,9 @@ target-version = ['py37', 'py38', 'py39', 'py310']
|
|
26
26
|
requires = ['setuptools==67.2.0']
|
27
27
|
build-backend = "setuptools.build_meta"
|
28
28
|
|
29
|
+
[project]
|
30
|
+
requires-python = ">=3.8"
|
31
|
+
|
29
32
|
[tool.ruff]
|
30
33
|
typing-modules = ["airflow.typing_compat"]
|
31
34
|
line-length = 110
|
@@ -35,12 +38,10 @@ extend-exclude = [
|
|
35
38
|
"airflow/providers/google/ads/_vendor/*",
|
36
39
|
# The files generated by stubgen aren't 100% valid syntax it turns out, and we don't ship them, so we can
|
37
40
|
# ignore them in ruff
|
38
|
-
"airflow/providers/common/sql/*/*.pyi"
|
41
|
+
"airflow/providers/common/sql/*/*.pyi",
|
42
|
+
"airflow/migrations/versions/*.py"
|
39
43
|
]
|
40
44
|
|
41
|
-
# TODO: Bump to Python 3.8 when support for Python 3.7 is dropped in Airflow.
|
42
|
-
target-version = "py37"
|
43
|
-
|
44
45
|
extend-select = [
|
45
46
|
"I", # Missing required import (auto-fixable)
|
46
47
|
"UP", # Pyupgrade
|
@@ -53,7 +54,7 @@ extend-select = [
|
|
53
54
|
"D106",
|
54
55
|
"D2",
|
55
56
|
"D3",
|
56
|
-
|
57
|
+
"D400",
|
57
58
|
# "D401", # Not enabled by ruff, but we don't want it
|
58
59
|
"D402",
|
59
60
|
"D403",
|
{apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/setup.cfg
RENAMED
@@ -21,13 +21,13 @@ classifiers =
|
|
21
21
|
Framework :: Apache Airflow
|
22
22
|
Framework :: Apache Airflow :: Provider
|
23
23
|
License :: OSI Approved :: Apache Software License
|
24
|
-
Programming Language :: Python :: 3.7
|
25
24
|
Programming Language :: Python :: 3.8
|
26
25
|
Programming Language :: Python :: 3.9
|
27
26
|
Programming Language :: Python :: 3.10
|
27
|
+
Programming Language :: Python :: 3.11
|
28
28
|
Topic :: System :: Monitoring
|
29
29
|
project_urls =
|
30
|
-
Documentation=https://airflow.apache.org/docs/apache-airflow-providers-postgres/5.5.
|
30
|
+
Documentation=https://airflow.apache.org/docs/apache-airflow-providers-postgres/5.5.1/
|
31
31
|
Bug Tracker=https://github.com/apache/airflow/issues
|
32
32
|
Source Code=https://github.com/apache/airflow
|
33
33
|
Slack Chat=https://s.apache.org/airflow-slack
|
@@ -40,7 +40,7 @@ python_tag = py3
|
|
40
40
|
[options]
|
41
41
|
zip_safe = False
|
42
42
|
include_package_data = True
|
43
|
-
python_requires = ~=3.
|
43
|
+
python_requires = ~=3.8
|
44
44
|
packages = find:
|
45
45
|
setup_requires =
|
46
46
|
setuptools
|
@@ -58,6 +58,6 @@ apache_airflow_provider =
|
|
58
58
|
packages = airflow.providers.postgres
|
59
59
|
|
60
60
|
[egg_info]
|
61
|
-
tag_build =
|
61
|
+
tag_build = rc1
|
62
62
|
tag_date = 0
|
63
63
|
|
{apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/LICENSE
RENAMED
File without changes
|
File without changes
|
{apache-airflow-providers-postgres-5.5.0rc2 → apache-airflow-providers-postgres-5.5.1rc1}/NOTICE
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|