Fails DuktapeRuntime::Context#call with complex identifier
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 35/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- javascript, rails, ruby
- Domain
- backend
Research direction
Start in ExecJS::DuktapeRuntime::Context#call, where the identifier is split on periods, and compare that behavior with the complex identifier passed from autoprefixer-rails/lib/autoprefixer-rails/processor.rb. Reproduce the reported call and verify that complex function identifiers are handled without breaking the existing lookup behavior.
Written by the indexing model from the issue text.
Description
I'm trying to use duktape with Rails environment:
- Rails 4.2.6
- ExecJS 2.7
- duktape 1.3.0.6
- autoprefixer-rails 6.0.3
After bundling gems I accessed the server and got ExecJS::ProgramError : identifier '(function(opts) {return eval(process' undefined .
In autoprefixer-rails, #call was called with following contexts:
apply_wrapper =
"(function(opts) {" +
"return eval(process.apply(this, opts));" +
"})"
params = params_with_browsers(opts[:from]).merge(opts)
result = runtime.call(apply_wrapper, [css, params])
In ExecJS::DuktapeRuntime::Context#call, it is parsed by identifier.split("."). It results in wrongly splitted code.
I don't know it is good to pass complex identifier for #call, but the code written as such exists.
- Dominant language
- Ruby
- Stars
- 578
- Forks
- 286
- PR merge metrics
- No merged PRs in 30d
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from rails/execjs
-
Difficulty 2/5 1-3 hours Newbie friendliness 45/100
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
-
Difficulty 4/5 3-5 days Newbie friendliness 25/100
-
Difficulty 4/5 3-5 days Newbie friendliness 25/100
Similar issues
-
Difficulty 1/5 Under an hour Newbie friendliness 90/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
バグ
Difficulty 1/5 Under an hour Newbie friendliness 92/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
voxpupuli/puppet-epel#186 · 1 comment ·
-
external_created_at is no longer used for the message timestamp since the new message UI (v4.4.0) OpenBug Frontend
Difficulty 2/5 1-3 hours Newbie friendliness 78/100