Skip to content

client.tasks.findAll deprecation #272

@dwelch2344

Description

@dwelch2344

Following along with the example on the README and noticed I'm getting a deprecation warning.

  const workspaces = await client.workspaces.findAll()
  const ws = workspaces.data.find(el => el.name === 'Example Team')

  const me = await client.users.me()

  const tasks = await client.tasks.findAll({
    assignee: parseInt(me.gid),
    workspace: ws.gid,
    opt_fields: 'id,name,assignee_status,completed'
  })
  console.log(tasks)

Produces the warning:

    This request is affected by the "new_user_task_lists" deprecation. Please visit this url for more info: https://forum.asana.com/t/update-on-our-planned-api-changes-to-user-task-lists-a-k-a-my-tasks/103828
  Adding "new_user_task_lists" to your "Asana-Enable" or "Asana-Disable" header will opt in/out to this deprecation and suppress this warning.

Looks like its been a few years since the change was announced, but I'd imagine the library should have a way to adapt (or comment about ignoring/disabling warning)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions