amalgam-lang 7.2.0__tar.gz → 7.2.1__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.

Potentially problematic release.


This version of amalgam-lang might be problematic. Click here for more details.

Files changed (60) hide show
  1. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/.github/workflows/build.yml +33 -37
  2. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/PKG-INFO +1 -1
  3. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/api.py +103 -2
  4. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam_lang.egg-info/PKG-INFO +1 -1
  5. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/.coveragerc +0 -0
  6. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/.flake8 +0 -0
  7. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/.github/CODEOWNERS +0 -0
  8. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/.github/templates/version_summary.md +0 -0
  9. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/.github/workflows/build-pr.yml +0 -0
  10. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/.github/workflows/build-release.yml +0 -0
  11. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/.gitignore +0 -0
  12. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/.pylintrc +0 -0
  13. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/CONTRIBUTING.md +0 -0
  14. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/LICENSE.txt +0 -0
  15. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/MANIFEST.in +0 -0
  16. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/README.md +0 -0
  17. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/__init__.py +0 -0
  18. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/darwin/amd64/amalgam-mt-noavx.dylib +0 -0
  19. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/darwin/amd64/amalgam-mt.dylib +0 -0
  20. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/darwin/amd64/amalgam-omp.dylib +0 -0
  21. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/darwin/amd64/amalgam-st.dylib +0 -0
  22. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/darwin/amd64/docs/version.json +0 -0
  23. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/darwin/arm64/amalgam-mt.dylib +0 -0
  24. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/darwin/arm64/amalgam-omp.dylib +0 -0
  25. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/darwin/arm64/amalgam-st.dylib +0 -0
  26. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/darwin/arm64/docs/version.json +0 -0
  27. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/linux/amd64/amalgam-mt-noavx.so +0 -0
  28. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/linux/amd64/amalgam-mt.so +0 -0
  29. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/linux/amd64/amalgam-omp.so +0 -0
  30. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/linux/amd64/amalgam-st.so +0 -0
  31. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/linux/amd64/docs/version.json +0 -0
  32. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/linux/arm64/amalgam-mt.so +0 -0
  33. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/linux/arm64/amalgam-omp.so +0 -0
  34. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/linux/arm64/amalgam-st.so +0 -0
  35. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/linux/arm64/docs/version.json +0 -0
  36. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/linux/arm64_8a/amalgam-st.so +0 -0
  37. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/linux/arm64_8a/docs/version.json +0 -0
  38. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/version.json +0 -0
  39. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/windows/amd64/amalgam-mt-noavx.dll +0 -0
  40. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/windows/amd64/amalgam-mt.dll +0 -0
  41. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/windows/amd64/amalgam-omp.dll +0 -0
  42. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/windows/amd64/amalgam-st.dll +0 -0
  43. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam/lib/windows/amd64/docs/version.json +0 -0
  44. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam_lang.egg-info/SOURCES.txt +0 -0
  45. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam_lang.egg-info/dependency_links.txt +0 -0
  46. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam_lang.egg-info/requires.txt +0 -0
  47. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/amalgam_lang.egg-info/top_level.txt +0 -0
  48. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/bin/build.sh +0 -0
  49. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/config/latest-mt-debug-howso.yml +0 -0
  50. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/config/latest-mt-howso.yml +0 -0
  51. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/config/latest-st-debug-howso.yml +0 -0
  52. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/config/latest-st-howso.yml +0 -0
  53. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/doc/dependency_decisions.yml +0 -0
  54. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/pyproject.toml +0 -0
  55. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/requirements-3.10-dev.txt +0 -0
  56. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/requirements-3.11-dev.txt +0 -0
  57. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/requirements-3.8-dev.txt +0 -0
  58. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/requirements-3.9-dev.txt +0 -0
  59. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/setup.cfg +0 -0
  60. {amalgam-lang-7.2.0 → amalgam-lang-7.2.1}/version.json +0 -0
@@ -278,7 +278,7 @@ jobs:
278
278
  config-pretty: 'MT'
279
279
  upstream-details: ${{ needs.metadata.outputs.upstream-details }}
280
280
 
281
- release:
281
+ publish:
282
282
  if: inputs.build-type == 'release'
283
283
  needs:
284
284
  - metadata
@@ -291,43 +291,39 @@ jobs:
291
291
  - pytest-windows-3-11-mt
292
292
  runs-on: ubuntu-latest
293
293
  environment:
294
- name: pypi
294
+ name: PyPi
295
295
  permissions:
296
- contents: write
297
296
  id-token: write
298
-
299
297
  steps:
300
298
 
301
- - uses: actions/checkout@v4
302
-
303
- - name: Download Artifacts
304
- uses: actions/download-artifact@v4
305
- with:
306
- path: ./tmp
307
-
308
- - name: Clean up dir
309
- run: |
310
- mkdir -p dist
311
- find ./tmp -type f -name '*.whl' -exec mv -t ./dist {} +
312
- find ./tmp -type f -name '*.tar.gz' -exec mv -t ./dist {} +
313
- ls ./dist
314
-
315
- - name: Create Release
316
- uses: ncipollo/release-action@v1
317
- with:
318
- tag: ${{ needs.metadata.outputs.version }}
319
- commit: ${{ github.sha }}
320
- name: "${{ github.event.repository.name }} ${{ needs.metadata.outputs.version }}"
321
- artifactErrorsFailBuild: true
322
- generateReleaseNotes: true
323
- makeLatest: legacy
324
- artifacts: "dist/*"
325
- artifactContentType: application/gzip
326
-
327
- - name: Set up Python
328
- uses: actions/setup-python@v5
329
- with:
330
- python-version: "3.11"
331
-
332
- - name: Publish distribution to PyPI
333
- uses: pypa/gh-action-pypi-publish@release/v1
299
+ - name: Download Artifacts
300
+ uses: actions/download-artifact@v4
301
+ with:
302
+ path: ./tmp
303
+
304
+ - name: Configure environment
305
+ run: |
306
+ mkdir -p dist
307
+ find ./tmp -type f -name '*.whl' -exec cp -t ./dist {} +
308
+ find ./tmp -type f -name '*.tar.gz' -exec cp -t ./dist {} +
309
+ ls ./dist
310
+
311
+ - name: Set up Python
312
+ uses: actions/setup-python@v5
313
+ with:
314
+ python-version: "3.11"
315
+
316
+ - name: Publish [PyPi]
317
+ uses: pypa/gh-action-pypi-publish@release/v1
318
+
319
+ release:
320
+ if: inputs.build-type == 'release'
321
+ needs:
322
+ - metadata
323
+ - publish
324
+ uses: howsoai/.github/.github/workflows/release.yml@main
325
+ secrets: inherit
326
+ with:
327
+ publish_location: 'PyPi'
328
+ version: ${{ needs.metadata.outputs.version }}
329
+ publish_name: 'amalgam-lang'
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: amalgam-lang
3
- Version: 7.2.0
3
+ Version: 7.2.1
4
4
  Summary: A direct interface with Amalgam compiled DLL or so.
5
5
  Author: Howso Incorporated
6
6
  Author-email: support@howso.com
@@ -664,10 +664,10 @@ class Amalgam:
664
664
  The handle to assign the entity.
665
665
  amlg_path : str
666
666
  The path to the filename.amlg/caml file.
667
- persist : bool
667
+ persist : bool, default False
668
668
  If set to true, all transactions will trigger the entity to be
669
669
  saved over the original source.
670
- load_contained : bool
670
+ load_contained : bool, default False
671
671
  If set to true, contained entities will be loaded.
672
672
  write_log : str, default ""
673
673
  Path to the write log. If empty string, the write log is
@@ -737,6 +737,71 @@ class Amalgam:
737
737
  self.gc()
738
738
 
739
739
  return result
740
+
741
+ def clone_entity(
742
+ self,
743
+ handle: str,
744
+ clone_handle: str,
745
+ amlg_path: str = "",
746
+ persist: bool = False,
747
+ write_log: str = "",
748
+ print_log: str = ""
749
+ ) -> bool:
750
+ """
751
+ Clones entity specified by handle into a new entity specified by clone_handle.
752
+
753
+ Parameters
754
+ ----------
755
+ handle : str
756
+ The handle of the amalgam entity to clone.
757
+ clone_handle : str
758
+ The handle to clone the entity into.
759
+ amlg_path : str, default ""
760
+ The path to store the filename.amlg/caml file. Only relevant if persist is True.
761
+ persist : bool, default False
762
+ If set to true, all transactions will trigger the entity to be
763
+ saved over the original source.
764
+ write_log : str, default ""
765
+ Path to the write log. If empty string, the write log is
766
+ not generated.
767
+ print_log : str, default ""
768
+ Path to the print log. If empty string, the print log is
769
+ not generated.
770
+
771
+ Returns
772
+ -------
773
+ bool
774
+ True if cloned successfully, False if not.
775
+ """
776
+ self.amlg.CloneEntity.argtype = [
777
+ c_char_p, c_char_p, c_char_p, c_bool, c_char_p, c_char_p]
778
+ handle_buf = self.str_to_char_p(handle)
779
+ clone_handle_buf = self.str_to_char_p(clone_handle)
780
+ amlg_path_buf = self.str_to_char_p(amlg_path)
781
+ write_log_buf = self.str_to_char_p(write_log)
782
+ print_log_buf = self.str_to_char_p(print_log)
783
+
784
+ clone_command_log_entry = (
785
+ f'CLONE_ENTITY "{self.escape_double_quotes(handle)}" '
786
+ f'"{self.escape_double_quotes(clone_handle)}" '
787
+ f'"{self.escape_double_quotes(amlg_path)}" {str(persist).lower()} '
788
+ f'"{write_log}" "{print_log}"'
789
+ )
790
+ self._log_execution(clone_command_log_entry)
791
+ result = self.amlg.LoadEntity(
792
+ handle_buf, amlg_path_buf, persist,
793
+ write_log_buf, print_log_buf)
794
+ self._log_reply(result)
795
+
796
+ del handle_buf
797
+ del clone_handle_buf
798
+ del amlg_path_buf
799
+ del write_log_buf
800
+ del print_log_buf
801
+ self.gc()
802
+
803
+ return result
804
+
740
805
 
741
806
  def store_entity(
742
807
  self,
@@ -801,6 +866,42 @@ class Amalgam:
801
866
  del handle_buf
802
867
  self.gc()
803
868
 
869
+ def set_random_seed(
870
+ self,
871
+ handle: str,
872
+ rand_seed: str
873
+ ) -> bool:
874
+ """
875
+ Sets an entity's random seed.
876
+
877
+ Parameters
878
+ ----------
879
+ handle : str
880
+ The handle of the amalgam entity.
881
+ rand_seed : str
882
+ A string representing the random seed to set.
883
+
884
+ Returns
885
+ -------
886
+ bool
887
+ True if the set was successful, false if not.
888
+ """
889
+ self.amlg.SetRandomSeed.argtype = [c_char_p, c_char_p]
890
+ self.amlg.SetRandomSeed.restype = c_bool
891
+
892
+ handle_buf = self.str_to_char_p(handle)
893
+ rand_seed_buf = self.str_to_char_p(rand_seed)
894
+
895
+ self._log_execution(f'SET_RANDOM_SEED "{self.escape_double_quotes(handle)}"'
896
+ f'"{self.escape_double_quotes(rand_seed)}"')
897
+ result = self.amlg.SetRandomSeed(handle_buf, rand_seed)
898
+ self._log_reply(None)
899
+
900
+ del handle_buf
901
+ del rand_seed_buf
902
+ self.gc()
903
+ return result
904
+
804
905
  def get_entities(self) -> List[str]:
805
906
  """
806
907
  Get loaded top level entities.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: amalgam-lang
3
- Version: 7.2.0
3
+ Version: 7.2.1
4
4
  Summary: A direct interface with Amalgam compiled DLL or so.
5
5
  Author: Howso Incorporated
6
6
  Author-email: support@howso.com
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