Bugs: Browse | Submit New | Admin

[#24869] yaml files contain too much data (c.f. #19555)

Date:
2009-03-25 16:09
Priority:
3
Submitted By:
Alexander Ninnig (ninnig)
Assigned To:
Cathal Mc Ginley (cathalmagus)
Category:
Library Manager
State:
Open
Summary:
yaml files contain too much data (c.f. #19555)

Detailed description
hello,

I use Alexandria version 0.6.3 with Ubuntu 8.04.

Sometimes, yaml-files contain too much data. Those files are much bigger, than usual files (sometimes more than 100kb).
Opening them (with a normal editor) shows, that right after "library:" one can find "&id001
!seq:Alexandria::Library" followed by lots of lots of content of other yaml-files. At the end, the correct endig
of the suspected file is shown.

So, it's like

Book101, line 1
Book101, line 2
Book101, line 3
  Book1 all lines
  Book2 all lines
  Book3 all lines
  ...
Book101, line 4
Book101, last line

No problem to fix it manually; I just open the yaml-files, that are way too big and cut out the wrong data (always beetween
"library:" and "loaned: false").

As I said, not really a problem for me, but I wanted to give you a feedback, in case this bug isn't known.


Unfortunately, I cannot tell WHEN this happens.

Thanks for this piece of software,
greetings,

alex

Add A Comment: Notepad

Please login


Followup

Message
Date: 2009-03-25 18:47
Sender: Cathal Mc Ginley

I've attached a script which *should* fix these corrupted files.

Back up your whole .alexandria directory first, then read the
instructions at the top of the script. Try it on a single YAML
file to start with, then run the script without parameters to
fix all the YAML files.

Please, let me know if it works.

PS: I noticed that Alexandria 0.6.4.1 crashed when I tried to
start it with your example corrupted YAML file in "My
Library"; but after you fix the data, it might be a good
time to upgrade :^)

http://alexandria.rubyforge.org/news/2009-03-14--0.6.4-released.h
tml
Date: 2009-03-25 17:39
Sender: Cathal Mc Ginley

This looks like a duplicate of #19555
http://rubyforge.org/tracker/?group_id=205&atid=863&func=
detail&aid=19555

If you read that report, you'll it's due to an issue with the
data format changing (briefly) between 0.6.2 and 0.6.3

Thanks for uploading a sample file, I can now work on resolving
the issue programmatically. I can probably work up a script for
"cleaning" your YAML files.

By the way, there is a later release - 0.6.4.1, but it hasn't
made its way out to Alexandria's PPA yet.

Attached Files:

Name Description Download
9783506238009.yaml yaml-file with too much content Download
fix_yaml.rb Script to fix corrupted YAML files Download

Changes:

Field Old Value Date By
File Added4447: fix_yaml.rb2009-03-25 18:47cathalmagus
resolution_idNone2009-03-25 18:47cathalmagus
category_idNone2009-03-25 17:39cathalmagus
assigned_tonone2009-03-25 17:39cathalmagus
summaryyaml files contain too much data2009-03-25 17:39cathalmagus
File Added4445: 9783506238009.yaml2009-03-25 16:09ninnig