Skip to main content

I have a workflow that uses the SharePoint Online connector to download and upload files from SharePoint.

  • It works fine on FME Desktop on my machine
  • It works fine if I run the workspace with fme.exe from the shell on my desktop
  • It fails on our server with the following message:
Python Exception <ModuleNotFoundError>: No module named 'fmepy_microsoft_sharepoint'

I have set up a web connection for this SharePoint instance and that connection was uploaded to the server when I published the workspace.

How can I fix this issue?

The SharepointOnlineConnector is an FME package. FME Packages are not installed by default in either FME Desktop or FME Server.

When you publish a workspace that requires the SharepointOnlineConnector to FME Server you should have been prompted to upload the package at the same time. Just make sure the checkbox is ticked in the publish dialog in the step following the web connection upload.

 


Hi @tomf​ ,

thank you for your message.

To verify that this is the issue, I did the following:

  1. Deleted workflow from server
  2. Published the workflow to the server again, making sure that the box next to the package upload was ticked (which is the default)
  3. Set up a new "run-once" schedule for the workflow and triggered it

Same as before, complains about the missing Python module.


Hi @tomf​ ,

thank you for your message.

To verify that this is the issue, I did the following:

  1. Deleted workflow from server
  2. Published the workflow to the server again, making sure that the box next to the package upload was ticked (which is the default)
  3. Set up a new "run-once" schedule for the workflow and triggered it

Same as before, complains about the missing Python module.

Hi @renewe0815​ ,

 

When you first publish a package to FME Server the .fpkg file gets uploaded to Resources > Engine and the first time a job is run that contains this package transformer it should extract the package and import all the files into a series of subfolders within Resources > Engine >Packages. For the SharepointOnlineConnector, a folder safe.microsoft.sharepoint should be created within the subfolders:

- packageFiles

-python

-transformers

-resources

-webfilesystems

 

Since it complains that the module cannot be found I suspect I suspect there was a problem with the package extraction and it only partially installed the first time around.

 

To try and resolve the issue please try and remove all references of the safe.microsoft.sharepoint folder from the folders listed above. Then try rerunning the workspace that contains the transformer. Hopefully this time the package will be able to extract all the files successfully and the transformer will work. Please let me know if this continues to fail.

 

 


Hi @renewe0815​ ,

 

When you first publish a package to FME Server the .fpkg file gets uploaded to Resources > Engine and the first time a job is run that contains this package transformer it should extract the package and import all the files into a series of subfolders within Resources > Engine >Packages. For the SharepointOnlineConnector, a folder safe.microsoft.sharepoint should be created within the subfolders:

- packageFiles

-python

-transformers

-resources

-webfilesystems

 

Since it complains that the module cannot be found I suspect I suspect there was a problem with the package extraction and it only partially installed the first time around.

 

To try and resolve the issue please try and remove all references of the safe.microsoft.sharepoint folder from the folders listed above. Then try rerunning the workspace that contains the transformer. Hopefully this time the package will be able to extract all the files successfully and the transformer will work. Please let me know if this continues to fail.

 

 

Thanks @hollyatsafe​ , it will take some time for me to try this because I don't have access to the file system of the server and so I have to contact the admins to delete the files. I will post here again once I was able to try this.


Hi @renewe0815​ ,

 

When you first publish a package to FME Server the .fpkg file gets uploaded to Resources > Engine and the first time a job is run that contains this package transformer it should extract the package and import all the files into a series of subfolders within Resources > Engine >Packages. For the SharepointOnlineConnector, a folder safe.microsoft.sharepoint should be created within the subfolders:

- packageFiles

-python

-transformers

-resources

-webfilesystems

 

Since it complains that the module cannot be found I suspect I suspect there was a problem with the package extraction and it only partially installed the first time around.

 

To try and resolve the issue please try and remove all references of the safe.microsoft.sharepoint folder from the folders listed above. Then try rerunning the workspace that contains the transformer. Hopefully this time the package will be able to extract all the files successfully and the transformer will work. Please let me know if this continues to fail.

 

 

Hi @hollyatsafe​ ,

 

our admin looked in those folders and only found the "safe.s3connector" folder (presumably for managing the AWS S3 connections). There was no "safe.microsoft.sharepoint" folder, even though I published the workflow a few times already and always made sure that the connection was published, too.

What could be the reason that the folder isn't there and what could I do to fix it? In case it makes a difference, the server is running on Linux.

 


Hi @renewe0815​ ,

 

When you first publish a package to FME Server the .fpkg file gets uploaded to Resources > Engine and the first time a job is run that contains this package transformer it should extract the package and import all the files into a series of subfolders within Resources > Engine >Packages. For the SharepointOnlineConnector, a folder safe.microsoft.sharepoint should be created within the subfolders:

- packageFiles

-python

-transformers

-resources

-webfilesystems

 

Since it complains that the module cannot be found I suspect I suspect there was a problem with the package extraction and it only partially installed the first time around.

 

To try and resolve the issue please try and remove all references of the safe.microsoft.sharepoint folder from the folders listed above. Then try rerunning the workspace that contains the transformer. Hopefully this time the package will be able to extract all the files successfully and the transformer will work. Please let me know if this continues to fail.

 

 

Hi @renewe0815​ ,

 

That sounds very odd. As a workaround I'd just downloading the safe.microsoft.sharepoint.fpkg file from FME Hub and asking your System Admin to drop it in Resources > Engine and then try running your workspace to see if that works.

 

I'm not sure why the publishing wizard is unable to upload the package, could you perhaps try with some other packages and see if the result is the same? Consider creating a case with support so that we can work with you and your admin to try and diagnose the problem.


Hi @hollyatsafe​ ,

I had the newest SharePoint package installed but still no luck. I submitted a case for this issue.


Hi @renewe0815​ ,

 

When you first publish a package to FME Server the .fpkg file gets uploaded to Resources > Engine and the first time a job is run that contains this package transformer it should extract the package and import all the files into a series of subfolders within Resources > Engine >Packages. For the SharepointOnlineConnector, a folder safe.microsoft.sharepoint should be created within the subfolders:

- packageFiles

-python

-transformers

-resources

-webfilesystems

 

Since it complains that the module cannot be found I suspect I suspect there was a problem with the package extraction and it only partially installed the first time around.

 

To try and resolve the issue please try and remove all references of the safe.microsoft.sharepoint folder from the folders listed above. Then try rerunning the workspace that contains the transformer. Hopefully this time the package will be able to extract all the files successfully and the transformer will work. Please let me know if this continues to fail.

 

 

Per this thread if it works successfully on your desktop, it seems like worst case scenario that you should be able to copy the files from your C:\\Users\\{my user}\\AppData\\Roaming\\Safe Software\\FME\\Packages to your Resources/Engine/Packages folder on FME server :)


Hi @hollyatsafe​ ,

I had the newest SharePoint package installed but still no luck. I submitted a case for this issue.

I just tried reuploading this using the 21607 and it didn't seem to work, so I tried an older version (2020.1) and upload that and it seemed to work.


Reply