Nuitka-winsvc 2.4.8__cp311-cp311-win_amd64.whl → 2.5.1__cp311-cp311-win_amd64.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 Nuitka-winsvc might be problematic. Click here for more details.

Files changed (294) hide show
  1. {Nuitka_winsvc-2.4.8.dist-info → Nuitka_winsvc-2.5.1.dist-info}/METADATA +2 -1
  2. {Nuitka_winsvc-2.4.8.dist-info → Nuitka_winsvc-2.5.1.dist-info}/RECORD +294 -271
  3. {Nuitka_winsvc-2.4.8.dist-info → Nuitka_winsvc-2.5.1.dist-info}/WHEEL +1 -1
  4. nuitka/Builtins.py +31 -0
  5. nuitka/HardImportRegistry.py +8 -0
  6. nuitka/MainControl.py +9 -4
  7. nuitka/OptionParsing.py +105 -52
  8. nuitka/Options.py +73 -16
  9. nuitka/OutputDirectories.py +7 -2
  10. nuitka/PostProcessing.py +69 -38
  11. nuitka/Progress.py +16 -1
  12. nuitka/PythonVersions.py +2 -1
  13. nuitka/Serialization.py +4 -2
  14. nuitka/Tracing.py +69 -1
  15. nuitka/Version.py +2 -2
  16. nuitka/build/Backend.scons +45 -5
  17. nuitka/build/CCompilerVersion.scons +6 -0
  18. nuitka/build/Onefile.scons +6 -0
  19. nuitka/build/SconsCaching.py +12 -2
  20. nuitka/build/SconsCompilerSettings.py +17 -6
  21. nuitka/build/SconsInterface.py +1 -0
  22. nuitka/build/SconsUtils.py +5 -0
  23. nuitka/build/include/nuitka/allocator.h +124 -1
  24. nuitka/build/include/nuitka/calling.h +6 -6
  25. nuitka/build/include/nuitka/compiled_asyncgen.h +10 -7
  26. nuitka/build/include/nuitka/compiled_frame.h +2 -1
  27. nuitka/build/include/nuitka/constants.h +6 -0
  28. nuitka/build/include/nuitka/debug_settings.h +60 -0
  29. nuitka/build/include/nuitka/exceptions.h +264 -121
  30. nuitka/build/include/nuitka/helper/attributes.h +0 -4
  31. nuitka/build/include/nuitka/helper/calling_generated.h +52 -52
  32. nuitka/build/include/nuitka/helper/comparisons_dual_eq.h +47 -0
  33. nuitka/build/include/nuitka/helper/comparisons_dual_ge.h +39 -0
  34. nuitka/build/include/nuitka/helper/comparisons_dual_gt.h +39 -0
  35. nuitka/build/include/nuitka/helper/comparisons_dual_le.h +47 -0
  36. nuitka/build/include/nuitka/helper/comparisons_dual_lt.h +47 -0
  37. nuitka/build/include/nuitka/helper/comparisons_dual_ne.h +39 -0
  38. nuitka/build/include/nuitka/helper/dictionaries.h +65 -29
  39. nuitka/build/include/nuitka/helper/ints.h +86 -37
  40. nuitka/build/include/nuitka/helper/iterators.h +82 -34
  41. nuitka/build/include/nuitka/helper/operations.h +3 -0
  42. nuitka/build/include/nuitka/helper/operations_binary_add.h +6 -0
  43. nuitka/build/include/nuitka/helper/operations_binary_dual_add.h +34 -0
  44. nuitka/build/include/nuitka/helper/operations_binary_sub.h +6 -0
  45. nuitka/build/include/nuitka/helper/operations_inplace_add.h +3 -0
  46. nuitka/build/include/nuitka/helper/operations_inplace_sub.h +3 -0
  47. nuitka/build/include/nuitka/helper/raising.h +47 -28
  48. nuitka/build/include/nuitka/helper/richcomparisons.h +7 -0
  49. nuitka/build/include/nuitka/helpers.h +12 -2
  50. nuitka/build/include/nuitka/prelude.h +35 -25
  51. nuitka/build/include/nuitka/printing.h +9 -7
  52. nuitka/build/include/nuitka/threading.h +15 -1
  53. nuitka/build/include/nuitka/type_aliases.h +3 -0
  54. nuitka/build/inline_copy/stubgen/astunparse.py +938 -0
  55. nuitka/build/inline_copy/stubgen/six.py +998 -0
  56. nuitka/build/inline_copy/stubgen/stubgen.py +307 -0
  57. nuitka/build/static_src/CompiledAsyncgenType.c +45 -39
  58. nuitka/build/static_src/CompiledCellType.c +6 -4
  59. nuitka/build/static_src/CompiledCodeHelpers.c +104 -40
  60. nuitka/build/static_src/CompiledCoroutineType.c +40 -30
  61. nuitka/build/static_src/CompiledFrameType.c +110 -79
  62. nuitka/build/static_src/CompiledFunctionType.c +173 -151
  63. nuitka/build/static_src/CompiledGeneratorType.c +51 -49
  64. nuitka/build/static_src/CompiledGeneratorTypeUncompiledIntegration.c +424 -46
  65. nuitka/build/static_src/CompiledMethodType.c +10 -13
  66. nuitka/build/static_src/HelpersAllocator.c +270 -32
  67. nuitka/build/static_src/HelpersAttributes.c +0 -21
  68. nuitka/build/static_src/HelpersBuiltin.c +22 -13
  69. nuitka/build/static_src/HelpersCalling.c +7 -7
  70. nuitka/build/static_src/HelpersCallingGenerated.c +70 -70
  71. nuitka/build/static_src/HelpersComparisonDualEq.c +183 -0
  72. nuitka/build/static_src/HelpersComparisonDualGe.c +121 -0
  73. nuitka/build/static_src/HelpersComparisonDualGt.c +121 -0
  74. nuitka/build/static_src/HelpersComparisonDualLe.c +183 -0
  75. nuitka/build/static_src/HelpersComparisonDualLt.c +183 -0
  76. nuitka/build/static_src/HelpersComparisonDualNe.c +121 -0
  77. nuitka/build/static_src/HelpersComparisonEq.c +18 -4
  78. nuitka/build/static_src/HelpersComparisonEqUtils.c +1 -0
  79. nuitka/build/static_src/HelpersComparisonGe.c +18 -4
  80. nuitka/build/static_src/HelpersComparisonGt.c +18 -4
  81. nuitka/build/static_src/HelpersComparisonLe.c +18 -4
  82. nuitka/build/static_src/HelpersComparisonLt.c +18 -4
  83. nuitka/build/static_src/HelpersComparisonNe.c +18 -4
  84. nuitka/build/static_src/HelpersConsole.c +34 -8
  85. nuitka/build/static_src/HelpersConstantsBlob.c +10 -4
  86. nuitka/build/static_src/HelpersDictionaries.c +181 -34
  87. nuitka/build/static_src/HelpersDictionariesGenerated.c +0 -106
  88. nuitka/build/static_src/HelpersExceptions.c +24 -50
  89. nuitka/build/static_src/HelpersFiles.c +79 -5
  90. nuitka/build/static_src/HelpersImport.c +13 -9
  91. nuitka/build/static_src/HelpersImportHard.c +23 -46
  92. nuitka/build/static_src/HelpersLists.c +98 -9
  93. nuitka/build/static_src/HelpersMatching.c +1 -1
  94. nuitka/build/static_src/HelpersOperationBinaryAdd.c +224 -6
  95. nuitka/build/static_src/HelpersOperationBinaryAddUtils.c +3 -0
  96. nuitka/build/static_src/HelpersOperationBinaryBitand.c +5 -5
  97. nuitka/build/static_src/HelpersOperationBinaryBitor.c +5 -5
  98. nuitka/build/static_src/HelpersOperationBinaryBitxor.c +5 -5
  99. nuitka/build/static_src/HelpersOperationBinaryDivmod.c +8 -2
  100. nuitka/build/static_src/HelpersOperationBinaryDualAdd.c +172 -0
  101. nuitka/build/static_src/HelpersOperationBinaryFloordiv.c +14 -8
  102. nuitka/build/static_src/HelpersOperationBinaryLshift.c +36 -36
  103. nuitka/build/static_src/HelpersOperationBinaryMatmult.c +1 -0
  104. nuitka/build/static_src/HelpersOperationBinaryMod.c +22 -10
  105. nuitka/build/static_src/HelpersOperationBinaryMult.c +17 -7
  106. nuitka/build/static_src/HelpersOperationBinaryOlddiv.c +14 -8
  107. nuitka/build/static_src/HelpersOperationBinaryPow.c +24 -24
  108. nuitka/build/static_src/HelpersOperationBinaryRshift.c +4 -4
  109. nuitka/build/static_src/HelpersOperationBinarySub.c +229 -8
  110. nuitka/build/static_src/HelpersOperationBinaryTruediv.c +8 -2
  111. nuitka/build/static_src/HelpersOperationInplaceAdd.c +162 -10
  112. nuitka/build/static_src/HelpersOperationInplaceBitand.c +5 -5
  113. nuitka/build/static_src/HelpersOperationInplaceBitor.c +5 -5
  114. nuitka/build/static_src/HelpersOperationInplaceBitxor.c +5 -5
  115. nuitka/build/static_src/HelpersOperationInplaceFloordiv.c +11 -6
  116. nuitka/build/static_src/HelpersOperationInplaceLshift.c +20 -20
  117. nuitka/build/static_src/HelpersOperationInplaceMatmult.c +1 -0
  118. nuitka/build/static_src/HelpersOperationInplaceMod.c +11 -6
  119. nuitka/build/static_src/HelpersOperationInplaceMult.c +11 -6
  120. nuitka/build/static_src/HelpersOperationInplaceOlddiv.c +11 -6
  121. nuitka/build/static_src/HelpersOperationInplacePow.c +20 -20
  122. nuitka/build/static_src/HelpersOperationInplaceRshift.c +4 -4
  123. nuitka/build/static_src/HelpersOperationInplaceSub.c +163 -10
  124. nuitka/build/static_src/HelpersOperationInplaceTruediv.c +6 -1
  125. nuitka/build/static_src/HelpersProfiling.c +1 -1
  126. nuitka/build/static_src/HelpersRaising.c +255 -310
  127. nuitka/build/static_src/HelpersStrings.c +1 -1
  128. nuitka/build/static_src/HelpersTuples.c +1 -1
  129. nuitka/build/static_src/HelpersTypes.c +98 -2
  130. nuitka/build/static_src/MainProgram.c +117 -29
  131. nuitka/build/static_src/MetaPathBasedLoader.c +18 -19
  132. nuitka/build/static_src/MetaPathBasedLoaderResourceReaderFiles.c +134 -11
  133. nuitka/build/static_src/OnefileBootstrap.c +6 -1
  134. nuitka/code_generation/AsyncgenCodes.py +2 -6
  135. nuitka/code_generation/BinaryOperationHelperDefinitions.py +269 -167
  136. nuitka/code_generation/BuiltinCodes.py +9 -1
  137. nuitka/code_generation/CallCodes.py +16 -16
  138. nuitka/code_generation/CodeGeneration.py +14 -2
  139. nuitka/code_generation/CodeHelperSelection.py +1 -1
  140. nuitka/code_generation/CodeHelpers.py +4 -1
  141. nuitka/code_generation/CodeObjectCodes.py +2 -2
  142. nuitka/code_generation/ComparisonCodes.py +13 -2
  143. nuitka/code_generation/ComparisonHelperDefinitions.py +23 -8
  144. nuitka/code_generation/Contexts.py +28 -16
  145. nuitka/code_generation/CoroutineCodes.py +2 -6
  146. nuitka/code_generation/DictCodes.py +3 -3
  147. nuitka/code_generation/ErrorCodes.py +34 -50
  148. nuitka/code_generation/ExceptionCodes.py +165 -96
  149. nuitka/code_generation/ExpressionCTypeSelectionHelpers.py +25 -10
  150. nuitka/code_generation/FrameCodes.py +4 -11
  151. nuitka/code_generation/FunctionCodes.py +2 -6
  152. nuitka/code_generation/GeneratorCodes.py +2 -6
  153. nuitka/code_generation/GlobalConstants.py +8 -2
  154. nuitka/code_generation/GlobalsLocalsCodes.py +2 -2
  155. nuitka/code_generation/IteratorCodes.py +67 -54
  156. nuitka/code_generation/LineNumberCodes.py +1 -3
  157. nuitka/code_generation/ModuleCodes.py +28 -4
  158. nuitka/code_generation/OperationCodes.py +51 -20
  159. nuitka/code_generation/PackageResourceCodes.py +37 -0
  160. nuitka/code_generation/RaisingCodes.py +164 -90
  161. nuitka/code_generation/Reports.py +13 -5
  162. nuitka/code_generation/ReturnCodes.py +2 -16
  163. nuitka/code_generation/TryCodes.py +12 -24
  164. nuitka/code_generation/TypeAliasCodes.py +48 -0
  165. nuitka/code_generation/VariableCodes.py +99 -40
  166. nuitka/code_generation/VariableDeclarations.py +8 -8
  167. nuitka/code_generation/YieldCodes.py +1 -1
  168. nuitka/code_generation/c_types/CTypeBases.py +10 -2
  169. nuitka/code_generation/c_types/CTypeModuleDictVariables.py +3 -0
  170. nuitka/code_generation/c_types/CTypeNuitkaBooleans.py +3 -4
  171. nuitka/code_generation/c_types/CTypeNuitkaInts.py +70 -25
  172. nuitka/code_generation/c_types/CTypeNuitkaVoids.py +1 -1
  173. nuitka/code_generation/c_types/CTypePyObjectPointers.py +16 -6
  174. nuitka/code_generation/templates/CodeTemplatesAsyncgens.py +2 -2
  175. nuitka/code_generation/templates/CodeTemplatesConstants.py +11 -3
  176. nuitka/code_generation/templates/CodeTemplatesCoroutines.py +2 -2
  177. nuitka/code_generation/templates/CodeTemplatesExceptions.py +15 -16
  178. nuitka/code_generation/templates/CodeTemplatesFrames.py +18 -10
  179. nuitka/code_generation/templates/CodeTemplatesFunction.py +2 -2
  180. nuitka/code_generation/templates/CodeTemplatesGeneratorFunction.py +2 -2
  181. nuitka/code_generation/templates/CodeTemplatesIterators.py +1 -35
  182. nuitka/code_generation/templates/CodeTemplatesModules.py +34 -4
  183. nuitka/code_generation/templates/CodeTemplatesVariables.py +73 -0
  184. nuitka/code_generation/templates_c/CodeTemplateCallsMixed.c.j2 +3 -3
  185. nuitka/code_generation/templates_c/CodeTemplateCallsPositional.c.j2 +3 -3
  186. nuitka/code_generation/templates_c/HelperDictionaryCopy.c.j2 +0 -105
  187. nuitka/code_generation/templates_c/HelperImportHard.c.j2 +1 -2
  188. nuitka/code_generation/templates_c/HelperLongTools.c.j2 +1 -1
  189. nuitka/code_generation/templates_c/HelperOperationBinaryDual.c.j2 +115 -0
  190. nuitka/code_generation/templates_c/HelperOperationComparisonBytes.c.j2 +9 -9
  191. nuitka/code_generation/templates_c/HelperOperationComparisonDual.c.j2 +86 -0
  192. nuitka/code_generation/templates_c/HelperOperationComparisonFloat.c.j2 +1 -1
  193. nuitka/code_generation/templates_c/HelperOperationComparisonInt.c.j2 +1 -1
  194. nuitka/code_generation/templates_c/HelperOperationComparisonList.c.j2 +9 -9
  195. nuitka/code_generation/templates_c/HelperOperationComparisonLong.c.j2 +7 -7
  196. nuitka/code_generation/templates_c/HelperOperationComparisonStr.c.j2 +9 -9
  197. nuitka/code_generation/templates_c/HelperOperationComparisonTuple.c.j2 +7 -7
  198. nuitka/code_generation/templates_c/HelperOperationComparisonUnicode.c.j2 +4 -4
  199. nuitka/code_generation/templates_c/HelperSlotsBinary.c.j2 +1 -1
  200. nuitka/code_generation/templates_c/HelperSlotsInt.c.j2 +31 -31
  201. nuitka/code_generation/templates_c/HelperSlotsLong.c.j2 +1 -1
  202. nuitka/containers/Namedtuples.py +6 -0
  203. nuitka/containers/OrderedSets.py +105 -5
  204. nuitka/distutils/Build.py +14 -0
  205. nuitka/distutils/DistutilCommands.py +50 -10
  206. nuitka/finalizations/Finalization.py +3 -3
  207. nuitka/finalizations/FinalizeMarkups.py +10 -14
  208. nuitka/freezer/DependsExe.py +13 -3
  209. nuitka/freezer/DllDependenciesMacOS.py +18 -1
  210. nuitka/freezer/DllDependenciesWin32.py +26 -12
  211. nuitka/freezer/ImportDetection.py +3 -0
  212. nuitka/freezer/IncludedDataFiles.py +31 -8
  213. nuitka/freezer/IncludedEntryPoints.py +3 -2
  214. nuitka/freezer/Standalone.py +76 -18
  215. nuitka/importing/Importing.py +33 -6
  216. nuitka/importing/Recursion.py +12 -1
  217. nuitka/importing/StandardLibrary.py +57 -59
  218. nuitka/nodes/AsyncgenNodes.py +3 -6
  219. nuitka/nodes/BuiltinIteratorNodes.py +1 -1
  220. nuitka/nodes/BuiltinRefNodes.py +14 -30
  221. nuitka/nodes/ChildrenHavingMixins.py +439 -46
  222. nuitka/nodes/ConditionalNodes.py +3 -2
  223. nuitka/nodes/CoroutineNodes.py +3 -6
  224. nuitka/nodes/ExceptionNodes.py +102 -26
  225. nuitka/nodes/ExpressionBasesGenerated.py +288 -4
  226. nuitka/nodes/FrameNodes.py +22 -11
  227. nuitka/nodes/FunctionNodes.py +3 -3
  228. nuitka/nodes/GeneratorNodes.py +3 -6
  229. nuitka/nodes/HardImportNodesGenerated.py +182 -0
  230. nuitka/nodes/ImportNodes.py +2 -2
  231. nuitka/nodes/NodeBases.py +28 -1
  232. nuitka/nodes/NodeMakingHelpers.py +71 -50
  233. nuitka/nodes/OperatorNodesUnary.py +128 -3
  234. nuitka/nodes/OsSysNodes.py +37 -6
  235. nuitka/nodes/OutlineNodes.py +2 -2
  236. nuitka/nodes/StatementBasesGenerated.py +0 -2
  237. nuitka/nodes/StatementNodes.py +8 -7
  238. nuitka/nodes/SubscriptNodes.py +1 -1
  239. nuitka/nodes/TypeNodes.py +28 -1
  240. nuitka/nodes/shapes/BuiltinTypeShapes.py +24 -7
  241. nuitka/nodes/shapes/ShapeMixins.py +17 -0
  242. nuitka/nodes/shapes/StandardShapes.py +53 -1
  243. nuitka/optimizations/BytecodeDemotion.py +2 -1
  244. nuitka/plugins/PluginBase.py +64 -22
  245. nuitka/plugins/Plugins.py +6 -3
  246. nuitka/plugins/standard/AntiBloatPlugin.py +23 -12
  247. nuitka/plugins/standard/ImplicitImports.py +1 -13
  248. nuitka/plugins/standard/KivyPlugin.py +3 -12
  249. nuitka/plugins/standard/MatplotlibPlugin.py +12 -1
  250. nuitka/plugins/standard/MultiprocessingPlugin.py +11 -20
  251. nuitka/plugins/standard/PlaywrightPlugin.py +184 -0
  252. nuitka/plugins/standard/PySidePyQtPlugin.py +8 -0
  253. nuitka/plugins/standard/TkinterPlugin.py +0 -56
  254. nuitka/plugins/standard/TransformersPlugin.py +70 -275
  255. nuitka/plugins/standard/standard.nuitka-package.config.yml +510 -28
  256. nuitka/plugins/standard/stdlib3.nuitka-package.config.yml +35 -2
  257. nuitka/reports/CompilationReportReader.py +12 -0
  258. nuitka/reports/Reports.py +11 -0
  259. nuitka/specs/BuiltinParameterSpecs.py +5 -1
  260. nuitka/specs/HardImportSpecs.py +7 -0
  261. nuitka/specs/ParameterSpecs.py +4 -4
  262. nuitka/tools/general/dll_report/__main__.py +10 -1
  263. nuitka/tools/onefile_compressor/OnefileCompressor.py +1 -1
  264. nuitka/tools/specialize/CTypeDescriptions.py +158 -9
  265. nuitka/tools/specialize/SpecializeC.py +218 -56
  266. nuitka/tools/testing/Common.py +70 -63
  267. nuitka/tools/testing/compare_with_cpython/__main__.py +3 -1
  268. nuitka/tools/testing/measure_construct_performance/__main__.py +1 -8
  269. nuitka/tools/testing/run_nuitka_tests/__main__.py +77 -11
  270. nuitka/tools/watch/AutoStage.py +1 -0
  271. nuitka/tree/Building.py +10 -37
  272. nuitka/tree/ComplexCallHelperFunctions.py +4 -0
  273. nuitka/tree/ReformulationAssertStatements.py +31 -14
  274. nuitka/tree/ReformulationAssignmentStatements.py +5 -1
  275. nuitka/tree/ReformulationClasses3.py +94 -19
  276. nuitka/tree/ReformulationDictionaryCreation.py +1 -0
  277. nuitka/tree/ReformulationFunctionStatements.py +1 -1
  278. nuitka/tree/ReformulationMatchStatements.py +3 -1
  279. nuitka/tree/ReformulationYieldExpressions.py +23 -5
  280. nuitka/utils/CommandLineOptions.py +27 -3
  281. nuitka/utils/Download.py +2 -2
  282. nuitka/utils/Execution.py +36 -31
  283. nuitka/utils/FileOperations.py +39 -54
  284. nuitka/utils/Importing.py +2 -14
  285. nuitka/utils/InlineCopies.py +52 -0
  286. nuitka/utils/InstalledPythons.py +9 -4
  287. nuitka/utils/Json.py +2 -2
  288. nuitka/utils/PackageResources.py +44 -0
  289. nuitka/utils/Utils.py +17 -0
  290. {Nuitka_winsvc-2.4.8.data → Nuitka_winsvc-2.5.1.data}/scripts/nuitka-run.cmd +0 -0
  291. {Nuitka_winsvc-2.4.8.data → Nuitka_winsvc-2.5.1.data}/scripts/nuitka.cmd +0 -0
  292. {Nuitka_winsvc-2.4.8.dist-info → Nuitka_winsvc-2.5.1.dist-info}/LICENSE.txt +0 -0
  293. {Nuitka_winsvc-2.4.8.dist-info → Nuitka_winsvc-2.5.1.dist-info}/entry_points.txt +0 -0
  294. {Nuitka_winsvc-2.4.8.dist-info → Nuitka_winsvc-2.5.1.dist-info}/top_level.txt +0 -0
@@ -1,15 +1,115 @@
1
1
  """ This module is only an abstraction of OrderedSet which is not present in
2
2
  Python at all.
3
3
 
4
+ spell-checker: ignore orderedset,orderedsets
5
+
4
6
  """
5
7
 
6
- try:
7
- # spell-checker: ignore orderedset
8
- from orderedset import OrderedSet
9
- except ImportError:
8
+ import os
9
+ import subprocess
10
+ import sys
11
+
12
+ from nuitka.PythonVersions import python_version
13
+ from nuitka.utils.InlineCopies import getDownloadCopyFolder
14
+
15
+ recommended_orderedset_package_name, recommended_orderedset_module_name = (
16
+ ("ordered-set", "ordered_set")
17
+ if python_version >= 0x370
18
+ else ("orderedset", "orderedsets")
19
+ )
20
+
21
+
22
+ def _tryImportOrderedSet():
10
23
  try:
11
- from ordered_set import OrderedSet
24
+ from orderedset import OrderedSet as result
12
25
  except ImportError:
26
+ try:
27
+ from ordered_set import OrderedSet as result
28
+ except ImportError:
29
+ return None
30
+
31
+ return result
32
+
33
+
34
+ OrderedSet = _tryImportOrderedSet()
35
+
36
+
37
+ def _findDownloadSitePackagesDir(download_folder):
38
+ for root, dirnames, _filenames in os.walk(download_folder):
39
+ found_candidate = None
40
+ for candidate in ("site-packages", "dist-packages", "vendor-packages"):
41
+ if candidate in dirnames:
42
+ # Unclear which one to use.
43
+ if found_candidate is not None:
44
+ return
45
+
46
+ found_candidate = candidate
47
+
48
+ if found_candidate:
49
+ return os.path.join(root, found_candidate)
50
+
51
+
52
+ def tryDownloadPackageName(package_name, module_name, package_version):
53
+ download_folder = getDownloadCopyFolder()
54
+
55
+ site_packages_folder = _findDownloadSitePackagesDir(download_folder)
56
+
57
+ if site_packages_folder is not None:
58
+ candidate = os.path.join(site_packages_folder, module_name)
59
+
60
+ if os.path.exists(candidate):
61
+ return site_packages_folder
62
+
63
+ if os.getenv("NUITKA_ASSUME_YES_FOR_DOWNLOADS") in ("1", "true", "yes"):
64
+ if package_version is not None:
65
+ package_spec = "%s==%s" % (package_name, package_version)
66
+ else:
67
+ package_spec = package_name
68
+
69
+ exit_code = subprocess.call(
70
+ [
71
+ sys.executable,
72
+ "-m",
73
+ "pip",
74
+ "install",
75
+ "--root",
76
+ download_folder,
77
+ package_spec,
78
+ ],
79
+ shell=False,
80
+ )
81
+
82
+ if exit_code != 0:
83
+ return None
84
+
85
+ if site_packages_folder is None:
86
+ site_packages_folder = _findDownloadSitePackagesDir(download_folder)
87
+
88
+ if site_packages_folder is not None:
89
+ candidate = os.path.join(site_packages_folder, module_name)
90
+
91
+ if os.path.exists(candidate):
92
+ return site_packages_folder
93
+
94
+
95
+ def _tryDownloadOrderedSet():
96
+ return tryDownloadPackageName(
97
+ recommended_orderedset_package_name,
98
+ recommended_orderedset_module_name,
99
+ package_version=None,
100
+ )
101
+
102
+
103
+ if OrderedSet is None:
104
+ downloaded_pip = _tryDownloadOrderedSet()
105
+
106
+ try:
107
+ sys.path.insert(0, downloaded_pip)
108
+ OrderedSet = _tryImportOrderedSet()
109
+ finally:
110
+ del sys.path[0]
111
+
112
+ if OrderedSet is None:
13
113
  from .OrderedSetsFallback import OrderedSet
14
114
 
15
115
 
nuitka/distutils/Build.py CHANGED
@@ -23,6 +23,20 @@ class NuitkaBuildMetaBackend(setuptools.build_meta._BuildMetaBackend):
23
23
  def build_wheel(
24
24
  self, wheel_directory, config_settings=None, metadata_directory=None
25
25
  ):
26
+ # Allow falling back to setuptools when the `build_with_nuitka` configuration setting is set to true.
27
+ if config_settings:
28
+ build_with_nuitka = config_settings.pop("build_with_nuitka", "true").lower()
29
+
30
+ if build_with_nuitka not in ("true", "false"):
31
+ raise ValueError(
32
+ "When passing the 'build_with_nuitka' setting, it must either be 'true' or 'false'."
33
+ )
34
+
35
+ if build_with_nuitka == "false":
36
+ return super().build_wheel(
37
+ wheel_directory, config_settings, metadata_directory
38
+ )
39
+
26
40
  os.environ["NUITKA_TOML_FILE"] = os.path.join(os.getcwd(), "pyproject.toml")
27
41
 
28
42
  with suppress_known_deprecation():
@@ -21,6 +21,10 @@ from nuitka.importing.Importing import (
21
21
  locateModule,
22
22
  )
23
23
  from nuitka.PythonVersions import python_version
24
+ from nuitka.reports.CompilationReportReader import (
25
+ getEmbeddedDataFilenames,
26
+ parseCompilationReport,
27
+ )
24
28
  from nuitka.Tracing import wheel_logger
25
29
  from nuitka.utils.Execution import check_call
26
30
  from nuitka.utils.FileOperations import deleteFile, getFileList, renameFile
@@ -31,6 +35,7 @@ def setupNuitkaDistutilsCommands(dist, keyword, value):
31
35
  # If the user project setup.py includes the key "build_with_nuitka=True" all
32
36
  # build operations (build, bdist_wheel, install etc) will run via Nuitka.
33
37
  # pylint: disable=unused-argument
38
+ # spell-checker: ignore cmdclass
34
39
 
35
40
  if not value:
36
41
  return
@@ -213,6 +218,9 @@ class build(distutils.command.build.build):
213
218
 
214
219
  @staticmethod
215
220
  def _parseOptionsEntry(option, value):
221
+ if option == "build_with_nuitka":
222
+ return
223
+
216
224
  option = "--" + option.lstrip("-")
217
225
 
218
226
  if type(value) is tuple and len(value) == 2 and value[0] == "setup.py":
@@ -231,7 +239,8 @@ class build(distutils.command.build.build):
231
239
  yield "%s=%s" % (option, value)
