Skip to content

Commit b284d41

Browse files
committed
Python code linting changes detected by black
1 parent 66780b4 commit b284d41

File tree

2 files changed

+16
-12
lines changed

2 files changed

+16
-12
lines changed

GrpcInterface/Python/rips/PythonExamples/wells_and_fractures/well_event_schedule.py

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ def main():
3030
well_path_coll = project.well_path_collection()
3131
wells = project.well_paths()
3232

33-
if (len(wells) > 0):
33+
if len(wells) > 0:
3434
well_path = wells[0]
3535

3636
print("Well name: ", well_path.name)
@@ -114,7 +114,9 @@ def main():
114114
perforations = perforation_coll.perforations()
115115
print(f" Perforations created: {len(perforations)}")
116116
for perf in perforations:
117-
print(f" - MD {perf.start_measured_depth:.0f} to {perf.end_measured_depth:.0f}m")
117+
print(
118+
f" - MD {perf.start_measured_depth:.0f} to {perf.end_measured_depth:.0f}m"
119+
)
118120
valves = perf.valves()
119121
if valves:
120122
print(f" Valves: {len(valves)}")
@@ -131,7 +133,9 @@ def main():
131133
perforations = perforation_coll.perforations()
132134
print(f" Perforations after full application: {len(perforations)}")
133135
for perf in perforations:
134-
print(f" - MD {perf.start_measured_depth:.0f} to {perf.end_measured_depth:.0f}m")
136+
print(
137+
f" - MD {perf.start_measured_depth:.0f} to {perf.end_measured_depth:.0f}m"
138+
)
135139

136140
print("\nExample completed successfully!")
137141
print("\nAPI Usage Summary:")

GrpcInterface/Python/rips/tests/test_well_events.py

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -170,12 +170,12 @@ def test_set_timestamp_creates_perforations(self, project_with_wells):
170170
assert len(perforations) > 0, "Perforation should be created from event"
171171
# Verify the perforation has the correct MD range
172172
perf = perforations[0]
173-
assert abs(perf.start_measured_depth - 2000.0) < 1.0, (
174-
"Perforation start MD should match"
175-
)
176-
assert abs(perf.end_measured_depth - 2200.0) < 1.0, (
177-
"Perforation end MD should match"
178-
)
173+
assert (
174+
abs(perf.start_measured_depth - 2000.0) < 1.0
175+
), "Perforation start MD should match"
176+
assert (
177+
abs(perf.end_measured_depth - 2200.0) < 1.0
178+
), "Perforation end MD should match"
179179

180180
def test_set_timestamp_creates_tubing_intervals(self, project_with_wells):
181181
"""Test that set_timestamp creates tubing intervals from tubing events."""
@@ -202,9 +202,9 @@ def test_set_timestamp_creates_tubing_intervals(self, project_with_wells):
202202
msw_settings = well_path_b.msw_settings()
203203
assert msw_settings is not None, "MSW settings should be available"
204204
# Check that diameter roughness mode was set to intervals
205-
assert msw_settings.diameter_roughness_mode == "Intervals", (
206-
"Diameter roughness mode should be set to Intervals"
207-
)
205+
assert (
206+
msw_settings.diameter_roughness_mode == "Intervals"
207+
), "Diameter roughness mode should be set to Intervals"
208208

209209
def test_set_timestamp_ignores_future_events(self, project_with_wells):
210210
"""Test that events after the timestamp are not applied."""

0 commit comments

Comments
 (0)