fyne-io / fyne

Cross platform GUI toolkit in Go inspired by Material Design
https://fyne.io/
Other
25.28k stars 1.4k forks source link

Hyphen in app ID results in bad apk package #3000

Open kgolding opened 2 years ago

kgolding commented 2 years ago

Having a hyphen in the app-id result in apk package that will not install with the error "There was a problem while parsing the package" when trying to install on the hadset, and the following error when installing in dev mode using adb install ...

Failure [INSTALL_PARSE_FAILED_BAD_PACKAGE_NAME: Invalid manifest package: bad character '-']

To Reproduce:

Steps to reproduce the behaviour:

  1. In FyneApp.toml in the [Details] section set ID to a string including a hyphen -
  2. Run fyne-cross adroid
  3. Transfer APK file to device and click to install

Device and debug info:

Device info
Jacalz commented 2 years ago

Indeed. Android does not support - in appIDs and they are generally discouraged in AppStream metadata as well (see https://github.com/ximion/metainfocreator/issues/12) I wonder if this issue perhaps makes more sense in fyne-io/fyne than here in fyne-cross?

andydotxyz commented 2 years ago

Agreed, feel free to move as it is fyne package that does this work.

Jacalz commented 2 years ago

Cool. I moved it over.

pierrec commented 2 months ago

What is the best practice in that case? Replace hyphens with underscores?

pierrec commented 2 months ago

nvm I see that this is actually already fixed! Maybe this should be closed.