Skip to content

Commit b72ce3a

Browse files
committed
chore: add migration guide for breaking change to get_ancestors
1 parent 10a0dcd commit b72ce3a

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

docs/reference/migrations.rst

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,28 @@ Migration Guide
33

44
This page can help when migrating Taskgraph across major versions.
55

6+
12.x -> 13.x
7+
------------
8+
9+
* Invert any usage of the dict keys and values returned by `get_ancestors`:
10+
11+
For example, if you were using:
12+
13+
.. code-block:: python
14+
15+
for label, taskid in get_ancestors(...):
16+
...
17+
18+
Change it to:
19+
20+
.. code-block:: python
21+
22+
for taskid, label in get_ancestors(...):
23+
...
24+
25+
Note that due to this change `get_ancestors` may return multiple tasks with
26+
the same label now, which your code may need to deal with.
27+
628
11.x -> 12.x
729
------------
830

0 commit comments

Comments
 (0)