Only some files import as nodes

I have a good number of org files converted from markdown via pandoc in my org-roam-directory but only one note actually shows up in my org-roam even after running db-sync and migrate-wizard (upon recommendation from another thread). The note that does show up was made with org-roam-capture so really it’s all the imported notes that aren’t appearing.

First thing you would like to check: do the converted Org files have an ID property? Either at the file level or in any of the headlines in the file. I don’t believe Pandoc automatically adds one.

Yes they do have ID properties already. Looks like migrate-wizard handles that.

If this is the case, I’d:

  1. Run org-roam-update-org-id-locations
    Note how many files and IDs it worked on.

  2. Run org-roam-db-sync again (after 1).

I don’t think you’d need to do C-u org-roam-db-sync (this forces db rebuild as the doc string says), but if 2 does not work, you can try it too.

If this procedure does not work, then I’d start edbug the program to inspect what’s really happening in runtime (hopefully you don’t have to do this).

It said 61 notes scanned, 61 files contain IDs and running db-sync again didn’t result in the program finding any notes.

I guess one last thing:

  • Do your files have title?
  • How do you see the notes (referring to the quotes part above)? – step-by-step with commands/functions you use

You say the captured ones show up correctly.

If you use capture to create a new note/file, and copy-and-pasted the text content of one of the files (and leave out the old ID), it should show up.

What’s the difference between the converted one and the newly created one by copy-and-paste?

Sorry, one more. If the file name (the full absolute file like ~/Documents/org-roam/this/is/my/ contains data/ in it, Org-roam by default excludes the file.

It’s defined in org-roam-file-exclude-regexp.

It’s weird. You have ID, title, and it’s an Org file. Captured files work. Then Org-roam seems to be working fine.

Oh! it was the missing title all along! adding titles fixed the issue. thank you!

1 Like