Pong tutorial not working?

404 views
Skip to first unread message

Andrew Doberstein

unread,
Mar 28, 2013, 1:41:22 PM3/28/13
to kivy-...@googlegroups.com
I'm fairly new to python and am trying to use the Pong tutorial to learn Kivy.  Unfortunately, even when I copy/paste the code in its entirety into my files, the tutorial doesn't work! 
Other kivy stuff does run, including the simpler versions of the pong tutorial before the ball is introduced. The only thing I have changed is the comment at the top of the Kivy file to match my version number of Kivy.

I'm working on a computer lab computer, it's running Windows 7 Enterprise. Here's what happens when I try to run main.py:

[INFO              ] Kivy v1.4.1
[INFO              ] [Logger      ] Record log in C:\Users\labuser\.kivy\logs\kivy_13-03-28_3.txt
[INFO              ] [Factory     ] 123 symbols loaded
[DEBUG             ] [Cache       ] register <kv.lang> with limit=None, timeout=Nones
[DEBUG             ] [Cache       ] register <kv.image> with limit=None, timeout=60s
[DEBUG             ] [Cache       ] register <kv.atlas> with limit=None, timeout=Nones
[DEBUG             ] [Cache       ] register <kv.texture> with limit=1000, timeout=60s
[DEBUG             ] [Cache       ] register <kv.shader> with limit=1000, timeout=60s
[INFO              ] [Window      ] using <pygame> as window provider
[INFO              ] [GL          ] OpenGL version <4.1.10524 Compatibility Profile Context>
[INFO              ] [GL          ] OpenGL vendor <ATI Technologies Inc.>
[INFO              ] [GL          ] OpenGL renderer <ATI Radeon HD 5450>
[INFO              ] [GL          ] Shading version <4.10>
[INFO              ] [GL          ] Texture max size <16384>
[INFO              ] [GL          ] Texture max units <16>
[INFO              ] [GL          ] OpenGL parsed version: 4, 1
[INFO              ] [Shader      ] fragment shader: <Fragment shader was successfully compiled to run on hardware.>
[INFO              ] [Shader      ] fragment compiled successfully
[INFO              ] [Shader      ] vertex shader: <Vertex shader was successfully compiled to run on hardware.>
[INFO              ] [Shader      ] vertex compiled successfully
[INFO              ] [Shader      ] program: <Vertex shader(s) linked, fragment shader(s) linked.>
[DEBUG             ] [ImagePygame ] Load <C:\Python27\lib\site-packages\kivy\data\glsl\default.png>
[INFO              ] [Window      ] virtual keyboard not allowed, single mode, not docked
[INFO              ] [Text        ] using <pygame> as text provider
 Traceback (most recent call last):
   File "C:\Users\labuser\Desktop\main.py", line 74, in <module>
     PongApp().run()
   File "C:\Python27\lib\site-packages\kivy\app.py", line 523, in run
     root = self.build()
   File "C:\Users\labuser\Desktop\main.py", line 67, in build
     game = PongGame()
   File "C:\Python27\lib\site-packages\kivy\uix\widget.py", line 113, in __init__
     Builder.apply(self)
   File "C:\Python27\lib\site-packages\kivy\lang.py", line 1217, in apply
     self._apply_rule(widget, rule, rule)
   File "C:\Python27\lib\site-packages\kivy\lang.py", line 1271, in _apply_rule
     cls = Factory_get(cname)
   File "C:\Python27\lib\site-packages\kivy\factory.py", line 70, in __getattr__
     raise FactoryException('Unknown class <%s>' % name)
 kivy.factory.FactoryException: Unknown class <PongBall>



Apparently, it doesn't know what <PongBall> is? But I copy/pasted the code so it's exactly like the examples, and I can see that PongBall is definitely defined:


 
Anyone know what's going on?

krister viirsaar

unread,
Mar 28, 2013, 2:14:18 PM3/28/13
to kivy-...@googlegroups.com
yes, you're missing the pong.kv. That's the bottom part of the code on that page you posted.

Akshay Arora

unread,
Mar 28, 2013, 3:11:21 PM3/28/13
to kivy-...@googlegroups.com

[INFO              ] Kivy v1.4.1

Please update your Kivy installation!!

Best Regards


On Thu, Mar 28, 2013 at 11:44 PM, krister viirsaar <krister....@gmail.com> wrote:
yes, you're missing the pong.kv. That's the bottom part of the code on that page you posted.

--
You received this message because you are subscribed to the Google Groups "Kivy users support" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kivy-users+...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Tu Chu

unread,
Sep 9, 2015, 3:07:24 PM9/9/15
to Kivy users support
Hi,
I running version 1.9.0, but i still that error :(
Help me.


Vào 02:11:21 UTC+7 Thứ Sáu, ngày 29 tháng 3 năm 2013, qua-non đã viết:

Tu Chu

unread,
Sep 16, 2015, 2:51:44 AM9/16/15
to Kivy users support
This my error


Reply all
Reply to author
Forward
0 new messages