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
Capture traces for updateParseTreeOnEdit #4101
base: main
Are you sure you want to change the base?
Conversation
@valerybugakov Saw that there's also |
const updatedTree = parser.safeParse(document.getText(), tree) | ||
parseTreesPerFile.set(cacheKey, updatedTree) | ||
wrapInActiveSpan('updateParseTreeOnEdit', span => { | ||
span.setAttribute('sampled', true) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we want to sample all these spans? The volume will be huge.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No I think that would probably be too large, I agree.
}) | ||
} | ||
|
||
const updatedTree = parser.safeParse(document.getText(), tree) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we decide to sample all spans here, we can move span.setAttribute('sampled', true)
and span.setAttribute('languageId', languageId)
into the observableParse
and use it here.
@philipp-spiess, that's right. I didn't instrument this part because it happens on every keystroke change. |
Capture traces for
updateParseTreeOnEdit
Test plan