Describe the bug
The retrieve_relay_node_payload function in _payload/_aspm.py has a missing comma between "type" and "username" in a list literal at lines 799-800. Python silently concatenates adjacent string literals, producing "typeusername" as a single key instead of two separate keys. This means neither type nor username kwargs work for ASPM relay node retrieval operations.
To Reproduce
- Create an ASPM service class instance
- Call the relay node method passing
type or username as kwargs:
from falconpy import ASPM
falcon = ASPM(client_id="ID", client_secret="SECRET")
result = falcon.retrieve_relay_node(
type="relay",
username="admin@example.com"
)
- Neither
type nor username appear in the request body sent to the API. The kwargs are silently ignored.
The root cause is a missing comma in src/falconpy/_payload/_aspm.py lines 799-800:
# Current (broken) - implicit string concatenation
keys = ["...", "type"
"username", "..."]
# This produces: [..., "typeusername", ...]
Expected behavior
Passing type or username as keyword arguments should include them in the JSON body sent to the API, consistent with the documented kwargs in the operation docstring.
Environment (please complete the following information):
- OS: All
- Python: All supported versions
- FalconPy: --
Additional context
Workaround: pass a pre-built body dict to bypass the payload builder:
result = falcon.retrieve_relay_node(body={
"type": "relay",
"username": "admin@example.com"
})
Fix: add the missing comma in src/falconpy/_payload/_aspm.py line 799:
# Before
keys = ["...", "type"
"username", "..."]
# After
keys = ["...", "type",
"username", "..."]
Describe the bug
The
retrieve_relay_node_payloadfunction in_payload/_aspm.pyhas a missing comma between"type"and"username"in a list literal at lines 799-800. Python silently concatenates adjacent string literals, producing"typeusername"as a single key instead of two separate keys. This means neithertypenorusernamekwargs work for ASPM relay node retrieval operations.To Reproduce
typeorusernameas kwargs:typenorusernameappear in the request body sent to the API. The kwargs are silently ignored.The root cause is a missing comma in
src/falconpy/_payload/_aspm.pylines 799-800:Expected behavior
Passing
typeorusernameas keyword arguments should include them in the JSON body sent to the API, consistent with the documented kwargs in the operation docstring.Environment (please complete the following information):
Additional context
Workaround: pass a pre-built body dict to bypass the payload builder:
Fix: add the missing comma in
src/falconpy/_payload/_aspm.pyline 799: