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

Allow backwards compatibility when setting float parameters to strings. #169

Merged
merged 2 commits into from
Nov 30, 2022

Conversation

psobot
Copy link
Member

@psobot psobot commented Nov 29, 2022

This PR fixes an introduced in #167; existing code that may set VST parameter values to strings (i.e.: plugin.frequency = "123.45 dB") will now throw a ValueError due to the fact that Pedalboard now (as of v0.6.5) expects a float instead of a str.

To fix this, Pedalboard now:

  • more reliably detects when a VST or AU plugin's parameters have suffixes but don't report them to the host via the .label parameter
  • allows setting a float-based parameter with a str
  • allows setting a float-based parameter with a str that has its .label suffixed on the end
  • exposes a .units parameter on AudioPluginParameter instances, for better discoverability than .label.

@psobot psobot added the bug Something isn't working label Nov 29, 2022
@psobot psobot merged commit 08e5986 into master Nov 30, 2022
@psobot psobot deleted the psobot/float-param-backwards-compatibility branch November 30, 2022 01:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant