Commit 6f79679a authored by Paweł Hajdan, Jr's avatar Paweł Hajdan, Jr Committed by Commit Bot

gclient validate: allow "recursion" setting

It's still used in some places like CDM.

This fixes the bug below.

Bug: 728343
Change-Id: I0f9e2bbd0339838ee6d1d240c584858947cf36d2
Reviewed-on: https://chromium-review.googlesource.com/522682
Commit-Queue: Paweł Hajdan Jr. <phajdan.jr@chromium.org>
Reviewed-by: 's avatarEmma Soederberg <emso@google.com>
parent 84f6f76c
......@@ -70,6 +70,9 @@ _GCLIENT_SCHEMA = schema.Schema({
# Hooks executed before processing DEPS. See 'hooks' for more details.
schema.Optional('pre_deps_hooks'): _GCLIENT_HOOKS_SCHEMA,
# Recursion limit for nested DEPS.
schema.Optional('recursion'): int,
# Whitelists deps for which recursion should be enabled.
schema.Optional('recursedeps'): [
schema.Optional(schema.Or(
......@@ -111,6 +114,8 @@ def _gclient_eval(node_or_string, global_scope, filename='<unknown>'):
def _convert(node):
if isinstance(node, ast.Str):
return node.s
elif isinstance(node, ast.Num):
return node.n
elif isinstance(node, ast.Tuple):
return tuple(map(_convert, node.elts))
elif isinstance(node, ast.List):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment