[BUG][R] Generated samples/client/echo_api/r cannot be run
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 2/5
- 見積もり時間
- 1〜3時間
- 初心者へのやさしさ
- 72/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 活発
- 技術スタック
- r
- 領域
- testing-qa
調査の方向性
samples/client/echo_api/r/R/data_query.R の37行目から始め、devtools::test() で失敗を再現します。bin/configs/r-echo-api.yaml のサンプル設定と、動作する R クライアントのテスト設定を比較し、その後 = [SUCCESS, FAILURE] を生成する R テンプレートのパスを追跡します。生成された echo_api R パッケージが読み込まれ、そのテストが構文エラーなしで実行されれば完了です。
索引モデルが issue の本文から書いたものです。
説明
Bug Report Checklist
- Have you provided a full/minimal spec to reproduce the issue?
- Have you validated the input using an OpenAPI validator?
- Have you tested with the latest master to confirm the issue still exists?
- Have you searched for related issues/PRs?
- What's the actual output vs expected output?
- [Optional] Sponsorship to speed up the bug fix or feature request (example)
Description
The generated echo_api client for R breaks out of the box because of invalid R syntax:
The = [SUCCESS, FAILURE] has the appearance of Python code that has snuck in.
openapi-generator version
This is found in the master branch and is an issue in generated integration test code, not an issue found actually running the generator.
OpenAPI declaration file content or url
NA; this is an integration test bug
Generation Details
NA; this is an integration test bug
Steps to reproduce
Navigating to samples/client/echo_api/r, trying to load the package or run tests fails because of the syntax error:
r % Rscript -e 'devtools::test()'
ℹ Testing openapi
Error in `load_all()`:
! Failed to load R/data_query.R
Caused by error in `parse()`:
! At R/data_query.R:37:53: unexpected '['
36: #' @param ... Other optional arguments.
37: initialize = function(`id` = NULL, `outcomes` = [
Related issues/PRs
Not found
Suggest a fix
I am not quite sure what template source is responsible for this errant R code. According to
this uses the same template as the working petstore R client tests; however, the latter three all use settings
exceptionPackage: rlang
useRlangExceptionHandling: true
returnExceptionOnFailure: true
do to which they are following a quite different code generation path that might bypass wherever the issue is. I don't see SUCCESS or FAILURE anywhere in that template directory so I couldn't trace it back any further than that.
- 主要言語
- Java
- スター
- 26.8k
- フォーク
- 7.7k
- 平均マージ
- 3日 16時間
- マージ済み PR(30日)
- 122
環境構築
このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
OpenAPITools/openapi-generator のほかの issue
-
Issue: Bug
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
OpenAPITools/openapi-generator#25021 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
OpenAPITools/openapi-generator#24997 ·
メンテナーはふだん 1 日以内に返信
-
Issue: Bug
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
OpenAPITools/openapi-generator#24859 ·
メンテナーはふだん 1 日以内に返信
-
[BUG][KOTLIN] Fails to compile after updating to 7.25.0 with useJackson3=false useSpringBoot4=trueオープンIssue: Bug
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
OpenAPITools/openapi-generator#24842 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 86/100
OpenAPITools/openapi-generator#24830 ·
メンテナーはふだん 1 日以内に返信
OpenAPITools/openapi-generator の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
apache/arrow-java#1311 ·
メンテナーはふだん 2 日以内に返信
-
bug triage
難易度 2/5 1〜3時間 初心者へのやさしさ 85/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
メンテナーはふだん 1 日以内に返信
-
security
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
IBM/networking-java-sdk#204 ·