<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/node.git/test/message, branch node-review</title>
<subtitle>github.com: joyent/node.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node.git/'/>
<entry>
<title>test: fix error messages after v8 upgrade</title>
<updated>2014-10-16T17:47:55+00:00</updated>
<author>
<name>Fedor Indutny</name>
<email>fedor@indutny.com</email>
</author>
<published>2014-10-10T22:18:34+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node.git/commit/?id=b94a3f68978f88e31d7a0c52caf01b238d0cb355'/>
<id>b94a3f68978f88e31d7a0c52caf01b238d0cb355</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge branch 'v0.10'</title>
<updated>2014-06-05T14:28:39+00:00</updated>
<author>
<name>Fedor Indutny</name>
<email>fedor@indutny.com</email>
</author>
<published>2014-06-05T14:28:39+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node.git/commit/?id=9920ae67b53283192a7396cad63f6d92b80f1a95'/>
<id>9920ae67b53283192a7396cad63f6d92b80f1a95</id>
<content type='text'>
Conflicts:
	ChangeLog
	lib/events.js
	lib/tls.js
	src/node_constants.cc
	src/node_crypto.cc
	src/node_crypto.h
	src/node_version.h
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Conflicts:
	ChangeLog
	lib/events.js
	lib/tls.js
	src/node_constants.cc
	src/node_crypto.cc
	src/node_crypto.h
	src/node_version.h
</pre>
</div>
</content>
</entry>
<entry>
<title>lib: name EventEmitter prototype methods</title>
<updated>2014-05-07T19:11:57+00:00</updated>
<author>
<name>Ben Noordhuis</name>
<email>info@bnoordhuis.nl</email>
</author>
<published>2014-05-05T14:48:51+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node.git/commit/?id=17fbdc18b8cec0b6b2827d9e3c6360b694e6e9c3'/>
<id>17fbdc18b8cec0b6b2827d9e3c6360b694e6e9c3</id>
<content type='text'>
Before this commit the EventEmitter methods were anonymous functions.
V8 tries to infer names for anonymous functions based on the execution
context but it frequently gets it wrong and when that happens, the
stack trace is usually confusing and unhelpful.  This commit names all
methods so V8 can fall back to the method.name property.

The above gotcha applies to all anonymous functions but is exacerbated
for EventEmitter methods because those are invoked with a plenitude of
different receivers.

Signed-off-by: Trevor Norris &lt;trev.norris@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Before this commit the EventEmitter methods were anonymous functions.
V8 tries to infer names for anonymous functions based on the execution
context but it frequently gets it wrong and when that happens, the
stack trace is usually confusing and unhelpful.  This commit names all
methods so V8 can fall back to the method.name property.

The above gotcha applies to all anonymous functions but is exacerbated
for EventEmitter methods because those are invoked with a plenitude of
different receivers.

Signed-off-by: Trevor Norris &lt;trev.norris@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>src: domain should not replace nextTick function</title>
<updated>2014-03-04T00:27:58+00:00</updated>
<author>
<name>Timothy J Fontaine</name>
<email>tjfontaine@gmail.com</email>
</author>
<published>2014-03-04T00:27:58+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node.git/commit/?id=06453a94a7b06df30be0148e8b1d89932350f677'/>
<id>06453a94a7b06df30be0148e8b1d89932350f677</id>
<content type='text'>
Previously if you cached process.nextTick and then require('domain')
subsequent nextTick() calls would not be caught because enqueued
functions were taking the wrong path. This keeps nextTick to a single
function reference and changes the implementation details after domain
has been required.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Previously if you cached process.nextTick and then require('domain')
subsequent nextTick() calls would not be caught because enqueued
functions were taking the wrong path. This keeps nextTick to a single
function reference and changes the implementation details after domain
has been required.
</pre>
</div>
</content>
</entry>
<entry>
<title>node: do not print SyntaxError hints to stderr</title>
<updated>2014-02-06T09:26:57+00:00</updated>
<author>
<name>Fedor Indutny</name>
<email>fedor.indutny@gmail.com</email>
</author>
<published>2014-02-05T16:38:33+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node.git/commit/?id=f1de13b8ab77f1bcab0d7cffee140a264cae4cce'/>
<id>f1de13b8ab77f1bcab0d7cffee140a264cae4cce</id>
<content type='text'>
Try embedding the ` ... ^` lines inside the `SyntaxError` (or any other
native error) object before giving up and printing them to the stderr.

fix #6920
fix #1310
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Try embedding the ` ... ^` lines inside the `SyntaxError` (or any other
native error) object before giving up and printing them to the stderr.

