Why does my MCPE command not work in MCJE?
Look at the error message:
Only one entity is allowed, but the provided selector allows more than one at position 0: <--[HERE]
When only one entity will be accepted, it is your job to make sure the target selector returns only one entity. Unlike Bedrock Edition, if your target selector allows more than one entity to be selected, even if it will return only one entity when run, it throws an error.
You need to use the limit=1
parameter to limit your target selection to one entity.
tp @e[type=husk] @e[type=wolf,limit=1]