Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

获远程接口数据失败 Error: compiler error in defname: #400

Open
xdqsgit opened this issue Dec 12, 2023 · 1 comment
Open

获远程接口数据失败 Error: compiler error in defname: #400

xdqsgit opened this issue Dec 12, 2023 · 1 comment
Labels
question Further information is requested

Comments

@xdqsgit
Copy link

xdqsgit commented Dec 12, 2023

What happens(发生了什么)?

.net 后端 提供的swagger 无法生成接口代码
日志如下:

本地数据源更新中...
[OriginManage ] [fetchMethod] 获远程数据中...
[OriginManage ] [translate] 翻译接口数据中的非法字符
[OriginManage ] 解析接口文本数据
[OriginManage ] [transform2StandardDataSource] 将远程数据转化成 pont 标准数据模型
[OriginManage ] 获远程接口数据失败 Error: compiler error in defname: Volo.Abp.Application.Dtos.ListResultDto`1[[Volo.Abp.Identity.IdentityRoleDto, Volo.Abp.Identity.Application.Contracts, Version=7.4.3.0, Culture=neutral, PublicKeyToken=null]]
[OriginManage ] 本地数据源更新完成

A clear and concise description of what the bug is(对错误的清晰而简明的描述).

Mini Showcase Repository(迷你展示库)

Provide a mini GitHub repository which can reproduce the issue(提供一个可以重现问题的小型 Github 存储库).

How To Reproduce(如何重现)

Steps to reproduce the behavior(重现行为的步骤): 1. 2.

Expected behavior(预期行为) 1. 2.

Context(上下文)

swagger 正文包含如下内容:
....

 "/api/identity/roles/all": {
            "get": {
                "tags": [
                    "Role"
                ],
                "responses": {
                    "200": {
                        "description": "Success",
                        "content": {
                            "text/plain": {
                                "schema": {
                                    "$ref": "#/components/schemas/Volo.Abp.Application.Dtos.ListResultDto`1[[Volo.Abp.Identity.IdentityRoleDto, Volo.Abp.Identity.Application.Contracts, Version=7.4.3.0, Culture=neutral, PublicKeyToken=null]]"
                                }
                            },
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Volo.Abp.Application.Dtos.ListResultDto`1[[Volo.Abp.Identity.IdentityRoleDto, Volo.Abp.Identity.Application.Contracts, Version=7.4.3.0, Culture=neutral, PublicKeyToken=null]]"
                                }
                            },
                            "text/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/Volo.Abp.Application.Dtos.ListResultDto`1[[Volo.Abp.Identity.IdentityRoleDto, Volo.Abp.Identity.Application.Contracts, Version=7.4.3.0, Culture=neutral, PublicKeyToken=null]]"
                                }
                            }
                        }
                    },

...

  • pont Version: 1.5.2
  • Node Version: 20.14
  • Platform(操作系统平台): win 11
@z979054461
Copy link
Collaborator

swagger中,$ref不正确,参考下这个:
api-docs.json

@z979054461 z979054461 added the question Further information is requested label Jan 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants