Tencent/tinker · error · TinkerRuntimeException

patch lib file directory not found, warning why the path is

Error message

patch lib file directory not found, warning why the path is null!!!!

What it means

Error "patch lib file directory not found, warning why the path is null!!!!" thrown in Tencent/tinker.

Source

Thrown at tinker-android/tinker-android-lib-no-op/src/main/java/com/tencent/tinker/lib/tinker/TinkerLoadResult.java:243

                    tinker.getLoadReporter().onLoadFileNotFound(new File(dexOptPath),
                        ShareConstants.TYPE_DEX_OPT, false);

                } else {
                    ShareTinkerLog.e(TAG, "patch dex opt file not found, but path is null!!!!");
                    throw new TinkerRuntimeException("patch dex opt file not found, but path is null!!!!");
                    // tinker.getLoadReporter().onLoadFileNotFound(null,
                    //     ShareConstants.TYPE_DEX, false);
                }
                break;
            case ShareConstants.ERROR_LOAD_PATCH_VERSION_LIB_DIRECTORY_NOT_EXIST:
                if (patchVersionDirectory != null) {
                    ShareTinkerLog.e(TAG, "patch lib file directory not found:%s", libraryDirectory.getAbsolutePath());
                    tinker.getLoadReporter().onLoadFileNotFound(libraryDirectory,
                        ShareConstants.TYPE_LIBRARY, true);
                } else {
                    //should be not here
                    ShareTinkerLog.e(TAG, "patch lib file directory not found, warning why the path is null!!!!");
                    throw new TinkerRuntimeException("patch lib file directory not found, warning why the path is null!!!!");

                    // tinker.getLoadReporter().onLoadFileNotFound(null,
                    //     ShareConstants.TYPE_LIBRARY, true);
                }

                break;
            case ShareConstants.ERROR_LOAD_PATCH_VERSION_LIB_FILE_NOT_EXIST:
                String libPath = ShareIntentUtil.getStringExtra(intentResult,
                    ShareIntentUtil.INTENT_PATCH_MISSING_LIB_PATH);
                if (libPath != null) {
                    //we only pass one missing file and then we break
                    ShareTinkerLog.e(TAG, "patch lib file not found:%s", libPath);
                    tinker.getLoadReporter().onLoadFileNotFound(new File(libPath),
                        ShareConstants.TYPE_LIBRARY, false);
                } else {
                    ShareTinkerLog.e(TAG, "patch lib file not found, but path is null!!!!");
                    throw new TinkerRuntimeException("patch lib file not found, but path is null!!!!");
                    // tinker.getLoadReporter().onLoadFileNotFound(null,

View on GitHub (pinned to 1b7ea02c23)

Solutions

  1. Re-apply the patch so the lib directory under the patch version directory is recreated.
  2. Verify the patch package actually contains native libraries matching the device ABI.

When it happens

Trigger: Thrown at tinker-android/tinker-android-lib-no-op/src/main/java/com/tencent/tinker/lib/tinker/TinkerLoadResult.java:243 when the library encounters an invalid state.

Common situations: Thrown in TinkerLoadResult.parseTinkerResult on ERROR_LOAD_PATCH_VERSION_LIB_DIRECTORY_NOT_EXIST when patchVersionDirectory is null, a state the code marks as 'should not be here'. Indicates corrupted patch application state.


AI-assisted analysis of Tencent/tinker@1b7ea02c23 (2026-08-14). Data as JSON: /api/errors/f36261264db9cff1. Report an issue: GitHub.