amalgam-lang 12.4.4__py3-none-manylinux_2_29_aarch64.whl → 13.0.1__py3-none-manylinux_2_29_aarch64.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 amalgam-lang might be problematic. Click here for more details.
- amalgam/api.py +86 -60
- amalgam/lib/linux/arm64/amalgam-mt.so +0 -0
- amalgam/lib/linux/arm64/amalgam-omp.so +0 -0
- amalgam/lib/linux/arm64/amalgam-st.so +0 -0
- amalgam/lib/linux/arm64/docs/version.json +1 -1
- amalgam/lib/linux/arm64_8a/amalgam-st.so +0 -0
- amalgam/lib/linux/arm64_8a/docs/version.json +1 -1
- amalgam/lib/version.json +3 -3
- {amalgam_lang-12.4.4.dist-info → amalgam_lang-13.0.1.dist-info}/METADATA +1 -1
- amalgam_lang-13.0.1.dist-info/RECORD +14 -0
- {amalgam_lang-12.4.4.dist-info → amalgam_lang-13.0.1.dist-info}/WHEEL +1 -1
- amalgam_lang-12.4.4.dist-info/RECORD +0 -14
- {amalgam_lang-12.4.4.dist-info → amalgam_lang-13.0.1.dist-info}/LICENSE.txt +0 -0
- {amalgam_lang-12.4.4.dist-info → amalgam_lang-13.0.1.dist-info}/top_level.txt +0 -0
amalgam/api.py
CHANGED
|
@@ -6,6 +6,7 @@ from ctypes import (
|
|
|
6
6
|
)
|
|
7
7
|
from datetime import datetime
|
|
8
8
|
import gc
|
|
9
|
+
import json as json_lib
|
|
9
10
|
import logging
|
|
10
11
|
from pathlib import Path
|
|
11
12
|
import platform
|
|
@@ -698,12 +699,11 @@ class Amalgam:
|
|
|
698
699
|
def load_entity(
|
|
699
700
|
self,
|
|
700
701
|
handle: str,
|
|
701
|
-
|
|
702
|
+
file_path: str,
|
|
702
703
|
*,
|
|
704
|
+
file_type: str = "",
|
|
703
705
|
persist: bool = False,
|
|
704
|
-
|
|
705
|
-
escape_filename: bool = False,
|
|
706
|
-
escape_contained_filenames: bool = True,
|
|
706
|
+
json_file_params: str = "",
|
|
707
707
|
write_log: str = "",
|
|
708
708
|
print_log: str = ""
|
|
709
709
|
) -> LoadEntityStatus:
|
|
@@ -714,18 +714,17 @@ class Amalgam:
|
|
|
714
714
|
----------
|
|
715
715
|
handle : str
|
|
716
716
|
The handle to assign the entity.
|
|
717
|
-
|
|
718
|
-
The path
|
|
717
|
+
file_path : str
|
|
718
|
+
The path of the file name to load.
|
|
719
|
+
file_type : str, default ""
|
|
720
|
+
If set to a nonempty string, will represent the type of file to load.
|
|
719
721
|
persist : bool, default False
|
|
720
|
-
If set to true, all transactions
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
escape_contained_filenames : bool, default True
|
|
727
|
-
If set to true, the filenames of contained entities will be
|
|
728
|
-
aggressively escaped.
|
|
722
|
+
If set to true, all transactions that update the entity will also be
|
|
723
|
+
written to the files.
|
|
724
|
+
json_file_params : str, default ""
|
|
725
|
+
Either empty string or a string of json specifying a set of key-value pairs
|
|
726
|
+
which are parameters specific to the file type. See Amalgam documentation
|
|
727
|
+
for details of allowed parameters.
|
|
729
728
|
write_log : str, default ""
|
|
730
729
|
Path to the write log. If empty string, the write log is
|
|
731
730
|
not generated.
|
|
@@ -739,29 +738,32 @@ class Amalgam:
|
|
|
739
738
|
Status of LoadEntity call.
|
|
740
739
|
"""
|
|
741
740
|
self.amlg.LoadEntity.argtypes = [
|
|
742
|
-
c_char_p, c_char_p,
|
|
741
|
+
c_char_p, c_char_p, c_char_p, c_bool, c_char_p, c_char_p, c_char_p]
|
|
743
742
|
self.amlg.LoadEntity.restype = _LoadEntityStatus
|
|
744
743
|
handle_buf = self.str_to_char_p(handle)
|
|
745
|
-
|
|
744
|
+
file_path_buf = self.str_to_char_p(file_path)
|
|
745
|
+
file_type_buf = self.str_to_char_p(file_type)
|
|
746
|
+
json_file_params_buf = self.str_to_char_p(json_file_params)
|
|
746
747
|
write_log_buf = self.str_to_char_p(write_log)
|
|
747
748
|
print_log_buf = self.str_to_char_p(print_log)
|
|
748
749
|
|
|
749
750
|
load_command_log_entry = (
|
|
750
751
|
f"LOAD_ENTITY \"{self.escape_double_quotes(handle)}\" "
|
|
751
|
-
f"\"{self.escape_double_quotes(
|
|
752
|
-
f"{
|
|
753
|
-
f"{
|
|
754
|
-
f"\"{print_log}\""
|
|
752
|
+
f"\"{self.escape_double_quotes(file_path)}\" "
|
|
753
|
+
f"\"{self.escape_double_quotes(file_type)}\" {str(persist).lower()} "
|
|
754
|
+
f"{json_lib.dumps(json_file_params)} "
|
|
755
|
+
f"\"{write_log}\" \"{print_log}\""
|
|
755
756
|
)
|
|
756
757
|
self._log_execution(load_command_log_entry)
|
|
757
758
|
result = LoadEntityStatus(self, self.amlg.LoadEntity(
|
|
758
|
-
handle_buf,
|
|
759
|
-
|
|
760
|
-
write_log_buf, print_log_buf))
|
|
759
|
+
handle_buf, file_path_buf, file_type_buf, persist,
|
|
760
|
+
json_file_params_buf, write_log_buf, print_log_buf))
|
|
761
761
|
self._log_reply(result)
|
|
762
762
|
|
|
763
763
|
del handle_buf
|
|
764
|
-
del
|
|
764
|
+
del file_path_buf
|
|
765
|
+
del file_type_buf
|
|
766
|
+
del json_file_params_buf
|
|
765
767
|
del write_log_buf
|
|
766
768
|
del print_log_buf
|
|
767
769
|
self.gc()
|
|
@@ -770,14 +772,14 @@ class Amalgam:
|
|
|
770
772
|
|
|
771
773
|
def verify_entity(
|
|
772
774
|
self,
|
|
773
|
-
|
|
775
|
+
file_path: str
|
|
774
776
|
) -> LoadEntityStatus:
|
|
775
777
|
"""
|
|
776
778
|
Verify an entity from an amalgam source file.
|
|
777
779
|
|
|
778
780
|
Parameters
|
|
779
781
|
----------
|
|
780
|
-
|
|
782
|
+
file_path : str
|
|
781
783
|
The path to the filename.amlg/caml file.
|
|
782
784
|
|
|
783
785
|
Returns
|
|
@@ -787,13 +789,13 @@ class Amalgam:
|
|
|
787
789
|
"""
|
|
788
790
|
self.amlg.VerifyEntity.argtypes = [c_char_p]
|
|
789
791
|
self.amlg.VerifyEntity.restype = _LoadEntityStatus
|
|
790
|
-
|
|
792
|
+
file_path_buf = self.str_to_char_p(file_path)
|
|
791
793
|
|
|
792
|
-
self._log_execution(f"VERIFY_ENTITY \"{self.escape_double_quotes(
|
|
793
|
-
result = LoadEntityStatus(self, self.amlg.VerifyEntity(
|
|
794
|
+
self._log_execution(f"VERIFY_ENTITY \"{self.escape_double_quotes(file_path)}\"")
|
|
795
|
+
result = LoadEntityStatus(self, self.amlg.VerifyEntity(file_path_buf))
|
|
794
796
|
self._log_reply(result)
|
|
795
797
|
|
|
796
|
-
del
|
|
798
|
+
del file_path_buf
|
|
797
799
|
self.gc()
|
|
798
800
|
|
|
799
801
|
return result
|
|
@@ -803,8 +805,10 @@ class Amalgam:
|
|
|
803
805
|
handle: str,
|
|
804
806
|
clone_handle: str,
|
|
805
807
|
*,
|
|
806
|
-
|
|
808
|
+
file_path: str = "",
|
|
809
|
+
file_type: str = "",
|
|
807
810
|
persist: bool = False,
|
|
811
|
+
json_file_params: str = "",
|
|
808
812
|
write_log: str = "",
|
|
809
813
|
print_log: str = ""
|
|
810
814
|
) -> bool:
|
|
@@ -817,11 +821,17 @@ class Amalgam:
|
|
|
817
821
|
The handle of the amalgam entity to clone.
|
|
818
822
|
clone_handle : str
|
|
819
823
|
The handle to clone the entity into.
|
|
820
|
-
|
|
821
|
-
The path
|
|
824
|
+
file_path : str, default ""
|
|
825
|
+
The path of the file name to load.
|
|
826
|
+
file_type : str, default ""
|
|
827
|
+
If set to a nonempty string, will represent the type of file to load.
|
|
822
828
|
persist : bool, default False
|
|
823
|
-
If set to true, all transactions
|
|
824
|
-
|
|
829
|
+
If set to true, all transactions that update the entity will also be
|
|
830
|
+
written to the files.
|
|
831
|
+
json_file_params : str, default ""
|
|
832
|
+
Either empty string or a string of json specifying a set of key-value pairs
|
|
833
|
+
which are parameters specific to the file type. See Amalgam documentation
|
|
834
|
+
for details of allowed parameters.
|
|
825
835
|
write_log : str, default ""
|
|
826
836
|
Path to the write log. If empty string, the write log is
|
|
827
837
|
not generated.
|
|
@@ -835,28 +845,34 @@ class Amalgam:
|
|
|
835
845
|
True if cloned successfully, False if not.
|
|
836
846
|
"""
|
|
837
847
|
self.amlg.CloneEntity.argtypes = [
|
|
838
|
-
c_char_p, c_char_p, c_char_p, c_bool, c_char_p, c_char_p]
|
|
848
|
+
c_char_p, c_char_p, c_char_p, c_char_p, c_bool, c_char_p, c_char_p, c_char_p]
|
|
839
849
|
handle_buf = self.str_to_char_p(handle)
|
|
840
850
|
clone_handle_buf = self.str_to_char_p(clone_handle)
|
|
841
|
-
|
|
851
|
+
file_path_buf = self.str_to_char_p(file_path)
|
|
852
|
+
file_type_buf = self.str_to_char_p(file_type)
|
|
853
|
+
json_file_params_buf = self.str_to_char_p(json_file_params)
|
|
842
854
|
write_log_buf = self.str_to_char_p(write_log)
|
|
843
855
|
print_log_buf = self.str_to_char_p(print_log)
|
|
844
856
|
|
|
845
857
|
clone_command_log_entry = (
|
|
846
858
|
f'CLONE_ENTITY "{self.escape_double_quotes(handle)}" '
|
|
847
859
|
f'"{self.escape_double_quotes(clone_handle)}" '
|
|
848
|
-
f
|
|
849
|
-
f
|
|
860
|
+
f"\"{self.escape_double_quotes(file_path)}\" "
|
|
861
|
+
f"\"{self.escape_double_quotes(file_type)}\" {str(persist).lower()} "
|
|
862
|
+
f"{json_lib.dumps(json_file_params)} "
|
|
863
|
+
f"\"{write_log}\" \"{print_log}\""
|
|
850
864
|
)
|
|
851
865
|
self._log_execution(clone_command_log_entry)
|
|
852
866
|
result = self.amlg.CloneEntity(
|
|
853
|
-
handle_buf, clone_handle_buf,
|
|
854
|
-
write_log_buf, print_log_buf)
|
|
867
|
+
handle_buf, clone_handle_buf, file_path_buf, file_type_buf, persist,
|
|
868
|
+
json_file_params_buf, write_log_buf, print_log_buf)
|
|
855
869
|
self._log_reply(result)
|
|
856
870
|
|
|
857
871
|
del handle_buf
|
|
858
872
|
del clone_handle_buf
|
|
859
|
-
del
|
|
873
|
+
del file_path_buf
|
|
874
|
+
del file_type_buf
|
|
875
|
+
del json_file_params_buf
|
|
860
876
|
del write_log_buf
|
|
861
877
|
del print_log_buf
|
|
862
878
|
self.gc()
|
|
@@ -866,43 +882,53 @@ class Amalgam:
|
|
|
866
882
|
def store_entity(
|
|
867
883
|
self,
|
|
868
884
|
handle: str,
|
|
869
|
-
|
|
885
|
+
file_path: str,
|
|
870
886
|
*,
|
|
871
|
-
|
|
872
|
-
|
|
887
|
+
file_type: str = "",
|
|
888
|
+
persist: bool = False,
|
|
889
|
+
json_file_params: str = "",
|
|
873
890
|
):
|
|
874
891
|
"""
|
|
875
|
-
Store entity to the file type specified within
|
|
892
|
+
Store entity to the file type specified within file_path.
|
|
876
893
|
|
|
877
894
|
Parameters
|
|
878
895
|
----------
|
|
879
896
|
handle : str
|
|
880
897
|
The handle of the amalgam entity.
|
|
881
|
-
|
|
882
|
-
The path
|
|
883
|
-
|
|
884
|
-
If set to
|
|
885
|
-
|
|
886
|
-
If set to true,
|
|
898
|
+
file_path : str
|
|
899
|
+
The path of the file name to load.
|
|
900
|
+
file_type : str, default ""
|
|
901
|
+
If set to a nonempty string, will represent the type of file to load.
|
|
902
|
+
persist : bool, default False
|
|
903
|
+
If set to true, all transactions that update the entity will also be
|
|
904
|
+
written to the files.
|
|
905
|
+
json_file_params : str, default ""
|
|
906
|
+
Either empty string or a string of json specifying a set of key-value pairs
|
|
907
|
+
which are parameters specific to the file type. See Amalgam documentation
|
|
908
|
+
for details of allowed parameters.
|
|
887
909
|
"""
|
|
888
910
|
self.amlg.StoreEntity.argtypes = [
|
|
889
|
-
c_char_p, c_char_p, c_bool,
|
|
911
|
+
c_char_p, c_char_p, c_char_p, c_bool, c_char_p]
|
|
890
912
|
handle_buf = self.str_to_char_p(handle)
|
|
891
|
-
|
|
913
|
+
file_path_buf = self.str_to_char_p(file_path)
|
|
914
|
+
file_type_buf = self.str_to_char_p(file_type)
|
|
915
|
+
json_file_params_buf = self.str_to_char_p(json_file_params)
|
|
892
916
|
|
|
893
917
|
store_command_log_entry = (
|
|
894
918
|
f"STORE_ENTITY \"{self.escape_double_quotes(handle)}\" "
|
|
895
|
-
f"\"{self.escape_double_quotes(
|
|
896
|
-
f"{str(
|
|
897
|
-
f"{
|
|
919
|
+
f"\"{self.escape_double_quotes(file_path)}\" "
|
|
920
|
+
f"\"{self.escape_double_quotes(file_type)}\" {str(persist).lower()} "
|
|
921
|
+
f"{json_lib.dumps(json_file_params)} "
|
|
898
922
|
)
|
|
899
923
|
self._log_execution(store_command_log_entry)
|
|
900
924
|
self.amlg.StoreEntity(
|
|
901
|
-
handle_buf,
|
|
925
|
+
handle_buf, file_path_buf, file_type_buf, persist, json_file_params_buf)
|
|
902
926
|
self._log_reply(None)
|
|
903
927
|
|
|
904
928
|
del handle_buf
|
|
905
|
-
del
|
|
929
|
+
del file_path_buf
|
|
930
|
+
del file_type_buf
|
|
931
|
+
del json_file_params_buf
|
|
906
932
|
self.gc()
|
|
907
933
|
|
|
908
934
|
def destroy_entity(
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
amalgam/lib/version.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": {
|
|
3
|
-
"amalgam": "
|
|
4
|
-
"amalgam_sha": "
|
|
5
|
-
"amalgam_url": "https://github.com/howsoai/amalgam/releases/tag/
|
|
3
|
+
"amalgam": "55.1.0",
|
|
4
|
+
"amalgam_sha": "e17f52b8baf84757d2e312725fe2f62368fcee53",
|
|
5
|
+
"amalgam_url": "https://github.com/howsoai/amalgam/releases/tag/55.1.0",
|
|
6
6
|
"amalgam_build_date": "",
|
|
7
7
|
"amalgam_display_title": ""
|
|
8
8
|
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
amalgam/__init__.py,sha256=oHu7Zr4eGDUqj93pLwz8t7gLa8lpAx6Q-xbGiJ3nJx0,18
|
|
2
|
+
amalgam/api.py,sha256=32K9fOdTJTiJYHqs3mX2q9dqxkLCA72POQ5Ri958Tzk,38164
|
|
3
|
+
amalgam/lib/version.json,sha256=FaQDg5wx8SQmhHrUeyodj186RQP9cpMc6to4gfSh0Ws,250
|
|
4
|
+
amalgam/lib/linux/arm64/amalgam-mt.so,sha256=CKTzO2RDD_pWP1mTCLS1ZGqdcNeJmnTI6wYCXABKDQ8,3597744
|
|
5
|
+
amalgam/lib/linux/arm64/amalgam-omp.so,sha256=8GL84LW2fzsvqlYvZx64IclLJp8DzpyGo5lr4hMICo4,3453168
|
|
6
|
+
amalgam/lib/linux/arm64/amalgam-st.so,sha256=W4Xo4lzm9lmg17nugrrnDOby2jf4vkujwPYvgVPmffo,3462936
|
|
7
|
+
amalgam/lib/linux/arm64/docs/version.json,sha256=kyZUKu0oBwEegnU7s4FgFSpfKKT-Kc9Yiuc3rQauh-o,25
|
|
8
|
+
amalgam/lib/linux/arm64_8a/amalgam-st.so,sha256=9zGcm1U1Pd39AFmt7yaMg7_auvPbc-Ker62IeYv2JbM,3457080
|
|
9
|
+
amalgam/lib/linux/arm64_8a/docs/version.json,sha256=kyZUKu0oBwEegnU7s4FgFSpfKKT-Kc9Yiuc3rQauh-o,25
|
|
10
|
+
amalgam_lang-13.0.1.dist-info/LICENSE.txt,sha256=2xqHuoHohba7gpcZZKtOICRjzeKsQANXG8WoV9V35KM,33893
|
|
11
|
+
amalgam_lang-13.0.1.dist-info/METADATA,sha256=4KZ0hKDwdm9xJH-8h4ksWVifGzYMG2uZg-0Tj5FVBfk,43814
|
|
12
|
+
amalgam_lang-13.0.1.dist-info/WHEEL,sha256=OVMc5UfuAQiSplgO0_WdW7vXVGAt9Hdd6qtN4HotdyA,91
|
|
13
|
+
amalgam_lang-13.0.1.dist-info/top_level.txt,sha256=rmPHU144SyaB25u5-FAQyECAQnJ39NvuJEcKXMRcdBo,8
|
|
14
|
+
amalgam_lang-13.0.1.dist-info/RECORD,,
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
amalgam/__init__.py,sha256=oHu7Zr4eGDUqj93pLwz8t7gLa8lpAx6Q-xbGiJ3nJx0,18
|
|
2
|
-
amalgam/api.py,sha256=IWS--0NCnhsadMYSna2gLllNxG_i3HpymY3eXbugwDU,36796
|
|
3
|
-
amalgam/lib/version.json,sha256=YUvyuI1u1VNGsViFkBaVkyjSQCJFGEeS-pjO1bXKgbg,250
|
|
4
|
-
amalgam/lib/linux/arm64/amalgam-mt.so,sha256=c6CNkaFUPUMwbawKV9CEkdj4l87exr7cZ4LEEsNmRIw,3612800
|
|
5
|
-
amalgam/lib/linux/arm64/amalgam-omp.so,sha256=1ojzi1Tu2c5GYox4U0_PNKCqP__-eetDhsxUx_m1Low,3458768
|
|
6
|
-
amalgam/lib/linux/arm64/amalgam-st.so,sha256=DQ_B7A67OWeX9CuDcEHcd5pyaKHfcVEyAGd1NOad94Y,3452008
|
|
7
|
-
amalgam/lib/linux/arm64/docs/version.json,sha256=iFB5iMUd5KXilFjyNpKKAPuGfeR5wj7jYdEeg8AQCWI,25
|
|
8
|
-
amalgam/lib/linux/arm64_8a/amalgam-st.so,sha256=saItbssOhl7iwG-SP9plUHJHBxO8Qb-1GxMAAbZ3Q8g,3458800
|
|
9
|
-
amalgam/lib/linux/arm64_8a/docs/version.json,sha256=iFB5iMUd5KXilFjyNpKKAPuGfeR5wj7jYdEeg8AQCWI,25
|
|
10
|
-
amalgam_lang-12.4.4.dist-info/LICENSE.txt,sha256=2xqHuoHohba7gpcZZKtOICRjzeKsQANXG8WoV9V35KM,33893
|
|
11
|
-
amalgam_lang-12.4.4.dist-info/METADATA,sha256=Qy0sURSJz_nql2f0xXwsydhHSAHEMdHRs4Kbbos4pQo,43814
|
|
12
|
-
amalgam_lang-12.4.4.dist-info/WHEEL,sha256=GV9aMThwP_4oNCtvEC2ec3qUYutgWeAzklro_0m4WJQ,91
|
|
13
|
-
amalgam_lang-12.4.4.dist-info/top_level.txt,sha256=rmPHU144SyaB25u5-FAQyECAQnJ39NvuJEcKXMRcdBo,8
|
|
14
|
-
amalgam_lang-12.4.4.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|