Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
19 changes: 19 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,25 @@ jobs:
# installation problems if out of date.
python -m pip install --upgrade pip setuptools numpy

mkdir ~/repos
pushd ~/repos
echo $PWD

git clone https://github.com/bluesky/bluesky-queueserver.git
pushd bluesky-queueserver
pip install .
popd
echo $PWD

git clone https://github.com/bluesky/bluesky-httpserver.git
pushd bluesky-httpserver
pip install .
popd
echo $PWD

popd
echo $PWD

pip install .
pip install -r requirements-dev.txt
pip list
Expand Down
24 changes: 23 additions & 1 deletion .github/workflows/docs_publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,12 @@ jobs:
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- uses: shogo82148/actions-setup-redis@v1
with:
redis-version: "7.x"
- name: Install dependencies
run: |
sudo apt install redis
# sudo apt install redis

# Versioneer uses the most recent git tag to generate __version__, which appears
# in the published documentation.
Expand All @@ -35,6 +38,25 @@ jobs:
# installation problems if out of date.
python -m pip install --upgrade pip setuptools numpy

mkdir ~/repos
pushd ~/repos
echo $PWD

git clone https://github.com/bluesky/bluesky-queueserver.git
pushd bluesky-queueserver
pip install .
popd
echo $PWD

git clone https://github.com/bluesky/bluesky-httpserver.git
pushd bluesky-httpserver
pip install .
popd
echo $PWD

popd
echo $PWD

pip install .
pip install -r requirements-dev.txt
pip list
Expand Down
7 changes: 5 additions & 2 deletions .github/workflows/testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
python-version: ["3.10", "3.11", "3.12", "3.13"]
group: [1, 2, 3]
fail-fast: false

Expand All @@ -20,9 +20,12 @@ jobs:
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- uses: shogo82148/actions-setup-redis@v1
with:
redis-version: "7.x"
- name: Install dependencies
run: |
sudo apt install redis
# sudo apt install redis

# These packages are installed in the base environment but may be older
# versions. Explicitly upgrade them because they often create
Expand Down
10 changes: 8 additions & 2 deletions bluesky_queueserver_api/tests/test_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -4235,15 +4235,18 @@ def check_status(status, manager_state, worker_environment_exists):
RM = instantiate_re_api_class(rm_api_class)
assert RM.system_info_monitor.enabled is False

def _get_last_status():
def _get_last_status(timeout=10):
st = None
t0 = ttime.time()
while True:
try:
msg = RM.system_info_monitor.next_msg(timeout=0.1)
st = msg["msg"]["status"]
except RM.RequestTimeoutError:
if st is not None:
break
if ttime.time() >= t0 + timeout:
raise TimeoutError()
return st

if option == "single_enable":
Expand Down Expand Up @@ -4294,15 +4297,18 @@ async def testing():
RM = instantiate_re_api_class(rm_api_class)
assert RM.system_info_monitor.enabled is False

async def _get_last_status():
async def _get_last_status(timeout=10):
st = None
t0 = ttime.time()
while True:
try:
msg = await RM.system_info_monitor.next_msg(timeout=0.1)
st = msg["msg"]["status"]
except RM.RequestTimeoutError:
if st is not None:
break
if ttime.time() >= t0 + timeout:
raise TimeoutError()
return st

if option == "single_enable":
Expand Down
4 changes: 2 additions & 2 deletions docs/source/api-reference.rst
Original file line number Diff line number Diff line change
Expand Up @@ -262,8 +262,8 @@ API for monitoring system info of RE Manager

Each instance of ``REManagerAPI`` holds a reference to System Info Monitor. The monitor operates
similary to the Console Monitor and allows to receive streamed system information in real time.
The stream currently contains only messages with RE Manager *status*. Additional messages may be
added to the stream later.
The stream currently contains only messages with RE Manager *status*. Additional messages may be
added to the stream later.

.. autosummary::
:nosignatures:
Expand Down
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# List required packages in this file, one per line.
bluesky-queueserver
websockets
httpx
Loading