Skip to content

Conversation

@danfinlay
Copy link
Contributor

Replaces #5935.

Hides that feature (which doesn't make sense until we have mobile) behind a hidden feature flag.

Adds the ability to set feature flags from the background console using this method:

/*
* @method
* Sets a feature flag to the `enabled` value.
* @param { String } featureName - The unique name for the feature.
* @param { Boolean } enabled - Whether the feature should be enabled.
*/
function setPreference (featureName, enabled) { /* implementation */ }

You can try it out by entering setPreference('mobileSync', true) in the background console, which will add a new button to the bottom of the settings view.

@brunobar79 brunobar79 mentioned this pull request Jan 30, 2019
Copy link
Contributor

@brunobar79 brunobar79 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding this comments so I can address before we decide to merge this in

@brunobar79 brunobar79 changed the title Feature flag mobile sync [WIP] Feature flag mobile sync Jan 30, 2019
@brunobar79 brunobar79 added the DO-NOT-MERGE Pull requests that should not be merged label Jan 30, 2019
@metamaskbot
Copy link
Collaborator

Builds ready [51b826f]: mascara, chrome, firefox, edge, opera

@metamaskbot
Copy link
Collaborator

Builds ready [42cb688]: mascara, chrome, firefox, edge, opera

@metamaskbot
Copy link
Collaborator

Builds ready [0f55566]: mascara, chrome, firefox, edge, opera

@brunobar79 brunobar79 changed the title [WIP] Feature flag mobile sync Feature Flag + Mobile Sync Feb 20, 2019
@brunobar79 brunobar79 added needs review and removed DO-NOT-MERGE Pull requests that should not be merged labels Feb 20, 2019
@brunobar79 brunobar79 removed the request for review from alextsg February 20, 2019 01:31
@brunobar79 brunobar79 dismissed their stale review February 21, 2019 00:14

I can't review myself lol

@danfinlay
Copy link
Contributor Author

There's an important item to note with this feature: Since it hangs a method on the global namespace, preferences managed are highly exposed to all dependencies, so we should make sure that none of the preferences have any potential for abuse by a malicious dependency.

@danfinlay
Copy link
Contributor Author

Ok I've pushed up some comments to help encourage correct future use of the feature flags hash. I'm ok with this being merged if someone approves it now.

@metamaskbot
Copy link
Collaborator

Builds ready [457c831]: mascara, chrome, firefox, edge, opera

@metamaskbot
Copy link
Collaborator

Builds ready [99a3c5c]: mascara, chrome, firefox, edge, opera

Copy link
Contributor

@whymarrh whymarrh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Two small things:

  1. The noted regression (?) in the PreferencesController
  2. The changes to the package-lock.json file should probably be dropped and re-added, I'm seeing this PR downgrade the version of json-rpc-engine we're pinned to from 3.8.0 to 3.7.3 which doesn't seem correct.

featureFlags: {
betaUI: true,
skipAnnounceBetaUI: true,
},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should drop this addition before merging as this seems to be a regression

@metamaskbot
Copy link
Collaborator

Builds ready [c2c56f0]: mascara, chrome, firefox, edge, opera

Copy link
Contributor

@whymarrh whymarrh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks fine to me

@whymarrh whymarrh merged commit f507f2a into develop Feb 25, 2019
@whymarrh whymarrh deleted the FeatureFlagMobileSync branch February 25, 2019 19:10
@guix77
Copy link

guix77 commented May 22, 2019

@danfinlay on MM 6.5.3 (FF + Chrome) under Settings > Advanced, the mobile sync is not hidden any more. Does not help with confusion about the "release" of the mobile app medias talked about and malware fake apps :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants