Browse Source

3-part Dyn TD labels are no more

pull/312/head
Ross McFarland 7 years ago
parent
commit
da9e268659
No known key found for this signature in database GPG Key ID: 61C10C4FC8FE4A89
2 changed files with 4 additions and 8 deletions
  1. +3
    -7
      octodns/provider/dyn.py
  2. +1
    -1
      tests/test_octodns_provider_dyn.py

+ 3
- 7
octodns/provider/dyn.py View File

@ -399,14 +399,10 @@ class DynProvider(BaseProvider):
tds = defaultdict(dict)
for td in get_all_dsf_services():
try:
_, fqdn, _type = td.label.split(':', 2)
fqdn, _type = td.label.split(':', 1)
except ValueError:
try:
fqdn, _type = td.label.split(':', 1)
except ValueError:
self.log.warn("Unsupported TrafficDirector '%s'",
td.label)
continue
self.log.warn("Unsupported TrafficDirector '%s'", td.label)
continue
tds[fqdn][_type] = td
self._traffic_directors = dict(tds)


+ 1
- 1
tests/test_octodns_provider_dyn.py View File

@ -1626,7 +1626,7 @@ class DummyRuleset(object):
class DummyTrafficDirector(object):
def __init__(self, rulesets=[], response_pools=[], ttl=42):
self.label = 'dynamic:dummy'
self.label = 'dummy:abcdef1234567890'
self.rulesets = rulesets
self.all_response_pools = response_pools
self.ttl = ttl


Loading…
Cancel
Save