matsengrp / phip-flow

A Nextflow pipeline to align, merge, and organize large PhIP-Seq datasets
MIT License
10 stars 6 forks source link

streamlit phip-viz error on startup #71

Closed bkellman closed 2 months ago

bkellman commented 7 months ago

I am trying to use phip-viz to view the pipeline output but running into an issue.

When I startup the app (with or without the -v parameter set), e.g.,

docker run -p 8501:8501 quay.io/matsengrp/phip-viz
docker run -p 8501:8501 -v $PWD:/app/data/ quay.io/matsengrp/phip-viz
docker run -p 8501:8501 -v <path_to_dotphipfile>/ quay.io/matsengrp/phip-viz
docker run -p 8501:8501 -v <path_to_app/data/dotphipfile>/ quay.io/matsengrp/phip-viz

I get the same error,

File "/usr/local/lib/python3.7/site-packages/streamlit/runtime/scriptrunner/script_runner.py", line 556, in _run_script
    exec(code, module.__dict__)
File "/app/streamlit_app.py", line 167, in <module>
    f"{fp}" for fp in os.listdir("./data")

I tried pulling the docker image a few different ways (implicitly on run and explicitly with a direct download). I also tried updating streamlite by reinstalling through conda (which shouldn't work but I thought I'd try). But I keep getting the same error. It seems like I'm supposed to be able to upload a dataset but the upload button seems to be dead too (below). Is this a wd issue or is this app defunct?

image

jgallowa07 commented 2 months ago

Thanks for pointing this out. I found a bug with the filepaths expected by the app, and some deprecated streamlit code. However, this bug was resulting in a FileNotFoundError. I was not seeing the error you posted above.

I've pushed a patched image to quay.io/matsengrp/phip-viz

To be clear, be sure that your current working directory contains ".phip" files. So if you were to run the example dataset through the pipeline, you'd do

cd results/pickle_data
docker run -p 8501:8501 -v $PWD:/app/data/ quay.io/matsengrp/phip-viz

Can you try this with the updated container (be sure to remove any old image you've pulled)?

bkellman commented 2 months ago

Awesome! working on it now.

jgallowa07 commented 2 months ago

Closing this for now as things seems to working with the new container. @bkellman feel free to re-open if you find the updated container did not work on your end. Thanks.