Problem to update Wiki [message #56607] |
Fri, 10 April 2009 09:10  |
Eclipse User |
|
|
|
Hi everybody,
I have a problem after creating a WIki
I am able to select a Baseline Process
But after (when I want to update manualy), I have an error :
undefined method `title' for nil:NilClass
Anybody know why ?
PS: It's a Test Environment without SMTP server
|
|
|
|
|
|
|
|
Re: Problem to update Wiki [message #56899 is a reply to message #56765] |
Tue, 12 May 2009 05:55  |
Eclipse User |
|
|
|
Thanks Onno, I will not use strange characters in my filenames anymore. It
will be easier
However, I think I found a solution concerning the rel_path:
In file /app/models/baseline_process.rb, You can modify method
scan4content like this :
require 'cgi'
#...
def scan4content
logger.info("Scanning content in site #{self.title}")
self.pages = []
if self.content_scanned_on.nil?
files = self.files_wikifiable
self.wikifiable_files_count = files.size # TODO obsolete?
files.each do |f|
page = BaselineProcessPage.new(:rel_path => CGI.escape(f.gsub
(self.path + '/', '')), :site => self, :tool => 'EPFC', :status =>
'N.A.')
self.pages << page
end
self.content_scanned_on = Time.now
self.save!
else
logger.info("Content has already been scanned!")
end
end
But you will have the same problem with filename : indeed there are 2
different columns in table pages (rel_pah and filname)
|
|
|
Re: Problem to update Wiki [message #598629 is a reply to message #56607] |
Wed, 15 April 2009 03:40  |
Eclipse User |
|
|
|
Hi everybody,
I think my problem is not to update a wiki but to create a baseline
In fact when I create a baseline, I obtain a baseline but without content
and 0 Pages
I check in the database, there isn't records in tables pages concerning
the new baseline
|
|
|
Re: Problem to update Wiki [message #598636 is a reply to message #56635] |
Mon, 20 April 2009 07:46  |
Eclipse User |
|
|
|
OK I found the real problem:
When we update a wiki with a baseline, many informations are recorded in
the database
As I have some path with accent characters, informations can't be insert
in the table "Pages". I have this error:
Mysql::Error: #HY000Incorrect string value: '\xE9_547B...' for column
'rel_path' at row 1: INSERT IGNORE INTO `pages` (`body_tag`, `created_on`,
`rel_path`) VALUES('', '2009-04-20 10:59:18',
'up/workproduct/produit_install�_547BA611.html')
|
|
|
Re: Problem to update Wiki [message #598643 is a reply to message #56660] |
Mon, 20 April 2009 08:12  |
Eclipse User |
|
|
|
Angelo wrote:
> OK I found the real problem:
> When we update a wiki with a baseline, many informations are recorded in
> the database
> As I have some path with accent characters, informations can't be insert
> in the table "Pages". I have this error:
> Mysql::Error: #HY000Incorrect string value: 'xE9_547B...' for column
> 'rel_path' at row 1: INSERT IGNORE INTO `pages` (`body_tag`, `created_on`,
> `rel_path`) VALUES('', '2009-04-20 10:59:18',
> 'up/workproduct/produit_install�_547BA611.html')
Sorry I forget my question
Is there a solution to insert those information ?
Naturally, I can rename this web page but it will be a long work because I
will have to change all html link in all my web's pages
|
|
|
|
Re: Problem to update Wiki [message #598664 is a reply to message #56687] |
Wed, 29 April 2009 05:55  |
Eclipse User |
|
|
|
I have created a bugzilla for this, I have to take a closer look at this
to see if a workaround is possible. It will not be soon I'm afraid.
It is a best practice to not use such strange characters in your filenames
so you might consider changing filenames anyway, regardless of a
workaround being available. Personally I only use lowercase characters and
underscores.
Bugzilla: https://bugs.eclipse.org/bugs/show_bug.cgi?id=274267
|
|
|
Re: Problem to update Wiki [message #598685 is a reply to message #56765] |
Tue, 12 May 2009 05:55  |
Eclipse User |
|
|
|
Thanks Onno, I will not use strange characters in my filenames anymore. It
will be easier
However, I think I found a solution concerning the rel_path:
In file /app/models/baseline_process.rb, You can modify method
scan4content like this :
require 'cgi'
#...
def scan4content
logger.info("Scanning content in site #{self.title}")
self.pages = []
if self.content_scanned_on.nil?
files = self.files_wikifiable
self.wikifiable_files_count = files.size # TODO obsolete?
files.each do |f|
page = BaselineProcessPage.new(:rel_path => CGI.escape(f.gsub
(self.path + '/', '')), :site => self, :tool => 'EPFC', :status =>
'N.A.')
self.pages << page
end
self.content_scanned_on = Time.now
self.save!
else
logger.info("Content has already been scanned!")
end
end
But you will have the same problem with filename : indeed there are 2
different columns in table pages (rel_pah and filname)
|
|
|
Powered by
FUDForum. Page generated in 0.24617 seconds