mirror of
https://github.com/github/octodns.git
synced 2024-05-11 05:55:00 +00:00
Enforce values as basic string to fix yaml export error
Fixes an exception in combination
with the yamlProvider as a target
The unmodified value object isn't
represented as string while
building the yaml output
The Exception:
yaml.representer.RepresenterError:
('cannot represent an object', 1.1.1.1)
yaml/representer.py@249,
represent_undefined()
This commit is contained in:
@@ -218,6 +218,9 @@ class TransipProvider(BaseProvider):
|
|||||||
|
|
||||||
def _parse_to_fqdn(self, value):
|
def _parse_to_fqdn(self, value):
|
||||||
|
|
||||||
|
# Enforce switch from suds.sax.text.Text to string
|
||||||
|
value = ''+value
|
||||||
|
|
||||||
# TransIP allows '@' as value to alias the root record.
|
# TransIP allows '@' as value to alias the root record.
|
||||||
# this provider won't set an '@' value, but can be an existing record
|
# this provider won't set an '@' value, but can be an existing record
|
||||||
if value == self.ROOT_RECORD:
|
if value == self.ROOT_RECORD:
|
||||||
@@ -240,7 +243,8 @@ class TransipProvider(BaseProvider):
|
|||||||
|
|
||||||
_values = []
|
_values = []
|
||||||
for record in records:
|
for record in records:
|
||||||
_values.append(record['content'])
|
# Enforce switch from suds.sax.text.Text to string
|
||||||
|
_values.append(''+record['content'])
|
||||||
|
|
||||||
return {
|
return {
|
||||||
'ttl': self._get_lowest_ttl(records),
|
'ttl': self._get_lowest_ttl(records),
|
||||||
|
|||||||
Reference in New Issue
Block a user