Skip to content

Conversation

@charliemirabile
Copy link
Contributor

Remove only instance of JS on website I am aware of, and slightly tweak when feedback is revealed to hopefully make CI less flaky.

We wanted to create a website without javascript but we used an `onclick`
handler that modifies `location.href` in order to navigate to `/logout`
when clicking the logout button. Instead, just make the button submit a
form that performs GET on `/logout`. This makes logging out possible
within e.g. `lynx` (currently the button does nothing an a message
indicating that the button is unsupported is displayed).
Right now the second count needs to increment after the deadline passes
before the feedback is revealed when in fact the border should be right
when the second of the deadline starts. Fix by switching from `<` to `<=`.

This should also make CI less flaky since even though we wait for the
processing to finish, if it is started early within a given second and
finishes within that second and the curl is able to run it might be able
to catch the old generic feedback before the second advances and the
detailed feedback is revealed.
Lynx aggressively caches pages which means that an outdated version of the
login page might be displayed (showing the user as logged in when they
aren't or vice versa). Use `Cache-Control: no-cache` which makes lynx not
store the page and always fetch it. (Technically no-store would be better,
but I don't think lynx recognizes it)
Copy link
Contributor

@theyoyojo theyoyojo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@theyoyojo theyoyojo merged commit 733decc into master Dec 4, 2025
1 of 2 checks passed
@theyoyojo theyoyojo deleted the misc_fixes branch December 4, 2025 18:18
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

Successfully merging this pull request may close these issues.

3 participants