Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chapter source deploy fails on permissions sets #3

Open
elukaweski opened this issue May 17, 2015 · 5 comments
Open

chapter source deploy fails on permissions sets #3

elukaweski opened this issue May 17, 2015 · 5 comments
Labels

Comments

@elukaweski
Copy link

Hi.....tremendous book !!! Glad to see all your ideas, which are discussed in various blogs, distilled into one central book.

I have an issue when deploying any individual chapter source via 'ant deploy'. The error I get is:
Error: Unknown user permission:
where is something like ManageUnlistedGroups
the workaround I use is to delete the permission sets folder from src...and remove the reference to commission sets from the package.xmkl file.

I have researched and cannot discover why I am getting this error. Any clues?
Thanks
Edwin

@afawcett
Copy link
Owner

This is a frustrating design issue with permission sets in my view, something i later discussed in this blog. Basically the fix is to remove all but required 'positive' permissions from the files (in this case all the userPermission entries). I'll make the changes in the .permissionSet files though in the repo to avoid this issue for others.

@afawcett afawcett added the bug label May 17, 2015
@afawcett
Copy link
Owner

Oh and thank you for your kind comments on the book, glad your enjoying it! 👍

@afawcett
Copy link
Owner

Note that depending on the features and type of org you have some user permissions don't exist, this is known as 'org shape' generally, by removing all unwanted and unneccessary entries from .permissionset files you avoid hitting this issue. In your case, ManageUnlistedGroups, its possible this permission is related to a configurable feature not on in your org, either due to you not enabling the related feature or it being not enabled in your org since its an old org. Hope this helps further with some more explanation.

@elukaweski
Copy link
Author

thanks for the quick response.

For now, I'll continue to just delete the files and look for the commit where you remove the "non-positive' permissions.
I just wonder why they are all there in the first place. When I build some permission sets as per the book (chapter 2 or 3), the resultant file is not the complete set of permissions.
Edwin

@afawcett
Copy link
Owner

Its an odd behaviour of how the Salesforce download of these metadata types work. Basically the files contain user access permissions, then only field/object/tab etc. permissions that relate to the objects/tabs etc your also retrieving in the same download. There is no direct way to say "give me all thats in the permission set" without specifying the entire system in the download request. I'm not sure if i covered this in the book or not, but i'm tending not download them and simply maintain them in source form. I also wrote a blog on with some more thoughts here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants