Skip to content

Commit 17c609b

Browse files
committed
vNext: Add migration step for publication-dissertation
1 parent b658755 commit 17c609b

1 file changed

Lines changed: 36 additions & 1 deletion

File tree

docs/releases/v14/upgrade-v14.0.md

Lines changed: 36 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,42 @@ invenio shell $(find $(dirname $(dirname $(uv python find)))/lib/*/site-packages
214214
# if using pipenv
215215
invenio shell $(find $(pipenv --venv)/lib/*/site-packages/invenio_app_rdm -name migrate_13_to_14.py)
216216
```
217-
TODO: create migrate_13_to_14.py script
217+
218+
#### Change resource type `publication-thesis` to `publication-dissertation`
219+
220+
!!! info "**Does this migration step apply to me?**"
221+
- **Yes**: You are using `publication-thesis` as a resource type (e.g., because you are using the default resource types) AND you want to use `publication-dissertation` instead.
222+
- **No**: You are not using `publication-thesis` as a resource type.
223+
224+
*Steps to follow if you want to migrate to `publication-dissertation`:*
225+
226+
1. If you are using a customized list of resource types in `<my_instance>/app_data/vocabularies/resource_types.yaml`, then:
227+
- set `title.<lang>` to "Thesis" (in appropriate language) for entry with `id` equal to `publication-dissertation`
228+
- remove the entry with `id` equal to `publication-thesis`
229+
230+
If you didn't customize resource types, you can skip this step.
231+
232+
2. Apply the resource types title change.
233+
- `invenio rdm-records add-to-fixture resourcetypes`
234+
- Note that this will change the title, but will not delete the `publication-thesis` from your data stores. Deletion is done in step 4.
235+
236+
3. Run the publication dissertation migration script:
237+
238+
```shell
239+
# if using uv
240+
invenio shell $(find $(dirname $(dirname $(uv python find)))/lib/*/site-packages/invenio_app_rdm -name migrate_13_0_to_14.py) --migrate-theses
241+
# if using pipenv
242+
invenio shell $(find $(pipenv --venv)/lib/*/site-packages/invenio_app_rdm -name migrate_13_0_to_14.py) --migrate-theses
243+
```
244+
245+
4. Delete `publication-thesis` vocabulary via invenio shell:
246+
247+
```python
248+
from invenio_vocabularies.proxies import current_service as vocabulary_service
249+
vocabulary_service.delete(system_identity, ('resourcetypes', 'publication-thesis'))
250+
```
251+
252+
218253

219254
#### OAuth client changes
220255

0 commit comments

Comments
 (0)