BIND 10 #1179: python interface for data source
BIND 10 Development
do-not-reply at isc.org
Mon Sep 26 15:28:49 UTC 2011
#1179: python interface for data source
-------------------------------------+-------------------------------------
Reporter: | Owner: vorner
jinmei | Status: reviewing
Type: task | Milestone:
Priority: major | Sprint-20110927
Component: data | Resolution:
source | Sensitive: 0
Keywords: | Sub-Project: DNS
Defect Severity: N/A | Estimated Difficulty: 4
Feature Depending on Ticket: | Total Hours: 0
Add Hours to Ticket: 0 |
Internal?: 0 |
-------------------------------------+-------------------------------------
Changes (by jelte):
* owner: jelte => vorner
Comment:
Replying to [comment:12 vorner]:
> > I've made it into a more general way (make a list of rrsets to expect,
and
> > check them one by one on name, class, type, sorted rdata), instead of
hoping
> > that to_text() returns the same). It does completely skip rdata for
RRSIG
> > rrsets now; the API won't allow me to recreate rrsig data
'FAKEFAKEFAKE' :)
>
> How is that so? In works in C++ tests, who stops you from creating them?
>
ok,ok, my laziness does :)
the c++ tests compare raw wire data while i compare rdata structures in
these tests, and 'FAKEFAKEFAKE' is not valid RRSIG rdata, but we could do
the same here. Haven't done so yet (it would make the helper functions
uglier if i need to pass multiple sets of raw data around), but you may
insist :)
> > I think we can make separate tasks for those. They should be pretty
> > small.
>
> OK, tomorrow is planning call, let's have few tasks ready for it.
>
will do
> One comment to the code. What is the purpose of the smiley?
> {{{#!python
> expected_rrsets[:]
> }}}
>
> If you mean the whole list, the brackets don't need to be there.
It's a copy (by way of a slice over the whole list). Technically it's not
necessary, since we return straight away, but in general it is a bad idea
to modify something you're iterating over, so I prefer to make a copy in
such cases. List(expected_rrsets) or copy.copy(expected_rrsets) are fine
in this scenario too, but i'm quite partial to the [:] notation :)
--
Ticket URL: <http://bind10.isc.org/ticket/1179#comment:13>
BIND 10 Development <http://bind10.isc.org>
BIND 10 Development
More information about the bind10-tickets
mailing list