Skip to content

Conversation

@lwjohnst86
Copy link
Member

Description

Very small fix to use properties in read_json().

Needs a quick review.

Checklist

  • Ran just run-all

@lwjohnst86 lwjohnst86 requested a review from a team as a code owner October 28, 2025 09:00
@lwjohnst86 lwjohnst86 changed the base branch from feat/implement-error-true-argument to main October 28, 2025 09:03
@lwjohnst86 lwjohnst86 marked this pull request as draft October 28, 2025 09:03
@lwjohnst86 lwjohnst86 moved this from Todo to In Progress in Iteration planning Oct 28, 2025
@lwjohnst86
Copy link
Member Author

I messed up, this has commits from another PR. Will wait until that one is merged before converting this one to be ready for review.

@lwjohnst86 lwjohnst86 moved this from In Progress to In Review in Iteration planning Nov 4, 2025
@lwjohnst86 lwjohnst86 marked this pull request as ready for review November 4, 2025 10:35
@martonvago
Copy link
Contributor

Sorry, are you waiting on me for this?

@lwjohnst86
Copy link
Member Author

@martonvago yes! Or someone 😛

Copy link
Contributor

@martonvago martonvago left a comment

Choose a reason for hiding this comment

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

Nice!!

"""
try:
descriptor: Any = loads(path.read_text())
properties: dict[str, Any] = loads(path.read_text())
Copy link
Contributor

Choose a reason for hiding this comment

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

But the return type of loads is Any, right? So we can't assert here that it's a dict. (That's why we are checking it later on.)

Suggested change
properties: dict[str, Any] = loads(path.read_text())
properties: Any = loads(path.read_text())

) from None # To hide the original traceback

if not isinstance(descriptor, dict):
if not isinstance(properties, dict): # pyright: ignore
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
if not isinstance(properties, dict): # pyright: ignore
if not isinstance(properties, dict):

Or what is it complaining about?

@github-project-automation github-project-automation bot moved this from In Review to In Progress in Iteration planning Nov 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: In Progress

Development

Successfully merging this pull request may close these issues.

3 participants