Error when importing project with iteration cadence
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
Group/project structure
Group (ultimate)
|- Cadence
|- Iteration --|
|- Project |
|- Issue ------|
Importing project into same group
- Export the project.
- Re-import the project into the same group.
Outcome: project imports, and issue is connected to the correct iteration. Error in logs from attempting to create new iteration cadence:
{
"feature_category": "importers",
"severity": "WARN",
"time": "2024-08-28T13:02:39.008Z",
"correlation_id": "01J6CH9CWHV37B672AWNT4E4YS",
"meta.caller_id": "RepositoryImportWorker",
"meta.remote_ip": "127.0.0.1",
"meta.feature_category": "importers",
"meta.user": "root",
"meta.user_id": 1,
"meta.project": "cadence-test/cadence-import-2",
"meta.root_namespace": "cadence-test",
"meta.client_id": "user/1",
"meta.root_caller_id": "Import::GitlabProjectsController#create",
"message": "[Project/Group Import] Invalid object relation built",
"relation_key": "iterations_cadence",
"relation_index": 0,
"relation_class": "Iterations::Cadence",
"error_messages": "Start date can't be blank. Group can't be blank. Duration in weeks can't be blank. Iterations in advance can't be blank"
}
Importing project into new ultimate group
Outcome: Same error in logs, no iteration or cadence created at group level.
{
"feature_category": "importers",
"severity": "WARN",
"time": "2024-08-28T13:56:14.134Z",
"correlation_id": "01J6CMBGSH64HKMQCXB7ESDM01",
"meta.caller_id": "RepositoryImportWorker",
"meta.remote_ip": "127.0.0.1",
"meta.feature_category": "importers",
"meta.user": "root",
"meta.user_id": 1,
"meta.project": "cadence-import-2/group-with-no-iteration",
"meta.root_namespace": "cadence-import-2",
"meta.client_id": "user/1",
"meta.root_caller_id": "Import::GitlabProjectsController#create",
"message": "[Project/Group Import] Invalid object relation built",
"relation_key": "iterations_cadence",
"relation_index": 0,
"relation_class": "Iterations::Cadence",
"error_messages": "Start date can't be blank. Group can't be blank. Duration in weeks can't be blank. Iterations in advance can't be blank"
}
Suspected factors
- An iteration cadence must belong to a group. If importing iteration cadences should be supported, we need to either connect them to the group into which the project is being imported, or some parent group.
- If a project is being imported into the group it came from, the iteration may not need to be re-created.
-
start_date,duration_in_weeksanditerations_in_advanceare only validated ifautomaticis set to true.automaticisn't in the exported fields, but defaults totrue, so no cadences without these values are importable.
Workaround
Manually create an iteration cadence on the destination group with the expected name.
Edited by Thiago Figueiró