Comments (10)
I did just released xmlshim 0.2.4 which is compatible with node 10.
from node-blockly.
@znerol Thanks. Now it supports NodeJS 10.x and later
from node-blockly.
I've tried your fork
"xmlshim": "git://github.com/eyz/node-xmlshim.git#be6220b53809b2c5a84be25c17e56bc4a12ba411"
Everything seems to be ok, but some tests are failed
13 passing (151ms)
2 failing
1) XML
domToText:
TypeError: xml.TextWriter is not a constructor
at exports.XMLSerializer.serializeToString (node_modules/xmlshim/index.js:24:22)
at Object.module.exports.Blockly.Xml.domToText (lib/blockly_compressed.js:1279:450)
at Context.<anonymous> (test/xml_test.js:43:30)
2) XML
domToPrettyText:
TypeError: xml.TextWriter is not a constructor
at exports.XMLSerializer.serializeToString (node_modules/xmlshim/index.js:24:22)
at Object.module.exports.Blockly.Xml.domToText (lib/blockly_compressed.js:1279:450)
at Object.module.exports.Blockly.Xml.domToPrettyText (lib/blockly_compressed.js:1280:55)
at Context.<anonymous> (test/xml_test.js:50:30)
xml.TextWriter is missing. Any ideas?
from node-blockly.
@mo4islona I'm not having any problems with this fork in my project, but yes -- I am able to reproduce those errors with the following (minimum reproduction from the pertinent code in xmlshim/index.js) -
var xml = require("libxmljs");
var textwriter = new xml.TextWriter();
I suspect this is why there was a workaround before; see the original git://github.com/znerol/libxmljs.git#xmlwriter-0.18.0
that I replaced with the latest libxmljs, at eyz/node-xmlshim@be6220b
I think the best answer here is for znerol/libxmljs to take a look at the NodeJS 10.x support, and see if there may need to be a variation of that workaround for NodeJS 10.x.
It may be that I simply don't use that code path, and haven't come across this issue myself. Do we know how to exercise this failing code path with node-blocky?
from node-blockly.
So, any updates on this or everyone is on Node 8.x or older?
from node-blockly.
@Z-AX I'm on Node 10.x on my fork (top comment, above), but I'm quite certain I'm not using all code paths in node-blockly
from node-blockly.
@eyz Me neither, but npm install
fails because of one of it's sub-dependencies.
from node-blockly.
@znerol :(
"dependencies": {
"jsdom": "^14.0.0",
"xmlshim": "^0.2.5"
}
node -v v10.15.2
gulp[48582]: ../src/node_contextify.cc:633:static void node::contextify::ContextifyScript::New(const FunctionCallbackInfo<v8::Value> &): Assertion `args[1]->IsString()' failed.
1: 0x10003860e node::Abort() [/usr/local/Cellar/node@10/10.15.2/bin/node]
2: 0x100037748 node::AddEnvironmentCleanupHook(v8::Isolate*, void (*)(void*), void*) [/usr/local/Cellar/node@10/10.15.2/bin/node]
3: 0x10005c44b node::contextify::ContextifyScript::New(v8::FunctionCallbackInfo<v8::Value> const&) [/usr/local/Cellar/node@10/10.15.2/bin/node]
4: 0x1001cfb19 v8::internal::FunctionCallbackArguments::Call(v8::internal::CallHandlerInfo*) [/usr/local/Cellar/node@10/10.15.2/bin/node]
5: 0x1001cee2f v8::internal::MaybeHandle<v8::internal::Object> v8::internal::(anonymous namespace)::HandleApiCallHelper<true>(v8::internal::Isolate*, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::FunctionTemplateInfo>, v8::internal::Handle<v8::internal::Object>, v8::internal::BuiltinArguments) [/usr/local/Cellar/node@10/10.15.2/bin/node]
6: 0x1001ce8b0 v8::internal::Builtin_Impl_HandleApiCall(v8::internal::BuiltinArguments, v8::internal::Isolate*) [/usr/local/Cellar/node@10/10.15.2/bin/node]
7: 0x21b8c4f5be3d
/var/folders/n1/0vlb066d7md10j1jckns_3dh0000gn/T/yarn--1553549475371-0.5941561074139992/node: line 3: 48582 Abort trap: 6 "/usr/local/Cellar/node@10/10.15.2/bin/node" "$@"
error Command failed with exit code 134.
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
from node-blockly.
@mo4islona this stack trace doesn't look like it is related to jsdom/xmlshim. The one in gulpjs/gulp#2162 looks quite similar though.
from node-blockly.
Thanks, folks!
from node-blockly.
Related Issues (20)
- Install Error is caused by `xmlshim` that depend on `libxmljs` HOT 4
- Possible to build on our own?
- Can't load javascript blocks HOT 2
- How to import custom blocks and generate code? HOT 2
- static files from server HOT 1
- Add /* eslint-disable */ for generated browser.js HOT 1
- Translate xml string to a javascript string in Browser HOT 4
- Usage with webpack? HOT 1
- Error when trying to generate javascript from xml that contains overridden shadows HOT 19
- Update to Blockly 2.20190722.0 (July 2019) HOT 2
- Expose blockly functions HOT 2
- Does not compile on Node 12 HOT 2
- Latest blockly version: goog is not defined HOT 4
- for help๏ผ--blockly's user block program data pass HOT 2
- goog missing in node-block/browser HOT 1
- Generator type is not always the same as block type for certain blocks HOT 2
- Blockly.JavaScript.addReservedWords() dosen't add a reserved word. HOT 1
- Update to Blockly Q2 2020? HOT 2
- Blockly.Theme.defineTheme() is not a function HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from node-blockly.