When installing commons for the first time, patches to the flag module causes the default flags not to render properly, which throws an error on site:

It only occurs on new installs it seems, and with the patches from the make file applied. When the patches are removed the error goes away. Working to isolate the specific patch causing the issue now.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | duplicate-flag-names-2283113-2.patch | 8.78 KB | devin carlson |
| Admin_Dude___commons3.jpg | 1.37 MB | japerry |
Comments
Comment #1
japerryConfirmed that #2027091: Provide a hook_flag_default_flags_alter to allow altering of default definations is the cause of the issue.
Since Devin wrote this I'll assign it to him ;-)I keep getting the two patches mixed up. This patch needs a port back to 2.x since the 3.x patch doesn't work properly.Comment #2
devin carlson commentedThe Commons Follow submodules (node, user, term, group) currently define their own
email_*flags which share the same names as the defaultemail_*flags provided by the Message Subscribe Email module.Flag uses a nonstandard (neither Entity API or CTools) method of providing default content that has a few issues in Flag 7.x-2.x which are fixed with the patches currently included in the makefile. These fixes result in the default flags provided by Message Subscribe Email being used over the identical flags provided by the Commons Follow submodules (whichever module is called last is used). The Message Subscribe Email default flags are disabled by default, while various code in Commons (mainly views) relies on the flags being available, which is the source of the error messages.
This issue could be solved in a number of ways:
email_*flags - ideal solution but not feasible due to the "upgrade" pathThe attached patch takes the second approach. The
email_groupflag is left alone since it actually doesn't use the same namespace as the equivalent flag provided by Message Subscribe Email, namedemail_og, which is why it isn't seen in the error message shown the screenshot.Comment #3
devin carlson commentedRetested #2 and confirmed that it fixed the error messages appearing on a fresh and an existing install by ensuring that the flags are enabled.
Comment #5
lsolesen commentedMarked #2275957: Flag [FLAGNAME] is not setup correctly. It is probably disabled or have no bundles configured. as duplicate