Skip to content
This repository has been archived by the owner on Aug 19, 2023. It is now read-only.

图文问题 #11

Open
Pauluooooo opened this issue Apr 20, 2023 · 4 comments
Open

图文问题 #11

Pauluooooo opened this issue Apr 20, 2023 · 4 comments

Comments

@Pauluooooo
Copy link

当一条消息是包含了图片和文字时,似乎只会存储图片,消息的文字并不会显示。并且图片在资源库中是可以看到的,然后再主页看不到,包括第三方的安卓、苹果软件上。

@qazxcdswe123
Copy link
Owner

qazxcdswe123 commented Apr 20, 2023

现在用的逻辑图片相关功能一直有问题,我看看能不能找机会重写一下。。

@lava-lake
Copy link

我也碰上了,这段逻辑有问题

if r.status_code == 200:
media_url = f"{BASE_URL}o/r/{r.json()['data']['id']}/telegram-download.jpg"
markdown_photo_preview_text = "![](" + media_url + ")\n"
data = {"content": markdown_photo_preview_text}
r = requests.post(API_BASE_URL + "memo?openId=" + OPENID, json=data)
update.message.reply_text(f'Uploaded 1 photos. {BASE_URL}m/{r.json()["data"]["id"]}')
else:

@qazxcdswe123
Copy link
Owner

Done

@lava-lake
Copy link

现在出错信息变成 - tgmemobot | 2023-04-29 17:25:51,676 - root - ERROR - Error: expected string or bytes-like object, got 'NoneType' in send_photo_memo

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

No branches or pull requests

3 participants