Where is Semaphore?

Hi buddies

I’ve installed Panda3D 1.7.0, change my pythonpath to point it and all code i try to run i sadly got this message

DirectStart: Starting the game.
Traceback (most recent call last):
File “NoGame.py”, line 1, in
import direct.directbase.DirectStart
File “C:\Panda3D-1.7.0\direct\directbase\DirectStart.py”, line 3, in
from direct.showbase import ShowBase
File “C:\Panda3D-1.7.0\direct\showbase\ShowBase.py”, line 17, in
from MessengerGlobal import *
File “C:\Panda3D-1.7.0\direct\showbase\MessengerGlobal.py”, line 5, in
import Messenger
File “C:\Panda3D-1.7.0\direct\showbase\Messenger.py”, line 8, in
from direct.stdpy.threading import Lock
File “C:\Panda3D-1.7.0\direct\stdpy\threading.py”, line 256, in
class Semaphore(pm.Semaphore):
AttributeError: ‘module’ object has no attribute ‘Semaphore’

How to fix it? Where this class Semaphore?
Thanx

Semaphore is a new class in 1.7. I suspect you may still be inadvertently running the libraries from a previous version of Panda (changing pythonpath changes the Python files that are loaded, but does not necessarily change the C++ libraries that are loaded). Make sure you have updated your PATH variable as needed as well.

It might be easiest just to fully uninstall all older versions of Panda to ensure they are not conflicting.

David

Hi David

You’re right. Now everything runs fine.
Thanx :slight_smile: