Installing hieraki help

Ahoy,

I tried to install hieraki and it was a big mess.

  1. upload_progress module needed to be installed
  2. no test/development server configured in the config file so i had to
    add those
  3. no log directory, had to add that
  4. had to install 2 gems (ok fine)
  5. once the server started, go to homepage and

" NameError in Wiki/pageController#index

uninitialized constant Node

RAILS_ROOT: ./script/…/config/…
Application Trace | Framework Trace | Full Trace

This error occured while loading the following files:
wiki/processor/instruction_set/node.rb"

I didn’t find any documentation , help or otherwise anywhere.

Will Jessup wrote:

Ahoy,
5) once the server started, go to homepage and
" NameError in Wiki/pageController#index

uninitialized constant Node

RAILS_ROOT: ./script/…/config/…
Application Trace | Framework Trace | Full Trace

This error occured while loading the following files:
wiki/processor/instruction_set/node.rb"

I didn’t find any documentation , help or otherwise anywhere.
I have this problem too

This only happen with development environment, production is ok, I don’t
know why?

does the hieraki mailing list work? is the website ok? seems like
something has gone wrong with the project.

Peter

El lun, 24-04-2006 a las 08:13 +0200, agilesoftware escribió:

This only happen with development environment, production is ok, I don’t
know why?

No is exactly the same.

uninitialized constant Node

RAILS_ROOT: script/…/config/…

/usr/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/active_support/dependencies.rb:123:in
const_missing' #{RAILS_ROOT}/app/controllers/wiki/processor/instruction_set.rb:8:inlookup_root’
/usr/lib/ruby/gems/1.8/gems/actionpack-1.12.1/lib/action_controller/filters.rb:399:in
call_filters' /usr/lib/ruby/gems/1.8/gems/actionpack-1.12.1/lib/action_controller/filters.rb:394:incall_filters’
/usr/lib/ruby/gems/1.8/gems/actionpack-1.12.1/lib/action_controller/filters.rb:383:in
before_action' /usr/lib/ruby/gems/1.8/gems/actionpack-1.12.1/lib/action_controller/filters.rb:365:inperform_action_without_benchmark’
/usr/lib/ruby/gems/1.8/gems/actionpack-1.12.1/lib/action_controller/benchmarking.rb:69:in
perform_action_without_rescue' /usr/lib/ruby/1.8/benchmark.rb:293:inmeasure’
/usr/lib/ruby/gems/1.8/gems/actionpack-1.12.1/lib/action_controller/benchmarking.rb:69:in
perform_action_without_rescue' /usr/lib/ruby/gems/1.8/gems/actionpack-1.12.1/lib/action_controller/rescue.rb:82:inperform_action’
/usr/lib/ruby/gems/1.8/gems/actionpack-1.12.1/lib/action_controller/base.rb:381:in
process_without_filters' /usr/lib/ruby/gems/1.8/gems/actionpack-1.12.1/lib/action_controller/filters.rb:377:inprocess_without_session_management_support’
/usr/lib/ruby/gems/1.8/gems/actionpack-1.12.1/lib/action_controller/session_management.rb:117:in
process' /usr/lib/ruby/gems/1.8/gems/rails-1.1.2/lib/dispatcher.rb:38:indispatch’
/usr/lib/ruby/gems/1.8/gems/rails-1.1.2/lib/webrick_server.rb:115:in
handle_dispatch' /usr/lib/ruby/gems/1.8/gems/rails-1.1.2/lib/webrick_server.rb:81:inservice’
/usr/lib/ruby/1.8/webrick/httpserver.rb:104:in service' /usr/lib/ruby/1.8/webrick/httpserver.rb:65:inrun’
/usr/lib/ruby/1.8/webrick/server.rb:173:in start_thread' /usr/lib/ruby/1.8/webrick/server.rb:162:instart_thread’
/usr/lib/ruby/1.8/webrick/server.rb:95:in start' /usr/lib/ruby/1.8/webrick/server.rb:92:instart’
/usr/lib/ruby/1.8/webrick/server.rb:23:in start' /usr/lib/ruby/1.8/webrick/server.rb:82:instart’
/usr/lib/ruby/gems/1.8/gems/rails-1.1.2/lib/webrick_server.rb:67:in
dispatch' /usr/lib/ruby/gems/1.8/gems/rails-1.1.2/lib/commands/servers/webrick.rb:59 /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:21:inrequire’
/usr/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/active_support/dependencies.rb:147:in
require' /usr/lib/ruby/gems/1.8/gems/rails-1.1.2/lib/commands/server.rb:30 /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:21:inrequire’
/usr/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/active_support/dependencies.rb:147:in
`require’
script/server:3
This error occured while loading the following files:
wiki/processor/instruction_set/node.rb

I’m running Hieraki with frozen rails 1.0 (vendor/rails)

Here are three of the files I changed to get Hieraki working:

I patched the search so it would work. Using Typo search as a guide:

=======================================
models/wiki/page.rb lines ~65-86

def self.search(query, options = {})
configuration = { :only_published => false }
configuration.update(options) if options.is_a?(Hash)
if !query.to_s.strip.empty?
published = ‘AND published != 0’ if configuration[:only_published]
tokens = query.split

if configuration[:only_published]

else

    # Using SQLite3, now - Ed Gard
    #find_by_sql(["SELECT *
    #              FROM pages
    #              WHERE MATCH (keywords) AGAINST (?)", 

tokens.join(’ ')])

end

    # New - Ed Gard
    find(:all,
         :conditions => [(["(LOWER(keywords) LIKE ?)"] * 

tokens.size).join(" AND "), *tokens.collect { |token| [token] * 1
}.flatten],
:order => ‘updated_at DESC’)
else
[]
end
end

=============================================
Another changed file:

views/wiki/actions/_edit_acl.rhtml

<%= heading_for(@page, ‘Permission Settings’)%>
<%= start_form_tag wiki_url(@page, :action => ‘edit_acl’) %>

User: <%= render_spinner('user') %>

<%= end_form_tag %>

<%= render :partial => ‘shared/control_buttons’ %>
<%= observe_field “login”,
{ :frequency => 0.5,
:url => wiki_url(@page, :controller =>
‘wiki/acl’, :action => ‘show’),
:with => “‘login=’+ escape($(‘login’).value)”,
:update => ‘user_result’
}.merge(remote_spinner(‘user’, ‘user_result’)) %>

============
Added a migration:

db/migrate/001_initial_schema.rb

class InitialSchema < ActiveRecord::Migration
def self.up
create_table “acl”, :force => true do |t|
t.column “user_id”, :integer, :default => 0, :null => false
t.column “page_id”, :integer, :default => 0, :null => false
t.column “control_bit”, :integer, :limit => 1, :default => 0
t.column “modify_bit”, :integer, :limit => 1, :default => 0
t.column “delete_bit”, :integer, :limit => 1, :default => 0
t.column “create_bit”, :integer, :limit => 1, :default => 0
end

create_table "document_revision_meta", :force => true do |t|
  t.column "body", :text, :default => "", :null => false
end

create_table "external_link_revision_meta", :force => true do |t|
  t.column "url", :string, :default => "", :null => false
  t.column "description", :text, :default => "", :null => false
end

create_table "folder_revision_meta", :force => true do |t|
  t.column "description", :text, :default => "", :null => false
end

create_table "internal_link_revision_meta", :force => true do |t|
  t.column "link_to_name", :string, :default => "", :null => false
end

create_table "mimes", :id => false, :force => true do |t|
  t.column "filetype", :string, :limit => 10, :default => "", :null 

=> false
t.column “mimetype”, :string, :limit => 50, :default => “”, :null
=> false
end

create_table "nodes", :id => false, :force => true do |t|
  t.column "name", :string, :default => "", :null => false
  t.column "parent_name", :string, :default => "", :null => false
  t.column "page_id", :integer, :default => 0, :null => false
  t.column "position", :integer, :default => 0, :null => false
  t.column "lft", :integer, :default => 0, :null => false
  t.column "rgt", :integer, :default => 0, :null => false
end

add_index "nodes", ["parent_name"], :name => "parent_name"

create_table "page_revisions", :force => true do |t|
  t.column "page_id", :integer, :default => 0, :null => false
  t.column "meta_id", :integer, :default => 0, :null => false
  t.column "user_id", :integer, :default => 0, :null => false
  t.column "type", :string, :default => "", :null => false
  t.column "title", :string, :default => "", :null => false
  t.column "comment", :string, :default => ""
  t.column "published", :integer, :limit => 1, :default => 0
  t.column "created_at", :datetime
  t.column "ip", :string, :limit => 15
end

create_table "pages", :force => true do |t|
  t.column "version", :integer, :default => 0, :null => false
  t.column "keywords", :text, :default => "", :null => false
  t.column "type", :string, :default => "", :null => false
  t.column "updated_at", :datetime
end

add_index "pages", ["type"], :name => "type"
add_index "pages", ["keywords"], :name => "keywords"

create_table "users", :force => true do |t|
  t.column "name", :string, :limit => 80, :default => "", :null => 

false
t.column “login”, :string, :limit => 80, :default => “”, :null =>
false
t.column “email”, :string, :default => “”, :null => false
t.column “password”, :string, :limit => 40
t.column “created_at”, :datetime
end

end

def self.down
end
end

====================================

Ed

Will Jessup wrote:

Ahoy,

I tried to install hieraki and it was a big mess.

  1. upload_progress module needed to be installed
  2. no test/development server configured in the config file so i had to
    add those
  3. no log directory, had to add that
  4. had to install 2 gems (ok fine)
  5. once the server started, go to homepage and

" NameError in Wiki/pageController#index

uninitialized constant Node

RAILS_ROOT: ./script/…/config/…
Application Trace | Framework Trace | Full Trace

This error occured while loading the following files:
wiki/processor/instruction_set/node.rb"

I didn’t find any documentation , help or otherwise anywhere.