facebook / facebook/relay

"Encountered two children with the same key" bug

Open
#2,433 4 comments 0 reactions 0 assignees View on GitHub
wontfix
Dominant language
Rust
Stars
19k
Forks
1.9k
PR merge metrics
No merged PRs in 30d

Description

This is an old bug. Probably fixed in https://github.com/facebook/relay/pull/2349

When I add two items with the same text prop, Relay will warn. I am not doing anything special in http://github.com/este/este.

It's clientMutationID thing. Care to comment, please?

```
warning.js?6327:33 Warning: Encountered two children with the same key, `cjgmunj9x000j0756vwy1p6uv`. Keys should be unique so that components maintain their identity across updates. Non-unique keys may cause children to be duplicated and/or omitted — the behavior is unsupported and could change in a future version.
in div (created by View)
in View (at Webs.js:18)
in Webs (created by Relay(Webs))
in Relay(Webs) (at index.js:25)
in Authenticated (at index.js:67)
in div (created by View)
in View (at Page.js:84)
in PageBody (at Page.js:159)
in div (created by View)
in View (created by ScrollView)
in div (created by View)
in View (created by ScrollViewBase)
in ScrollViewBase (created by ScrollView)
in ScrollView (at Page.js:71)
in PageContainer (at Page.js:157)
in Page (at withIntl.js:19)
in WrapperComponent (created by InjectIntl(WrapperComponent))
in InjectIntl(WrapperComponent) (created by Relay(InjectIntl(WrapperComponent)))
in Relay(InjectIntl(WrapperComponent)) (at index.js:62)
in Index (at index.js:90)
in RelayProvider (at index.js:89)
in ErrorPopupProvider (at index.js:88)
in IntlProvider (at index.js:79)
in App (created by Container)
in AppContainer (created by Container)
in Container (created by App)
in App
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.