Skip to content

Issue with gpiodevice #21

@tijmenvandenbrink

Description

@tijmenvandenbrink

Hi,

I'm getting the following error after upgrading pms5003 from 0.0.5 to 1.0.0. I'm running on:

Linux raspberrypi 6.1.21-v8+ #1642 SMP PREEMPT Mon Apr  3 17:24:16 BST 2023 aarch64 GNU/Linux

PRETTY_NAME="Debian GNU/Linux 11 (bullseye)"
NAME="Debian GNU/Linux"
VERSION_ID="11"
VERSION="11 (bullseye)"
VERSION_CODENAME=bullseye
ID=debian

I get the following error:

Press Ctrl+C to exit!


StopIteration

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/tijmen/projects/enviroplus_exporter/enviroplus_exporter.py", line 52, in <module>
    pms5003 = PMS5003()
  File "/home/tijmen/projects/enviroplus_exporter/.env/lib/python3.9/site-packages/pms5003/__init__.py", line 109, in __init__
    self._pin_enable, self._pin_reset = gpiodevice.get_pins_for_platform(PLATFORMS)
  File "/home/tijmen/projects/enviroplus_exporter/.env/lib/python3.9/site-packages/gpiodevice/__init__.py", line 153, in get_pins_for_platform
    result.append(get_pin(pin, user_label, settings))
  File "/home/tijmen/projects/enviroplus_exporter/.env/lib/python3.9/site-packages/gpiodevice/__init__.py", line 138, in get_pin
    chip = find_chip_by_pins(pin)
  File "/home/tijmen/projects/enviroplus_exporter/.env/lib/python3.9/site-packages/gpiodevice/errors.py", line 45, in wrapper
    errors.append(next(i))
SystemError: <built-in method close of gpiod._ext.Chip object at 0x7fb1f3a850> returned a result with an error set

Any idea how to resolve this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions