HPA behaviour was not considered in "hpa ambiguous selector" (#112011) fix

Hi Everyone,
We are using two hpa to control a deployment, But both hpa will not active on the same time. we handle it using scaling policy.
But the following fix completely disables both hpa.

Is it possible to consider the scaling policy while determining the ambiguous selector?

Following is our hpa that working on single deployment, that is been disabled by the above fix.

apiVersion: autoscaling/v2beta2
kind: HorizontalPodAutoscaler
metadata:
  name: app-scale-up
  namespace: ns
spec:
  scaleTargetRef:
    apiVersion: apps/v1
    kind: Deployment
    name: app
  minReplicas: 5
  maxReplicas: 25
  metrics:
    - type: External
      external:
        metric:
          name: container_cpu_usage
        target:
          type: Value
          value: 60
  behavior:
    scaleDown:
      selectPolicy: Disabled
    scaleUp:
      stabilizationWindowSeconds: 60
      policies:
        - type: Pods
          value: 1
          periodSeconds: 10
---
apiVersion: autoscaling/v2beta2
kind: HorizontalPodAutoscaler
metadata:
  name: app-scale-down
  namespace: ns
spec:
  scaleTargetRef:
    apiVersion: apps/v1
    kind: Deployment
    name: app
  minReplicas: 5
  maxReplicas: 25
  metrics:
    - type: External
      external:
        metric:
          name: container_cpu_usage
        target:
          type: Value
          value: 30
  behavior:
    scaleDown:
      stabilizationWindowSeconds: 500
      policies:
        - type: Pods
          value: 1
          periodSeconds: 60
    scaleUp:
      selectPolicy: Disabled

Cluster information: 1.28

Kubernetes version:
Cloud being used: AWS
Installation method: EKS
Host OS:
CNI and version:
CRI and version:

You can format your yaml by highlighting it and pressing Ctrl-Shift-C, it will make your output easier to read.