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

Add option for carbon capture in integrated steelworks (Sourcery refactored) #753

Closed

Conversation

sourcery-ai[bot]
Copy link

@sourcery-ai sourcery-ai bot commented Oct 8, 2023

Pull Request #719 refactored by Sourcery.

If you're happy with these changes, merge this Pull Request using the Squash and merge strategy.

NOTE: As code is pushed to the original Pull Request, Sourcery will
re-run and update (force-push) this Pull Request with new refactorings as
necessary. If Sourcery finds no refactorings at any point, this Pull Request
will be closed automatically.

See our documentation here.

Run Sourcery locally

Reduce the feedback loop during development by using the Sourcery editor plugin:

Review changes via command line

To manually merge these changes, make sure you're on the blast-furnace-with-cc branch, then run:

git fetch origin sourcery/blast-furnace-with-cc
git merge --ff-only FETCH_HEAD
git reset HEAD^

Help us improve this pull request!

@sourcery-ai sourcery-ai bot requested a review from fneum October 8, 2023 10:02
if isinstance(item, dict):
return item[investment_year]
else:
return item
return item[investment_year] if isinstance(item, dict) else item
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function get refactored with the following changes:

Comment on lines 418 to 415
if snakemake.wildcards.clusters[-1:] == "m":
genmap = busmap_s
else:
genmap = clustermaps

genmap = busmap_s if snakemake.wildcards.clusters[-1:] == "m" else clustermaps
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function update_wind_solar_costs refactored with the following changes:

Comment on lines 510 to 505
to_drop = list(n.buses.query("carrier not in ['AC', 'DC']").carrier.unique())
if to_drop:
if to_drop := list(
n.buses.query("carrier not in ['AC', 'DC']").carrier.unique()
):
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function remove_non_electric_buses refactored with the following changes:

Comment on lines -1237 to +1233
augmentation = list(
if augmentation := list(
k_edge_augmentation(G, k_edge, avail=complement_edges.values)
)

if augmentation:
):
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function add_storage_and_grids refactored with the following changes:

@fneum fneum closed this Oct 8, 2023
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.

1 participant