Skip to content

Commit 539154f

Browse files
committed
fix linting
1 parent e592402 commit 539154f

File tree

4 files changed

+8
-6
lines changed

4 files changed

+8
-6
lines changed

_delphi_utils_python/.pylintrc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ disable=logging-format-interpolation,
1212
[BASIC]
1313

1414
# Allow arbitrarily short-named variables.
15-
variable-rgx=[a-z_][a-z0-9_]*
16-
argument-rgx=[a-z_][a-z0-9_]*
17-
attr-rgx=[a-z_][a-z0-9_]*
15+
variable-rgx=([a-z_][a-z0-9_]*|[a-zA-Z])
16+
argument-rgx=([a-z_][a-z0-9_]*|[a-zA-Z])
17+
attr-rgx=([a-z_][a-z0-9_]*|[a-zA-Z])
1818

1919
[DESIGN]
2020

_delphi_utils_python/delphi_utils/weekday.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,7 @@ def _fit(X, scales, npnums, npdenoms):
9999
# If the magnitude of the objective function is too large, an error is
100100
# thrown; Rescale the objective function by going through loop
101101
continue
102+
return None
102103

103104
@staticmethod
104105
def calc_adjustment(params, sub_data, cols, date_col):

changehc/delphi_changehc/run.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,6 @@ def run_module(params: Dict[str, Dict[str, Any]]):
185185
more_stats = su_inst.update_sensor(
186186
data,
187187
params["common"]["export_dir"],
188-
logger,
189188
)
190189
stats.extend(more_stats)
191190

claims_hosp/delphi_claims_hosp/update_indicator.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,8 @@ def update_indicator(self, input_filepath, outpath, logger):
169169
for geo_id, sub_data in data_frame.groupby(level=0):
170170
sub_data.reset_index(inplace=True)
171171
if self.weekday:
172-
sub_data = Weekday.calc_adjustment(wd_params, sub_data, ["num"], Config.DATE_COL)
172+
sub_data = Weekday.calc_adjustment(
173+
wd_params, sub_data, ["num"], Config.DATE_COL)
173174
sub_data.set_index(Config.DATE_COL, inplace=True)
174175
res = ClaimsHospIndicator.fit(sub_data, self.burnindate, geo_id)
175176
res = pd.DataFrame(res)
@@ -184,7 +185,8 @@ def update_indicator(self, input_filepath, outpath, logger):
184185
for geo_id, sub_data in data_frame.groupby(level=0, as_index=False):
185186
sub_data.reset_index(inplace=True)
186187
if self.weekday:
187-
sub_data = Weekday.calc_adjustment(wd_params, sub_data, ["num"], Config.DATE_COL)
188+
sub_data = Weekday.calc_adjustment(
189+
wd_params, sub_data, ["num"], Config.DATE_COL)
188190
sub_data.set_index(Config.DATE_COL, inplace=True)
189191
pool_results.append(
190192
pool.apply_async(

0 commit comments

Comments
 (0)