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

Field 'Activated Date' cannot be empty, even after passing ActivatedDate value in Json #884

Closed
KatteriSharath opened this issue Oct 13, 2023 · 8 comments · Fixed by #885
Closed
Assignees
Labels
bug Something isn't working

Comments

@KatteriSharath
Copy link

Describe the problem
Hi Team,
For few Jira Items, even though the ActivatedDate Field is present in the generated JSON, while and after importing to Azure it is giving the error: Invalid field status 'InvalidType' for field 'Microsoft.VSTS.Common.ActivatedDate'.

below is the Json generated after Exporting from Jira

    {
      "ReferenceName": "System.Title",
      "Value": "Title_Issue "
    },
    {
      "ReferenceName": "System.AssignedTo",
      "Value": "Masked"
    },
    {
      "ReferenceName": "Microsoft.VSTS.Common.Priority",
      "Value": "3"
    },
    {
      "ReferenceName": "Microsoft.VSTS.Common.ActivatedBy",
      "Value": "Masked"
    },
    {
      "ReferenceName": "Microsoft.VSTS.Scheduling.OriginalEstimate",
      "Value": "80"
    },
    {
      "ReferenceName": "Microsoft.VSTS.Common.ActivatedDate",
      "Value": "14/06/2023 10:06:29"
    },
    {
      "ReferenceName": "System.State",
      "Value": "Active"
    }

below is the error while importing
image

below is the error displaying in Azure board
image

@Alexander-Hjelm
Copy link
Collaborator

Debug.zip

@KatteriSharath, give this build of the WorkItem Importer a try and let me know the resuults!

@KatteriSharath
Copy link
Author

Hi @Alexander-Hjelm , Thanks for the response.
Since i do not have permission to download zip file i could not able to try the debug.
but j have referred https://github.com/solidify/jira-azuredevops-migrator/pull/885/files PR and made changes manually and tried, i am still getting the same issue.

@Alexander-Hjelm
Copy link
Collaborator

Alexander-Hjelm commented Oct 15, 2023

@KatteriSharath Ok!

It looks like ActivatedDate field on your exported work item is on the wrong format. The value is 14/06/2023 10:06:29 when it should be on a format like 2023-06-14T10:06:29.635+00:00.

Could you try and edit the value for Microsoft.VSTS.Common.ActivatedDate to the correct format in your exported config, just to see if that fixes the error or not? Get back to me with the results.

If so, let me have a look and see if maybe the tool is missing a conversion somewhere.

@Alexander-Hjelm
Copy link
Collaborator

@KatteriSharath Furthermore, which time zone are you in?

@KatteriSharath
Copy link
Author

@Alexander-Hjelm i am in BST time zone (UK)

@KatteriSharath
Copy link
Author

Additionally, I conducted testing on approximately 300 work items, with only 5 of them exhibiting this error. Moreover, I have just attempted this for another work item, and the activation date is as follows:

"ReferenceName": "Microsoft.VSTS.Common.ActivatedDate",
"Value": "11/09/2023 10:55:37"

This item was successfully imported into Azure without encountering any errors.

@wallymathieu
Copy link
Contributor

wallymathieu commented Oct 16, 2023

When using a process that uses "Resolved" there is also "Resolved Date" not being set for resolved issues.

Could it be that you need similar logic as

private void CorrectClosedByAndClosedDate(WiRevision rev, WorkItem wi)

For activated and resolved as well?

It seems like only the initial values are set for activated date
https://github.com/solidify/jira-azuredevops-migrator/blob/cac9794a898f8c4be77eea9ca353b3fb0757627d/src/WorkItemMigrator/WorkItemImport/WitClient/WitClientUtils.cs#L690C1-L700
And no values are set for resolved date

@KatteriSharath
Copy link
Author

Thanks for Response @wallymathieu ,
from the below screen shot, i am passing the Resolved date, can you please let me know if it is as expected?

image

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
3 participants