Skip to content

Comments

Fix linter issues in jsonld.py#244

Open
mielvds wants to merge 1 commit intoformat-canonfrom
linter-jsonld
Open

Fix linter issues in jsonld.py#244
mielvds wants to merge 1 commit intoformat-canonfrom
linter-jsonld

Conversation

@mielvds
Copy link
Collaborator

@mielvds mielvds commented Feb 16, 2026

This PR fixes the ruff linter issues in jsonld.py. Formatting is not yet applied to keep the changes acceptable.
Notable changes:

  • rename some internal parameters from camelCase to pythonic, e.g., requestProfile to request_profile. Keys in options dict are kept of course to not introduce breaking changes.
  • replace mutable defaults in function parameters with None and initiated them inside the function (no idea why ruff does not like this)
  • prefix unused loop variables with _
  • merged a couple of nested if statements
  • added a stacklevel to logged warnings
  • changed some old string formatting to f-strings or ''.format()

@github-actions
Copy link

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.

2 participants