Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
176 commits
Select commit Hold shift + click to select a range
d5e027d
Add initial file layout for SALT models
hettlage Sep 5, 2025
9f47c17
Add the observation request model
hettlage Sep 5, 2025
b3980a7
Merge branch 'main' into salt-facility
hettlage Sep 5, 2025
5773030
Add a first version of the block model
hettlage Sep 10, 2025
905fa7f
Add a first version of the SALT sidereal target model
hettlage Sep 10, 2025
8b07329
Add the magnitude range model
hettlage Sep 10, 2025
be49a16
Add Pydantic validators for checking greater than or equal to and les…
hettlage Sep 11, 2025
0dc058b
Add the constraints model
hettlage Sep 11, 2025
8860589
Replace the Ge and Le validators with GreaterEqual and LessEqual
hettlage Sep 11, 2025
b72c1e7
Handle the case of zero maximum visits correctly
hettlage Sep 11, 2025
c42efbc
Use an AstroPy Angle instead of an AstroPy Quantity
hettlage Sep 11, 2025
17b4a3f
Fix the GreaterEqual and LessEqual validator
hettlage Sep 11, 2025
91fe20a
Allow only right ascension values supported by SALT
hettlage Sep 11, 2025
0639e01
Move model tests into separate files
hettlage Sep 11, 2025
588a1e5
Move literal types into separate files
hettlage Sep 11, 2025
5ed2ef3
Update the Block model to use the Constraints model
hettlage Sep 12, 2025
57a3abe
Fix minor language issues
hettlage Sep 12, 2025
d0e66bc
Add validators for greater than and less than relations
hettlage Sep 12, 2025
dedf481
Add the acquisitions model
hettlage Sep 15, 2025
0601fb7
Merge branch 'main' into salt-facility
hettlage Sep 16, 2025
598b6d4
Fix a formatting issue
hettlage Sep 16, 2025
057482e
Add a type annotation for defining custom types based on an AstroPy Q…
hettlage Sep 16, 2025
59cf06e
Add types for a duration
hettlage Sep 16, 2025
7602f37
Type the exposure time as a positive duration
hettlage Sep 16, 2025
50446c5
Refactor the validation for the target right ascension
hettlage Sep 17, 2025
4a2c044
Fix the target coordinate validation
hettlage Sep 17, 2025
d4922f5
Add the reference star model
hettlage Sep 17, 2025
1af9fd7
Add the acquisition model in the block model
hettlage Sep 17, 2025
5f83ed7
Add an Instrument type
hettlage Sep 17, 2025
6566ec1
Refactor the model import
hettlage Sep 17, 2025
a6907cd
Revert "Add an Instrument type"
hettlage Sep 17, 2025
8587677
Add the Salticam model
hettlage Sep 17, 2025
a1d07e0
Add the filter sequence step model
hettlage Sep 17, 2025
ade179f
Add the Salticam detector model
hettlage Sep 17, 2025
644deb0
Rename FilterSequenceStep to SalticamFilterSequenceStep
hettlage Sep 17, 2025
14d651a
Remove spurious import
hettlage Sep 17, 2025
9dc6a37
Add the Salticam dither pattern model
hettlage Sep 19, 2025
c13c777
Add the dither pattern to the Salticam model
hettlage Sep 19, 2025
aba55ff
Avoid misleading type checker errors
hettlage Sep 19, 2025
55531c8
Merge branch 'main' into salt-facility
hettlage Oct 21, 2025
befed11
Add a model for RSS configurations
hettlage Oct 22, 2025
edf30fb
Add RSS imaging filters
hettlage Oct 22, 2025
efb556c
Add models for RSS imaging and configurations and RSS polarimetry setups
hettlage Oct 29, 2025
eff3281
Check that the angles in a wave plate pattern are correct
hettlage Oct 30, 2025
afd6046
Change include_flats to include_flat for Salticam
hettlage Oct 30, 2025
3f02ffe
Update comments and add RSS order blocking filters
hettlage Oct 30, 2025
1792e2c
Add the RSS spectroscopy base model
hettlage Oct 30, 2025
d39f3b5
Add validation for grating and articulation angles
hettlage Nov 9, 2025
c83bc62
Add a model for RSS longslit spectroscopy setups
hettlage Nov 9, 2025
5f98e67
Add a model for RSS multiobject spectroscopy (MOS) setups
hettlage Nov 9, 2025
948883d
Refactor RSS and Salticam types
hettlage Nov 9, 2025
7f7548a
Add a model for RSS slit mask IFU spectroscopy setups
hettlage Nov 9, 2025
a325eae
Update the type of the configuration field in the Rss model
hettlage Nov 9, 2025
ed7ff52
Add a model for RSS detector setups
hettlage Nov 9, 2025
acff1b7
Enforce a positive dither pattern offset
hettlage Nov 9, 2025
034b418
Add a model for RSS dither patterns
hettlage Nov 9, 2025
1fcd3b0
Do not limit dither pattern offsets to positive values
hettlage Nov 9, 2025
be2dc5b
Add a model for HRS configurations
hettlage Nov 9, 2025
9445085
Add a model for HRS detector setups
hettlage Nov 11, 2025
9316a95
Fix a docstring
hettlage Nov 11, 2025
4f7f744
Fix formatting
hettlage Nov 11, 2025
e8a64eb
Add a model for NIRWALS configurations
hettlage Nov 11, 2025
8f48434
Add a model for NIRWALS dither pattern steps
hettlage Nov 11, 2025
36dbf11
Fix docstrings
hettlage Nov 11, 2025
47b19ca
Add functionality to validate XML against the SALT schema
hettlage Feb 2, 2026
0118d98
Add a function for rendering Jinja templates
hettlage Feb 2, 2026
e4b1032
Reformat a file
hettlage Feb 2, 2026
26961d5
Move a test file
hettlage Feb 2, 2026
ed2d6b1
Update docstrings
hettlage Feb 2, 2026
8a76eab
Add Pydantic serializers for transforming string values
hettlage Feb 3, 2026
9b52d7a
Add Pydantic serializers for transforming string values
hettlage Feb 4, 2026
c0f8dd9
Fix a typo in a docstring
hettlage Feb 4, 2026
960e935
Add a validator for turning strings into lower case
hettlage Feb 5, 2026
8c55f8e
Handle None values
hettlage Feb 5, 2026
fafac39
Move all model string values to lower case
hettlage Feb 5, 2026
d8d81f5
Handle polarimetry patterns specified as a string
hettlage Feb 6, 2026
6060dd7
Add templates for serializing Salticam instances
hettlage Feb 6, 2026
3f4b4be
Add templates for serializing Rss detector setups
hettlage Feb 9, 2026
f24a767
Add a configuration mode field
hettlage Feb 9, 2026
df28fb6
Refactor tests
hettlage Feb 9, 2026
34d3571
Ensure the detector window height is an integer
hettlage Feb 9, 2026
70a7081
Add a template for serializing RSS imaging configurations
hettlage Feb 9, 2026
a4ae9c6
Fix the filter serialization
hettlage Feb 9, 2026
287266e
Validate RssSpectroscopy instances when assigning fields
hettlage Feb 9, 2026
90295d4
Add the articulation station as a computed field
hettlage Feb 9, 2026
744176c
Handle RSS filters correctly when generating XML
hettlage Feb 9, 2026
c1d6261
Add template for RSS spectroscopy XML
hettlage Feb 9, 2026
53bfb23
Validate all SALT models on field assignment
hettlage Feb 9, 2026
99a781c
Handle null values
hettlage Feb 9, 2026
55df484
Fix the detector window height value in the XML
hettlage Feb 9, 2026
7930aa7
Fix a unit test
hettlage Feb 9, 2026
45ad83d
Make the Salticam dither pattern optional
hettlage Feb 9, 2026
d381b22
Add tests for generating XML for RSS spectroscopy setups
hettlage Feb 9, 2026
16f8dba
Group unit tests in classes
hettlage Feb 9, 2026
9a50ea8
Add test for generating the XML for a Salticam dither pattern
hettlage Feb 9, 2026
02b1627
Add a template for generating the XML for an RSS dither pattern
hettlage Feb 9, 2026
c0ef922
Update docstrings
hettlage Feb 9, 2026
0dd758a
Update the proposal schema
hettlage Feb 9, 2026
6e55cb8
Use default calibration flats
hettlage Feb 9, 2026
683ce71
Add a Jinja filter for wave plate stations
hettlage Feb 10, 2026
cced7b4
Add a template for generating RSS setups
hettlage Feb 10, 2026
229e2a6
Prettify the generated XML a bit
hettlage Feb 10, 2026
30d1484
Mark the number of groups as a computed field
hettlage Feb 10, 2026
0a82143
Update the XML schema
hettlage Feb 10, 2026
9ad0ef7
Add template for NIRWALS dither pattern steps
hettlage Feb 10, 2026
834c343
Add a Jinja filter for NIRWALS articulation stations
hettlage Feb 10, 2026
0b79c33
Add a template for NIRWALS setups
hettlage Feb 10, 2026
f817a7e
Allow any float values for magnitudes
hettlage Feb 10, 2026
2aab57e
Add a Jinja filter for converting years to ISO timestamps
hettlage Feb 10, 2026
bf5d7bb
Add validation to SALT targets
hettlage Feb 10, 2026
f15bed2
Add template for SALT targets
hettlage Feb 10, 2026
5944072
Remove an unnecessary import
hettlage Feb 10, 2026
3fae21f
Add a global function for generating UUID strings in a Jinja template
hettlage Feb 10, 2026
c5dc9d1
Generate UUID strings for the target id and target code
hettlage Feb 10, 2026
f7ffc96
Generate UUID strings for the target id and target code
hettlage Feb 10, 2026
ee5eaac
Add a global function to Jinja for converting a float into an Angle o…
hettlage Feb 10, 2026
544845b
Add a Jinja filter for getting the sign of a number
hettlage Feb 10, 2026
2e69971
Add the missing values to the target template
hettlage Feb 10, 2026
6fb6ef0
Refactor the code
hettlage Feb 10, 2026
9e4d15d
Add docstrings
hettlage Feb 10, 2026
c1ab100
Use a computed field for the HRS precision radial velocity calibration
hettlage Feb 10, 2026
d8280bf
Add a Jinja filter for displaying the iodine cell position
hettlage Feb 10, 2026
20e3fe6
Add a template for HRS setups
hettlage Feb 10, 2026
7de2975
Merge remote-tracking branch 'origin/salt-facility' into salt-facility
hettlage Feb 10, 2026
79ff07e
Update the XML schema
hettlage Feb 11, 2026
4268cbb
Update the NIRWALS templates to conform to the latest XML schema
hettlage Feb 11, 2026
34478ef
Fix the proper motion values in the XML
hettlage Feb 11, 2026
af3734c
Update the XML schema
hettlage Feb 11, 2026
df69954
Update the Acquisition model
hettlage Feb 11, 2026
33d66df
Add the template for acquisitions
hettlage Feb 11, 2026
655c5f0
Update the XML schema
hettlage Feb 11, 2026
d590aae
Use a default value for the block identifier
hettlage Feb 11, 2026
3d07f6c
Add an instrument name field to the instrument models
hettlage Feb 12, 2026
371e62a
Fix the type of the instrument field
hettlage Feb 12, 2026
700efda
Fix handling of the minimum number of nights between visits
hettlage Feb 12, 2026
f0fc089
Add a template for generating blocks
hettlage Feb 12, 2026
3dabfc6
Add a template for generating the XML for al, request blocks
hettlage Feb 13, 2026
632ecd9
Add a method for getting the set of attachments used by a request
hettlage Feb 13, 2026
c60cc00
Fix the RSS spectroscopy template
hettlage Feb 13, 2026
aacf450
Fix the acquisition template
hettlage Feb 13, 2026
984bc06
Add a utility function for updating the attachment paths in an XML do…
hettlage Feb 13, 2026
821c025
Rename one of the test finder charts
hettlage Feb 16, 2026
67578f8
Add a fixture for generating test data files
hettlage Feb 16, 2026
77316c7
Validate the XML as well
hettlage Feb 16, 2026
40c0a76
Parse the XML as bytes
hettlage Feb 16, 2026
39ec509
Fix finder chart name and formatting
hettlage Feb 16, 2026
5f14a06
Add missing import back
hettlage Feb 16, 2026
f6a5a3b
Add a block submission element
hettlage Feb 16, 2026
0c765bf
Add a block submission element
hettlage Feb 17, 2026
51cc981
Remove unnecessary imports
hettlage Feb 25, 2026
9ba6141
Improve testing with duplicate attachments
hettlage Feb 25, 2026
068d436
Add a method for mapping attachments to paths for the submitted XML
hettlage Feb 25, 2026
5a28564
Add a method for mapping attachments to paths for the submitted XML
hettlage Feb 26, 2026
25a2df9
Fix the name of the dummy slit mask file
hettlage Mar 5, 2026
d105a6b
Add zip file export
hettlage Mar 5, 2026
07b212f
Serialize observation windows
hettlage Apr 19, 2026
3f686ef
Fix linting issues
hettlage Apr 19, 2026
79ee33b
Add a section on SALT to the README
hettlage Apr 27, 2026
086f23f
Add PyAstroSALT as a dependency
hettlage Apr 27, 2026
8a01149
Add SALT configuration settings
hettlage Apr 27, 2026
bd390a4
Handle missing windows
hettlage Apr 27, 2026
470119e
Fix name of the file containing the submitted blocks
hettlage Apr 27, 2026
47cc917
Remove wrong type from Hrs documentation
hettlage Apr 27, 2026
b39f7e7
Handle the case of no arc request correctly
hettlage Apr 27, 2026
d12e1ee
Move conftest.py
hettlage Apr 27, 2026
229914e
Remove extraneous whitespace in XML
hettlage Apr 27, 2026
699882e
Fix the type hint for blocks
hettlage Apr 27, 2026
3b08519
Upgrade PyAstroSALT
hettlage Apr 28, 2026
0d51eaf
Revert dependency issues because of Pydantic issue
hettlage Apr 28, 2026
25ceffc
Update PyAstroSALT dependency
hettlage May 7, 2026
3b3859b
Add the SALT facility class
hettlage May 7, 2026
5e4c69e
Add an example notebook for SALT requests
hettlage May 7, 2026
8f40eaf
Merge branch 'main' into salt-facility
hettlage May 7, 2026
bd50a5b
Update the uv lock file
hettlage May 7, 2026
fbf04c8
Fix a formatting issue
hettlage May 7, 2026
2d5452d
Add the dependency group for SALT when testing
hettlage May 7, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ name: CI
on:
# Triggers the workflow on push or pull request events but only for the "main" branch
push:
branches: ["main"]
branches: [ "main" ]
pull_request:
branches: ["main"]
branches: [ "main" ]

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
Expand Down Expand Up @@ -44,7 +44,7 @@ jobs:
python-version: ${{ matrix.python-version }}

