Describe the bug
After upgrading Komga to version 1.24.4, komf fails to connect and throws a deserialization error when fetching the current user from the Komga API.
Error message:
JsonConvertException: Illegal input: Field 'ageRestriction' is required for type with serial name 'snd.komga.client.user.KomgaUser', but it was missing at path: $
Root cause
Komga 1.24.4 introduced the following change (see their changelog):
omit UserDto.ageRestriction instead of returning null
Previously, the API returned "ageRestriction": null. Now the field is omitted entirely from the response. komf's KomgaUser model has ageRestriction as a required field with no default, so deserialization
fails when the field is absent.
Steps to reproduce
- Run komf
latest (1.7.1) against Komga 1.24.4
- Attempt to connect to Komga from komf's web UI
- Observe the
JsonConvertException above
Expected behavior
komf should handle a missing ageRestriction field gracefully (e.g. by making it nullable or providing a default value).
Environment
- komf version: 1.7.1 (
latest)
- Komga version: 1.24.4
- Workaround: pinning Komga to 1.24.3 restores functionality
Describe the bug
After upgrading Komga to version 1.24.4, komf fails to connect and throws a deserialization error when fetching the current user from the Komga API.
Error message:
JsonConvertException: Illegal input: Field 'ageRestriction' is required for type with serial name 'snd.komga.client.user.KomgaUser', but it was missing at path: $
Root cause
Komga 1.24.4 introduced the following change (see their changelog):
Previously, the API returned
"ageRestriction": null. Now the field is omitted entirely from the response. komf'sKomgaUsermodel hasageRestrictionas a required field with no default, so deserializationfails when the field is absent.
Steps to reproduce
latest(1.7.1) against Komga 1.24.4JsonConvertExceptionaboveExpected behavior
komf should handle a missing
ageRestrictionfield gracefully (e.g. by making it nullable or providing a default value).Environment
latest)