ramitkataria commented on code in PR #77420:
URL: https://github.com/apache/airflow/pull/77420#discussion_r4655418560
##########
scripts/in_container/install_mermaid_cli.sh:
##########
@@ -25,9 +25,31 @@ set -euo pipefail
MERMAID_CLI_VERSION="11.17.0"
+function align_image_packages_with_hardened_repository() {
+ # Chromium pulls in libraries (libx11-xcb1) that depend on the exact
dhi.io version of packages
+ # the image already has. When dhi.io has renumbered those since the
image's OS dependencies were
+ # installed, apt refuses to downgrade the image's copy and the install
fails. This repeats the
+ # function of the same name in scripts/docker/install_os_dependencies.sh,
which explains the
+ # renumbering and only runs when the OS dependencies are installed, not on
this later apt run.
+ local package
+ local dhi_version
+ local -a downgrades=()
+ while read -r package; do
+ dhi_version=$(apt-cache madison "${package}" | awk -F' [|] ' '$3 ~
/dhi\.io/ && !found {print $2; found=1}')
+ if [[ -n "${dhi_version}" ]]; then
+ downgrades+=("${package}=${dhi_version}")
+ fi
+ done < <(apt list --installed 2>/dev/null | awk -F/ '/\[installed,local\]/
{print $1}')
Review Comment:
That was intentional - it only touches installed versions that no repository
offers any more, which is the same rule the image build applies. A list limited
to today's conflict would break the docs build again on the next dhi.io
renumbering
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]