MerginMaps / MerginMaps/python-api-client

Check project ID when doing sync

未关闭
#191 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

enhancement
主要语言
Python
星标
23
派生
12
平均合并
2 天 13 小时
30 天内合并 PR
7

描述

When doing project pull/push, we should check project info based on project's ID instead of project name, to make sure that we're do the right thing even if something happened to the project:

  • project got renamed (or project was transferred to other workspace and we still have access to it) - we sync as usual, using the new project name when doing upload/download API calls
  • project was deleted - if project info returns 404, we know it got deleted
  • project access permission was removed from our user - if project info returns 403, we know there's permission problem

Note: some projects created/updated with an old version of MM plugin will not have project ID stored in the metadata - it would be good if we could handle those correctly as well (just hope that the project was not renamed / transferred).

Once #190 is implemented, it should be possible to add auto tests that will exercise that check.

贡献指南

打开贡献指南

从这里开始

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

调研方向

首先跟踪项目的 pull/push 流程,以及项目元数据当前如何存储项目名称。查看 project-info API 调用和 issue #190,然后添加对基于 ID 的查找、重命名或转移处理、404 删除以及 403 权限错误的检查,同时保留对不含 ID 的元数据的现有行为。完成时应包含 issue 中描述的自动化测试。

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

评估

技术栈
python
领域
api
Issue 类型
功能
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
42/100

把新 issue 发到你的邮箱

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