Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion routes/supplementary_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def load(self, users: pd.Series) -> None:
if self.working_hours.empty:
logging.info("Notion working hours table does not exist")
else:
print(users)
logging.info(f"Users\n{users}")
for index, row in self.working_hours.iterrows():
not_matches = (users == row["User"]).value_counts().loc[False]
if not_matches == users.count():
Expand Down
3 changes: 2 additions & 1 deletion routes/tempo_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@ def load(self, from_date: str = "1970-01-01", to_date: str = str(date.today()))
self.data = self.raw[["issue.key", "timeSpentSeconds", "billableSeconds", "startDate", "author.displayName"]]
self.data.columns = ["Key", "Time", "Billable", "Date", "User"]
df = pd.DataFrame(self.data.loc[:, ("Key")].str.split("-", n=1).tolist(), columns=["Group", "Number"])
self.data.loc[:, ("Group")] = df["Group"]
self.data = self.data.join(df)
self.data = self.data.drop(["Number"], axis="columns")
self.data.loc[:, ("Date")] = pd.to_datetime(self.data.loc[:, ("Date")], format="%Y-%m-%d")
self.data.loc[:, ("Time")] = self.data.loc[:, ("Time")] / 3600
self.data.loc[:, ("Billable")] = self.data.loc[:, ("Billable")] / 3600
Expand Down