Skip to main content
Solved

Import error when using paramiko and scp python libraries on FME Server


Forum|alt.badge.img+1

Hello everyone,

 

I'm using the paramiko and scp python libraries in a pythoncaller to transfer files from my local environment to a remote Linux server. When testing locally I received an import error which I could solve by removing all contents of C:\\Users\\<user>\\Documents\\FME\\Plugins\\Python and reinstalling paramiko and scp.

 

However, when I transferred the contents to the Plugin folder on my FME Server instance, managed by FME Cloud, I received the same import error I previously received on FME Desktop even though the Plugin folder on FME Server was empty to start with.

 

The import error I receive is formatted like this: Python Exception <ImportError>: cannot import name '_bycript' from partially initialized module 'bcrypt' (most likely due to a circular import) (/data/fmeserver/resources/engine/Plugins/Python/bcrypt).

 

The following python code is the source of the import error:

import paramiko

from scp import SCPClient

 

I noticed that the importerror might be related to the FME Version I am using. Both Desktop and Server are version 2021.2.5.0 Build 21816 WIN64. Locally It worked on an older version (2020.2.0.0 Build 20787 WIN64) before I reinstalled paramiko and scp to make it work on the 2021.2.5 version.

 

Thank you in advance for all the help.

Best answer by siennaatsafe

Hi @kd​ 

 

Do you know if paramiko and scp are OS specific? I've seen users need specific Linux libraries before.

 

What version of Python are you using? You may need to create a folder in FME Server if the version doesn't match the Python Compatibility setting in FME Desktop.

View original
Did this help you find an answer to your question?

2 replies

siennaatsafe
Safer
Forum|alt.badge.img+10
  • Safer
  • Best Answer
  • June 24, 2022

Hi @kd​ 

 

Do you know if paramiko and scp are OS specific? I've seen users need specific Linux libraries before.

 

What version of Python are you using? You may need to create a folder in FME Server if the version doesn't match the Python Compatibility setting in FME Desktop.


Forum|alt.badge.img+1
  • Author
  • June 27, 2022
siennaatsafe wrote:

Hi @kd​ 

 

Do you know if paramiko and scp are OS specific? I've seen users need specific Linux libraries before.

 

What version of Python are you using? You may need to create a folder in FME Server if the version doesn't match the Python Compatibility setting in FME Desktop.

Hello Sienna,

 

I managed to fix the issue using your suggestions.

I first installed paramiko and scp on a Linux server. Then I copied those files to FME Server under a new subfolder 'Resources\\Engine\\Plugins\\Python\\python38'.

 

Thank you for helping me!


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings