You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description of the problem, including code/CLI snippet
It appears that the CLI may be passing the actions flag as a string instead of as JSON. I saw this potentially related discussion (it's an old discussion, so it may be out of date), but I couldn't find a corresponding issue.
Create a new commit in the repo with the new files.
Actual Behavior
Fails with a 400 error saying "actions is invalid" (and it's possible I could be missing something here. I checked that my JSON was valid and checked with the official Gitlab API spec as first steps in debugging).
Specifications
python-gitlab version: 5.0.0
Gitlab server version (or gitlab.com):
The text was updated successfully, but these errors were encountered:
Thanks for the report @Anthony-Fiddes! Yes, this is currently still an issue with the CLI unfortunately and we haven't picked this up. See #1735 for more details.
Description of the problem, including code/CLI snippet
It appears that the CLI may be passing the
actions
flag as a string instead of as JSON. I saw this potentially related discussion (it's an old discussion, so it may be out of date), but I couldn't find a corresponding issue.Command run:
gitlab -d project-commit create --project-id ****** --branch main --commit-message 'create multiple/' --actions '[{"action": "create", "file_path": "multiple/file-to-commit1.txt", "content": "@multiple/file-to-commit1.txt"}, {"action": "create", "file_path": "multiple/file-to-commit2.txt", "content": "@multiple/file-to-commit2.txt"}, {"action": "create", "file_path": "multiple/file-to-commit3.txt", "content": "@multiple/file-to-commit3.txt"}]'
Output:
Expected Behavior
Create a new commit in the repo with the new files.
Actual Behavior
Fails with a 400 error saying "actions is invalid" (and it's possible I could be missing something here. I checked that my JSON was valid and checked with the official Gitlab API spec as first steps in debugging).
Specifications
The text was updated successfully, but these errors were encountered: