8000 Incorrect "default" behavior in nested groups · Issue #94 · dmulyalin/ttp · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Incorrect "default" behavior in nested groups #94
Open
@vlisjak

Description

@vlisjak

Text:

router isis LAB
 <some lines removed>
 flex-algo 128
  priority 100
  metric-type delay
  advertise-definition
  prefix-metric
 !

Template: note that I define "priority" 999 so it does not match

<group name="routing.isis.LAB" default="MISSING">
router isis LAB {{ _start_ |  _exact_ }}
 
 <group name="fa128" default="MISSING">
 flex-algo 128 {{ _start_ |  _exact_ }}
  priority {{ priority | equal('999') }}
  metric-type {{ metric_type | equal('delay') }}
  advertise-definition {{ advertise_definition | set('true') }}
  prefix-metric {{ prefix_metric | set('true') }}
 !{{ _end_ }}
 </group>
 
 <group name="LEFTOVER">
 {{ LEFTOVER | _line_ | joinmatches }}
 </group>

!{{ _end_ }}
</group>

Result is wrong, because all attributes processed after "priority" are also marked MISSING (although they are supposed to match)

            fa128:
              advertise_definition: MISSING
              metric_type: MISSING
              prefix_metric: MISSING
              priority: MISSING

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0