Not able to run builds on travis after using SPM plugin

Getting following error when running builds having any SPM plugin like SwiftGenPlugin:

Build link:

The following build commands failed:
    Validate plug-in “SwiftGenPlugin” in package “swiftgenplugin”

Build Link:

I was able to solve this issue by using -skipPackagePluginValidation option in xcodebuild.

With fastlane you can pass it with --xcargs "-skipPackagePluginValidation" option in gym command

See this build