← Back to Feed
retoor
retoor · Level 57680
devlog

Minor update, api affected

@Lensflare

● A visibility status for posts, gists, projects and news, so an owner can temporarily pull content back without deleting it.
The four statuses

  • published (default): listed everywhere and open to everyone.
  • hidden: removed from feeds, search, topics, profiles and the sitemap, but still opens by direct link (marked noindex).
  • offline: only the owner and administrators can open it; everyone else gets a 404 and cannot comment, vote, react or bookmark it.
  • draft: same access as offline. The API accepts it, but the UI does not offer it yet.

Where it shows up

  • Specification: one module, devplacepy/database/visibility.py. Existing rows need no migration, because a missing value counts as published.
  • Owner controls: a bar on the post, gist and project pages, and a Visibility select in the create and edit forms.
  • Endpoints: POST /posts/visibility/{slug}, /gists/visibility/{slug} and /projects/{slug}/visibility. Only the owner can use them.
  • News: administrators set a news article's status from the admin news page, using the existing status column.
  • Devii: four new tools, set_post_visibility, set_gist_visibility, set_project_visibility and admin_set_news_visibility.
  • Audit and docs: each change is recorded as <kind>.visibility.set. I updated the API docs, added /docs/content-visibility.html, and updated the README, events.md and the CLAUDE.md
    files.

Testing

  • I wrote unit, API and end-to-end tests, and they pass.
  • I ran only targeted tests, as you asked, not the full suite.
  • The dev server is running it and the main pages return 200.

I fixed one bug along the way: my first version created empty posts, gists and projects tables on a fresh database, which broke the feed and sitemap.

so please check the ios app if everything still works.

I am currently working on: https://molodetz.nl/repos/TOSV
and https://molodetz.nl/repos/templewm

Comments

retoor retoor

Oh, also the link emoji on this page is fixed!

retoor retoor

so please check the ios app if everything still works.

Lensflare Lensflare

Looks like workii workii so far

retoor retoor

Perfect. Thanks for testing..

retoor retoor

Consider to add the field. Thanks to the field we can do darkrant like stuff. Private rants. Basically your own secret devplace. If you want to exchange some top secret source or something else, this is the way to go.

Lensflare Lensflare

Tbh I don’t see the point of putting secrets into a public forum, securing them only by obscurity.
That’s what private messages are for.

retoor retoor ↳ @Lensflare

Yeah, in the darkrant times, there were no private messages. But now you can have offtopic discussion threads. It's just a feature. It's not for excluding people. That's the last thing I would ever do.