From 5752ca38118281ad72f00dcf618f4e280e7a32ac Mon Sep 17 00:00:00 2001 From: generatedunixname89002005232357 Date: Sat, 21 Oct 2023 07:29:57 -0700 Subject: [PATCH] Revert D50197948: Multisect successfully blamed "D50197948: [antlir2][migration] convert 'flavor_config_override' to 'dnf_versionlock_extend'" for test or build failures Summary: This diff is reverting D50197948 Depends on D50527741 D50197948: [antlir2][migration] convert 'flavor_config_override' to 'dnf_versionlock_extend' by vmagro has been identified to be causing the following test or build failures: Tests affected: - [build_infra/buckaemon/integration_tests:tests - integration_test.py::test_query](https://www.internalfb.com/intern/test/844425018084705/) Here's the Multisect link: https://www.internalfb.com/multisect/3364673 Here are the tasks that are relevant to this breakage: We're generating a revert to back out the changes in this diff, please note the backout may land if someone accepts it. If you believe this diff has been generated in error you may Commandeer and Abandon it. Test Plan: NA Reviewed By: vmagro Differential Revision: D50527745 fbshipit-source-id: 1d6e34b96ba1bbbd2880ce99550fc75d730eabc7 --- antlir/antlir2/bzl/compat.bzl | 14 -------------- antlir/bzl/image_layer.bzl | 3 +-- 2 files changed, 1 insertion(+), 16 deletions(-) diff --git a/antlir/antlir2/bzl/compat.bzl b/antlir/antlir2/bzl/compat.bzl index 11a3e0c2760..7bb56ac18ba 100644 --- a/antlir/antlir2/bzl/compat.bzl +++ b/antlir/antlir2/bzl/compat.bzl @@ -38,20 +38,6 @@ def _from_antlir1_flavor( return flavor -def _flavor_config_override_to_versionlock_extend(flavor_config_override): - versionlock_extend = None - if flavor_config_override and hasattr(flavor_config_override, "rpm_version_set_overrides") and flavor_config_override.rpm_version_set_overrides: - versionlock_extend = {} - for nevra in flavor_config_override.rpm_version_set_overrides: - versionlock_extend[nevra.name] = "{}:{}-{}.{}".format( - nevra.epoch, - nevra.version, - nevra.release, - nevra.arch, - ) - return versionlock_extend - compat = struct( from_antlir1_flavor = _from_antlir1_flavor, - flavor_config_override_to_versionlock_extend = _flavor_config_override_to_versionlock_extend, ) diff --git a/antlir/bzl/image_layer.bzl b/antlir/bzl/image_layer.bzl index 1df83594844..8aa794b562f 100644 --- a/antlir/bzl/image_layer.bzl +++ b/antlir/bzl/image_layer.bzl @@ -89,7 +89,6 @@ The consequences of this information hiding are: that metadata during compilation. """ -load("//antlir/antlir2/bzl:compat.bzl?v2_only", "compat") load("//antlir/antlir2/bzl/image:defs.bzl?v2_only", antlir2_image = "image") load(":antlir2_shim.bzl", "antlir2_shim") load(":build_defs.bzl", "get_visibility", "is_buck2") @@ -120,6 +119,7 @@ def image_layer( antlir2_compatible_with = None, antlir2_features = [], antlir1_features = [], + antlir2_allow_ignored_flavor_config_override: bool = False, antlir2_default_mountpoint: str | None = None, **image_layer_kwargs): """ @@ -156,7 +156,6 @@ def image_layer( # Antlir1 provisioning images explicitly install package-devel stub, we need to allow them here. dnf_excluded_rpms = ["aziot-identity-service"], default_mountpoint = antlir2_default_mountpoint, - dnf_versionlock_extend = compat.flavor_config_override_to_versionlock_extend(flavor_config_override), fake_buck1 = struct( fn = antlir2_shim.fake_buck1_layer, name = name,