oarepo-runtime 1.7.0__py3-none-any.whl → 1.7.1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,10 @@
1
- from invenio_pidstore.errors import PIDUnregistered
1
+ from invenio_pidstore.errors import PIDUnregistered, PIDDoesNotExistError
2
2
  from invenio_records_resources.references.entity_resolvers.records import (
3
3
  RecordProxy as InvenioRecordProxy,
4
4
  )
5
5
  from sqlalchemy.exc import NoResultFound
6
+ from invenio_access.permissions import system_identity
7
+ from invenio_records_resources.references.entity_resolvers.results import ServiceResultProxy as InvenioServiceResultProxy
6
8
 
7
9
 
8
10
  def set_field(result, resolved_dict, field_name):
@@ -35,6 +37,15 @@ class RecordProxy(InvenioRecordProxy):
35
37
  },
36
38
  }
37
39
 
40
+ class WithDeletedServiceResultProxy(InvenioServiceResultProxy):
41
+ """Resolver proxy for a result item entity."""
42
+
43
+ def _resolve(self):
44
+ """Resolve the result item from the proxy's reference dict."""
45
+ id_ = self._parse_ref_dict_id()
46
+ # TODO: Make identity customizable
47
+ return self.service.read(system_identity, id_, include_deleted=True).to_dict()
48
+
38
49
 
39
50
  class DraftProxy(RecordProxy):
40
51
  def _resolve(self):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: oarepo-runtime
3
- Version: 1.7.0
3
+ Version: 1.7.1
4
4
  Summary: A set of runtime extensions of Invenio repository
5
5
  Description-Content-Type: text/markdown
6
6
  License-File: LICENSE
@@ -60,7 +60,7 @@ oarepo_runtime/records/dumpers/__init__.py,sha256=OmzNhLdMNKibmCksnj9eTX9xPBG30d
60
60
  oarepo_runtime/records/dumpers/edtf_interval.py,sha256=8bE3JlaR7b33rxDc7LW9R8jcwNI66Zb07Jee6YUmlrE,1231
61
61
  oarepo_runtime/records/dumpers/multilingual_dumper.py,sha256=PbNFCLsiH4XV3E1v8xga_fzlcEImHy8OXn_UKh_8VBU,1090
62
62
  oarepo_runtime/records/entity_resolvers/__init__.py,sha256=UiiIT54pUu9j7qPAPfqVp4UTnXnppp0c_LtKbFnyt6Y,383
63
- oarepo_runtime/records/entity_resolvers/proxies.py,sha256=R92Cil_sTgX-sHJtdNv82yd-F3SUfsGSNCHdwI9Zfq8,1516
63
+ oarepo_runtime/records/entity_resolvers/proxies.py,sha256=P9c8JeHc25i_v8uXxTMHNlMNTFskET6dTM0VVMfLfyk,2097
64
64
  oarepo_runtime/records/mappings/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
65
65
  oarepo_runtime/records/mappings/rdm_parent_mapping.json,sha256=ykgVr-navpy-HlhUN78sZ1ZpcAaduzZ0ESpphLK4b5E,14233
66
66
  oarepo_runtime/records/owners/__init__.py,sha256=R4hudCBqLRRzgCnkEjXIL7hSp068z-s6YOwYSkWyuaw,93
@@ -149,13 +149,13 @@ oarepo_runtime/translations/en/LC_MESSAGES/messages.po,sha256=7-5S3iINOSFSI5gVdR
149
149
  oarepo_runtime/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
150
150
  oarepo_runtime/utils/functools.py,sha256=gKS9YZtlIYcDvdNA9cmYO00yjiXBYV1jg8VpcRUyQyg,1324
151
151
  oarepo_runtime/utils/path.py,sha256=V1NVyk3m12_YLbj7QHYvUpE1wScO78bYsX1LOLeXDkI,3108
152
- oarepo_runtime-1.7.0.dist-info/licenses/LICENSE,sha256=h2uWz0OaB3EN-J1ImdGJZzc7yvfQjvHVYdUhQ-H7ypY,1064
152
+ oarepo_runtime-1.7.1.dist-info/licenses/LICENSE,sha256=h2uWz0OaB3EN-J1ImdGJZzc7yvfQjvHVYdUhQ-H7ypY,1064
153
153
  tests/marshmallow_to_json/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
154
154
  tests/marshmallow_to_json/test_datacite_ui_schema.py,sha256=82iLj8nW45lZOUewpWbLX3mpSkpa9lxo-vK-Qtv_1bU,48552
155
155
  tests/marshmallow_to_json/test_simple_schema.py,sha256=izZN9p0v6kovtSZ6AdxBYmK_c6ZOti2_z_wPT_zXIr0,1500
156
156
  tests/pkg_data/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
157
- oarepo_runtime-1.7.0.dist-info/METADATA,sha256=NUTpowtktIjmv9Wws8RahuI0nXprG3FGS_O7IKOjI80,4788
158
- oarepo_runtime-1.7.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
159
- oarepo_runtime-1.7.0.dist-info/entry_points.txt,sha256=k7O5LZUOGsVeSpB7ulU0txBUNp1CVQG7Q7TJIVTPbzU,491
160
- oarepo_runtime-1.7.0.dist-info/top_level.txt,sha256=bHhlkT1_RQC4IkfTQCqA3iN4KCB6cSFQlsXpQMSP-bE,21
161
- oarepo_runtime-1.7.0.dist-info/RECORD,,
157
+ oarepo_runtime-1.7.1.dist-info/METADATA,sha256=rvL7MLlWJ21OM6vVVDks-Ga6iqUJiqmqEZirtr1OfbA,4788
158
+ oarepo_runtime-1.7.1.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
159
+ oarepo_runtime-1.7.1.dist-info/entry_points.txt,sha256=k7O5LZUOGsVeSpB7ulU0txBUNp1CVQG7Q7TJIVTPbzU,491
160
+ oarepo_runtime-1.7.1.dist-info/top_level.txt,sha256=bHhlkT1_RQC4IkfTQCqA3iN4KCB6cSFQlsXpQMSP-bE,21
161
+ oarepo_runtime-1.7.1.dist-info/RECORD,,