File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed
Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change 88# We set the limit to 50MB to be safe and consistent with the other SDKs (where this limit is 64MB), to be reconsidered upon further testing
99MESSAGE_LIMIT = 50 * 1024 * 1024
1010
11- machine_arch = platform .machine ()
12- python_version = platform .python_version ()[:4 ]
11+ machine_arch = platform .machine (). lower ()
12+ major , minor = map ( int , platform .python_version ()[:4 ]. split ( '.' ))
1313base_path = "onepassword.lib"
14-
1514arch_map = {
1615 "x86_64" : "x86_64" ,
1716 "amd64" : "x86_64" ,
2221if machine_arch not in arch_map :
2322 raise ImportError (f"Your machine's architecture is not currently supported: { machine_arch } " )
2423
25- if platform .system ().lower () == "Darwin " :
24+ if platform .system ().lower () == "darwin " :
2625 if arch_map [machine_arch ] == "x86_64" :
27- core_path = f"{ base_path } .x86_64_macosx_10_13.op_uniffi_core" if python_version > "3.13" else f"{ base_path } .x86_64_macosx_10_9.op_uniffi_core"
26+ core_path = f"{ base_path } .x86_64_macosx_10_13.op_uniffi_core" if major > 3 and minor >= 13 else f"{ base_path } .x86_64_macosx_10_9.op_uniffi_core"
2827 else :
2928 core_path = f"{ base_path } .aarch64_macosx_11_0.op_uniffi_core"
3029else :
You can’t perform that action at this time.
0 commit comments