Greetings!
Just to be certain — are you running the command from the global configuration context, and not from the enable context? For example:
switch(config)# allow-unsupported-transceiver
Warning: The use of third-party transceivers is at your own risk and may void support and warranty. Please see HPE Warranty terms and conditions.
Do you agree, and do you wish to continue enabling? (Y/N)
The command will not work from the operator, enable, or any individual feature, interface, or VLAN context (even if you are in configuration mode):
switch(eth-1/10)# allow-unsupported-transceiver
Invalid input: allow-unsupported-transceiver