Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 6099c96

Browse filesBrowse files
committed
Add comment regarding dedent_block_string_value
1 parent a2da74c commit 6099c96
Copy full SHA for 6099c96

File tree

Expand file treeCollapse file tree

1 file changed

+5
-0
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+5
-0
lines changed

‎src/graphql/language/block_string.py

Copy file name to clipboardExpand all lines: src/graphql/language/block_string.py
+5Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@ def dedent_block_string_value(raw_string: str) -> str:
1313
1414
This implements the GraphQL spec's BlockStringValue() static algorithm.
1515
16+
Note that this is very similar to Python's inspect.cleandoc() function.
17+
The differences is that the latter also expands tabs to spaces and
18+
removes whitespace at the beginning of the first line. Python also has
19+
textwrap.dedent() which uses a completely different algorithm.
20+
1621
For internal use only.
1722
"""
1823
# Expand a block string's raw value into independent lines.

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.