Closed mbarton closed 1 month ago
Commenting out that line leads to it hanging running the tests (which used to happen regularly before adding the docs build step):
https://github.com/rcpch/rcpch-audit-engine/actions/runs/11122510093/job/30904036148
You get 16GB of RAM on the default GitHub action runners and 14GB of disk. So I doubt it's memory pressure ~but wouldn't rule it out~
Running the command locally uses only 200MB of memory.
I tried bumping the versions of all the mkdocs libraries and amusingly that is causing mkdocs to hang locally for me, spinning on 100% CPU.
I would guess in CI then perhaps it's bringing in a new enough version of mkdocs
for the issue to happen but because I already had a docker build locally perhaps it was using an older version that didn't have the issue?
pystack shows some regex matching is taking up all the time:
Traceback for thread 1 (mkdocs) [Has the GIL] (most recent call last):
(Python) File "/usr/local/bin/mkdocs", line 8, in <module>
sys.exit(cli())
(Python) File "/usr/local/lib/python3.11/site-packages/click/core.py", line 1157, in __call__
return self.main(*args, **kwargs)
(Python) File "/usr/local/lib/python3.11/site-packages/click/core.py", line 1078, in main
rv = self.invoke(ctx)
(Python) File "/usr/local/lib/python3.11/site-packages/click/core.py", line 1688, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
(Python) File "/usr/local/lib/python3.11/site-packages/click/core.py", line 1434, in invoke
return ctx.invoke(self.callback, **ctx.params)
(Python) File "/usr/local/lib/python3.11/site-packages/click/core.py", line 783, in invoke
return __callback(*args, **kwargs)
(Python) File "/usr/local/lib/python3.11/site-packages/mkdocs/__main__.py", line 288, in build_command
build.build(cfg, dirty=not clean)
(Python) File "/usr/local/lib/python3.11/site-packages/mkdocs/commands/build.py", line 310, in build
_populate_page(file.page, config, files, dirty)
(Python) File "/usr/local/lib/python3.11/site-packages/mkdocs/commands/build.py", line 167, in _populate_page
page.render(config, files)
(Python) File "/usr/local/lib/python3.11/site-packages/mkdocs/structure/pages.py", line 285, in render
self.content = md.convert(self.markdown)
(Python) File "/usr/local/lib/python3.11/site-packages/markdown/core.py", line 354, in convert
self.lines = prep.run(self.lines)
(Python) File "/usr/local/lib/python3.11/site-packages/pymdownx/superfences.py", line 888, in run
return self.search_nested(lines)
(Python) File "/usr/local/lib/python3.11/site-packages/pymdownx/superfences.py", line 682, in search_nested
m = RE_NESTED_FENCE_START.match(line, self.ws_len)
Poor Mans Profiler confirms this, including the string it's matching:
"```number_of_completed_fields_in_related_models``` performs this same process for all fields in related models. For example, a single multiaxial description of a child's epilepsy comprises multiple episodes, all of which are different."
Thread 1 (Thread 0x7fae7f812b80 (LWP 1) "mkdocs"):
#0 0x00007fae7fd0d601 in sre_ucs1_match (state=<optimized out>, pattern=0x571498b8ae40, toplevel=<optimized out>) at ./Modules/_sre/sre_lib.h:868
#1 0x00007fae7fd6cb0a in _sre_SRE_Pattern_match_impl (endpos=9223372036854775807, pos=0, string="```number_of_completed_fields_in_related_models``` performs this same process for all fields in related models. For example, a single multiaxial description of a child's epilepsy comprises multiple episodes, all of which are different.", cls=<optimized out>, self=0x571498b8aba0) at ./Modules/_sre/sre.c:659
#2 _sre_SRE_Pattern_match (self=0x571498b8aba0, cls=<optimized out>, args=<optimized out>, nargs=<optimized out>, kwnames=<optimized out>) at ./Modules/_sre/clinic/sre.c.h:224
#3 0x00007fae7fd0d209 in method_vectorcall_FASTCALL_KEYWORDS_METHOD (func=<method_descriptor at remote 0x7fae7f621760>, args=0x7fae7f655930, nargsf=<optimized out>, kwnames=<optimized out>) at Objects/descrobject.c:386
#4 0x00007fae7fce45b3 in _PyObject_VectorcallTstate (kwnames=<optimized out>, nargsf=<optimized out>, args=<optimized out>, callable=<method_descriptor at remote 0x7fae7f621760>, tstate=0x7fae7ffc2658 <_PyRuntime+166328>) at ./Include/internal/pycore_call.h:92
#5 PyObject_Vectorcall (callable=<method_descriptor at remote 0x7fae7f621760>, args=<optimized out>, nargsf=<optimized out>, kwnames=<optimized out>) at Objects/call.c:299
#6 0x00007fae7fcd975b in _PyEval_EvalFrameDefault (tstate=<optimized out>, frame=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:4769
#7 0x00007fae7fcd82ea in _PyEval_EvalFrame (throwflag=0, frame=0x7fae7f655410, tstate=0x7fae7ffc2658 <_PyRuntime+166328>) at ./Include/internal/pycore_ceval.h:73
#8 _PyEval_Vector (tstate=0x7fae7ffc2658 <_PyRuntime+166328>, func=<optimized out>, locals=<optimized out>, args=<optimized out>, argcount=<optimized out>, kwnames=<optimized out>) at Python/ceval.c:6434
#9 0x00007fae7fcf5b36 in _PyVectorcall_Call (tstate=0x7fae7ffc2658 <_PyRuntime+166328>, func=0x7fae7fcf2930 <_PyFunction_Vectorcall>, callable=<function at remote 0x7fae7ee0a3e0>, tuple=<optimized out>, kwargs=<optimized out>) at Objects/call.c:257
#10 0x00007fae7fcdb8d0 in _PyEval_EvalFrameDefault (tstate=<optimized out>, frame=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:5376
#11 0x00007fae7fcd82ea in _PyEval_EvalFrame (throwflag=0, frame=0x7fae7f655358, tstate=0x7fae7ffc2658 <_PyRuntime+166328>) at ./Include/internal/pycore_ceval.h:73
#12 _PyEval_Vector (tstate=0x7fae7ffc2658 <_PyRuntime+166328>, func=func@entry=0x7fae7f234360, locals=locals@entry=0x0, args=args@entry=0x7fae7f3c39b0, argcount=<optimized out>, kwnames=kwnames@entry=<unknown at remote 0x7fae7f3c3ab0>) at Python/ceval.c:6434
#13 0x00007fae7fd01a4d in _PyFunction_Vectorcall (kwnames=<unknown at remote 0x7fae7f3c3ab0>, nargsf=<optimized out>, stack=0x7fae7f3c39b0, func=<function at remote 0x7fae7f234360>) at Objects/call.c:393
#14 _PyObject_VectorcallTstate (kwnames=<unknown at remote 0x7fae7f3c3ab0>, nargsf=<optimized out>, args=0x7fae7f3c39b0, callable=<function at remote 0x7fae7f234360>, tstate=0x7fae7ffc2658 <_PyRuntime+166328>) at ./Include/internal/pycore_call.h:92
#15 method_vectorcall (method=method@entry=<method at remote 0x7fae7f591bc0>, args=args@entry=0x7fae7f3c39b8, nargsf=<optimized out>, kwnames=kwnames@entry=('config_file', 'clean', 'strict', 'theme', 'use_directory_urls', 'site_dir')) at Objects/classobject.c:59
#16 0x00007fae7fcf5b36 in _PyVectorcall_Call (tstate=0x7fae7ffc2658 <_PyRuntime+166328>, func=0x7fae7fd01990 <method_vectorcall>, callable=<method at remote 0x7fae7f591bc0>, tuple=<optimized out>, kwargs=<optimized out>) at Objects/call.c:257
#17 0x00007fae7fcdb8d0 in _PyEval_EvalFrameDefault (tstate=<optimized out>, frame=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:5376
#18 0x00007fae7fcd82ea in _PyEval_EvalFrame (throwflag=0, frame=0x7fae7f655120, tstate=0x7fae7ffc2658 <_PyRuntime+166328>) at ./Include/internal/pycore_ceval.h:73
#19 _PyEval_Vector (tstate=0x7fae7ffc2658 <_PyRuntime+166328>, func=func@entry=0x7fae7f1e8720, locals=locals@entry=0x0, args=args@entry=0x7ffc387c0508, argcount=argcount@entry=1, kwnames=kwnames@entry=0x0) at Python/ceval.c:6434
#20 0x00007fae7fd01afd in _PyFunction_Vectorcall (kwnames=0x0, nargsf=1, stack=0x7ffc387c0508, func=<function at remote 0x7fae7f1e8720>) at Objects/call.c:393
#21 _PyObject_VectorcallTstate (kwnames=0x0, nargsf=1, args=0x7ffc387c0508, callable=<function at remote 0x7fae7f1e8720>, tstate=0x7fae7ffc2658 <_PyRuntime+166328>) at ./Include/internal/pycore_call.h:92
#22 method_vectorcall (method=<optimized out>, args=0x7fae7ffa82d0 <_PyRuntime+58928>, nargsf=<optimized out>, kwnames=<optimized out>) at Objects/classobject.c:67
#23 0x00007fae7fcdb8d0 in _PyEval_EvalFrameDefault (tstate=<optimized out>, frame=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:5376
#24 0x00007fae7fcd82ea in _PyEval_EvalFrame (throwflag=0, frame=0x7fae7f655098, tstate=0x7fae7ffc2658 <_PyRuntime+166328>) at ./Include/internal/pycore_ceval.h:73
#25 _PyEval_Vector (tstate=0x7fae7ffc2658 <_PyRuntime+166328>, func=func@entry=0x7fae7f1e8860, locals=locals@entry=0x0, args=<optimized out>, argcount=argcount@entry=1, kwnames=kwnames@entry=0x0) at Python/ceval.c:6434
#26 0x00007fae7fcd37fb in _PyFunction_Vectorcall (kwnames=0x0, nargsf=<optimized out>, stack=<optimized out>, func=<function at remote 0x7fae7f1e8860>) at Objects/call.c:393
#27 _PyObject_FastCallDictTstate (tstate=0x7fae7ffc2658 <_PyRuntime+166328>, callable=<function at remote 0x7fae7f1e8860>, args=<optimized out>, nargsf=<optimized out>, kwargs=<optimized out>) at Objects/call.c:141
#28 0x00007fae7fcf50c4 in _PyObject_Call_Prepend (tstate=0x7fae7ffc2658 <_PyRuntime+166328>, callable=<function at remote 0x7fae7f1e8860>, obj=<optimized out>, args=(), kwargs=<optimized out>) at Objects/call.c:482
#29 0x00007fae7fd6d68e in slot_tp_call (self=<Group(name='cli', context_settings={'help_option_names': ['-h', '--help'], 'max_content_width': 120}, callback=<function at remote 0x7fae7ee0a0c0>, params=[<Option(name='version', opts=['-V', '--version'], secondary_opts=[], type=<BoolParamType() at remote 0x7fae7f226550>, required=False, callback=<function at remote 0x7fae7ee09f80>, nargs=1, multiple=False, expose_value=False, default=False, is_eager=True, metavar=None, envvar=None, _custom_shell_complete=None, prompt=None, confirmation_prompt=False, prompt_required=True, hide_input=False, hidden=False, _flag_needs_value=False, is_flag=True, is_bool_flag=True, flag_value=True, count=False, allow_from_autoenv=True, help='Show the version and exit.', show_default=None, show_choices=True, show_envvar=False) at remote 0x7fae7ede4c90>, <Option(name='quiet', opts=['-q', '--quiet'], secondary_opts=[], type=<...>, required=False, callback=<function at remote 0x7fae7ee0a2a0>, nargs=1, multiple=False, expose_value=False, default=False, is_eager=False, metavar=None, e...(truncated), args=(), kwds=0x0) at Objects/typeobject.c:7624
#30 0x00007fae7fcd23ff in _PyObject_MakeTpCall (tstate=0x7fae7ffc2658 <_PyRuntime+166328>, callable=<Group(name='cli', context_settings={'help_option_names': ['-h', '--help'], 'max_content_width': 120}, callback=<function at remote 0x7fae7ee0a0c0>, params=[<Option(name='version', opts=['-V', '--version'], secondary_opts=[], type=<BoolParamType() at remote 0x7fae7f226550>, required=False, callback=<function at remote 0x7fae7ee09f80>, nargs=1, multiple=False, expose_value=False, default=False, is_eager=True, metavar=None, envvar=None, _custom_shell_complete=None, prompt=None, confirmation_prompt=False, prompt_required=True, hide_input=False, hidden=False, _flag_needs_value=False, is_flag=True, is_bool_flag=True, flag_value=True, count=False, allow_from_autoenv=True, help='Show the version and exit.', show_default=None, show_choices=True, show_envvar=False) at remote 0x7fae7ede4c90>, <Option(name='quiet', opts=['-q', '--quiet'], secondary_opts=[], type=<...>, required=False, callback=<function at remote 0x7fae7ee0a2a0>, nargs=1, multiple=False, expose_value=False, default=False, is_eager=False, metavar=None, e...(truncated), args=<optimized out>, nargs=0, keywords=<optimized out>) at Objects/call.c:214
#31 0x00007fae7fcd975b in _PyEval_EvalFrameDefault (tstate=<optimized out>, frame=<optimized out>, throwflag=<optimized out>) at Python/ceval.c:4769
#32 0x00007fae7fcd82ea in _PyEval_EvalFrame (throwflag=0, frame=0x7fae7f655020, tstate=0x7fae7ffc2658 <_PyRuntime+166328>) at ./Include/internal/pycore_ceval.h:73
#33 _PyEval_Vector (tstate=tstate@entry=0x7fae7ffc2658 <_PyRuntime+166328>, func=func@entry=0x7fae7f78a520, locals=locals@entry={'__name__': '__main__', '__doc__': None, '__package__': None, '__loader__': <SourceFileLoader(name='__main__', path='/usr/local/bin/mkdocs') at remote 0x7fae7f575810>, '__spec__': None, '__annotations__': {}, '__builtins__': <module at remote 0x7fae7f744a90>, '__file__': '/usr/local/bin/mkdocs', '__cached__': None, 're': <module at remote 0x7fae7f5ac630>, 'sys': <module at remote 0x7fae7f736ca0>, 'cli': <Group(name='cli', context_settings={'help_option_names': ['-h', '--help'], 'max_content_width': 120}, callback=<function at remote 0x7fae7ee0a0c0>, params=[<Option(name='version', opts=['-V', '--version'], secondary_opts=[], type=<BoolParamType() at remote 0x7fae7f226550>, required=False, callback=<function at remote 0x7fae7ee09f80>, nargs=1, multiple=False, expose_value=False, default=False, is_eager=True, metavar=None, envvar=None, _custom_shell_complete=None, prompt=None, confirmation_prompt=False, prompt_required=True, hide_input=False, hidden=False, _flag_needs_value=False, is_flag=True, is_bool_flag=Tr...(truncated), args=args@entry=0x0, argcount=argcount@entry=0, kwnames=kwnames@entry=0x0) at Python/ceval.c:6434
#34 0x00007fae7fd25fe8 in PyEval_EvalCode (co=<code at remote 0x7fae7f700310>, globals=<optimized out>, locals={'__name__': '__main__', '__doc__': None, '__package__': None, '__loader__': <SourceFileLoader(name='__main__', path='/usr/local/bin/mkdocs') at remote 0x7fae7f575810>, '__spec__': None, '__annotations__': {}, '__builtins__': <module at remote 0x7fae7f744a90>, '__file__': '/usr/local/bin/mkdocs', '__cached__': None, 're': <module at remote 0x7fae7f5ac630>, 'sys': <module at remote 0x7fae7f736ca0>, 'cli': <Group(name='cli', context_settings={'help_option_names': ['-h', '--help'], 'max_content_width': 120}, callback=<function at remote 0x7fae7ee0a0c0>, params=[<Option(name='version', opts=['-V', '--version'], secondary_opts=[], type=<BoolParamType() at remote 0x7fae7f226550>, required=False, callback=<function at remote 0x7fae7ee09f80>, nargs=1, multiple=False, expose_value=False, default=False, is_eager=True, metavar=None, envvar=None, _custom_shell_complete=None, prompt=None, confirmation_prompt=False, prompt_required=True, hide_input=False, hidden=False, _flag_needs_value=False, is_flag=True, is_bool_flag=Tr...(truncated)) at Python/ceval.c:1148
#35 0x00007fae7fd555e3 in run_eval_code_obj (tstate=tstate@entry=0x7fae7ffc2658 <_PyRuntime+166328>, co=co@entry=0x7fae7f700310, globals=globals@entry={'__name__': '__main__', '__doc__': None, '__package__': None, '__loader__': <SourceFileLoader(name='__main__', path='/usr/local/bin/mkdocs') at remote 0x7fae7f575810>, '__spec__': None, '__annotations__': {}, '__builtins__': <module at remote 0x7fae7f744a90>, '__file__': '/usr/local/bin/mkdocs', '__cached__': None, 're': <module at remote 0x7fae7f5ac630>, 'sys': <module at remote 0x7fae7f736ca0>, 'cli': <Group(name='cli', context_settings={'help_option_names': ['-h', '--help'], 'max_content_width': 120}, callback=<function at remote 0x7fae7ee0a0c0>, params=[<Option(name='version', opts=['-V', '--version'], secondary_opts=[], type=<BoolParamType() at remote 0x7fae7f226550>, required=False, callback=<function at remote 0x7fae7ee09f80>, nargs=1, multiple=False, expose_value=False, default=False, is_eager=True, metavar=None, envvar=None, _custom_shell_complete=None, prompt=None, confirmation_prompt=False, prompt_required=True, hide_input=False, hidden=False, _flag_needs_value=False, is_flag=True, is_bool_flag=Tr...(truncated), locals=locals@entry={'__name__': '__main__', '__doc__': None, '__package__': None, '__loader__': <SourceFileLoader(name='__main__', path='/usr/local/bin/mkdocs') at remote 0x7fae7f575810>, '__spec__': None, '__annotations__': {}, '__builtins__': <module at remote 0x7fae7f744a90>, '__file__': '/usr/local/bin/mkdocs', '__cached__': None, 're': <module at remote 0x7fae7f5ac630>, 'sys': <module at remote 0x7fae7f736ca0>, 'cli': <Group(name='cli', context_settings={'help_option_names': ['-h', '--help'], 'max_content_width': 120}, callback=<function at remote 0x7fae7ee0a0c0>, params=[<Option(name='version', opts=['-V', '--version'], secondary_opts=[], type=<BoolParamType() at remote 0x7fae7f226550>, required=False, callback=<function at remote 0x7fae7ee09f80>, nargs=1, multiple=False, expose_value=False, default=False, is_eager=True, metavar=None, envvar=None, _custom_shell_complete=None, prompt=None, confirmation_prompt=False, prompt_required=True, hide_input=False, hidden=False, _flag_needs_value=False, is_flag=True, is_bool_flag=Tr...(truncated)) at Python/pythonrun.c:1741
#36 0x00007fae7fd5557a in run_mod (mod=mod@entry=0x5714988cb630, filename=filename@entry='/usr/local/bin/mkdocs', globals=globals@entry={'__name__': '__main__', '__doc__': None, '__package__': None, '__loader__': <SourceFileLoader(name='__main__', path='/usr/local/bin/mkdocs') at remote 0x7fae7f575810>, '__spec__': None, '__annotations__': {}, '__builtins__': <module at remote 0x7fae7f744a90>, '__file__': '/usr/local/bin/mkdocs', '__cached__': None, 're': <module at remote 0x7fae7f5ac630>, 'sys': <module at remote 0x7fae7f736ca0>, 'cli': <Group(name='cli', context_settings={'help_option_names': ['-h', '--help'], 'max_content_width': 120}, callback=<function at remote 0x7fae7ee0a0c0>, params=[<Option(name='version', opts=['-V', '--version'], secondary_opts=[], type=<BoolParamType() at remote 0x7fae7f226550>, required=False, callback=<function at remote 0x7fae7ee09f80>, nargs=1, multiple=False, expose_value=False, default=False, is_eager=True, metavar=None, envvar=None, _custom_shell_complete=None, prompt=None, confirmation_prompt=False, prompt_required=True, hide_input=False, hidden=False, _flag_needs_value=False, is_flag=True, is_bool_flag=Tr...(truncated), locals=locals@entry={'__name__': '__main__', '__doc__': None, '__package__': None, '__loader__': <SourceFileLoader(name='__main__', path='/usr/local/bin/mkdocs') at remote 0x7fae7f575810>, '__spec__': None, '__annotations__': {}, '__builtins__': <module at remote 0x7fae7f744a90>, '__file__': '/usr/local/bin/mkdocs', '__cached__': None, 're': <module at remote 0x7fae7f5ac630>, 'sys': <module at remote 0x7fae7f736ca0>, 'cli': <Group(name='cli', context_settings={'help_option_names': ['-h', '--help'], 'max_content_width': 120}, callback=<function at remote 0x7fae7ee0a0c0>, params=[<Option(name='version', opts=['-V', '--version'], secondary_opts=[], type=<BoolParamType() at remote 0x7fae7f226550>, required=False, callback=<function at remote 0x7fae7ee09f80>, nargs=1, multiple=False, expose_value=False, default=False, is_eager=True, metavar=None, envvar=None, _custom_shell_complete=None, prompt=None, confirmation_prompt=False, prompt_required=True, hide_input=False, hidden=False, _flag_needs_value=False, is_flag=True, is_bool_flag=Tr...(truncated), flags=flags@entry=0x7ffc387c0bf8, arena=arena@entry=0x7fae7f6d5c10) at Python/pythonrun.c:1762
#37 0x00007fae7fd55182 in pyrun_file (fp=fp@entry=0x57149881e370, filename=filename@entry='/usr/local/bin/mkdocs', start=start@entry=257, globals=globals@entry={'__name__': '__main__', '__doc__': None, '__package__': None, '__loader__': <SourceFileLoader(name='__main__', path='/usr/local/bin/mkdocs') at remote 0x7fae7f575810>, '__spec__': None, '__annotations__': {}, '__builtins__': <module at remote 0x7fae7f744a90>, '__file__': '/usr/local/bin/mkdocs', '__cached__': None, 're': <module at remote 0x7fae7f5ac630>, 'sys': <module at remote 0x7fae7f736ca0>, 'cli': <Group(name='cli', context_settings={'help_option_names': ['-h', '--help'], 'max_content_width': 120}, callback=<function at remote 0x7fae7ee0a0c0>, params=[<Option(name='version', opts=['-V', '--version'], secondary_opts=[], type=<BoolParamType() at remote 0x7fae7f226550>, required=False, callback=<function at remote 0x7fae7ee09f80>, nargs=1, multiple=False, expose_value=False, default=False, is_eager=True, metavar=None, envvar=None, _custom_shell_complete=None, prompt=None, confirmation_prompt=False, prompt_required=True, hide_input=False, hidden=False, _flag_needs_value=False, is_flag=True, is_bool_flag=Tr...(truncated), locals=locals@entry={'__name__': '__main__', '__doc__': None, '__package__': None, '__loader__': <SourceFileLoader(name='__main__', path='/usr/local/bin/mkdocs') at remote 0x7fae7f575810>, '__spec__': None, '__annotations__': {}, '__builtins__': <module at remote 0x7fae7f744a90>, '__file__': '/usr/local/bin/mkdocs', '__cached__': None, 're': <module at remote 0x7fae7f5ac630>, 'sys': <module at remote 0x7fae7f736ca0>, 'cli': <Group(name='cli', context_settings={'help_option_names': ['-h', '--help'], 'max_content_width': 120}, callback=<function at remote 0x7fae7ee0a0c0>, params=[<Option(name='version', opts=['-V', '--version'], secondary_opts=[], type=<BoolParamType() at remote 0x7fae7f226550>, required=False, callback=<function at remote 0x7fae7ee09f80>, nargs=1, multiple=False, expose_value=False, default=False, is_eager=True, metavar=None, envvar=None, _custom_shell_complete=None, prompt=None, confirmation_prompt=False, prompt_required=True, hide_input=False, hidden=False, _flag_needs_value=False, is_flag=True, is_bool_flag=Tr...(truncated), closeit=closeit@entry=1, flags=0x7ffc387c0bf8) at Python/pythonrun.c:1657
#38 0x00007fae7fd54f95 in _PyRun_SimpleFileObject (fp=0x57149881e370, filename='/usr/local/bin/mkdocs', closeit=1, flags=0x7ffc387c0bf8) at Python/pythonrun.c:440
#39 0x00007fae7fd54d94 in _PyRun_AnyFileObject (fp=0x57149881e370, filename='/usr/local/bin/mkdocs', closeit=1, flags=0x7ffc387c0bf8) at Python/pythonrun.c:79
#40 0x00007fae7fc0956a in pymain_run_file_obj (skip_source_first_line=0, filename='/usr/local/bin/mkdocs', program_name='/usr/local/bin/python') at Modules/main.c:360
#41 pymain_run_file (config=0x7fae7ffa86a0 <_PyRuntime+59904>) at Modules/main.c:379
#42 pymain_run_python (exitcode=0x7ffc387c0bf4) at Modules/main.c:601
#43 Py_RunMain () at Modules/main.c:680
#44 0x00007fae7fd12c77 in Py_BytesMain (argc=<optimized out>, argv=<optimized out>) at Modules/main.c:734
#45 0x00007fae7f91a24a in __libc_start_call_main (main=main@entry=0x5714972ec140 <main>, argc=argc@entry=5, argv=argv@entry=0x7ffc387c0e48) at ../sysdeps/nptl/libc_start_call_main.h:58
#46 0x00007fae7f91a305 in __libc_start_main_impl (main=0x5714972ec140 <main>, argc=5, argv=0x7ffc387c0e48, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7ffc387c0e38) at ../csu/libc-start.c:360
#47 0x00005714972ec071 in _start ()
Triple backticks are being using in form-scoring.md
when they should be inline single backticks. Replacing them all seems to make everything work again :rofl:
I hate computers I'm off to live on a farm somewhere
Looks like it was pymdown-extensions being upgraded that caused the issue. We bring it in transitively via markdown and mkdocs.
Good version
2024-09-23T14:19:20.6100516Z #11 5.607 Collecting pymdown-extensions~=10.2 (from mkdocs-material==9.5.32->-r /app/requirements/requirements.txt (line 48))
2024-09-23T14:19:20.6102579Z #11 5.610 Downloading pymdown_extensions-10.10.1-py3-none-any.whl.metadata (3.0 kB)
Bad version
2024-10-01T07:20:51.2576000Z #11 5.745 Collecting pymdown-extensions~=10.2 (from mkdocs-material==9.5.32->-r /app/requirements/requirements.txt (line 48))
2024-10-01T07:20:51.4143409Z #11 5.752 Downloading pymdown_extensions-10.11.1-py3-none-any.whl.metadata (3.0 kB)
I think it probably was https://github.com/facelessuser/pymdown-extensions/pull/2470. My guess is that we somehow sent the updated superfence regex quadratic or something. They have previously fixed some Regex DOS in that one: https://github.com/Python-Markdown/markdown/pull/1130
Fixed in #1048
https://github.com/rcpch/rcpch-audit-engine/actions/runs/11103582170/job/30897712344
Appears to hang on this line which builds the documentation to later embed in the container:
https://github.com/rcpch/rcpch-audit-engine/blob/aba0c3882ccf9055964d3905c471c296637e23b7/s/ci#L21
This command runs fine locally on my machine in 15 seconds.