flet
flet copied to clipboard
Failed to start Flutter renderer: No available configurations for the given RGBA pixel format
I can't run your examples, flet just opened a black screen after running the script.

Could you please provide more info like what OS is that, version of Python, etc.?
Full error message, a code sample to reproduce the issue.
Error: note: second warning occurred when I close the app
App URL: http://127.0.0.1:39159
Connected to Flet app and handling user sessions...
** (flet:15375): WARNING **: 08:53:19.431: Failed to start Flutter renderer: No available configurations for the given RGBA pixel format
(flet:15375): GLib-GObject-WARNING **: 08:53:23.631: ../../../gobject/gsignal.c:2736: instance '0x12db290' has no handler with id '100'
OS: Linux Mint 20 Kernel version: 5.4.0-60-generic Python 3.8.5
Script: it doesn't matter what it is. flet can't run any script successfully.
import flet
from flet import ElevatedButton, Text, TextField
def main(page):
def btn_click(e):
if not txt_name.value:
txt_name.error_text = "Please enter your name"
page.update()
else:
name = txt_name.value
page.clean()
page.add(Text(f"Hello, {name}!"))
txt_name = TextField(label="Your name")
page.add(txt_name, ElevatedButton("Say hello!", on_click=btn_click))
flet.app(target=main)
Might make sense to report the issue to flutter as well. I see similar (but not same) "failed to start" due to Linux graphics issues, e.g. here.
There is also the exact same error reported in connection to some other app using Flutter on Linux (Ubuntu).
Well, it would be more helpful for Flutter if @mehrdad-dev submit an issue: install Flutter SDK, do a simple code repro, run flutter doctor, etc. - do all the steps required in issue template. I don't have enough data to submit an issue.
Yes, definitely meant that the user with the problematic OS would be best placed to submit the issue.
Alright, I will send a report after doing these steps.
@mehrdad-dev Did you manage to submit a report to Flutter team?