Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix bug when a macro returns a field #37

Merged
merged 6 commits into from
Jul 27, 2020

Conversation

rw-access
Copy link
Contributor

Issues

Closes #36

Details

Fixed a bug that was introduced with #16. When a macro expanded to a field, there was an uncaught exception at

eql/eql/parser.py

Lines 721 to 722 in c76c36a

if ast_node.base not in self._var_types:
ast_node, type_hint = self._update_field_info(node, ast_node)
. The line just needed to be updated to account for NodeInfo and the current type tracking.

@rw-access rw-access added the enhancement New feature or request label Jul 27, 2020
@rw-access rw-access requested a review from brokensound77 July 27, 2020 15:32
@rw-access rw-access changed the title Fix bug when using macros with a schema Fix bug when a macro returns a field Jul 27, 2020
@rw-access rw-access added bug Something isn't working and removed enhancement New feature or request labels Jul 27, 2020
Copy link
Contributor

@brokensound77 brokensound77 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@rw-access rw-access merged commit 23a5253 into endgameinc:master Jul 27, 2020
@rw-access rw-access deleted the bug/macro-expansion-hints branch July 27, 2020 16:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Uncaught exception for macros that return fields
2 participants