Categories
Fontlab Python

Fixing pip installation errors in Fontlab 7

When trying to run “Install/Update Scripts” in Fontlab 7, you may experience one of the following issues:

  • Installation fails with a “Cannot install pip” error message
  • Installation of pip may appear to be successful but a restart of Fontlab prompts the user to install pip again

These errors kept cropping up for me on Macs running macOS Big Sur. I’m running version 7.2.0 of Fontlab.

The 'Cannot install pip' error message in Fontlab 7.2.0

Fortunately this issue is fixable – well, the following method worked for me at least. The clue to solving it was at https://github.com/pypa/pip/issues/9500 – the correct version of pip needs to be downloaded before it can be installed.

To do so, open the Scripting panel by selecting Windows > Panel > Scripting.

Open the scripts list sidebar by clicking on the “Scripts List” button at the top right of the panel. Once opened, click on the “Update/Install Scripts” script in the sidebar.

The Update/Install Scripts script in Fontlab's Scripting panel with line 110 highlighted

Locate line 110 and change the URL from:

https://bootstrap.pypa.io/get-pip.py

to

https://bootstrap.pypa.io/pip/2.7/get-pip.py

(i.e. setting the specific version to match the Python installation you’re using)

If you now reload Fontlab, rerun the script, and reload once more, TypeRig and Delta Machine should now be available to you!

Incidentally, if you prefer to keep Fontlab’s Update/Install Scripts script intact, there’s nothing to stop you from copying and pasting the contents of that script into a new script, and running that instead. Anyway, hope this solves your problem!

(This post was updated on 13 June 2021 to update the get-pip URL, and to include information on pip not being present after a restart)