Simon Brunning
Simon Brunning11mo ago

I'm having some trouble with `mo.ui.

I'm having some trouble with mo.ui.file - I can't seem to get it to update.
4 Replies
Simon Brunning
Simon BrunningOP11mo ago
I have this simple example:
import marimo

__generated_with = "0.1.78"
app = marimo.App()


@app.cell
def __(mo):
upfile = mo.ui.file(kind="area")
upfile
return upfile,


@app.cell
def __(mo, upfile):
mo.md(f"{upfile=!r} {upfile.name()=!r}")
return


@app.cell
def __():
import marimo as mo
return mo,


if __name__ == "__main__":
app.run()
import marimo

__generated_with = "0.1.78"
app = marimo.App()


@app.cell
def __(mo):
upfile = mo.ui.file(kind="area")
upfile
return upfile,


@app.cell
def __(mo, upfile):
mo.md(f"{upfile=!r} {upfile.name()=!r}")
return


@app.cell
def __():
import marimo as mo
return mo,


if __name__ == "__main__":
app.run()
Simon Brunning
Simon BrunningOP11mo ago
But even after upliading a file, I don't see the value update.
No description
Simon Brunning
Simon BrunningOP11mo ago
I am sure I'm doing somethign wrong here. Ah - looks like the issue is with large files. Small files work fine, but large ones look like they've uploaded, but things seem to freeze..
Simon Brunning
Simon BrunningOP11mo ago
GitHub
Large file uploads fail silently. · Issue #609 · marimo-team/marimo
Describe the bug Uploading a large file using mo.ui.file() fails silently. While rejecting large files is probably necessary, it would be useful to be able to configure the size of acceptable files...