Section 10 of Visualizing velocity - VPython_Intro

Apologies but I appear to be going round in circles here:
I have the code working that bounces the ball between the right and left walls and if I alter the relevant vector in ball.velocity = vector(25,5,0) for example the the ball follows the associated vector path.
My problem is in Section 10 adding an arrow to visualize the ball path and going forward with the exercise, leave a trail with the arrow attached to the ball.
the code from the exercise is this:

vscale = 0.1
varr = arrow(pos=ball.pos, axis=vscale*ball.velocity, color=color.yellow)

My code that I HAD working before I tried to implement the addition of the arrow on the ball is this:

from vpython import *
ball = sphere(pos=vector(-4,0,0), radius=0.5, color=color.cyan)
wallR = box(pos=vector(6,0,0), size=vector(0.2,12,12), color=color.green)
wallL = box(pos=vector(-6,0,0), size=vector(0.2,12,12), color=color.green)
ball.velocity = vector(25,5,0)
vscale = 0.1
#varr = arrow(pos=(ball.pos), axis=(ball.velocity), color=color.yellow)
varr = arrow(pos=ball.pos, axis=vscale*ball.velocity, color=color.yellow)
deltat = 0.01
t = 0

while t < 3:
    rate(100)
    if ball.pos.x + ball.radius > wallR.pos.x:
        ball.velocity.x = -ball.velocity.x
        
    if wallL.pos.x + ball.radius > ball.pos.x:
            ball.velocity.x = -ball.velocity.x
            
    ball.pos = ball.pos + ball.velocity*deltat 
    t = t + deltat #update every deltat

Could anyone please assist and guide my understanding what I’m doing wrong please?

Before anyone can try to explain why the problem occurs, we need to be able to understand what the problem is. Not the cause (that’s what we’re here to help with) but the actual problem - i.e. the reason why you decided there is something wrong. So:

Exactly what happens when you try the last known working version of the code?

When you make the desired change, exactly what should happen, and how is that different from what already happens?

When you try your current attempt, exactly what happens? How is that different from what you want to happen?