232
240
 
233
241
  def _build(self, build_lib):
234
- # High complexity, pylint: disable=too-many-branches,too-many-locals
242
+ # High complexity,
243
+ # pylint: disable=too-many-branches,too-many-locals,too-many-statements
235
244
 
236
245
  old_dir = os.getcwd()
237
246
 
@@ -249,6 +258,8 @@ class build(distutils.command.build.build):
249
258
  # Search in the build directory preferably.
250
259
  addMainScriptDirectory(main_package_dir)
251
260
 
261
+ embedded_data_files = set()
262
+
252
263
  for is_package, module_name in self._findBuildTasks():
253
264
  # Nuitka wants the main package by filename, probably we should stop
254
265
  # needing that.
@@ -276,7 +287,12 @@ class build(distutils.command.build.build):
276
287
  "--enable-plugin=pylint-warnings",
277
288
  "--output-dir=%s" % output_dir,
278
289
  "--nofollow-import-to=*.tests",
290
+ "--nowarn-mnemonic=compiled-package-hidden-by-package",
279
291
  "--remove-output",
292
+ # Note: For when we are debugging module mode of Nuitka, not for general use.
293
+ # "--debug",
294
+ # "--trace",
295
+ # "--python-flag=-v"
280
296
  ]
281
297
 
282
298
  if package_name is not None:
@@ -319,12 +335,25 @@ class build(distutils.command.build.build):
319
335
  ):
320
336
  command.extend(self._parseOptionsEntry(option, value))
321
337
 
338
+ report_filename = None
339
+
322
340
  # Process any extra options from setuptools
323
341
  if "nuitka" in self.distribution.command_options:
324
342
  for option, value in self.distribution.command_options[
325
343
  "nuitka"
326
344
  ].items():
327
- command.extend(self._parseOptionsEntry(option, value))
345
+ for option in self._parseOptionsEntry(option, value):
346
+ command.append(option)
347
+
348
+ if option.startswith("--report="):
349
+ report_filename = option.split("=", 1)[1]
350
+
351
+ if report_filename is None:
352
+ command.append("--report=compilation-report.xml")
353
+ report_filename = "compilation-report.xml"
354
+ delete_report = True
355
+ else:
356
+ delete_report = False
328
357
 
329
358
  command.append(main_filename)
330
359
 
@@ -337,17 +366,26 @@ class build(distutils.command.build.build):
337
366
  "Finished compilation of '%s'." % module_name.asString(), style="green"
338
367
  )
339
368
 
340
- self.build_lib = build_lib
369
+ report = parseCompilationReport(report_filename)
341
370
 
342
- os.chdir(old_dir)
371
+ embedded_data_files.update(getEmbeddedDataFilenames(report))
372
+
373
+ if delete_report:
374
+ os.unlink(report_filename)
375
+
376
+ self.build_lib = build_lib
343
377
 
344
378
  # Remove Python code from build folder, that's our job now.
345
- for root, _, filenames in os.walk(build_lib):
346
- for filename in filenames:
347
- fullpath = os.path.join(root, filename)
379
+ for filename in getFileList(
380
+ build_lib, only_suffixes=(".py", ".pyw", ".pyc", ".pyo")
381
+ ):
382
+ os.unlink(filename)
348
383
 
349
- if fullpath.lower().endswith((".py", ".pyw", ".pyc", ".pyo")):
350
- os.unlink(fullpath)
384
+ # Remove data files from build folder, that's our job now too
385
+ for filename in embedded_data_files:
386
+ os.unlink(filename)
387
+
388
+ os.chdir(old_dir)
351
389
 
352
390
 
353
391
  # Required by distutils, used as command name, pylint: disable=invalid-name
@@ -355,7 +393,8 @@ class install(distutils.command.install.install):
355
393
  # pylint: disable=attribute-defined-outside-init
356
394
  def finalize_options(self):
357
395
  distutils.command.install.install.finalize_options(self)
358
- # Ensure the purelib folder is not used
396
+ # Ensure the "purelib" folder is not used
397
+ # spell-checker: ignore purelib,platlib
359
398
  self.install_lib = self.install_platlib
360
399
 
361
400
 
@@ -376,6 +415,7 @@ class bdist_nuitka(wheel.bdist_wheel.bdist_wheel):
376
415
  # Force module to use correct platform in name
377
416
  self.root_is_pure = False
378
417
 
418
+ # virtual method name, spell-checker: ignore wheelfile
379
419
  def write_wheelfile(self, wheelfile_base, generator=None):
380
420
  if generator is None:
381
421
  from nuitka.Version import getNuitkaVersion
@@ -14,9 +14,9 @@ from nuitka.tree import Operations
14
14
  from .FinalizeMarkups import FinalizeMarkups
15
15
 
16
16
 
17
- def prepareCodeGeneration(tree):
18
- visitor = FinalizeMarkups()
19
- Operations.visitTree(tree, visitor)
17
+ def prepareCodeGeneration(module):
18
+ visitor = FinalizeMarkups(module)
19
+ Operations.visitTree(module, visitor)
20
20
 
21
21
 
22
22
  # Part of "Nuitka", an optimizing Python compiler that is compatible and
@@ -23,6 +23,9 @@ from nuitka.tree.Operations import VisitorNoopMixin
23
23
 
24
24
 
25
25
  class FinalizeMarkups(VisitorNoopMixin):
26
+ def __init__(self, module):
27
+ self.module = module
28
+
26
29
  def onEnterNode(self, node):
27
30
  try:
28
31
  self._onEnterNode(node)
@@ -37,26 +40,17 @@ class FinalizeMarkups(VisitorNoopMixin):
37
40
  # This has many different things it deals with, so there need to be a
38
41
  # lot of branches and statements, pylint: disable=too-many-branches
39
42
 
40
- # Also all self specific things have been done on the outside,
41
- # pylint: disable=no-self-use
42
43
  if node.isStatementReturn() or node.isStatementGeneratorReturn():
43
- search = node
44
-
45
- in_tried_block = False
46
-
47
44
  # Search up to the containing function, and check for a try/finally
48
45
  # containing the "return" statement.
49
- search = search.getParentReturnConsumer()
46
+ search = node.getParentReturnConsumer()
50
47
 
51
48
  if (
52
49
  search.isExpressionGeneratorObjectBody()
53
50
  or search.isExpressionCoroutineObjectBody()
54
51
  or search.isExpressionAsyncgenObjectBody()
55
52
  ):
56
- if in_tried_block:
57
- search.markAsNeedsGeneratorReturnHandling(2)
58
- else:
59
- search.markAsNeedsGeneratorReturnHandling(1)
53
+ search.markAsNeedsGeneratorReturnHandling()
60
54
 
61
55
  if node.isExpressionFunctionCreation():
