Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Uploaded files are not appearing in channel and do not contain mimetype

未关闭
#1,575 39 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
25/100
Issue 类型
缺陷
描述清晰度
需要澄清
活跃度
停滞
技术栈
python
领域
api

调研方向

首先使用提供的 Python runtime 详细信息,复现 issue 中所示的三个 Slack API 调用:files.getUploadURLExternal、files.completeUploadExternal 和 files.sharedPublicURL。将由此得到的文件可见性、频道关联和 mimetype 字段与 Slack API 文档进行比较。完成的标准是记录下原因,或确定一项具体的 SDK 更改,并提供可复现的测试用例。

由索引模型根据 Issue 内容生成。

描述

auto-triage-skip question server-side-issue Version: 3x web-client

I am trying to upload a file to a private Slack channel using the Slack API via the following Python script.
However, once uploaded, the file cannot be downloaded by users in the channel. I am looking for help to understand why this is happening and how to resolve it.

Python runtime version

3.12.1

I used these step:
  1. https://slack.com/api/files.getUploadURLExternal
  2. https://slack.com/api/files.completeUploadExternal
  3. https://slack.com/api/files.sharedPublicURL
Actual result:
{
  "ok": true,
  "file": {
    "id": "XXXXXXXXXX",
    "created": 1729848820,
    "timestamp": 1729848820,
    "name": "xxxxxxxxxxxxxxxxxx.xxx",
    "title": "xxxxxxxxxxxxxxxxxxxx.xxx",
    "mimetype": "",
    "filetype": "",
    "pretty_type": "",
    "user": "XXXXXXXXX",
    "user_team": "XXXXXXXX",
    "editable": false,
    "size": 61652577,
    "mode": "hosted",
    "is_external": false,
    "external_type": "",
    "is_public": false,
    "public_url_shared": true,
    "display_as_bot": false,
    "username": "",
    "url_private": "https://files.slack.com/files-pri/xxxxxxxxx-xxxxxxxxxx/xxxxxxxxxxxxxxxxxx.xxx",
    "url_private_download": "https://files.slack.com/files-pri/xxxxxxxxxxxxx-xxxxxxx/download/xxxxxxxxxxxxxxxxxx.xxx",
    "media_display_type": "unknown",
    "permalink": "https://xxxxxxxxx.slack.com/files/xxxxxxxxxx/xxxxxxxxxxxxxxx/xxxxxxxxxxxxx.xxx",
    "permalink_public": "https://slack-files.com/xxxxxxxxxx-xxxxxxxxxxxxx-xxxxxxxxxxxxx",
    "comments_count": 0,
    "is_starred": false,
    "shares": {},
    "channels": [],
    "groups": [],
    "ims": [],
    "has_more_shares": false,
    "has_rich_preview": false,
    "file_access": "visible"
  }
}
主要语言
Python
星标
4k
派生
857
平均合并
22 小时 21 分钟
30 天内合并 PR
16

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

slackapi/python-slack-sdk 的其他 Issue

查看 slackapi/python-slack-sdk 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。