I may have found a bug with the new Error_event class you added recently. I notice that when I set the xid of a flow mod, the xid in an error event is different. Perhaps its not converted back from network format? I'm not sure where that code is, but it is being converted to network format on the way out in pycontext.cc.

-Derek

On 12/17/2010 04:07 PM, Derek Cormier wrote:
It works =)

On 12/17/2010 04:03 PM, Murphy McCauley wrote:
Ugh, I have actually been sitting on a patch forever that add support for xids all the way through Python; I really should nail it down and commit it. Sorry.

Change send_flow_command() in context.i also.

-- Murphy

On Dec 16, 2010, at 10:52 PM, Derek Cormier wrote:

Hello,

I'm modifying some Nox code so that core.py's *install_datapath_flow* takes another argument- the xid for the flow mod request.

def install_datapath_flow(self, dp_id, attrs, idle_timeout, hard_timeout,
                              actions, buffer_id=None,
                              priority=openflow.OFP_DEFAULT_PRIORITY,
                              inport=None, packet=None, xid=0):

I also changed *send_flow_command*...

def send_flow_command(self, dp_id, command, attrs,
                          priority=openflow.OFP_DEFAULT_PRIORITY,
                          add_args=None,
hard_timeout=openflow.OFP_FLOW_PERMANENT, xid=0):

... and its call

self.ctxt.send_flow_command(dp_id, command, m, idle_timeout,
hard_timeout, oactions, buffer_id, priority, xid)

I also made the argument changes in *pycontext.hh* and *pycontext.c*.

However, when I run a Nox component that calls that method, I get the error:

File "./nox/coreapps/pyrt/pycomponent.py", line 589, in send_flow_command def send_flow_command(self, *args): return _pycomponent.PyContext_send_flow_command(self, *args) TypeError: PyContext_send_flow_command() *takes exactly 9 arguments (10 given)*

I did recompile the source. *pycomponent.py* seems to be created after building, so there is some other step I'm missing. I think it has to do with swig?

Thanks for your help,
Derek

_______________________________________________
nox-dev mailing list
nox-dev@noxrepo.org <mailto:nox-dev@noxrepo.org>
http://noxrepo.org/mailman/listinfo/nox-dev_noxrepo.org



_______________________________________________
nox-dev mailing list
nox-dev@noxrepo.org
http://noxrepo.org/mailman/listinfo/nox-dev_noxrepo.org

_______________________________________________
nox-dev mailing list
nox-dev@noxrepo.org
http://noxrepo.org/mailman/listinfo/nox-dev_noxrepo.org

Reply via email to