Skip to content

Invalid Syntax in mode.py #218

@byrleyar

Description

@byrleyar

I am trying to get xbee-python up and running in Arch using pycharm. I've got a project setup using python 3.9. When I add from digi.xbee.devices import XBeeDevice to main.py, I get the following error:

Traceback (most recent call last):
File "/home/andrew/PycharmProjects/xbee/main.py", line 15, in
from digi.xbee.devices import XBeeDevice
File "/home/andrew/PycharmProjects/xbee/venv/lib/python3.9/site-packages/digi/xbee/devices.py", line 22, in
from digi.xbee import serial
File "/home/andrew/PycharmProjects/xbee/venv/lib/python3.9/site-packages/digi/xbee/serial.py", line 21, in
from digi.xbee.models.mode import OperatingMode
File "/home/andrew/PycharmProjects/xbee/venv/lib/python3.9/site-packages/digi/xbee/models/mode.py", line 230
return sum(op.code for op in options if lambda option: option != cls.EXPLICIT)
^
SyntaxError: invalid syntax

Note: the carrot falls directly under the "l" in lambda

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions