Skip to main content

Logo

AegisBlade Python Client

pypi version supported python versions license

Deploy & run your code in a single function call.
Read the docs »

Examples · Sign Up for an API Key · Report Bug

Installation

We recommend using virtualenv to create an isolated environment for your python application.

Install the python package as a dependency of your application.

$ pip install aegisblade

Or for python3:

pip3 install aegisblade

Hello World Example

const {aegisblade} = require('aegisblade');
const os = require("os");

/**
 * In this example the `helloWorld()` function will be run on a
 * server using AegisBlade. 
 */
async function helloWorld() {
    console.log(`The server's hostname is ${os.hostname()}`);

    return `Hello World from ${os.hostname()}`;
}

// Any target function to be run on AegisBlade must be exported.
module.exports = {helloWorld};

/**
 * The `main()` function will run on your local machine
 * and start the job running the `helloWorld()` function
 * on a server using AegisBlade.
 */
async function main() {
    let job = await aegisblade.run(helloWorld);

    console.log(`Job Id: ${job.id}`);
    console.log("Waiting for the job to finish running...");

    let jobReturnValue = await job.getReturnValue();
    let jobLogs = await job.getLogs();

    console.log(`Job Return Value: ${jobReturnValue}`);
    console.log(`Job Logs: ${jobLogs}`);
}

//  Using the `require.main === module` idiom to only run main when this script
//    is called directly is especially important when using AegisBlade to prevent
//    infinite loops of jobs creating jobs.
if (require.main === module) {
    (async () => {
        try {
            await main();
        } catch (err) {
            console.error(err);
        }
    })();
}

Note on Python 2

The official python organization will no longer support Python 2 following January 2020.

Due to it's popular usage though, we will likely continue to support a Python 2.7 client for the forseeable future.

Reference

Python Client Reference Docs

Contact

AegisBlade - @aegisbladehq - welovedevs@aegisblade.com

Project Link: https://github.com/aegisblade/aegis-nodejs

Metadata

Release files for aegisblade 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for aegisblade 0.2.0
File Size Uploaded Provenance
aegisblade-0.2.0.tar.gz 24.0 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for aegisblade 0.2.0
File Interpreter ABI Platform
aegisblade-0.2.0-py2-none-any.whl Python 2 none any Details

Total release size: 72.8 kB

Release files / aegisblade-0.2.0.tar.gz

Download URL aegisblade-0.2.0.tar.gz
Size 24.0 kB
Tags Source
SHA-256 checksum
How to use checksums
0a52fa0c87a3c195562ad0a3c9ea1cab8dc853f91aa8eb75ed9965045689b77f
BLAKE2b-256 checksum
How to use checksums
dd51fd574623b8688465484dd75077c64c39a5890a4d734f6d5a2c9f18a8e172
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.15.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/2.7.16

Release files / aegisblade-0.2.0-py2-none-any.whl

Download URL aegisblade-0.2.0-py2-none-any.whl
Size 48.8 kB
Tags Python 2
SHA-256 checksum
How to use checksums
a579fddd66203cced1b45b119f7e370fe812f9c8074e566154effa2507bd4ae7
BLAKE2b-256 checksum
How to use checksums
255cd5c8c3b1fa2343751a4fc3dbd81b2401627cba4f233c0f51139e08942cea
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.15.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/2.7.16

Security for aegisblade 0.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.2.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page