mirror of
https://github.com/pelican-dev/panel.git
synced 2026-02-24 03:12:01 +03:00
Unable to remove custom container labels which use dot notation (e.g. test.test) #312
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @sebygreen on GitHub (Apr 14, 2025).
Originally assigned to: @rmartinoscar on GitHub.
Current Behavior
The panel throws an error when trying to delete custom container labels if they are formatted using dot notation. The error is thrown when saving the changes in the admin panel.
500 Server ErrorFilament\Forms\Components\KeyValue::Filament\Forms\Components\{closure}(): Argument #1 ($value) must be of type ?string, array givenExpected Behavior
The container labels should be removed when saving, as they do when using a single word as a value.
Steps to Reproduce
test.testand any valuetest.testThis issue was first reported on discord, here
Relevant comment from mristau in the above thread:
"the docker labels are saved as a json object into database and it looks like it'll parse anything with "dot-notation" to an array.
{data.docker_labels.test.test: "__rm__"}i suspect this here fails if there is dot-notation used inside a docker-label"Panel Version
1.0.0-beta19
Wings Version
1.0.0-beta11
Games and/or Eggs Affected
Minecraft (Custom), Minecraft (Vanilla), Satisfactory
Docker Image
ghcr.io/parkervcp/yolks:java_21, ghcr.io/parkervcp/steamcmd:debian
Error Logs
Is there an existing issue for this?
@rmartinoscar commented on GitHub (Apr 14, 2025):
https://docs.docker.com/engine/manage-resources/labels/#key-format-recommendations
I will add a check so it doesn't crash but i can't see how did you manage to create a label with a dot in its labels
@sebygreen commented on GitHub (Apr 14, 2025):
it is my first time using labels. i was messing around with a server dashboard called glance. their system to render pretty docker container information uses labels such as
glance.nameorglance.icon.many thanks for your time.