A suite of modules to enable TDA/MMA observations
Project description
AEONlib
A suite of modules to enable TDA/MMA observations
Configuration
Many of the facilities and services accessed by AEONlib require specific configuration such as api keys, urls, etc. All configuration can be supplied by either supplying a .env file or setting environmental variables in the execution environment.
Example .env file:
AEON_LCO_API_ROOT="https://observe.lco.global/api"
AEON_LCO_TOKEN="my-api-token"
Or set environmental variables via the shell:
export AEON_LCO_API_ROOT="https://observe.lco.global/api"
export AEON_LCO_TOKEN="my-api-token"
All configuration keys are prefixed with AEON_ to prevent conflicts. See the documentation for each service to see which configuration keys are available, or check conf.py
Environmental variables take precedence over .env files. See the pydantic-settings documentation for more details.
Testing
This project uses pytest to run tests:
pytest
Some tests are marked as online. These tests make real http requests in order
to test interfaces with various services. To run them:
pytest -m online
A subset of online tests are marked as side_effect. These are tests that change data on remote
systems. For example, a test might be testing creating new observation requests, or updating the
status of one. You might want to disable these:
pytest -m "not side_effect"
CI does not run tests marked as online.
Viewing logs during tests
Aeonlib turns on the Pytest
Live Logging feature.
By default any logging calls with a level above WARNING will be displayed to the console
during the test run. It may be helpful to display debug logging, especially if debugging remote
facilities or services:
pytest -m online --log-cli-level=debug
Linting
All code is formatted via ruff.
Code Generation
Las Cumbres Observatory instrument classes are generated via the generator.py script. This script takes as input the OCS instruments api in order to produce definitions of all instruments currently available on the network.
To update the definitions, first make sure you have installed the codegen dependency
group:
uv sync --group codegen # or poetry install --with codegen
This ensures regular users of the library do not need to install these dependencies.
The generate.py script takes as input JSON as produced by the instruments endpoint:
codegen/lco/generator.py {facility} instruments.json
Or directly from stdin using a pipe:
curl https://observe.lco.global/api/instruments/ | codegen/lco/generator.py {facility}
If the output looks satisfactory, you can redirect the output to overwrite the LCO instruments definition file:
curl https://observe.lco.global/api/instruments/ | codegen/lco/generator.py {facility} > src/aeonlib/ocs/lco/instruments.py
Supported Facilities
This list is a work in progress.
Las Cumbres Observatory (LCO)
Dependency group
Las Cumbres Observatory requires no additional dependency groups to be installed.
Configuration Values
See configuration for instructions on setting these values.
lco_token: str = ""
lco_api_root: str = "https://observe.lco.global/api/"
Helpful links
SOAR
SOAR is functionally the same as LCO, but has its own set of instruments and can be configured separately.
Dependency group
SOAR requires no additional dependency groups to be installed.
Configuration Values
See configuration for instructions on setting these values.
soar_token: str = ""
soar_api_root: str = "https://observe.lco.global/api/"
Note: the soar API token will default to the same value as lco_token, if it is set.
BLANCO
BLANCO is functionally the same as LCO, but has its own set of instruments and can be configured separately.
Dependency group
BLANCO requires no additional dependency groups to be installed.
Configuration Values
See configuration for instructions on setting these values.
blanco_token: str = ""
blanco_api_root: str = "https://observe.lco.global/api/"
Note: the blanco API token will default to the same value as lco_token, if it is set.
ESO (European Southern Observatory)
Full documentation: TODO
Dependency Group
To use the ESO facility, you must install the eso group:
pip install aeonlib[eso]
uv sync --extra eso
poetry install --with eso
Configuration Values
See configuration for instructions on setting these values.
eso_environment: str = "demo"
eso_username: str = ""
eso_password: str = ""
Helpul links
LT (Liverpool Telescope)
Dependency Group
To use the LT facility, you must install the lt group:
pip install aeonlib[lt]
uv sync --extra lt
poetry install --with lt
Configuration Values
See configuration for instructions on setting these values.
lt_username: str = ""
lt_password: str = ""
lt_host: str = ""
lt_port: str = ""
Helpful links
SAAO (South African Astronomical Observatory)
Configuration Values
saao_token: str = ""
saao_api_root: str = "https://ocsio.saao.ac.za/api/"
Helpful links
SALT (Southern African Large Telescope)
Dependency Group
To use the SALT facility, you must install the salt group:
pip install aeonlib[salt]
uv sync --extra salt
poetry install --with salt
Configuration values
See configuration for instructions on setting these values.
salt_username: str = ""
salt_password = ""
The username and password are those you would use for the SALT Web Manager.
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file aeonlib-0.2.0.tar.gz.
File metadata
- Download URL: aeonlib-0.2.0.tar.gz
- Upload date:
- Size: 184.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2d923b17f4ad864d2ba12da38ea5e46469df0e176937dc9d7e5389d42f37ee4a
|
|
| MD5 |
a635fc01fa5ba4ddf8441438f9d2ef21
|
|
| BLAKE2b-256 |
b01148dec0d6469733954aba71de2310a7bf419fc57c60e535cd4060336eb5d6
|
Provenance
The following attestation bundles were made for aeonlib-0.2.0.tar.gz:
Publisher:
publish.yml on AEONplus/AEONlib
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
aeonlib-0.2.0.tar.gz -
Subject digest:
2d923b17f4ad864d2ba12da38ea5e46469df0e176937dc9d7e5389d42f37ee4a - Sigstore transparency entry: 1464016072
- Sigstore integration time:
-
Permalink:
AEONplus/AEONlib@9ad5bf6e8053fd6eb72fbdde9ad55871cff07eb3 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/AEONplus
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@9ad5bf6e8053fd6eb72fbdde9ad55871cff07eb3 -
Trigger Event:
push
-
Statement type:
File details
Details for the file aeonlib-0.2.0-py3-none-any.whl.
File metadata
- Download URL: aeonlib-0.2.0-py3-none-any.whl
- Upload date:
- Size: 103.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b5742a46dddceb78d82e0eb2298ef75ce67522df6dff57f911e57c89cf7b0ad3
|
|
| MD5 |
fe036f4d22c8d4fb80fffa9a9de4dd03
|
|
| BLAKE2b-256 |
aa2a5f46acef126af077058bd053cbc5229db2dd20e90adbc44591c3ea121378
|
Provenance
The following attestation bundles were made for aeonlib-0.2.0-py3-none-any.whl:
Publisher:
publish.yml on AEONplus/AEONlib
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
aeonlib-0.2.0-py3-none-any.whl -
Subject digest:
b5742a46dddceb78d82e0eb2298ef75ce67522df6dff57f911e57c89cf7b0ad3 - Sigstore transparency entry: 1464016207
- Sigstore integration time:
-
Permalink:
AEONplus/AEONlib@9ad5bf6e8053fd6eb72fbdde9ad55871cff07eb3 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/AEONplus
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@9ad5bf6e8053fd6eb72fbdde9ad55871cff07eb3 -
Trigger Event:
push
-
Statement type: