How to export from Mnemosyne?

108 views
Skip to first unread message

OldGrantonian

unread,
Sep 17, 2008, 6:31:41 AM9/17/08
to mnemosyne-proj-users
I use MS 1.1.1 with WinXP Home.

When I want to export from MS, I do the following:

File > Export

In the "Export to File" dialog box, the following values are pre-
populated:
(a) File format: XML
(b) File to export to: ...\<database_name>
\<database_name>.XML

So at first glance, it looks as I only need to select a category, then
click OK. I then expect to see a file called <database_name>.XML in
the target directory.

In fact nothing happens.

In the "File Format" dropdown menu, I then try "Cuecard.wcu".

In "File to export to", I expect to see the extension XML change to
WCU. It doesn't. If I now click OK, there is no file in the target
directory. If I manually type WCU, there is still no file.

I then try the only other option, which is "Text with tab-separated Q/
A". Again, nothing happens.

The only way that I can export a file is to actually browse to the
target directory, then enter a filename.

Am I doing something wrong?

Peter Bienstman

unread,
Sep 17, 2008, 6:44:36 AM9/17/08
to mnemosyne-...@googlegroups.com
You are right that the extension does not change automatically when changing
file format.

However, if I just change the extension manually and click on export,
everything works.

Is there anything in the error log?

Sometimes strange things happen under Windows, and then it helps uninstalling
the program, and reinstalling it.

Peter

--
------------------------------------------------
Peter Bienstman
Ghent University, Dept. of Information Technology
Sint-Pietersnieuwstraat 41, B-9000 Gent, Belgium
tel: +32 9 264 34 46, fax: +32 9 264 35 93
WWW: http://photonics.intec.UGent.be
email: Peter.B...@UGent.be
------------------------------------------------

OldGrantonian

unread,
Sep 17, 2008, 9:55:55 AM9/17/08
to mnemosyne-proj-users
On Sep 17, 11:44 am, Peter Bienstman <Peter.Bienst...@ugent.be> wrote:

> Is there anything in the error log?


The log had no mention of export errors. But I think I've found the
problem.

For any program that produces data, I keep that data in a single
location. That makes it easy to backup to an external drive with a
single command.

So my MS data is at:

My Documents\Data\.mnemosyne

rather than at the installation default:

D:\Documents and Settings\<user_name>\.mnemosyne

As an experiment, I moved my data back to:

D:\Documents and Settings\<user_name>\.mnemosyne

I opened my database from that location, then tried an export.
Everything worked fine :)

Here are the differences produced by having data in different
locations:

If the data is stored at the installation default, then the path in
"File to export to" is:

d:\documents and settings\<user_name>\.mnemosyne\databases
\<database_name>\<database_name>.xml

However, if the data is move to another location, then the path in
"File to export to" is:

databases\..<more_folders>....\<database_name>\<database_name>.xml

BTW: I have verified that MS can always find the current "config.py"
file by searching upwards from the location of the current database.
Therefore, the export routine should also be able to locate the
current database directory, simply by interrogating the operating
system for the name of the current directory.

Recommendation: For the export field, "File to export to", the pre-
populated value should be the full path of the current database plus
<database_name>.<extension>

Peter Bienstman

unread,
Sep 17, 2008, 10:05:04 AM9/17/08
to mnemosyne-...@googlegroups.com
On Wednesday 17 September 2008 15:55:55 OldGrantonian wrote:

> BTW: I have verified that MS can always find the current "config.py"
> file by searching upwards from the location of the current database.

This is unsupported. If you want to place your data directory in a different
place, the only supported way to do so is by adding the command line option '-
d <my desired path>' when you start Mnemosyne.

You can automate this by creating a desktop shortcut with as location

"C:\Program Files\Mnemosyne\mnemosyne.exe" -d C:\whatever

Otherwise, you will run into troubles by mixing data from the default location
and your desired location, as you found out.

Peter

OldGrantonian

unread,
Sep 18, 2008, 3:51:21 AM9/18/08
to mnemosyne-proj-users
Everything works now :)

I right-clicked on the desktop icon, and in the "Start in" field, I
typed:

"D:\Documents and Settings\<user_name>\My Documents\Data\.mnemosyne"

That's the first time I knew the purpose of the "Start in" field :)

BTW: What's the purpose of the dot in front of the ".mnemosyne" ?

Peter Bienstman

unread,
Sep 18, 2008, 3:52:36 AM9/18/08
to mnemosyne-...@googlegroups.com
On Thursday 18 September 2008 09:51:21 OldGrantonian wrote:

> BTW: What's the purpose of the dot in front of the ".mnemosyne" ?

