philippj / SteamworksPy

A working Python API system for Valve's Steamworks.
MIT License
214 stars 40 forks source link

Problem with util being interpreted as part of ctypes #39

Closed sudasana closed 2 years ago

sudasana commented 4 years ago

I just started using SteamworksPy, and I was only able to get everything running after I made a very small change in the main __init__.py file. Initially my attempt to import the library failed:

File "\steamworks\__init__.py", line 40, in STEAMWORKS
    _arch = util.get_arch()
AttributeError: module 'ctypes.util' has no attribute 'get_arch'

I fixed this simply by changing the steamworks util into something unique:

import steamworks.util as s_util

and

_arch = s_util.get_arch()

I'm not sure why the interpreter why understanding util as part of ctypes, but this fixed it and everything looks be be initializing fine now.

Gramps commented 4 years ago

Huh, that's pretty odd. I'll check into it! Thanks for letting me know!

sudasana commented 4 years ago

No problem, thanks for the project!