Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ffpython import fontforge & psMat modules error on Windows #3981

Open
snoopy-coder opened this issue Oct 19, 2019 · 9 comments
Open

ffpython import fontforge & psMat modules error on Windows #3981

snoopy-coder opened this issue Oct 19, 2019 · 9 comments
Labels

Comments

@snoopy-coder
Copy link

snoopy-coder commented Oct 19, 2019

I'm trying to install fontforge and psMat modules, but I'm having trouble with this error:

Python 3.7.4 (default, Jul 30 2019, 07:47:48)  [GCC 9.1.0 32 bit] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import fontforge
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: DLL load failed: The specified procedure could not be found.
>>> import psMat
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: DLL load failed: The specified procedure could not be found.
>>>

I checked this problem on two releases - Aug 1,2019 (Python 3.7.4) & Apr 13, 2019 (Python 2.7.16) - the result is absolutely the same. Thanks in advance for any help you might offer as I am helpless.

@jtanx
Copy link
Contributor

jtanx commented Oct 19, 2019

What's your Windows version?

@snoopy-coder
Copy link
Author

Windows 7 SP1 x64 (6.1.7601)

@jtanx
Copy link
Contributor

jtanx commented Oct 19, 2019

If you go to C:\Program Files (x86)\FontForgeBuilds\bin in Windows Explorer and double click on ffpython.exe, what happens? It should launch the python console. If it doesn't it should tell you what dll is missing.

@snoopy-coder
Copy link
Author

I run fontforge-console.bat from C:\Program Files (x86)\FontForgeBuilds and then I run ffpython.exe manually:


Enlarge

I suspect that violated any dependencies fontforge.pyd and psMat.pyd from C:\Program Files (x86)\FontForgeBuilds\lib\python3.7\site-packages

@jtanx
Copy link
Contributor

jtanx commented Oct 19, 2019

There's a couple of things you can try:

  1. If you run ffpython -v, what do you see when you import the module? This is what I see on Windows 7:
    image
  2. Get dependency walker, copy fontforge.pyd into the bin folder, and open that fontforge.pyd in the dependency walker. See what dll is missing

@snoopy-coder
Copy link
Author

Unfortunately, I could not find anything definite, except verbose log (ffpython.exe -v):

Python 3.7.4 (default, Jul 30 2019, 07:47:48)  [GCC 9.1.0 32 bit] on win32
Type "help", "copyright", "credits" or "license" for more information.
import 'atexit' # <class '_frozen_importlib.BuiltinImporter'>
>>> import fontforge
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "<frozen importlib._bootstrap>", line 983, in _find_and_load
  File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 670, in _load_unlocked
  File "<frozen importlib._bootstrap>", line 583, in module_from_spec
  File "<frozen importlib._bootstrap_external>", line 1043, in create_module
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
ImportError: DLL load failed: The specified procedure could not be found.
>>> import psMat
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "<frozen importlib._bootstrap>", line 983, in _find_and_load
  File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 670, in _load_unlocked
  File "<frozen importlib._bootstrap>", line 583, in module_from_spec
  File "<frozen importlib._bootstrap_external>", line 1043, in create_module
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
ImportError: DLL load failed: The specified procedure could not be found.
>>>

And outdated FontForge discussion thread on sourceforge.net describing a similar problem.

@snoopy-coder
Copy link
Author

Through trial and error I finally found the solution here.

@kiwi0fruit
Copy link

It's still not fixed? I uninstalled FontForge-2019-08-01-Windows.exe and installed FontForge-2019-03-17-Windows.exe -- bug is gone.

@ctrlcctrlv
Copy link
Member

I'll reopen this bug for you; I agree with you that it's still an issue and installing third party stuff as @snoopy-coder did is not an acceptable solution long term for the project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants