-
-
Notifications
You must be signed in to change notification settings - Fork 17.7k
Open
Labels
0.kind: bugSomething is brokenSomething is broken6.topic: nixosIssues or PRs affecting NixOS modules, or package usability issues specific to NixOSIssues or PRs affecting NixOS modules, or package usability issues specific to NixOS
Description
Nixpkgs version
- Stable (25.11)
Describe the bug
The traccar settings serializer does not properly escape strings.
Steps to reproduce
{
services.traccar.settings.database.url = "jdbc:postgresql://localhost/traccar?socketFactory=org.newsclub.net.unix.AFUNIXSocketFactory$FactoryArg&socketFactoryArg=/var/run/postgresql/.s.PGSQL.5432";
}leads to this snippet in the /var/lib/traccar/config.xml:
<entry key='database.url'>jdbc:postgresql://localhost/traccar?socketFactory=org.newsclub.net.unix.AFUNIXSocketFactory&socketFactoryArg=/var/run/postgresql/.s.PGSQL.5432</entry>The $FactoryArg part is just removed, and the freestanding & actually should be an & within XML. Not good.
Expected behaviour
All settings are properly serialized into an XML file, such that the string that I put in via Nix is also the string perceived by the Java app reading that XML file (=traccar)
Screenshots
No response
Relevant log output
Additional context
The previous configuration mechanism for traccar was also broken, see #377804 .
System metadata
- system:
"x86_64-linux" - host os:
Linux 6.18.2, NixOS, 25.11 (Xantusia), 25.11.20251229.89dbf01 - multi-user?:
yes - sandbox:
yes - version:
nix-env (Lix, like Nix) 2.93.3 System type: x86_64-linux Additional system types: aarch64-linux, armv7l-linux, i686-linux Features: gc, signed-caches System configuration file: /etc/nix/nix.conf User configuration files: /home/wucke13/.config/nix/nix.conf:/etc/xdg/nix/nix.conf:/home/wucke13/.nix-profile/etc/xdg/nix/nix.conf:/nix/profile/etc/xdg/nix/nix.conf:/home/wucke13/.local/state/nix/profile/etc/xdg/nix/nix.conf:/etc/profiles/per-user/wucke13/etc/xdg/nix/nix.conf:/nix/var/nix/profiles/default/etc/xdg/nix/nix.conf:/run/current-system/sw/etc/xdg/nix/nix.conf Store directory: /nix/store State directory: /nix/var/nix Data directory: /nix/store/zp4ccr3fvndjx0dznjg7yf49xh68bdzw-lix-2.93.3/share - nixpkgs:
/etc/nix/inputs/nixpkgs
Notify maintainers
Note for maintainers: Please tag this issue in your pull request description. (i.e. Resolves #ISSUE.)
I assert that this issue is relevant for Nixpkgs
- I assert that this is a bug and not a support request.
- I assert that this is not a duplicate of an existing issue.
- I assert that I have read the NixOS Code of Conduct and agree to abide by it.
Is this issue important to you?
Add a 👍 reaction to issues you find important.
Metadata
Metadata
Assignees
Labels
0.kind: bugSomething is brokenSomething is broken6.topic: nixosIssues or PRs affecting NixOS modules, or package usability issues specific to NixOSIssues or PRs affecting NixOS modules, or package usability issues specific to NixOS