python - Hunk #1 在 53 时失败
问题描述
我正在使用 python-for-android 在 python 脚本中创建一个 android 应用程序
在 pycharm 中创建应用程序时,我遇到了一些错误,甚至我不知道为什么会导致这些错误
[INFO]: Prebuilding six for armeabi-v7a
[INFO]: six has no prebuild_armeabi_v7a, skipping
[INFO]: Prebuilding pyjnius for armeabi-v7a
[INFO]: pyjnius has no prebuild_armeabi_v7a, skipping
[INFO]: Applying patches for pyjnius[armeabi-v7a]
[INFO]: Applying patch sdl2_jnienv_getter.patch
[INFO]: -> running patch -t -d /home/veluvijay/.local/share/python-for-android/build/other_builds...(and 167 more)
working: 1 out of 1 hunk FAILED -- saving rejects to file setup.py.rej Exception in thread background thread for pid 13494:
Traceback (most recent call last):
File "/usr/lib/python3.6/threading.py", line 916, in _bootstrap_inner
self.run()
File "/usr/lib/python3.6/threading.py", line 864, in run
self._target(*self._args, **self._kwargs)
File "/home/veluvijay/envs/imagetotext/lib/python3.6/site-packages/sh.py", line 2170, in background_thread
handle_exit_code(exit_code)
File "/home/veluvijay/envs/imagetotext/lib/python3.6/site-packages/sh.py", line 1929, in fn
return self.command.handle_command_exit_code(exit_code)
File "/home/veluvijay/envs/imagetotext/lib/python3.6/site-packages/sh.py", line 672, in handle_command_exit_code
raise exc
sh.ErrorReturnCode_1:
RAN: /usr/bin/patch -t -d /home/veluvijay/.local/share/python-for-android/build/other_builds/pyjnius-python2-sdl2/armeabi-v7a/pyjnius -p1 -i /home/veluvijay/envs/imagetotext/lib/python3.6/site-packages/pythonforandroid/recipes/pyjnius/sdl2_jnienv_getter.patch
STDOUT:
patching file jnius/jnius_jvm_android.pxi
patching file setup.py
Hunk #1 FAILED at 53.
1 out of 1 hunk FAILED -- saving rejects to file setup.py.rej
STDERR:
解决方案
修补文件 setup.py Hunk #1 FAILED at 53。
您的补丁文件导致错误,您可能需要删除或更改它。
推荐阅读
- android - 从 Firebase 中检索特定数据
- java - JavaFX 不适用于 IntelliJ (jdk 9)
- python - 为什么放入'if'语句时函数会自动打印
- postgresql - Docker - 无法访问 postgres 数据库
- python - datepicker 在 django 中不起作用?
- android - POST 因 Retrofit 失败(连接超时),但可与 Postman 一起使用
- node.js - Vue.js:找不到模块
- reactjs - 如何调度从 API 获取的数据?
- html - HTML colspan 和 rowspan 问题
- c++ - 我有一个字符串变量 word="APA"