Roam-Research / issues

Roam Research - A note-taking tool for networked thought.
https://roamresearch.com/
304 stars 7 forks source link

[Export/Import] Block-Level Back-References Are Not Preserved (redux) #588

Open pmbauer opened 3 years ago

pmbauer commented 3 years ago

Describe the bug

Restoring a graph from a backup does not preserve block-level back-references.

Note that the new EDN backup/restore flow does not cover this use case and there are still multiple bugs exporting and restoring subsets of a graphs as exported from All Pages.

This bug impacts block-level back references and calculations.

To Reproduce

Download this minimal repro graph and extract. Roam-Export-1595945469902.zip.

It contains two pages: [[Concept A]] [[Concept B]]

[[Concept A]] contains a block reference to a block in [[Concept B]], text Lorem ipsum

Steps to reproduce the behavior:

  1. import the minimal repro graph into any roam database
  2. Go to [[Concept B]]
  3. We expect a button next to the block with the count "1". There is a page-level back-reference to [[Concept A]] but the block level back-reference on the block Lorem ipsum is missing.
  4. Go to [[Concept A]] and edit the block containing the block reference to Lorem ipsum (e.g. add a space and delete it).
  5. Go to [[Concept B]]. Observe the previously missing block-level back reference is present.

System Information:

Additional context Export/Import related bugs (now closed, but still impacted)

This also impacts calculations. After importing blocks with calculations, the computed values are wrong. You have to make a minor edit to every calculation block to make it show the correct value.