VPython redirecting to localhost

2.8k views Asked by At

I have installed vpython (check http://vpython.org/ ) in python 3.6 (and Windows 10) from cmd by typing pip install vpython, and it installed successfully.

But when I type from vpython import * in IDLE, even after a couple of reinstalling, it's redirecting me to localhost:50484, and I can't do any Vpython stuff in IDLE.

What should I do to fix the issue, and run VPython on my PC properly ?

After googling up, I think my problem of vpython is pretty unique.

4

There are 4 answers

2
Jaffer Wilson On BEST ANSWER

I have tried installing the Vpython by opening the cmd with administrative permission.

Then I wrote the lines on python console:

Python 3.6.0 (v3.6.0:41df79263a11, Dec 23 2016, 07:18:10) [MSC v.1900 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> from vpython import *
>>> box()
<vpython.vpython.box object at 0x0497E770>
>>>

Here is the output what I got:

Vpython image

5
orangeInk On

I'm pretty sure that browser window is rendering your output. I've just installed vpython and when I type from vpython import * in the python console a browser window opens just like you said. After that I go back into my python console and type box() which draws a box inside that browser window.

Edit: I installed with conda install -c vpython vpython

0
user1114907 On

At the start of http://vpython.org/contents/docs/curve.html is this important statement:

This is documentation for Classic VPython (VPython 6), which continues to be available but is no longer supported. See vpython.org for information on installing VPython 7 or using GlowScript VPython. Documentation is available at glowscript.org by clicking Help.

Since you are using the vpython module, you need to read the documentation for the vpython module (VPython 7). Here for example is the curve documentation:

http://www.glowscript.org/docs/VPythonDocs/curve.html

0
AudioBubble On

After importing vpython(don't close the browser(vpython window)) Check dir the of the vpython using command dir(vpython) it contains the HTTPserver and many other useful classes... check that out .. this may help you ..