Fixing the snippet editing form
What does this MR do?
A hotfix for editing Snippets with multi-file support
What's the problem?
In the course of preparing the snippets with multi-file support, we were not able to roll out the full-size feature and following the iterative approach, decided to go in small steps. There are a lot of steps FE should take there, but the very first one is to support blobs
Array (where we return the blob
Objects). For the snippet view, this has been implemented in !35605 (merged). However, I overlooked that by introducing the blobs
array, I left out the original blob
object that, even though not used by the view, is still used by the edit form and should be updated only in #220785 (closed). Before that Issue is resolved, Snippet edit form should rely on singular blob
object alongside the blobs
array. This is supported on the BE side.
So, in essence, it's impossible to edit a Snippet atm and this MR addresses that.
So what does this MR do after all?
The MR puts back the singular blob
object for the Snippet edit form to keep working while the work on implementing #220785 (closed) is in progress.
Screenshots
Before | After |
---|---|
![]() |
![]() |
Does this MR meet the acceptance criteria?
Conformity
-
Changelog entry -
Documentation (if required) -
Code review guidelines -
Merge request performance guidelines -
Style guides -
Database guides -
Separation of EE specific content
Availability and Testing
-
Review and add/update tests for this feature/bug. Consider all test levels. See the Test Planning Process. -
Tested in all supported browsers -
Informed Infrastructure department of a default or new setting change, if applicable per definition of done
Security
If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:
-
Label as security and @ mention @gitlab-com/gl-security/appsec
-
The MR includes necessary changes to maintain consistency between UI, API, email, or other methods -
Security reports checked/validated by a reviewer from the AppSec team