GithubHelp home page GithubHelp logo

Remove Kernel#caller patches about opal-rspec HOT 6 CLOSED

opal avatar opal commented on July 18, 2024
Remove Kernel#caller patches

from opal-rspec.

Comments (6)

wied03 avatar wied03 commented on July 18, 2024

@elia - Do you think this belongs in a separate GEM? These Bower dependencies can be pulled in via rails-assets (I use that to represent Bower deps as GEMs on my project) but I think this probably belongs in a separate GEM.

from opal-rspec.

elia avatar elia commented on July 18, 2024

@wied03 I'm quite sure this should be optional, not necessarily by using another gem but one shouldn't be forced in. Although an argument in favor of an external gem can be made by pointing out that the gem could be independent from RSpec and just provide source-mapped backtraces to opal on nodejs.

from opal-rspec.

wied03 avatar wied03 commented on July 18, 2024

Some Kernel#caller discussion here - opal/opal#894

from opal-rspec.

wied03 avatar wied03 commented on July 18, 2024

It probably needs to be removed anyways because it's poorly tested and brittle, but removing this code in the kernel_caller_fix branch didn't improve performance that much:
image

from opal-rspec.

wied03 avatar wied03 commented on July 18, 2024

Test was conducted using time bundle exec rake opal_specs. Around 40 of the 140 tests are expected to fail so they will have exceptions regardless. I would have expected the other 100 tests that pass to improve these results more than they did.

from opal-rspec.

jgaskins avatar jgaskins commented on July 18, 2024

Just throwing it in here for posterity that the majority of time spent in RSpec overhead (that is, not the actual specs themselves) was due to break calls in Enumerable.

Considering the results in opal/opal#1450, you can probably multiply any benefit gained by at least 4x. Possibly a lot more, considering that timing the Rake task measures time between command prompts, which includes loading node, Opal, and RSpec. This is a huge portion of execution time, too. For example, Clearwater specs take about 8 seconds on my machine, but nearly all of that is load time.

A better benchmark would probably be the execution time of the specs only.

from opal-rspec.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.