8000 Add Locations Filter for Instrumented Locations by 4e6 · Pull Request #1564 · enso-org/enso · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Add Locations Filter for Instrumented Locations #1564

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

Merged
merged 7 commits into from
Mar 12, 2021

Conversation

4e6
Copy link
Contributor
@4e6 4e6 commented Mar 10, 2021

Pull Request Description

close #1529

PR adds the location filter that excludes lambdas and local functions from the instrumentation.

Changelog:
feat: implement locations filter that extracts a comprehensive list of locations that should be instrumented
feat: instantiate the runtime instrument using the new location filter
test: add test suite that checks instrumented locations

Important Notes

Checklist

Please include the following checklist in your PR:

  • The documentation has been updated if necessary.
  • All code conforms to the Scala, Java, and Rust style guides.
  • All documentation and configuration conforms to the markdown and YAML style guides.
  • All code has been tested where possible.

@4e6 4e6 added Type: Enhancement p-high Should be completed in the next sprint labels Mar 10, 2021
@4e6 4e6 self-assigned this Mar 10, 2021
Copy link
Contributor
@kustosz kustosz left a comment

Choose a reason for hiding this comment

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

  1. The code looks good.
  2. Tested this build in the IDE – my original "lambda slow" case is now indeed fixed. Using the _ sugar instead of a lambda in the same spot is also fixed.
  3. Before merging, please clarify for me the status of the block tests – why are they pending and why do they assert thunks in places that should be forces.

context.receive(4) should contain allOf (
Api.Response(requestId, Api.PushContextResponse(contextId)),
TestMessages.update(contextId, xExpr, Constants.THUNK),
TestMessages.update(contextId, mainRes, Constants.THUNK),
Copy link
Contributor

Choose a reason for hiding this comment

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

this should be an integer, not a thunk

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's pending because of #1567

context.receive(5) should contain allOf (
Api.Response(requestId, Api.PushContextResponse(contextId)),
TestMessages.update(contextId, xExpr, Constants.THUNK),
TestMessages.update(contextId, mainRes, Constants.THUNK),
Copy link
Contributor

Choose a reason for hiding this comment

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

this should be an integer, not a thunk

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's pending because of #1567

}

it should "not instrument sugared lambdas in block expressions" in {
pending
Copy link
Contributor

Choose a reason for hiding this comment

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

why are these pending?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's pending because of #1566

@4e6 4e6 merged commit b0680d0 into main Mar 12, 2021
@4e6 4e6 deleted the wip/db/not-instrument-functions branch March 12, 2021 11:27
iamrecursion pushed a commit that referenced this pull request Mar 16, 2021
PR adds the location filter that excludes lambdas 
and local functions from the instrumentation.
@JaroslavTulach
Copy link
Member

LocationFilter based on sections doesn't work well with incremental source updates and I am doing my best to remove it altogether.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p-high Should be completed in the next sprint
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Mapping a lambda in the IDE is very slow
3 participants
Add this suggestion to a batch that can be applied as a single commit. This suggestion is invalid because no changes were made to the code. Suggestions cannot be applied while the pull request is closed. Suggestions cannot be applied while viewing a subset of changes. Only one suggestion per line can be applied in a batch. Add this suggestion to a batch that can be applied as a single commit. Applying suggestions on deleted lines is not supported. You must change the existing code in this line in order to create a valid suggestion. Outdated suggestions cannot be applied. This suggestion has been applied or marked resolved. Suggestions cannot be applied from pending reviews. Suggestions cannot be applied on multi-line comments. Suggestions cannot be applied while the pull request is queued to merge. Suggestion cannot be applied right now. Please check back later.
0