Skip to content

Commit f3a10e0

Browse files
committed
Merge remote-tracking branch 'upstream/main' into read-csv-from-directory
2 parents b6b48e9 + 7d542b4 commit f3a10e0

File tree

3 files changed

+20
-32
lines changed

3 files changed

+20
-32
lines changed

web/pandas/about/roadmap.md

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -58,27 +58,6 @@ library, making their behavior more consistent with the handling of
5858
NumPy arrays. We'll do this by cleaning up pandas' internals and
5959
adding new methods to the extension array interface.
6060

61-
### String data type
62-
63-
Currently, pandas stores text data in an `object` -dtype NumPy array.
64-
The current implementation has two primary drawbacks: First, `object`
65-
-dtype is not specific to strings: any Python object can be stored in an
66-
`object` -dtype array, not just strings. Second: this is not efficient.
67-
The NumPy memory model isn't especially well-suited to variable width
68-
text data.
69-
70-
To solve the first issue, we propose a new extension type for string
71-
data. This will initially be opt-in, with users explicitly requesting
72-
`dtype="string"`. The array backing this string dtype may initially be
73-
the current implementation: an `object` -dtype NumPy array of Python
74-
strings.
75-
76-
To solve the second issue (performance), we'll explore alternative
77-
in-memory array libraries (for example, Apache Arrow). As part of the
78-
work, we may need to implement certain operations expected by pandas
79-
users (for example the algorithm used in, `Series.str.upper`). That work
80-
may be done outside of pandas.
81-
8261
### Apache Arrow interoperability
8362

8463
[Apache Arrow](https://arrow.apache.org) is a cross-language development

web/pandas/static/css/pandas.css

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -106,23 +106,22 @@ blockquote {
106106
color: #787878;
107107
font-size: 18px;
108108
}
109-
110109
.toc {
111-
background: #f0f0f0;
112-
padding: 10px;
110+
background: #f9f9f9;
111+
padding: 1em;
112+
border: 0.1em solid darkgrey;
113+
border-radius: 0.4em;
113114
display: inline-block;
115+
margin: 1em 0;
116+
}
117+
.toc .toctitle {
118+
font-weight: bold;
119+
padding-bottom: 1em;
114120
}
115121
a.headerlink {
116122
opacity: 0;
117123
}
118-
h2:hover a.headerlink {
119-
opacity: 1;
120-
transition: opacity 0.5s;
121-
}
122-
h3:hover a.headerlink {
124+
h2:hover a.headerlink, h3:hover a.headerlink {
123125
opacity: 1;
124126
transition: opacity 0.5s;
125127
}
126-
.container {
127-
max-width: 100ch;
128-
}

web/pandas_web.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -441,6 +441,16 @@ def main(
441441
For ``.md`` and ``.html`` files, render them with the context
442442
before copying them. ``.md`` files are transformed to HTML.
443443
"""
444+
# Sanity check: validate that versions.json is valid JSON
445+
versions_path = os.path.join(source_path, "versions.json")
446+
with open(versions_path, encoding="utf-8") as f:
447+
try:
448+
json.load(f)
449+
except json.JSONDecodeError as e:
450+
raise RuntimeError(
451+
f"Invalid versions.json: {e}. Ensure it is valid JSON."
452+
) from e
453+
444454
config_fname = os.path.join(source_path, "config.yml")
445455

446456
shutil.rmtree(target_path, ignore_errors=True)

0 commit comments

Comments
 (0)