Closed Bug 1232457 Opened 4 years ago Closed 4 years ago

Make ./mach taskcluster-graph errors more readable

Categories

(Taskcluster :: General, defect)

defect
Not set

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 1245888

People

(Reporter: armenzg, Unassigned)

References

Details

In production it looks like this [1] and locally it looks like this [2]

[1]
+ ./mach taskcluster-graph --pushlog-id=100896 --project=try '--message=try: -b od -p linux64_tc -u all -t none' --owner=jmaher@mozilla.com --revision-hash=f5be19e29b4b073f026bacbea0f31fa457d871bc --extend-graph
[taskcluster] === Task Finished ===
[taskcluster:error] Error calling 'stopped' for extendTaskGraph : Error encountered when attempting to extend task graph. Invalid json in taskgraph extension path: "/home/worker/artifacts/graph.json". Dumping file. "Error running mach:\n\n    ['taskcluster-graph', '--pushlog-id=100896', '--project=try', '--message=try: -b od -p linux64_tc -u all -t none', '--owner=jmaher@mozilla.com', '--revision-hash=f5be19e29b4b073f026bacbea0f31fa457d871bc', '--extend-graph']\n\nThe error occurred in code that was called by the mach command. This is either\na bug in the called code itself or in the way that mach is calling it.\n\nYou should consider filing a bug for this issue.\n\nIf filing a bug, please include the full output of mach, including this error\nmessage.\n\nThe details of the failure are as follows:\n\nParserError: while parsing a block mapping\n  in \"<unicode string>\", line 240, column 6:\n         allowed_build_tasks:\n         ^\nexpected <block end>, but found '<block mapping start>'\n  in \"<unicode string>\", line 243, column 7:\n          tasks/builds/opt_linux64_clobber ... \n          ^\n\n  File \"/home/worker/workspace/gecko/testing/taskcluster/mach_commands.py\", line 318, in create_graph\n    jobs = templates.load(job_path, {})\n  File \"/home/worker/workspace/gecko/testing/taskcluster/taskcluster_graph/templates.py\", line 131, in load\n    return self.render(path, content, parameters, seen)\n  File \"/home/worker/workspace/gecko/testing/taskcluster/taskcluster_graph/templates.py\", line 101, in render\n    result = yaml.load(content)\n  File \"/home/worker/workspace/gecko/python/pyyaml/lib/yaml/__init__.py\", line 71, in load\n    return loader.get_single_data()\n  File \"/home/worker/workspace/gecko/python/pyyaml/lib/yaml/constructor.py\", line 37, in get_single_data\n    node = self.get_single_node()\n  File \"/home/worker/workspace/gecko/python/pyyaml/lib/yaml/composer.py\", line 36, in get_single_node\n    document = self.compose_document()\n  File \"/home/worker/workspace/gecko/python/pyyaml/lib/yaml/composer.py\", line 55, in compose_document\n    node = self.compose_node(None, None)\n  File \"/home/worker/workspace/gecko/python/pyyaml/lib/yaml/composer.py\", line 84, in compose_node\n    node = self.compose_mapping_node(anchor)\n  File \"/home/worker/workspace/gecko/python/pyyaml/lib/yaml/composer.py\", line 133, in compose_mapping_node\n    item_value = self.compose_node(node, item_key)\n  File \"/home/worker/workspace/gecko/python/pyyaml/lib/yaml/composer.py\", line 84, in compose_node\n    node = self.compose_mapping_node(anchor)\n  File \"/home/worker/workspace/gecko/python/pyyaml/lib/yaml/composer.py\", line 133, in compose_mapping_node\n    item_value = self.compose_node(node, item_key)\n  File \"/home/worker/workspace/gecko/python/pyyaml/lib/yaml/composer.py\", line 84, in compose_node\n    node = self.compose_mapping_node(anchor)\n  File \"/home/worker/workspace/gecko/python/pyyaml/lib/yaml/composer.py\", line 127, in compose_mapping_node\n    while not self.check_event(MappingEndEvent):\n  File \"/home/worker/workspace/gecko/python/pyyaml/lib/yaml/parser.py\", line 98, in check_event\n    self.current_event = self.state()\n  File \"/home/worker/workspace/gecko/python/pyyaml/lib/yaml/parser.py\", line 439, in parse_block_mapping_key\n    \"expected <block end>, but found %r\" % token.id, token.start_mark)\n"
[taskcluster] Unsuccessful task run with exit code: 1 completed in 34.217 seconds

[2]
armenzg@armenzg-thinkpad:~/repos/mozilla-central$ ./mach taskcluster-graph --pushlog-id=100896 --project=try '--message=try: -b od -p linux64_tc -u all -t none' --owner=jmaher@mozilla.com --revision-hash=f5be19e29b4b073f026bacbea0f31fa457d871bc --extend-graph
Error running mach:

    ['taskcluster-graph', '--pushlog-id=100896', '--project=try', '--message=try: -b od -p linux64_tc -u all -t none', '--owner=jmaher@mozilla.com', '--revision-hash=f5be19e29b4b073f026bacbea0f31fa457d871bc', '--extend-graph']

The error occurred in code that was called by the mach command. This is either
a bug in the called code itself or in the way that mach is calling it.

You should consider filing a bug for this issue.

If filing a bug, please include the full output of mach, including this error
message.

The details of the failure are as follows:

ParserError: while parsing a block mapping
  in "<unicode string>", line 240, column 6:
         allowed_build_tasks:
         ^
expected <block end>, but found '<block mapping start>'
  in "<unicode string>", line 243, column 7:
          tasks/builds/opt_linux64_clobber ... 
          ^

  File "/home/armenzg/repos/mozilla-central/testing/taskcluster/mach_commands.py", line 318, in create_graph
    jobs = templates.load(job_path, {})
  File "/home/armenzg/repos/mozilla-central/testing/taskcluster/taskcluster_graph/templates.py", line 131, in load
    return self.render(path, content, parameters, seen)
  File "/home/armenzg/repos/mozilla-central/testing/taskcluster/taskcluster_graph/templates.py", line 101, in render
    result = yaml.load(content)
  File "/home/armenzg/repos/mozilla-central/python/pyyaml/lib/yaml/__init__.py", line 71, in load
    return loader.get_single_data()
  File "/home/armenzg/repos/mozilla-central/python/pyyaml/lib/yaml/constructor.py", line 37, in get_single_data
    node = self.get_single_node()
  File "/home/armenzg/repos/mozilla-central/python/pyyaml/lib/yaml/composer.py", line 36, in get_single_node
    document = self.compose_document()
  File "/home/armenzg/repos/mozilla-central/python/pyyaml/lib/yaml/composer.py", line 55, in compose_document
    node = self.compose_node(None, None)
  File "/home/armenzg/repos/mozilla-central/python/pyyaml/lib/yaml/composer.py", line 84, in compose_node
    node = self.compose_mapping_node(anchor)
  File "/home/armenzg/repos/mozilla-central/python/pyyaml/lib/yaml/composer.py", line 133, in compose_mapping_node
    item_value = self.compose_node(node, item_key)
  File "/home/armenzg/repos/mozilla-central/python/pyyaml/lib/yaml/composer.py", line 84, in compose_node
    node = self.compose_mapping_node(anchor)
  File "/home/armenzg/repos/mozilla-central/python/pyyaml/lib/yaml/composer.py", line 133, in compose_mapping_node
    item_value = self.compose_node(node, item_key)
  File "/home/armenzg/repos/mozilla-central/python/pyyaml/lib/yaml/composer.py", line 84, in compose_node
    node = self.compose_mapping_node(anchor)
  File "/home/armenzg/repos/mozilla-central/python/pyyaml/lib/yaml/composer.py", line 127, in compose_mapping_node
    while not self.check_event(MappingEndEvent):
  File "/home/armenzg/repos/mozilla-central/python/pyyaml/lib/yaml/parser.py", line 98, in check_event
    self.current_event = self.state()
  File "/home/armenzg/repos/mozilla-central/python/pyyaml/lib/yaml/parser.py", line 439, in parse_block_mapping_key
    "expected <block end>, but found %r" % token.id, token.start_mark)
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 1245888
You need to log in before you can comment on or make changes to this bug.