Skip to content

Commit

Permalink
pull and update
Browse files Browse the repository at this point in the history
  • Loading branch information
eduardo-rodrigues committed Jul 3, 2023
2 parents 4f94385 + f1ae455 commit b987241
Showing 1 changed file with 11 additions and 6 deletions.
17 changes: 11 additions & 6 deletions src/particle/particle/convert.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,10 @@
from __future__ import annotations

import os
import warnings
from datetime import date
from io import StringIO
from pathlib import Path
import warnings
from typing import Any, Callable, Iterable, TextIO, TypeVar

import numpy as np
Expand Down Expand Up @@ -408,13 +408,18 @@ def produce_files(
# Check it there are rows only present in the .mcd file specified by year,
# in which case we need to update our curated files!
ext_table_excl = pd.DataFrame(
ext_table[~(ext_table.index.isin(full_table.index) | ext_table.index.isin(addons.index))]
,
columns= full_table.columns,
)
ext_table[
~(
ext_table.index.isin(full_table.index)
| ext_table.index.isin(addons.index)
)
],
columns=full_table.columns,
)
if len(ext_table_excl) > 0:
mcd_year = "mass_width_" + year + ".mcd"
warnings.warn(f"""{mcd_year!r} contains the following {len(ext_table_excl)} new entries:"
warnings.warn(
f"""{mcd_year!r} contains the following {len(ext_table_excl)} new entries:"
{ext_table_excl.index.to_list()}
Curation needs an update!""", stacklevel=1)

Expand Down

0 comments on commit b987241

Please sign in to comment.