Skip to main content

A Python abstraction class to access NUT servers.

Project description

Build Status Test Coverage Code Health PyPi Version

This is an API overhaul of PyNUT, a Python library to allow communication with NUT (Network UPS Tools) servers.

Note: Updated package to remove telnetlib dependency and convert to PEP 517 build

Note: This is an unofficial project, and is in no way supported or endorsed by the Network UPS Tools developers.

Requirements

The module itself requires only Python 3.

Usage

Example:

from nut2 import PyNUTClient
client = PyNUTClient()
client.help()
client.list_ups()
client.list_vars("My_UPS")

Please note that this module has completely and intentionally broken backwards compatibility with PyNUT 1.X.

See inline documentation for more usage information.

Installation

Use pip:

pip install nut2-notl

PyNUT

The following information is copied from the original PyNUT README:

This directory contains various NUT Client related Python scripts, written by David Goncalves, and released under GPL v3.

  • “module”: this directory contains PyNUT.py, which is a Python abstraction class to access NUT server(s). You can use it in Python programs to access NUT’s upsd data server in a simple way, without having to know the NUT protocol.

To import it on Python programs you have to use the following (case sensitive) : ‘import PyNUT’

This module provides a ‘PyNUTClient’ class that can be used to connect and get data from an upsd data server.

To install the PyNUT module on Debian/Ubuntu, copy it to: /usr/share/python-support/python-pynut/

This directory also contains test_nutclient.py, which is a PyNUT test program. For this to be fully functional, you will need to adapt the login, password and upsname to fit your configuration.

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

nut2_notl-2.1.2.tar.gz (21.1 kB view details)

Uploaded Source

Built Distribution

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

nut2_notl-2.1.2-py3-none-any.whl (18.7 kB view details)

Uploaded Python 3

File details

Details for the file nut2_notl-2.1.2.tar.gz.

File metadata

  • Download URL: nut2_notl-2.1.2.tar.gz
  • Upload date:
  • Size: 21.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for nut2_notl-2.1.2.tar.gz
Algorithm Hash digest
SHA256 5527d754713c2be6ced58964bbce0ea876877331afb8aa0a7498ebd2127b0082
MD5 2bfb8044cfcb23aa6115fe3fef77075a
BLAKE2b-256 862379b132b1f46ff90cc0d6b203dbb24ff2e379515e0237c5127695ef0b74e7

See more details on using hashes here.

File details

Details for the file nut2_notl-2.1.2-py3-none-any.whl.

File metadata

  • Download URL: nut2_notl-2.1.2-py3-none-any.whl
  • Upload date:
  • Size: 18.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for nut2_notl-2.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 15b93eaaddc10238df4af83d3a4bd37f76fbf7b694eb52ab90cece06c04df604
MD5 546a6bdc2822425faa5e5ca4515a41da
BLAKE2b-256 395f46deab1544e6d169806da448498dd498404f61b51b3e16f1ccc9b1db916a

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