pytmc 2.18.0__tar.gz → 2.18.2__tar.gz

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.
Files changed (90) hide show
  1. {pytmc-2.18.0/pytmc.egg-info → pytmc-2.18.2}/PKG-INFO +2 -2
  2. {pytmc-2.18.0 → pytmc-2.18.2}/docs/source/release_notes.rst +15 -0
  3. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/_version.py +2 -2
  4. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/parser.py +14 -2
  5. {pytmc-2.18.0 → pytmc-2.18.2/pytmc.egg-info}/PKG-INFO +2 -2
  6. {pytmc-2.18.0 → pytmc-2.18.2}/.coveragerc +0 -0
  7. {pytmc-2.18.0 → pytmc-2.18.2}/.flake8 +0 -0
  8. {pytmc-2.18.0 → pytmc-2.18.2}/.git_archival.txt +0 -0
  9. {pytmc-2.18.0 → pytmc-2.18.2}/.gitattributes +0 -0
  10. {pytmc-2.18.0 → pytmc-2.18.2}/.github/workflows/standard.yml +0 -0
  11. {pytmc-2.18.0 → pytmc-2.18.2}/.gitignore +0 -0
  12. {pytmc-2.18.0 → pytmc-2.18.2}/.gitmodules +0 -0
  13. {pytmc-2.18.0 → pytmc-2.18.2}/.landscape.yml +0 -0
  14. {pytmc-2.18.0 → pytmc-2.18.2}/.pre-commit-config.yaml +0 -0
  15. {pytmc-2.18.0 → pytmc-2.18.2}/AUTHORS.rst +0 -0
  16. {pytmc-2.18.0 → pytmc-2.18.2}/CONTRIBUTING.rst +0 -0
  17. {pytmc-2.18.0 → pytmc-2.18.2}/LICENSE +0 -0
  18. {pytmc-2.18.0 → pytmc-2.18.2}/MANIFEST.in +0 -0
  19. {pytmc-2.18.0 → pytmc-2.18.2}/README.rst +0 -0
  20. {pytmc-2.18.0 → pytmc-2.18.2}/conda-recipe/meta.yaml +0 -0
  21. {pytmc-2.18.0 → pytmc-2.18.2}/dev-requirements.txt +0 -0
  22. {pytmc-2.18.0 → pytmc-2.18.2}/docs/Makefile +0 -0
  23. {pytmc-2.18.0 → pytmc-2.18.2}/docs/source/_static/.gitkeep +0 -0
  24. {pytmc-2.18.0 → pytmc-2.18.2}/docs/source/conf.py +0 -0
  25. {pytmc-2.18.0 → pytmc-2.18.2}/docs/source/getting_started.rst +0 -0
  26. {pytmc-2.18.0 → pytmc-2.18.2}/docs/source/index.rst +0 -0
  27. {pytmc-2.18.0 → pytmc-2.18.2}/docs/source/installation.rst +0 -0
  28. {pytmc-2.18.0 → pytmc-2.18.2}/docs/source/pragma_usage.rst +0 -0
  29. {pytmc-2.18.0 → pytmc-2.18.2}/docs/source/source_code.rst +0 -0
  30. {pytmc-2.18.0 → pytmc-2.18.2}/docs/source/terminal_usage.rst +0 -0
  31. {pytmc-2.18.0 → pytmc-2.18.2}/docs/source/user_guide.rst +0 -0
  32. {pytmc-2.18.0 → pytmc-2.18.2}/docs-requirements.txt +0 -0
  33. {pytmc-2.18.0 → pytmc-2.18.2}/pyproject.toml +0 -0
  34. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/__init__.py +0 -0
  35. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/__main__.py +0 -0
  36. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/beckhoff.py +0 -0
  37. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/bin/__init__.py +0 -0
  38. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/bin/code.py +0 -0
  39. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/bin/db.py +0 -0
  40. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/bin/debug.py +0 -0
  41. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/bin/iocboot.py +0 -0
  42. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/bin/pragmalint.py +0 -0
  43. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/bin/pytmc.py +0 -0
  44. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/bin/stcmd.py +0 -0
  45. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/bin/summary.py +0 -0
  46. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/bin/template.py +0 -0
  47. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/bin/types.py +0 -0
  48. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/bin/util.py +0 -0
  49. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/bin/xmltranslate.py +0 -0
  50. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/code.py +0 -0
  51. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/default_settings/__init__.py +0 -0
  52. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/default_settings/conf.ini +0 -0
  53. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/default_settings/unified_ordered_field_list.py +0 -0
  54. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/defaults.py +0 -0
  55. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/linter.py +0 -0
  56. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/pragmas.py +0 -0
  57. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/record.py +0 -0
  58. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/templates/EPICS_proto_template.proto +0 -0
  59. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/templates/asyn_standard_file.jinja2 +0 -0
  60. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/templates/asyn_standard_record.jinja2 +0 -0
  61. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/templates/stcmd_default.cmd +0 -0
  62. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/__init__.py +0 -0
  63. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/ads.dbd +0 -0
  64. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/conftest.py +0 -0
  65. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/static_routes.xml +0 -0
  66. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/templates/basic_test.txt +0 -0
  67. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/templates/smoke_test.txt +0 -0
  68. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/test_archive.py +0 -0
  69. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/test_commandline.py +0 -0
  70. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/test_integrations.py +0 -0
  71. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/test_lint.py +0 -0
  72. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/test_motion.py +0 -0
  73. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/test_parsing.py +0 -0
  74. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/test_project.py +0 -0
  75. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/test_record.py +0 -0
  76. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/test_xml_collector.py +0 -0
  77. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/test_xml_obj.py +0 -0
  78. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/tmc_files/ArbiterPLC.tmc +0 -0
  79. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/tmc_files/tc_mot_example.tmc +0 -0
  80. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/tests/tmc_files/xtes_sxr_plc.tmc +0 -0
  81. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/validation/__init__.py +0 -0
  82. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/validation/v0.1.py +0 -0
  83. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc/version.py +0 -0
  84. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc.egg-info/SOURCES.txt +0 -0
  85. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc.egg-info/dependency_links.txt +0 -0
  86. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc.egg-info/entry_points.txt +0 -0
  87. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc.egg-info/requires.txt +0 -0
  88. {pytmc-2.18.0 → pytmc-2.18.2}/pytmc.egg-info/top_level.txt +0 -0
  89. {pytmc-2.18.0 → pytmc-2.18.2}/requirements.txt +0 -0
  90. {pytmc-2.18.0 → pytmc-2.18.2}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.2
2
2
  Name: pytmc
3
- Version: 2.18.0
3
+ Version: 2.18.2
4
4
  Summary: Generate Epics DB records from TwinCAT .tmc files
5
5
  Author: SLAC National Accelerator Laboratory
6
6
  License: Copyright (c) 2023, The Board of Trustees of the Leland Stanford Junior
@@ -2,6 +2,21 @@
2
2
  Release History
3
3
  =================
4
4
 
5
+ v2.18.2 (2025-02-12)
6
+ ====================
7
+
8
+ Changes
9
+ -------
10
+ - Add support for TwinCAT 4026 structures that store certain xti files in folders
11
+ adjacent to their locations in 4024.
12
+
13
+
14
+ v2.18.1 (2025-02-11)
15
+ ====================
16
+
17
+ Due to an error, no functional changes in this tag. Please use the next tag instead.
18
+
19
+
5
20
  v2.18.0 (2024-12-19)
6
21
  ====================
7
22
 
@@ -12,5 +12,5 @@ __version__: str
12
12
  __version_tuple__: VERSION_TUPLE
13
13
  version_tuple: VERSION_TUPLE
14
14
 
15
- __version__ = version = '2.18.0'
16
- __version_tuple__ = version_tuple = (2, 18, 0)
15
+ __version__ = version = '2.18.2'
16
+ __version_tuple__ = version_tuple = (2, 18, 2)
@@ -147,7 +147,7 @@ def element_to_class_name(
147
147
  return tag, TwincatItem
148
148
 
149
149
 
150
- def _determine_path(base_path, name, class_hint):
150
+ def _determine_path(base_path, name, class_hint) -> pathlib.Path:
151
151
  """
152
152
  Determine the path to load child XTI items from, given a base path and the
153
153
  class load path hint.
@@ -429,7 +429,19 @@ class TwincatItem:
429
429
  name=parent.name,
430
430
  class_hint=cls._load_path_hint,
431
431
  )
432
- return parse(base_path / filename, parent=parent)
432
+ try:
433
+ return parse(base_path / filename, parent=parent)
434
+ except FileNotFoundError as exc:
435
+ original_error = exc
436
+ # TwinCAT is weird, let's do a best-effort glob through directories parallel to base_path
437
+ for try_dir in base_path.parent.glob("*"):
438
+ if try_dir.is_dir():
439
+ try:
440
+ return parse(try_dir / filename, parent=parent)
441
+ except FileNotFoundError:
442
+ ...
443
+ # We tried I guess
444
+ raise original_error
433
445
 
434
446
 
435
447
  class _LazyLoadPlaceholder:
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.2
2
2
  Name: pytmc
3
- Version: 2.18.0
3
+ Version: 2.18.2
4
4
  Summary: Generate Epics DB records from TwinCAT .tmc files
5
5
  Author: SLAC National Accelerator Laboratory
6
6
  License: Copyright (c) 2023, The Board of Trustees of the Leland Stanford Junior
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes