Skip to content

Commit

Permalink
MNT: Fix some ruff warnings about not using f-strings
Browse files Browse the repository at this point in the history
  • Loading branch information
dopplershift committed Aug 11, 2023
1 parent 779d52c commit 4e56f48
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/metpy/calc/kinematics.py
Original file line number Diff line number Diff line change
Expand Up @@ -1044,7 +1044,7 @@ def potential_vorticity_baroclinic(
or np.shape(potential_temperature)[vertical_dim] != np.shape(pressure)[vertical_dim]
):
raise ValueError('Length of potential temperature along the vertical axis '
'{} must be at least 3.'.format(vertical_dim))
f'{vertical_dim} must be at least 3.')

avor = absolute_vorticity(u, v, dx, dy, latitude, x_dim=x_dim, y_dim=y_dim,
parallel_scale=parallel_scale, meridional_scale=meridional_scale)
Expand Down
2 changes: 1 addition & 1 deletion src/metpy/plots/station_plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -620,7 +620,7 @@ def coerce_data(dat, u):
def __repr__(self):
"""Return string representation of layout."""
return ('{'
+ ', '.join('{0}: ({1[0].name}, {1[1]}, ...)'.format(loc, info)
+ ', '.join(f'{loc}: ({info[0].name}, {info[1]}, ...)'
for loc, info in sorted(self.items()))
+ '}')

Expand Down

0 comments on commit 4e56f48

Please sign in to comment.