Metadata-Version: 2.4
Name: satnogs-obs-deleter
Version: 0.1.0
Summary: Script for maintaining a fair distribution of observation time on your station
Author: Martin Hübner
Author-email: Martin Hübner <martin.hubner@web.de>
License-Expression: AGPL-3.0-only
License-File: LICENSE
Requires-Dist: satnogs-api-client>=0.4
Requires-Python: >=3.10
Description-Content-Type: text/markdown

# satnogs-obs-deleter

This script maintains a fair distribution of observation time on your satnogs
station(s). It achieves this by calculating the success rate for each
transmitter of future observations per station. If the probability drops below
a configured threshold, the observation will be de-scheduled.

> [!TIP]
> Main Repository: [codeberg.org/akira25/satnogs-obs-deleter](https://codeberg.org/akira25/satnogs-obs-deleter). Please contribute there.


## Installation

You can get this software by cloning this repository:

```sh
$ git clone https://codeberg.org/akira25/satnogs-obs-deleter.git
$ cd satnogs-obs-deleter
$ python -m venv .venv
$ source .venv/bin/activate
$ pip install -e '.'
$ satnogs-obs-deleter --help
```

This project is compatible with using [uv](https://docs.astral.sh/uv/):

```sh
$ git clone https://codeberg.org/akira25/satnogs-obs-deleter.git
$ cd satnogs-obs-deleter
$ uv sync
$ uv run satnogs-obs-deleter --help
```

## Configuration

To run `satnogs-obs-deleter`, you will need a configuration file. It is toml-based
and should have a structure similar to this:

```toml
#
# satnogs-obs-deleter configuration
#

station = [106, 4271]  # Needs to be a list
api_token = "__YOUR_TOKEN_HERE__"

# Observations for these satellites will be blocked in general. Please consider
# using this sparsely.
blocked_satellites = [
    # "Some-Sat",  # schedules massively without ever checking results
]

# Block observations from specific observers. Also useful for maintenance-situations
blocked_observers = [
    # "Some-User",
]

# Block observations that are very likely to fail, e.g. because they failed on this station very often in the past
block_likely_failing = true
# Block transmitters if their success rate on the station is below this threshold
min_success_rate = 0.20  # percent

# Block observations, that infringe the min-horizon you have set in satnogs-networks web interface
# (not implemented yet)
block_min_horizon = false
# Delete passes that culminate below this limit. (Not implemented yet)
block_min_culmination = 10  # degree.
```

## License

This project is licensed under the [GNU Affero General Public License v3.0 only](LICENSE).
