This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# written by https://github.com/jonathangreen & shared with his permission | |
# modest aditional contributions by https://github.com/dheles | |
import argparse | |
import os | |
import lxml.etree as ET | |
from multiprocessing import Pool | |
from datetime import datetime |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import sqlite3 | |
def main(): | |
conn = sqlite3.connect('example.db') | |
c = conn.cursor() | |
# Create table | |
c.execute('''CREATE TABLE example |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import sqlite3 | |
def main(): | |
conn = sqlite3.connect('example.db') | |
c = conn.cursor() | |
# Create table | |
c.execute('''CREATE TABLE example |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[#|2019-04-12T16:59:51.484+0000|INFO|glassfish 4.1|edu.harvard.iq.dataverse.search.IndexBatchServiceBean|_ThreadID=125;_ThreadName=__ejb-thread-pool1;_TimeMillis=1555088391484;_LevelValue=800;| | |
indexing dataset 1 of 68 (id=16)|#] | |
[#|2019-04-12T16:59:51.672+0000|WARNING|glassfish 4.1|javax.enterprise.ejb.container|_ThreadID=125;_ThreadName=__ejb-thread-pool1;_TimeMillis=1555088391672;_LevelValue=900;_MessageID=AS-EJB-00056;| | |
A system exception occurred during an invocation on EJB DataverseServiceBean, method: public edu.harvard.iq.dataverse.Dataverse edu.harvard.iq.dataverse.DataverseServiceBean.findRootDataverse()|#] | |
[#|2019-04-12T16:59:51.672+0000|WARNING|glassfish 4.1|javax.enterprise.ejb.container|_ThreadID=125;_ThreadName=__ejb-thread-pool1;_TimeMillis=1555088391672;_LevelValue=900;| | |
javax.ejb.TransactionRolledbackLocalException: Exception thrown from bean | |
at com.sun.ejb.containers.EJBContainerTransactionManager.checkExceptionClientTx(EJBContainerTransactionManager.java:662) | |
at com.sun.ejb.conta |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#---------------------------------------------------------------# | |
#----------------SWORD 2.0 SERVER CONFIGURATIONS----------------# | |
#---------------------------------------------------------------# | |
# These configs are only used by the SWORD Server interface, # | |
# version 2.0 (used by DSpace to accept ingest packages via # | |
# SWORD 2.0 protocol) # | |
#---------------------------------------------------------------# | |
# the base url of the sword 2.0 system | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# EXAMPLE "local.cfg" for DSpace. | |
# | |
# Any configurations added to this file will automatically OVERRIDE configurations | |
# of the same name in any of the DSpace *.cfg files. This includes overriding | |
# settings in any of these files: | |
# * [dspace]/config/dspace.cfg | |
# * Or any configuration file that is included in 'dspace.cfg' | |
# (See "include = [filepath]" settings near the end of dspace.cfg. | |
# By default, it includes all [dspace]/config/modules/*.cfg files) | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ python client.py | |
https://jscholarship.library.jhu.edu/swordv2/collection/1774.2/58586 | |
atom_generator: '['admin@dspace-prod.mse.jhu.edu version:"2.0" uri:"http://www.dspace.org/ns/sword/2.0/"']' | |
atom_id: '['https://jscholarship.library.jhu.edu/swordv2/edit/dbbde8a5-179f-4e94-bd4f-c852682e357d']' | |
atom_rights: '[None]' | |
atom_title: '['Untitled: example.zip']' | |
atom_updated: '['2018-07-02T04:00:00.000Z']' | |
dcterms_available: '['2018-07-02T16:48:49Z']' | |
dcterms_description: '['Zip file deposted by SWORD without accompanying metadata']' | |
dcterms_provenance: '['Made available in DSpace on 2018-07-02T16:48:49Z (GMT). No. of bitstreams: 2\nexample.zip: 33777 bytes, checksum: 2b25f82ba67284461d4a481d7a06dd28 (MD5)\nexample.zip: 33777 bytes, checksum: 2b25f82ba67284461d4a481d7a06dd28 (MD5)']' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def test_session | |
session = "test-session" | |
default_label = "test-default-login" | |
session_label = "test-session-login" | |
username = "user" | |
password = "pass" | |
default_output = "#{default_label}:#{username}:#{password}" | |
session_output = "#{session_label}:#{username}:#{password}" | |
error_pattern_no_record = /No such record\(s\)/ | |
error_pattern_no_session = /Unknown session/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ gem build hyrax.gemspec | |
WARNING: license value 'Apache2' is invalid. Use a license identifier from | |
http://spdx.org/licenses or 'Nonstandard' for a nonstandard license. | |
Did you mean 'Apache-2.0', 'mpich2'? | |
WARNING: open-ended dependency on hydra-head (>= 10.4.0) is not recommended | |
if hydra-head is semantically versioned, use: | |
add_runtime_dependency 'hydra-head', '~> 10.4', '>= 10.4.0' | |
WARNING: open-ended dependency on browse-everything (>= 0.10.5) is not recommended | |
if browse-everything is semantically versioned, use: | |
add_runtime_dependency 'browse-everything', '~> 0.10', '>= 0.10.5' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ RAILS_ENV=development bundle exec rake packager:aip["import/CompSci_current.zip","dheles@jhu.edu"] | |
loading task import | |
Building Import Package from AIP Export file: import/CompSci_current.zip | |
***** COLLECTION [Current Technical Reports] ***** | |
******* ITEM [http://jhir.library.jhu.edu/handle/1774.2/33295] ******* | |
bitstream_430525.pdf -> ChaudhryTR09.pdf | |
-------- UpLoaded Files ---------- | |
#<Hyrax::UploadedFile:0x00000005e9c3c0> | |
---------------------------------- | |
** Creating Item... |
NewerOlder