Comments (19)
Can you provide more details? I think, 'localhost' is more future-proof because it can resolve to an iPv6 address (::1) instead of the IPv4 address.
from nengo-gui.
Can you provide more details? I think, 'localhost' is more future-proof because it can resolve to an iPv6 address (::1) instead of the IPv4 address.
Ooo... good point. Forgot about that.
The problem was that on his machine somehow the browser refused to resolve localhost and went to http://www.localhost.com/ instead. I've never seen a computer do that before, and indeed, didn't even know it was possible.
from nengo-gui.
One could argue that it is problem with his configuration. Maybe this one?
from nengo-gui.
One could argue that it is problem with his configuration. Maybe this one?
Oh no.... that's exactly what's happening. We pop open the browser window slightly before the server gets started, and so if firefox tries to open up the page before the server is ready, it doesn't respond to the initial request, gives up, and tries localhost.com
and www.localhost.com
instead. Ouch.
So the real solution is to keep things aimed at localhost
, but not call webbrowser.open()
until after we're sure the server is ready. Otherwise we can hit this race condition.
from nengo-gui.
So I tried the solution on the link Jan posted. The localhost no longer resolves to www.localhost.com http://www.localhost.com/ but just localhost:8080 doesn’t work either. Only 127.0.0.1:8080 works for me…
On Jan 22, 2015, at 5:41 PM, tcstewar [email protected] wrote:
One could argue that it is problem with his configuration. Maybe this one?
Oh no.... that's exactly what's happening. We pop open the browser window slightly before the server gets started, and so if firefox tries to open up the page before the server is ready, it doesn't respond to the initial request, gives up, and tries localhost.com and www.localhost.com instead. Ouch.
So the real solution is to keep things aimed at localhost, but not call webbrowser.open() until after we're sure the server is ready. Otherwise we can hit this race condition.
—
Reply to this email directly or view it on GitHub #21 (comment).
from nengo-gui.
Websocket now queries the document.URL in order to connect websockets.
from nengo-gui.
Websocket now queries the document.URL in order to connect websockets.
That's not the problem here. The problem is that the document URL itself doesn't work, not the websockets.
I haven't seen this problem in a while except on on Mac a few weeks ago. But the fix was still to manually go to http://127.0.0.1:8080 rather than http://localhost:8080
from nengo-gui.
The IPython visualization waits until the server is started. So we might be able to reuse that code.
from nengo-gui.
The IPython visualization waits until the server is started. So we might be able to reuse that code.
Possibly. I'd like to have access to a machine where the problem exists, though, before trying to debug it, as I'm not 100% convinced that it's a startup time thing.
from nengo-gui.
How about inserting a sleep
in the startup to see whether you can reproduce it? That doesn't guarantee that there is not an additional problem, but at least it allows to verify that part.
from nengo-gui.
How about inserting a sleep in the startup to see whether you can reproduce it?
Ooo, good idea.. lemme try that...
Argh, nope, even with a 30-second sleep neither Firefox nor Chrome give up for me. And it was never anywhere close to that amount of time in previous situations I've seen this in.
from nengo-gui.
So I think that puts me back to thinking this is an IPv4 vs IPv6 issue... it might have been on a machine that was treating localhost
as ::1
instead of as 127.0.0.1
, and I'm pretty sure I haven't turned on support for IPv6 in swi.py. So that might be all that's happening here.....
from nengo-gui.
Is this resolved by #673?
from nengo-gui.
No. It is still using localhost
and does not support IPv6. Though, IPv6 support is easy to turn on, but the websocket implementation has to be change too to accept those connections (shouldn't be too complicated either).
from nengo-gui.
This needs to get looked at again, especially since @jgosmann 's server refactoring. It'd be great to have IPv6 support. The initially reported issue seems very rare (and we don't currently have a machine that's exhibiting it), but my current belief is that if we had full IPv6 support, then the problem wouldn't happen.
from nengo-gui.
Seems like we're currently not supporting IPv6. Replacing IPv4 with IPv6 support would probably be easy with 2 or 3 lines changed, but supporting IPv4 and IPv6 is a bit harder. Here are some links with helpful information:
- https://bugs.python.org/issue17561
- https://code.activestate.com/recipes/578504-server-supporting-ipv4-and-ipv6/
from nengo-gui.
#864 adds dual stack IPv6 support. Not sure if that resolves this problem?
from nengo-gui.
Did anyone see this problem in the last year or can this be closed?
from nengo-gui.
As far as I can tell, this issues hasn't come up again, and there has been no further update since the the last request so I am going to close this out.
from nengo-gui.
Related Issues (20)
- Give name from assignment higher precedence than label HOT 9
- Feedback submission form
- Modifying settings for GUI embedded in Jupyter HOT 2
- Deliver files with appropriate MIME type header
- InlineGUI server extension not compatible with Tornado 6 HOT 1
- Modulatory connections are drawn to (0,0) HOT 1
- Simulation doesn't read values from input slider on start HOT 1
- Simulation Doesn't Run, Windows 10 OS
- Update embedded GUI example HOT 1
- Wrong semantic pointer plot values when showing pairs HOT 5
- Piecewise import error HOT 2
- Minor comments fix in hbb_tutorials, chapters 6 & 7
- In hbb_tutorials, chapter 7, example 4 iterator for projection too small
- InlineGUI depends on notebook package
- Need some intuition just output few schematic point variable in one plot HOT 1
- Signal dict KeyError when displaying voltage plots with a model containing more than one ensemble HOT 1
- Autocompletion errors in nengo-gui on win 10 x64 with python 3.7 HOT 1
- "Module 'collections' has no attribute 'Iterable'" when running a simulation with a slider (Python 3.10) HOT 4
- Nengo GUI not loading fully in browser possibly due to CORS policy
- nengo-gui not compatible with global inline flags in python 3.11 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 nengo-gui.