Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FyneApp.toml causes BadLength error #5272

Open
2 tasks done
AquilaFasciata opened this issue Nov 17, 2024 · 5 comments
Open
2 tasks done

FyneApp.toml causes BadLength error #5272

AquilaFasciata opened this issue Nov 17, 2024 · 5 comments
Labels
unverified A bug that has been reported but not verified

Comments

@AquilaFasciata
Copy link

Checklist

  • I have searched the issue tracker for open issues that relate to the same problem, before opening a new one.
  • This issue only relates to a single bug. I will open new issues for any other problems.

Describe the bug

Current go app runs without a FyneApp.toml; upon inserting one (even copying the example in the Docs) causes the following error at runtime:

X Error of failed request:  BadLength (poly request too large or internal Xlib length error)
  Major opcode of failed request:  18 (X_ChangeProperty)
  Serial number of failed request:  246
  Current serial number in output stream:  246

Removing the toml results in a successful build and run.

How to reproduce

  1. Add FyneApp.toml
  2. Try go build, fyne build, or go run main.go and run executable
  3. Error occurs

Screenshots

No response

Example code

func main() {
	prog := app.New()
	mainWindow := prog.NewWindow("Expense Report Builder")
	mainWindow.Resize(fyne.Size{Height: 412, Width: 720})

	templateRow, templatePathBox := inputRow(&mainWindow, "Template: ", FILE)
	rosterRow, rosterPathBox := inputRow(&mainWindow, "Roster: ", FILE)
	outputRow, outputPathBox := inputRow(&mainWindow, "Output: ", FOLDER)
	runButton := widget.NewButton("Create Expense Reports", func() {
		err := business(rosterPathBox.Text, templatePathBox.Text, outputPathBox.Text)
		if err != nil {
			dialog.ShowError(err, mainWindow)
		}
	})

	mainWindow.SetContent(container.NewStack(
		container.NewVBox(
			templateRow, rosterRow, outputRow, runButton,
		),
	))

	mainWindow.ShowAndRun()
	// TODO Build ui
	// TODO Verify additions from Github
}

Fyne version

2.5.2

Go compiler version

1.23.2

Operating system and version

Arch Linux

Additional Information

This only appears to be an issue with the example code provided; simple "Hello, world" programs work (as well as the fyne demo app).

@AquilaFasciata AquilaFasciata added the unverified A bug that has been reported but not verified label Nov 17, 2024
@andydotxyz
Copy link
Member

Please share the FyneApp.toml that is causing issues on your machine for clarity.

Most apps include this file and we have never seen the issue reported, so perhaps there is something strange in the file encoding?

@AquilaFasciata
Copy link
Author

FyneApp.txt
Github doesn't allow .toml files, but it's the exact same other than the extension.

@andydotxyz
Copy link
Member

Oh wow I see.
Can you provide more info about the window manager or desktop you are using on Arch? So far I cannot replicate this...

@AquilaFasciata
Copy link
Author

AquilaFasciata commented Nov 20, 2024

I've tried this both on KDE Plasma 6, as well as Hyprland with the same error on both.

Curiously, I'm able to build for Windows with fyne-cross but not for Linux with fyne-cross due to a go: download go1.23 for linux/amd64: toolchain not available error. (This was a config error on my part)

@AquilaFasciata
Copy link
Author

For further review, the repo in question is public, just don't judge my poor code, it was thrown together and I'm new to Go 😅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
unverified A bug that has been reported but not verified
Projects
None yet
Development

No branches or pull requests

2 participants