Skip to content

Commit 05befd4

Browse files
authored
CLN: Format doc code blocks (#36700)
1 parent 1e1857f commit 05befd4

File tree

9 files changed

+385
-352
lines changed

9 files changed

+385
-352
lines changed

doc/source/development/code_style.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,5 +172,6 @@ Reading from a url
172172
.. code-block:: python
173173
174174
from pandas.io.common import urlopen
175-
with urlopen('http://www.google.com') as url:
175+
176+
with urlopen("http://www.google.com") as url:
176177
raw_text = url.read()

doc/source/development/developer.rst

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -71,11 +71,13 @@ descriptor format for these as is follows:
7171
.. code-block:: python
7272
7373
index = pd.RangeIndex(0, 10, 2)
74-
{'kind': 'range',
75-
'name': index.name,
76-
'start': index.start,
77-
'stop': index.stop,
78-
'step': index.step}
74+
{
75+
"kind": "range",
76+
"name": index.name,
77+
"start": index.start,
78+
"stop": index.stop,
79+
"step": index.step,
80+
}
7981
8082
Other index types must be serialized as data columns along with the other
8183
DataFrame columns. The metadata for these is a string indicating the name of

doc/source/development/internals.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,8 +68,9 @@ integer **codes** (until version 0.24 named *labels*), and the level **names**:
6868

6969
.. ipython:: python
7070
71-
index = pd.MultiIndex.from_product([range(3), ['one', 'two']],
72-
names=['first', 'second'])
71+
index = pd.MultiIndex.from_product(
72+
[range(3), ["one", "two"]], names=["first", "second"]
73+
)
7374
index
7475
index.levels
7576
index.codes

0 commit comments

Comments
 (0)