This error does not seem to affect running the vpython program or running the rest of the notebook. I see this error regularly, especially when creating a presentation that has many vpython programs in the same notebook. I do not know what causes the error. I also am not sure whether it is related to vpython or not.
A Google search on the error goes back to this ipython post from 2011.
In summary, the “error” is may be annoying but not fatal.
AT
Hello, I am learning how to code and use vpython and then I got this error from running this code with Jupyter notebook. Is there any way to solve this problem?
ERROR! Session/line number was not unique in database. History logging moved to new session 88
. . .
from vpython import *
from math import *
canvas(width=900,height=900)
proj = sphere(pos = vector(-5,0,0),
radius = 0.1,
color = color.red,
make_trail=True)
#velocity vector components
proj.speed = 10.0 #initial speed
proj.angle = 45*3.141459/180 #initial angle from the x+ axis
#velocity vector
proj.velocity = vector(proj.speed*cos(proj.angle),
proj.speed*sin(proj.angle),
0)
proj.mass = 1.0
grav_field = 9.8
#time
dt = 0.01
time =0
#loop
while(proj.pos.y >= 0):
rate(10)
#force(s)
grav_force = vector(0,-proj.mass*grav_field,0)
#Total force
force = grav_force
#Update Velocity
proj.velocity += force/proj.mass * dt
#Update Position
proj.pos += proj.velocity * dt
#Update Time
time += dt
Thanks for your answer.
--
You received this message because you are subscribed to the Google Groups "VPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
vpython-user...@googlegroups.com.
For more options, visit
https://groups.google.com/d/optout.