-
Notifications
You must be signed in to change notification settings - Fork 9
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
Callback for clicking on annotations #76 #80
base: main
Are you sure you want to change the base?
Conversation
The ci error comes from my code? ... |
https://github.com/lfoppiano/streamlit-pdf-viewer/actions/runs/12107866260 |
@lfoppiano Considering this, I’m beginning to think that it might be necessary to set up local environments for Python 3.7 and Python 3.8, where the tests have been failing so far. However, looking at the specific error details in the GitHub Actions logs, as shown below, the test might be unstable since I haven’t made any changes to the code that would affect the height or the number of components. https://github.com/lfoppiano/streamlit-pdf-viewer/actions/runs/12139594120/job/33847552805?pr=80 > assert round(b_box_1['height']) < iframe_box['height'] and round(b_box_1['height']) > 0
E assert (2378 < 926.9999694824219)
E + where 2378 = round(2377.7000427246094)
tests/test_tabs.py:86: AssertionError https://github.com/lfoppiano/streamlit-pdf-viewer/actions/runs/12139709855/job/33847907010?pr=80 > assert len(iframe_components) == 6
E assert 5 == 6
E + where 5 = len([<Locator frame=<Frame name= url='http://localhost:40857/'> selector='iframe[title="streamlit_pdf_viewer.streamlit_pdf...me name= url='http://localhost:40857/'> selector='iframe[title="streamlit_pdf_viewer.streamlit_pdf_viewer"] >> nth=4'>])
tests/test_resolution_boost.py:42: AssertionError Could you share your thoughts before I investigate further? |
This works great locally for me (python 3.10) |
Thanks for this PR, it's great you've done it. I tried myself but I failed... I really appreciate. |
@t29mato It seems tests work. Could you please add some documentation in the readme.md? in particular we need some examples on how to define the function etc... |
I found that the tests are running with the 3.10.12 version no matter what we set up before... no idea why... 😭 |
@lfoppiano I've updated the readme. please check it out |
to support the callback function on annotation for #76
behavior
pr80.mov
I've tested using the application structure-vision lfoppiano/structure-vision#4