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

stopped polling for changes once the panda is in an err state #108

Merged
merged 1 commit into from
Apr 8, 2024

Conversation

evalott100
Copy link
Contributor

@evalott100 evalott100 commented Apr 4, 2024

Closes #107

We currently cannot set the alarm state of an out record in softioc, however the new PV PANDA:Status will still work for our cluster liveness check.

We also need to make a corresponding change in the client to break out of the loop in asyncio.AsyncioClient._ctrl_read_forever if we receive no bytes.

Copy link

codecov bot commented Apr 4, 2024

Codecov Report

Attention: Patch coverage is 96.29630% with 1 lines in your changes are missing coverage. Please review.

Project coverage is 90.87%. Comparing base (e4c51ea) to head (caa753f).

Files Patch % Lines
src/pandablocks_ioc/_connection_status.py 94.11% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #108      +/-   ##
==========================================
+ Coverage   90.02%   90.87%   +0.84%     
==========================================
  Files           7        8       +1     
  Lines        1203     1227      +24     
  Branches      192      194       +2     
==========================================
+ Hits         1083     1115      +32     
+ Misses         82       74       -8     
  Partials       38       38              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@evalott100 evalott100 force-pushed the handle_disconnect_better branch from cd6b24c to ad44331 Compare April 4, 2024 10:01
@evalott100
Copy link
Contributor Author

Now if there's a TimeoutError the ioc closes the client after going into an alarm state. The client doesn't deal with the PandA's unresponsiveness.

Also set a new PV PANDA:Status to one of DISCONNECTED, CONNECTED, CONNECTING.
Added tests.
@evalott100 evalott100 force-pushed the handle_disconnect_better branch from ad44331 to caa753f Compare April 4, 2024 10:07
@evalott100 evalott100 requested a review from coretl April 4, 2024 10:07
Copy link
Contributor

@coretl coretl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just need something in the client too to break out when recv returns nothing

@evalott100 evalott100 force-pushed the handle_disconnect_better branch from 42dcdaa to caa753f Compare April 8, 2024 10:06
@evalott100 evalott100 merged commit 47637b4 into main Apr 8, 2024
38 checks passed
@evalott100 evalott100 deleted the handle_disconnect_better branch April 8, 2024 10:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Change behaviour when device disconnects
2 participants