generated RSS not a match for Nitter
Closed this issue · 9 comments
I'm assuming (since the base script came from a Nitter issue) that you're aiming to have this work in place of a Nitter instance. :-)
I've been using Nitter to feed RSS to an instance of pleroma-bot; this is the input to a pleroma instance made of of accounts that mirror Twitter accounts, so folks can follow them from a Mastodon client.
Putting this server in place of Nitter should, in theory, just work; life never really matches up with theory though.
The pleroma-bot is barfing on the RSS from this server. The only difference in the "item" blocks seems to be that Nitter has:
<dc:creator>@EFF</dc:creator>
in each block and this server doesn't.
("@EFF" being the Twitter account I'm comparing.)
Would it be simple for you to add that attribute?
Sure, you can go ahead an add that in server.ts
. No need to create a separate "flavour" for it since it isn't likely to break anything.
I'd never heard of Typescript till I was figuring out how to make this run; I'm very much a sysadmin, not a dev. So this may be a bit barbaric. :-)
To hazard a guess, it'd be adding a line to:
feed.item({
maybe something along the lines of:
dc:creator: username,
?
(I'll try a few things on my local install and get back to you.)
TypeScript is just JavaScript with some extra syntax here and there. It gets transpiled down to JS after typechecking. 🙂
Probably 'dc:creator': username
, yes. If not, the docs will be the place to look.
Yay!
I found a way that works, and is ingested all the way through to the Mastodon client. Tweets are flowing through https://twitter.oksocial.net/main/public again. :-)
It was adding:
custom_elements: [ {'dc:creator': username}],
to feed.item (I put it between date and description).
I'm not much of a git user either, but I'll see if I can figure out how to submit it as a patch in a suitably github-y way. :-)
(Thanks for setting this up; it helps me a lot.)
Nice! Just click the pencil button here to edit the file and submit a PR.
Can you make sure the whitespace around the brackets looks like this? [{ 'dc:creator': username }],
Sorry; didn't see your note about whitespace till after I did the pull request; thanks for fixing it.
No problem! Just to double check something I didn't notice until after I merged it, was it supposed to be sdc
or dc
?
It's dc; darn. I fatfingered that.
I sent another pull request with that fixed. Apologies.
Thanks for your help! Glad we got it sorted. 😄