Azure automation failed importing python xlsxwriter library

Xu, Yifan 1 Reputation point
2021-12-29T06:54:56.44+00:00

The following showed what I did in Azure portal and how the import effort failed.

Upload File (.whl or .tar.gz format, 100 MB max size)
"XlsxWriter-3.0.2.tar.gz"

Name
XlsxWriter

Runtime version
2.7.12

Last modified
12/28/2021, 9:36:22 PM
Package version
Size
0 KB
Status
Failed
Runtime version
2.7.12
Error
Orchestrator.Activities.PythonPackageExtractException: Error while extractinig Python package: pip could not convert tar.gz file C:\Users\Client\Temp\XlsxWriter.tar.gz to wheel file Processing c:\users\client\temp\xlsxwriter.tar.gz No files/directories in c:\users\client\temp\pip-l9m25e-build\pip-egg-info (from PKG-INFO) You are using pip version 9.0.1, however version 21.3.1 is available. You should consider upgrading via the 'python -m pip install --upgrade pip' command. at Orchestrator.Activities.SetModuleActivity.ExecuteInternal(CodeActivityContext context, Byte[] moduleContent, String moduleName, ModuleLanguage moduleLanguage, Guid moduleVersionId, String modulePath) at Orchestrator.Activities.SetModuleActivity.Execute(CodeActivityContext context) at System.Activities.CodeActivity.InternalExecute(ActivityInstance instance, ActivityExecutor executor, BookmarkManager bookmarkManager) at System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor executor, BookmarkManager bookmarkManager, Location resultLocation)

Azure Automation
Azure Automation
An Azure service that is used to automate, configure, and install updates across hybrid environments.
1,366 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. SwathiDhanwada-MSFT 18,996 Reputation points Moderator
    2022-01-03T06:46:36.983+00:00

    @Xu, Yifan Welcome to Microsoft Q & A Community Forum. I have tried to reproduce the issue you are facing. However, I was able to load the package successfully. Sharing the steps here for your reference.

    • Downloaded XlsxWriter 3.0.2 from this link.
    • In your Automation account, select Python packages under Shared Resources. Click + Add a Python package.
    • On the Add Python Package page, select a "XlsxWriter-3.0.2.tar.gz" package to upload.
      161828-image.png
    • Make sure to select Runtime Version as 3.8.0 (preview) as the "XlsxWriter" package needs python version >= 3.4 List item
    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.