Describe the bug
The aspm_node_payload function in _payload/_aspm.py has a typo at line 724: "dashbaord_url" instead of "dashboard_url". This means when users pass dashboard_url= as a keyword argument to ASPM node creation operations, the payload builder never matches it (it's looking for the misspelled version), and the value is silently omitted from the request body.
To Reproduce
- Create an ASPM service class instance
- Call the node creation method passing
dashboard_url as a kwarg:
from falconpy import ASPM
falcon = ASPM(client_id="ID", client_secret="SECRET")
result = falcon.create_node(
name="my-node",
dashboard_url="https://grafana.internal/d/my-dashboard"
)
- The
dashboard_url field does not appear in the request body sent to the API. The kwarg is silently ignored.
The root cause is a typo in src/falconpy/_payload/_aspm.py line 724:
# Current (broken)
keys = ["...", "dashbaord_url", "..."]
# Should be
keys = ["...", "dashboard_url", "..."]
Expected behavior
Passing dashboard_url as a keyword argument should include it in the JSON body sent to the API.
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.create_node(body={
"name": "my-node",
"dashboard_url": "https://grafana.internal/d/my-dashboard"
})
Alternatively, users could pass the misspelled kwarg dashbaord_url= which would work but is not documented and relies on the bug persisting.
Fix: correct the typo in src/falconpy/_payload/_aspm.py line 724:
# Before
"dashbaord_url"
# After
"dashboard_url"
Describe the bug
The
aspm_node_payloadfunction in_payload/_aspm.pyhas a typo at line 724:"dashbaord_url"instead of"dashboard_url". This means when users passdashboard_url=as a keyword argument to ASPM node creation operations, the payload builder never matches it (it's looking for the misspelled version), and the value is silently omitted from the request body.To Reproduce
dashboard_urlas a kwarg:dashboard_urlfield does not appear in the request body sent to the API. The kwarg is silently ignored.The root cause is a typo in
src/falconpy/_payload/_aspm.pyline 724:Expected behavior
Passing
dashboard_urlas a keyword argument should include it in the JSON body sent to the API.Environment (please complete the following information):
Additional context
Workaround: pass a pre-built body dict to bypass the payload builder:
Alternatively, users could pass the misspelled kwarg
dashbaord_url=which would work but is not documented and relies on the bug persisting.Fix: correct the typo in
src/falconpy/_payload/_aspm.pyline 724: