[Bug][nightly]: getCustomFieldGroup endpoint raises a 500 error when getting a Card Group #909

Closed
opened 2026-02-04 21:36:51 +03:00 by OVERLORD · 4 comments
Owner

Originally created by @hwelch-fle on GitHub (Feb 1, 2026).

Where is the problem occurring?

I encountered the problem while interacting with the server (Backend)

What browsers are you seeing the problem on?

Other

Current behavior

I'm not sure if this is intended behavior or not, but the getCustomFieldGroup end point seems to fail when getting a CustomFieldGroup that is created directly from a Card.

Here's a plankapy example of the endpoint failing

>>> cfg = card.create_card_field_group('My Group')
>>> card.custom_field_groups.extract('name')
('My Group', )
>>> cfg.id
12345678...

>>> planka.endpoints.getCustomFieldGroup(cfg.id)
...
HTTPStatusError: Server error '500 Internal Server Error' for url 'http://localhost:1337/api/custom-field-groups/12345678...'
...

If that endpoint specifically reserved for accessing base/board groups? It's documented as being able to get card groups as long as the user has access to the group:

Retrieves comprehensive custom field group information, including fields and values. Requires access to the board/card.

The group does still appear when accessed using Card['included']:

>>> card.custom_field_groups
[CustomFieldGroup({id: '12345678...', cardId: '<card.id>', boardId: None, baseCustomFieldGroupId: None, ...})]

I am noticing that both Board and BaseCustomFieldGroupId are nulled out in a group created on a card, and in the api/controllers for that endpoint, only board and project are checked:

052edc9fb1/server/api/controllers/custom-field-groups/show.js (L84C1-L87C77)

Desired behavior

A call to getCustomFieldGroup using a CustomFieldGroup that was created on a card returns the associated CustomFieldGroup

Steps to reproduce

call getCustomFieldGroup endpoint (GET api/custom-field-groups/{groupId}) with a groupId that was created from a card modal with no base group selected.

Other information

I can see how joining all cards could be an expensive operation here, but maybe allow passing an optional cardId to the endpoint? For now I can get around the issue by just getting the card value for the CustomFieldGroup and navigating from there.

Originally created by @hwelch-fle on GitHub (Feb 1, 2026). ### Where is the problem occurring? I encountered the problem while interacting with the server (Backend) ### What browsers are you seeing the problem on? Other ### Current behavior I'm not sure if this is intended behavior or not, but the `getCustomFieldGroup` end point seems to fail when getting a CustomFieldGroup that is created directly from a Card. Here's a plankapy example of the endpoint failing ```python >>> cfg = card.create_card_field_group('My Group') >>> card.custom_field_groups.extract('name') ('My Group', ) >>> cfg.id 12345678... >>> planka.endpoints.getCustomFieldGroup(cfg.id) ... HTTPStatusError: Server error '500 Internal Server Error' for url 'http://localhost:1337/api/custom-field-groups/12345678...' ... ``` If that endpoint specifically reserved for accessing base/board groups? It's documented as being able to get card groups as long as the user has access to the group: ``` Retrieves comprehensive custom field group information, including fields and values. Requires access to the board/card. ``` The group does still appear when accessed using `Card['included']`: ```python >>> card.custom_field_groups [CustomFieldGroup({id: '12345678...', cardId: '<card.id>', boardId: None, baseCustomFieldGroupId: None, ...})] ``` I am noticing that both Board and BaseCustomFieldGroupId are nulled out in a group created on a card, and in the `api/controllers` for that endpoint, only board and project are checked: https://github.com/plankanban/planka/blob/052edc9fb1ad751c48f710fbe07b4248b2a6c395/server/api/controllers/custom-field-groups/show.js#L84C1-L87C77 ### Desired behavior A call to `getCustomFieldGroup` using a CustomFieldGroup that was created on a card returns the associated CustomFieldGroup ### Steps to reproduce call `getCustomFieldGroup` endpoint (`GET api/custom-field-groups/{groupId}`) with a groupId that was created from a card modal with no base group selected. ### Other information I can see how joining all cards could be an expensive operation here, but maybe allow passing an optional cardId to the endpoint? For now I can get around the issue by just getting the card value for the CustomFieldGroup and navigating from there.
OVERLORD added the bug label 2026-02-04 21:36:51 +03:00
Author
Owner

@meltyshev commented on GitHub (Feb 1, 2026):

Hey! Thanks for reporting this - it's definitely a bug, I'm getting a 500 too. We hadn't noticed it earlier since we don't use this method from the client (I think we added it because it's used in the Pro version). And yes - both (card and board-wide group) should be accessible.

@meltyshev commented on GitHub (Feb 1, 2026): Hey! Thanks for reporting this - it's definitely a bug, I'm getting a 500 too. We hadn't noticed it earlier since we don't use this method from the client (I think we added it because it's used in the Pro version). And yes - both (card and board-wide group) should be accessible.
Author
Owner

@hwelch-fle commented on GitHub (Feb 1, 2026):

Hey! Thanks for reporting this - it's definitely a bug, I'm getting a 500 too. We hadn't noticed it earlier since we don't use this method from the client (I think we added it because it's used in the Pro version). And yes - both (card and board-wide group) should be accessible.

That's for the fix! That was one of the last pieces for building a test project that hits every end point. One last one I'm having issues with is comments. Specifically embedding/triggering a mention action from the API. Do I need to embed the HTML mention info in the comment text body? Or will an @ suffice? The mention doesn't ping when posted through the API, but it does when I go to edit it through the web client

@hwelch-fle commented on GitHub (Feb 1, 2026): > Hey! Thanks for reporting this - it's definitely a bug, I'm getting a 500 too. We hadn't noticed it earlier since we don't use this method from the client (I think we added it because it's used in the Pro version). And yes - both (card and board-wide group) should be accessible. That's for the fix! That was one of the last pieces for building a test project that hits every end point. One last one I'm having issues with is comments. Specifically embedding/triggering a mention action from the API. Do I need to embed the HTML mention info in the comment text body? Or will an @ suffice? The mention doesn't ping when posted through the API, but it does when I go to edit it through the web client
Author
Owner

@meltyshev commented on GitHub (Feb 2, 2026):

That's for the fix! That was one of the last pieces for building a test project that hits every end point. One last one I'm having issues with is comments. Specifically embedding/triggering a mention action from the API. Do I need to embed the HTML mention info in the comment text body? Or will an @ suffice? The mention doesn't ping when posted through the API, but it does when I go to edit it through the web client

Thanks for the question :) It now works via markdown syntax - Hello, @[demo](1700325152031507457). It needs to start with @, followed by the display name [demo] and the user id (1700325152031507457). If the user has access to the card - a notification will be sent.

@meltyshev commented on GitHub (Feb 2, 2026): > That's for the fix! That was one of the last pieces for building a test project that hits every end point. One last one I'm having issues with is comments. Specifically embedding/triggering a mention action from the API. Do I need to embed the HTML mention info in the comment text body? Or will an @ suffice? The mention doesn't ping when posted through the API, but it does when I go to edit it through the web client Thanks for the question :) It now works via markdown syntax - `Hello, @[demo](1700325152031507457)`. It needs to start with `@`, followed by the display name `[demo]` and the user id `(1700325152031507457)`. If the user has access to the card - a notification will be sent.
Author
Owner

@hwelch-fle commented on GitHub (Feb 2, 2026):

Thanks for the question :) It now works via markdown syntax - Hello, @[demo](1700325152031507457). It needs to start with @, followed by the display name [demo] and the user id (1700325152031507457). If the user has access to the card - a notification will be sent.

Duh. Thanks for clarifying! I'll get that patched in now

@hwelch-fle commented on GitHub (Feb 2, 2026): > Thanks for the question :) It now works via markdown syntax - `Hello, @[demo](1700325152031507457)`. It needs to start with `@`, followed by the display name `[demo]` and the user id `(1700325152031507457)`. If the user has access to the card - a notification will be sent. Duh. Thanks for clarifying! I'll get that patched in now
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/planka#909