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

pronouns: fetching list should also use custom backend #2599

Open
dgw opened this issue Mar 16, 2024 · 3 comments
Open

pronouns: fetching list should also use custom backend #2599

dgw opened this issue Mar 16, 2024 · 3 comments

Comments

@dgw
Copy link
Member

dgw commented Mar 16, 2024

Despite making the link_base_url customizable, the plugin is still hardcoded to fetch the actual list of pronoun sets from our repo:

r = requests.get(
'https://github.com/sopel-irc/pronoun-service/raw/main/src/lib/data/pronouns.tab')

This should be changed to use the custom backend instead, in case people want to customize the pronoun sets available through their own self-hosted instance.

Note: This might require some not-insignificant amount of work, as the site doesn't appear to expose the pronoun data in a way that's anywhere near as simple to read as the .tab file in the Git repo. The most efficient approach might be to let the user specify two values, one for the URL base and a second pointing at the plaintext pronoun list.

@dgw dgw added the Feature label Mar 16, 2024
@dgw dgw added this to the 8.1.0 milestone Mar 16, 2024
@dgw
Copy link
Member Author

dgw commented Mar 23, 2024

In the spirit of taking what should be a simple issue and making it complicated, I looked around a bit and found https://pronouns.within.lgbt/ / https://github.com/Xe/pronouns. The advantage vs. our current backend is that it actually has an API, which is relevant to this issue because there is an /api/all route that would replace fetching the .tab file from GH.

It's obviously harder for us to spin up a project-owned instance, though. Our current Svelte app pretty much Just Works if you toss the code up on Netlify or something (the static-site hosts are all pretty good at figuring out how to handle JS webapps). This alternative would require a Docker container host if we want to migrate pronouns.sopel.chat onto it.

@dgw
Copy link
Member Author

dgw commented Mar 23, 2024

Quick follow-up: I figured out how to get a free instance of Xe/pronouns running on Render in about 30 minutes. Next step would be examining the license (Edit: It's using the JSON License.) and getting permission (if needed) to maintain a fork with our own domain in the examples and our project's contact info in the error pages etc. where it appears.

Could also see if upstream is interested in making those values configurable; it all depends on their attitude toward others self-hosting their own instances (whether lower traffic to the main instance is seen as "taking away" or "load balancing", basically).

@dgw
Copy link
Member Author

dgw commented Mar 28, 2024

Upstream is totally interested in configurability. 🥳 Above issue mention is me writing out the detailed ideas, after getting preliminary buy-in via a Mastodon conversation (linked there).

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

No branches or pull requests

2 participants