62
56
  if (
@@ -72,11 +66,10 @@ class FinalizeMarkups(VisitorNoopMixin):
72
66
  function_body = node.getFunctionBody()
73
67
  parent_module = function_body.getParentModule()
74
68
 
75
- node_module = node.getParentModule()
76
- if node_module is not parent_module:
69
+ if self.module is not parent_module:
77
70
  function_body.markAsCrossModuleUsed()
78
71
 
79
- node_module.addCrossUsedFunction(function_body)
72
+ self.module.addCrossUsedFunction(function_body)
80
73
 
81
74
  if node.isStatementAssignmentVariable():
82
75
  target_var = node.getVariable()
@@ -93,6 +86,9 @@ class FinalizeMarkups(VisitorNoopMixin):
93
86
  # TODO: This might be bad.
94
87
  assign_source.removeMarkAsInplaceSuspect()
95
88
 
89
+ if target_var.isModuleVariable():
90
+ pass
91
+
96
92
  if python_version < 0x300 and node.isStatementPublishException():
97
93
  node.getParentStatementsFrame().markAsFrameExceptionPreserving()
98
94
 
@@ -3,12 +3,14 @@
3
3
 
4
4
  """ Interface to depends.exe on Windows.
5
5
 
6
- We use depends.exe to investigate needed DLLs of Python DLLs.
6
+ We use "depends.exe" to investigate needed DLLs of Python DLLs.
7
7
 
8
8
  """
9
9
 
10
10
  import os
11
11
 
12
+ # pylint: disable=I0021,import-error,redefined-builtin
13
+ from nuitka.__past__ import WindowsError
12
14
  from nuitka.containers.OrderedSets import OrderedSet
13
15
  from nuitka.Options import assumeYesForDownloads
14
16
  from nuitka.Tracing import inclusion_logger
@@ -18,6 +20,7 @@ from nuitka.utils.FileOperations import (
18
20
  deleteFile,
19
21
  getExternalUsePath,
20
22
  getFileContentByLine,
23
+ getNormalizedPath,
21
24
  getWindowsLongPathName,
22
25
  isFilenameBelowPath,
23
26
  isFilesystemEncodable,
@@ -65,6 +68,7 @@ def _attemptToFindNotFoundDLL(dll_filename):
65
68
  if dll_filename in currently_loaded_dlls:
66
69
  return currently_loaded_dlls[dll_filename]
67
70
 
71
+ # Lets try the Windows system, spell-checker: ignore systemroot
68
72
  dll_filename = os.path.join(
69
73
  os.environ["SYSTEMROOT"],
70
74
  "SysWOW64" if getArchitecture() == "x86_64" else "System32",
@@ -132,7 +136,13 @@ def _parseDependsExeOutput2(lines):
132
136
  continue
133
137
 
134
138
  dll_filename = os.path.abspath(dll_filename)
135
- dll_filename = getWindowsLongPathName(dll_filename)
139
+
140
+ # Ignore errors trying to resolve the filename. Sometimes Chinese
141
+ # directory paths do not resolve to long filenames.
142
+ try:
143
+ dll_filename = getWindowsLongPathName(dll_filename)
144
+ except WindowsError:
145
+ pass
136
146
 
137
147
  dll_name = os.path.basename(dll_filename)
138
148
 
@@ -152,7 +162,7 @@ def _parseDependsExeOutput2(lines):
152
162
 
153
163
  assert os.path.isfile(dll_filename), (dll_filename, line)
154
164
 
155
- result.add(os.path.normcase(os.path.abspath(dll_filename)))
165
+ result.add(getNormalizedPath(os.path.normcase(dll_filename)))
156
166
 
157
167
  return result
158
168
 
@@ -57,7 +57,12 @@ def _detectPythonRpaths():
57
57
 
58
58
 
59
59
  def detectBinaryPathDLLsMacOS(
60
- original_dir, binary_filename, package_name, keep_unresolved, recursive
60
+ original_dir,
61
+ binary_filename,
62
+ package_name,
63
+ keep_unresolved,
64
+ recursive,
65
+ recursive_dlls=None,
61
66
  ):
62
67
  assert os.path.exists(binary_filename), binary_filename
63
68
 
@@ -91,13 +96,25 @@ def detectBinaryPathDLLsMacOS(
91
96
  if recursive:
92
97
  merged_result = OrderedDict(resolved_result)
93
98
 
99
+ # For recursive DLL detection, cycle may exist, so we keep track of what
100
+ # was seen so far.
101
+ if recursive_dlls is None:
102
+ recursive_dlls = set([binary_filename])
103
+ else:
104
+ recursive_dlls = set(recursive_dlls)
105
+ recursive_dlls.add(binary_filename)
106
+
94
107
  for sub_dll_filename in resolved_result:
108
+ if sub_dll_filename in recursive_dlls:
109
+ continue
110
+
95
111
  _, sub_result = detectBinaryPathDLLsMacOS(
96
112
  original_dir=os.path.dirname(sub_dll_filename),
97
113
  binary_filename=sub_dll_filename,
98
114
  package_name=package_name,
99
115
  keep_unresolved=True,
100
116
  recursive=True,
117
+ recursive_dlls=recursive_dlls,
101
118
  )
102
119
 
103
120
  merged_result.update(sub_result)
@@ -43,6 +43,7 @@ def detectBinaryPathDLLsWin32(
43
43
  original_dir,
44
44
  binary_filename,
45
45
  package_name,
46
+ use_path,
46
47
  use_cache,
47
48
  update_cache,
48
49
  ):
@@ -55,6 +56,7 @@ def detectBinaryPathDLLsWin32(
55
56
  original_dir=original_dir,
56
57
  binary_filename=binary_filename,
57
58
  package_name=package_name,
59
+ use_path=use_path,
58
60
  )
59
61
 
60
62
  if use_cache:
@@ -79,7 +81,9 @@ def detectBinaryPathDLLsWin32(
79
81
  if isShowProgress():
80
82
  inclusion_logger.info("Analyzing dependencies of '%s'." % binary_filename)
81
83
 
82
- scan_dirs = _getScanDirectories(package_name, original_dir)
84
+ scan_dirs = _getScanDirectories(
85
+ package_name=package_name, original_dir=original_dir, use_path=use_path
86
+ )
83
87
 
84
88
  result = detectDLLsWithDependencyWalker(
85
89
  binary_filename=binary_filename, source_dir=source_dir, scan_dirs=scan_dirs
@@ -91,7 +95,7 @@ def detectBinaryPathDLLsWin32(
91
95
  return result
92
96
 
93
97
 
94
- def _getScanDirectories(package_name, original_dir):
98
+ def _getScanDirectories(package_name, original_dir, use_path):
95
99
  # TODO: Move PyWin32 specific stuff to yaml dll section
96
100
  # pylint: disable=too-many-branches
97
101
 
@@ -120,18 +124,23 @@ def _getScanDirectories(package_name, original_dir):
120
124
  if py_win32_dir is not None:
121
125
  scan_dirs.append(py_win32_dir)
122
126
 
123
- for path_dir in os.environ["PATH"].split(";"):
124
- if not os.path.isdir(path_dir):
125
- continue
127
+ if use_path:
128
+ for path_dir in os.environ["PATH"].split(";"):
129
+ if not os.path.isdir(path_dir):
130
+ continue
126
131
 
127
- if areSamePaths(path_dir, os.path.join(os.environ["SYSTEMROOT"])):
128
- continue
129
- if areSamePaths(path_dir, os.path.join(os.environ["SYSTEMROOT"], "System32")):
130
- continue
131
- if areSamePaths(path_dir, os.path.join(os.environ["SYSTEMROOT"], "SysWOW64")):
132
- continue
132
+ if areSamePaths(path_dir, os.path.join(os.environ["SYSTEMROOT"])):
133
+ continue
134
+ if areSamePaths(
135
+ path_dir, os.path.join(os.environ["SYSTEMROOT"], "System32")
136
+ ):
137
+ continue
138
+ if areSamePaths(
139
+ path_dir, os.path.join(os.environ["SYSTEMROOT"], "SysWOW64")
140
+ ):
141
+ continue
133
142
 
134
- scan_dirs.append(path_dir)
143
+ scan_dirs.append(path_dir)
135
144
 
136
145
  result = []
137
146
 
@@ -161,6 +170,7 @@ def _getCacheFilename(
161
170
  original_dir,
162
171
  binary_filename,
163
172
  package_name,
173
+ use_path,
164
174
  ):
165
175
  original_filename = os.path.join(original_dir, os.path.basename(binary_filename))
166
176
  original_filename = os.path.normcase(original_filename)
@@ -192,6 +202,10 @@ def _getCacheFilename(
192
202
  # Take Nuitka version into account as well, ought to catch code changes.
193
203
  hash_value.updateFromValues(version_string)
194
204
 
205
+ # Using PATH or not, should also be considered different.
206
+ if use_path:
207
+ hash_value.updateFromValues(os.getenv("PATH"))
208
+
195
209
  cache_dir = os.path.join(getCacheDir("library_dependencies"), dependency_tool)
196
210
  makePath(cache_dir)
197
211
 
@@ -137,6 +137,9 @@ print("\\n".join(sorted(
137
137
  "_collections_abc.py",
138
138
  "_collections_abc.pyc",
139
139
  ):
140
+ if python_version >= 0x3D0:
141
+ detections.append((module_name, 2, "sourcefile", filename))
142
+
140
143
  module_name = ModuleName("_collections_abc")
141
144
 
142
145
  if filename.endswith(".py"):
@@ -19,6 +19,7 @@ from nuitka.Options import (
19
19
  getShallIncludeDataFiles,
20
20
  getShallIncludeExternallyDataFilePatterns,
21
21
  getShallIncludePackageData,
22
+ getShallIncludeRawDirs,
22
23
  getShallNotIncludeDataFilePatterns,
23
24
  isAcceleratedMode,
24
25
  isOnefileMode,
@@ -35,6 +36,7 @@ from nuitka.utils.FileOperations import (
35
36
  getFileList,
36
37
  getFilenameExtension,
37
38
  getFileSize,
39
+ getNormalizedPath,
38
40
  isFilenameBelowPath,
39
41
  isLegalPath,
40
42
  isRelativePath,
@@ -98,9 +100,9 @@ class IncludedDataFile(object):
98
100
 
99
101
  self.kind = kind
100
102
  self.source_path = source_path
101
- self.dest_path = os.path.normpath(dest_path)
103
+ self.dest_path = getNormalizedPath(dest_path)
102
104
 
103
- is_legal, illegal_reason = isLegalPath(dest_path)
105
+ is_legal, illegal_reason = isLegalPath(self.dest_path)
104
106
  if not is_legal:
105
107
  general.sysexit(
106
108
  "Error, cannot add data file with '%s' path, as '%s'"
@@ -166,11 +168,12 @@ def makeIncludedDataFile(source_path, dest_path, reason, tracer, tags):
166
168
  # In accelerated mode, data files can be everywhere, but they cannot
167
169
  # change place.
168
170
  if isAcceleratedMode():
169
- if "package_data" not in tags and not areSamePaths(source_path, dest_path):
170
- tracer.sysexit(
171
- "Error, cannot change paths for data files in accelerated mode from '%s' to '%s'."
172
- % (source_path, dest_path)
173
- )
171
+ if "copy" in tags:
172
+ if "package_data" not in tags and not areSamePaths(source_path, dest_path):
173
+ tracer.sysexit(
174
+ "Error, cannot change paths for data files in accelerated mode from '%s' to '%s'."
175
+ % (source_path, dest_path)
176
+ )
174
177
  else:
175
178
  inside = True
176
179
  if not isRelativePath(dest_path):
@@ -341,6 +344,8 @@ def getIncludedDataFiles():
341
344
 
342
345
 
343
346
  def _addIncludedDataFilesFromFileOptions():
347
+ # Many different option variants, pylint: disable=too-many-branches
348
+
344
349
  for pattern, source_path, dest_path, arg in getShallIncludeDataFiles():
345
350
  filenames = resolveShellPatternToFilenames(pattern)
346
351
 
@@ -392,6 +397,24 @@ def _addIncludedDataFilesFromFileOptions():
392
397
  if count == 0:
393
398
  options_logger.warning("No data files in directory '%s.'" % source_path)
394
399
 
400
+ for source_path, dest_path in getShallIncludeRawDirs():
401
+ count = 0
402
+
403
+ for included_datafile in makeIncludedDataDirectory(
404
+ source_path=source_path,
405
+ dest_path=os.path.normpath(dest_path),
406
+ reason="specified raw dir '%s' on command line" % source_path,
407
+ tracer=options_logger,
408
+ tags="user",
409
+ raw=True,
410
+ ):
411
+ yield included_datafile
412
+
413
+ count += 1
414
+
415
+ if count == 0:
416
+ options_logger.warning("No files in raw directory '%s.'" % source_path)
417
+
395
418
 
396
419
  def addIncludedDataFilesFromFileOptions():
397
420
  """Early data files, from user options that work with file system."""
@@ -538,7 +561,7 @@ def _reportDataFiles():
538
561
 
539
562
 
540
563
  def _checkPathConflict(dest_path, standalone_entry_points):
541
- assert os.path.normpath(dest_path) == dest_path
564
+ assert getNormalizedPath(dest_path) == dest_path
542
565
 
543
566
  while dest_path:
544
567
  for standalone_entry_point in standalone_entry_points:
@@ -17,6 +17,7 @@ from nuitka.Options import getShallNotIncludeDllFilePatterns, isShowInclusion
17
17
  from nuitka.Tracing import general, inclusion_logger
18
18
  from nuitka.utils.FileOperations import (
19
19
  areSamePaths,
20
+ getNormalizedPath,
20
21
  getReportPath,
21
22
  hasFilenameExtension,
22
23
  haveSameFileContents,
@@ -51,7 +52,7 @@ def _makeIncludedEntryPoint(
51
52
  assert type(executable) is bool, executable
52
53
 
53
54
  # Make sure outside code uses sane paths only.
54
- assert source_path == os.path.normpath(source_path), source_path
55
+ assert source_path == getNormalizedPath(source_path), source_path
55
56
 
56
57
  # Avoid obvious mistakes, these files won't be binaries or DLL ever, right?
57
58
  assert not hasFilenameExtension(path=source_path, extensions=(".qml", ".json"))
@@ -60,7 +61,7 @@ def _makeIncludedEntryPoint(
60
61
  logger=logger,
61
62
  kind=kind,
62
63
  source_path=source_path,
63
- dest_path=os.path.normpath(dest_path),
64
+ dest_path=getNormalizedPath(dest_path),
64
65
  module_name=module_name,
65
66
  package_name=package_name,
66
67
  executable=executable,