Skip to content

Commit c752ea3

Browse files
committed
Merge branch 'develop' into fix/847-dataset-metadata-field-validations
2 parents f213b76 + a3f4b8b commit c752ea3

File tree

31 files changed

+223
-103
lines changed

31 files changed

+223
-103
lines changed

CHANGELOG.md

Lines changed: 39 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -8,24 +8,54 @@ This changelog follows the principles of [Keep a Changelog](https://keepachangel
88

99
### Added
1010

11-
- Dataset Templates Selector in the Create Dataset page.
11+
### Changed
12+
13+
- Use of the new `sourceLastUpdateTime` query parameter from update dataset and file metadata endpoints to support optimistic concurrency control during editing operations. See [Edit Dataset Metadata](https://guides.dataverse.org/en/6.8/api/native-api.html#edit-dataset-metadata) and [Updating File Metadata](https://guides.dataverse.org/en/6.8/api/native-api.html#updating-file-metadata) guides for more details.
14+
15+
### Fixed
16+
17+
- Show toast notification when API token is copied to clipboard.
18+
19+
### Removed
20+
21+
---
22+
23+
## [v0.2.0] -- 2025-10-03
24+
25+
### Added
26+
27+
- Dataset Templates integration in the Create Dataset form. (#745)
28+
- Advanced Search UI replicating legacy JSF, with persistence of queries and facet filters. (#760, dataverse#9993)
29+
- External Search integration with selectable search service and first-load fetch behavior. (#710)
30+
- File Edit Tags with populated categories dropdown. (#763)
31+
- DEMO environment option in deploy actions.
1232
- Metadata Export Dropdown to the metadata tab of Dataset Page and File Page.
1333
- External Tools integration. All types supported: Explore, Configure, Preview and Query tools in Dataset and File pages. Still not showing external tools for Auxiliary Files as additional development is needed.
14-
- Added the value entered by the user in the error messages for metadata field validation errors in EMAIL and URL type fields. For example, instead of showing "Point of Contact E-mail is not a valid email address.", we now show "Point of Contact E-mail foo is not a valid email address."
34+
- Dataset page: citation downloads available in multiple formats with copy-to-clipboard. (#786)
1535

1636
### Changed
1737

18-
- Standardize Node.js version to 22 across all environments (docker dev environment, CI, production).
19-
- Changed the way we were handling DATE type metadata field validation to better match the backend validation and give users better error messages. For example, for an input like "foo AD", we now show "Production Date is not a valid date. The AD year must be numeric.". For an input like "99999 AD", we now show "Production Date is not a valid date. The AD year cant be higher than 9999.". For an input like "[-9999?], we now show "Production Date is not a valid date. The year in brackets cannot be negative.", etc.
38+
- Standardized Node.js to v22 across environments (docker dev, CI, production).
39+
- Upgrade Keycloak to 26.3.2; updated SPI and test realm JSON.
40+
- Truncate long collection and dataset descriptions with expandable content. (#789)
41+
- UI polish: Files Table always shows action buttons. (#800)
2042

2143
### Fixed
2244

23-
- Upgrade dependencies to drastically reduce vulnerabilities flagged by `npm audit`. Reduced from +100 including 12 critical and 33 high to only 2 moderate.
45+
- Guest user access: file info retrieval works on deaccessioned datasets. (#752)
46+
- Collection filter queries with values containing ":" now parsed correctly. (#812)
47+
- File upload: corrected "drop one file to replace" warning behavior. (#810)
48+
- Create Collection form: prevent numeric-only aliases. (#798)
49+
- Improved URL handling and wrapping across the UI. (#774)
2450

25-
### Removed
51+
### Documentation
2652

27-
---
53+
- Introduced CHANGELOG and updated related documents. (#828)
54+
- Added Environments section to README.
55+
- Expanded Keycloak deployment documentation with realm setup and SPI guidance.
2856

29-
## [v0.1.0] -- 2025-08-13
57+
### Security
3058

31-
[Unreleased]: https://github.com/IQSS/dataverse-frontend/compare/v0.1.0...develop
59+
- Fixed dependencies vulnerabilities: reduced npm audit issues from 100+ (including 12 critical and 33 high) to only 2 moderate.
60+
61+
## [v0.1.0] -- 2025-08-13

docs/making-releases.md

Lines changed: 11 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@
77
- [Use the Latest Dataverse Client Javascript Version](#use-the-latest-dataverse-client-javascript-version)
88
- [Merge "release branch" into "main"](#merge-release-branch-into-main)
99
- [Create a Draft Release on GitHub and Tag the Version](#create-a-draft-release-on-github-and-tag-the-version)
10-
- [Merge "release branch" into "develop"](#merge-release-branch-into-develop)
11-
- [Delete "release branch"](#delete-release-branch)
10+
- [Sync "develop" branch with changes from "main"](#sync-develop-branch-with-changes-from-main)
11+
- [Delete "release branch" and "sync develop" branch](#delete-release-branch-and-sync-develop-branch)
1212

1313
## Introduction
1414

@@ -83,8 +83,7 @@ Before releasing, ensure the changelog is properly prepared:
8383
### Removed
8484
```
8585

86-
4. **Update the version links** at the bottom of the changelog files
87-
5. **Commit the changelog updates** as part of the release preparation
86+
4. **Commit the changelog updates** as part of the release preparation
8887

8988
## Use the Latest Dataverse Client Javascript Version
9089

@@ -128,21 +127,18 @@ Go to https://github.com/IQSS/dataverse-frontend/releases/new to start creating
128127

129128
At this point you can send around the draft release for any final feedback. Make corrections to the draft, if necessary. Publish once everything is ok.
130129

131-
## Merge "release branch" into "develop"
130+
## Sync develop branch with changes from main
132131

133132
After merging the release branch into `main`, ensure the develop branch is updated with the latest changes.
134133

135-
```shell
136-
git checkout develop
137-
git merge release/X.X.X
138-
git push origin develop
139-
```
134+
Create a pull request to sync the `develop` branch with the `main` branch. Create the branch from `main` and name it `sync-develop-v[version-number]`.
140135

141-
## Delete "release branch"
136+
This is a good time to revert or adjust any release-specific changes that are **not needed in `develop`**, such as:
142137

143-
Once the release process is complete and the `release` branch has been merged into both `main` and `develop`, you can safely delete the `release` branch to keep the repository clean.
138+
- Using the npm version of the latest `@iqss/dataverse-client-javascript` package — check what alpha version is used in `develop` and revert to that version.
139+
- Updating the `E2E_DATAVERSE_IMAGE_TAG` in `workflows/test.yml` — revert it to the value used in `develop` (usually `unstable`).
140+
- Any other release-only changes or configuration updates that should not persist in `develop`.
144141

145-
- Delete the branch locally from your repository.
146-
- Delete the branch remotely from the remote repository.
142+
## Delete "release branch" and "sync-develop" branch.
147143

148-
This ensures that the `release` branch is no longer present in either your local or remote repositories.
144+
Once the release process is complete and the changes have been merged into both `main` and `develop`, you can delete the `release` branch and the `sync-develop` branch to keep the repository clean.

package-lock.json

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
22
"engines": {
3-
"npm": ">=10",
4-
"node": ">=22 <23"
3+
"npm": ">=10",
4+
"node": ">=22 <23"
55
},
66
"name": "dataverse-frontend",
7-
"version": "0.1.0",
7+
"version": "0.2.0",
88
"type": "module",
99
"private": true,
1010
"workspaces": {
@@ -18,7 +18,7 @@
1818
"@dnd-kit/sortable": "8.0.0",
1919
"@dnd-kit/utilities": "3.2.2",
2020
"@faker-js/faker": "7.6.0",
21-
"@iqss/dataverse-client-javascript": "2.1.0-pr385.bb9affc",
21+
"@iqss/dataverse-client-javascript": "2.0.0-alpha.76",
2222
"@iqss/dataverse-design-system": "*",
2323
"@istanbuljs/nyc-config-typescript": "1.0.2",
2424
"@tanstack/react-table": "8.9.2",
@@ -181,7 +181,6 @@
181181
"workerDirectory": "public"
182182
},
183183
"readme": "ERROR: No README data found!",
184-
"_id": "dataverse-frontend@0.1.0",
185184
"overrides": {
186185
"@parcel/watcher": "2.1.0",
187186
"form-data": "^4.0.0",

public/locales/en/account.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@
1313
"copyToClipboard": "Copy to Clipboard",
1414
"recreateToken": "Recreate Token",
1515
"revokeToken": "Revoke Token",
16-
"createToken": "Create Token"
16+
"createToken": "Create Token",
17+
"copiedToClipboard": "API token copied to clipboard."
1718
},
1819
"info": {
1920
"username": "Username",

src/dataset/domain/models/Dataset.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -252,6 +252,12 @@ export class DatasetVersion {
252252
public readonly isInReview: boolean,
253253
public readonly latestVersionPublishingStatus: DatasetPublishingStatus,
254254
public readonly someDatasetVersionHasBeenReleased: boolean,
255+
/**
256+
* The timestamp of the last update to this dataset version.
257+
* Format: ISO 8601 string (e.g., "2023-06-01T12:34:56Z").
258+
* Used for optimistic concurrency control to detect concurrent updates.
259+
*/
260+
public readonly lastUpdateTime: string,
255261
public readonly termsOfAccess?: TermsOfAccess,
256262
public readonly deaccessionNote?: string
257263
) {}
@@ -268,6 +274,7 @@ export class DatasetVersion {
268274
public readonly isInReview: boolean,
269275
public readonly latestVersionPublishingStatus: DatasetPublishingStatus,
270276
public readonly someDatasetVersionHasBeenReleased: boolean,
277+
public readonly lastUpdateTime: string,
271278
public readonly termsOfAccess?: TermsOfAccess,
272279
public readonly deaccessionNote?: string
273280
) {
@@ -336,6 +343,7 @@ export class DatasetVersion {
336343
this.isInReview,
337344
this.latestVersionPublishingStatus,
338345
this.someDatasetVersionHasBeenReleased,
346+
this.lastUpdateTime,
339347
this.termsOfAccess,
340348
this.deaccessionNote
341349
)

src/dataset/domain/repositories/DatasetRepository.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ export interface DatasetRepository {
3030
updateMetadata: (
3131
datasetId: string | number,
3232
datasetDTO: DatasetDTO,
33-
internalVersionNumber: number
33+
sourceLastUpdateTime?: string
3434
) => Promise<void>
3535
deaccession: (
3636
datasetId: string | number,

src/dataset/domain/useCases/updateDatasetMetadata.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ export function updateDatasetMetadata(
55
datasetRepository: DatasetRepository,
66
datasetId: string | number,
77
updatedDataset: DatasetDTO,
8-
internalVersionNumber: number
8+
sourceLastUpdateTime?: string
99
): Promise<void> {
1010
return datasetRepository
11-
.updateMetadata(datasetId, updatedDataset, internalVersionNumber)
11+
.updateMetadata(datasetId, updatedDataset, sourceLastUpdateTime)
1212
.catch((error: Error) => {
1313
throw new Error(error.message)
1414
})

src/dataset/infrastructure/mappers/JSDatasetMapper.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ export class JSDatasetMapper {
5656
jsDataset.versionInfo,
5757
JSDatasetMapper.toDatasetTitle(jsDataset.metadataBlocks),
5858
jsDatasetCitation,
59+
jsDataset.versionInfo.lastUpdateTime,
5960
jsDataset.publicationDate,
6061
jsDataset.termsOfUse?.termsOfAccess,
6162
jsDataset.versionInfo.deaccessionNote as string

src/dataset/infrastructure/mappers/JSDatasetPreviewMapper.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ export class JSDatasetPreviewMapper {
1212
jsDatasetPreview.versionId,
1313
jsDatasetPreview.versionInfo,
1414
jsDatasetPreview.title,
15-
jsDatasetPreview.citation
15+
jsDatasetPreview.citation,
16+
jsDatasetPreview.versionInfo.lastUpdateTime
1617
),
1718
releaseOrCreateDate: JSDatasetPreviewMapper.toPreviewDate(jsDatasetPreview.versionInfo),
1819
description: jsDatasetPreview.description,

0 commit comments

Comments
 (0)