Sometimes Nanoc fails to build the site

It seems sometimes Nanoc is choking and it errors out. The process doesn't stop, but it creates some skip entries which then they stuck.

Job #246070460 failed for b96a7b55.

      create  [0.00s]  public/ce/user/admin_area/img/license_details.png
      create  [0.00s]  public/ce/user/admin_area/user_cohorts.html  No link definition for link ID 'core only' found on line 4
kramdown warning(s) for <Nanoc::CompilationItemRepView item.identifier=/ce/user/admin_area/license.md name=default>
  No link definition for link ID 'starter only' found on line 4
kramdown warning(s) for <Nanoc::CompilationItemRepView item.identifier=/ce/user/admin_area/geo_nodes.md name=default>
  No link definition for link ID 'premium only' found on line 4
#<Thread:0x0000559eddf3fb20@/builds/gitlab-com/gitlab-docs/vendor/ruby/2.6.0/gems/nanoc-core-4.11.5/lib/nanoc/core/notification_center.rb:29 run> terminated with exception (report_on_exception is true):
/builds/gitlab-com/gitlab-docs/vendor/ruby/2.6.0/gems/ddmetrics-1.0.1/lib/ddmetrics/stopwatch.rb:29:in `start': Cannot start, because stopwatch is already running (DDMetrics::Stopwatch::AlreadyRunningError)
	from /builds/gitlab-com/gitlab-docs/vendor/ruby/2.6.0/gems/nanoc-4.11.5/lib/nanoc/cli/commands/compile_listeners/file_action_printer.rb:32:in `block in start'
	from /builds/gitlab-com/gitlab-docs/vendor/ruby/2.6.0/gems/nanoc-4.11.5/lib/nanoc/cli/commands/compile_listeners/abstract.rb:55:in `block in on'
	from /builds/gitlab-com/gitlab-docs/vendor/ruby/2.6.0/gems/nanoc-core-4.11.5/lib/nanoc/core/notification_center.rb:40:in `block (3 levels) in start'
	from /builds/gitlab-com/gitlab-docs/vendor/ruby/2.6.0/gems/nanoc-core-4.11.5/lib/nanoc/core/notification_center.rb:39:in `each'
	from /builds/gitlab-com/gitlab-docs/vendor/ruby/2.6.0/gems/nanoc-core-4.11.5/lib/nanoc/core/notification_center.rb:39:in `block (2 levels) in start'
	from /builds/gitlab-com/gitlab-docs/vendor/ruby/2.6.0/gems/nanoc-core-4.11.5/lib/nanoc/core/notification_center.rb:32:in `loop'
	from /builds/gitlab-com/gitlab-docs/vendor/ruby/2.6.0/gems/nanoc-core-4.11.5/lib/nanoc/core/notification_center.rb:32:in `block in start'

      create  [0.11s]  public/ce/user/admin_area/monitoring/health_check.html
      create  [0.16s]  public/ce/user/admin_area/custom_project_templates.html
      create  [0.09s]  public/ce/user/admin_area/broadcast_messages.html
      create  [0.35s]  public/ce/user/admin_area/img/broadcast_messages.png
      create  [0.25s]  public/ce/user/admin_area/img/abuse_reports_page.png
      create  [0.07s]  public/ce/user/admin_area/labels.html
      create  [0.61s]  public/ce/user/admin_area/monitoring/convdev.html
        skip  /builds/gitlab-com/gitlab-docs/public/ce/user/admin_area/diff_limits.html
        skip  /builds/gitlab-com/gitlab-docs/public/ce/user/admin_area/abuse_reports.html
        skip  /builds/gitlab-com/gitlab-docs/public/ce/user/admin_area/index.html
        skip  /builds/gitlab-com/gitlab-docs/public/ce/user/admin_area/settings/terms.html

Upstream issue

I reported this upstream https://github.com/nanoc/nanoc/issues/1445.

Edited by Achilleas Pipinellis