Developing Flows

If your organization develops and customizes flows, you can give your System Admins additional permissions by adding the “.env” file variables described in the sections below.

Uploading blocks and editing Custom Code Blocks

By default, the ALLOW_CODE_UPLOAD “.env” file variable is set to true, which allows System Admins to upload flow blocks and edit the code for Custom Code Blocks. If you want to prevent System Admins from completing these tasks, set ALLOW_CODE_UPLOAD to false.

To learn more about uploading flow blocks, contact your Hyperscience representative.

For more information on editing code in Custom Code Blocks, see Modifying Custom Code Blocks.

Managing third-party Python packages

In preparation for Python 3.9’s end-of-life in October 2025, we support the use of both Python 3.9 and Python 3.11 in Hyperscience v39.1. This support allows you to upgrade your flows and code blocks separately from the application-upgrade process, giving you the opportunity to test and upgrade your flows in the application before Python 3.9 support is removed in a future version of Hyperscience. 

Because of this dual-version support in v39.1, the steps for managing third-party Python packages in v39.1 differ from those used in previous versions of Hyperscience.

v39.1

v39.1

If developers at your organization are creating Python Code Blocks for your flows, they may want to install custom Python packages to add features to the blocks. System Admins can install and manage these packages on behalf of your developers.  

Viewing installed Python packages 

To find out which Python packages are currently installed in your application, go to Flows > Python Packages. You can use the Search text box at the top of the page to search for a specific package by its name. 

The Python Packages page contains several lists of packages.

Summary of User Installed Packages

In the Summary of User Installed Packages card, you can find a list of all the packages users at your organization have installed in your instance. Each row in the table shows the name of an installed package and indicates its compatibility with Python 3.9 and Python 3.11.

The system may have created copies of packages installed for Python 3.9 to make them accessible to flows using Python 3.11. We recommend testing these packages to ensure they work in Python 3.11 flows and updating them if newer versions are available. For more information on updating packages, see Updating Python packages.

Selecting the Show system-installed packages option adds any pre-installed packages to the table, giving you a complete list of packages in your instance, along with information about their compatibility with our supported Python versions. 

Installed Packages for Python 3.11 

The packages in the Installed Packages for Python 3.11 are available to flows using Python 3.11. By default, it shows only those packages that were installed by users at your organization. To see a list of all Python 3.11 packages, select the Show system-installed packages option.

The table contains the following information for each package:

  • The package's name. If information about the package is available on an external website, clicking the name redirects you to that website.
  • Whether the package was pre-installed, or, if it was not, the date and time it was added
  • The version of the package
  • If the package was not pre-installed, links to download or delete the package

You can also sort the table by the names of the packages and the dates they were added.

Installed Packages for Python 3.9

These packages are available to flows using Python 3.9. Just as in the Installed Packages for Python 3.11 card, you can select the Show system-installed packages option to show pre-installed packages in addition to the user-installed packages that are shown by default.

The table’s layout and sorting options are the same as those described for the Installed Packages for Python 3.11 card.

Adding packages

While several Python packages are installed in the Hyperscience application by default, developers at your organization may want to upload additional packages to meet their flow-development needs. If you are a System Admin, you can edit the application's ".env" file to allow the uploading of these packages. Then, you can upload custom Python packages on behalf of your developers.

Package requirements

The packages you install must be compatible with Python 3.9 or 3.11. If the package has any dependencies, you must also install those packages.

Enable package uploading in the application

Your application may already allow you to upload Python packages. To find out, go to Flows > Python Packages.

  • If the message at the top of the page ends with "To add more packages, please download or build a Python wheel (.whl) file, then upload below with the Add Packages button," your application already has package uploading enabled. You do not need to make any changes to your application's ".env" file, and you can follow the steps in Upload custom Python packages below.

  • If the message at the top of the page ends with "Adding packages is currently disabled. Set HS_ALLOW_EXTERNAL_PYTHON_PACKAGES_UPLOAD to enable," you need to update your application's ".env" file before uploading packages.

To enable package uploading in the application:

  1. Add the HS_ALLOW_EXTERNAL_PYTHON_PACKAGES_UPLOAD variable to your ".env" file and set it to true.
  2. After you've updated the ".env" file, go to Flows > Python Packages, and make sure the message at the top of the page ends with "To add more packages, upload through the 'Add Packages' button."
    • If it does, you can follow the steps in Upload custom Python packages below to begin uploading packages.
    • If it does not, double-check the content of your ".env" file to make sure you entered the new variable and its value correctly.

Upload custom Python packages

  1. Go to Flows > Python Packages, and click Add Package in either of the Python 3.9 or Python 3.11 cards.

  2. Do one of the following:
    • Drag and drop the package's wheel (.whl) file into the Add Python Packages dialog box.
    • Click Browse, and find and open the package's wheel (.whl) file on your machine.

  3. If you would like to upload additional packages, click Add More Files to drag-and-drop or open more files. Otherwise, click Upload.

    The package appears in either the Installed Packages for Python 3.9 card or the Installed Packages for Python 3.11 card, depending on which Add Package button you clicked to upload the packages. 

Updating Python packages

You cannot update pre-installed packages.

If you would like to update a Python package that a user has installed in your application, you can do so by following the steps below:

  1. Go to Flows > Python Packages, and click Add Package in either of the Python 3.9 or Python 3.11 cards.

  2. Do one of the following:
    • Drag and drop the updated package's wheel (.whl) file into the Add Python Packages dialog box.
    • Click Browse, and find and open the updated package's wheel (.whl) file on your machine.

  3. If you would like to update additional packages, click Add More Files to drag-and-drop or open more files. Otherwise, click Upload.

  4. For each updated package, you are asked to confirm whether or not you want to overwrite the current package with its new version. To do so, click Confirm.

    The package's Date Added and Version values are updated in either the Python 3.9 table or the Python 3.11 table.

Downloading user-installed packages

You can download individual user-installed Python packages or all user-installed packages for a particular version of Python. You cannot download pre-installed packages.

Download all user-installed packages for a Python version

To download all the user-installed packages for a particular version of Python:

  1. Go to Flows > Python Packages, and click the menu ( ) in either of the Python 3.9 or Python 3.11 cards.

  2. Click Download user installed packages.

    The file's name is in the format python_packages_[3.11 or 3.9]_YYYYMMDD-HHMMSS.zip, where YYYYMMDD is the year, month, and date of the download and HHMMSS is the hour, minutes, and seconds of the download's time in UTC time.

Download an individual package

You can download individual packages that you've previously uploaded. This process can be helpful when migrating your custom packages from one environment to another.

To download an individual package, go to Flows > Python Packages, and click the Download Package button ( DownloadModelIcon.png ) in the package's row in either the Python 3.9 table or the Python 3.11 table.

The downloaded file's name matches the name of the uploaded wheel file.

Deleting a custom package

You cannot delete pre-installed packages.

If you no longer need a custom package, you can delete it from the application.

Go to Flows > Python Packages, and click the Uninstall Package button ( DeleteAccountAPIAccount.png ) in the package's row in either the Python 3.9 table or the Python 3.11 table.

Downloading requirements.txt for a Python version

Downloading a requirements.txt file for Python 3.9 or Python 3.11 can help your developers know exactly which packages are available to them as they develop flows for your organization, as well as the installed versions of those packages. They can then use the file to download the packages to their local environments.

To download requirements.text for a particular version of Python:

  1. Go to Flows > Python Packages, and click the menu ( ) in either of the Python 3.9 or Python 3.11 cards.

  2. Click Download as requirements.txt.

    The requirements.txt file is downloaded to your machine.
v34-v39

v34-v39

If developers at your organization are creating custom blocks for your flows, they may want to install custom Python packages to add features to the blocks. System Admins can install and manage these packages on behalf of your developers.  

Viewing installed Python packages 

To find out which Python packages are currently installed in your application, go to Flows > Python Packages.

PythonPackagesTable.png

The Python Packages table contains the following information for each package:

  • The package's name. If information about the package is available on an external website, clicking the name redirects you to that website.
  • Whether the package was pre-installed, or, if it was not, the date and time it was added
  • The version of the package
  • If the package was not pre-installed, links to download or delete the package

You can use the Search text box at the top of the page to search for a specific package by its name. You can also sort the table by the names of the packages and the dates they were added.

