DependencyTrack / DependencyTrack/dependency-track

POST /v1/project auto-creates a tag but other endpoints require tags to exist

Open
#5,194 0 comments 0 reactions 0 assignees View on GitHub
defect in triage
Dominant language
Java
Stars
4.2k
Forks
811
Avg merge
8h 39m
Merged PRs (30d)
237

Description

### Current Behavior

I can update a project with tags that don't exist in the system and the tags will be created.

If I try to add tags to a project via `v1/tag/$tag_name/project` and the tag does not exist I get an error:
```
{"status":404,"title":"Resource does not exist","detail":"A tag with name newtag does not exist"}
```

I didn't check it but I expect similar behavior for other `v1/tag` endpoints

### Expected Behavior

Missing tags are automatically created by all endpoints.

### Dependency-Track Version

4.13.2

### Dependency-Track Distribution

Container Image

### Database Server

N/A

### Database Server Version

_No response_

### Browser

N/A

### Checklist

- [x] I have read and understand the [contributing guidelines](https://github.com/DependencyTrack/dependency-track/blob/master/CONTRIBUTING.md#filing-issues)
- [x] I have checked the [existing issues](https://github.com/DependencyTrack/dependency-track/issues) for whether this defect was already reported

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.