Skip to content

Commit 56d622b

Browse files
committed
Changed the generation of the 1id-index.txt file to not list individual drafts in states Candidate for WG Adoption and Call for WG Adoption Issued as group drafts.
- Legacy-Id: 15612
1 parent b415d8c commit 56d622b

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

ietf/idindex/index.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -221,6 +221,9 @@ def active_drafts_index_by_group(extra_values=()):
221221
# this returns a lot of data so try to be efficient
222222

223223
active_state = State.objects.get(type="draft", slug="active")
224+
wg_cand = State.objects.get(type="draft-stream-ietf", slug="wg-cand")
225+
wg_adopt = State.objects.get(type="draft-stream-ietf", slug="c-adopt")
226+
individual = Group.objects.get(acronym='none')
224227

225228
groups_dict = dict((g.id, g) for g in Group.objects.all())
226229

@@ -229,6 +232,10 @@ def active_drafts_index_by_group(extra_values=()):
229232
docs_dict = dict((d["name"], d)
230233
for d in Document.objects.filter(states=active_state).values(*extracted_values))
231234

235+
# Special case for drafts with group set, but in state wg_cand:
236+
for d in Document.objects.filter(states=active_state).filter(states__in=[wg_cand, wg_adopt]):
237+
docs_dict[d.name]['group_id'] = individual.id
238+
232239
# add initial and latest revision time
233240
for time, doc_id in NewRevisionDocEvent.objects.filter(type="new_revision", doc__states=active_state).order_by('-time').values_list("time", "doc_id"):
234241
d = docs_dict.get(doc_id)

0 commit comments

Comments
 (0)