Link Archive for Edited Posts?

@manton @sod I’ve been working on editing a bunch of posts on one of my sites that didn’t get all their metadata imported (due to the way it was being stored by a WordPress plugin). Part of this is adding links to the posts.

It appears that edited posts don’t trigger the link archive mechanism. (I am on the Premium plan.) Could there be a way to manually trigger the link archives? This would be really useful as this particular blog has gone through some horrendous bouts of link rot in the past.

I just edited a non-links post on my test blog, added a link, and it archived successfully. So I think it’s at least supposed to work. Could you share a couple of URLs that aren’t working for you? Also, are you editing on the web or in one of the apps?

Both… I do the main editing locally in Obsidian, and use a plugin to update the post. But then I go in on the web back end to add the summary and add alt text to the images.

Here’s one: Mikael Fyrek: I Step Into The Advent

Okay, thanks. I took one of the URLs in that blog post (https://www.kahvi.org/releases.php?release_number=276?release_number=276) and added it to my test blog by editing one of my existing posts, and that triggered an archiving (https://micro.blog/archives/9493240).

So this is probably tied to your workflow somehow. Maybe archiving isn’t triggered when a post is edited through the plug-in? Or maybe you’re hitting some kind of cooldown? I have a vague memory of there being a cooldown period on the archiving so that it can’t be misused, archiving the same URL again and again.

Just theories, though. I think @manton is the only one who can tell you exactly what’s going on here.

I had to double-check too because this isn’t well documented. There are a few of cases where we don’t archive the links:

  • At most every 5 minutes.
  • If a specific URL has already been saved, we won’t save it again the same day.
  • Imported posts are skipped. :slightly_frowning_face:

I have a feeling the last one is really the problem here. I put the limit in place because I was worried about someone importing 10k posts and there being a larger cost for us to save everything.

I’m going to loosen this restriction so that even for imported posts, if a post is edited, we will archive the links anyway. I’ll roll that change out later today.

Are the imported posts somehow flagged on the back end so they don’t archive? That would make sense as I imported over 400 posts (this was the site that I needed to set up all the redirects for).

If that is the case, maybe a “simple” solution would be to remove the flag when a post is edited through the back end? I can only manually touch a maximum of 50 posts/day, so that might not be a big drag on the system.

New posts I’ve been creating in Obsidian have Archive Links when they are posted. So that isn’t the case. @manton has the right scenario here: these posts were all imported from my WordPress site. It makes sense that he’d want to rate-limit the archiving since scanning and archiving the links in 400+ posts could be a big hit. (Especially if someone opened an account and imported a bunch of spam posts with 100’s of links in them…)

I’ve finished making that change so that when edited, even imported posts do save the archived links. @unattributed — When you are done editing posts and getting everything how you want it, why don’t you send us a quick email at help@micro.blog and I will manually archive links for all 400 posts for your blog.

1 Like

Can confirm: the post I just updated via the API had its link(s) archived.

If it’s any consolation, as I go through an edit these posts I’m reducing the amount of media storage needed. By the time I’m done it’ll be down to ~87 Meg (of course it was only around a Gig to begin with… :smiley: )

A semi-related issue. When my posts were imported I hadn’t set up my domain on my site. So the posts were imported with the initial sub-domain:

https://cerebralrift.micro.blog/2013/03/23/dubrajah-ethnic-profound/

After setting up my domain, the front end shows the correct address:

https://cerebralrift.cc/2013/03/23/dubrajah-ethnic-profound/

Once edited, sometimes the backend starts shows the second address, sometimes not. It’s generally not a big deal, but if I need to re-edit a post and publish an update via the API I sometimes have to switch URL’s to post the update.