Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds except for caget failure #576

Merged
merged 3 commits into from
Nov 27, 2023
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
6 changes: 6 additions & 0 deletions docs/agents/pysmurf-controller.rst
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,12 @@ These can be installed via pip:
$ python -m pip install 'sodetlib @ git+https://github.com/simonsobs/sodetlib.git@master'
$ python -m pip install 'sotodlib @ git+https://github.com/simonsobs/sotodlib.git@master'

Additionally, ``socs`` should be installed with the ``pysmurf`` group:

.. code-block:: bash

$ pip install -U socs[pysmurf]

Configuration File Examples
-----------------------------------

Expand Down
2 changes: 2 additions & 0 deletions docs/user/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ The different groups, and the agents they provide dependencies for are:
- Magpie Agent
* - ``pfeiffer``
- Pfeiffer TC 400 Agent
* - ``pysmurf``
- Pysmurf Controller Agent
* - ``smurf_sim``
- SMuRF File Emulator, SMuRF Stream Simulator
* - ``synacc``
Expand Down
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ pandas
pfeiffer-vacuum-protocol==0.4

# pysmurf controller
pyepics
pysmurf @ git+https://github.com/slaclab/pysmurf.git@main
sodetlib @ git+https://github.com/simonsobs/sodetlib.git@master
sotodlib @ git+https://github.com/simonsobs/sotodlib.git@master
Expand Down
15 changes: 8 additions & 7 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,12 @@
pfeiffer_deps = ['pfeiffer-vacuum-protocol==0.4']

# Pysmurf Controller Agent
# pysmurf_deps = [
# 'pysmurf @ git+https://github.com/slaclab/pysmurf.git@main',
# 'sodetlib @ git+https://github.com/simonsobs/sodetlib.git@master',
# 'sotodlib @ git+https://github.com/simonsobs/sotodlib.git@master',
# ]
pysmurf_deps = [
'pyepics',
# 'pysmurf @ git+https://github.com/slaclab/pysmurf.git@main',
# 'sodetlib @ git+https://github.com/simonsobs/sodetlib.git@master',
# 'sotodlib @ git+https://github.com/simonsobs/sotodlib.git@master',
]

# SMuRF File Emulator, SMuRF Stream Simulator
smurf_sim_deps = ['so3g']
Expand All @@ -60,7 +61,7 @@
# Note: Not including the holograph deps, which are Python 3.8 only. Also not
# including any dependencies with only direct references.
all_deps = acu_deps + labjack_deps + magpie_deps + pfeiffer_deps + \
smurf_sim_deps + synacc_deps + timing_master_deps
pysmurf_deps + smurf_sim_deps + synacc_deps + timing_master_deps
all_deps = list(set(all_deps))

setup(
Expand Down Expand Up @@ -119,7 +120,7 @@
'labjack': labjack_deps,
'magpie': magpie_deps,
'pfeiffer': pfeiffer_deps,
# 'pysmurf': pysmurf_deps,
'pysmurf': pysmurf_deps,
'smurf_sim': smurf_sim_deps,
'synacc': synacc_deps,
'timing_master': timing_master_deps,
Expand Down
3 changes: 2 additions & 1 deletion socs/agents/pysmurf_controller/agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
import time
from typing import Optional

import epics
import numpy as np
import sodetlib as sdl
from ocs import ocs_agent, site_config
Expand Down Expand Up @@ -316,7 +317,7 @@ def check_state(self, session, params=None):
stream_id=cfg.stream_id,
)
session.data.update(d)
except RuntimeError:
except (RuntimeError, epics.ca.ChannelAccessGetFailure):
self.log.warn("Could not connect to epics server! Waiting and "
"then trying again")

Expand Down