mschwartz / SilkJS

V8 Based JavaScript Swiss Army Knife (and HTTP Server!)
https://github.com/decafjs/decaf
Other
323 stars 37 forks source link

httpd-silk.js blocking on Ubuntu 12.04 #31

Open rbettelh opened 11 years ago

rbettelh commented 11 years ago

After following the build and install steps on Ubuntu 12.04, httpd-silk.js seems to start successfully.

Pointing my browser to localhost:9090 effectively loads the home page from docroot. However, trying to navigate other links fails with the spinning wheel turnning for ever.

Any idea?

dgtlife commented 11 years ago

@rbettelh I had the same experience last night on Ubuntu 12.04.2 64-bit (in Virtualbox on OS X Mountain Lion); I had previously compiled and installed V8 itself, and I summarily assumed some sort of conflict between the 2 V8s. I just built SilkJS on OS X Mountain Lion and the thing works just fine (except for some child processes catching Signal 11). I can navigate to all the pages just fine. I will take another look at the Ubuntu install and see if I can figure out what's causing the issue there.

dgtlife commented 11 years ago

The behavior of the SilkJS test server is quite strange on Ubuntu 12.04.2. After a fresh install of SilkJS and running

$ ./silkjs httpd/main.js

the server starts up fine and the home page loads. But once you click on any of the navigational links on the left you get the spinning "Wait" overlay. And this happens/continues for every link. On any subsequent attempt to reload the page it does not fully reload; most time you get just a blank page with the browser indicating that it's still loading stuff. It is always waiting for some file, usually the "/jquery.mobile-1.0b1/jquery.mobile-1.0b1.min.css". I tried commenting out that header line in index.jst that asks to load this file. Once I did that, it then got stuck waiting for "sitebg.png", which is called for in silk.css. Now these are all local files.

The HTML loads fully with curl, and the View Source on Chrome confirms that it too receives the complete HTML. However, Chrome and Firefox never fully load all the elements specified in the HTML. The browser is always stuck waiting for some file.

Also, rapid reloads seem to hang the server, after which nothing loads. Once you kill it and restart it you're back to the blank page waiting for "/jquery.mobile-1.0b1/jquery.mobile-1.0b1.min.css".

Meanwhile, on OS X ML the server is happily serving for every link. So, I'll have to do my "getting to know SilkJS" on OS X, and wait for some guidance for the Ubuntu side.

ghost commented 11 years ago

@dgtlife,

Re: "...the server starts up fine and the home page loads. But once you click on any of the navigational links on the left you get the spinning "Wait" overlay."

I can report the exact same result on Debian Squeeze.

For Linux Mint 14 (Ubuntu), I get different results, but I suspect the exact same root cause. The page starts loading, but remains blank until I kill the server. It then partially renders.

dgtlife commented 11 years ago

@rbettelh, this issue was posted and resolved over in the SilkJS Google group; check the link below:

https://groups.google.com/forum/?fromgroups=#!topic/silkjs/_LHMDC7_dSo

mschwartz commented 11 years ago

I apologize for the issue guys. The Google team made code breaking API changes in V8. My fix was to force a known working revision of V8 to be used for SilkJS builds, for now.

I intend to update the SilkJS code to work with the bleeding edge versions of V8