~ knotless Search/
↑↓ move↵ open⇧↵ all results

chadtmiller.com/knotless

git that lives in your Atmosphere account

knotless.dev
1 collaborator

knotless 0.13.0 Latest 2 packages, 1 image

1
10

The iOS app reports, blocks and deletes an account's data, as the pages do

Merged
Merged chadtmiller.com asked to merge into main from chadtmiller.com/knotless:ios/report-block-delete

What changes

The iOS app gains what the pages have for reporting, blocking and deleting data, using the same methods and words.

Reporting. A sheet takes why, from the same six reasons, and more in words, then sends createReport. It opens from a menu on someone else's profile, repository, pull or issue, and on someone else's comment. Nothing of one's own offers it, and it needs signing in.

Blocking. Someone else's profile has Block or Unblock in its menu. Blocked accounts, under that menu and your own profile's, lists each block with Unblock, and blocks another by handle, from all your repositories or one.

Deleting data. Delete your knotless data, in your own profile's menu, says what the account holds and which repositories are shared, with a link to transfer each on the site. Once the handle is typed it deletes a hundred at a time with progress, then signs out. A failure says that what's deleted stays deleted and that trying again carries on.

Write gains numbers, as deleteAccountData's limit is an integer. The thread's title leaves room for the new menu.

Why

Apple asks an app with what people write to let them report it and block those who write it, and external TestFlight review may look for that. An app with accounts should also offer deleting them. The owner asked for these to match the pages.

How it was checked

just ios-look for the menus on a profile and a comment, the report sheet and its sent state, Blocked accounts from both menus, and the delete sheet with the handle typed. ios/check-models.sh compiled and read 41 answers. Here its lexicon step couldn't run without npm ci in harness/, so ios.yml holds the new writes to their lexicons. The pages' flows cover what each method does on the server.

Shortcomings

No write here has reached a real server: the look tool answers for it, and these change real accounts. So the app's session isn't yet seen working with createReport, blockActor, unblockActor, listBlocks, getAccountData or deleteAccountData, though they take the pages' cookie, which is what the app sends. Delete's last step and sign-out have only run against the look tool's answer.

Hiding a pull, issue or comment, which the pages give a repository's owner, isn't here. Deleting removes knotless's data, as on the pages, not the atproto account, which lives on its PDS.

🤖 Generated with Claude Code

menu.png

rep.png

blocks.png

del.png

ck.png

Approved

This adds reporting, blocking and deleting account data to the iOS app. Reporting is on profiles, repositories, pulls, issues and others' comments. Blocking is a profile menu entry plus a Blocked accounts screen. Deleting data is a confirm-by-handle sheet that deletes 100 at a time, then signs out. I read all the changed files. The models match the defs.json viewer blocking field. Write.numbers correctly sends limit as an integer. The own-content checks hide Report as the body says, and the thread title width accounts for the new menu. I found nothing that must change. The PR says no write has reached a real server, so I couldn't check that.

One thing to harden: the loop in DeleteDataSheet.remove runs until step.done. A server answer of deleted: 0, done: false would loop forever, calling a destructive method each time. Stopping after a step that deleted nothing, with the error message, would be safer.

ios/Knotless/Views/Moderation.swiftline 336
while true {
let step = try await Client.shared.deleteStep(Writes.deleteData(did: did, limit: Self.part))
deleted += step.deleted
if step.done { break }
review.knotless.dev

This loop has no guard against a step that deletes nothing without finishing. Consider breaking with a failure when step.deleted == 0 && !step.done.

Merged as 765c51a