Getting assertion error when trying to debug with audiopluginhost

I’m getting following assertion in a default juce project when I try to debug with the audiopluginhost:
#if JucePlugin_Build_AU
jassert (wrapperType == wrapperType_Undefined || param->getVersionHint() != 0);
I know what the error means, but how do I fix it?

You need to pass a non-zero version hint when constructing your parameters. This probably means passing a ParameterID { "id", 1 } instead of just "id" as the first parameter of each parameter constructor.

But where do I set the version hint, there is no use of a ParameterID in the pluginprocessor or plugineditor file. So my conclusion is that it is something inside of the buildings in juce but where do I set the version hint?

That is a new thing you are required to do in your code because of Apple/AU, and for example older tutorial material doesn’t cover it. You need to change the code where you are creating your plugin parameters to do that new thing.

For example, if your code has something like :

std::make_unique<juce::AudioParameterFloat> ("PSEUDOCTAVE", "Pseudo Octave", 100.0, 2400.0, 1200.0);

It would now need to be replaced with :

std::make_unique<juce::AudioParameterFloat> (juce::ParameterID("PSEUDOCTAVE",1), "Pseudo Octave", 100.0, 2400.0, 1200.0);

So I tried to compile and run the AudioPluginHost.jucer from Xcode and this assertion is getting active , so this has to be something within juce and not something I written, which is the big problem here. I need to get my hands dirty in the inside of juce to solve this problem but don’t know where to start with.

You don’t need to change anything in Juce, it’s a problem in your own code.

but I didn’t write anything yet I just compiled the AudioPluginHost. sorry for the expense but I’m really confused. I even reinstalled juce and it didn’t change anything.

Is the AudioPluginHost trying to load some existing plugins when you start it up? If those are your own plugins, you would need to rebuild them with the new changes required before you try to use the AudioPluginHost. (Or you have to edit/delete the AudioPluginHost document it loads at startup.)

oh that could be possible thanks! I will look for it and give a answer afterwards

Edit: Yes the big mistake was in some of my other projects where I didn’t debug and tried it directly in the DAW. Thanks for the support!