fix #6920
fix #1310
</pre>
</div>
</content>
</entry>
<entry>
<title>src: only access stack of non-null errors</title>
<updated>2013-12-23T11:08:11+00:00</updated>
<author>
<name>Vladimir Kurchatkin</name>
<email>vladimir.kurchatkin@gmail.com</email>
</author>
<published>2013-12-23T06:18:08+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node.git/commit/?id=055f7e9da99561a549ea887bb88ec93ad423b182'/>
<id>055f7e9da99561a549ea887bb88ec93ad423b182</id>
<content type='text'>
Avoid segmentation fault when `null` is thrown
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Avoid segmentation fault when `null` is thrown
</pre>
</div>
</content>
</entry>
<entry>
<title>src: only access stack of defined errors</title>
<updated>2013-12-10T17:33:33+00:00</updated>
<author>
<name>Vladimir Kurchatkin</name>
<email>vladimir.kurchatkin@gmail.com</email>
</author>
<published>2013-12-06T11:56:37+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node.git/commit/?id=259d44962291bc73ae60919ea6442d762ee139d2'/>
<id>259d44962291bc73ae60919ea6442d762ee139d2</id>
<content type='text'>
Avoid segmentation fault when `undefined` is thrown
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Avoid segmentation fault when `undefined` is thrown
</pre>
</div>
</content>
</entry>
<entry>
<title>vm: update API to use options argument</title>
<updated>2013-08-29T05:27:24+00:00</updated>
<author>
<name>Domenic Denicola</name>
<email>domenic@domenicdenicola.com</email>
</author>
<published>2013-08-24T22:53:24+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node.git/commit/?id=fd3657610e49005dfc778c3f060dbba0a34f286a'/>
<id>fd3657610e49005dfc778c3f060dbba0a34f286a</id>
<content type='text'>
Passing a filename is still supported in place of certain options
arguments, for backward-compatibility, but timeout and display-errors
are not translated since those were undocumented.

Also managed to eliminate an extra stack trace line by not calling
through the `createScript` export.

Added a few message tests to show how `displayErrors` works.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Passing a filename is still supported in place of certain options
arguments, for backward-compatibility, but timeout and display-errors
are not translated since those were undocumented.

Also managed to eliminate an extra stack trace line by not calling
through the `createScript` export.

Added a few message tests to show how `displayErrors` works.
</pre>
</div>
</content>
</entry>
<entry>
<title>vm, core, module: re-do vm to fix known issues</title>
<updated>2013-08-21T22:52:23+00:00</updated>
<author>
<name>Domenic Denicola</name>
<email>domenic@domenicdenicola.com</email>
</author>
<published>2013-07-27T04:34:12+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node.git/commit/?id=7afdba6e0bc3b69c2bf5fdbd59f938ac8f7a64c5'/>
<id>7afdba6e0bc3b69c2bf5fdbd59f938ac8f7a64c5</id>
<content type='text'>
As documented in #3042 and in [1], the existing vm implementation has
many problems. All of these are solved by @brianmcd's [contextify][2]
package. This commit uses contextify as a conceptual base and its code
core to overhaul the vm module and fix its many edge cases and caveats.

Functionally, this fixes #3042. In particular:

- A context is now indistinguishable from the object it is based on
  (the "sandbox"). A context is simply a sandbox that has been marked
  by the vm module, via `vm.createContext`, with special internal
  information that allows scripts to be run inside of it.
- Consequently, items added to the context from anywhere are
  immediately visible to all code that can access that context, both
  inside and outside the virtual machine.

This commit also smooths over the API very slightly:

- Parameter defaults are now uniformly triggered via `undefined`, per
  ES6 semantics and previous discussion at [3].
- Several undocumented and problematic features have been removed, e.g.
  the conflation of `vm.Script` with `vm` itself, and the fact that
  `Script` instances also had all static `vm` methods. The API is now
  exactly as documented (although arguably the existence of the
  `vm.Script` export is not yet documented, just the `Script` class
  itself).

In terms of implementation, this replaces node_script.cc with
node_contextify.cc, which is derived originally from [4] (see [5]) but
has since undergone extensive modifications and iterations to expose
the most useful C++ API and use the coding conventions and utilities of
Node core.

The bindings exposed by `process.binding('contextify')`
(node_contextify.cc) replace those formerly exposed by
`process.binding('evals')` (node_script.cc). They are:

- ContextifyScript(code, [filename]), with methods:
  - runInThisContext()
  - runInContext(sandbox, [timeout])