Adding packages

While several Python packages are installed in the Hyperscience application by default, developers at your organization may want to upload additional packages to meet their flow-development needs. If you are a System Admin, you can edit the application's ".env" file to allow the uploading of these packages. Then, you can upload custom Python packages on behalf of your developers.

Package requirements

The packages you install must be compatible with Python 3.7. If the package has any dependencies, you must also install those packages.

Enable package uploading in the application

Your application may already allow you to upload Python packages. To find out, go to Flows > Python Packages.

  • If the message at the top of the page ends with "To add more packages, upload through the 'Add Packages' button," your application already has package uploading enabled. You do not need to make any changes to your application's ".env" file, and you can follow the steps in Upload custom Python packages below.

YouCanImportPythonPackages.png

  • If the message at the top of the page ends with "Adding packages is currently disabled. Set HS_ALLOW_EXTERNAL_PYTHON_PACKAGES_UPLOAD to enable," you need to update your application's ".env" file before uploading packages.

PythonPackagesCannotImport.png

To enable package uploading in the application:

  1. Add the HS_ALLOW_EXTERNAL_PYTHON_PACKAGES_UPLOAD variable to your ".env" file and set it to true.
  2. After you've updated the ".env" file, go to Flows > Python Packages, and make sure the message at the top of the page ends with "To add more packages, upload through the 'Add Packages' button."
    • If it does, you can follow the steps in Upload custom Python packages below to begin uploading packages.
    • If it does not, double-check the content of your ".env" file to make sure you entered the new variable and its value correctly.

Upload custom Python packages

The steps in the upload process depend on which version of Hyperscience you are using.

v35 and later

  1. Go to Flows > Python Packages, and click Add Packages.

  2. Do one of the following:
    • Drag and drop the package's wheel (.whl) file into the Add Python Packages dialog box.
    • Click Choose Files, and find and open the package's wheel (.whl) file on your machine.

  3. If you would like to upload additional packages, click Add More Files to drag-and-drop or open more files. Otherwise, click Upload.

The package appears in the Python Packages table.

v34

Follow the steps outlined in our Flows SDK documentation.

Updating Python packages (v35 and later)

You cannot update pre-installed packages.

If you would like to update a Python package that you’ve installed in your application, you can do so by following the steps below:

  1. Go to Flows > Python Packages, and click Add Packages.

  2. Do one of the following:
    • Drag and drop the updated package's wheel (.whl) file into the Add Python Packages dialog box.
    • Click Choose Files, and find and open the updated package's wheel (.whl) file on your machine.

  3. If you would like to update additional packages, click Add More Files to drag-and-drop or open more files. Otherwise, click Upload.

  4. For each updated package, you are asked to confirm whether or not you want to overwrite the current package with its new version. To do so, click Confirm.

    The package's Date Added and Version values are updated in the Python Packages table.

Downloading packages

You can download individual or all Python packages installed in your application.

Download all packages

Downloading all packages in your application can help your developers know exactly which packages are available to them as they develop flows for your organization.

To download all the packages installed in your application, go to Flows > Python Packages, and click Download All Packages.

The downloaded file contains both pre-installed packages and any custom packages you've uploaded. The file's name is in the format python_packages_MMDD-HHMMSS.zip, where MMDD is the month and date of the download and HHMMSS is the hour, minutes, and seconds of the download's time in UTC time.

Download an individual package

You cannot download individual pre-installed packages. To download pre-installed packages, follow the steps in Download all packages.

You can download individual packages that you've previously uploaded. This process can be helpful when migrating your custom packages from one environment to another.

To download an individual package, go to Flows > Python Packages, and click the Download Package button ( DownloadModelIcon.png ) in the package's row in the table.

The downloaded file's name matches the name of the uploaded wheel file.

Deleting a custom package

You cannot delete pre-installed packages.

If you no longer need a custom package, you can delete it from the application.

v35 and later

Go to Flows > Python Packages, and click the Uninstall Package button ( DeleteAccountAPIAccount.png ) in the package's row in the table.

v34

Follow the steps outlined in our Flows SDK documentation.

Was this article helpful?
0 out of 0 found this helpful