Skip to content

Commit

Permalink
Make team username matching case-insensitive (#57)
Browse files Browse the repository at this point in the history
* Fix lower-case name

* Fix tag
  • Loading branch information
choldgraf authored Oct 31, 2024
1 parent 310802b commit 31dfe02
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
3 changes: 3 additions & 0 deletions book/cloud.md
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,9 @@ for ix, irow in communities.iterrows():
```

```{code-cell} ipython3
---
tags: [remove-cell]
---
# Read in locations data and link it to our communities
locations = pd.read_csv("./data/airtable-locations.csv")
communities = pd.merge(communities, locations[["aid", "Latitude", "Longitude"]], left_on="Location", right_on="aid", how="left")
Expand Down
9 changes: 4 additions & 5 deletions book/people.md
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ def strip_ansi(text):
json = loads(strip_ansi(out.stdout))
team = safe_load(Path("data/team.yml").read_text())
team = [ii.lower() for ii in team]
```
+++ {"editable": true, "slideshow": {"slide_type": ""}, "tags": ["remove-cell"]}
Expand Down Expand Up @@ -147,14 +148,12 @@ tags: [remove-cell]
# Turn into dataframe
df = pd.DataFrame(json["items"])
# Light cleanup
# Extract assignees as strings instead of lists
def extract_assignee(val):
if isinstance(val, list):
val = val[0]
return val
return val.lower()
df = df.dropna(subset=["assignees"])
df["assignees"] = df["assignees"].map(extract_assignee)
# Only keep time off for our window
Expand Down

0 comments on commit 31dfe02

Please sign in to comment.