- makeContext(sandbox)

From this, the vm.js file builds the entire documented vm module API.

node.js and module.js were modified to use this new native binding, or
the vm module itself where possible. This introduces an extra line or
two into the stack traces of module compilation (and thus into most
stack traces), explaining the changed tests.

The tests were also updated slightly, with all vm-related simple tests
consolidated as test/simple/test-vm-* (some of them were formerly
test/simple/test-script-*). At the same time they switched from
`common.debug` to `console.error` and were updated to use
`assert.throws` instead of rolling their own error-testing methods.

New tests were also added, of course, demonstrating the new
capabilities and fixes.

[1]: http://nodejs.org/docs/v0.10.16/api/vm.html#vm_caveats
[2]: https://github.com/brianmcd/contextify
[3]: https://github.com/joyent/node/issues/5323#issuecomment-20250726
[4]: https://github.com/kkoopa/contextify/blob/bf123f3ef960f0943d1e30bda02e3163a004e964/src/contextify.cc
[5]: https://gist.github.com/domenic/6068120
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
As documented in #3042 and in [1], the existing vm implementation has
many problems. All of these are solved by @brianmcd's [contextify][2]
package. This commit uses contextify as a conceptual base and its code
core to overhaul the vm module and fix its many edge cases and caveats.

Functionally, this fixes #3042. In particular:

- A context is now indistinguishable from the object it is based on
  (the "sandbox"). A context is simply a sandbox that has been marked
  by the vm module, via `vm.createContext`, with special internal
  information that allows scripts to be run inside of it.
- Consequently, items added to the context from anywhere are
  immediately visible to all code that can access that context, both
  inside and outside the virtual machine.

This commit also smooths over the API very slightly:

- Parameter defaults are now uniformly triggered via `undefined`, per
  ES6 semantics and previous discussion at [3].
- Several undocumented and problematic features have been removed, e.g.
  the conflation of `vm.Script` with `vm` itself, and the fact that
  `Script` instances also had all static `vm` methods. The API is now
  exactly as documented (although arguably the existence of the
  `vm.Script` export is not yet documented, just the `Script` class
  itself).

In terms of implementation, this replaces node_script.cc with
node_contextify.cc, which is derived originally from [4] (see [5]) but
has since undergone extensive modifications and iterations to expose
the most useful C++ API and use the coding conventions and utilities of
Node core.

The bindings exposed by `process.binding('contextify')`
(node_contextify.cc) replace those formerly exposed by
`process.binding('evals')` (node_script.cc). They are:

- ContextifyScript(code, [filename]), with methods:
  - runInThisContext()
  - runInContext(sandbox, [timeout])
- makeContext(sandbox)

From this, the vm.js file builds the entire documented vm module API.

node.js and module.js were modified to use this new native binding, or
the vm module itself where possible. This introduces an extra line or
two into the stack traces of module compilation (and thus into most
stack traces), explaining the changed tests.

The tests were also updated slightly, with all vm-related simple tests
consolidated as test/simple/test-vm-* (some of them were formerly
test/simple/test-script-*). At the same time they switched from
`common.debug` to `console.error` and were updated to use
`assert.throws` instead of rolling their own error-testing methods.

New tests were also added, of course, demonstrating the new
capabilities and fixes.

[1]: http://nodejs.org/docs/v0.10.16/api/vm.html#vm_caveats
[2]: https://github.com/brianmcd/contextify
[3]: https://github.com/joyent/node/issues/5323#issuecomment-20250726
[4]: https://github.com/kkoopa/contextify/blob/bf123f3ef960f0943d1e30bda02e3163a004e964/src/contextify.cc
[5]: https://gist.github.com/domenic/6068120
</pre>
</div>
</content>
</entry>
<entry>
<title>test: update tests after internal api change</title>
<updated>2013-08-15T20:20:15+00:00</updated>
<author>
<name>Ben Noordhuis</name>
<email>info@bnoordhuis.nl</email>
</author>
<published>2013-08-15T20:20:04+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/node.git/commit/?id=a1ea8a27e6d3688cf694dfa9ce1d67d4c7174bad'/>
<id>a1ea8a27e6d3688cf694dfa9ce1d67d4c7174bad</id>
<content type='text'>
Commit 0aa1335 changes the way timeout events are dispatched. Update
two tests that still used the old way.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Commit 0aa1335 changes the way timeout events are dispatched. Update
two tests that still used the old way.
</pre>
</div>
</content>
</entry>
</feed>
