Sometimes when trying to activate or uninstall K2 4.7 App from App Catalog level or from the Site Collection level you can get the following error:
If you enable SmO logging you can trace that error actually happens on SmO level, more specifically with SharePoint Integration Helper Methods SmO and its Activate Site Collection method:
System > SharePoint 2013 Integration > SharePoint Integration Helper Methods
*NOTE: Issue happens with Activate Site Collection method, not with Activate Site Collections one.
Sometimes clearing your browser’s cookies and cache or starting your browser using another user account or incognito / InPrivate mode helps to resolve this issue. But when those methods does not work you may try to execute this method manually in the SmO Tester tool using K2 service account. The only required input property which you need is the SiteURL, the rest of the fields can be blank. This action should result in an output message “Success”. Once that’s done, you can go back to your SharePoint AppCatalog and Activate or Uninstall the K2 App from there – this time it should not give you any errors.