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(platforms): platforms cannot use "this" in hooks #5412

Merged
merged 1 commit into from
Jan 3, 2024

Conversation

hasanaburayyan
Copy link
Contributor

@hasanaburayyan hasanaburayyan commented Jan 3, 2024

Since I was yanking out the callbacks for synth-hooks I needed to bind their associated instance to the callback's this

Closes: #5131

Checklist

  • Title matches Winglang's style guide
  • Description explains motivation and solution
  • Tests added (always)
  • Docs updated (only required for features)
  • Added pr/e2e-full label if this feature requires end-to-end testing

By submitting this pull request, I confirm that my contribution is made under the terms of the Wing Cloud Contribution License.

@hasanaburayyan hasanaburayyan requested a review from a team as a code owner January 3, 2024 01:26
@monadabot
Copy link
Contributor

Thanks for opening this pull request! 🎉
Please consult the contributing guidelines for details on how to contribute to this project.
If you need any assistence, don't hesitate to ping the relevant owner over Slack.

Topic Owner
Wing SDK and utility APIs @chriscbr
Wing Console @ainvoner, @skyrpex, @polamoros
JSON, structs, primitives and collections @hasanaburayyan
Platforms and plugins @hasanaburayyan
Frontend resources (website, react, etc) @tsuf239
Language design @eladb
VSCode extension and language server @markmcculloh
Compiler architecture, inflights, lifting @yoav-steinberg
Wing Testing Framework @tsuf239
Wing CLI @markmcculloh
Build system, dev environment, releases @markmcculloh
Library Ecosystem @chriscbr
Documentation @hasanaburayyan
SDK test suite @tsuf239
Examples @skorfmann
Wing Playground @eladcon

@hasanaburayyan
Copy link
Contributor Author

cc: @skorfmann

@monadabot
Copy link
Contributor

Console preview environment is available at https://wing-console-pr-5412.fly.dev 🚀

Last Updated (UTC) 2024-01-03 01:32

@monadabot
Copy link
Contributor

Benchmarks

Comparison to Baseline 🟥⬜⬜⬜⬜⬜⬜🟩⬜⬜⬜⬜⬜
Benchmark Before After Change
version 72ms±0.59 74ms±0.75 +2ms (+2.31%)🟥
jsii_big.test.w -t sim 3398ms±25.68 3422ms±19.23 +24ms (+0.72%)⬜
jsii_big.test.w -t tf-aws 3530ms±26.73 3528ms±23.54 -2ms (-0.05%)⬜
functions_1.test.w -t sim 644ms±6.52 639ms±8.13 -4ms (-0.67%)⬜
functions_1.test.w -t tf-aws 1726ms±44.6 1710ms±30.81 -16ms (-0.93%)⬜
hello_world.test.w -t sim 640ms±4.2 638ms±4.84 -2ms (-0.35%)⬜
hello_world.test.w -t tf-aws 5004ms±22.23 4956ms±62.06 -47ms (-0.94%)⬜
functions_10.test.w -t sim 711ms±6.96 693ms±6.68 -18ms (-2.55%)🟩
functions_10.test.w -t tf-aws 3681ms±30.13 3686ms±22.28 +5ms (+0.14%)⬜
jsii_small.test.w -t sim 609ms±4.35 602ms±5.58 -7ms (-1.16%)⬜
jsii_small.test.w -t tf-aws 730ms±7.76 731ms±6.25 +1ms (+0.14%)⬜
empty.test.w -t sim 599ms±3.09 599ms±4.19 0ms (-0.05%)⬜
empty.test.w -t tf-aws 712ms±5.02 717ms±6.67 +5ms (+0.69%)⬜

⬜ Within 1.5 standard deviations
🟩 Faster, Above 1.5 standard deviations
🟥 Slower, Above 1.5 standard deviations

Benchmarks may vary outside of normal expectations, especially when running in GitHub Actions CI.

Results
name mean min max moe sd
version 74ms 73ms 76ms 1ms 1ms
jsii_big.test.w -t sim 3422ms 3379ms 3459ms 19ms 27ms
jsii_big.test.w -t tf-aws 3528ms 3482ms 3603ms 24ms 33ms
functions_1.test.w -t sim 639ms 623ms 657ms 8ms 11ms
functions_1.test.w -t tf-aws 1710ms 1648ms 1779ms 31ms 43ms
hello_world.test.w -t sim 638ms 623ms 647ms 5ms 7ms
hello_world.test.w -t tf-aws 4956ms 4861ms 5128ms 62ms 87ms
functions_10.test.w -t sim 693ms 673ms 705ms 7ms 9ms
functions_10.test.w -t tf-aws 3686ms 3657ms 3755ms 22ms 31ms
jsii_small.test.w -t sim 602ms 591ms 613ms 6ms 8ms
jsii_small.test.w -t tf-aws 731ms 713ms 738ms 6ms 9ms
empty.test.w -t sim 599ms 589ms 607ms 4ms 6ms
empty.test.w -t tf-aws 717ms 706ms 731ms 7ms 9ms
Last Updated (UTC) 2024-01-03 01:40

Copy link
Contributor

mergify bot commented Jan 3, 2024

Thanks for contributing, @hasanaburayyan! This PR will now be added to the merge queue, or immediately merged if hasan/fix-this-platform is up-to-date with main and the queue is empty.

mergify bot added a commit that referenced this pull request Jan 3, 2024
@mergify mergify bot merged commit 6437741 into main Jan 3, 2024
21 checks passed
@mergify mergify bot deleted the hasan/fix-this-platform branch January 3, 2024 12:30
@monadabot
Copy link
Contributor

Congrats! 🚀 This was released in Wing 0.54.28.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

custom platforms can't use this
3 participants