Skip to content

fix #141 save button - #155

Merged
robnagler merged 24 commits into
mainfrom
141-save-button
Feb 4, 2026
Merged

fix #141 save button#155
robnagler merged 24 commits into
mainfrom
141-save-button

Conversation

@moellep

@moellep moellep commented Sep 5, 2025

Copy link
Copy Markdown
Collaborator

I need to add some test cases, but this is ready for a draft review.

@moellep
moellep requested a review from robnagler September 5, 2025 23:09

@robnagler robnagler left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I made all these comments so I'm sending them. After this, I'm going to commit my changes to this branch, and I'll need you to get it working. There should be a test.

Comment thread slicops/package_data/sliclet/screen.yaml Outdated
Comment thread slicops/package_data/sliclet/screen.yaml Outdated
Comment thread slicops/package_data/sliclet/screen.yaml Outdated
Comment thread slicops/package_data/sliclet/screen.yaml Outdated
Comment thread slicops/sliclet/screen.py Outdated
Comment thread slicops/sliclet/screen.py Outdated
Comment thread slicops/sliclet/screen.py Outdated
Comment thread slicops/sliclet/screen.py Outdated
Comment thread slicops/sliclet/screen.py Outdated
Comment thread slicops/sliclet/screen.py Outdated
@moellep
moellep requested a review from robnagler September 16, 2025 21:02
Comment thread tests/plot_test.py
import h5py

i = _imageset()
with pkio.save_chdir(pkunit.work_dir()) as w:

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

save_chdir_work() which empties the directory first

Comment thread tests/plot_test.py


def test_imageset_save_to_file():
from glob import glob

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

generally we just import glob, which is the module, but since you already import pkio. just use pkoio.sorted_glob

Comment thread tests/plot_test.py
:license: http://www.apache.org/licenses/LICENSE-2.0.html
"""

from pykern import pkunit

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

generally we don't import it here just out of formality so that all tests defer imports, which can be very important.

Comment thread tests/plot_test.py
[3, 5, 7.5, 3],
)
pkunit.pkeq(round(f.x.fit.results.sig, 2), 0.53)
pkunit.pkeq([round(v, 2) for v in f.x.fit.fit_line], [0.5, 2.5, 12.5, 2.5, 0.5])

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

this probably should be returned in i

@robnagler
robnagler merged commit 4160acc into main Feb 4, 2026
1 check passed
@robnagler
robnagler deleted the 141-save-button branch February 4, 2026 22:57
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.

2 participants