Skip to main content

SciJava log handler for Python 🐍☕📑

DOI

A very thin Python package (mavenized for ImageJ2) to use the SciJava LogService as a handler for Python's logging facility. See the wiki page about Logging for more details about ImageJ's logging framework.

Developed and provided by the Imaging Core Facility (IMCF) of the Biozentrum, University of Basel, Switzerland.

🚫 WARNING 🚫

The PyPI packages of this project are exclusively useful for automatic testing of e.g. the imcflibs package! They have no real use-case in the standard CPython world 🐍🌍!

Example usage

The code in extra/scripts/example.py demonstrates how to use the handler in an ImageJ2 Python script utilizing the fabulous Script Parameters for retrieving the LogService instance.

Running this code from ImageJ will result in the following messages being printed to the console or the Log window, depending on how you launch ImageJ:

[Fri Jan  5 12:25:15 CET 2018] [ERROR] +++ new round of messages (level WARNING) +++
[Fri Jan  5 12:25:15 CET 2018] [WARNING] warn log message
[Fri Jan  5 12:25:15 CET 2018] [ERROR] error log message
[Fri Jan  5 12:25:15 CET 2018] [ERROR] critical log message
[Fri Jan  5 12:25:15 CET 2018] [ERROR] --- finished round of messages (level WARNING) ---
[Fri Jan  5 12:25:15 CET 2018] [ERROR] +++ new round of messages (level INFO) +++
[Fri Jan  5 12:25:15 CET 2018] [INFO] info log message
[Fri Jan  5 12:25:15 CET 2018] [WARNING] warn log message
[Fri Jan  5 12:25:15 CET 2018] [ERROR] error log message
[Fri Jan  5 12:25:15 CET 2018] [ERROR] critical log message
[Fri Jan  5 12:25:15 CET 2018] [ERROR] --- finished round of messages (level INFO) ---
[Fri Jan  5 12:25:15 CET 2018] [ERROR] +++ new round of messages (level DEBUG) +++
[Fri Jan  5 12:25:15 CET 2018] [DEBUG] debug log message
[Fri Jan  5 12:25:15 CET 2018] [INFO] info log message
[Fri Jan  5 12:25:15 CET 2018] [WARNING] warn log message
[Fri Jan  5 12:25:15 CET 2018] [ERROR] error log message
[Fri Jan  5 12:25:15 CET 2018] [ERROR] critical log message
[Fri Jan  5 12:25:15 CET 2018] [ERROR] --- finished round of messages (level DEBUG) ---
[Fri Jan  5 12:25:15 CET 2018] [ERROR] +++ new round of messages (level WARNING) +++
[Fri Jan  5 12:25:15 CET 2018] [WARNING] warn log message
[Fri Jan  5 12:25:15 CET 2018] [ERROR] error log message
[Fri Jan  5 12:25:15 CET 2018] [ERROR] critical log message
[Fri Jan  5 12:25:15 CET 2018] [ERROR] --- finished round of messages (level WARNING) ---

Metadata

Release files for sjlogging 0.5.4

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

Source distribution (sdist)

Source distribution for sjlogging 0.5.4
File Size Uploaded
sjlogging-0.5.4.tar.gz 16.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for sjlogging 0.5.4
File Interpreter ABI Platform
sjlogging-0.5.4-py2.py3-none-any.whl Python 3, Python 2 none any Details

Total release size: 34.5 kB

Release files / sjlogging-0.5.4.tar.gz

Download URL sjlogging-0.5.4.tar.gz
Size 16.4 kB
Tags Source
SHA-256 checksum
How to use checksums
5fb1a4e6338088bdbf9d943a867bf1bc6f77031ec48dbb7dd96f09abb0aaaa92
BLAKE2b-256 checksum
How to use checksums
1201642d78b2c4be39fc0c1c7f103c9e13194fda1655d246aa35f5398d4b4797
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.2 CPython/3.12.3 Linux/5.15.0-125-generic

Release files / sjlogging-0.5.4-py2.py3-none-any.whl

Download URL sjlogging-0.5.4-py2.py3-none-any.whl
Size 18.1 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
e7db0a34ac2788a0404ac02beee232132f3946330cc04d28a37eea9adb3cfd42
BLAKE2b-256 checksum
How to use checksums
32662032e35c0e59c611295f3d8b6024bd94d88f9b5111ffaff2bbac9837de67
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.8.2 CPython/3.12.3 Linux/5.15.0-125-generic

Release history Release notifications | RSS feed

This release

0.5.4 This release

2 release files

0.5.3

2 release files

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