-
Notifications
You must be signed in to change notification settings - Fork 334
WPB-21964: move feature flags logic to wire-subsystems #4941
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
base: develop
Are you sure you want to change the base?
WPB-21964: move feature flags logic to wire-subsystems #4941
Conversation
battermann
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please add a changelog
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
does this have to stay in galley? why?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It depends on things only definable in galley, such as Opts.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That alone is solvable by extracting a dedicated config for the subsystem. Are there still other reasons?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems so, but it is the wrong tradeoff.
Pros:
- interpreters and effects are co-located (for one usage)
Cons:
- high coupling of
galleywith all packages depending onwire-subsystems - low cohesion, as all changes will impact all the dependant packages
Having separated effects definitions/interpreters, enforcing high cohesion and low coupling, is the purpose of effects systems.
| global <- inputs (view $ settings . checkGroupInfo) | ||
| guard (global == Just True) | ||
| mls <- getFeatureForTeam @MLSConfig tid | ||
| mls <- getFeatureForTeam @_ @MLSConfig tid |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we change the order of the type parameters so that we do not have to pass a placeholder type?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure, it's polysemy defined
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just tried with foralls at effect level, it does not work
| SConversationMemberUpdateTag -> do | ||
| void $ ensureOtherMember lconv (cmuTarget action) conv | ||
| E.setOtherMember lcnv (cmuTarget action) (cmuUpdate action) | ||
| let action' = action :: ConversationMemberUpdate |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this suddenly necessary?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When making the change, GHC was unable to properly infer it, I do not know why (I welcome any idea), this is the workaround I have found.
|
@akshaymankar @battermann I have moved the interpreters in |
Checklist
changelog.d