Get history of due date changes including year

I’m retrieving task stories to perform some analysis on due date changes. In the text of the story the due date often has no year listed. Here’s an example story: “exampleuser1 changed the due date to Mar 29. Oct 9, 2017.” If this were the last due date change, I could simply use the current due date but this task has had subsequent due date changes. I investigated this example by talking to the task owner and determined that the due date was changed to Mar 29, 2019.

I haven’t found a pattern for when the year is shown or not shown, but I have confirmed that in all cases, the story text through the API matches what the user sees.

Is there any other way that I can determine the year associated with these changed due dates through the API or otherwise? I have a large number of tasks to analyze so I cannot manually investigate each one.

Thanks in advance for any recommendations or redirection!

Unfortunately there’s no way I’m aware of to get that data retroactively. @Bastien_Siebman or @lpb, do you guys have any ideas?

But I have another note of caution for you: be aware that the story data you’re retrieving is not a complete and total record of changes to the tasks. See this post for more. Because what’s mostly lost are multiple events within a 24 hour period, the missing data may be less significant for your purposes; I could be wrong but I’m thinking most updates to due dates don’t occur more than once within 24 hours. But I wanted you to be aware of the missing-data issue.

@Brooks_Hooper and @Phil_Seeman,

I don’t have any direct experience with this but I just did a couple tests in the app and then checked the API results. The way it appears to work now is:

If I change the due date to a new date within the current year, I’ll see something like this:

exampleuser1 changed the due date to Mar 29. Feb 6, 2019.

If I change the due date to a new date in a future year, I’ll see something like this:

exampleuser1 changed the due date to Mar 29, 2020. Feb 6, 2019.

That seems to be how it works now in the app, and I confirmed the API (GET /tasks/taskId/stories) returns the same text. So that would mean one could assume that, if no year is shown, the year is assumed to be the current year.

But that doesn’t jibe with what Brooks discovered from his research.

So either 1) there was a bug in the past only (because it’s not behaving that way now) that left out the year in the story text, or 2) maybe the research was mistaken?

Hope that helps!

Thank you - I was not aware of that potential for incomplete history. I would like to see that discussion. When I click the link I get a page that says:

> Sorry, you don't have access to that topic!

@Marie - I noticed in another topic that you were able to get a similar issue cleared up. Are you the right person to ask to help here as well?

Thank you @lpb,

I had similar thoughts when I first encountered this and thought I had it narrowed down to a six month window rather than current year. That was several months ago as I had to put this analysis on hold. Here’s a recent entry that shows the year being added to an entry as recently as December.

exampleuser1 changed the due date to Dec 27, 2018. Dec 20, 2018

I was also wondering if this could be caused by the method of entry but couldn’t create any instances of that.

Hmmm…I have to confess I only checked a couple dates so there was some speculation in my post; sorry!

@Joe_Trollo could you or a colleague give us the real answer!? Thanks…

Brooks, my apologies, I linked to the wrong destination. I’ve corrected the link. Let me know if you have more questions on the topic of the gaps in stories.

Sorry guys, can’y help. My natural developer instinct would be that if the year is not given, it is the current year :sweat_smile: but developers do create bugs sometimes (apparently that happens) :slight_smile:

1 Like

Hey all! We are currently working on exposing new fields on a variety of stories, and in the particular case of resource_subtype: "due_date_changed" , we’ll be attaching objects with the old and new values that look like this:

    "due_on": "2019-03-26"
    "due_at": 2019-03-26T17:00:00.000Z"
    "start_on": "2019-03-22"

Note that resource_subtype: "due_date_changed" represents the type of the story, in this case a story about changes in the due and start dates of a task. For more information about story’s subtypes please check out Joe’s recent announcement post.

Once these are launched, you’ll know the year unambiguously.

We expect to launch these within the next 2 weeks. Stay tuned!


Wow! Thank you Sasha - this sounds very promising and even easier than the parsing of stories that I’m currently doing. I will most certainly stay tuned.

With Bridge24 for Asana, you have a panel displaying task history. For each task, you can see all events, including due date changes. You can see when and who change the due date for any task. The date format includes the date and time, including year.