So that it's a hidden directory under Linux. Common practice on that platform.

Peter

Peter Bienstman

unread,
Sep 18, 2008, 3:55:28 AM9/18/08
to mnemosyne-...@googlegroups.com
On Thursday 18 September 2008 09:51:21 OldGrantonian wrote:
> Everything works now :)
>
> I right-clicked on the desktop icon, and in the "Start in" field, I
> typed:
>
> "D:\Documents and Settings\<user_name>\My Documents\Data\.mnemosyne"
>
> That's the first time I knew the purpose of the "Start in" field :)

Oh, BTW, that is NOT how you are supposed to do this. You should use the -d
option in the 'target' field as I explained, otherwise it won't work.

Peter

OldGrantonian

unread,
Sep 18, 2008, 8:36:41 AM9/18/08
to mnemosyne-proj-users
Peter Bienstman wrote:

> You can automate this by creating a desktop shortcut with as location

> "C:\Program Files\Mnemosyne\mnemosyne.exe" -d C:\whatever



I must be doing something wrong :(

For simplicity, I've copied my up-to-date directory to D:\.mnemosyne

At a DOS command prompt, type:

"C:\Program Files\Mnemosyne\mnemosyne.exe" -d "D:\.mnemosyne"

When MS opens, I do an export. The export is always to the (out-of-
date) installation location:

D:\Documents and Settings\<user>\.mnemosyne

If I edit a card, the file is again saved to the installation
location.

Please advise.

Peter Bienstman

unread,
Sep 18, 2008, 9:05:06 AM9/18/08
to mnemosyne-...@googlegroups.com
In order to keep you having to retype stuff, Mnemosyne remembers the last
directory of a successful export.

It's only when starting from a 'virgin' installation that the location
defaults to the current datadir.

Peter

OldGrantonian

unread,
Sep 19, 2008, 9:39:21 AM9/19/08
to mnemosyne-proj-users
Hi Peter,

I still can't do exports without a lot of manual hassle.

I'm not a techie, so most of your well-intended advice on "virgin
installation" and "current datadir" is all meaningless to me. I would,
therefore, be most grateful if you would consent to a simple, step-by-
step approach to this issue. The advantage of the step-by-step
approach is that we can incrementally advance a mutually agreed
"baseline" to the next successful baseline. If we disagree, we can
roll back to a previously agreed baseline and start again.

Here are my successful steps:

1) Copy the .mnemosyne directory to a new location, D:\.mnemosyne

2) In the desktop shortcut, enter the following values:

Target:
"C:\Program Files\Mnemosyne\mnemosyne.exe" -d "D:\.mnemosyne"

Start in:
<<blank>>

3) Launch MS

4) File > Open

Navigate to any database under D:\.mnemosyne

5) Edit the first card by making a trivial edit, such as adding a
space and then deleting the space.

6) File > Save

7) In Windows Explorer, verify that the .MEM file has been updated in
the correct database location.
----------------------------------------------------------------------------

Everything works up to here. So this is Baseline #1.
---------------------------------------------------------------------------

8) File > Export

9) In the " Export to file" dialog box, accept all the pre-populated
defaults

In my MS, the pre-populated defaults are:

File format: XML
File to export to: databases\iseb\hambling\myquestions
\myquestions.xml <<which is correct>>

10) Click OK.
----------------------------------------------------------

After step 10, nothing happens.

I searched every possible MS database for the exported file, but no
luck.

If there are any errors in my previous steps, please let me know, so
that I can redo the steps from Baseline #1.

Peter Bienstman

unread,
Sep 19, 2008, 11:08:16 AM9/19/08
to mnemosyne-...@googlegroups.com
Hi,

Virgin install is the state you have after just installing the program and
when you haven't touched it yet.

The datadir is the .mnemosyne directory.

When I read your recipe, the following has happened internally:

* The first time you started .mnemosyne, you did not use the -d option, the
datadir got created in its default location in C:\Documents and
settings\oldgrantonian\.mnemosyne. The default directory for exports also got
initialised to that directory.

* if you move your datadir to a new place and start with the correct -d
option, internally, the export directory still points to C:\Documents and
settings\oldgrantonian\.mnemosyne, so that in your scenario, you try to export
to a path which no longer exists. Mnemosyne silently fails in this case, as
opposed to giving an error. I will make this more robust in a future release

* However, the workaround is easy, just browse to the correct dir the first
time, and afterwards Mnemosyne will remember that location.

If you start Mnemosyne the first time with the -d option, then this issue will
not occur.

Hopefully this clarifies the situation somewhat.

Thanks for the feedback!

Peter

Reply all
Reply to author
Forward
0 new messages