Skip to content

Seeing !!python/object/apply:ipaddress.IPv4Interface in yaml output #119

@bassslap

Description

@bassslap

Converting Cisco to JUNOS IPv4 address, example, I see the python object come through to yaml file:
convert from:
interface Loopback0
ip address 10.1.1.1 255.255.255.255

To yaml output, I see this using functions="to_ip('ip', 'mask'):

interface {{ intf }} ip address {{ ip }} {{ mask }}

output:
interfaces:
intf: Loopback0
ip: !!python/object/apply:ipaddress.IPv4Interface. <<<<<-----Why is this happening???
- 10.1.1.1/32. <<<<<<--- This looks good.
is_loop: true
mask: 255.255.255.255

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