Solara

S

Solara

Join the community to ask questions about Solara and get answers from other members.

Join

questions-issues

general

announcements

404 errors on Jupyter kernels running under starlette

OS: Linux VM Situation: running behind nginx proxy Use case: Displaying Solara app (in particular a Jdaviz interactive window) as an embedded frame in a webpage Problem: I've gotten everything to the point where it seems to mostly be working, except that I'm getting 404 errors part of the way in to loading the interface. In particular, I'm getting the following (as reported from the uvicorn starlette log output):...

Updating & re-rendering custom `component_vue`

Hi there! I have a question regarding the updating/rendering of a custom component_vue component. Say I have a fairly complex component_vue . It has many elements, and lots of props. Is there some condition after which one can say "you are using way too many props for solara + vue to handle the re-rendering smoothly". Or is there some condition, like are the props updated (on the frontend side) simultaneously or one by one.. ...

Update state when component is displayed in the front end

I am using solara for an experimental logbook app. The app displays a list of markdown entries, and this list can get quite big and slow to load, expecially if there are images inside. With some simple print debugging, i can see that my custom components render quite fast, but the solara.Markdown() takes a while to rended when there are large images to display. I am thinking of only displaying the text (without images) at first, and only when that is done, go back and add the images. But i would need some kind of callback that updates a reactive variable when a component has finshied loading on the client. Is this possible? Is there a better way to improve performance?...

Change size of matplotlib fig

So I am using Mesa so create a simulation. In order to visualize it I am using the build in SolaraViz library to visualize the simulation. However I am facing a problem, the matplotlib graph that is being used to plot the simulation is too small. I've tried to scale the graph without success so far. The code used looks as following:...
No description

Does Solara offer a directory picker widget by any chance?

Does Solara offer a directory picker widget by any chance?

is there a way for an user to communicate with the kernel through the client?

I'm just wondering if that's possible, because I remember I could do something like that when I used voila...

Best Front-End for App with a more Advanced UI?

First, thanks Maarten! Newbie question here: I'm a python dev (among othere things) but a front-end + javascript neophte. My dream is to use Solara to build a full-stack application with a beautiful front-end as if the app was a pure React/Next/Vue.js/Nuxt/Angular/... app. I know that I can build a nice data dashboard with Solara but what else would you recommend learning in order to build a really advanced, gorgeous front-end UI for a more full-featured application with Solara? React? Next? Is it easier to integrate React components than, say, PyQT? I want full control over the exact layout of the UI and the ability to create custom components? ...

Localization of datetime

Hi there! I am trying to figure out how to localize a datetime object in my Solara application. I want to show a banner like: ```...

Missing Static Assets in Solara Installation (main8.css)

I'm encountering an issue with missing static assets in my Solara installation. Specifically, the main8.css file is missing from the CDN directory. Environment: OS: Windows Server Python: [your Python version]...
No description

State updates don't trigger page rerender in some cases

I have a @solara.component that immediately sets a reactive state to True. When this happens, the page fails to rerender: ```python import solara as sl ...

Update Ipyaggrid data from selected dataframe

I need to update the ipyaggrid table based on the DataFrame selected in the dropdown.
However, only the first selected DataFrame gets updated, and not the subsequent ones.
On the other hand, the Solara datatable updates correctly.
Can someone help me find a solution, please? ...

Dashboard from a dataframe, modified only i-th row

Hello, I have a dashboard created from a dataframe. For each row from a df subset a card with graph and some other info is created. Now if the data in i-th row are modified, I want to update only the corresponding card. My current solution updates all rows. The code is at https://gist.github.com/robert-marik/77e1bdccc617bd6880f324535fe74a98 (I was not allowed to paste link from pycafe, since the message turned to be long). When I click the button, all cards are rendered again, despite the fact that only one row has been modified. Any idea?...

Second sidebar

Is there any easy way to create a second sidebar where can place extra controls? Similar to Tensorflow tensorboard (e.g https://www.tensorflow.org/tensorboard) Or anyway to change default layout by using Vuetify wireframes (e.g https://v2.vuetifyjs.com/en/getting-started/wireframes/) ?...

iPhone mine

My iPhone Mini (13) is having some issues with Solara, as the browser keeps freezing. Which iphone would you recommend for better performance ?

Database interaction

Do you have an example where solara is used to generate an interface allowing the user to interact with a database ?: I am looking to build an app that allows - reading info through a research bar (researching an email and displaying related info like associated group) - editing info in the displayed results and saving it to the database - writing a new line in a table thanks to a form-like component...

Is there a way to manage multi-user storage?

I work on a system where we allow users to start AWS instances and use them to run jupyter notebooks and/or voila apps, basically, once the instance starts, we mount the user file system and they can run their workflows on their environments. There's a couple of modules that we would like to move from voila, to Solara, we would like to create a custom docker container where we would launch the Solara app... the problem is that we'd like to have user's storage independent, so if an user (that we know who is) launches the tool, they ideally will only have access to an specific folder in the server where Solara is running, but we need to make sure that they cannot see different user's info.... From the point of view of Solara, is there any use case where you have already implemented something similar? is there any application you think might help to achieve this?...

I am trying to create an HTML component with event listeners.

The aim is to have an HTML component to render HTML snippets and than listen to certain events that happen on a particular class. For instance attach a click event listener to all elements with class decorated. I want to emit these events so that I can check in the python backend which element was clicked So far I was able to create the vue template file and also the ipyvuetify component which I then convert to a solara component. It works except for catching the emitted event in python. Here are the two files I have so far as well as the page for solara. Any ideas would be much appreciated....

Solara not respecting different root path

We have a Solara app which we'd like to exist at a specific URL, e.g. http://domain.com/solara-app. However, it doesn't seem like we can find the correct combination of SOLARA_ROOT_PATH, SOLARA_BASE_URL, or SOLARA_ORIGIN to get the app served at that location. Currently, when using SOLARA_ROOT_PATH and SOLAR_BASE_URL, attempting to access http://domain.com/solara-app yields a spinning loading icon and the following the console:
WebSocket connection to 'ws://localhost:8865/solara-app/jupyter/api/kernels/c24edfd8-d5c3-4c25-b9c0-8b1d0b49f2dd/channels?session_id=38c6874d-2fed-4d58-9211-80f5a3f33295' failed:
WebSocket connection to 'ws://localhost:8865/solara-app/jupyter/api/kernels/c24edfd8-d5c3-4c25-b9c0-8b1d0b49f2dd/channels?session_id=38c6874d-2fed-4d58-9211-80f5a3f33295' failed:
We have also tried attempting to mount the Solara app at the specified path in a Starlette server, which does seem to work except that our static asset files are no longer found, and the authentication through Solara Enterprise fails with Starlette complaining about missing middle ware....

Context doesn't update when fetching from a namespace

I'm having some trouble getting a context to be provided then read in a child component properly. At the top-most component, the context is defined, but perhaps because of the import order, it doesn't seem to re-update the context later? When the reading function si called, it only reads it as 'foobar' and doesn't change. Here is the schematic:...

Documentation on caching behaviour

Where can i find documentation / code examples on how solara handles component caching? I noticed that sub components are not re-rendered when their parent is re-rendered if their arguments do not change and if they are in the same order. But if the arguments or the order changes, they get redrawn I am rendering a list of components, to which i need to add in random locations. When adding to the bottom it works great, only rendering the new one, but when adding in other locations it forces a re-render of the whole list. ...
Next