-
Notifications
You must be signed in to change notification settings - Fork 2.1k
fix(validation): reject reserved FQN characters in entity and column names #27521
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
jaya6400
wants to merge
21
commits into
open-metadata:main
Choose a base branch
from
jaya6400:fix/entity-name-validation-special-chars
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
1e493d9
fix(validation): reject reserved FQN characters in entity and column …
jaya6400 7544edc
fix(validation): also block control characters in entity name pattern
jaya6400 a0b7a4a
fix(validation): extend entity name validation to cover additional sc…
jaya6400 d2e375d
fix(validation): add < and | to columnName pattern in table.json
jaya6400 69bbdb6
fix(lint): disable no-control-regex for intentional control char rang…
jaya6400 d7e09e3
fix(tests): add integration tests for entity name validation with res…
jaya6400 bf06846
fix(validation): add minLength:1 to pipeline task name and apply spot…
jaya6400 ae93a76
Add validation tests for empty pipeline task names
jaya6400 e4cb111
chore: add missing license header to PipelineResourceIT
jaya6400 4229b00
chore: fix license headers and playwright linting
jaya6400 b043532
chore: fix license header URL and format
jaya6400 77ca90c
chore: fix playwright test formatting
jaya6400 419a2fa
chore: fix missing blank line in license headers
jaya6400 7686748
chore: align license headers with project 2026 standards
jaya6400 602b7a9
fix: remove incorrect license header, fix playwright spec, revert cop…
jaya6400 e02537b
fix: correct license headers and line endings across UI files
jaya6400 51a857e
fix: fix line endings in regex constants
jaya6400 cf2f659
fix: fix line endings and formatting in PipelineValidation spec
jaya6400 cde2888
fix: replace lookahead regex with character class to fix Python/Rust …
jaya6400 4f11e09
fix: use character class regex without lookahead for Python/Rust comp…
jaya6400 eee2391
fix: re-add double colon blocking in entity name patterns
jaya6400 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
88 changes: 88 additions & 0 deletions
88
openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/PipelineValidation.spec.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,88 @@ | ||
| /* | ||
| * Copyright 2026 Collate. | ||
| * Licensed under the Apache License, Version 2.0 (the "License"); | ||
| * you may not use this file except in compliance with the License. | ||
| * You may obtain a copy of the License at | ||
| * http://www.apache.org/licenses/LICENSE-2.0 | ||
| * Unless required by applicable law or agreed to in writing, software | ||
| * distributed under the License is distributed on an "AS IS" BASIS, | ||
| * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
| * See the License for the specific language governing permissions and | ||
| * limitations under the License. | ||
| */ | ||
|
|
||
| import { expect, test, type APIRequestContext } from '@playwright/test'; | ||
| import { getDefaultAdminAPIContext, uuid } from '../../utils/common'; | ||
|
|
||
| test.use({ storageState: 'playwright/.auth/admin.json' }); | ||
|
|
||
| test.describe('Pipeline entity name validation', () => { | ||
| let apiContext: APIRequestContext; | ||
| let afterAction: () => Promise<void>; | ||
| let serviceFqn = ''; | ||
|
|
||
| test.beforeAll(async ({ browser }) => { | ||
| const response = await getDefaultAdminAPIContext(browser); | ||
| apiContext = response.apiContext; | ||
| afterAction = response.afterAction; | ||
|
|
||
| const serviceName = `pw-pipeline-validation-service-${uuid()}`; | ||
| const serviceResponse = await apiContext.post( | ||
| '/api/v1/services/pipelineServices', | ||
| { | ||
| data: { | ||
| name: serviceName, | ||
| serviceType: 'Dagster', | ||
| connection: { | ||
| config: { | ||
| type: 'Dagster', | ||
| host: 'admin', | ||
| token: 'admin', | ||
| timeout: '1000', | ||
| supportsMetadataExtraction: true, | ||
| }, | ||
| }, | ||
| }, | ||
| } | ||
| ); | ||
|
|
||
| expect(serviceResponse.status()).toBe(201); | ||
| const serviceData = await serviceResponse.json(); | ||
| serviceFqn = serviceData.fullyQualifiedName; | ||
| }); | ||
|
|
||
| test.afterAll(async () => { | ||
| if (serviceFqn) { | ||
| await apiContext.delete( | ||
| `/api/v1/services/pipelineServices/name/${encodeURIComponent( | ||
| serviceFqn | ||
| )}?recursive=true&hardDelete=true` | ||
| ); | ||
| } | ||
| await afterAction(); | ||
| }); | ||
|
|
||
| test('should reject pipeline creation when task name is empty', async () => { | ||
| const response = await apiContext.post('/api/v1/pipelines', { | ||
| data: { | ||
| name: `pw-pipeline-empty-task-${uuid()}`, | ||
| service: serviceFqn, | ||
| tasks: [{ name: '' }], | ||
| }, | ||
| }); | ||
|
|
||
| expect(response.status()).toBe(400); | ||
| }); | ||
|
|
||
| test('should reject pipeline creation when task name contains reserved FQN characters', async () => { | ||
| const response = await apiContext.post('/api/v1/pipelines', { | ||
| data: { | ||
| name: `pw-pipeline-invalid-task-${uuid()}`, | ||
| service: serviceFqn, | ||
| tasks: [{ name: 'task<invalid' }], | ||
| }, | ||
| }); | ||
|
|
||
| expect(response.status()).toBe(400); | ||
| }); | ||
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.