如何在石墨烯模式中使用 Python 保留/限制词?

问题描述

我目前正在为 Jira REST API 构建一个带有 GrapheneGraphQL 包装器,但该服务在Python。 IE。这些是您从 Jira Projects 中获取的一些字段:

[{
    "self": "https://myproject.atlassian.net/rest/api/3/project","id": "12345","avatarUrls": {
        "48x48": "https://myproject.atlassian.net/...","24x24": "https://myproject.atlassian.net/...","16x16": "https://myproject.atlassian.net/...","32x32": "https://myproject.atlassian.net/..."
    }
    ...
}]

为了将此响应映射到我尝试使用下划线名称(例如 _48x48)的模式,但在我启动 Flask 应用程序时立即引发此错误

AssertionError: Names must match /^[_a-zA-Z][_a-zA-Z0-9]*$/ but "48x48" does not

有没有正确的方法将这些特殊的领域映射到石墨烯中?

预先感谢所有帮助。

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)