Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

表情包制作帮助图片乱码 #43

Closed
Tuio21 opened this issue Apr 5, 2023 · 2 comments
Closed

表情包制作帮助图片乱码 #43

Tuio21 opened this issue Apr 5, 2023 · 2 comments

Comments

@Tuio21
Copy link

Tuio21 commented Apr 5, 2023

-1ee77d73913c93cf
为什么会这样,其他用着都没问题,表情也没问题就是这个有问题

@MeetWq
Copy link
Member

MeetWq commented Apr 5, 2023

装字体

@MeetWq MeetWq closed this as completed Apr 5, 2023
@maoxig
Copy link

maoxig commented Apr 6, 2023

如果你的字体已经安装好了,可以试着去删掉这张帮助图片的缓存,路径参考插件nonebot_plugin_localstore的缓存目录,我猜测是因为

if not meme_list_cache_file.exists():
img = await run_sync(render_meme_list)(meme_list)
with open(meme_list_cache_file, "wb") as f:
f.write(img.getvalue())
else:
img = BytesIO(meme_list_cache_file.read_bytes())

你应该是生成乱码的帮助图后才成功安装上字体,而这张图片没有清除掉,导致发送了之前生成的乱码图。如果删掉这张图片后仍是乱码,那么应该是你字体的问题
这个问题我也出现了,删掉后就没问题了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants