ansys-fluent-core 0.34.dev0__py3-none-any.whl → 0.34.1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of ansys-fluent-core might be problematic. Click here for more details.

Files changed (79) hide show
  1. ansys/fluent/core/__init__.py +3 -3
  2. ansys/fluent/core/codegen/builtin_settingsgen.py +25 -19
  3. ansys/fluent/core/codegen/settingsgen.py +17 -5
  4. ansys/fluent/core/codegen/tuigen.py +2 -1
  5. ansys/fluent/core/docker/docker_compose.py +4 -1
  6. ansys/fluent/core/docker/utils.py +35 -0
  7. ansys/fluent/core/exceptions.py +13 -1
  8. ansys/fluent/core/field_data_interfaces.py +239 -38
  9. ansys/fluent/core/file_session.py +167 -61
  10. ansys/fluent/core/fluent_connection.py +23 -16
  11. ansys/fluent/core/generated/api_tree/api_objects.json +1 -1
  12. ansys/fluent/core/generated/datamodel_231/flicing.py +45 -45
  13. ansys/fluent/core/generated/datamodel_231/meshing.py +256 -256
  14. ansys/fluent/core/generated/datamodel_232/flicing.py +15 -15
  15. ansys/fluent/core/generated/datamodel_232/meshing.py +205 -205
  16. ansys/fluent/core/generated/datamodel_241/flicing.py +50 -50
  17. ansys/fluent/core/generated/datamodel_241/meshing.py +279 -279
  18. ansys/fluent/core/generated/datamodel_242/flicing.py +45 -45
  19. ansys/fluent/core/generated/datamodel_242/meshing.py +315 -315
  20. ansys/fluent/core/generated/datamodel_242/part_management.py +9 -9
  21. ansys/fluent/core/generated/datamodel_251/flicing.py +35 -35
  22. ansys/fluent/core/generated/datamodel_251/meshing.py +311 -311
  23. ansys/fluent/core/generated/datamodel_252/flicing.py +60 -60
  24. ansys/fluent/core/generated/datamodel_252/meshing.py +391 -391
  25. ansys/fluent/core/generated/datamodel_252/part_management.py +10 -10
  26. ansys/fluent/core/generated/datamodel_261/flicing.py +35 -35
  27. ansys/fluent/core/generated/datamodel_261/meshing.py +494 -475
  28. ansys/fluent/core/generated/datamodel_261/meshing_utilities.py +296 -616
  29. ansys/fluent/core/generated/datamodel_261/part_management.py +5 -5
  30. ansys/fluent/core/generated/datamodel_261/preferences.py +7 -0
  31. ansys/fluent/core/generated/fluent_version_261.py +3 -3
  32. ansys/fluent/core/generated/meshing/tui_261.py +1186 -1180
  33. ansys/fluent/core/generated/solver/settings_231.py +1 -0
  34. ansys/fluent/core/generated/solver/settings_231.pyi +3025 -1
  35. ansys/fluent/core/generated/solver/settings_232.py +1 -0
  36. ansys/fluent/core/generated/solver/settings_232.pyi +3425 -1
  37. ansys/fluent/core/generated/solver/settings_241.py +1 -0
  38. ansys/fluent/core/generated/solver/settings_241.pyi +4423 -1
  39. ansys/fluent/core/generated/solver/settings_242.py +1 -0
  40. ansys/fluent/core/generated/solver/settings_242.pyi +5474 -1
  41. ansys/fluent/core/generated/solver/settings_251.py +11 -0
  42. ansys/fluent/core/generated/solver/settings_251.pyi +6006 -1
  43. ansys/fluent/core/generated/solver/settings_252.py +11 -1
  44. ansys/fluent/core/generated/solver/settings_252.pyi +6782 -2
  45. ansys/fluent/core/generated/solver/settings_261.py +7438 -3941
  46. ansys/fluent/core/generated/solver/settings_261.pyi +10916 -2656
  47. ansys/fluent/core/generated/solver/settings_builtin.py +56 -22
  48. ansys/fluent/core/generated/solver/settings_builtin.pyi +22 -0
  49. ansys/fluent/core/generated/solver/tui_261.py +3877 -2876
  50. ansys/fluent/core/launcher/container_launcher.py +6 -2
  51. ansys/fluent/core/launcher/error_handler.py +1 -1
  52. ansys/fluent/core/launcher/fluent_container.py +53 -10
  53. ansys/fluent/core/launcher/launcher.py +3 -0
  54. ansys/fluent/core/launcher/watchdog.py +6 -6
  55. ansys/fluent/core/launcher/watchdog_exec +1 -1
  56. ansys/fluent/core/pyfluent_warnings.py +7 -1
  57. ansys/fluent/core/report.py +2 -0
  58. ansys/fluent/core/search.py +11 -3
  59. ansys/fluent/core/services/__init__.py +2 -2
  60. ansys/fluent/core/services/app_utilities.py +39 -0
  61. ansys/fluent/core/services/deprecated_field_data.py +4 -4
  62. ansys/fluent/core/services/field_data.py +185 -49
  63. ansys/fluent/core/services/reduction.py +16 -5
  64. ansys/fluent/core/services/settings.py +1 -0
  65. ansys/fluent/core/session.py +16 -1
  66. ansys/fluent/core/session_pure_meshing.py +5 -5
  67. ansys/fluent/core/session_pure_meshing.pyi +1 -0
  68. ansys/fluent/core/session_solver.py +33 -8
  69. ansys/fluent/core/session_solver.pyi +1 -0
  70. ansys/fluent/core/solver/error_message.py +2 -2
  71. ansys/fluent/core/solver/flobject.py +187 -120
  72. ansys/fluent/core/solver/function/reduction.py +37 -9
  73. ansys/fluent/core/solver/settings_builtin_data.py +5 -3
  74. ansys/fluent/core/utils/fluent_version.py +1 -3
  75. ansys/fluent/core/utils/networking.py +18 -8
  76. {ansys_fluent_core-0.34.dev0.dist-info → ansys_fluent_core-0.34.1.dist-info}/METADATA +10 -11
  77. {ansys_fluent_core-0.34.dev0.dist-info → ansys_fluent_core-0.34.1.dist-info}/RECORD +79 -78
  78. {ansys_fluent_core-0.34.dev0.dist-info → ansys_fluent_core-0.34.1.dist-info}/WHEEL +1 -1
  79. {ansys_fluent_core-0.34.dev0.dist-info/licenses → ansys_fluent_core-0.34.1.dist-info}/LICENSE +0 -0
@@ -216,13 +216,17 @@ class DockerLauncher:
216
216
 
217
217
  if is_compose():
218
218
  port, config_dict, container = start_fluent_container(
219
- self._args, self.argvals["container_dict"]
219
+ self._args,
220
+ self.argvals["container_dict"],
221
+ self.argvals["start_timeout"],
220
222
  )
221
223
 
222
224
  _, _, password = _get_server_info_from_container(config_dict=config_dict)
223
225
  else:
224
226
  port, password, container = start_fluent_container(
225
- self._args, self.argvals["container_dict"]
227
+ self._args,
228
+ self.argvals["container_dict"],
229
+ self.argvals["start_timeout"],
226
230
  )
227
231
 
228
232
  fluent_connection = FluentConnection(
@@ -70,7 +70,7 @@ class LaunchFluentError(Exception):
70
70
 
71
71
  def __init__(self, launch_string):
72
72
  """__init__ method of LaunchFluentError class."""
73
- details = "\n" + "Fluent Launch string: " + launch_string
73
+ details = "\n" + "Fluent Launch command: " + launch_string
74
74
  super().__init__(details)
75
75
 
76
76
 
@@ -77,10 +77,16 @@ from pathlib import Path, PurePosixPath
77
77
  from pprint import pformat
78
78
  import tempfile
79
79
  from typing import Any, List
80
+ import warnings
80
81
 
81
82
  import ansys.fluent.core as pyfluent
82
83
  from ansys.fluent.core.docker.docker_compose import ComposeBasedLauncher
84
+ from ansys.fluent.core.docker.utils import get_ghcr_fluent_image_name
85
+ from ansys.fluent.core.launcher.error_handler import (
86
+ LaunchFluentError,
87
+ )
83
88
  from ansys.fluent.core.launcher.launcher_utils import is_compose
89
+ from ansys.fluent.core.pyfluent_warnings import PyFluentDeprecationWarning
84
90
  from ansys.fluent.core.session import _parse_server_info_file
85
91
  from ansys.fluent.core.utils.deprecate import all_deprecators
86
92
  from ansys.fluent.core.utils.execution import timeout_loop
@@ -155,7 +161,7 @@ def configure_container_dict(
155
161
  args: List[str],
156
162
  mount_source: str | Path | None = None,
157
163
  mount_target: str | Path | None = None,
158
- timeout: int = 60,
164
+ timeout: int | None = None,
159
165
  port: int | None = None,
160
166
  license_server: str | None = None,
161
167
  container_server_info_file: str | Path | None = None,
@@ -180,7 +186,7 @@ def configure_container_dict(
180
186
  Path inside the container where ``mount_source`` will be mounted. This will be the working directory path
181
187
  visible to the Fluent process running inside the container.
182
188
  timeout : int, optional
183
- Time limit for the Fluent container to start, in seconds. By default, 30 seconds.
189
+ Time limit for the Fluent container to start, in seconds.
184
190
  port : int, optional
185
191
  Port for Fluent container to use.
186
192
  license_server : str, optional
@@ -231,6 +237,12 @@ def configure_container_dict(
231
237
  See also :func:`start_fluent_container`.
232
238
  """
233
239
 
240
+ if timeout is not None:
241
+ warnings.warn(
242
+ "configure_container_dict(timeout) is deprecated, use launch_fluent(start_timeout) instead.",
243
+ PyFluentDeprecationWarning,
244
+ )
245
+
234
246
  logger.debug(f"container_dict before processing:\n{dict_to_str(container_dict)}")
235
247
 
236
248
  # Starting with 'mount_source' because it is not tied to the 'working_dir'.
@@ -390,8 +402,10 @@ def configure_container_dict(
390
402
  image_tag = os.getenv(
391
403
  "FLUENT_IMAGE_TAG", f"v{pyfluent.FLUENT_RELEASE_VERSION}"
392
404
  )
393
- if not image_name:
394
- image_name = os.getenv("FLUENT_IMAGE_NAME", "ghcr.io/ansys/pyfluent")
405
+ if not image_name and image_tag:
406
+ image_name = os.getenv(
407
+ "FLUENT_IMAGE_NAME", get_ghcr_fluent_image_name(image_tag)
408
+ )
395
409
  if not image_tag or not image_name:
396
410
  fluent_image = os.getenv("FLUENT_CONTAINER_IMAGE", None)
397
411
  elif image_tag and image_name:
@@ -444,7 +458,7 @@ def configure_container_dict(
444
458
  container_dict["mount_target"] = mount_target
445
459
 
446
460
  logger.debug(
447
- f"Fluent container timeout: {timeout}, container_grpc_port: {container_grpc_port}, "
461
+ f"Fluent container container_grpc_port: {container_grpc_port}, "
448
462
  f"host_server_info_file: '{host_server_info_file}', "
449
463
  f"remove_server_info_file: {remove_server_info_file}"
450
464
  )
@@ -460,7 +474,7 @@ def configure_container_dict(
460
474
 
461
475
 
462
476
  def start_fluent_container(
463
- args: List[str], container_dict: dict | None = None
477
+ args: List[str], container_dict: dict | None = None, start_timeout: int = 60
464
478
  ) -> tuple[int, str, Any]:
465
479
  """Start a Fluent container.
466
480
 
@@ -470,6 +484,9 @@ def start_fluent_container(
470
484
  List of Fluent launch arguments.
471
485
  container_dict : dict, optional
472
486
  Dictionary with Docker container configuration.
487
+ start_timeout : int, optional
488
+ Timeout in seconds for the container to start. If not specified, it defaults to 60
489
+ seconds.
473
490
 
474
491
  Returns
475
492
  -------
@@ -503,6 +520,14 @@ def start_fluent_container(
503
520
  host_server_info_file,
504
521
  remove_server_info_file,
505
522
  ) = container_vars
523
+ launch_string = " ".join(config_dict["command"])
524
+
525
+ if timeout:
526
+ logger.warning(
527
+ "launch_fluent(start_timeout) overridden by configure_container_dict(timeout) value."
528
+ )
529
+ start_timeout = timeout
530
+ del timeout
506
531
 
507
532
  try:
508
533
  if is_compose():
@@ -536,18 +561,36 @@ def start_fluent_container(
536
561
  config_dict.pop("fluent_image"), **config_dict
537
562
  )
538
563
 
564
+ logger.debug(
565
+ f"Waiting for Fluent container for up to {start_timeout} seconds..."
566
+ )
567
+
539
568
  success = timeout_loop(
540
- lambda: host_server_info_file.stat().st_mtime > last_mtime, timeout
569
+ lambda: host_server_info_file.stat().st_mtime > last_mtime,
570
+ start_timeout,
541
571
  )
542
572
 
543
573
  if not success:
544
- raise TimeoutError(
545
- "Fluent container launch has timed out, stop container manually."
546
- )
574
+ try:
575
+ container.stop()
576
+ except Exception as stop_ex:
577
+ logger.error(f"Failed to stop container: {stop_ex}")
578
+ raise TimeoutError(
579
+ f"Fluent container launch has timed out after {start_timeout} seconds. "
580
+ f"Additionally, stopping the container failed: {stop_ex}"
581
+ ) from stop_ex
582
+ else:
583
+ raise TimeoutError(
584
+ f"Fluent container launch has timed out after {start_timeout} seconds."
585
+ " The container was stopped."
586
+ )
547
587
  else:
548
588
  _, _, password = _parse_server_info_file(str(host_server_info_file))
549
589
 
550
590
  return port, password, container
591
+ except Exception as ex:
592
+ logger.error(f"Exception caught - {type(ex).__name__}: {ex}")
593
+ raise LaunchFluentError(launch_string) from ex
551
594
  finally:
552
595
  if remove_server_info_file and host_server_info_file.exists():
553
596
  host_server_info_file.unlink()
@@ -322,6 +322,9 @@ def launch_fluent(
322
322
  if env is None:
323
323
  env = {}
324
324
 
325
+ if start_timeout is None:
326
+ start_timeout = int(os.getenv("PYFLUENT_FLUENT_LAUNCH_TIMEOUT", "60"))
327
+
325
328
  def _mode_to_launcher_type(fluent_launch_mode: LaunchMode):
326
329
  launcher_mode_type = {
327
330
  LaunchMode.CONTAINER: DockerLauncher,
@@ -76,8 +76,8 @@ def launch(
76
76
  )
77
77
  )
78
78
 
79
- env_watchdog_debug = os.getenv("PYFLUENT_WATCHDOG_DEBUG", "off").upper()
80
- if env_watchdog_debug in ("1", "ON"):
79
+ debug_watchdog = os.getenv("PYFLUENT_WATCHDOG_DEBUG") == "1"
80
+ if debug_watchdog:
81
81
  logger.debug(
82
82
  f"PYFLUENT_WATCHDOG_DEBUG environment variable found, "
83
83
  f"enabling debugging for watchdog ID {watchdog_id}..."
@@ -131,7 +131,7 @@ def launch(
131
131
  watchdog_id,
132
132
  ]
133
133
 
134
- if env_watchdog_debug in ("1", "ON"):
134
+ if debug_watchdog:
135
135
  logger.debug(f"Starting Watchdog logging to directory {os.getcwd()}")
136
136
 
137
137
  kwargs = {"env": watchdog_env, "stdin": subprocess.DEVNULL, "close_fds": True}
@@ -151,7 +151,7 @@ def launch(
151
151
  if os.name == "posix":
152
152
  kwargs.update(start_new_session=True)
153
153
 
154
- if env_watchdog_debug in ("1", "ON") and os.name != "nt":
154
+ if debug_watchdog and os.name != "nt":
155
155
  kwargs.update(
156
156
  stdout=open(f"pyfluent_watchdog_out_{watchdog_id}.log", mode="w"),
157
157
  stderr=open(f"pyfluent_watchdog_err_{watchdog_id}.log", mode="w"),
@@ -194,13 +194,13 @@ def launch(
194
194
  err_content = "Watchdog - %s" % f.read().replace("\n", "")
195
195
  watchdog_err.unlink()
196
196
  logger.error(err_content)
197
- if os.getenv("PYFLUENT_WATCHDOG_EXCEPTION_ON_ERROR"):
197
+ if os.getenv("PYFLUENT_WATCHDOG_EXCEPTION_ON_ERROR") == "1":
198
198
  raise UnsuccessfulWatchdogLaunch(err_content)
199
199
 
200
200
  logger.warning(
201
201
  "PyFluent Watchdog did not initialize correctly, proceeding without it..."
202
202
  )
203
- if os.getenv("PYFLUENT_WATCHDOG_EXCEPTION_ON_ERROR"):
203
+ if os.getenv("PYFLUENT_WATCHDOG_EXCEPTION_ON_ERROR") == "1":
204
204
  raise UnsuccessfulWatchdogLaunch(
205
205
  "PyFluent Watchdog did not initialize correctly."
206
206
  )
@@ -34,7 +34,7 @@ if __name__ == "__main__":
34
34
 
35
35
  logger = pyfluent.logger.get_logger("pyfluent.watchdog")
36
36
 
37
- if os.getenv("PYFLUENT_WATCHDOG_DEBUG", "OFF").upper() in ("1", "ON"):
37
+ if os.getenv("PYFLUENT_WATCHDOG_DEBUG") == "1":
38
38
  pyfluent.logger.enable(custom_config=log_config)
39
39
  logger.setLevel("DEBUG")
40
40
  logger.handlers = pyfluent.logger.get_logger(
@@ -38,6 +38,12 @@ class PyFluentUserWarning(UserWarning):
38
38
  pass
39
39
 
40
40
 
41
+ class FluentDevVersionWarning(PyFluentUserWarning):
42
+ """Warning raised when a released PyFluent version is used with a development version of Fluent."""
43
+
44
+ pass
45
+
46
+
41
47
  def warning_for_fluent_dev_version(version):
42
48
  """Provides warning if Fluent develop branch is used."""
43
49
  from ansys.fluent.core import FLUENT_RELEASE_VERSION, FluentVersion
@@ -47,7 +53,7 @@ def warning_for_fluent_dev_version(version):
47
53
  "⚠️ Warning: You are using PyFluent with an unreleased or development version of Fluent.\n"
48
54
  "Compatibility is not guaranteed, and unexpected behavior may occur. Please use a released "
49
55
  "version of Fluent that is officially supported by this version of PyFluent.",
50
- PyFluentUserWarning,
56
+ FluentDevVersionWarning,
51
57
  )
52
58
 
53
59
 
@@ -44,6 +44,8 @@ ANSYS_ENV_VARS = [
44
44
  "PYFLUENT_FLUENT_IP",
45
45
  "PYFLUENT_FLUENT_PORT",
46
46
  "PYFLUENT_FLUENT_ROOT",
47
+ "PYFLUENT_FLUENT_LAUNCH_TIMEOUT",
48
+ "PYFLUENT_FLUENT_AUTOMATIC_TRANSCRIPT",
47
49
  "PYFLUENT_GRPC_LOG_BYTES_LIMIT",
48
50
  "PYFLUENT_LAUNCH_CONTAINER",
49
51
  "PYFLUENT_LOGGING",
@@ -207,10 +207,18 @@ def _print_search_results(
207
207
  for query in queries:
208
208
  if isinstance(query, tuple):
209
209
  name, score = query
210
- if name in first_token and has_query(name, substrings):
211
- results.add((api_object, round(score, 2)))
212
210
  else:
213
- if query in first_token and has_query(query, substrings):
211
+ name = query
212
+ score = None
213
+
214
+ if (
215
+ name in first_token
216
+ and has_query(name, substrings)
217
+ and name in substrings[-1]
218
+ ):
219
+ if score is not None:
220
+ results.add((api_object, round(score, 2)))
221
+ else:
214
222
  results.add(api_object)
215
223
 
216
224
  return sorted(results)
@@ -32,7 +32,7 @@ from ansys.fluent.core.services.datamodel_tui import (
32
32
  )
33
33
  from ansys.fluent.core.services.deprecated_field_data import DeprecatedFieldData
34
34
  from ansys.fluent.core.services.events import EventsService
35
- from ansys.fluent.core.services.field_data import FieldInfo, LiveFieldData
35
+ from ansys.fluent.core.services.field_data import LiveFieldData, _FieldInfo
36
36
  from ansys.fluent.core.services.health_check import HealthCheckService
37
37
  from ansys.fluent.core.services.monitor import MonitorsService
38
38
  from ansys.fluent.core.services.reduction import Reduction
@@ -54,7 +54,7 @@ _service_cls_by_name = {
54
54
  "events": EventsService,
55
55
  "field_data": LiveFieldData,
56
56
  "field_data_old": DeprecatedFieldData,
57
- "field_info": FieldInfo,
57
+ "field_info": _FieldInfo,
58
58
  "monitors": MonitorsService,
59
59
  "reduction": Reduction,
60
60
  "svar": SolutionVariableService,
@@ -104,6 +104,12 @@ class AppUtilitiesService:
104
104
  """Is beta enabled RPC of AppUtilities service."""
105
105
  return self._stub.IsBetaEnabled(request, metadata=self._metadata)
106
106
 
107
+ def enable_beta(
108
+ self, request: AppUtilitiesProtoModule.EnableBetaRequest
109
+ ) -> AppUtilitiesProtoModule.EnableBetaResponse:
110
+ """Is beta enabled RPC of AppUtilities service."""
111
+ return self._stub.EnableBeta(request, metadata=self._metadata)
112
+
107
113
  def is_wildcard(
108
114
  self, request: AppUtilitiesProtoModule.IsWildcardRequest
109
115
  ) -> AppUtilitiesProtoModule.IsWildcardResponse:
@@ -255,6 +261,18 @@ class AppUtilitiesOld:
255
261
  """Is beta enabled."""
256
262
  return self.scheme.eval("(is-beta-feature-available?)")
257
263
 
264
+ def enable_beta(self):
265
+ """Enable beta features.
266
+
267
+ Raises
268
+ ------
269
+ RuntimeError
270
+ Not supported before Fluent 2025 R2.
271
+ """
272
+ raise RuntimeError(
273
+ "Enabling beta is not supported by PyFluent for Fluent versions before 2025 R2."
274
+ )
275
+
258
276
  def is_wildcard(self, input: str | None = None) -> bool:
259
277
  """Is wildcard."""
260
278
  return self.scheme.eval(f'(has-fnmatch-wild-card? "{input}")')
@@ -405,6 +423,11 @@ class AppUtilities:
405
423
  response = self.service.is_beta_enabled(request)
406
424
  return response.is_beta_enabled
407
425
 
426
+ def enable_beta(self) -> None:
427
+ """Enable beta features."""
428
+ request = AppUtilitiesProtoModule.EnableBetaRequest()
429
+ self.service.enable_beta(request)
430
+
408
431
  def is_wildcard(self, input: str | None = None) -> bool:
409
432
  """Is wildcard."""
410
433
  request = AppUtilitiesProtoModule.IsWildcardRequest()
@@ -456,3 +479,19 @@ class AppUtilities:
456
479
  request = AppUtilitiesProtoModule.SetWorkingDirectoryRequest()
457
480
  request.path = path
458
481
  self.service.set_working_directory(request)
482
+
483
+
484
+ class AppUtilitiesV252(AppUtilities):
485
+ """AppUtilitiesV252.
486
+ This is for methods whose implementations are missing in the 25R2 server.
487
+ """
488
+
489
+ def __init__(self, service: AppUtilitiesService, scheme):
490
+ super().__init__(service)
491
+ self.scheme = scheme
492
+
493
+ def enable_beta(self) -> None:
494
+ """Enable beta features."""
495
+ self.scheme.eval(
496
+ '(fl-execute-cmd "file" "beta-settings" (list (cons "enable?" #t)))'
497
+ )
@@ -28,15 +28,15 @@ import warnings
28
28
  from ansys.api.fluent.v0 import field_data_pb2 as FieldDataProtoModule
29
29
  from ansys.fluent.core.pyfluent_warnings import PyFluentDeprecationWarning
30
30
  from ansys.fluent.core.services.field_data import (
31
+ Batch,
31
32
  ChunkParser,
32
33
  FieldDataService,
33
- FieldInfo,
34
34
  SurfaceDataType,
35
- Transaction,
36
35
  _AllowedScalarFieldNames,
37
36
  _AllowedSurfaceIDs,
38
37
  _AllowedSurfaceNames,
39
38
  _AllowedVectorFieldNames,
39
+ _FieldInfo,
40
40
  _FieldMethod,
41
41
  _get_surface_ids,
42
42
  get_fields_request,
@@ -223,7 +223,7 @@ class DeprecatedFieldData:
223
223
  def __init__(
224
224
  self,
225
225
  service: FieldDataService,
226
- field_info: FieldInfo,
226
+ field_info: _FieldInfo,
227
227
  is_data_valid: Callable[[], bool],
228
228
  scheme_eval=None,
229
229
  ):
@@ -288,7 +288,7 @@ class DeprecatedFieldData:
288
288
  def new_transaction(self):
289
289
  """Create a new field transaction."""
290
290
  warnings.warn(DEPRECATION_MSG, PyFluentDeprecationWarning)
291
- return Transaction(
291
+ return Batch(
292
292
  self._service,
293
293
  self._field_info,
294
294
  self._allowed_surface_ids,