Skip to content

I can't test properly with unittest. #103

@ZA0068

Description

@ZA0068

I have a project that involves this Tello Python library.

Everything else works fine, except the test won't stop, despite it being completed regardless of success or failure.

I have to manually disable the test which is very tedious, and it will not work when firing multiple tests at once, because when once Tello object is created, it will not be destroyed and can't be called again twice.

This is error i get:

Stdout:
[WinError 10048] Normalt må en socket-adresse (protokol/netværksadresse/port) kun bruges én gang
Testing are done.

Stderr:
Traceback (most recent call last):
  File "c:\Users\zaina\OneDrive\Skoleopgaver\Robotteknologi\Bachelorprojekt\Source code\pytello\Arucodetector.py", line 57, in ConnectDrone
    self.SetDrone(tellopy.Tello())
  File "C:\Users\zaina\anaconda3\lib\site-packages\tellopy\_internal\tello.py", line 91, in __init__
    self.sock.bind(('', self.port))
OSError: [WinError 10048] Normalt må en socket-adresse (protokol/netværksadresse/port) kun bruges én gang

You can clearly see what i mean on that screenshot:
billede

Look at the blue lines I've made. These points out a nonterminating process that prevents re-instantiation of Tello Object.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions