Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues after updating modules for Sonos plugin #60

Closed
mlamoure opened this issue Jul 11, 2023 · 5 comments
Closed

Issues after updating modules for Sonos plugin #60

mlamoure opened this issue Jul 11, 2023 · 5 comments
Assignees

Comments

@mlamoure
Copy link

mlamoure commented Jul 11, 2023

Hey—

Yesterday I installed the Sonos Python 3 preview, which had me run a bunch of pip3 commands to install missing modules. After doing so, I noticed today that the Lutron plugin stopped working. See below log when doing a reload. Any thoughts on how to address?

   Reloading plugin "Lutron RRA2/Caséta 2022.1.2" using API v3.0
   Starting plugin "Lutron RRA2/Caséta 2022.1.2" (pid 47685)
   Lutron RRA2/Caséta Error        insert() argument 2 must be xml.etree.ElementTree.Element, not lxml.etree._Element
Traceback (most recent call last):
  File "/Library/Application Support/Perceptive Automation/Indigo 2022.2/IndigoPluginHost3.app/Contents/Resources/PlugIns/plugin_base.py", line 290, in __init__
    indigo._resolvePluginFuncFromName(self, "_parseDevicesXML")(DEVICE_FILENAME)
  File "/Library/Application Support/Perceptive Automation/Indigo 2022.2/IndigoPluginHost3.app/Contents/Resources/PlugIns/plugin_base.py", line 894, in _parse_devices_xml
    device_dict["ConfigUIRawXml"] = self._parse_config_ui_node(config_ui, filename=filename)
  File "/Library/Application Support/Perceptive Automation/Indigo 2022.2/IndigoPluginHost3.app/Contents/Resources/PlugIns/plugin_base.py", line 624, in _parse_config_ui_node
    self._swap_templated_field(config_ui, refnode, refid, templatename, True)
  File "/Library/Application Support/Perceptive Automation/Indigo 2022.2/IndigoPluginHost3.app/Contents/Resources/PlugIns/plugin_base.py", line 604, in _swap_templated_field
    config_ui.insert(insert_index, import_field)
TypeError: insert() argument 2 must be xml.etree.ElementTree.Element, not lxml.etree._Element
@mlamoure
Copy link
Author

It looks like lxml is the module in question.

$ pip3.10 install lxml
Requirement already satisfied: lxml in /Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/site-packages (4.9.3)

@FlyingDiver
Copy link
Owner

First thing to do is uninstall lxml and see if it starts working again.

That error is actually in the Indigo plugin host code, not my plugin.

@mlamoure
Copy link
Author

Yes uninstalling the lxml module allowed the Lutron plugin to start properly. However doing so produces errors for the Sonos plugin now. Should I report that to the new Sonos plugin team?

@FlyingDiver
Copy link
Owner

Yes. I'll see if I can help them figure out why it's breaking.

@mlamoure
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants