Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set keyword value #379

Merged
merged 1 commit into from
Jan 28, 2021
Merged

Set keyword value #379

merged 1 commit into from
Jan 28, 2021

Conversation

rouille
Copy link
Collaborator

@rouille rouille commented Jan 26, 2021

Purpose

A FutureWarning is raised when running the tests:

powersimdata/design/investment/tests/test_investment_costs.py::test_calculate_gen_inv_costs_2030
  /Users/brdo/CEM/PowerSimData/powersimdata/design/investment/investment_costs.py:371: FutureWarning: The default value of regex will change from True to False in a future version. In addition, single character regular expressions will*not* be treated as literal strings when regex=True.
    cost["value"] = cost["value"].str.replace("$", "")

I have set the regex parameter to True in the replace method (current default value) to avoid any surprise when we update pandas.

Testing

No more warning when running pytest

Where to look

The optional parameter regex is set to True, which is the current default value

Time estimate

2 min

@rouille rouille added this to the Hey Joe milestone Jan 26, 2021
@rouille rouille merged commit a84b126 into develop Jan 28, 2021
@rouille rouille deleted the ben/replace branch January 28, 2021 18:47
@ahurli ahurli mentioned this pull request Mar 11, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants