jupyterlab / jupyterlab-git

A Git extension for JupyterLab
BSD 3-Clause "New" or "Revised" License
1.46k stars 319 forks source link

commit message always set to "Committing changes..." (v0.50.0a0) #1281

Closed CagtayFabry closed 1 year ago

CagtayFabry commented 1 year ago

Thanks for releasing with support for JupyterLab 4 ! Trying out the 0.50.0a0 release, I noticed that my commit messages (summary and/or description) are not registered with git, instead every commit shows Committing changes... as commit message.

Description

When committing changes using the extension UI, the commit message is always set to Committing changes... . This can be verified using git log or the history view of the extension (commit console was created from command line): image

Reproduce

  1. Go to any git repository (or create a new one)
  2. Stage changes
  3. Enter commit summary (and optionally description)
  4. click COMMIT in the extension UI
  5. verify git log

Expected behavior

The commit message summary and description provided by the user should be attached to the commit.

Context

Command Line Output
Paste the output from your command line running `jupyter lab` here, use `--debug` if possible.
Web Browser Output
Paste the output from your browser web console here.
welcome[bot] commented 1 year ago

Thank you for opening your first issue in this project! Engagement like this is essential for open source projects! :hugs:
If you haven't done so already, check out Jupyter's Code of Conduct. Also, please try to follow the issue template as it helps other other community members to contribute more effectively. welcome You can meet the other Jovyans by joining our Discourse forum. There is also an intro thread there where you can stop by and say Hi! :wave:
Welcome to the Jupyter community! :tada:

krassowski commented 1 year ago

Indeed, message gets overridden here:

https://github.com/jupyterlab/jupyterlab-git/blob/e95a9e56613b3827b90fdf50a2c0d71687ae37af/src/components/GitPanel.tsx#L782-L806

It is quite interesting case of TypeScript not picking it up because it is in another scope (try-catch context).