Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

creating new task with rest api, with checkbox attribute, error on attribute modification #2982

Open
codeistpl opened this issue Mar 19, 2021 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@codeistpl
Copy link

codeistpl commented Mar 19, 2021

My actions before raising this issue

If you will create task with REST API, and in task labels definitions you will add attribute of input type checkbox, you will not be able to set attribute value in UI.

here is a minimal reproduction.
https://gist.github.com/codeistpl/190b3866871405192975c9f81ee4eca3

Environment

cvat setup with docker-compose
Docker version 20.10.5, build 55c4c88
docker-compose version 1.28.2
Server version: 1.2
Core version: 3.10.0
Canvas version: 2.2.1
UI version: 1.13.3

hash from develop branch:
eb1cb83

Steps to Reproduce

Reproduction steps:

  1. setup cvat as in official guideline (run on localhost)
  2. add user and password to match script with bug reproduction.
  3. get reproduction script from https://gist.github.com/codeistpl/190b3866871405192975c9f81ee4eca3
  4. put some image.png into same folder script.
  5. run script, it will create task in cvat
  6. login to cvat
  7. open created task
  8. open annotation job
  9. make single annotation
  10. try to modify annotation attributes
  11. You will get - Could not update annotations Error: Trying to save an attribute attribute with id 150 and invalid value default_value

Workaround:

  1. open task
  2. click on label editor "RAW" mode (do not edit anything)
  3. click on Done
  4. now you can set attributes value.
@JVUnderground
Copy link

Same behavior is happening in my machine.

Server version: 1.2
Core version: 3.6.1
Canvas version: 2.1.0
UI version: 1.9.3

@nmanovic nmanovic added the bug Something isn't working label Mar 30, 2021
@nmanovic nmanovic added this to the Backlog milestone Mar 30, 2021
@ErikOrjehag
Copy link

Hi, I've successfully used checkboxes in the rest API in my project. But I create them like this:

{'name': 'My checkbox',
 'input_type': 'checkbox',
 'mutable': True,
 'default_value': 'false',
 'values': ['false', 'true']}

I'm on this commit e0fc323a4d649c34bcfee47f67b7efd9a54683a8

@nmanovic nmanovic removed this from the Backlog milestone Nov 24, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants