❤️ It's great to see you here! I'm currently available on evenings and weekends for consulting and freelance work. Let's chat about how I can help you achieve your goals.
🚀 The Background
Initially I offered only GitHub authentication, which makes the service available to a large group of people, but it excludes folks who don’t already have a GitHub account. I wanted to expand the reach of the site and for this reason OAuth2 authentication via GitLab and Google is now also available. This new setup allows you to add multiple identities to your account.
Once you are logged in, you can add additional identities on your profile page.
This means that you can have one account which allows you to log in via GitHub, Google and GitLab. That leaves some you options in case you lose access to one of your accounts etc.
If you’re signing in for the first time, start with the OAuth2 provider of your choice on the signup page:
The Technical Stuff
I implemented the authentication via https://metacpan.org/pod/Mojolicious::Plugin::OAuth2. I was previously using https://metacpan.org/pod/Mojolicious::Plugin::Web::Auth, which is quite handy in that it will fetch user info for you after completing authentication, but it has a bug in the Google implementation and the last release was in 2019.
Initially I thought about sending a pull request to
Mojolicious::Plugin::Web::Auth and asking the author for a new release, but
Mojolicious::Plugin::OAuth2 supports mocking, which is really handy in my testing flow. I can now do proper, mocked logins and account creation in both Perl tests and my Playwright tests. It ended up being a better fit for me. My test coverage went up as well.
Codecov tells me that my coverage is currently over 95%, so I’m able to deploy changes with a lot of confidence right now.
Give it a Try
If you already have a https://www.prettygoodping.com account, feel free to add more identities to it. If you don’t have one yet, please sign up for the Beta and let me know what you think at GitHub or via email@example.com.