Fix: element -> row
This commit is contained in:
parent
d78fcbc281
commit
5177df06d7
@ -49,7 +49,7 @@ def exam_dict2row(exam):
|
|||||||
**q,
|
**q,
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
return elements
|
return rows
|
||||||
|
|
||||||
|
|
||||||
@cli.command()
|
@cli.command()
|
||||||
@ -60,9 +60,9 @@ def new_exam():
|
|||||||
for ex in range(int(exam["ExQty"])):
|
for ex in range(int(exam["ExQty"])):
|
||||||
exam["exercices"].append(prompt_exercise(ex + 1))
|
exam["exercices"].append(prompt_exercise(ex + 1))
|
||||||
|
|
||||||
elements = exam_dict2element(exam)
|
rows = exam_dict2row(exam)
|
||||||
|
|
||||||
base_df = pd.DataFrame.from_dict(elements)[NO_ST_COLUMNS.keys()]
|
base_df = pd.DataFrame.from_dict(rows)[NO_ST_COLUMNS.keys()]
|
||||||
base_df.rename(columns=NO_ST_COLUMNS, inplace=True)
|
base_df.rename(columns=NO_ST_COLUMNS, inplace=True)
|
||||||
|
|
||||||
students = pd.read_csv(exam["tribe"]["students"])["Nom"]
|
students = pd.read_csv(exam["tribe"]["students"])["Nom"]
|
||||||
@ -117,18 +117,3 @@ def report(csv_file):
|
|||||||
csv_file=str(csv_file.absolute()),
|
csv_file=str(csv_file.absolute()),
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
|
|
||||||
# with open(csv_file.parent / "description.yml") as f:
|
|
||||||
# tribe_desc = yaml.load(f, Loader=yaml.FullLoader)
|
|
||||||
|
|
||||||
# template = Path(config["templates"]) / "tpl_student.ipynb"
|
|
||||||
# dest = Path(config["output"]) / tribe / csv_filename / "students"
|
|
||||||
# dest.mkdir(parents=True, exist_ok=True)
|
|
||||||
|
|
||||||
# for st in tribe_desc["students"]:
|
|
||||||
# click.echo(f"Building {st} report on {assessment}")
|
|
||||||
# pm.execute_notebook(
|
|
||||||
# str(template),
|
|
||||||
# str(dest / f"{st}.ipynb"),
|
|
||||||
# parameters=dict(tribe=tribe, student=st, source=str(tribe_dir.absolute())),
|
|
||||||
# )
|
|
||||||
|
Loading…
Reference in New Issue
Block a user