PermissionError: [Errno 13] when using streamlit_timeline on Streamlit Cloud

No problems when running locally but when I try on the Community Cloud I get this error:

streamlit.runtime.caching.cache_errors.CacheKeyNotFoundError: Local disk cache storage is disabled (persist=None)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):

  File "/home/adminuser/venv/lib/python3.9/site-packages/streamlit/runtime/scriptrunner/", line 552, in _run_script

    exec(code, module.__dict__)

  File "/mount/src/policyinbrief/", line 16, in <module>

    timeline = st_timeline(doc_data, groups=[])  # , options=timeline_options)

  File "/home/adminuser/venv/lib/python3.9/site-packages/streamlit_timeline/", line 126, in st_timeline

    _import_styles(style, True)

  File "/home/adminuser/venv/lib/python3.9/site-packages/streamlit/runtime/caching/", line 211, in wrapper

    return cached_func(*args, **kwargs)

  File "/home/adminuser/venv/lib/python3.9/site-packages/streamlit/runtime/caching/", line 240, in __call__

    return self._get_or_create_cached_value(args, kwargs)

  File "/home/adminuser/venv/lib/python3.9/site-packages/streamlit/runtime/caching/", line 266, in _get_or_create_cached_value

    return self._handle_cache_miss(cache, value_key, func_args, func_kwargs)

  File "/home/adminuser/venv/lib/python3.9/site-packages/streamlit/runtime/caching/", line 320, in _handle_cache_miss

    computed_value = self._info.func(*func_args, **func_kwargs)

  File "/home/adminuser/venv/lib/python3.9/site-packages/streamlit_timeline/", line 71, in _import_styles

    shutil.copyfile(html_backup, html_path)

  File "/usr/local/lib/python3.9/", line 266, in copyfile

    with open(dst, 'wb') as fdst:

PermissionError: [Errno 13] Permission denied: '/home/adminuser/venv/lib/python3.9/site-packages/streamlit_timeline/frontend/build/index.html'

It happens with just instantiating a basic timeline like this:

import streamlit as st
from streamlit_timeline import st_timeline

st.write("## Timeline")

doc_data = [
        "id": 1,
        "content": "item 1",
        "start": "2021-01-01",
        "end": "2021-01-02",

timeline = st_timeline(doc_data, groups=[])  # , options=timeline_options)

Is there a server setting I’m missing?


Hey @makrtank ,

Thanks for sharing this question!

I’m assuming streamlit_timeline is included in your requirements file?

Hey @Caroline

Mild panic as I double checked… :sweat_smile:

it’s actually the streamlit-vis-timeline project:

That makes more sense given where the exception is thrown. But still not sure why it has a problem there.

Just deployed it to AWS EC2 and it works there…

Hm, that is peculiar – can you share the link to the deployed app?

It looks like the streamlit_timeline is doing something a bit unusual, in that it attempts to dynamically overwrite files when the component is actually used. You might consider actually filing an issue with streamlit-timeline requesting that they not require overwriting of files this way, as it seems a bit strange to require this when actually running the code.

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.