Skip to content

Commit a50007b

Browse files
committed
docs: Do not register category fragments
This is causing a name collision on category names when building header links in the documentation. The "category" names are being registered in get_fragment even though the header patterns for Events and Requests are: * `## {} Events` * `## {} Requests` As a result, when processing Requests, the shared categories between Events and Requests, such as "General" and "Config", end up with "deduplicated" names for the header links such as: * general-1-requests * config-1-requests This results in broken links in the Requests Table of Contents. Since the categories themselves are not used to build links anywhere, we can set the register param in those get_fragment(category) calls to False and only register the requestType and eventType fragments.
1 parent 04be16d commit a50007b

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎docs/docs/generate_md.py‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ def get_requests(requests):
162162
requestsOut.append(request)
163163
if not len(requestsOut):
164164
continue
165-
categoryFragment = get_fragment(category)
165+
categoryFragment = get_fragment(category, False)
166166
ret += '## {} Requests\n\n'.format(category)
167167
for request in requestsOut:
168168
requestType = request['requestType']
@@ -227,7 +227,7 @@ def get_events(events):
227227
eventsOut.append(event)
228228
if not len(eventsOut):
229229
continue
230-
categoryFragment = get_fragment(category)
230+
categoryFragment = get_fragment(category, False)
231231
ret += '## {} Events\n\n'.format(category)
232232
for event in eventsOut:
233233
eventType = event['eventType']

0 commit comments

Comments
 (0)