From 3c8cf390d47b3c9490c053db1b84fcce0decdf47 Mon Sep 17 00:00:00 2001 From: Erwin Coumans Date: Thu, 2 Jan 2020 14:45:42 -0800 Subject: [PATCH] one more fix in previous commit related to bullet_client.py --- examples/pybullet/gym/pybullet_utils/bullet_client.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/examples/pybullet/gym/pybullet_utils/bullet_client.py b/examples/pybullet/gym/pybullet_utils/bullet_client.py index a477f5c4d..0eb09f8a2 100644 --- a/examples/pybullet/gym/pybullet_utils/bullet_client.py +++ b/examples/pybullet/gym/pybullet_utils/bullet_client.py @@ -41,7 +41,8 @@ class BulletClient(object): def __getattr__(self, name): """Inject the client id into Bullet functions.""" attribute = getattr(pybullet, name) - attribute = functools.partial(attribute, physicsClientId=self._client) + if inspect.isbuiltin(attribute): + attribute = functools.partial(attribute, physicsClientId=self._client) if name=="disconnect": self._client = -1 return attribute