Open mnn opened 8 years ago
Thanks for the report. I've only tested on Mac OS and Ubuntu runs the builds.
I'll spin up a Windows VM and investigate.
Have you tried splitting your apib
file into smaller files?
No, I haven't. Also I'm not sure other tools we use support multiple files, so it's really not a good solution (at least for us).
The input file has approx. 180kB and I was testing it on Windows 10 x64.
Hmm that's a pretty small file.
Windows 10, noted. Which Node.js version are you using?
Oh, my NodeJS is quite old (4.1.1), I'll try updating it and will report back.
Crashes also with NodeJS v5.9.0 (exactly same error).
Thanks @mnn for the update.
Are you able to email me a sanitised version of your file? I would like to test it on other OS's as well as on Win 10.
You can email me yakov at therocketsurgeon dot com
@mnn have you used the previous versions of Drakov?
I have previously had issues compiling Protagonist (Snowcrash) on a Windows machine, mainly due to my ignorance of running C compilers on Windows :)
I'm looking at the possibility of maintaining versions to give user choice as to which parser is used. See #129
I have not. But in Installation instructions
there is just npm install ...
, I didn't compile anything by hand. gcc
seems to be working (at least minimal program compiles just fine). I'm using mingw.
Is there anything else I should check to see if it's working?
if you can try doing npm install drakov@0.2.2
and see if it goes through.
That version uses protagonist which requires some C compilation.
After fixing which version of Python is node-gyp using it compiled. I converted input file to unix line endings and it works without any hacks :smile:.
PS: I'm sure it's the right version (got both installed) - it says in white Drakov 0.2.2
.
Yeah it's a pain to install Drakov + Protagonist on Windows.
I would recommend sticking with 0.2.2, until we have another mainline version that has it. Drafter.js doesn't seem to work very well on Windows for now.
@mnn in your previous comment did you mean you had it working with 1.0.0? or just 0.2.2?
@yakovkhalinsky 0.2.2 ran without any hacks, 1.0.0 run also but only after changing variable definition "TOTAL_MEMORY" in drafter.nomem.js
to ~10 times higher value. So that apparently is not an ideal solution, it will break with any update.
I'm finding the same issue here with a 420kb input file. The only solution I have found is splitting the input file into multiple.
Will see if #134 that includes a newer version of Drafter.js improves this issue and report back
When I run
drakov -f apiary.apib
it crashes after few seconds. I didn't find any way of setting anything memory related from command line.I "solved" the issue by replacing variable definition in
drafter.nomem.js
, but I would like to know a better method (one that doesn't break after update), if one exists.