Skip to content

Commit e1b40d2

Browse files
authored
Fix comment in maps_pass.py
1 parent fd2412e commit e1b40d2

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

pythonbpf/maps/maps_pass.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -176,10 +176,9 @@ def process_bpf_map(func_node, compilation_context):
176176
if isinstance(rval, ast.Call) and isinstance(rval.func, ast.Name):
177177
handler = MapProcessorRegistry.get_processor(rval.func.id)
178178
if handler is None:
179-
# Falling back to a hash map here used to produce an object that
180-
# compiled cleanly and was then rejected by the kernel, because the
181-
# map carried the wrong type and none of the real map type's
182-
# validation ran. A misspelled map type is a program error.
179+
# Raise an exception and fail the build because the
180+
# map carried the wrong type. A misspelled map type
181+
# is a program error.
183182
known = ", ".join(sorted(MapProcessorRegistry.known_types()))
184183
raise ValueError(
185184
f"Unknown map type '{rval.func.id}' returned by '{map_name}'. "

0 commit comments

Comments
 (0)