Skip to content
This repository has been archived by the owner on Sep 20, 2024. It is now read-only.

Fix Avalon plugins attribute overrides #1413

Merged
merged 1 commit into from
Apr 30, 2021

Conversation

iLLiCiTiT
Copy link
Member

Issue

Function modifying attributes of avalon plugins is using host integration module to define what is host name which is an issue because we've moved all host integrations into api folder so all plugins are looking for api host in settings.

Changes

  • added function modifying attributes of plugins that can be imported form openpype.lib
  • function take host name from AVALON_APP which should always hold host name

@iLLiCiTiT iLLiCiTiT self-assigned this Apr 27, 2021
print(">>> We have preset for {}".format(plugin_name))
for option, value in plugin_settings.items():
if option == "enabled" and value is False:
setattr(plugin, "active", False)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do not call setattr with a constant attribute value, it is not any safer than normal property access.

@mkolar mkolar added this to the 3.0.0-rc1 milestone Apr 30, 2021
@mkolar mkolar added the type: bug Something isn't working label Apr 30, 2021
@mkolar mkolar merged commit 18b41d6 into develop Apr 30, 2021
@mkolar mkolar deleted the bugfix/plugin_overrides_per_host branch April 30, 2021 14:47
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
type: bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants