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

If a label has 2+ attributes, one of which 'expression', they will fail to update #2927

Open
2 tasks done
zhiltsov-max opened this issue Mar 9, 2021 · 3 comments · May be fixed by #7889
Open
2 tasks done

If a label has 2+ attributes, one of which 'expression', they will fail to update #2927

zhiltsov-max opened this issue Mar 9, 2021 · 3 comments · May be fixed by #7889
Labels
bug Something isn't working good first issue Good for newcomers

Comments

@zhiltsov-max
Copy link
Contributor

zhiltsov-max commented Mar 9, 2021

My actions before raising this issue

Expected Behaviour

Attribute values are changed, no errors.

Current Behaviour

If a label has 2+ attributes, one of which 'expression', they will fail to update on attempt of changing any attribute value of an annotation object.
Looks like the problem is with an attribute expression. But if there is only this attribute, no problems. Attribute order in a label does not seem to have any impact.

Possible Solution

Steps to Reproduce (for bugs)

  1. Having a label with this configuration:
    image

Not this one:
image

But this one:
image

Will produce these errors on attempt to change any attribute value of an annotation object:
image

image

OK:
image

Fail:
image

Context

Your Environment

  • Git hash commit (git log -1): 0533050 (should be compatible with 7a2dcff)
  • Docker version docker version (e.g. Docker 17.0.05):
  • Are you using Docker Swarm or Kubernetes?
  • Operating System and version (e.g. Linux, Windows, MacOS):
  • Code example or link to GitHub repo or gist to reproduce problem:
  • Other diagnostic information / logs:
    Logs from `cvat` container

Next steps

You may join our Gitter channel for community support.

@zhiltsov-max zhiltsov-max added the bug Something isn't working label Mar 9, 2021
@nmanovic nmanovic added this to To do in UI via automation Mar 9, 2021
@nmanovic nmanovic added this to the Backlog milestone Mar 9, 2021
@bsekachev bsekachev self-assigned this Jun 9, 2021
@nmanovic nmanovic removed this from the Backlog milestone Nov 24, 2021
bsekachev added a commit that referenced this issue Jul 19, 2023
…editor (#6474)

<!-- Raise an issue to propose your change
(https://github.com/opencv/cvat/issues).
It helps to avoid duplication of efforts from multiple independent
contributors.
Discuss your ideas with maintainers to be sure that changes will be
approved and merged.
Read the [Contribution
guide](https://opencv.github.io/cvat/docs/contributing/). -->

<!-- Provide a general summary of your changes in the Title above -->

### Motivation and context
Resolved #6415
Related #3113 (need to fix server part and probably throw code 400, not
500)
Related #2927 (need to fix server)


![image](https://github.com/opencv/cvat/assets/40690378/016f9def-bd5f-4dcf-9a00-c6b75b0dd50f)


### How has this been tested?
<!-- Please describe in detail how you tested your changes.
Include details of your testing environment, and the tests you ran to
see how your change affects other areas of the code, etc. -->

### Checklist
<!-- Go over all the following points, and put an `x` in all the boxes
that apply.
If an item isn't applicable for some reason, then ~~explicitly
strikethrough~~ the whole
line. If you don't do that, GitHub will show incorrect progress for the
pull request.
If you're unsure about any of these, don't hesitate to ask. We're here
to help! -->
- [x] I submit my changes into the `develop` branch
- [x] I have added a description of my changes into the
[CHANGELOG](https://github.com/opencv/cvat/blob/develop/CHANGELOG.md)
file
- [ ] I have updated the documentation accordingly
- [ ] I have added tests to cover my changes
- [x] I have linked related issues (see [GitHub docs](

https://help.github.com/en/github/managing-your-work-on-github/linking-a-pull-request-to-an-issue#linking-a-pull-request-to-an-issue-using-a-keyword))
- [x] I have increased versions of npm packages if it is necessary

([cvat-canvas](https://github.com/opencv/cvat/tree/develop/cvat-canvas#versioning),

[cvat-core](https://github.com/opencv/cvat/tree/develop/cvat-core#versioning),

[cvat-data](https://github.com/opencv/cvat/tree/develop/cvat-data#versioning)
and

[cvat-ui](https://github.com/opencv/cvat/tree/develop/cvat-ui#versioning))

### License

- [x] I submit _my code changes_ under the same [MIT License](
https://github.com/opencv/cvat/blob/develop/LICENSE) that covers the
project.
  Feel free to contact the maintainers if that's a concern.
@bsekachev bsekachev added this to To do in Server and REST API via automation Jul 19, 2023
@bsekachev bsekachev removed their assignment Jul 19, 2023
@bsekachev
Copy link
Member

Empty value is not valid for a checkbox, client was fixed, but probably we also need to fix a server to check default_attribute value is valid for a corresponding attribute type.

mikhail-treskin pushed a commit to retailnext/cvat that referenced this issue Oct 25, 2023
…editor (cvat-ai#6474)

<!-- Raise an issue to propose your change
(https://github.com/opencv/cvat/issues).
It helps to avoid duplication of efforts from multiple independent
contributors.
Discuss your ideas with maintainers to be sure that changes will be
approved and merged.
Read the [Contribution
guide](https://opencv.github.io/cvat/docs/contributing/). -->

<!-- Provide a general summary of your changes in the Title above -->

### Motivation and context
Resolved cvat-ai#6415
Related cvat-ai#3113 (need to fix server part and probably throw code 400, not
500)
Related cvat-ai#2927 (need to fix server)


![image](https://github.com/opencv/cvat/assets/40690378/016f9def-bd5f-4dcf-9a00-c6b75b0dd50f)


### How has this been tested?
<!-- Please describe in detail how you tested your changes.
Include details of your testing environment, and the tests you ran to
see how your change affects other areas of the code, etc. -->

### Checklist
<!-- Go over all the following points, and put an `x` in all the boxes
that apply.
If an item isn't applicable for some reason, then ~~explicitly
strikethrough~~ the whole
line. If you don't do that, GitHub will show incorrect progress for the
pull request.
If you're unsure about any of these, don't hesitate to ask. We're here
to help! -->
- [x] I submit my changes into the `develop` branch
- [x] I have added a description of my changes into the
[CHANGELOG](https://github.com/opencv/cvat/blob/develop/CHANGELOG.md)
file
- [ ] I have updated the documentation accordingly
- [ ] I have added tests to cover my changes
- [x] I have linked related issues (see [GitHub docs](

https://help.github.com/en/github/managing-your-work-on-github/linking-a-pull-request-to-an-issue#linking-a-pull-request-to-an-issue-using-a-keyword))
- [x] I have increased versions of npm packages if it is necessary

([cvat-canvas](https://github.com/opencv/cvat/tree/develop/cvat-canvas#versioning),

[cvat-core](https://github.com/opencv/cvat/tree/develop/cvat-core#versioning),

[cvat-data](https://github.com/opencv/cvat/tree/develop/cvat-data#versioning)
and

[cvat-ui](https://github.com/opencv/cvat/tree/develop/cvat-ui#versioning))

### License

- [x] I submit _my code changes_ under the same [MIT License](
https://github.com/opencv/cvat/blob/develop/LICENSE) that covers the
project.
  Feel free to contact the maintainers if that's a concern.
@bsekachev bsekachev added the good first issue Good for newcomers label Mar 11, 2024
@KrishavRajSingh
Copy link
Contributor

Empty value is not valid for a checkbox, client was fixed, but probably we also need to fix a server to check default_attribute value is valid for a corresponding attribute type.

So we need to check if Checkbox is selected, it should be either true or false on the server side.Right??

@bsekachev
Copy link
Member

@KrishavRajSingh

Yep.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers
Projects
UI
To do
Development

Successfully merging a pull request may close this issue.

4 participants