我通过api上传了一些图片到帖子中,为什么只有部分图片有灯箱效果?

AI 生成的摘要

昊毅_周 reported that images uploaded via the Admin API to a Discourse post lacked lightbox effects, despite having identical dimensions and aspect ratios. blake requested the API call details and suggested checking if rebuilding the HTML or manually creating posts via the UI reproduced the issue, aiming to determine if the problem was specific to the API or the platform. 昊毅_周 confirmed that rebuilding the HTML did not resolve the issue. Ultimately, 昊毅_周 stated that the issue was resolved by adding a 200ms delay between each API call in the automation script, which allowed all images to display correctly with lightbox effects.

https://openttc.com/t/topic/74
请看这个帖子。
我通过admin API,使用自动化脚本上传了一些图片。
但是只有少部分图片有灯箱效果。
图片的长和宽以及比例都是相同的。

您能否分享一下您用来创建带有图片链接的帖子的 API 调用?

如果您重建帖子的 HTML,它会创建灯箱吗?

另外,如果您手动创建一些带有图片的帖子,就像您的 API 调用所做的那样,它是否不会为其中一些帖子创建灯箱?试图弄清楚这是 API 问题,还是 UI 中也存在同样的问题。

@昊毅_周 您的问题解决了吗?

通过rebuild HTML还是无法解决问题。

我想应该是解决了。
我的自动化脚本一开始没有设置延迟,后来我给每次API调用增加了一个200ms的延迟。所有的图片都正常了。
谢谢!