From 5613aa894828bcca286d8e23f1ef99eb7d97b2df Mon Sep 17 00:00:00 2001 From: Marshall Roch Date: Sat, 16 Mar 2019 09:08:52 -0700 Subject: [PATCH] flow v0.95 Summary: 0.95 has a more accurate definition of JSON.stringify which could return void. Reviewed By: dsainati1 Differential Revision: D14494286 fbshipit-source-id: 6cf9cb5889b4078548665bc66fe899a266c689ce --- .flowconfig | 2 +- .flowconfig.android | 2 +- RNTester/js/LayoutEventsExample.js | 5 ++++- package.json | 2 +- template/_flowconfig | 2 +- yarn.lock | 27 ++++----------------------- 6 files changed, 12 insertions(+), 28 deletions(-) diff --git a/.flowconfig b/.flowconfig index 9c5e95b203c..27ebd321646 100644 --- a/.flowconfig +++ b/.flowconfig @@ -101,4 +101,4 @@ untyped-import untyped-type-import [version] -^0.94.0 +^0.95.0 diff --git a/.flowconfig.android b/.flowconfig.android index 074ee5e2269..8dd6b445668 100644 --- a/.flowconfig.android +++ b/.flowconfig.android @@ -101,4 +101,4 @@ untyped-import untyped-type-import [version] -^0.94.0 +^0.95.0 diff --git a/RNTester/js/LayoutEventsExample.js b/RNTester/js/LayoutEventsExample.js index b9e555852d6..84f38fa4897 100644 --- a/RNTester/js/LayoutEventsExample.js +++ b/RNTester/js/LayoutEventsExample.js @@ -98,7 +98,10 @@ class LayoutEventExample extends React.Component { /> ViewLayout:{' '} - {JSON.stringify(this.state.viewLayout, null, ' ') + '\n\n'} + {/* $FlowFixMe(>=0.95.0 site=react_native_fb) This comment + * suppresses an error found when Flow v0.95 was deployed. To see + * the error, delete this comment and run Flow. */ + JSON.stringify(this.state.viewLayout, null, ' ') + '\n\n'} A simple piece of text.{this.state.extraText} diff --git a/package.json b/package.json index ddc862611c0..d0be9821e84 100644 --- a/package.json +++ b/package.json @@ -125,7 +125,7 @@ "eslint-plugin-react": "7.8.2", "eslint-plugin-react-hooks": "^1.0.1", "eslint-plugin-react-native": "3.5.0", - "flow-bin": "^0.94.0", + "flow-bin": "^0.95.0", "flow-remove-types": "1.2.3", "jest": "24.5.0", "jest-junit": "6.3.0", diff --git a/template/_flowconfig b/template/_flowconfig index 7e9e9133de9..098af31aacf 100644 --- a/template/_flowconfig +++ b/template/_flowconfig @@ -66,4 +66,4 @@ suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy suppress_comment=\\(.\\|\n\\)*\\$FlowExpectedError [version] -^0.94.0 +^0.95.0 diff --git a/yarn.lock b/yarn.lock index 29397fc2914..b6aa3d6595f 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2594,13 +2594,6 @@ eslint-plugin-react@7.8.2: jsx-ast-utils "^2.0.1" prop-types "^15.6.0" -eslint-plugin-relay@0.0.28: - version "0.0.28" - resolved "https://registry.yarnpkg.com/eslint-plugin-relay/-/eslint-plugin-relay-0.0.28.tgz#dd9ba7dc03fd21f3a30e053d21d90e5bf2ecff34" - integrity sha512-CvyT/WxEQmcUKE4lVqjxgioTj3zSvHnT9bvR4cISgs9j2z4J5Ojsurjcv/kWe4I6gf6L+lV6zcVuZ2LkiRIO6g== - dependencies: - graphql "^14.0.0" - eslint-rule-composer@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/eslint-rule-composer/-/eslint-rule-composer-0.3.0.tgz#79320c927b0c5c0d3d3d2b76c8b4a488f25bbaf9" @@ -3082,10 +3075,10 @@ flat-cache@^1.2.1: graceful-fs "^4.1.2" write "^0.2.1" -flow-bin@^0.94.0: - version "0.94.0" - resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.94.0.tgz#b5d58fe7559705b73a18229f97edfc3ab6ffffcb" - integrity sha512-DYF7r9CJ/AksfmmB4+q+TyLMoeQPRnqtF1Pk7KY3zgfkB/nVuA3nXyzqgsIPIvnMSiFEXQcFK4z+iPxSLckZhQ== +flow-bin@^0.95.0: + version "0.95.1" + resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.95.1.tgz#633113831ccff4b7ee70a2730f63fc43b69ba85f" + integrity sha512-06IOC/pqPMNRYtC6AMZEWYR9Fi6UdBC7gImGinPuNUpPZFnP5E9/0cBCl3DWrH4zz/gSM2HdDilU7vPGpYIr2w== flow-parser@0.*: version "0.89.0" @@ -3320,13 +3313,6 @@ graceful-fs@^4.1.15: resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.15.tgz#ffb703e1066e8a0eeaa4c8b80ba9253eeefbfb00" integrity sha512-6uHUhOPEBgQ24HM+r6b/QwWfZq+yiFcipKFrOFiBEnWdy5sdzYoi+pJeQaPI5qOLRFqWmAXUPQNsielzdLoecA== -graphql@^14.0.0: - version "14.1.1" - resolved "https://registry.yarnpkg.com/graphql/-/graphql-14.1.1.tgz#d5d77df4b19ef41538d7215d1e7a28834619fac0" - integrity sha512-C5zDzLqvfPAgTtP8AUPIt9keDabrdRAqSWjj2OPRKrKxI9Fb65I36s1uCs1UUBFnSWTdO7hyHi7z1ZbwKMKF6Q== - dependencies: - iterall "^1.2.2" - "growl@~> 1.10.0": version "1.10.5" resolved "https://registry.yarnpkg.com/growl/-/growl-1.10.5.tgz#f2735dc2283674fa67478b10181059355c369e5e" @@ -3911,11 +3897,6 @@ istanbul-reports@^2.1.1: dependencies: handlebars "^4.1.0" -iterall@^1.2.2: - version "1.2.2" - resolved "https://registry.yarnpkg.com/iterall/-/iterall-1.2.2.tgz#92d70deb8028e0c39ff3164fdbf4d8b088130cd7" - integrity sha512-yynBb1g+RFUPY64fTrFv7nsjRrENBQJaX2UL+2Szc9REFrSNm1rpSXHGzhmAy7a9uv3vlvgBlXnf9RqmPH1/DA== - jest-changed-files@^24.5.0: version "24.5.0" resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-24.5.0.tgz#4075269ee115d87194fd5822e642af22133cf705"