Description
I have small Windows module that relies on the ctypes core module. On the project RTD site the page for the module comes up empty. Looking at the latest almost successful build log https://readthedocs.org/builds/apt/2900858/ there is a failure during make html stage.
File "/var/build/user_builds/apt/checkouts/latest/knownpaths.py", line 5, in <module>
from ctypes import windll, wintypes
File "/usr/lib/python2.7/ctypes/wintypes.py", line 23, in <module>
class VARIANT_BOOL(_SimpleCData):
ValueError: _type_ 'v' not supported
Following the FAQ entry https://read-the-docs.readthedocs.org/en/latest/faq.html#i-get-import-errors-on-libraries-that-depend-on-c-modules I tried to fake import ctypes using mock
, but doing so cause the build to fail completely. From what I can tell, but I'm no means an expert in this area, it's because mock itself is missing some math functions:
File "/var/build/user_builds/apt/checkouts/latest/knownpaths.py", line 13, in GUID
("Data4", wintypes.BYTE * 8)
TypeError: unsupported operand type(s) for *: 'Mock' and 'int'
Full details of the trouble and steps taken so far at maphew/apt#48
Am I following the right path? Can ctypes be used in a project on RTD and I just need to persevere?