Skip to main content

petlja_api

A python library for interacting with the petlja.org API.

Installation

pip install petlja-api

Basic usage

import petlja_api as petlja

session = petlja.login()

# Create problem
prob_id = petlja.create_problem(session, name="My Problem", alias="my-prob")
petlja.upload_testcases(session, prob_id, "my-prob/testcases.zip")
petlja.upload_statement(session, prob_id, "my-prob/statement.md")

# Create competition
comp_id = petlja.create_competition(session, name="My Competition", alias="my-comp")
petlja.add_problem(session, comp_id, prob_id)

# Upload solution
score = petlja.submit(session, prob_id, "my-prob/sol.cpp", comp_id)

Metadata

Release files for petlja-api 0.4.2

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

Source distribution (sdist)

Source distribution for petlja-api 0.4.2
File Size Uploaded Provenance Actions
petlja_api-0.4.2.tar.gz 15.1 kB Without provenance Details for petlja_api-0.4.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for petlja-api 0.4.2
File Interpreter ABI Platform Actions
petlja_api-0.4.2-py3-none-any.whl Python 3 none any Details for petlja_api-0.4.2-py3-none-any.whl

Total release size: 24.6 kB

Release files / petlja_api-0.4.2.tar.gz

Download URL petlja_api-0.4.2.tar.gz
Size 15.1 kB
Tags Source
SHA-256 checksum
How to use checksums
5087afa1f0c551b9848a91843f6c5ff0079e8420aae40e1eb3699b45e2570b8b
BLAKE2b-256 checksum
How to use checksums
97bb71ed019a6e907356d5dcb30b86037d282e870dc820259412d3daa4bf2ff1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / petlja_api-0.4.2-py3-none-any.whl

Download URL petlja_api-0.4.2-py3-none-any.whl
Size 9.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
83141ffb5cbe98165e3456a6df507963ecb985db18ad3ba153a4d531a3e69760
BLAKE2b-256 checksum
How to use checksums
47432ae9a80420c387a15c62630610830517e9991025bb64070cda8cf9e34659
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Security for petlja-api 0.4.2

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.

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