`Application.launch_instance()` does not return any `start()` values
- 主要語言
- Python
- 星號
- 653
- 分支
- 217
- 平均合併
- 2 天 21 小時
- 30 天內合併 PR
- 2
描述
Currently (v5.0.0.dev) `launch_instance()` method invokes `start()` without returning its value:
def launch_instance(cls, argv=None, **kwargs):
app = cls.instance(**kwargs)
app.initialize(argv)
app.start()
But the `start()` method by default returns the value from any sub-application:
def start(self):
if self.subapp is not None:
return self.subapp.start()
So any values returned from the *sub-app* are lost if `launch_instance()` is used.
Is that on purpose?
## Sidenote
Strangely, in jupyter, the `JupyterApp.launch_instance()` method returns whatever the `Application.launch_instance()` return, which is nothing of course, and the question is: why does it return a guranteed `None`?
貢獻指南
研究方向
Start by reading Application.launch_instance() and Application.start(), then inspect any tests covering application startup and sub-applications. Confirm how JupyterApp.launch_instance() uses the result. Done means values returned by start(), including sub-application results, are preserved when launch_instance() is called, with regression coverage.
由索引模型根據 Issue 內容生成。
評估
- 技術堆疊
- python
- 領域
- cli
- Issue 類型
- 缺陷
- 難度
- 2/5
- 預估耗時
- 1-3 小時
- 活躍度
- 停滯
- 描述清晰度
- 基本清楚
- 新手友好度
- 35/100