two issues on .aup files with readonly flag

This section is now closed.
Forum rules
This forum is now closed.

For help with current Audacity, please post to the 2.x. board for your operating system.

Please post feedback about the current 2.x version on the 2.x.feedback board.
Locked
jan.kolar
Posts: 273
Joined: Sat May 24, 2008 7:01 pm
Operating System: Please select

two issues on .aup files with readonly flag

Post by jan.kolar » Mon Jun 02, 2008 10:36 am

Summary:
When "saving as", readonly files should be copied writeable (BGJKcpro).
When readonly block fails to be deleted, a warning shuld be given.
("There were some blockfiles Audacity could note delete to release disk space".) (BGJKro)

code:BGJKro Readonly flags

(Win XP, both 1.2.6.stable and 1.3.5.beta.unicode)

While editing, if some .au are read-only, they get never deleted.
I think that Audacity should inform about this error.
(I tested with changing of bits-per-sample of tracks.)

I think Audacity should respect read-only attributes but give a warning it cannot delete them.

Also: I do not know if Audacity ever modifies block files.
If it does, this probably implies data corruption if
any block files happens to be read-only.

Moreover, when starting 1.3.5. next time, it discovers unused blocks, and offers to delete them,
but if I say yes, it does not delete them (and it does NOT give an error message)



code:BGJKcpro

(Win XP, both 1.2.6.stable and 1.3.5.beta.unicode)

When doing "Save as",
Audacity copies read-only block files as read-only
(though .aup is created writable regardles of the original files r/o attribute).
I think this is should be changed because
1. inconsistent
2. not useful when opening a project that was copied from readonly CD/DVD media by OS-tools
3. not useful if original project was marked read only intentionaly (spare original copy)
4. read-only block files are not subseqeuntly deleted during editing (cf. also BGJKro)

I think newly created copy of project should be fully modifiable.

Addenum regarding 3.
I do not know what is the behaviour of Audacity on unix (Linux etc.).
I suggest it should check the attributes of files
and not remove readonly blockfiles though unix allows that.
What I mean is what unix command 'rm' does.
This should apply both to block files and .aup file.

Second addenum regarding 3.
The following behaviour is on edge:
This is good: If .aup is readonly, it does get renamed to .aup.bak but not deleted.
This is good: If .aup.bak is readonly, it it does NOT get deleted.
This is good but carefully when changing the audacity.
Indeed, If I open *twice* a project with all files r/o, it would be bad to loose .aup file;
at least I have it renamed as .aup.bak

steve
Site Admin
Posts: 81627
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: two issues on .aup files with readonly flag

Post by steve » Mon Jun 02, 2008 6:00 pm

Why would some .au files be read only?
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

jan.kolar
Posts: 273
Joined: Sat May 24, 2008 7:01 pm
Operating System: Please select

Re: two issues on .aup files with readonly flag

Post by jan.kolar » Mon Jun 02, 2008 8:03 pm

stevethefiddle wrote:Why would some .au files be read only?
One reason is above: because copy from r/o media like CD.

Other reason:
Because I decided to protect my pressious project (1 hour of live spoken material, I should not pretend).
Then I wanted to make a copy and work with the copy.
I was going to experiment (I am new to audacity, dont you know?).
But, alas, Do not know, is the .aup's refereferencing to block files relative or absolute ...?
Never mind, lets do it the _best_ and _safest_ way:
Run audacity, "save project as".
The copy of project contains read-only files, too.

steve
Site Admin
Posts: 81627
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: two issues on .aup files with readonly flag

Post by steve » Mon Jun 02, 2008 8:36 pm

I think I am missing the point:

I have a read only text file, I open it in my text editor and try to save it - it doesn't work.
I make a copy of the file and make it read/write - now I can edit it.
What is it that is different in Audacity?

BTW. I don't think that anyone ever recommends saving audacity projects to CD. Unless you are either very lucky, or an experienced user there is a very good chance that the project will never work again. Save backups of your exported WAV files to CD.
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

jan.kolar
Posts: 273
Joined: Sat May 24, 2008 7:01 pm
Operating System: Please select

because Re: why

Post by jan.kolar » Mon Jun 02, 2008 10:51 pm

Steve, No, no, no, I do it as follows:

Procedure B:
I have a read only text file,
I open it in my text editor, do "Save as" under new name.
Now I can edit it.

Why? Because:

<<What is it that is different in Audacity?>>
For text files, or general one-file-documents, both procedures are possible.
For Audacity I can do only B for two purposes:

1.
I do not know internal structure of the multifile documents.
(OK, I know enough if I know it is a also a Unix application.
In windows however, the standard is to reference the files by fullpath.
Having two Excel files that refer each other, can I copy them to a different directory.
Yes I can, end everything looks fine BUT THEY ARE BOTH REFERING THE OLDER COPY, I think)
So therefore I have to use "Save as", the program itself understants its files.

2.Usually I wish to have both in the same directory, so I have to choose different names.
Having xx.aup and xx_data,
how do I copy (or, rename) to yy.aup?
I have to create yy_date, OK so far,
and edit yy.aup (!!!). Then I have to check if blockfiles contain some references
and cross finger.
If something is wrong, I do not loose the copy only, but I destroy the original as well!


<<BTW. I don't think that anyone ever recommends saving audacity projects to CD.>>

I guess Audacity can be released in future together with example .aup files on the CD !
This is the optimal format for conferences, exhibitions, musical events....
Since it does not need intallator to work, neither examples will have to depend on it.

And its perhaps the best way to give to singer from my band (BTW, I have no band)
so he/she can try at home, and the can hear himself together with the band.
I it cheaper than to give away my USB key... (I have USB key ;) )

<<Unless you are either very lucky, or an experienced user there is a very good chance that the project
will never work again. Save backups of your exported WAV files to CD>>

No, no, no, if I copy to CD and then copy back, and it is exatly the same after copying back !!! After all, it is a FILE !
Well, I should not forget to remove the r/o flag.

(For consistency of my writing: at the moment of writing, I already knew or believed, that I can copy
.aup together with _data and this retains its integrity.)

jan.kolar
Posts: 273
Joined: Sat May 24, 2008 7:01 pm
Operating System: Please select

check for renamed .aup files -- suggestion

Post by jan.kolar » Tue Jun 03, 2008 12:03 am

This is a suggestion, that could help novice user.

If yy.aup is opened, that referes to xx_data block directory,
user should be warned, given an advice,
and offered to cancel opening the project file.

(Probably all is possible, the following might be the most probable situations
1. user renamed xx.aup to yy.aup.
It is 'safe' but certainly not advisible to proceed.
2. user copied xx.aup and xx_data to yy.aup and yy_data.
It is totally desctructive to preceed, both .aup are refering to the same block data !
)

------

off topic: Copying or linking on Import

That all makes return also to the question whether
importing files should mean by default copying or linking.
I have a strong opinion about the current way of silent linking
is not acceptable. And there are several (easy?) ways how to solve that.
1. If menu says "Import", the file should be copied,
unless myself chooses some other option explicitly
The menu can also contain item "Link an external file".
or "Import by linking external file"
or check-item "Fast Import by linking" (default no) {{typo correction Fact -> Fast, JK}}
(or opposite "Copy the audio while importing" with default yes).
2. After clicking Import and selecting the files,
user can answer a dialog, with options copy / link (varA)
with check box "make this permanent choice" (varB)
and advise that the permanent choice can be changed in preferences.
(Preferences: new check "Always ask" (negation of varB) and old one Copy... (varA) )
3. As regards "consider anything else needed as a result e.g. space checking, dialogue asking user what to do if insufficient space" from wiki ( http://audacityteam.org/wiki/index.php? ... _after_1.4 ):
This is not relevant objection, because if I import by linking and Amplify by 0dB (or something less trivial)
all possible checks have do be done anyway. And if anything fails, I think the action should be the same:
give a warning and cancel the action.
Last edited by jan.kolar on Sun Jun 08, 2008 12:10 pm, edited 1 time in total.

steve
Site Admin
Posts: 81627
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: two issues on .aup files with readonly flag

Post by steve » Tue Jun 03, 2008 12:44 am

jan.kolar wrote:Steve, No, no, no, I do it as follows:
OK, I did say that perhaps I was missing your point :)

I see what you mean now.
jan.kolar wrote:And its perhaps the best way to give to singer from my band (BTW, I have no band)
so he/she can try at home, and the can hear himself together with the band.
I it cheaper than to give away my USB key...
I do something like this quite often (I do have a band), but not all band members use Audacity, so I Export tracks as Ogg or FLAC files, upload to our web space and e-mail them a link (NOT mp3 because that messes up the timings and tracks will not line up exactly). Other band members can then import the tracks into Audacity, Cool Edit Pro, Audition, or whatever program they use (I gave them all copies of OggDrop and FlacDrop to make converting back to wav easy and quick).
jan.kolar wrote:I already knew or believed, that I can copy
.aup together with _data and this retains its integrity.
Yes it can be done successfully, but there are issues that the user must be aware of to avoid problems. Problems may include this permission issue, and if data outside of the data folder is referenced by the project (depending on settings in "Edit > Preferences > Audio Files"), and a relatively small data error on the disk can cause major problems with the project....
----------------------------
We've got a bit out of sync with our messages - you must be faster at typing jan :)
jan.kolar wrote:1. If menu says "Import", the file should be copied,
unless myself chooses some other option explicitly
The menu can also contain item "Link an external file".
or "Import by linking external file"
or check-item "Fact Import by linking" (default no)
This choice can be made in "Edit > Preferences > Audio Files" (Audacity 1.3.x)
"Edit > Preferences > File Formats" (Audacity 1.2.x).
There is a previous discussion somewhere on the forum about which should be the default option, and really it depends on what the user is doing. For making relatively minor changes to large files (such as splitting an LP recording, or trimming an audio book), most users prefer the linking method. For more involved editing shorter, but more complex projects (such as editing and mixing a multi-track band recording) the safer but slower "import" method is generally preferred.

Documentation about this is here (v.1.2) http://audacityteam.org/manual-1.2/prefs.html
and here (v.1.3.5) http://audacityteam.org/manual/index.ph ... references
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

jan.kolar
Posts: 273
Joined: Sat May 24, 2008 7:01 pm
Operating System: Please select

Re: two issues on .aup files with readonly flag

Post by jan.kolar » Tue Jun 03, 2008 12:37 pm

stevethefiddle wrote: This choice can be made in "Edit > Preferences > Audio Files" (Audacity 1.3.x)
"Edit > Preferences > File Formats" (Audacity 1.2.x).

There is a previous discussion somewhere on the forum about which should be the default option, and really it depends on what the user is doing. For making relatively minor changes to large files (such as splitting an LP recording, or trimming an audio book), most users prefer the linking method. For more involved editing shorter, but more complex projects (such as editing and mixing a multi-track band recording) the safer but slower "import" method is generally preferred.

Documentation about this is here (v.1.2) http://audacityteam.org/manual-1.2/prefs.html
and here (v.1.3.5) http://audacityteam.org/manual/index.ph ... references

Steve, All that I know !
And still it does not change my opion.
But how much did I know when importing the first file?

Locked