diff --git a/CHANGES/pulp-glue/+cache_file.bugfix b/CHANGES/pulp-glue/+cache_file.bugfix new file mode 100644 index 000000000..695bdeefc --- /dev/null +++ b/CHANGES/pulp-glue/+cache_file.bugfix @@ -0,0 +1 @@ +Sanitize the filename of the chached `api.json`. diff --git a/pulp-glue/src/pulp_glue/common/openapi.py b/pulp-glue/src/pulp_glue/common/openapi.py index 53aafe538..8b5074654 100644 --- a/pulp-glue/src/pulp_glue/common/openapi.py +++ b/pulp-glue/src/pulp_glue/common/openapi.py @@ -216,8 +216,10 @@ def load_api(self, refresh_cache: bool = False) -> None: apidoc_cache: str = os.path.join( os.path.expanduser(xdg_cache_home), "squeezer", - (self._base_url + "_" + self._doc_path).replace(":", "_").replace("/", "_") - + "api.json", + (self._base_url + "_" + self._doc_path) + .replace(":", "_") + .replace("/", "_") + .replace("?", "_"), ) try: if refresh_cache: