Skip to content

Conversation

@BlankEclair
Copy link

@BlankEclair BlankEclair commented Apr 10, 2025

This commit rewrites how srcset is parsed so that it is slightly more spec-compliant (I may have fudged the descriptor parsing since the parser is so dry to read). Unit tests are also added to make sure that regressions do not happen again.

Fixes #381

I remembered to:

  • Update or add unit tests if needed
  • Update or add documentation/comments if needed
    • There's nothing really needed to add documentation-wise, is there?
  • Made sure stray files or whitespace didn't get committed
  • If significant changes, branch from develop and set to merge into develop
    • I don't think this patch is significant enough, so I branched from master :p
  • Read the guidelines for contributing
    • I kinda eyeballed PEP 8 ^^; (I'm hoping that CI yells at me if so)

Changes:

  • Follow the spec more in terms of parsing srcset
  • Add basic unit tests for srcset parsing

This commit rewrites how srcset is parsed so that it is slightly more
spec-compliant (I may have fudged the descriptor parsing since the parser
is so dry to read). Unit tests are also added to make sure that regressions
do not happen again.

Fixes ArchiveTeam#381
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.

1 participant