Error calling nw by command-line

2 views
Skip to first unread message

josea...@gmail.com

unread,
Aug 30, 2013, 2:29:37 PM8/30/13
to node-...@googlegroups.com
Hello everyone.

We use node-webkit to preview a invoice/bill XML file and he´s called from command-line like:

nw LeitorXML file.xml

LeitorXML is a HTML5 with some js scripts and file.xml is a optional argument: we could run only 'nw LeitorXML' and then drag´n´drop the xml file. It´s basically a offline report viewer. It is called from a PROGRESS application.


Everything was working fine but today one of our clients is having the following error:

Uncaught node.js Error TypeError: Cannot set property 'innerHTML' of null at  
PreencheDadosNFe (file:///X:/progress/ocx/node-webkit/LeitorXML/js/js-xml-nfe.js:735:52) at 
PreencheDadosXML (file:///X:/progress/ocx/node-webkit/LeitorXML/js/js-util.js:188:33) at 
file:///X:/progress/ocx/node-webkit/LeitorXML/js/js-nw.js:21:3 at fs.js:266:14 at 
Object.oncomplete (fs.js:107:15)
The command-line that PROGRESS is calling is:

X:\progress\ocx\node-webkit>nw.exe X:\progress\ocx\node-webkit\LeitorXML X:\progress\lst\xml\43130895323994000355550000000647151000647157-procNFe.xml

The paths are correct, so is not this.
The app and the xml file are also ok, cause if is loaded by drag´n´drop works ok.
If we move the nw / app / xml file to other location or drive letter, it work ok.

So, the problem is the path: length or maybe drive letter?

I already downloaded the last version, with this fix:

* Fix regression: app cannot start from path contains '\x' (win) 

 but the error persists. Anyone has any hint?

Thanks in advance,

José Posser

josea...@gmail.com

unread,
Sep 11, 2013, 8:24:28 AM9/11/13
to node-...@googlegroups.com, josea...@gmail.com
Solved using some setTimeout before fetch the xml file, seems the some network delay fetching the file was causing the issue.
Reply all
Reply to author
Forward
0 new messages