Skip to main content
Solved

Install python modules which cannot be installed with easy_install

  • July 4, 2017
  • 2 replies
  • 84 views

Hello everybody,

 

 

I want to install an external python package named xtopdf in FME.

 

The problem is that this package cannot be installed with easy_install or pip as usual. It has to be installed manually (https://bitbucket.org/vasudevram/xtopdf). That means the hints given on https://knowledge.safe.com/articles/841/install-python-modules-into-fme.html don't work here.

 

In my normal Python envorionment outside from FME I could download the zip file, unzip it in a directory 'xtopdf' in my Python directory, create an __init__.py in that directory, install a few other needed packages and it worked.

 

But in my FME Python environment it does not work like that. If I copy my xtopdf folder in the directory .../FME2017/fmepython27/Lib, install other needed packages and create a startup script where I just try to import the package 'os' as a test and this module. While 'os' could be imported 'xtopdf' could not be found!

 

 

Hope that anyone has some experience with installing python modules like that one.

 

 

Best regards,

 

Felix

Best answer by david_r

The Python installed with FME is a light-weight version that might not have all the needed dependencies in place for some third-party modules.

When dealing with scenarios like these best practice is to download and install a full Python installation (e.g. from python.org) and point FME to it. Just be careful about using a 32-bit version of Python with a 32-bit version of FME etc.

You can then easily install whichever module you need.

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

2 replies

david_r
Celebrity
  • Best Answer
  • July 4, 2017

The Python installed with FME is a light-weight version that might not have all the needed dependencies in place for some third-party modules.

When dealing with scenarios like these best practice is to download and install a full Python installation (e.g. from python.org) and point FME to it. Just be careful about using a 32-bit version of Python with a 32-bit version of FME etc.

You can then easily install whichever module you need.


danilo_fme
Celebrity
Forum|alt.badge.img+52
  • Celebrity
  • July 4, 2017

The Python installed with FME is a light-weight version that might not have all the needed dependencies in place for some third-party modules.

When dealing with scenarios like these best practice is to download and install a full Python installation (e.g. from python.org) and point FME to it. Just be careful about using a 32-bit version of Python with a 32-bit version of FME etc.

You can then easily install whichever module you need.

@david_r Perfect explanation!!!!