@@ -133,6 +133,8 @@ git log 2.8.0..HEAD --pretty=oneline -- airflow-core/src/airflow/api_fastapi/cor
133133cd ${AIRFLOW_REPO_ROOT}
134134rm dist/*
135135breeze release-management prepare-python-client --distribution-format both --python-client-repo " ${CLIENT_REPO_ROOT} " --version-suffix " "
136+ breeze release-management prepare-tarball --tarball-type apache_airflow_python_client --version " ${VERSION} " --version-suffix " ${VERSION_SUFFIX} "
137+
136138```
137139
138140- This should generate both sdist and .whl package in ` dist ` folder of the Airflow repository. It should
@@ -339,15 +341,34 @@ Airflow Python client supports reproducible builds, which means that the package
339341sources should produce binary identical packages in reproducible way. You should check if the packages can be
340342binary-reproduced when built from the sources.
341343
342- Checkout airflow sources and build packages in dist folder (replace X.Y.Zrc1 with the version + rc candidate)
343- you are checking):
344+ 1 ) Set versions of the packages to be checked:
345+
346+ ``` shell script
347+ cd < directory where airflow is checked out>
348+ VERSION=X.Y.Z
349+ VERSION_SUFFIX=rc1
350+ VERSION_RC=${VERSION}${VERSION_SUFFIX}
351+ ```
352+
353+ 2 ) Change directory where your airflow sources are checked out
354+
355+ ``` shell
356+ cd " ${AIRFLOW_REPO_ROOT} "
357+ ```
358+
359+ 3 ) Check out the `` python-client `` tag (assume apache is the remote name of the repository):
360+
361+ ``` shell
362+ git fetch apache --tags
363+ git checkout providers/${VERSION_RC}
364+ ```
365+
366+ 4 ) Build the distribution and source tarball:
344367
345368``` shell script
346- VERSION=X.Y.Zrc1
347- git checkout python-client/${VERSION}
348- export AIRFLOW_REPO_ROOT=$( pwd)
349369rm -rf dist/*
350370breeze release-management prepare-python-client --distribution-format both --version-suffix " "
371+ breeze release-management prepare-tarball --tarball-type apache_airflow_python_client --version " ${VERSION} " --version-suffix " ${VERSION_SUFFIX} "
351372```
352373
353374The last - build step - by default will use Dockerized build and building of Python client packages
@@ -356,13 +377,16 @@ will be done in a docker container. However, if you have `hatch` installed loc
356377
357378``` bash
358379breeze release-management prepare-python-client --distribution-format both --use-local-hatch --version-suffix " "
380+ breeze release-management prepare-tarball --tarball-type apache_airflow_python_client --version " ${VERSION} " --version-suffix " ${VERSION_SUFFIX} "
359381```
360382
361383This is generally faster and requires less resources/network bandwidth.
362384
363- Both commands should produce reproducible ` .whl ` , ` .tar.gz ` packages in dist folder.
385+ Both commands should produce reproducible ` .whl ` , ` .tar.gz ` packages in dist folder and "-source.tar.gz"
386+ file containing airflow sources in dist folder.
364387
365- Change to the directory where you have the packages from svn:
388+ 4 ) Change to the directory where you have the packages from svn and check if they are identical to the ones
389+ you just built:
366390
367391``` shell script
368392# First clone the repo if you do not have it
@@ -371,7 +395,7 @@ cd ..
371395svn update --set-depth=infinity asf-dist/dev/airflow/clients/python
372396
373397# Then compare the packages
374- cd asf-dist/dev/airflow/clients/python/${VERSION }
398+ cd asf-dist/dev/airflow/clients/python/${VERSION_RC }
375399for i in ${AIRFLOW_REPO_ROOT} /dist/*
376400do
377401 echo " Checking if $( basename $i ) is the same as $i "
@@ -386,6 +410,63 @@ In case the files are different, you should see:
386410Binary files apache_airflow-client-2.9.0.tar.gz and .../apache_airflow-2.9.0.tar.gz differ
387411```
388412
413+ ### Licence check
414+
415+ This can be done with the Apache RAT tool.
416+
417+ Download the latest jar from https://creadur.apache.org/rat/download_rat.cgi (unpack the binary, the jar is inside)
418+
419+ You can run this command to do it for you:
420+
421+ ``` shell script
422+ wget -qO- https://dlcdn.apache.org//creadur/apache-rat-0.17/apache-rat-0.17-bin.tar.gz | gunzip | tar -C /tmp -xvf -
423+ ```
424+
425+ Unpack the release source archive (the ` <package + version>-source.tar.gz ` file) to a folder
426+
427+ ``` shell script
428+ rm -rf /tmp/apache/airflow-python-client-src && mkdir -p /tmp/apache-airflow-python-client-src && tar -xzf ${PATH_TO_SVN} /providers/${RELEASE_DATE} /apache_airflow_python_client-* -source.tar.gz --strip-components 1 -C /tmp/apache-airflow-python-client-src
429+ ```
430+
431+ Run the check:
432+
433+ ``` shell script
434+ java -jar /tmp/apache-rat-0.17/apache-rat-0.17.jar --input-exclude-file /tmp/apache-airflow-python-client-src/.rat-excludes /tmp/apache-airflow-python-client-src/ | grep -E " ! |INFO: "
435+ ```
436+
437+ You should see no files reported as Unknown or with wrong licence and summary of the check similar to:
438+
439+ ```
440+ INFO: Apache Creadur RAT 0.17 (Apache Software Foundation)
441+ INFO: Excluding patterns: .git-blame-ignore-revs, .github/*, .git ...
442+ INFO: Excluding MISC collection.
443+ INFO: Excluding HIDDEN_DIR collection.
444+ SLF4J(W): No SLF4J providers were found.
445+ SLF4J(W): Defaulting to no-operation (NOP) logger implementation
446+ SLF4J(W): See https://www.slf4j.org/codes.html#noProviders for further details.
447+ INFO: RAT summary:
448+ INFO: Approved: 15615
449+ INFO: Archives: 2
450+ INFO: Binaries: 813
451+ INFO: Document types: 5
452+ INFO: Ignored: 2392
453+ INFO: License categories: 2
454+ INFO: License names: 2
455+ INFO: Notices: 216
456+ INFO: Standards: 15609
457+ INFO: Unapproved: 0
458+ INFO: Unknown: 0
459+ ```
460+
461+ There should be no files reported as Unknown or Unapproved. The files that are unknown or unapproved should be shown with a line starting with ` ! ` .
462+
463+ For example:
464+
465+ ```
466+ ! Unapproved: 1 A count of unapproved licenses.
467+ ! /CODE_OF_CONDUCT.md
468+ ```
469+
389470## Signature check
390471
391472Make sure you have imported into your GPG the PGP key of the person signing the release. You can find the valid keys in
0 commit comments