diff --git a/src/stashcache.py b/src/stashcache.py index 30e1009d7..d2fd72a4e 100644 --- a/src/stashcache.py +++ b/src/stashcache.py @@ -531,8 +531,14 @@ def generate_origin_scitokens(vo_data: VOsData, resource_groups: List[ResourceGr dirname, suppress_errors)) allowed_vos.append(vo_name) - - + # Older plugin versions require at least one issuer block (SOFTWARE-4389) + if not issuer_blocks: + issuer_blocks.append( + _get_scitokens_issuer_block(vo_name="nonexistent", + scitokens={"Issuer": "https://scitokens.org/nonexistent", + "Base Path": "/no-issuers-found"}, + dirname="/no-issuers-found", + suppress_errors=suppress_errors)) issuer_blocks_str = "\n".join(issuer_blocks) allowed_vos_str = ", ".join(allowed_vos)