Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Implement AnyNode/AnyNodeRef for FStringFormatSpec #9836

Merged
merged 1 commit into from
Feb 5, 2024

Conversation

dhruvmanila
Copy link
Member

Summary

This PR adds the AnyNode and AnyNodeRef implementation for FStringFormatSpec node which will be required in the f-string formatting.

The main usage for this is so that we can pass in the node directly to suppressed_node in case debug expression is used to format is as verbatim text.

@dhruvmanila dhruvmanila added the internal An internal refactor or improvement label Feb 5, 2024
@dhruvmanila dhruvmanila force-pushed the dhruv/format-spec-anynode branch from faa457e to 9eea4e4 Compare February 5, 2024 19:18
@dhruvmanila dhruvmanila enabled auto-merge (squash) February 5, 2024 19:18
@dhruvmanila dhruvmanila merged commit 36b7528 into main Feb 5, 2024
17 checks passed
@dhruvmanila dhruvmanila deleted the dhruv/format-spec-anynode branch February 5, 2024 19:23
Copy link
Contributor

github-actions bot commented Feb 5, 2024

ruff-ecosystem results

Linter (stable)

ℹ️ ecosystem check encountered linter errors. (no lint changes; 1 project error)

sphinx-doc/sphinx (error)

ruff failed
  Cause: Selection of unstable rules without the `--preview` flag is not allowed. Enable preview or remove selection of:
	- FURB113
	- FURB131
	- FURB132

Linter (preview)

✅ ecosystem check detected no linter changes.

Formatter (stable)

ℹ️ ecosystem check encountered format errors. (no format changes; 2 project errors)

sphinx-doc/sphinx (error)

ruff format --no-preview --exclude tests/roots/test-pycode/cp_1251_coded.py

ruff failed
  Cause: Selection of unstable rules without the `--preview` flag is not allowed. Enable preview or remove selection of:
	- FURB113
	- FURB131
	- FURB132

openai/openai-cookbook (error)

warning: Detected debug build without --no-cache.
error: Failed to parse examples/dalle/Image_generations_edits_and_variations_with_DALL-E.ipynb:3:7:8: Unexpected token 'prompt'

Formatter (preview)

ℹ️ ecosystem check encountered format errors. (no format changes; 1 project error)

openai/openai-cookbook (error)

ruff format --preview

warning: Detected debug build without --no-cache.
error: Failed to parse examples/dalle/Image_generations_edits_and_variations_with_DALL-E.ipynb:3:7:8: Unexpected token 'prompt'

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
internal An internal refactor or improvement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants