Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Quote text is never set #35

Open
philgyford opened this issue Apr 10, 2022 · 2 comments
Open

Quote text is never set #35

philgyford opened this issue Apr 10, 2022 · 2 comments

Comments

@philgyford
Copy link

Webmention has a quote field but, as far as I can tell, it's never set.

I assume it would be good to set it in mentions.tasks.incoming_webmentions.process_incoming_webmention() using a tweaked _update_wm() function, but I'm not sure if you have in mind what text the quote should be?

Maybe use BeautifulSoup to try a few ways of getting something representative from the source page? Maybe grab the .e-content's content (falling back to.h-entry, then trying <main>, then trying the meta description?), and then use the HTML-stripped, start of that?

@beatonma
Copy link
Owner

I'm not sure if you have in mind what text the quote should be?

Not really. I think I added it with the intention of the user (at the time, myself) manually picking whatever excerpt they liked and adding it in the admin pages.

I think it's worth exploring this though. Getting the right context for a mention might be tricky for a general case but your suggestions sound reasonable.

P.S. Thanks for this and the other recent issues - I'm focussing on another project at the moment but will get back to this asap to sort them out!

@beatonma
Copy link
Owner

(This one hasn't been touched yet but now that the more problematic issues are fixed in 3.0.0 I'll try and do something with it)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants