Skip to content

Commit

Permalink
Merge pull request #352 from CDLUC3/develop
Browse files Browse the repository at this point in the history
EZID 3.0.10rc2
  • Loading branch information
rushirajnenuji authored Oct 27, 2022
2 parents a102f21 + 91fd10e commit 6a2868e
Show file tree
Hide file tree
Showing 8 changed files with 15 additions and 10 deletions.
10 changes: 7 additions & 3 deletions impl/nog/shoulder.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,13 +116,17 @@ def create_shoulder(
log.debug('Minter BerkeleyDB created at: {}'.format(bdb_path.as_posix()))
# Add new shoulder row to the shoulder table.
try:
minterVal = "ezid:/{}".format(
'/'.join(bdb_path.parts[-3:-1]),
)
if (is_super_shoulder):
minterVal = ''

ezidapp.models.shoulder.Shoulder.objects.create(
prefix=ns,
type=ns.scheme.upper(),
name=organization_name_str,
minter="ezid:/{}".format(
'/'.join(bdb_path.parts[-3:-1]),
),
minter=minterVal,
datacenter=datacenter_model,
crossrefEnabled=is_crossref,
isTest=is_test,
Expand Down
1 change: 1 addition & 0 deletions impl/ui_demo.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ def simple(request):
# noinspection PyDictCreation
def advanced(request):
d = {'menu_item': 'ui_home.learn'}
d["testPrefixes"] = django.conf.settings.TEST_SHOULDER_DICT
d['prefixes'] = sorted(
django.conf.settings.TEST_SHOULDER_DICT, key=lambda p: p['namespace'].lower()
) # must be done before calling form processing
Expand Down
2 changes: 1 addition & 1 deletion settings/settings.py.j2
Original file line number Diff line number Diff line change
Expand Up @@ -512,7 +512,7 @@ LINKCHECKER_USER_AGENT = 'EZID (EZID link checker; https://ezid.cdlib.org/)'
# link. Set to a negative value to make unlimited.
LINKCHECKER_MAX_READ = 104_857_600
# EZID Link checker e-mails
LINK_CHECKER_ADMIN = '{{ link_checker_admin }}'
LINK_CHECKER_ADMIN = {{ link_checker_admin }}

# Internal settings

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ at [MEMORY-ADDRESS]>,
'isTest': True,
'isUuid': False,
'manager': 'ezid',
'minter': 'ezid:/91101/r01',
'minter': '',
'name': '91101/r01 test org',
'prefix': 'ark:/91101/r01/',
'prefix_shares_datacenter': False,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ at [MEMORY-ADDRESS]>,
'isTest': True,
'isUuid': False,
'manager': 'ezid',
'minter': 'ezid:/b9111/r01',
'minter': '',
'name': '91101/r01 test org',
'prefix': 'doi:10.9111/R01/',
'prefix_shares_datacenter': True,
Expand Down
6 changes: 2 additions & 4 deletions tests/test_shoulder_create_ark.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,11 +90,9 @@ def test_1030(self, caplog, tmp_bdb_root):
'--skip-checks',
'--test',
)
ezid_uri = "ezid:/99920/NULL"
ezid_uri = ''
assert ezidapp.models.shoulder.Shoulder.objects.filter(prefix=ns_str).exists()
s = ezidapp.models.shoulder.Shoulder.objects.filter(minter=ezid_uri).get()
sample.assert_match(tests.util.util.shoulder_to_dict(s), 'NULL')
assert s.minter == ezid_uri
s = ezidapp.models.shoulder.Shoulder.objects.filter(prefix=ns_str).get()
assert s.name == org_str
assert s.active
assert s.isSupershoulder
Expand Down
1 change: 1 addition & 0 deletions tools/link_check_emailer.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#! /usr/bin/env python
# -*- coding: utf-8 -*-

# Copyright©2021, Regents of the University of California
# http://creativecommons.org/licenses/BSD
Expand Down
1 change: 1 addition & 0 deletions tools/link_check_summary_report.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#! /usr/bin/env python
# -*- coding: utf-8 -*-

# Copyright©2021, Regents of the University of California
# http://creativecommons.org/licenses/BSD
Expand Down

0 comments on commit 6a2868e

Please sign in to comment.