There is a high possibility that the Trust settings between the iOS real device and the Mac PC are not working properly. Try the following procedure to resolve the issue.
- Select Settings > General > Reset > Reset Location & Privacy on the iOS real device, and clear the settings for trusted computers.
- Restart the iOS real device.
- Connect the iOS real device to the Mac PC, and if the message “Trust This Computer?” appears, click Trust.
If it doesn't work, you can get more detailed error messages by running the "ios-deploy --id *** --bundle ***" part of the command directly from the Mac terminal. If the error message “A valid provisioning profile for this executable was not found” appears, use the following procedure to check that the IPA file can be used on the tested device.
- Copy the IPA file and change the extension to .zip.
- Double-click the .zip file to unzip the file.
- Open the contents of Payload/***.app/embedded.mobileprovision in a text editor as a binary file, and check that the UDID of the tested device is included in the ProvisionedDevices.
- If it is not included, the IPA file cannot be used on the tested device.
In such a case, recreate the IPA file using the following procedure.
- Register the UDID of the tested device in Devices on the Apple Developer program page.
- Use the Apple ID used in 1. to create the IPA file (Ad-Hoc or Development) again.