folio_data_import 0.6.1__tar.gz → 0.6.2__tar.gz
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.
- {folio_data_import-0.6.1 → folio_data_import-0.6.2}/PKG-INFO +1 -1
- {folio_data_import-0.6.1 → folio_data_import-0.6.2}/pyproject.toml +1 -1
- {folio_data_import-0.6.1 → folio_data_import-0.6.2}/src/folio_data_import/UserImport.py +11 -1
- {folio_data_import-0.6.1 → folio_data_import-0.6.2}/README.md +0 -0
- {folio_data_import-0.6.1 → folio_data_import-0.6.2}/src/folio_data_import/BatchPoster.py +0 -0
- {folio_data_import-0.6.1 → folio_data_import-0.6.2}/src/folio_data_import/DILogRetriever.py +0 -0
- {folio_data_import-0.6.1 → folio_data_import-0.6.2}/src/folio_data_import/MARCDataImport.py +0 -0
- {folio_data_import-0.6.1 → folio_data_import-0.6.2}/src/folio_data_import/__init__.py +0 -0
- {folio_data_import-0.6.1 → folio_data_import-0.6.2}/src/folio_data_import/__main__.py +0 -0
- {folio_data_import-0.6.1 → folio_data_import-0.6.2}/src/folio_data_import/_postgres.py +0 -0
- {folio_data_import-0.6.1 → folio_data_import-0.6.2}/src/folio_data_import/_progress.py +0 -0
- {folio_data_import-0.6.1 → folio_data_import-0.6.2}/src/folio_data_import/custom_exceptions.py +0 -0
- {folio_data_import-0.6.1 → folio_data_import-0.6.2}/src/folio_data_import/marc_preprocessors/__init__.py +0 -0
- {folio_data_import-0.6.1 → folio_data_import-0.6.2}/src/folio_data_import/marc_preprocessors/_preprocessors.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: folio_data_import
|
|
3
|
-
Version: 0.6.
|
|
3
|
+
Version: 0.6.2
|
|
4
4
|
Summary: A python module to perform bulk import of data into a FOLIO environment. Currently supports MARC and user data import.
|
|
5
5
|
Author: Brooks Travis
|
|
6
6
|
Author-email: Brooks Travis <brooks.travis@gmail.com>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "folio_data_import"
|
|
3
|
-
version = "0.6.
|
|
3
|
+
version = "0.6.2"
|
|
4
4
|
description = "A python module to perform bulk import of data into a FOLIO environment. Currently supports MARC and user data import."
|
|
5
5
|
authors = [{ name = "Brooks Travis", email = "brooks.travis@gmail.com" }]
|
|
6
6
|
license = "MIT"
|
|
@@ -152,6 +152,15 @@ class UserImporter: # noqa: R0902
|
|
|
152
152
|
description="Whether to delete existing users, rather than create/update.",
|
|
153
153
|
),
|
|
154
154
|
] = False
|
|
155
|
+
delete_pus: Annotated[
|
|
156
|
+
bool,
|
|
157
|
+
Field(
|
|
158
|
+
title="Delete permission user objects when deleting users",
|
|
159
|
+
description=(
|
|
160
|
+
"Whether to delete associated permission user objects when deleting users."
|
|
161
|
+
),
|
|
162
|
+
),
|
|
163
|
+
] = False
|
|
155
164
|
|
|
156
165
|
logfile: AsyncTextIOWrapper
|
|
157
166
|
errorfile: AsyncTextIOWrapper
|
|
@@ -174,6 +183,7 @@ class UserImporter: # noqa: R0902
|
|
|
174
183
|
)
|
|
175
184
|
else:
|
|
176
185
|
self.reporter = reporter
|
|
186
|
+
self.delete_pus = config.delete_pus
|
|
177
187
|
self.limit_simultaneous_requests = asyncio.Semaphore(config.limit_simultaneous_requests)
|
|
178
188
|
# Build reference data maps (these need processing)
|
|
179
189
|
self.patron_group_map: dict = self.build_ref_data_id_map(
|
|
@@ -827,7 +837,7 @@ class UserImporter: # noqa: R0902
|
|
|
827
837
|
f"{str(getattr(getattr(ee, 'response', str(ee)), 'text', str(ee)))}\n"
|
|
828
838
|
)
|
|
829
839
|
try:
|
|
830
|
-
if existing_pu:
|
|
840
|
+
if existing_pu and self.delete_pus:
|
|
831
841
|
await self.folio_client.folio_delete_async(
|
|
832
842
|
f"/perms/users/{existing_pu.get('id', '')}"
|
|
833
843
|
)
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{folio_data_import-0.6.1 → folio_data_import-0.6.2}/src/folio_data_import/custom_exceptions.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|