logseq / publish-spa

A github action and CLI to publish logseq graphs as a SPA app
MIT License
244 stars 14 forks source link

Missing non-public pages despite enabling "All pages public when publishing" in settings #41

Closed reubenjohn closed 3 weeks ago

reubenjohn commented 3 weeks ago

What Happened?

When viewing the files generated by publish-sma in my browser (served using python -m http.server), I only see the 14 pages that I explicitly marked as public. However, I expected to see all 101 pages of my graph, because I enabled the "All pages public when publishing" setting.

When viewing the standalone HTML file generated from the logseq windows application, I see all 101 files.

Reproduce the Bug

  1. Create a new graph
  2. Create a page in the graph. Make sure it is not public.
  3. Go to Settings > Editor. Enable "All pages public when publishing".
  4. Go to Export > "Export public pages"
  5. View the generated HTML file in browser. Under "All Pages", you should see your page.
  6. Next, generate the site using publish-spa.
  7. Serve the generated files (eg. cd generated-folder && python -m http.server -> defaults to port 8000)
  8. Visit localhost:8000 (or wherever else you served the files). Under "All Pages", you won't see your page.

Expected Behavior

I expected pages to be exported even though they weren't explicitly marked as public because the All pages public when publishing toggle was turned on.

Desktop or Mobile Platform Information

Linux reubjohn-linux 5.4.0-187-generic #207~18.04.1-Ubuntu SMP Thu Jun 13 15:01:12 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux

LOGSEQ_PUBSPA_VERSION=0.3.1 LOGSEQ_VERSION=0.10.6

reubenjohn commented 3 weeks ago

I was being stupid. I didn't pull my graph after updating the settings.