Skip to content

"You're leaving Lichess" popup also applies to shortened Lichess URLs #16445

@Naphthalin

Description

@Naphthalin

Thanks to #14511 we (the Lc0 devs) can provide direct challenge links for the Leela piece odds bots. Ideally, we'd put challenge links for all accepted positions into the bot description, so Lichess users can directly profit from that feature without leaving lichess.org.

Due to the character limit in profile descriptions, this allows max. 3 challenge links, which works for https://lichess.org/@/LeelaQueenOdds (since there is only 1 position per side), https://lichess.org/@/LeelaQueenForKnight (only the b1/b8 knight gets removed), https://lichess.org/@/RookOdds (only the queen side rook gets removed) for chess related reasons. For https://lichess.org/@/LeelaKnightOdds we only provide the links for playing as black, while users have to visit the linked blog post for playing as white (or manually insert the FEN). This affects how the bots are used by Lichess users: only 3% of knight odds games are played as white, compared to 39% for rook odds, 32% for queen for knight odds, and 57% for queen odds.

We're currently in the process of completing the family with https://lichess.org/@/LeelaPieceOdds, accepting (almost) every reasonable or thinkable setup from white giving double knight odds up to black giving queen+rook+rook odds (14 combinations). To fit challenge links into the bot description, we're currently using shortened lichess challenge URLs, hosted on https://lc0.org, for example https://lc0.org/QNN redirecting to https://lichess.org/?user=LeelaPieceOdds&fen=rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/R1B1KB1R_w_KQkq#friend (in total 2x14x10=280 characters). This however triggers the "you're leaving Lichess" warning popup, despite linking back to lichess.org, which doesn't provide an ideal user experience.

This issue would be resolved by any of the following solutions:

  • for shortened URLs and known providers, check the redirection URL instead/on top of the original URL
  • generally allow links in profile descriptions (possibly only to lichess.org, or allowlisted URLs), and don't count the URL to the character limit, only the text
  • add https://lc0.org to the allowlist in
    `lichess.org lichess4545.com ligacatur.com
    github.com discord.com discord.gg mastodon.online
    twitter.com facebook.com twitch.tv
    wikipedia.org wikimedia.org
    chess24.com chess.com chessable.com
    `.split(/[ \n]/);
    to suppress the popup, with the knowledge that these are shortened URLs
  • make an exception to the 400 character limit (though this wouldn't be practical without also allowing hyperlinks)

We can of course understand if neither of these solutions suit your general approach, and you're fine with confusing (and possibly desensibilizing) users why there is a popup if they aren't leaving lichess.

Thanks a lot for all your work!

Best regards,
Naphthalin

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions