Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]
### Fixed
- [#172] Hide New-Mode-Tour to prevent interaction with warp menu

## [v25.12.0-8] - 2026-04-02
### Fixed
Expand Down
7 changes: 7 additions & 0 deletions integrationTests/cypress/e2e/dismiss_notification.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Feature: Dismiss Notifications

@requires_testuser
Scenario: test user opens sonar first time
Given the user is logged into the CES
When the user navigates to "/projects/create" page
Then the headline "Welcome to SonarQube Community Build" should not exist
4 changes: 4 additions & 0 deletions integrationTests/cypress/support/step_definitions/then.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,4 +81,8 @@ Then(/^the user can not access the \/users\/groups Web API endpoint$/, function
cy.requestSonarAPI("/users/groups?login=" + testuserdata.username, token, false, 403)
})
})
});

Then("the headline {string} should not exist", function (name) {
cy.contains('h2', name, { timeout: 2000 }).should('not.exist');
});
54 changes: 54 additions & 0 deletions resources/startup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -582,6 +582,58 @@ DO UPDATE SET
created_at = EXCLUDED.created_at;"
}

function disableTourDialogs() {
# This marks the newModesTour as already read.
# Extend: notice_keys for further notices to dismiss
execute_sql_statement_on_database "
CREATE OR REPLACE FUNCTION set_dismissed_notices()
RETURNS trigger AS \$\$
DECLARE
notice_key TEXT;
notice_keys TEXT[] := ARRAY[
'user.dismissedNotices.showNewModesTour'
];
BEGIN
IF NEW.uuid IS NOT NULL THEN
FOREACH notice_key IN ARRAY notice_keys
LOOP
INSERT INTO properties (
uuid,
prop_key,
is_empty,
text_value,
user_uuid,
created_at
)
SELECT
gen_random_uuid(),
notice_key,
false,
'',
NEW.uuid,
(EXTRACT(EPOCH FROM NOW()) * 1000)::bigint
WHERE NOT EXISTS (
SELECT 1 FROM properties p
WHERE p.user_uuid = NEW.uuid
AND p.prop_key = notice_key
);
END LOOP;

END IF;

RETURN NEW;
END;
\$\$ LANGUAGE plpgsql;
"
execute_sql_statement_on_database "
DROP TRIGGER IF EXISTS trg_dismissed_notices ON users;
CREATE TRIGGER trg_dismissed_notices
AFTER INSERT ON users
FOR EACH ROW
EXECUTE FUNCTION set_dismissed_notices();
"
}

### End of function declarations, work is done now
runMain() {
printCloudoguLogo
Expand Down Expand Up @@ -685,6 +737,8 @@ runMain() {

remove_all_temporary_admins_users_and_groups

disableTourDialogs

doguctl state "ready"

exec tail -F /opt/sonar/logs/es.log & # this tail on the elasticsearch logs is a temporary workaround, see https://github.com/docker-library/official-images/pull/6361#issuecomment-516184762
Expand Down