Nuitka-winsvc 2.1.6__cp311-cp311-win_amd64.whl → 2.2.2__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.
- {Nuitka_winsvc-2.1.6.dist-info → Nuitka_winsvc-2.2.2.dist-info}/METADATA +1 -1
- {Nuitka_winsvc-2.1.6.dist-info → Nuitka_winsvc-2.2.2.dist-info}/RECORD +234 -225
- nuitka/Errors.py +4 -0
- nuitka/HardImportRegistry.py +18 -1
- nuitka/MainControl.py +27 -30
- nuitka/OptionParsing.py +32 -30
- nuitka/Options.py +26 -13
- nuitka/OutputDirectories.py +7 -4
- nuitka/PostProcessing.py +9 -7
- nuitka/Progress.py +3 -3
- nuitka/PythonVersions.py +2 -2
- nuitka/TreeXML.py +1 -1
- nuitka/Version.py +1 -1
- nuitka/build/Backend.scons +2 -1
- nuitka/build/DataComposerInterface.py +1 -0
- nuitka/build/Onefile.scons +2 -1
- nuitka/build/SconsCaching.py +64 -46
- nuitka/build/SconsCompilerSettings.py +19 -6
- nuitka/build/SconsHacks.py +0 -1
- nuitka/build/SconsInterface.py +84 -5
- nuitka/build/SconsProgress.py +0 -1
- nuitka/build/SconsUtils.py +8 -4
- nuitka/build/include/nuitka/allocator.h +8 -3
- nuitka/build/include/nuitka/compiled_cell.h +8 -0
- nuitka/build/include/nuitka/exceptions.h +554 -179
- nuitka/build/include/nuitka/helper/dictionaries.h +1 -1
- nuitka/build/include/nuitka/helper/import_hard.h +3 -0
- nuitka/build/include/nuitka/helper/ints.h +15 -2
- nuitka/build/include/nuitka/helper/lists.h +4 -1
- nuitka/build/include/nuitka/helper/raising.h +12 -0
- nuitka/build/include/nuitka/helper/tuples.h +5 -1
- nuitka/build/include/nuitka/helpers.h +4 -0
- nuitka/build/include/nuitka/importing.h +3 -4
- nuitka/build/include/nuitka/jit_sources.h +25 -0
- nuitka/build/include/nuitka/prelude.h +38 -11
- nuitka/build/include/nuitka/printing.h +3 -0
- nuitka/build/include/nuitka/threading.h +2 -6
- nuitka/build/include/nuitka/type_aliases.h +27 -0
- nuitka/build/inline_copy/pkg_resources/pkg_resources/__init__.py +0 -3
- nuitka/build/inline_copy/tqdm/tqdm/version.py +1 -4
- nuitka/build/static_src/CompiledAsyncgenType.c +99 -114
- nuitka/build/static_src/CompiledCodeHelpers.c +23 -14
- nuitka/build/static_src/CompiledCoroutineType.c +96 -114
- nuitka/build/static_src/CompiledFrameType.c +14 -11
- nuitka/build/static_src/CompiledFunctionType.c +34 -7
- nuitka/build/static_src/CompiledGeneratorType.c +248 -142
- nuitka/build/static_src/CompiledGeneratorTypeUncompiledIntegration.c +60 -70
- nuitka/build/static_src/CompiledMethodType.c +8 -7
- nuitka/build/static_src/HelpersAttributes.c +2 -19
- nuitka/build/static_src/HelpersBuiltin.c +2 -1
- nuitka/build/static_src/HelpersComparisonEq.c +32 -18
- nuitka/build/static_src/HelpersComparisonGe.c +50 -36
- nuitka/build/static_src/HelpersComparisonGt.c +50 -36
- nuitka/build/static_src/HelpersComparisonLe.c +50 -36
- nuitka/build/static_src/HelpersComparisonLt.c +50 -36
- nuitka/build/static_src/HelpersComparisonNe.c +32 -18
- nuitka/build/static_src/HelpersDeepcopy.c +6 -8
- nuitka/build/static_src/HelpersDictionaries.c +8 -3
- nuitka/build/static_src/HelpersExceptions.c +42 -28
- nuitka/build/static_src/HelpersFilesystemPaths.c +7 -7
- nuitka/build/static_src/HelpersImportHard.c +15 -0
- nuitka/build/static_src/HelpersJitSources.c +46 -0
- nuitka/build/static_src/HelpersLists.c +40 -0
- nuitka/build/static_src/HelpersOperationBinaryAdd.c +66 -66
- nuitka/build/static_src/HelpersOperationBinaryAddUtils.c +80 -33
- nuitka/build/static_src/HelpersOperationBinaryMultUtils.c +16 -13
- nuitka/build/static_src/HelpersOperationBinarySub.c +39 -39
- nuitka/build/static_src/HelpersOperationInplaceAdd.c +54 -54
- nuitka/build/static_src/HelpersOperationInplaceAddUtils.c +1 -1
- nuitka/build/static_src/HelpersOperationInplaceSub.c +50 -50
- nuitka/build/static_src/HelpersProfiling.c +3 -4
- nuitka/build/static_src/HelpersRaising.c +62 -1
- nuitka/build/static_src/HelpersStrings.c +203 -8
- nuitka/build/static_src/HelpersTypes.c +42 -0
- nuitka/build/static_src/MainProgram.c +1 -1
- nuitka/build/static_src/MetaPathBasedLoader.c +2 -1
- nuitka/build/static_src/OnefileBootstrap.c +3 -3
- nuitka/code_generation/BinaryOperationHelperDefinitions.py +5 -3
- nuitka/code_generation/BuiltinCodes.py +1 -0
- nuitka/code_generation/CodeGeneration.py +11 -0
- nuitka/code_generation/CodeHelpers.py +5 -3
- nuitka/code_generation/CodeObjectCodes.py +10 -6
- nuitka/code_generation/ComparisonCodes.py +19 -3
- nuitka/code_generation/ConstantCodes.py +5 -0
- nuitka/code_generation/Contexts.py +22 -6
- nuitka/code_generation/Emission.py +1 -0
- nuitka/code_generation/ErrorCodes.py +8 -16
- nuitka/code_generation/EvalCodes.py +5 -3
- nuitka/code_generation/ExceptionCodes.py +8 -1
- nuitka/code_generation/ExpressionCTypeSelectionHelpers.py +1 -0
- nuitka/code_generation/FrameCodes.py +5 -3
- nuitka/code_generation/FunctionCodes.py +0 -1
- nuitka/code_generation/GeneratorCodes.py +3 -3
- nuitka/code_generation/GlobalConstants.py +0 -2
- nuitka/code_generation/ImportCodes.py +2 -0
- nuitka/code_generation/JitCodes.py +44 -0
- nuitka/code_generation/ListCodes.py +11 -17
- nuitka/code_generation/MatchCodes.py +0 -1
- nuitka/code_generation/ModuleCodes.py +2 -1
- nuitka/code_generation/Namify.py +0 -1
- nuitka/code_generation/NetworkxCodes.py +51 -0
- nuitka/code_generation/OperationCodes.py +8 -6
- nuitka/code_generation/PackageResourceCodes.py +7 -5
- nuitka/code_generation/TensorflowCodes.py +54 -0
- nuitka/code_generation/TypeAliasCodes.py +71 -0
- nuitka/code_generation/VariableCodes.py +7 -5
- nuitka/code_generation/VariableDeclarations.py +1 -0
- nuitka/code_generation/c_types/CTypeCLongs.py +0 -1
- nuitka/code_generation/c_types/CTypeNuitkaInts.py +0 -1
- nuitka/code_generation/c_types/CTypeVoids.py +1 -0
- nuitka/code_generation/templates/CodeTemplatesConstants.py +14 -0
- nuitka/code_generation/templates/CodeTemplatesExceptions.py +1 -1
- nuitka/code_generation/templates/CodeTemplatesIterators.py +0 -1
- nuitka/code_generation/templates/CodeTemplatesLoader.py +0 -1
- nuitka/code_generation/templates/CodeTemplatesModules.py +9 -4
- nuitka/code_generation/templates/CodeTemplatesVariables.py +8 -8
- nuitka/code_generation/templates/TemplateDebugWrapper.py +0 -1
- nuitka/code_generation/templates_c/HelperOperationComparisonUnicode.c.j2 +4 -0
- nuitka/code_generation/templates_c/HelperSlotsLong.c.j2 +9 -7
- nuitka/containers/Namedtuples.py +0 -1
- nuitka/finalizations/Finalization.py +1 -0
- nuitka/finalizations/FinalizeMarkups.py +0 -1
- nuitka/freezer/DllDependenciesMacOS.py +60 -13
- nuitka/freezer/DllDependenciesPosix.py +0 -1
- nuitka/freezer/DllDependenciesWin32.py +2 -1
- nuitka/freezer/IncludedDataFiles.py +46 -15
- nuitka/freezer/IncludedEntryPoints.py +5 -3
- nuitka/freezer/Standalone.py +6 -1
- nuitka/importing/ImportCache.py +2 -2
- nuitka/importing/ImportResolving.py +80 -78
- nuitka/importing/Importing.py +34 -1
- nuitka/nodes/AttributeNodesGenerated.py +21 -6
- nuitka/nodes/BuiltinComplexNodes.py +1 -0
- nuitka/nodes/BuiltinFormatNodes.py +1 -0
- nuitka/nodes/BuiltinIteratorNodes.py +5 -3
- nuitka/nodes/BuiltinOperationNodeBasesGenerated.py +21 -6
- nuitka/nodes/BuiltinRefNodes.py +8 -1
- nuitka/nodes/BuiltinVarsNodes.py +0 -1
- nuitka/nodes/ChildrenHavingMixins.py +906 -186
- nuitka/nodes/CodeObjectSpecs.py +1 -1
- nuitka/nodes/ConditionalNodes.py +2 -6
- nuitka/nodes/ConstantRefNodes.py +38 -0
- nuitka/nodes/CtypesNodes.py +0 -1
- nuitka/nodes/DictionaryNodes.py +0 -1
- nuitka/nodes/ExceptionNodes.py +10 -0
- nuitka/nodes/ExpressionBases.py +15 -9
- nuitka/nodes/ExpressionBasesGenerated.py +32 -15
- nuitka/nodes/FunctionNodes.py +50 -5
- nuitka/nodes/HardImportNodesGenerated.py +245 -60
- nuitka/nodes/ImportHardNodes.py +27 -13
- nuitka/nodes/ImportNodes.py +92 -70
- nuitka/nodes/InjectCNodes.py +0 -1
- nuitka/nodes/ModuleNodes.py +10 -5
- nuitka/nodes/NetworkxNodes.py +45 -0
- nuitka/nodes/OperatorNodesUnary.py +1 -0
- nuitka/nodes/OsSysNodes.py +0 -1
- nuitka/nodes/PackageMetadataNodes.py +0 -1
- nuitka/nodes/PackageResourceNodes.py +10 -6
- nuitka/nodes/StatementBasesGenerated.py +107 -60
- nuitka/nodes/StringConcatenationNodes.py +1 -0
- nuitka/nodes/TensorflowNodes.py +38 -0
- nuitka/nodes/TypeNodes.py +21 -0
- nuitka/nodes/VariableRefNodes.py +1 -0
- nuitka/nodes/shapes/BuiltinTypeShapes.py +25 -15
- nuitka/optimizations/Optimization.py +7 -6
- nuitka/optimizations/OptimizeBuiltinCalls.py +11 -9
- nuitka/optimizations/Tags.py +0 -1
- nuitka/optimizations/TraceCollections.py +6 -55
- nuitka/optimizations/ValueTraces.py +49 -1
- nuitka/plugins/PluginBase.py +26 -4
- nuitka/plugins/Plugins.py +49 -12
- nuitka/plugins/standard/AntiBloatPlugin.py +12 -2
- nuitka/plugins/standard/ConsiderPyLintAnnotationsPlugin.py +0 -1
- nuitka/plugins/standard/DataFilesPlugin.py +2 -6
- nuitka/plugins/standard/DillPlugin.py +3 -3
- nuitka/plugins/standard/DllFilesPlugin.py +29 -23
- nuitka/plugins/standard/GiPlugin.py +1 -0
- nuitka/plugins/standard/ImplicitImports.py +8 -7
- nuitka/plugins/standard/MatplotlibPlugin.py +1 -0
- nuitka/plugins/standard/OptionsNannyPlugin.py +3 -7
- nuitka/plugins/standard/PkgResourcesPlugin.py +0 -1
- nuitka/plugins/standard/PmwPlugin.py +10 -9
- nuitka/plugins/standard/PySidePyQtPlugin.py +0 -28
- nuitka/plugins/standard/TensorflowPlugin.py +1 -0
- nuitka/plugins/standard/TorchPlugin.py +1 -0
- nuitka/plugins/standard/TrioPlugin.py +1 -0
- nuitka/plugins/standard/standard.nuitka-package.config.yml +249 -34
- nuitka/reports/CompilationReportReader.py +0 -1
- nuitka/reports/Reports.py +49 -5
- nuitka/specs/BuiltinParameterSpecs.py +10 -2
- nuitka/specs/BuiltinStrOperationSpecs.py +1 -1
- nuitka/specs/BuiltinTypeOperationSpecs.py +0 -1
- nuitka/specs/HardImportSpecs.py +34 -1
- nuitka/specs/ParameterSpecs.py +11 -9
- nuitka/tools/environments/Virtualenv.py +0 -1
- nuitka/tools/specialize/CTypeDescriptions.py +15 -11
- nuitka/tools/specialize/SpecializeC.py +11 -9
- nuitka/tools/specialize/SpecializePython.py +57 -30
- nuitka/tools/testing/Common.py +24 -7
- nuitka/tools/testing/OutputComparison.py +4 -0
- nuitka/tools/testing/Pythons.py +0 -1
- nuitka/tools/testing/compare_with_cpython/__main__.py +0 -4
- nuitka/tools/watch/GitHub.py +4 -1
- nuitka/tools/watch/__main__.py +22 -1
- nuitka/tree/Building.py +3 -0
- nuitka/tree/InternalModule.py +0 -1
- nuitka/tree/ReformulationAssertStatements.py +1 -0
- nuitka/tree/ReformulationAssignmentStatements.py +26 -3
- nuitka/tree/ReformulationClasses3.py +23 -26
- nuitka/tree/ReformulationContractionExpressions.py +5 -3
- nuitka/tree/ReformulationDictionaryCreation.py +6 -5
- nuitka/tree/ReformulationExecStatements.py +8 -6
- nuitka/tree/ReformulationFunctionStatements.py +10 -6
- nuitka/tree/SourceHandling.py +8 -0
- nuitka/tree/TreeHelpers.py +6 -3
- nuitka/utils/AppDirs.py +6 -2
- nuitka/utils/CStrings.py +1 -1
- nuitka/utils/CommandLineOptions.py +0 -1
- nuitka/utils/Distributions.py +3 -3
- nuitka/utils/Download.py +5 -1
- nuitka/utils/Execution.py +6 -3
- nuitka/utils/FileOperations.py +61 -34
- nuitka/utils/Importing.py +4 -4
- nuitka/utils/InstanceCounters.py +1 -0
- nuitka/utils/MacOSApp.py +1 -0
- nuitka/utils/Shebang.py +1 -0
- nuitka/utils/Utils.py +39 -1
- nuitka/utils/WindowsFileUsage.py +4 -3
- {Nuitka_winsvc-2.1.6.data → Nuitka_winsvc-2.2.2.data}/scripts/nuitka-run.bat +0 -0
- {Nuitka_winsvc-2.1.6.data → Nuitka_winsvc-2.2.2.data}/scripts/nuitka.bat +0 -0
- {Nuitka_winsvc-2.1.6.dist-info → Nuitka_winsvc-2.2.2.dist-info}/LICENSE.txt +0 -0
- {Nuitka_winsvc-2.1.6.dist-info → Nuitka_winsvc-2.2.2.dist-info}/WHEEL +0 -0
- {Nuitka_winsvc-2.1.6.dist-info → Nuitka_winsvc-2.2.2.dist-info}/entry_points.txt +0 -0
- {Nuitka_winsvc-2.1.6.dist-info → Nuitka_winsvc-2.2.2.dist-info}/top_level.txt +0 -0
|
@@ -26,6 +26,7 @@ from nuitka.utils.SharedLibraries import (
|
|
|
26
26
|
getOtoolDependencyOutput,
|
|
27
27
|
getOtoolListing,
|
|
28
28
|
)
|
|
29
|
+
from nuitka.utils.Utils import getArchitecture
|
|
29
30
|
|
|
30
31
|
from .DllDependenciesCommon import getLdLibraryPath
|
|
31
32
|
|
|
@@ -50,7 +51,7 @@ def _detectPythonRpaths():
|
|
|
50
51
|
if os.path.isdir(candidate):
|
|
51
52
|
result.append(candidate)
|
|
52
53
|
|
|
53
|
-
return tuple(result)
|
|
54
|
+
return tuple(set(result))
|
|
54
55
|
|
|
55
56
|
|
|
56
57
|
def detectBinaryPathDLLsMacOS(
|
|
@@ -93,8 +94,8 @@ def detectBinaryPathDLLsMacOS(
|
|
|
93
94
|
original_dir=os.path.dirname(sub_dll_filename),
|
|
94
95
|
binary_filename=sub_dll_filename,
|
|
95
96
|
package_name=package_name,
|
|
96
|
-
recursive=True,
|
|
97
97
|
keep_unresolved=True,
|
|
98
|
+
recursive=True,
|
|
98
99
|
)
|
|
99
100
|
|
|
100
101
|
merged_result.update(sub_result)
|
|
@@ -133,6 +134,24 @@ def _parseOtoolListingOutput(output):
|
|
|
133
134
|
return paths
|
|
134
135
|
|
|
135
136
|
|
|
137
|
+
def _getNonVersionedDllFilenames(filename):
|
|
138
|
+
yield filename
|
|
139
|
+
|
|
140
|
+
if getArchitecture() == "arm64" and filename.endswith(".dylib"):
|
|
141
|
+
yield filename[:-6] + "_arm64.dylib"
|
|
142
|
+
|
|
143
|
+
match = re.match(r"^(.*?)(\.\d+)+\.dylib$", filename)
|
|
144
|
+
|
|
145
|
+
if match:
|
|
146
|
+
yield match.group(1) + ".dylib"
|
|
147
|
+
|
|
148
|
+
# TODO: The versioned filename, might do the same, and so could the
|
|
149
|
+
# "x86_64" specific DLL be a thing too, but we should have actual
|
|
150
|
+
# examples to be sure they are covered with tests.
|
|
151
|
+
if getArchitecture() == "arm64":
|
|
152
|
+
yield match.group(1) + "_arm64.dylib"
|
|
153
|
+
|
|
154
|
+
|
|
136
155
|
def _resolveBinaryPathDLLsMacOS(
|
|
137
156
|
original_dir, binary_filename, paths, package_specific_dirs, package_name
|
|
138
157
|
):
|
|
@@ -149,11 +168,17 @@ def _resolveBinaryPathDLLsMacOS(
|
|
|
149
168
|
for path in paths:
|
|
150
169
|
if path.startswith("@rpath/"):
|
|
151
170
|
# Resolve rpath to just the ones given, first match.
|
|
171
|
+
library_name = path[7:]
|
|
172
|
+
|
|
152
173
|
for rpath in rpaths:
|
|
153
|
-
if os.path.exists(os.path.join(rpath,
|
|
174
|
+
if os.path.exists(os.path.join(rpath, library_name)):
|
|
154
175
|
resolved_path = os.path.normpath(os.path.join(rpath, path[7:]))
|
|
155
176
|
break
|
|
156
177
|
else:
|
|
178
|
+
# These have become virtual in later macOS.
|
|
179
|
+
if library_name in ("libc++.1.dylib", "libz.1.dylib"):
|
|
180
|
+
continue
|
|
181
|
+
|
|
157
182
|
# This is only a guess, might be missing package specific directories.
|
|
158
183
|
resolved_path = os.path.normpath(os.path.join(original_dir, path[7:]))
|
|
159
184
|
elif path.startswith("@loader_path/"):
|
|
@@ -189,22 +214,33 @@ def _resolveBinaryPathDLLsMacOS(
|
|
|
189
214
|
)
|
|
190
215
|
|
|
191
216
|
# Some extension modules seem to reference themselves by a different
|
|
192
|
-
# extension module name, so use that if it exists
|
|
193
|
-
|
|
217
|
+
# extension module name, so use that if it exists, and some versioned
|
|
218
|
+
# DLL dependencies do not matter.
|
|
219
|
+
if python_version >= 0x300:
|
|
194
220
|
so_suffixes = getSharedLibrarySuffixes()[:-1]
|
|
195
221
|
|
|
196
222
|
specific_suffix = so_suffixes[0]
|
|
197
223
|
abi_suffix = so_suffixes[1]
|
|
198
224
|
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
else:
|
|
204
|
-
candidate = None
|
|
225
|
+
for resolved_path_candidate in _getNonVersionedDllFilenames(resolved_path):
|
|
226
|
+
if os.path.exists(resolved_path_candidate):
|
|
227
|
+
resolved_path = resolved_path_candidate
|
|
228
|
+
break
|
|
205
229
|
|
|
206
|
-
|
|
207
|
-
|
|
230
|
+
if resolved_path_candidate.endswith(specific_suffix):
|
|
231
|
+
candidate = (
|
|
232
|
+
resolved_path_candidate[: -len(specific_suffix)] + abi_suffix
|
|
233
|
+
)
|
|
234
|
+
elif resolved_path_candidate.endswith(abi_suffix):
|
|
235
|
+
candidate = (
|
|
236
|
+
resolved_path_candidate[: -len(specific_suffix)] + abi_suffix
|
|
237
|
+
)
|
|
238
|
+
else:
|
|
239
|
+
candidate = None
|
|
240
|
+
|
|
241
|
+
if candidate is not None and os.path.exists(candidate):
|
|
242
|
+
resolved_path = candidate
|
|
243
|
+
break
|
|
208
244
|
|
|
209
245
|
# Sometimes self-dependencies are on a numbered version, but deployed is
|
|
210
246
|
# one version without it. The macOS just ignores that, and so we do.
|
|
@@ -241,6 +277,17 @@ def _resolveBinaryPathDLLsMacOS(
|
|
|
241
277
|
# TODO: Missing DLLs that are accepted, are not really forbidden, we
|
|
242
278
|
# should instead acknowledge them as missing, and treat that properly
|
|
243
279
|
# in using code.
|
|
280
|
+
if acceptable is True:
|
|
281
|
+
raise NuitkaForbiddenDLLEncounter(binary_filename, plugin_name)
|
|
282
|
+
|
|
283
|
+
# We check both the user and the used DLL if they are listed. This
|
|
284
|
+
# might be a form of bug hiding, that the later is not sufficient,
|
|
285
|
+
# that we should address later.
|
|
286
|
+
acceptable, plugin_name = Plugins.isAcceptableMissingDLL(
|
|
287
|
+
package_name=package_name,
|
|
288
|
+
filename=resolved_path,
|
|
289
|
+
)
|
|
290
|
+
|
|
244
291
|
if acceptable is True:
|
|
245
292
|
raise NuitkaForbiddenDLLEncounter(binary_filename, plugin_name)
|
|
246
293
|
|
|
@@ -14,6 +14,7 @@ from nuitka.build.SconsUtils import readSconsReport
|
|
|
14
14
|
from nuitka.containers.OrderedSets import OrderedSet
|
|
15
15
|
from nuitka.Options import isShowProgress
|
|
16
16
|
from nuitka.plugins.Plugins import Plugins
|
|
17
|
+
from nuitka.PythonVersions import getSystemPrefixPath
|
|
17
18
|
from nuitka.Tracing import inclusion_logger
|
|
18
19
|
from nuitka.utils.AppDirs import getCacheDir
|
|
19
20
|
from nuitka.utils.FileOperations import (
|
|
@@ -99,7 +100,7 @@ def _getScanDirectories(package_name, original_dir):
|
|
|
99
100
|
if cache_key in _scan_dir_cache:
|
|
100
101
|
return _scan_dir_cache[cache_key]
|
|
101
102
|
|
|
102
|
-
scan_dirs = [
|
|
103
|
+
scan_dirs = [getSystemPrefixPath()]
|
|
103
104
|
|
|
104
105
|
if package_name is not None:
|
|
105
106
|
scan_dirs.extend(getPackageSpecificDLLDirectories(package_name))
|
|
@@ -20,6 +20,7 @@ from nuitka.Options import (
|
|
|
20
20
|
getShallIncludeExternallyDataFilePatterns,
|
|
21
21
|
getShallIncludePackageData,
|
|
22
22
|
getShallNotIncludeDataFilePatterns,
|
|
23
|
+
isAcceleratedMode,
|
|
23
24
|
isOnefileMode,
|
|
24
25
|
isStandaloneMode,
|
|
25
26
|
shallMakeModule,
|
|
@@ -27,6 +28,7 @@ from nuitka.Options import (
|
|
|
27
28
|
from nuitka.OutputDirectories import getStandaloneDirectoryPath
|
|
28
29
|
from nuitka.Tracing import options_logger
|
|
29
30
|
from nuitka.utils.FileOperations import (
|
|
31
|
+
areSamePaths,
|
|
30
32
|
containsPathElements,
|
|
31
33
|
copyFileWithPermissions,
|
|
32
34
|
getFileContents,
|
|
@@ -145,18 +147,6 @@ def makeIncludedDataFile(source_path, dest_path, reason, tracer, tags):
|
|
|
145
147
|
if "framework_resource" in tags and not isMacOS():
|
|
146
148
|
tracer.sysexit("Using resource files on non-MacOS")
|
|
147
149
|
|
|
148
|
-
inside = True
|
|
149
|
-
if not isRelativePath(dest_path):
|
|
150
|
-
if "framework_resource" in tags and not isOnefileMode():
|
|
151
|
-
inside = isRelativePath(os.path.join("Resources", dest_path))
|
|
152
|
-
else:
|
|
153
|
-
inside = False
|
|
154
|
-
|
|
155
|
-
if not inside:
|
|
156
|
-
tracer.sysexit(
|
|
157
|
-
"Error, cannot use dest path '%s' outside of distribution." % dest_path
|
|
158
|
-
)
|
|
159
|
-
|
|
160
150
|
# Refuse directories, these must be kept distinct.
|
|
161
151
|
if os.path.isdir(source_path):
|
|
162
152
|
tracer.sysexit(
|
|
@@ -164,6 +154,27 @@ def makeIncludedDataFile(source_path, dest_path, reason, tracer, tags):
|
|
|
164
154
|
% source_path
|
|
165
155
|
)
|
|
166
156
|
|
|
157
|
+
# In accelerated mode, data files can be everywhere, but they cannot
|
|
158
|
+
# change place.
|
|
159
|
+
if isAcceleratedMode():
|
|
160
|
+
if "package_data" not in tags and not areSamePaths(source_path, dest_path):
|
|
161
|
+
tracer.sysexit(
|
|
162
|
+
"Error, cannot change paths for data files in accelerated mode '%s'."
|
|
163
|
+
% dest_path
|
|
164
|
+
)
|
|
165
|
+
else:
|
|
166
|
+
inside = True
|
|
167
|
+
if not isRelativePath(dest_path):
|
|
168
|
+
if "framework_resource" in tags and not isOnefileMode():
|
|
169
|
+
inside = isRelativePath(os.path.join("Resources", dest_path))
|
|
170
|
+
else:
|
|
171
|
+
inside = False
|
|
172
|
+
|
|
173
|
+
if not inside:
|
|
174
|
+
tracer.sysexit(
|
|
175
|
+
"Error, cannot use dest path '%s' outside of distribution." % dest_path
|
|
176
|
+
)
|
|
177
|
+
|
|
167
178
|
return IncludedDataFile(
|
|
168
179
|
kind="data_file",
|
|
169
180
|
source_path=source_path,
|
|
@@ -506,7 +517,25 @@ def _reportDataFiles():
|
|
|
506
517
|
_data_file_traces.clear()
|
|
507
518
|
|
|
508
519
|
|
|
509
|
-
def
|
|
520
|
+
def _checkPathConflict(dest_path, standalone_entry_points):
|
|
521
|
+
assert os.path.normpath(dest_path) == dest_path
|
|
522
|
+
|
|
523
|
+
while dest_path:
|
|
524
|
+
for standalone_entry_point in standalone_entry_points:
|
|
525
|
+
if dest_path == standalone_entry_point.dest_path:
|
|
526
|
+
options_logger.sysexit(
|
|
527
|
+
"""\
|
|
528
|
+
Error, data file to be placed in distribution as '%s' conflicts with %s '%s'."""
|
|
529
|
+
% (
|
|
530
|
+
dest_path,
|
|
531
|
+
standalone_entry_point.kind,
|
|
532
|
+
standalone_entry_point.dest_path,
|
|
533
|
+
)
|
|
534
|
+
)
|
|
535
|
+
dest_path = os.path.dirname(dest_path)
|
|
536
|
+
|
|
537
|
+
|
|
538
|
+
def _handleDataFile(included_datafile, standalone_entry_points):
|
|
510
539
|
"""Handle a data file."""
|
|
511
540
|
tracer = included_datafile.tracer
|
|
512
541
|
|
|
@@ -529,6 +558,7 @@ def _handleDataFile(included_datafile):
|
|
|
529
558
|
if "external" in included_datafile.tags:
|
|
530
559
|
dest_path = getOutputPath(included_datafile.dest_path)
|
|
531
560
|
else:
|
|
561
|
+
_checkPathConflict(included_datafile.dest_path, standalone_entry_points)
|
|
532
562
|
dest_path = os.path.join(dist_dir, included_datafile.dest_path)
|
|
533
563
|
|
|
534
564
|
if included_datafile.kind == "data_blob":
|
|
@@ -548,7 +578,7 @@ def _handleDataFile(included_datafile):
|
|
|
548
578
|
assert False, included_datafile
|
|
549
579
|
|
|
550
580
|
|
|
551
|
-
def copyDataFiles():
|
|
581
|
+
def copyDataFiles(standalone_entry_points):
|
|
552
582
|
"""Copy the data files needed for standalone distribution.
|
|
553
583
|
|
|
554
584
|
Notes:
|
|
@@ -576,7 +606,8 @@ plugins '--embed-*' options. Not done for '%s'."""
|
|
|
576
606
|
)
|
|
577
607
|
|
|
578
608
|
_handleDataFile(
|
|
579
|
-
included_datafile,
|
|
609
|
+
included_datafile=included_datafile,
|
|
610
|
+
standalone_entry_points=standalone_entry_points,
|
|
580
611
|
)
|
|
581
612
|
|
|
582
613
|
_reportDataFiles()
|
|
@@ -316,9 +316,11 @@ def addExtensionModuleEntryPoint(module):
|
|
|
316
316
|
+ getSharedLibrarySuffix(preferred=False),
|
|
317
317
|
module_name=module.getFullName(),
|
|
318
318
|
package_name=module.getFullName().getPackageName(),
|
|
319
|
-
reason=
|
|
320
|
-
|
|
321
|
-
|
|
319
|
+
reason=(
|
|
320
|
+
"required extension module for CPython library startup"
|
|
321
|
+
if module.isTechnical()
|
|
322
|
+
else "used extension module"
|
|
323
|
+
),
|
|
322
324
|
)
|
|
323
325
|
)
|
|
324
326
|
|
nuitka/freezer/Standalone.py
CHANGED
|
@@ -28,6 +28,8 @@ from nuitka.Progress import (
|
|
|
28
28
|
reportProgressBar,
|
|
29
29
|
setupProgressBar,
|
|
30
30
|
)
|
|
31
|
+
from nuitka.PythonFlavors import isAnacondaPython, isHomebrewPython
|
|
32
|
+
from nuitka.PythonVersions import getSystemPrefixPath
|
|
31
33
|
from nuitka.Tracing import general, inclusion_logger
|
|
32
34
|
from nuitka.utils.FileOperations import areInSamePaths, isFilenameBelowPath
|
|
33
35
|
from nuitka.utils.SharedLibraries import copyDllFile, setSharedLibraryRPATH
|
|
@@ -220,6 +222,9 @@ def copyDllsUsed(dist_dir, standalone_entry_points):
|
|
|
220
222
|
def _reduceToPythonPath(used_dlls):
|
|
221
223
|
inside_paths = getPythonUnpackedSearchPath()
|
|
222
224
|
|
|
225
|
+
if isAnacondaPython() or isHomebrewPython():
|
|
226
|
+
inside_paths.insert(0, getSystemPrefixPath())
|
|
227
|
+
|
|
223
228
|
def decideInside(dll_filename):
|
|
224
229
|
return any(
|
|
225
230
|
isFilenameBelowPath(path=inside_path, filename=dll_filename)
|
|
@@ -284,7 +289,7 @@ def _detectUsedDLLs(standalone_entry_point, source_dir):
|
|
|
284
289
|
# TODO: If used by a DLL from the same folder, put it there,
|
|
285
290
|
# otherwise top level, but for now this is limited to a few cases
|
|
286
291
|
# where required that way (openvino) or known to be good only (av),
|
|
287
|
-
# because it broke other things.
|
|
292
|
+
# because it broke other things. spell-checker: ignore openvino
|
|
288
293
|
if standalone_entry_point.package_name in (
|
|
289
294
|
"openvino",
|
|
290
295
|
"av",
|
nuitka/importing/ImportCache.py
CHANGED
|
@@ -68,14 +68,14 @@ def replaceImportedModule(old, new):
|
|
|
68
68
|
imported_by_name[key] = new
|
|
69
69
|
break
|
|
70
70
|
else:
|
|
71
|
-
assert False
|
|
71
|
+
assert False, (old, new)
|
|
72
72
|
|
|
73
73
|
for key, value in imported_modules.items():
|
|
74
74
|
if value == old:
|
|
75
75
|
imported_modules[key] = new
|
|
76
76
|
break
|
|
77
77
|
else:
|
|
78
|
-
assert False
|
|
78
|
+
assert False, (old, new)
|
|
79
79
|
|
|
80
80
|
|
|
81
81
|
# Part of "Nuitka", an optimizing Python compiler that is compatible and
|
|
@@ -15,101 +15,103 @@ from nuitka.utils.ModuleNames import ModuleName
|
|
|
15
15
|
|
|
16
16
|
_six_moves = {
|
|
17
17
|
"six.moves.builtins": "__builtin__" if python_version < 0x300 else "builtins",
|
|
18
|
-
"six.moves.configparser":
|
|
19
|
-
|
|
20
|
-
|
|
18
|
+
"six.moves.configparser": (
|
|
19
|
+
"ConfigParser" if python_version < 0x300 else "configparser"
|
|
20
|
+
),
|
|
21
21
|
"six.moves.copyreg": "copy_reg" if python_version < 0x300 else "copyreg",
|
|
22
22
|
"six.moves.dbm_gnu": "gdbm" if python_version < 0x300 else "dbm.gnu",
|
|
23
|
-
"six.moves._dummy_thread":
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
"six.moves.http_cookiejar":
|
|
27
|
-
|
|
28
|
-
|
|
23
|
+
"six.moves._dummy_thread": (
|
|
24
|
+
"dummy_thread" if python_version < 0x300 else "_dummy_thread"
|
|
25
|
+
),
|
|
26
|
+
"six.moves.http_cookiejar": (
|
|
27
|
+
"cookielib" if python_version < 0x300 else "http.cookiejar"
|
|
28
|
+
),
|
|
29
29
|
"six.moves.http_cookies": "Cookie" if python_version < 0x300 else "http.cookies",
|
|
30
|
-
"six.moves.html_entities":
|
|
31
|
-
|
|
32
|
-
|
|
30
|
+
"six.moves.html_entities": (
|
|
31
|
+
"htmlentitydefs" if python_version < 0x300 else "html.entities"
|
|
32
|
+
),
|
|
33
33
|
"six.moves.html_parser": "HTMLParser" if python_version < 0x300 else "html.parser",
|
|
34
34
|
"six.moves.http_client": "httplib" if python_version < 0x300 else "http.client",
|
|
35
|
-
"six.moves.email_mime_multipart":
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
"six.moves.email_mime_nonmultipart":
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
35
|
+
"six.moves.email_mime_multipart": (
|
|
36
|
+
"email.MIMEMultipart" if python_version < 0x300 else "email.mime.multipart"
|
|
37
|
+
),
|
|
38
|
+
"six.moves.email_mime_nonmultipart": (
|
|
39
|
+
"email.MIMENonMultipart"
|
|
40
|
+
if python_version < 0x300
|
|
41
|
+
else "email.mime.nonmultipart"
|
|
42
|
+
),
|
|
43
|
+
"six.moves.email_mime_text": (
|
|
44
|
+
"email.MIMEText" if python_version < 0x300 else "email.mime.text"
|
|
45
|
+
),
|
|
46
|
+
"six.moves.email_mime_base": (
|
|
47
|
+
"email.MIMEBase" if python_version < 0x300 else "email.mime.base"
|
|
48
|
+
),
|
|
49
|
+
"six.moves.BaseHTTPServer": (
|
|
50
|
+
"BaseHTTPServer" if python_version < 0x300 else "http.server"
|
|
51
|
+
),
|
|
52
|
+
"six.moves.CGIHTTPServer": (
|
|
53
|
+
"CGIHTTPServer" if python_version < 0x300 else "http.server"
|
|
54
|
+
),
|
|
55
|
+
"six.moves.SimpleHTTPServer": (
|
|
56
|
+
"SimpleHTTPServer" if python_version < 0x300 else "http.server"
|
|
57
|
+
),
|
|
56
58
|
"six.moves.cPickle": "cPickle" if python_version < 0x300 else "pickle",
|
|
57
59
|
"six.moves.queue": "Queue" if python_version < 0x300 else "queue",
|
|
58
60
|
"six.moves.reprlib": "repr" if python_version < 0x300 else "reprlib",
|
|
59
|
-
"six.moves.socketserver":
|
|
60
|
-
|
|
61
|
-
|
|
61
|
+
"six.moves.socketserver": (
|
|
62
|
+
"SocketServer" if python_version < 0x300 else "socketserver"
|
|
63
|
+
),
|
|
62
64
|
"six.moves._thread": "thread" if python_version < 0x300 else "_thread",
|
|
63
65
|
"six.moves.tkinter": "Tkinter" if python_version < 0x300 else "tkinter",
|
|
64
|
-
"six.moves.tkinter_dialog":
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
"six.moves.tkinter_filedialog":
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
"six.moves.tkinter_scrolledtext":
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
"six.moves.tkinter_simpledialog":
|
|
74
|
-
|
|
75
|
-
|
|
66
|
+
"six.moves.tkinter_dialog": (
|
|
67
|
+
"Dialog" if python_version < 0x300 else "tkinter.dialog"
|
|
68
|
+
),
|
|
69
|
+
"six.moves.tkinter_filedialog": (
|
|
70
|
+
"FileDialog" if python_version < 0x300 else "tkinter.filedialog"
|
|
71
|
+
),
|
|
72
|
+
"six.moves.tkinter_scrolledtext": (
|
|
73
|
+
"ScrolledText" if python_version < 0x300 else "tkinter.scrolledtext"
|
|
74
|
+
),
|
|
75
|
+
"six.moves.tkinter_simpledialog": (
|
|
76
|
+
"SimpleDialog" if python_version < 0x300 else "tkinter.simpledialog"
|
|
77
|
+
),
|
|
76
78
|
"six.moves.tkinter_tix": "Tix" if python_version < 0x300 else "tkinter.tix",
|
|
77
79
|
"six.moves.tkinter_ttk": "ttk" if python_version < 0x300 else "tkinter.ttk",
|
|
78
|
-
"six.moves.tkinter_constants":
|
|
79
|
-
|
|
80
|
-
|
|
80
|
+
"six.moves.tkinter_constants": (
|
|
81
|
+
"Tkconstants" if python_version < 0x300 else "tkinter.constants"
|
|
82
|
+
),
|
|
81
83
|
"six.moves.tkinter_dnd": "Tkdnd" if python_version < 0x300 else "tkinter.dnd",
|
|
82
|
-
"six.moves.tkinter_colorchooser":
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
"six.moves.tkinter_commondialog":
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
"six.moves.tkinter_tkfiledialog":
|
|
89
|
-
|
|
90
|
-
|
|
84
|
+
"six.moves.tkinter_colorchooser": (
|
|
85
|
+
"tkColorChooser" if python_version < 0x300 else "tkinter_colorchooser"
|
|
86
|
+
),
|
|
87
|
+
"six.moves.tkinter_commondialog": (
|
|
88
|
+
"tkCommonDialog" if python_version < 0x300 else "tkinter_commondialog"
|
|
89
|
+
),
|
|
90
|
+
"six.moves.tkinter_tkfiledialog": (
|
|
91
|
+
"tkFileDialog" if python_version < 0x300 else "tkinter.filedialog"
|
|
92
|
+
),
|
|
91
93
|
"six.moves.tkinter_font": "tkFont" if python_version < 0x300 else "tkinter.font",
|
|
92
|
-
"six.moves.tkinter_messagebox":
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
"six.moves.tkinter_tksimpledialog":
|
|
96
|
-
|
|
97
|
-
|
|
94
|
+
"six.moves.tkinter_messagebox": (
|
|
95
|
+
"tkMessageBox" if python_version < 0x300 else "tkinter.messagebox"
|
|
96
|
+
),
|
|
97
|
+
"six.moves.tkinter_tksimpledialog": (
|
|
98
|
+
"tkSimpleDialog" if python_version < 0x300 else "tkinter_tksimpledialog"
|
|
99
|
+
),
|
|
98
100
|
"six.moves.urllib_parse": None if python_version < 0x300 else "urllib.parse",
|
|
99
101
|
"six.moves.urllib_error": None if python_version < 0x300 else "urllib.error",
|
|
100
|
-
"six.moves.urllib_robotparser":
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
"six.moves.xmlrpc_client":
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
"six.moves.xmlrpc_server":
|
|
107
|
-
|
|
108
|
-
|
|
102
|
+
"six.moves.urllib_robotparser": (
|
|
103
|
+
"robotparser" if python_version < 0x300 else "urllib.robotparser"
|
|
104
|
+
),
|
|
105
|
+
"six.moves.xmlrpc_client": (
|
|
106
|
+
"xmlrpclib" if python_version < 0x300 else "xmlrpc.client"
|
|
107
|
+
),
|
|
108
|
+
"six.moves.xmlrpc_server": (
|
|
109
|
+
"SimpleXMLRPCServer" if python_version < 0x300 else "xmlrpc.server"
|
|
110
|
+
),
|
|
109
111
|
"six.moves.winreg": "_winreg" if python_version < 0x300 else "winreg",
|
|
110
|
-
"six.moves.urllib.request":
|
|
111
|
-
|
|
112
|
-
|
|
112
|
+
"six.moves.urllib.request": (
|
|
113
|
+
"urllib2" if python_version < 0x300 else "urllib.request"
|
|
114
|
+
),
|
|
113
115
|
}
|
|
114
116
|
|
|
115
117
|
|
nuitka/importing/Importing.py
CHANGED
|
@@ -21,7 +21,6 @@ it's from the standard library, one can abuse the attribute ``__file__`` of the
|
|
|
21
21
|
|
|
22
22
|
"""
|
|
23
23
|
|
|
24
|
-
|
|
25
24
|
import collections
|
|
26
25
|
import os
|
|
27
26
|
import sys
|
|
@@ -131,6 +130,38 @@ def makeModuleUsageAttempt(
|
|
|
131
130
|
)
|
|
132
131
|
|
|
133
132
|
|
|
133
|
+
def makeParentModuleUsagesAttempts(module_usage_attempt):
|
|
134
|
+
result = []
|
|
135
|
+
|
|
136
|
+
for parent_package_name in module_usage_attempt.module_name.getParentPackageNames():
|
|
137
|
+
(
|
|
138
|
+
_parent_package_name,
|
|
139
|
+
parent_module_filename,
|
|
140
|
+
parent_module_kind,
|
|
141
|
+
parent_module_finding,
|
|
142
|
+
) = locateModule(
|
|
143
|
+
module_name=parent_package_name,
|
|
144
|
+
parent_package=None,
|
|
145
|
+
level=0,
|
|
146
|
+
)
|
|
147
|
+
|
|
148
|
+
result.append(
|
|
149
|
+
makeModuleUsageAttempt(
|
|
150
|
+
module_name=parent_package_name,
|
|
151
|
+
filename=parent_module_filename,
|
|
152
|
+
finding=parent_module_finding,
|
|
153
|
+
module_kind=parent_module_kind,
|
|
154
|
+
level=0,
|
|
155
|
+
source_ref=module_usage_attempt.source_ref,
|
|
156
|
+
reason="import path parent",
|
|
157
|
+
)
|
|
158
|
+
)
|
|
159
|
+
|
|
160
|
+
result.append(module_usage_attempt)
|
|
161
|
+
|
|
162
|
+
return tuple(result)
|
|
163
|
+
|
|
164
|
+
|
|
134
165
|
def addMainScriptDirectory(main_dir):
|
|
135
166
|
"""Initialize the main script directory.
|
|
136
167
|
|
|
@@ -920,6 +951,7 @@ _stdlib_module_raises = {
|
|
|
920
951
|
"_subprocess": False,
|
|
921
952
|
"_sha": False, # TODO: Not entirely clear if that's true
|
|
922
953
|
"_sha1": False,
|
|
954
|
+
"_sha2": False,
|
|
923
955
|
"_sha256": False,
|
|
924
956
|
"_sha3": False,
|
|
925
957
|
"_sha512": False,
|
|
@@ -983,6 +1015,7 @@ _stdlib_module_raises = {
|
|
|
983
1015
|
"zipimport": False,
|
|
984
1016
|
"zlib": False,
|
|
985
1017
|
"_ssl": True,
|
|
1018
|
+
"_xxinterpchannels": False,
|
|
986
1019
|
}
|
|
987
1020
|
|
|
988
1021
|
|
|
@@ -2,18 +2,33 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
# We are not avoiding these in generated code at all
|
|
5
|
-
# pylint: disable=I0021,too-many-lines
|
|
6
|
-
# pylint: disable=I0021,
|
|
7
|
-
# pylint: disable=I0021,too-many-instance-attributes
|
|
8
|
-
# pylint: disable=I0021,too-many-return-statements
|
|
5
|
+
# pylint: disable=I0021,line-too-long,too-many-instance-attributes,too-many-lines
|
|
6
|
+
# pylint: disable=I0021,too-many-arguments,too-many-return-statements,too-many-statements
|
|
9
7
|
|
|
10
8
|
|
|
11
9
|
"""Specialized attribute nodes
|
|
12
10
|
|
|
13
11
|
WARNING, this code is GENERATED. Modify the template AttributeNodeFixed.py.j2 instead!
|
|
14
12
|
|
|
15
|
-
spell-checker: ignore append
|
|
16
|
-
spell-checker: ignore
|
|
13
|
+
spell-checker: ignore __prepare__ append args autograph buffering capitalize casefold
|
|
14
|
+
spell-checker: ignore center chars clear closefd copy count decode default delete dist
|
|
15
|
+
spell-checker: ignore distribution_name encode encoding end endswith errors exit_code
|
|
16
|
+
spell-checker: ignore expandtabs experimental_attributes experimental_autograph_options
|
|
17
|
+
spell-checker: ignore experimental_compile experimental_follow_type_hints
|
|
18
|
+
spell-checker: ignore experimental_implements experimental_relax_shapes extend file
|
|
19
|
+
spell-checker: ignore fillchar find format format_map formatmap fromkeys func get group
|
|
20
|
+
spell-checker: ignore handle has_key haskey index input_signature insert isalnum isalpha
|
|
21
|
+
spell-checker: ignore isascii isdecimal isdigit isidentifier islower isnumeric isprintable
|
|
22
|
+
spell-checker: ignore isspace istitle isupper item items iterable iteritems iterkeys
|
|
23
|
+
spell-checker: ignore itervalues jit_compile join keepends key keys kwargs ljust lower
|
|
24
|
+
spell-checker: ignore lstrip maketrans maxsplit mode name new newline old opener p package
|
|
25
|
+
spell-checker: ignore package_or_requirement pairs partition path pop popitem prefix
|
|
26
|
+
spell-checker: ignore prepare reduce_retracing remove replace resource resource_name
|
|
27
|
+
spell-checker: ignore reverse rfind rindex rjust rpartition rsplit rstrip s sep setdefault
|
|
28
|
+
spell-checker: ignore sort split splitlines start startswith stop strip sub suffix
|
|
29
|
+
spell-checker: ignore swapcase table tabsize title translate update upper use_errno
|
|
30
|
+
spell-checker: ignore use_last_error value values viewitems viewkeys viewvalues width
|
|
31
|
+
spell-checker: ignore winmode zfill
|
|
17
32
|
"""
|
|
18
33
|
|
|
19
34
|
|
|
@@ -203,9 +203,11 @@ class StatementSpecialUnpackCheckFromIterated(
|
|
|
203
203
|
result = makeRaiseExceptionReplacementStatement(
|
|
204
204
|
statement=self,
|
|
205
205
|
exception_type="ValueError",
|
|
206
|
-
exception_value=
|
|
207
|
-
|
|
208
|
-
|
|
206
|
+
exception_value=(
|
|
207
|
+
"too many values to unpack"
|
|
208
|
+
if python_version < 0x300
|
|
209
|
+
else "too many values to unpack (expected %d)" % self.count
|
|
210
|
+
),
|
|
209
211
|
)
|
|
210
212
|
|
|
211
213
|
trace_collection.onExceptionRaiseExit(TypeError)
|