Skip to content

Commit

Permalink
Shorten relay read time resolver key prefix
Browse files Browse the repository at this point in the history
Reviewed By: evanyeung

Differential Revision: D68988060

fbshipit-source-id: 0cf31cf58d779572a4e8bdadf339595826756506
  • Loading branch information
tyao1 authored and facebook-github-bot committed Feb 4, 2025
1 parent 203d8b1 commit a5d6b23
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/react-relay/__tests__/LiveResolvers-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -1506,7 +1506,7 @@ describe('client-only fragments', () => {
expect(() => {
GLOBAL_STORE.dispatch({type: 'INCREMENT'});
}).toThrowError(
'Unexpected LiveState value returned from Relay Resolver internal field `RELAY_RESOLVER_LIVE_STATE_VALUE`. It is likely a bug in Relay, or a corrupt state of the relay store state Field Path `counter_suspends_when_odd`. Record `{"__id":"client:1:read_time_resolver:counter_suspends_when_odd","__typename":"__RELAY_RESOLVER__","__resolverError":null,"__resolverValue":{"__LIVE_RESOLVER_SUSPENSE_SENTINEL":true},"__resolverLiveStateDirty":true}`.',
'Unexpected LiveState value returned from Relay Resolver internal field `RELAY_RESOLVER_LIVE_STATE_VALUE`. It is likely a bug in Relay, or a corrupt state of the relay store state Field Path `counter_suspends_when_odd`. Record `{"__id":"client:1:$r:counter_suspends_when_odd","__typename":"__RELAY_RESOLVER__","__resolverError":null,"__resolverValue":{"__LIVE_RESOLVER_SUSPENSE_SENTINEL":true},"__resolverLiveStateDirty":true}`.',
);
// $FlowFixMe[incompatible-use]
expect(renderer.toJSON()).toEqual('Loading...');
Expand Down
2 changes: 1 addition & 1 deletion packages/relay-runtime/store/RelayStoreUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ const ERRORS_KEY: '__errors' = '__errors';
const MODULE_COMPONENT_KEY_PREFIX = '__module_component_';
const MODULE_OPERATION_KEY_PREFIX = '__module_operation_';

const RELAY_READ_TIME_RESOLVER_KEY_PREFIX = 'read_time_resolver:';
const RELAY_READ_TIME_RESOLVER_KEY_PREFIX = '$r:';

function getArgumentValue(
arg: NormalizationArgument | ReaderArgument,
Expand Down

0 comments on commit a5d6b23

Please sign in to comment.