Skip to content

feat: Add device id to About Mapeo screen#989

Open
gmaclennan wants to merge 5 commits intodevelopfrom
feat/device-id
Open

feat: Add device id to About Mapeo screen#989
gmaclennan wants to merge 5 commits intodevelopfrom
feat/device-id

Conversation

@gmaclennan
Copy link
Member

Not yet tested on a device.

Adds the device id to the About Mapeo screen in settings. The device ID is currently the public key of the writer hypercore for the device. This can be useful for debugging - matching the device to data in the hypercores

Comment on lines +98 to +104
<DeviceInfoListItem label={t(m.deviceId)} deviceProp="deviceId" />
<ListItem>
<ListItemText
primary={t(m.deviceId)}
secondary={displayDeviceId}
></ListItemText>
</ListItem>
Copy link
Member

Choose a reason for hiding this comment

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

list item here doesn't seem necessary if you have the DeviceInfoListItem already

Copy link
Member Author

Choose a reason for hiding this comment

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

DeviceInfoListItem is a specific wrapper for properties exposed by react-native-device-info.

Copy link
Member

Choose a reason for hiding this comment

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

ah got it 👍

Copy link
Member

Choose a reason for hiding this comment

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

tested this locally and somewhat confused about what we want to achieve with this. There are now two Device IDs being listed - one from react-native-device-info and the other from something in the backend? Question is what do we want to display in this case, and can we update the label for one of them to make it clearer about what it is?

image

Copy link
Member Author

Choose a reason for hiding this comment

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

Looks like we need a better name.

This is the public key of the device's writeable hypercore. It is useful for debugging when trying to establish which observations were created on which device. Useful when eg you are analysing a Mapeo project and find missing sparse data in particular hypercore and figuring out which device that is from.

Copy link
Member

@achou11 achou11 Oct 5, 2022

Choose a reason for hiding this comment

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

got it! makes sense after reading the original PR description. few suggestions that come off the top of my head in case any may come relatively close:

  • Device Core ID
  • Device Data ID
  • Device Hypercore ID
  • Core ID
  • Hypercore ID
  • Core Data ID

@achou11
Copy link
Member

achou11 commented Oct 5, 2022

Updated this PR to catch up with develop branch and converted AboutMapeo to TS. Still need to come up with a better label name for the device hypercore id (see #989 (comment))

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.

2 participants