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

khepri_machine: Use functions to manipulate the internal state #253

Merged

Conversation

dumbbell
Copy link
Member

… instead of using the record directly.

Why

This is a preparation step for a future update of the record. At that point, there will be two versions of the state record to support and it's easier to isolate that handling in a few functions.

How

All reads and writes to the state go through a set of get_*/1 and set_*/2 functions.

... instead of using the record directly.

[Why]
This is a preparation step for a future update of the record. At that
point, there will be two versions of the state record to support and
it's easier to isolate that handling in a few functions.

[How]
All reads and writes to the state go through a set of `get_*/1` and
`set_*/2` functions.
@dumbbell dumbbell added the enhancement New feature or request label Feb 23, 2024
@dumbbell dumbbell added this to the v0.13.0 milestone Feb 23, 2024
@dumbbell dumbbell self-assigned this Feb 23, 2024
Copy link

codecov bot commented Feb 23, 2024

Codecov Report

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

Project coverage is 89.34%. Comparing base (1bf8154) to head (d72e300).

Files Patch % Lines
src/khepri_machine.erl 96.87% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #253      +/-   ##
==========================================
+ Coverage   89.15%   89.34%   +0.19%     
==========================================
  Files          20       20              
  Lines        2932     2975      +43     
==========================================
+ Hits         2614     2658      +44     
+ Misses        318      317       -1     
Flag Coverage Δ
erlang-24 88.26% <96.87%> (+0.13%) ⬆️
erlang-25 88.30% <96.87%> (+0.34%) ⬆️
erlang-26 89.00% <96.87%> (+0.16%) ⬆️
os-ubuntu-latest 89.34% <96.87%> (+0.25%) ⬆️
os-windows-latest 89.00% <96.87%> (+0.12%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

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

@dumbbell dumbbell marked this pull request as ready for review February 23, 2024 14:05
@dumbbell dumbbell merged commit 6c20549 into main Feb 23, 2024
12 checks passed
@dumbbell dumbbell deleted the isolate-machine-state-handling-in-dedicated-functions branch February 23, 2024 14:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant