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

[WIP, reproduced as failing test] Fix HTMLCS issue affecting <input autocomplete="username"> with implicit type #698

Draft
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

danyalaytekin
Copy link
Member

@danyalaytekin danyalaytekin commented Mar 18, 2024

Adding a failing test to draft PR.

Remote manual test case

nvm install 20
npx \
    pa11y/pa11y#fix-691-including-username \
    http://doctors.mystewardhealthcare.org/user/login

Domain from #691

Notes

@danyalaytekin danyalaytekin added type: bug status: work required Issues or PRs that are incomplete and require work labels Mar 18, 2024
@danyalaytekin danyalaytekin added this to the 8.x milestone Mar 18, 2024
@danyalaytekin danyalaytekin self-assigned this Mar 18, 2024
@danyalaytekin
Copy link
Member Author

As described above this issue appears to be caused by a html_codesniffer@2.5.1 bug that was fixed in their default branch sometime between 2020-2022 but hasn't been released. I can think of two options:

  1. Use patch-package to patch html_codesniffer@2.5.1 after installation, but we'd be patching the entire built file, which has most of its functionality on one line, so the patch will be deleting that line (several hundred KB) and replacing it with the patched line, which doesn't seem ideal (example with only a few characters patched).
  2. (My preference) Soft fork to pa11y/HTML_CodeSniffer and build from there, cherry picking a few fixes, until the project returns to life.

What do you think @aarongoldenthal @hollsk @josebolos @jpw, and can you think of any other options?

@aarongoldenthal
Copy link
Contributor

As described above this issue appears to be caused by a html_codesniffer@2.5.1 bug that was fixed in their default branch sometime between 2020-2022 but hasn't been released. I can think of two options:

  1. Use patch-package to patch html_codesniffer@2.5.1 after installation, but we'd be patching the entire built file, which has most of its functionality on one line, so the patch will be deleting that line (several hundred KB) and replacing it with the patched line, which doesn't seem ideal (example with only a few characters patched).
  2. (My preference) Soft fork to pa11y/HTML_CodeSniffer and build from there, cherry picking a few fixes, until the project returns to life.

What do you think @aarongoldenthal @hollsk @josebolos @jpw, and can you think of any other options?

The soft fork seems like the lesser of two evils (although I do wonder if the project will return to life 🤔)

@hollsk
Copy link
Member

hollsk commented Mar 19, 2024

Yes, I was working up a "state of the project" doc yesterday and noted the lack of activity on HTML_CS then too, and I agree that its future seems uncertain.

I'm also leaning towards soft fork, though I do wonder where that leaves Pa11y over the long term. In theory we could probably replace it with a different rules engine (WebAIM's WAVE, maybe), but that'd be a longer-term decision than here. Soft fork will buy us some time to decide in any case.

@Zauberbutter
Copy link

I am gratefully using pa11y together with vNu and a link checker library to provide an internal website quality assurance service. Sadly I don't have the time to develop the service to a open source one, but I have some ideas. So I just want to share some libraries with you, maybe they will be useful for further development of pa11y or the deprecation of htmlcs:

@danyalaytekin danyalaytekin changed the title [WIP, reproduced as failing test] Support pages containing <input autocomplete="username"> [WIP, reproduced as failing test] Support pages containing <input autocomplete="username"> (implicit type) Mar 21, 2024
@danyalaytekin danyalaytekin changed the title [WIP, reproduced as failing test] Support pages containing <input autocomplete="username"> (implicit type) [WIP, reproduced as failing test] Fix HTMLCS issue affecting <input autocomplete="username"> with implicit type Mar 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: work required Issues or PRs that are incomplete and require work type: bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Certain pages result in "Cannot read properties of undefined (reading 'replace')"
4 participants