Registry / http-networking / ryu
library4.34pypypiunverified

Ryu is a component-based software-defined networking (SDN) framework that provides a set of APIs for network applications to manage and control network devices. The current version is 4.34. It has a stable release cadence with occasional updates.

pip install ryu
INSTALL
IMPORT
SIG · RYU
R
ryu
http-networkingpythonv4.34
Install
Import
Disk
Pass rate
0/ 10
Env Coverage0 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v? · pip install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.95 runs
build_error
glibc
py 3.103.95 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

app_manager
from ryu.base import app_manager
import app_manager
Ryu is not installed as top-level modules; always import from 'ryu' package.
set_ev_cls
from ryu.controller.handler import set_ev_cls
from ryu.base.handler import set_ev_cls
set_ev_cls is in the controller.handler module, not base.

A minimal Ryu application that responds to switch connection events.

from ryu.base import app_manager from ryu.controller import ofp_event from ryu.controller.handler import MAIN_DISPATCHER, set_ev_cls from ryu.ofproto import ofproto_v1_3 class MyController(app_manager.RyuApp): OFP_VERSIONS = [ofproto_v1_3.OFP_VERSION] @set_ev_cls(ofp_event.EventOFPSwitchFeatures, MAIN_DISPATCHER) def switch_features_handler(self, ev): datapath = ev.msg.datapath ofproto = datapath.ofproto parser = datapath.ofproto_parser print(f"Switch connected: {datapath.id}")
ryu-manager --version
Debug
Known issues
breakingRyu removed support for Python 2.7 as of version 4.31. Attempting to use Python 2 will result in syntax errors.
fix
Use Python 3.6 or higher.
affects: >=4.31
deprecatedThe 'ryu-manager --observe-links' flag is deprecated in favor of using the REST API or topology discovery module directly.
fix
Use Ryu's REST API or import 'ryu.app.rest_topology' explicitly.
affects: >=4.30
gotchaRyu applications must declare the OFP_VERSIONS class variable. Omitting it causes silent failures or versions mismatches.
fix
Add 'OFP_VERSIONS = [ofproto_v1_3.OFP_VERSION]' (or appropriate version) in your RyuApp subclass.
affects: all
Upgrade
Version history
4.34latest on PyPI · released May 27, 2020
Audit
Dependencies
eventletrequiredRequired for asynchronous I/O and hub.
routesrequiredRequired for URL routing in REST API.
Agent activity
14 hits · last 30 days
node
10
OpenAI (training)
1
Resources
ryu — pip install ryu · libregistry