Skip to content

Commit

Permalink
fix: TRIAG-600: Add missing storage title field to Redis config (#5985)
Browse files Browse the repository at this point in the history
[Re-created using `gh` command line tool for CI (mirror #5552]

This commit adds a required missing field to the Redis storage form --
the storage title. Without this field, the UI will throw an exception
when trying to display the saved configuration's card. See
[Slack](https://label-studio.slack.com/archives/CQ8LYQ0J2/p1709796798556099)
for details.

Also fix the port showing up as `undefined` on the frontend's storage
card. We'll need to make a similar change in LSE.

---------

Co-authored-by: Justin Ziniel <[email protected]>
Co-authored-by: jombooth <[email protected]>
Co-authored-by: robot-ci-heartex <[email protected]>
  • Loading branch information
4 people authored Jun 14, 2024
1 parent 3ebe34a commit 590c8a4
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 21 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/tests-yarn-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
main:
name: "yarn e2e"
runs-on: ubuntu-latest
timeout-minutes: 45
timeout-minutes: 60
steps:
- uses: hmarr/[email protected]

Expand Down Expand Up @@ -56,11 +56,11 @@ jobs:
BUILD_NO_MINIMIZATION: true
run: |
set -xeuo pipefail
yarn lsf:serve &
pid=$!
echo "pid=${pid}" >> $GITHUB_OUTPUT
while ! curl -s -o /dev/null -L "http://localhost:3000"; do
echo "=> Waiting for service to become available"
sleep 2s
Expand Down
11 changes: 8 additions & 3 deletions label_studio/io_storages/redis/form_layout.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
# 2x2 grid
redis_params: &redis_params
redis_title: &redis_title
- type: text
name: title
label: Storage Title

# 2x2 grid
redis_params: &redis_params
- type: text
name: path
label: Path
Expand All @@ -19,7 +21,10 @@ redis_params: &redis_params
label: Port

ImportStorage:
# Title, Path, Password, Host and Port
# Title
- columnCount: 1
fields: *redis_title
# Path, Password, Host and Port
- columnCount: 2
fields: *redis_params
# Regex filter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ const RedisStorage = ({ storage }) => {
<DescriptionList.Item term="Path">{storage.path}</DescriptionList.Item>
<DescriptionList.Item term="Host">
{storage.host}
{storage.port ? `:${storage.post}` : ""}
{storage.port ? `:${storage.port}` : ""}
</DescriptionList.Item>
</>
);
Expand Down
2 changes: 1 addition & 1 deletion web/dist/apps/labelstudio/main.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion web/dist/apps/labelstudio/main.js.map

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions web/dist/apps/labelstudio/version.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"message": "feat: LEAP-1020: Relation side panel improvements (#5711)",
"commit": "9df4eb93ccd4a94a587375f50a225bd754d0df1d",
"date": "2024-06-14T14:28:49.000Z",
"branch": "develop"
"message": "Merge branch 'develop' into 'fb-TRIAG-600/redis-fields'",
"commit": "32748f4b980fdcad979a60e29ccd4cf0cb6b2dc7",
"date": "2024-06-14T13:56:23.000Z",
"branch": "fb-TRIAG-600/redis-fields"
}
8 changes: 4 additions & 4 deletions web/dist/libs/datamanager/version.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"message": "feat: LEAP-1020: Relation side panel improvements (#5711)",
"commit": "9df4eb93ccd4a94a587375f50a225bd754d0df1d",
"date": "2024-06-14T14:28:49.000Z",
"branch": "develop"
"message": "Merge branch 'develop' into 'fb-TRIAG-600/redis-fields'",
"commit": "32748f4b980fdcad979a60e29ccd4cf0cb6b2dc7",
"date": "2024-06-14T13:56:23.000Z",
"branch": "fb-TRIAG-600/redis-fields"
}
8 changes: 4 additions & 4 deletions web/dist/libs/editor/version.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"message": "feat: LEAP-1020: Relation side panel improvements (#5711)",
"commit": "9df4eb93ccd4a94a587375f50a225bd754d0df1d",
"date": "2024-06-14T14:28:49.000Z",
"branch": "develop"
"message": "Merge branch 'develop' into 'fb-TRIAG-600/redis-fields'",
"commit": "32748f4b980fdcad979a60e29ccd4cf0cb6b2dc7",
"date": "2024-06-14T13:56:23.000Z",
"branch": "fb-TRIAG-600/redis-fields"
}

0 comments on commit 590c8a4

Please sign in to comment.