Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
JTaeuber committed Nov 29, 2024
1 parent 9f0baaa commit 4e5459e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -466,11 +466,11 @@ issues are observed in the logs.
`--max-retries-on-conflict`
: Optional: Specifies the maximum number of retries KubeDownscaler should perform
: Optional: Specifies the maximum number of retries KubeDownscaler should perform
when encountering a conflict error (HTTP 409). These errors occur when one of the
resources, just before being processed by Kube Downscaler, is modified by another entity,
such as an HPA, CI/CD pipeline, or manual intervention. If enabled, Kube Downscaler will
retry the update immediately, without waiting for the next iteration (default: 0). This
retry the update immediately, without waiting for the next iteration (default: 0). This
argument is strongly recommended when using the `--once` argument to process large clusters
Expand Down
2 changes: 1 addition & 1 deletion kube_downscaler/scaler.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
from pykube import CronJob
from pykube import CustomResourceDefinition
from pykube import DaemonSet
from pykube import HTTPClient
from pykube import Deployment
from pykube import HorizontalPodAutoscaler
from pykube import HTTPClient
Expand Down Expand Up @@ -312,6 +311,7 @@ def get_resources(kind, api, namespaces: FrozenSet[str], excluded_namespaces):


def get_resource(kind, api, namespace, resource_name: str):
try:
resource = kind.objects(api).filter(namespace=namespace).get_or_none(name=resource_name)
if resource is None:
logger.debug(f"{kind.endpoint} {namespace}/{resource_name} not found")
Expand Down

0 comments on commit 4e5459e

Please sign in to comment.