A simple Python script to evaluate your ArchivesSpace instance for DACS compliance.
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.gitignore
LICENSE
README.md
setup.py
single_level.py

README.md

DACSspace

A simple Python script to evaluate your ArchivesSpace instance for DACS single-level minimum required elements.

DACSspace utilizes the ArchivesSpace API to check resources for DACS compliance and produces a csv containing a list of evaluated resources. If a DACS field is present its content will be written to the csv, if a field is missing the csv will read "FALSE" for that item.

Requirements

  • Python (written for and tested on 2.7).
  • ConfigParser
  • Requests module

Installation

Download Python

If you are using Windows, add Python to your PATH variable

Install requirements (ConfigParser instructions / Requests instructions)

Setup

Run setup.py to create a configuration file named local_settings.cfg which will allow you to connect to your ArchivesSpace instance. You will need:

  • BaseURL of your ArchivesSpace instance
  • Repository ID for your ArchivesSpace installation
  • ArchivesSpace username and password

Your configuration file will look something like this:

[ArchivesSpace]
baseURL: #BaseURL of your ArchivesSpace instance
repository: #Repository ID of your ArchivesSpace installation
user: #ArchivesSpace username
password: #ArchivesSpace password for the username used above

[Destinations]
directory: #Directory where you would like to save the csv file
filename: dacs_singlelevel_report.csv

Usage

Using the command line navigate to the directory containing the DACSspace repository and run single-level.py to execute the script.

DACSspace will prompt you to answer two questions allowing you to limit which resources you'd like the script to evaluate:

Welcome to DACSspace!
I'll ask you a series of questions to refine how to script works.
If you want to use the default value for a question press the ENTER key.

Do you want DACSspace to include unpublished resources? y/n (default is n):
Do you want to further limit the script by a specific resource id? If so, enter a string that must be present in the resource id (enter to skip):

Pressing the ENTER key for both questions will use the default version of the script which will get ALL resources.

The script will create a list of evaluated resources in a csv file (default is dacs_singlelevel_report.csv).

A sample csv file will look like this:

title publish resource extent date language repository creator scope restrictions
#resource title TRUE #resourceId 20.8 inclusive eng #NameofRepository FALSE #scopenote #accessrestriction
#resource title TRUE #resourceId 50.6 single FALSE #NameofRepository #creator FALSE FALSE

If you are using Microsoft Excel to view the csv file, consult the following links to avoid encoding issues: Excel 2007, Excel 2013.

Contributing

Pull requests accepted!

Authors

Hillel Arnold and Amy Berish

License

This code is released under the MIT license. See LICENSE for further details.