Giter VIP home page Giter VIP logo

hydra-head's People

Contributors

afred avatar atz avatar awead avatar barmintor avatar botimer avatar capncodewash avatar carolyncole avatar cbeer avatar cjcolvar avatar dchandekstark avatar dlpierce avatar escowles avatar flyingzumwalt avatar grosscol avatar hackartisan avatar hectorcorrea avatar hortongn avatar jcoyne avatar jenlindner avatar jeremyf avatar jkeck avatar joegilbert avatar jrgriffiniii avatar mbklein avatar mcritchlow avatar mjgiarlo avatar ndushay avatar rickjohnson avatar tpendragon avatar val99erie avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

hydra-head's Issues

:type option missing in DownloadBehavior

ArgumentError (:type option required):
actionpack (4.0.0) lib/action_controller/metal/data_streaming.rb:137:in send_file_headers!' hydra-core (6.4.0) app/controllers/concerns/hydra/controller/download_behavior.rb:75:insend_content'
hydra-core (6.4.0) app/controllers/concerns/hydra/controller/download_behavior.rb:15:in `show'

Permissions counting problems

I was doing de Hydra Head tutorial and found something strange. At the lesson: "Set Permissions on an Object", I was setting more then 5 permissions to a book, but when I tried to see those permissions, it only showed 4.

I created a model rspec called "book.rb" to show that problem.

describe 'Book' do

let (:book) { Book.new }

it "should have 5 permissions" do
  book.permissions = [{:type => "group", :access => "discover", :name => "group1"},     {:type => "group", :access => "edit", :name => "group2"},                       {:type => "group", :access => "edit", :name => "group3"},                               {:type => "person", :access => "edit", :name => "user1"},                                   {:type => "person", :access => "read", :name => "user2"}]
  book.permissions.size.should < 5
end

end

id generation bug in HydraHead.add_keywords javascript in master

In the current js, the added input tag's id is generated with a suffix calculated like so:

var keyword_count = $(this).parent().siblings('.fedora-text-field').length;

If there was more than one keyword value to begin with, those values will all be under a single p.fedora-text-field tag, but the above code will always give the new value an id of 'subject_topic_1'. Unless the text field scaffolding is reworked to place each input in its own p.fedora-text-field, the counting needs to be more along the lines of:

  var keyword_count = 0;
  var counts = $(this).parent().siblings('.fedora-text-field').map(
     function(){
       if ($(this).children('input[type="text"]')) {
       return $(this).children('input[type="text"]').length;
       } else return 0;
     });
  for (var i = 0; i < counts.length; i++) { keyword_count += counts[i]}

Update the CatalogController template to remove deprecations

DEPRECATION WARNING: config.index.show_link is deprecated; use config.index.title_field instead. (called from block in <class:CatalogController> at /home/travis/build/projecthydra/hydra-head/hydra-core/spec/internal/app/controllers/catalog_controller.rb:23)
DEPRECATION WARNING: config.index.record_display_type is deprecated; use config.index.display_type_field instead. (called from block in <class:CatalogController> at /home/travis/build/projecthydra/hydra-head/hydra-core/spec/internal/app/controllers/catalog_controller.rb:24)
DEPRECATION WARNING: config.show.html_title is deprecated; use config.show.title_field instead. (called from block in <class:CatalogController> at /home/travis/build/projecthydra/hydra-head/hydra-core/spec/internal/app/controllers/catalog_controller.rb:27)
DEPRECATION WARNING: config.show.heading is deprecated; use config.show.title_field instead. (called from block in <class:CatalogController> at /home/travis/build/projecthydra/hydra-head/hydra-core/spec/internal/app/controllers/catalog_controller.rb:28)
DEPRECATION WARNING: config.show.display_type is deprecated; use config.show.display_type_field instead. (called from block in <class:CatalogController> at /home/travis/build/projecthydra/hydra-head/hydra-core/spec/internal/app/controllers/catalog_controller.rb:29)
DEPRECATION WARNING: config.show.display_type is deprecated; use config.show.display_type_field instead. (called from block (4 levels) in <top (required)> at /home/travis/build/projecthydra/hydra-head/hydra-core/spec/helpers/blacklight_helper_spec.rb:7)
DEPRECATION WARNING: config.show.display_type is deprecated; use config.show.display_type_field instead. (called from document_partial_name at /home/travis/build/projecthydra/hydra-head/hydra-core/app/helpers/hydra/blacklight_helper_behavior.rb:15)

Gated discovery does not apply policies to anonymous user

from Hydra:: PolicyAwareAccessControlsEnforcement:

# find all the policies that grant discover/read/edit permissions to this user or any of it's groups
  def policies_with_access
    #### TODO -- Memoize this and put it in the session?
    return [] unless current_user
    # [snip]
  end

The return statement is the apparent cause of the observed effect that admin policies are not being applied to a search by an anonymous user.

Can't reset rightsMetadata.read_users (or read_groups) to empty once it's been set to something else

require 'spec_helper'

describe Hydra::Datastream::RightsMetadata do
  before :all do
    class RightsTest < ActiveFedora::Base
      include Hydra::ModelMixins::RightsMetadata
      has_metadata name: 'rightsMetadata', type: Hydra::Datastream::RightsMetadata
    end
  end

  after :all do
    Object.send(:remove_const,:RightsTest)
  end

  describe "rightsMetadata" do

    let!(:thing) {RightsTest.new}

    before :each do
      thing.read_users = ['[email protected]']
      thing.save
    end

    it "should persist read_users" do
      thing.reload.read_users.should == ['[email protected]']
    end

    it "should persist changes" do
      thing.read_users += ['[email protected]']
      thing.save
      thing.reload.read_users.should == ['[email protected]','[email protected]']
    end

    it "should persist emptiness" do
      thing.read_users = []
      thing.save
      thing.reload.read_users.should == []
    end
  end
end

Journal Article Example: Dead Link for Sample Mode XML

The URL for the Sample Mod XML returns a dead link (404).

Note: I found that if I use the "Example of the MODS XML" code block earlier in the article, added additional author, and modified the title and journal issue, I was able to create an XML file that contains elements in the article_mods_sample.xml that would pass subsequent tests.

Supply an XML schema for Hydra rightsMetadata

Formerly HYDRA-842

There exists no documented shared namespace and schema for Hydra rightsMetadata. Attached is a "strawman" example from Eddie Shin. A published schema would be a valuable piece of shared documentation.

Error: can not sort on multivalued field: pub_date_sort

I went through the text at

https://github.com/projecthydra/hydra-head/blob/master/README.textile

and then

https://github.com/projecthydra/hydra-head/wiki/Tools-for-Developing-and-Testing-your-Application

and then https://github.com/projecthydra/hydra-head/wiki/How-to-Get-Started

up to the point where it links to

https://github.com/projecthydra/hydra-head/wiki/Out-of-the-Box-Tour

and as I go through that

(2) Run the Hydra-Head gem’s RSpec Tests

rake hyhead:spec

This will print out a lot of information while the tests run. If all the tests passed, you will see something like this (the important part is “0 failures”):

...

(3) Run the Hydra-Head gem’s Cucumber Tests

Before running the cucumber tests, you have to remove the default index.html file that Rails provides

  rm public/index.html

Now run the cucumber tests

rake hyhead:cucumber

There are no longer hyhead: tasks defined... I ran instead

rake spec
rake cucumber

and they had exit code 0.

Now, when I go to http://localhost:3000 I get:


Started GET "/" for 127.0.0.1 at 2012-09-16 12:29:08 -0700
Processing by CatalogController#index as HTML
Solr parameters: {:qt=>"search", :rows=>10, :"facet.field"=>["object_type_facet", "pub_date", "subject_topic_facet", "language_facet", "lc_1letter_facet", "subject_geo_facet", "subject_era_facet"], "spellcheck.q"=>nil, :"f.subject_topic_facet.facet.limit"=>21, :sort=>"score desc, pub_date_sort desc, title_sort asc", :fq=>["edit_access_group_t:public OR discover_access_group_t:public OR read_access_group_t:public"]}
Completed 500 Internal Server Error in 30ms

RSolr::Error::Http (RSolr::Error::Http - 400 Bad Request
Error:     can not sort on multivalued field: pub_date_sort

URI: http://localhost:8983/solr/development/select?wt=ruby&fq=edit_access_group_t%3Apublic+OR+discover_access_group_t%3Apublic+OR+read_access_group_t%3Apublic&fq=-has_model_s%3A%22info%3Afedora%2Fafmodel%3AFileAsset%22&qt=search&rows=10&facet.field=object_type_facet&facet.field=pub_date&facet.field=subject_topic_facet&facet.field=language_facet&facet.field=lc_1letter_facet&facet.field=subject_geo_facet&facet.field=subject_era_facet&f.subject_topic_facet.facet.limit=21&sort=score+desc%2C+pub_date_sort+desc%2C+title_sort+asc

Backtrace: /Users/tingle/.rvm/gems/[email protected]/gems/rsolr-1.0.8/lib/rsolr/client.rb:230:in `adapt_response'
/Users/tingle/.rvm/gems/[email protected]/gems/rsolr-1.0.8/lib/rsolr/client.rb:167:in `execute'
/Users/tingle/.rvm/gems/[email protected]/gems/rsolr-1.0.8/lib/rsolr/client.rb:161:in `send_and_receive'
/Users/tingle/.rvm/gems/[email protected]/gems/rsolr-ext-1.0.3/lib/rsolr-ext/client.rb:21:in `find'
/Users/tingle/.rvm/gems/[email protected]/gems/blacklight-3.3.2/lib/blacklight/solr_helper.rb:85:in `find'
/Users/tingle/.rvm/gems/[email protected]/gems/blacklight-3.3.2/lib/blacklight/solr_helper.rb:317:in `get_search_results'
/Users/tingle/.rvm/gems/[email protected]/gems/blacklight-3.3.2/lib/blacklight/catalog.rb:34:in `index'
/Users/tingle/.rvm/gems/[email protected]/gems/actionpack-3.2.3/lib/action_controller/metal/implicit_render.rb:4:in `send_action'
/Users/tingle/.rvm/gems/[email protected]/gems/actionpack-3.2.3/lib/abstract_controller/base.rb:167:in `process_action'
/Users/tingle/.rvm/gems/[email protected]/gems/actionpack-3.2.3/lib/action_controller/metal/rendering.rb:10:in `process_action'
/Users/tingle/.rvm/gems/[email protected]/gems/actionpack-3.2.3/lib/abstract_controller/callbacks.rb:18:in `block in process_action'):
  rsolr (1.0.8) lib/rsolr/client.rb:230:in `adapt_response'
  rsolr (1.0.8) lib/rsolr/client.rb:167:in `execute'
  rsolr (1.0.8) lib/rsolr/client.rb:161:in `send_and_receive'
  rsolr-ext (1.0.3) lib/rsolr-ext/client.rb:21:in `find'
  blacklight (3.3.2) lib/blacklight/solr_helper.rb:85:in `find'
  blacklight (3.3.2) lib/blacklight/solr_helper.rb:317:in `get_search_results'
  blacklight (3.3.2) lib/blacklight/catalog.rb:34:in `index'
  actionpack (3.2.3) lib/action_controller/metal/implicit_render.rb:4:in `send_action'
  actionpack (3.2.3) lib/abstract_controller/base.rb:167:in `process_action'
  actionpack (3.2.3) lib/action_controller/metal/rendering.rb:10:in `process_action'
  actionpack (3.2.3) lib/abstract_controller/callbacks.rb:18:in `block in process_action'
  activesupport (3.2.3) lib/active_support/callbacks.rb:535:in `_run__1780543052194961142__process_action__2949795445947570623__callbacks'
  activesupport (3.2.3) lib/active_support/callbacks.rb:405:in `__run_callback'
  activesupport (3.2.3) lib/active_support/callbacks.rb:385:in `_run_process_action_callbacks'
  activesupport (3.2.3) lib/active_support/callbacks.rb:81:in `run_callbacks'
  actionpack (3.2.3) lib/abstract_controller/callbacks.rb:17:in `process_action'
  actionpack (3.2.3) lib/action_controller/metal/rescue.rb:29:in `process_action'
  actionpack (3.2.3) lib/action_controller/metal/instrumentation.rb:30:in `block in process_action'
  activesupport (3.2.3) lib/active_support/notifications.rb:123:in `block in instrument'
  activesupport (3.2.3) lib/active_support/notifications/instrumenter.rb:20:in `instrument'
  activesupport (3.2.3) lib/active_support/notifications.rb:123:in `instrument'
  actionpack (3.2.3) lib/action_controller/metal/instrumentation.rb:29:in `process_action'
  actionpack (3.2.3) lib/action_controller/metal/params_wrapper.rb:205:in `process_action'
  activerecord (3.2.3) lib/active_record/railties/controller_runtime.rb:18:in `process_action'
  actionpack (3.2.3) lib/abstract_controller/base.rb:121:in `process'
  actionpack (3.2.3) lib/abstract_controller/rendering.rb:45:in `process'
  actionpack (3.2.3) lib/action_controller/metal.rb:203:in `dispatch'
  actionpack (3.2.3) lib/action_controller/metal/rack_delegation.rb:14:in `dispatch'
  actionpack (3.2.3) lib/action_controller/metal.rb:246:in `block in action'
  actionpack (3.2.3) lib/action_dispatch/routing/route_set.rb:73:in `call'
  actionpack (3.2.3) lib/action_dispatch/routing/route_set.rb:73:in `dispatch'
  actionpack (3.2.3) lib/action_dispatch/routing/route_set.rb:36:in `call'
  journey (1.0.4) lib/journey/router.rb:68:in `block in call'
  journey (1.0.4) lib/journey/router.rb:56:in `each'
  journey (1.0.4) lib/journey/router.rb:56:in `call'
  actionpack (3.2.3) lib/action_dispatch/routing/route_set.rb:600:in `call'
  actionpack (3.2.3) lib/action_dispatch/middleware/static.rb:62:in `call'
  warden (1.2.1) lib/warden/manager.rb:35:in `block in call'
  warden (1.2.1) lib/warden/manager.rb:34:in `catch'
  warden (1.2.1) lib/warden/manager.rb:34:in `call'
  actionpack (3.2.3) lib/action_dispatch/middleware/best_standards_support.rb:17:in `call'
  rack (1.4.1) lib/rack/etag.rb:23:in `call'
  rack (1.4.1) lib/rack/conditionalget.rb:25:in `call'
  actionpack (3.2.3) lib/action_dispatch/middleware/head.rb:14:in `call'
  actionpack (3.2.3) lib/action_dispatch/middleware/params_parser.rb:21:in `call'
  actionpack (3.2.3) lib/action_dispatch/middleware/flash.rb:242:in `call'
  rack (1.4.1) lib/rack/session/abstract/id.rb:205:in `context'
  rack (1.4.1) lib/rack/session/abstract/id.rb:200:in `call'
  actionpack (3.2.3) lib/action_dispatch/middleware/cookies.rb:338:in `call'
  activerecord (3.2.3) lib/active_record/query_cache.rb:64:in `call'
  activerecord (3.2.3) lib/active_record/connection_adapters/abstract/connection_pool.rb:467:in `call'
  actionpack (3.2.3) lib/action_dispatch/middleware/callbacks.rb:28:in `block in call'
  activesupport (3.2.3) lib/active_support/callbacks.rb:405:in `_run__4266802855547583725__call__647872806407529695__callbacks'
  activesupport (3.2.3) lib/active_support/callbacks.rb:405:in `__run_callback'
  activesupport (3.2.3) lib/active_support/callbacks.rb:385:in `_run_call_callbacks'
  activesupport (3.2.3) lib/active_support/callbacks.rb:81:in `run_callbacks'
  actionpack (3.2.3) lib/action_dispatch/middleware/callbacks.rb:27:in `call'
  actionpack (3.2.3) lib/action_dispatch/middleware/reloader.rb:65:in `call'
  actionpack (3.2.3) lib/action_dispatch/middleware/remote_ip.rb:31:in `call'
  actionpack (3.2.3) lib/action_dispatch/middleware/debug_exceptions.rb:16:in `call'
  actionpack (3.2.3) lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
  railties (3.2.3) lib/rails/rack/logger.rb:26:in `call_app'
  railties (3.2.3) lib/rails/rack/logger.rb:16:in `call'
  actionpack (3.2.3) lib/action_dispatch/middleware/request_id.rb:22:in `call'
  rack (1.4.1) lib/rack/methodoverride.rb:21:in `call'
  rack (1.4.1) lib/rack/runtime.rb:17:in `call'
  activesupport (3.2.3) lib/active_support/cache/strategy/local_cache.rb:72:in `call'
  rack (1.4.1) lib/rack/lock.rb:15:in `call'
  actionpack (3.2.3) lib/action_dispatch/middleware/static.rb:62:in `call'
  railties (3.2.3) lib/rails/engine.rb:479:in `call'
  railties (3.2.3) lib/rails/application.rb:220:in `call'
  rack (1.4.1) lib/rack/content_length.rb:14:in `call'
  railties (3.2.3) lib/rails/rack/log_tailer.rb:14:in `call'
  rack (1.4.1) lib/rack/handler/webrick.rb:59:in `service'
  /Users/tingle/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/webrick/httpserver.rb:138:in `service'
  /Users/tingle/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/webrick/httpserver.rb:94:in `run'
  /Users/tingle/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/webrick/server.rb:191:in `block in start_thread'


  Rendered /Users/tingle/.rvm/gems/[email protected]/gems/actionpack-3.2.3/lib/action_dispatch/middleware/templates/rescues/_trace.erb (3.6ms)
  Rendered /Users/tingle/.rvm/gems/[email protected]/gems/actionpack-3.2.3/lib/action_dispatch/middleware/templates/rescues/_request_and_response.erb (1.2ms)
  Rendered /Users/tingle/.rvm/gems/[email protected]/gems/actionpack-3.2.3/lib/action_dispatch/middleware/templates/rescues/diagnostics.erb within rescues/layout (16.2ms)

Nil pointer error in Hydra::Datastream::RightsMetadata

     NoMethodError:
       undefined method `keys' for nil:NilClass
     # /Users/justin/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/hydra-access-controls-6.4.0/lib/hydra/datastream/rights_metadata.rb:146:in `permissions='
     # ./spec/models/collection_spec.rb:36:in `block (2 levels) in <top (required)>'

rails ~>3.2.2 or rails = 3.2.3

trying to install "my_hydra_head" from scratch, following the instructions @ https://github.com/projecthydra/hydra-head/

Install Rails

Currently hydra-head is compatible with Rails 3.2

gem install 'rails' --version '~>3.2.2'
BRIAN-TINGLEs-MacBook-Air:my_hydra_head tingle$ bundle install
Fetching gem metadata from https://rubygems.org/........
Fetching gem metadata from https://rubygems.org/..
Bundler could not find compatible versions for gem "rails":
  In Gefile:
    hydra-head (~> 4.0.0) ruby depends on
      rails (= 3.2.3) ruby

    rails (3.2.8)

should that be?

gem install 'rails' --version ' = 3.2.3'
--- a/Gemfile
+++ b/Gemfile
@@ -7,6 +7,8 @@ gem 'rails', '3.2.3'

 gem 'sqlite3'

+gem 'blacklight', '~> 3.3.2'
+gem 'hydra-head', '~> 4.0.0'

 # Gems used only for assets and not required
 # in production environments by default.
@@ -20,6 +22,20 @@ group :assets do
   gem 'uglifier', '>= 1.0.3'
 end

+# You will probably want to use these to run the tests you write for your hydra head
+# For testing with Cucumber
+group :cucumber do
+  gem 'cucumber'
+  gem 'cucumber-rails'
+end
+
+# For testing with rspec
+group :development, :test do
+  gem 'rspec-rails', '>=2.9.0'
+  gem 'jettywrapper'
+  gem 'database_cleaner'
+end
+
 gem 'jquery-rails'

 # To use ActiveModel has_secure_password

After that; bundle install did run with exit 0.

CanCan lesson

CanCan lesson asks you to use the Book's show page, but doesn't specify that you need to use the /books controller and not the /catalog.

Embargo is not enforced

You can set embargo on a Fedora object and the embargo field gets indexed in Solr correctly. However, searches are not enforcing embargo. The under_embargo? check works, though.

It looks like embargo enforcement was removed a while ago:
https://github.com/projecthydra/hydra-head/blob/v3.0.0/lib/hydra/access_controls_enforcement.rb#L203

It also looks like it is now possible to enforce it for the show view:
https://github.com/projecthydra/hydra-head/blob/2be4b2a0a3a0b7cf68e38bfecc7cd7f318ceee3e/hydra-core/lib/generators/hydra/templates/catalog_controller.rb#L9

https://github.com/projecthydra/hydra-head/blob/2402c71167d3aed9d62bae78ce5c504854f3188d/hydra-access-controls/lib/hydra/access_controls_enforcement.rb#L53

It seems to make more sense to enforce it for all Solr queries, though. This could mean adding code around here:

https://github.com/projecthydra/hydra-head/blob/49a936eef922f9024ffa08a9efff6c816d6032d2/hydra-access-controls/lib/hydra/access_controls_enforcement.rb#L19

A workaround for applications wanting to enforce embargo before this is fixed might look something like this:

https://github.com/projecthydra/curate/blob/197e4535ca2bc8d95450ee9a1272b0fd9abbc7fe/app/controllers/catalog_controller.rb#L18

https://github.com/projecthydra/curate/blob/197e4535ca2bc8d95450ee9a1272b0fd9abbc7fe/app/helpers/hydramata/solr_helper.rb#L8

To enforce on edit/show views:
https://github.com/projecthydra/curate/blob/874656adffab69990edfab731afbd2c7f52de279/app/models/concerns/curate/ability.rb#L29
https://github.com/projecthydra/curate/blob/874656adffab69990edfab731afbd2c7f52de279/app/models/concerns/curate/ability.rb#L69
https://github.com/projecthydra/curate/blob/874656adffab69990edfab731afbd2c7f52de279/app/models/concerns/curate/ability.rb#L105
https://github.com/projecthydra/curate/blob/874656adffab69990edfab731afbd2c7f52de279/app/models/concerns/curate/ability.rb#L140

Add custom rspec matcher to assert what the inferface is for a valid Hydra model

Given that a Hydra model assumes a few metadata data streams, there should be a matcher such that:

  expect(Thing).to implement_hydra_model_api

In this way we can help migrate users from version to version. As I understand it, there is an assumption about having a descMetadata and a rightsMetadata datastream, but would want to verify additional behavior.

Release hydra-head 6.5.0.rc1

I have created a new branch 6-5-stable from 6-4-stable. #146 added a new public method, so semantic versioning suggests that we should issue a new minor release. #147 also upgraded active-fedora to minimum version 6.7.

Looking for +1's to release.

Slow loading of a Fedora object with a large datastream (version 5.4)

When doing an object.find(pid) on an object with a large datastream, there is a significant performance issue. Removing the datastream from the object "fixes" the issue.

To replicate, add the following line to one of your Active Fedora models:

has_metadata :name => "ARCHV-TECHMD", :type => ActiveFedora::Datastream,     :label=>'Archive image technical metadata'

Add an "ARCHV-TECHMD" datastream to your object with this xml content:
https://gist.github.com/mstroming/724d1395774d5b7f6d39

Copy this test file into your project, replace the "test_pid" with your pid, the "Model" with your model, and run the test (rspec path/to/file). You should see that it takes more than 5 seconds to load the object. You can then remove the datastream and re-run the test to see that it takes the regular amount of time to load the object.
https://gist.github.com/mstroming/8ff0ea09d556a7f99e72

It should work with rails 4

Currently, I'm unable to run bundle install.

The line gem.add_dependency 'blacklight' in hydra-access-controls.gemspec seems to cause this error:

Bundler could not find compatible versions for gem "railties":
  In Gemfile:
    hydra-head (>= 0) ruby depends on
      railties (~> 3.1.0) ruby

    rails (= 4.0.0.rc1) ruby depends on
      railties (4.0.0.rc1)

Bundler could not find compatible versions for gem "rails":
  In Gemfile:
    hydra-head (>= 0) ruby depends on
      rails (~> 3.0) ruby

    rails (4.0.0.rc1)

I wonder if this is because blacklight depends on boostrap-sass 2.3, which depends on sass-rails ~> 3.2, which depends on railties ~> 3.2

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.