Datasette plugin showing uptime at /-/uptime
Project description
datasette-uptime
Datasette plugin showing uptime at /-/uptime
Installation
Install this plugin in the same environment as Datasette.
datasette install datasette-uptime
Usage
Adds an endpint at /-/uptime
returning JSON that looks like this:
{
"started": 355764.709263208,
"now": 355824.192608208,
"uptime_seconds": 59.483345208049286,
"uptime_hours": 0.0165231515625136
}
This shows how long the server has been running.
Development
To set up this plugin locally, first checkout the code. Then create a new virtual environment:
cd datasette-uptime
python3 -m venv venv
source venv/bin/activate
Now install the dependencies and test dependencies:
pip install -e '.[test]'
To run the tests:
pytest
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
datasette-uptime-0.1.tar.gz
(6.3 kB
view details)
Built Distribution
File details
Details for the file datasette-uptime-0.1.tar.gz
.
File metadata
- Download URL: datasette-uptime-0.1.tar.gz
- Upload date:
- Size: 6.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.2 CPython/3.11.8
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | dddd3b03545eeb5cd29e6088911ab3ddb8c119b613269fb54694321caab8ada7 |
|
MD5 | 56ecc5db6609798c57a4c2c6044eaff0 |
|
BLAKE2b-256 | 2316628b4397c5dc6cd7400014ae3a854ea1598636e617461e08e53d7998aee1 |
File details
Details for the file datasette_uptime-0.1-py3-none-any.whl
.
File metadata
- Download URL: datasette_uptime-0.1-py3-none-any.whl
- Upload date:
- Size: 6.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.2 CPython/3.11.8
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bd91f327f11ebdcaf5b700578b5af060bf479be566e7337bd804da3424433f58 |
|
MD5 | f65f8008f37583e2a9aa086fb03f2415 |
|
BLAKE2b-256 | bfbd968673911ee2ac42e97f61b7a48b6b50e031a494205c8ad3ebb89f8fe333 |