Skip to content

Fix: patcher.py registry block passes wrong key to registry.patch#103

Open
mobs75 wants to merge 1 commit into
apache:mainfrom
mobs75:fix/patcher-registry-keyerror
Open

Fix: patcher.py registry block passes wrong key to registry.patch#103
mobs75 wants to merge 1 commit into
apache:mainfrom
mobs75:fix/patcher-registry-keyerror

Conversation

@mobs75

@mobs75 mobs75 commented Jun 12, 2026

Copy link
Copy Markdown

Summary

In nuvolaris/patcher.py, the block guarded by if "registry" in what_to_do was incorrectly passing what_to_do['milvus'] to registry.patch() instead of what_to_do['registry'].

Root Cause

This is a copy-paste error from the adjacent milvus block. The guard condition correctly checks for "registry", but the dictionary access used the wrong key.

Impact

A KeyError: 'milvus' is raised in whisk_update whenever:

  1. The diff contains spec.components.registry (registry is added or changed)
  2. The diff does NOT contain spec.components.milvus (milvus is absent from last-handled-configuration or unchanged)

This silently breaks any platform update that touches the registry component without simultaneously touching milvus.

Fix

One-line change: replace what_to_do['milvus'] with what_to_do['registry'] in the registry block.

Testing

Verified by code inspection that all other what_to_do accesses in patcher.py correctly match their guard conditions. This block was the only mismatch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant