update GRIB/BUFR media types #349
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: test-publish-subscribe-download | |
on: | |
[ push, pull_request ] | |
jobs: | |
test-publish-subscribe-download: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v3 | |
name: setup Python | |
with: | |
python-version: '3.10' | |
- name: Install pywis-pubsub | |
run: | | |
python3 setup.py install | |
python3 setup.py build | |
pywis-pubsub --version | |
pywis-pubsub schema sync | |
- name: run mosquitto container, detached | |
run: | | |
docker run --rm -d -p 1883:1883 -v $PWD/.github/workflows/test-data/mosquitto.conf:/mosquitto/config/mosquitto.conf --name pywis_pubsub-mqtt eclipse-mosquitto | |
- name: run tests | |
run: | | |
python3 setup.py test | |
- name: subscribe, publish and download without message validation | |
run: | | |
rm -rf .github/workflows/test-data/*.bufr4 | |
pywis-pubsub subscribe --config .github/workflows/test-data/sub-no-msg-validation.yml --download --verbosity DEBUG > /tmp/subscribe.log & | |
sleep 1 | |
pywis-pubsub publish --config .github/workflows/test-data/pub-config.yml --verbosity=DEBUG -i WIGOS_0-454-2-AWSCHIKANGAWA_20221109T135500 -u https://wmostorage.blob.core.windows.net/wmo-public/wmo-information-system/pywis-pubsub-test/WIGOS_0-454-2-AWSCHIKANGAWA_20221109T135500.bufr4 -g 33.8025,-11.8415 -w 0-454-2-AWSCHIKANGAWA | |
sleep 1 | |
less /tmp/subscribe.log | |
ls -lh .github/workflows/test-data/origin/a/wis2/mwi/malawi_wmo_demo/data/core/weather/surface-based-observations/synop/WIGOS_0-454-2-AWSCHIKANGAWA_20221109T135500.bufr4 | |
- name: subscribe, publish and download with message validation | |
run: | | |
rm -rf .github/workflows/test-data/*.bufr4 | |
pywis-pubsub subscribe --config .github/workflows/test-data/sub-with-msg-validation.yml --download --verbosity DEBUG > /tmp/subscribe.log & | |
sleep 1 | |
pywis-pubsub publish --config .github/workflows/test-data/pub-config.yml --verbosity=DEBUG -i WIGOS_0-454-2-AWSCHIKANGAWA_20221109T135500 -u https://wmostorage.blob.core.windows.net/wmo-public/wmo-information-system/pywis-pubsub-test/WIGOS_0-454-2-AWSCHIKANGAWA_20221109T135500.bufr4 -g 33.8025,-11.8415 -w 0-454-2-AWSCHIKANGAWA | |
sleep 1 | |
less /tmp/subscribe.log | |
ls -lh .github/workflows/test-data/origin/a/wis2/mwi/malawi_wmo_demo/data/core/weather/surface-based-observations/synop/WIGOS_0-454-2-AWSCHIKANGAWA_20221109T135500.bufr4 | |
- name: subscribe, publish and download with file-based publication | |
run: | | |
rm -rf .github/workflows/test-data/*.bufr4 | |
pywis-pubsub subscribe --config .github/workflows/test-data/sub-with-msg-validation.yml --download & | |
sleep 1 | |
pywis-pubsub publish --config .github/workflows/test-data/pub-config.yml --verbosity=DEBUG --file .github/workflows/test-data/example-message.json | |
sleep 1 | |
ls -lh .github/workflows/test-data/origin/a/wis2/mwi/malawi_wmo_demo/data/core/weather/surface-based-observations/synop/WIGOS_0-454-2-AWSCHIKANGAWA_20221109T135500.bufr4 |