Hi Charly, thanks for the response.
Reading through my code I realized that I had misspelled the requirements.txt file, to ‘requirments.txt’. I even did it in the title of this post haha.
It’s loading now, but weirdly, when I try to input a valid date, I get an error, and no graph shows up. It still works when I run it locally, but not deployed. Here’s the full error:
────────────────────── Traceback (most recent call last) ───────────────────────
/home/adminuser/venv/lib/python3.11/site-packages/streamlit/runtime/scriptru
nner/script_runner.py:600 in _run_script
/mount/src/stockchecker/main.py:23 in <module>
20 if len(ticker1) > 1 and start_date != end_date:
21 │ # Chart 1
22 │ data = yf.download(ticker1, start=start_date, end=end_date)
❱ 23 │ fig = px.line(data, x=data.index, y=data['Adj Close'], title=ticker
24 │ st.plotly_chart(fig)
25
26
/home/adminuser/venv/lib/python3.11/site-packages/plotly/express/_chart_type
s.py:262 in line
259 │ In a 2D line plot, each row of `data_frame` is represented as ver
260 │ a polyline mark in 2D space.
261 │ """
❱ 262 │ return make_figure(args=locals(), constructor=go.Scatter)
263
264
265 line.__doc__ = make_docstring(line, append_dict=_cartesian_append_dic
/home/adminuser/venv/lib/python3.11/site-packages/plotly/express/_core.py:19
45 in make_figure
1942 │ layout_patch = layout_patch or {}
1943 │ apply_default_cascade(args)
1944 │
❱ 1945 │ args = build_dataframe(args, constructor)
1946 │ if constructor in [go.Treemap, go.Sunburst, go.Icicle] and args["
1947 │ │ args = process_dataframe_hierarchy(args)
1948 │ if constructor == "timeline":
/home/adminuser/venv/lib/python3.11/site-packages/plotly/express/_core.py:13
24 in build_dataframe
1321 │ hist1d_orientation = constructor == go.Histogram or "ecdfmode" in
1322 │ if constructor in cartesians:
1323 │ │ if wide_x and wide_y:
❱ 1324 │ │ │ raise ValueError(
1325 │ │ │ │ "Cannot accept list of column references or list of c
1326 │ │ │ )
1327 │ │ if df_provided and no_x and no_y:
────────────────────────────────────────────────────────────────────────────────
ValueError: Cannot accept list of column references or list of columns for both
`x` and `y`.
Not sure why this error is occuring, the error message that pops up on screen is:
File "/home/adminuser/venv/lib/python3.11/site-packages/streamlit/runtime/scriptrunner/script_runner.py", line 600, in _run_script
exec(code, module.__dict__)File "/mount/src/stockchecker/main.py", line 23, in <module>
fig = px.line(data, x=data.index, y=data['Adj Close'], title=ticker1)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^File "/home/adminuser/venv/lib/python3.11/site-packages/plotly/express/_chart_types.py", line 262, in line
return make_figure(args=locals(), constructor=go.Scatter)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^File "/home/adminuser/venv/lib/python3.11/site-packages/plotly/express/_core.py", line 1945, in make_figure
args = build_dataframe(args, constructor)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^File "/home/adminuser/venv/lib/python3.11/site-packages/plotly/express/_core.py", line 1324, in build_dataframe
raise ValueError(
Code all seems to be matching, the only thing I can think of is that there was a .devcontainer folder added to the github repo automatically, but I didn’t want to delete it incase it’s necessary and not causing the error