Skip to main content

We recently installed FME 2020 we get the following error message when running workspaces with a Python Startup Script

Python Exception <ImportError>: No module named fmeobjects
Failed to import `fmesite'

 

System setup:

  • Microsoft Windows Server 2016 Standard
  • FME Desktop 2020.0 64-bit
  • ArcGIS Desktop 10.6.1
  • ArcGIS Desktop Background Geoprocessing 10.6.1 (64-bit) + 
  • ArcGIS Desktop Background Geoprocessing patch for Oracle 19C
  • Oracle Client 19c
  • Oracle instant client 19.5 64-bit

Workspace settings:

  • Preferred Python Interpreter: Esri ArcGIS Python 2.7
  • Python Compatibility: Esri ArcGIS Python 2.7

 

The problem doesn't occur in our previous version (FME 2019.2.2) with the other settings the same, so it seems it only occurs with FME 2020.

Any idea how to fix this?

 

Check the environment variables, in particular that if you have PYTHONHOME defined, that it points to the 64-bit Python, e.g. C:\\Python27\\ArcGISx6410.6


Check the environment variables, in particular that if you have PYTHONHOME defined, that it points to the 64-bit Python, e.g. C:\\Python27\\ArcGISx6410.6

Already tried setting PYTHONHOME to C:\\Python27\\ArcGISx6410.6, but that didn't help.

 

With FME 2019.2.2 we didn't have the PYTHONHOME variable, and it worked fine.

Did anything in FME 2020 regarding python processing?


Already tried setting PYTHONHOME to C:\\Python27\\ArcGISx6410.6, but that didn't help.

 

With FME 2019.2.2 we didn't have the PYTHONHOME variable, and it worked fine.

Did anything in FME 2020 regarding python processing?

Is the PYTHONPATH environment variable defined on your system? If so, what is the value?

I do not know if something fundamental changed in FME 2020 regarding Python, you may have to contact Safe support for that.

If you feel like digging into it yourself, this is a very good resource that explains how imports and search paths work: https://www.devdungeon.com/content/python-import-syspath-and-pythonpath-tutorial#toc-13


Is the PYTHONPATH environment variable defined on your system? If so, what is the value?

I do not know if something fundamental changed in FME 2020 regarding Python, you may have to contact Safe support for that.

If you feel like digging into it yourself, this is a very good resource that explains how imports and search paths work: https://www.devdungeon.com/content/python-import-syspath-and-pythonpath-tutorial#toc-13

Tried PYTHONPATH=C:\\Python27\\ArcGISx6410.6 also

Didn't help


Tried PYTHONPATH=C:\\Python27\\ArcGISx6410.6 also

Didn't help

You may already know this, but I'll mention it just in case: whenever these environment variables are changed, at the very minimum FME needs to be restarted completely. I've also seen instances where a reboot was necessary.

My recommendation would be to set PYTHONHOME and to leave PYTHONPATH undefined (not set).


Since Python 2.7 is deprecated, it is only installed by choice. Could it be as simple as 2.7 not getting installed?


Since Python 2.7 is deprecated, it is only installed by choice. Could it be as simple as 2.7 not getting installed?

Python 2.7 is installed by ArcGIS in C:\\Python27\\ArcGIS10.2

and the Python 2.7 64-bit is installed by ArcGIS Desktop Background Geoprocessing in C:\\Python27\\ArcGISx6410.2


Python 2.7 is installed by ArcGIS in C:\\Python27\\ArcGIS10.2

and the Python 2.7 64-bit is installed by ArcGIS Desktop Background Geoprocessing in C:\\Python27\\ArcGISx6410.2

But I could imagine you would need some 2.7 fme libraries as well, which I guess only get installed with FME Python 2.7.

But I am just second-guessing and may be talking nonsense....


I would say its because python 2.7 libraries for FME are no longer installed by default. Even if you are using a 2.7 interpreter and trying to use fme modules then you would need to have them installed.

 

 

If you must use Python 2.7 I would suggest reinstalling and check the box to install the 2.7 python libraries.

 

 


But I could imagine you would need some 2.7 fme libraries as well, which I guess only get installed with FME Python 2.7.

But I am just second-guessing and may be talking nonsense....

Yes this seems right to me @arnold_bijlsma


I would say its because python 2.7 libraries for FME are no longer installed by default. Even if you are using a 2.7 interpreter and trying to use fme modules then you would need to have them installed.

 

 

If you must use Python 2.7 I would suggest reinstalling and check the box to install the 2.7 python libraries.

 

 

Entirely agree as well.

I would say its because python 2.7 libraries for FME are no longer installed by default. Even if you are using a 2.7 interpreter and trying to use fme modules then you would need to have them installed.

 

 

If you must use Python 2.7 I would suggest reinstalling and check the box to install the 2.7 python libraries.

 

 

You can see that the python27 libraries no longer exist by default in the FME 2020 install folder.

 

 


I would say its because python 2.7 libraries for FME are no longer installed by default. Even if you are using a 2.7 interpreter and trying to use fme modules then you would need to have them installed.

 

 

If you must use Python 2.7 I would suggest reinstalling and check the box to install the 2.7 python libraries.

 

 

Yes, that fixed the problem!

On my earlier install I didn't check the python 2.7 checkbox, since that wasn't necessary in previous versions.

 

Thanks a lot for all your quick answers.

 


But I could imagine you would need some 2.7 fme libraries as well, which I guess only get installed with FME Python 2.7.

But I am just second-guessing and may be talking nonsense....

Yes, the problem was with the installation. I should have check the checkbox for installing Python 2.7

Though that wasn't necessary, because python 2.7 was already installed with ArcGIS and in previous versions that was enough.

Thank for your quick answers and replies.


Reply