Skip to main content

Simplified exception handling for Python

Project description

pytrycatch

from pytrycatch import handle_errors

@handle_errors(log=True, default_return="safe fallback")
def risky_operation():
    return 1 / 0

print(risky_operation())  # Output: "safe fallback"

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pytrycatch-0.0.2.tar.gz (3.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pytrycatch-0.0.2-py3-none-any.whl (3.8 kB view details)

Uploaded Python 3

File details

Details for the file pytrycatch-0.0.2.tar.gz.

File metadata

  • Download URL: pytrycatch-0.0.2.tar.gz
  • Upload date:
  • Size: 3.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.20

File hashes

Hashes for pytrycatch-0.0.2.tar.gz
Algorithm Hash digest
SHA256 9d03319ec4c46601ad2ab0742bb14a92f8719c388ce7088cbfbb6f9268075423
MD5 9a0072333649b9eb82008e9e9f599e9a
BLAKE2b-256 f0b39450016320c7c818f8872422ffe489c8d65bd2633662f1e9c609f6a74a21

See more details on using hashes here.

File details

Details for the file pytrycatch-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: pytrycatch-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 3.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.20

File hashes

Hashes for pytrycatch-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 3e875f344284715f6d33c812d2a2cba60e41ddaa4123f633803ef25b952da880
MD5 d455fccd73fabda60f48cd4175dcad60
BLAKE2b-256 731e7d2653fb1933bc67b6265cdb004addb5d2048fd54ba3be2bd46d262a409f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page