GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

list_ports_duplo_hub.system()   A
last analyzed

Complexity

Conditions 1

Size

Total Lines 2
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
nop 0
dl 0
loc 2
rs 10
c 0
b 0
f 0
1
from itertools import cycle
2
from curio import sleep
3
from bricknil import attach, start
4
from bricknil.hub import DuploTrainHub
5
from bricknil.sensor import DuploTrainMotor
6
from bricknil.process import Process
7
from bricknil.const import Color
8
import logging
9
10
@attach(DuploTrainMotor, name='motor')
11
class Robot(DuploTrainHub):
12
13
    async def hub_btn_change(self):
14
        pass
15
    async def vision_sensor_change(self):
16
        pass
17
    async def motor_change(self):
18
        pass
19
    async def tilt_sensor_change(self):
20
        pass
21
22
    async def run(self):
23
        self.message_info("Running")
24
        await sleep(20) # Give it enough time to gather data
25
        self.message_info("Done")
26
27
        self.message_info(self.port_info)
28
29
async def system():
30
    hub = Robot('robot', query_port_info=True)
31
32
if __name__ == '__main__':
33
    logging.basicConfig(level=logging.DEBUG)
34
    start(system)
35