- name: Install the project
run: uv sync --dev --extra eso --extra lt
run: uv sync --dev --extra eso --extra lt --extra salt

- name: Run tests
run: uv run pytest
54 changes: 50 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ A suite of modules to enable TDA/MMA observations
[issues](https://github.com/AEONplus/AEONlib/issues)

# 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.
Expand All @@ -33,8 +34,8 @@ Environmental variables take precedence over .env files. See the
[pydantic-settings](https://docs.pydantic.dev/latest/concepts/pydantic_settings/) documentation
for more details.


# Testing

This project uses [pytest](https://docs.pytest.org/) to run tests:

```bash
Expand All @@ -59,6 +60,7 @@ pytest -m "not side_effect"
CI does not run tests marked as online.

## Viewing logs during tests

Aeonlib turns on the Pytest
[Live Logging](https://docs.pytest.org/en/stable/how-to/logging.html#live-logs) feature.
By default any logging calls with a level above `WARNING` will be displayed to the console
Expand All @@ -70,9 +72,11 @@ pytest -m online --log-cli-level=debug
```

# Linting

All code is formatted via [ruff](https://astral.sh/ruff).

# Code Generation

Las Cumbres Observatory [instrument classes](src/aeonlib/ocs/lco/instruments.py)
are generated via the [generator.py](codegen/lco/generator.py) script. This script
takes as input the [OCS instruments api](https://observe.lco.global/api/instruments/)
Expand Down Expand Up @@ -105,22 +109,26 @@ LCO instruments definition file:
```bash
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](#configuration) for instructions on setting these values.

```python
lco_token: str = ""
lco_api_root: str = "https://observe.lco.global/api/"
```

### Helpful links

* [LCO Observation Portal](https://observe.lco.global/)
Expand All @@ -132,46 +140,55 @@ lco_api_root: str = "https://observe.lco.global/api/"
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](#configuration) for instructions on setting these values.

```python
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](#configuration) for instructions on setting these values.

```python
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:

```bash
pip install aeonlib[eso]
uv sync --extra eso
poetry install --with eso
```

### Configuration Values

See [configuration](#configuration) for instructions on setting these values.

```python
Expand All @@ -185,17 +202,20 @@ eso_password: str = ""
* [ESO Phase 2 API](https://www.eso.org/sci/observing/phase2/p2intro/Phase2API.html)
* [ESO Phase 2 Demo Application](https://www.eso.org/p2demo/home)


## LT (Liverpool Telescope)

### Dependency Group

To use the LT facility, you must install the `lt` group:

```bash
pip install aeonlib[lt]
uv sync --extra lt
poetry install --with lt
```

### Configuration Values

See [configuration](#configuration) for instructions on setting these values.

```python
Expand All @@ -204,17 +224,43 @@ lt_password: str = ""
lt_host: str = ""
lt_port: str = ""
```

### Helpful links
* [LT Phase 2 Information](https://telescope.livjm.ac.uk/PropInst/Phase2/)

* [LT Phase 2 Information](https://telescope.livjm.ac.uk/PropInst/Phase2/)

## SAAO (South African Astronomical Observatory)

### Configuration Values

```python
saao_token: str = ""
saao_api_root: str = "https://ocsio.saao.ac.za/api/"
saao_api_root: str = "https://ocsio.saao.ac.za/api/"
```

### Helpful links

* [SAAO Observatory Control System](https://ocsio.saao.ac.za/create)

## SALT (Southern African Large Telescope)

### Dependency Group

To use the SALT facility, you must install the `salt` group:

```bash
pip install aeonlib[salt]
uv sync --extra salt
poetry install --with salt
```

### Configuration values

See [configuration](#configuration) for instructions on setting these values.

```python
salt_username: str = ""
salt_password = ""
```

The username and password are those you would use for the [SALT Web Manager](https://www.salt.ac.za/wm/).
Loading
Loading