aaron-sierra commented on PR #2066:
URL: https://github.com/apache/libcloud/pull/2066#issuecomment-6693851219

   Hi Miguel,
   
   Thanks for your review.  In the example that you described regarding 
`Zone.prefix()` for a "sub-domain" that isn't _actually_ related to the `Zone` 
instance, what would you suggest as reasonable output? A few options come to 
mind:
   
   1. Return `None` to indicate "no relationship", since the empty string is 
used to indicate "related, but no prefix"
       * Both `None` and `""` are falsy, which could make it a source of error.
   2. Raise a `ValueError` exception (to aggressively highlight bugs?)
   3. Something else
   
   Presumably all three of the `Zone` helpers that operate on sub-domains 
should behave similarly when offered an unrelated "sub-domain" (i.e. 
`Zone.prefix()`, `Zone.hostname()`, and `Zone.fqdn()`). Does that sound right 
to you?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to