POV-Ray : Newsgroups : povray.general : "Failed to save file:" Server Time
25 Dec 2024 01:54:31 EST (-0500)
  "Failed to save file:" (Message 1 to 10 of 18)  
Goto Latest 10 Messages Next 8 Messages >>>
From: Charles C
Subject: "Failed to save file:"
Date: 2 Nov 2007 03:34:55
Message: <472ae12f@news.povray.org>
I've been assuming (correctly) that this was a known issue and I haven't 
worried too much about it, so it's taken me quite a while to get around 
to asking or looking into it at all.   Anyway I get:

"Failed to save file:

The process cannot access the file because it is being used by another 
process."

...in a self-compiled version of POV-Ray 3.6.0 for Windows which I've 
been using for a while now to avoid the spline / token_count issue.

The only entry I see on the server is this partial-thread:
http://news.povray.org/povray.beta-test/thread/%3C430daeda@news.povray.org%3E/?ttop=249422&toff=150

...in which Chris mentions it being fixed now, although that's for the 
beta.   I was just wondering if  I could find out the secret to Change 
3003 if it is indeed the same thing:

Change 3003 on 2004/07/22 by thorsten@host27
   Fixes file "saving" bug thanks to Massimo Valentini

Or is it just a matter of installing a newer version of the editor dll 
or something?

Thanks in advance!
Charles


Post a reply to this message

From: Alain
Subject: Re: "Failed to save file:"
Date: 2 Nov 2007 13:44:07
Message: <472b6ff7$1@news.povray.org>
Charles C nous apporta ses lumieres en ce 2007/11/02 04:34:
> I've been assuming (correctly) that this was a known issue and I haven't 
> worried too much about it, so it's taken me quite a while to get around 
> to asking or looking into it at all.   Anyway I get:
> 
> "Failed to save file:
> 
> The process cannot access the file because it is being used by another 
> process."
> 
> ...in a self-compiled version of POV-Ray 3.6.0 for Windows which I've 
> been using for a while now to avoid the spline / token_count issue.
> 
> The only entry I see on the server is this partial-thread:
>
http://news.povray.org/povray.beta-test/thread/%3C430daeda@news.povray.org%3E/?ttop=249422&toff=150

> 
> 
> ...in which Chris mentions it being fixed now, although that's for the 
> beta.   I was just wondering if  I could find out the secret to Change 
> 3003 if it is indeed the same thing:
> 
> Change 3003 on 2004/07/22 by thorsten@host27
>   Fixes file "saving" bug thanks to Massimo Valentini
> 
> Or is it just a matter of installing a newer version of the editor dll 
> or something?
> 
> Thanks in advance!
> Charles
Are you on Windows Vista? Is POV-Ray installed in the "program files" folder?
If so, Vista don't let you edit/change/save files in that location.
The solution is simply to install into a different folder. Or you can redirect 
all files to a user provided alternate folder.

-- 
Alain
-------------------------------------------------
Creationism: God made all shit.


Post a reply to this message

From: Charles C
Subject: Re: "Failed to save file:"
Date: 2 Nov 2007 17:22:59
Message: <472ba343@news.povray.org>
Alain wrote:

> Are you on Windows Vista? Is POV-Ray installed in the "program files" 
> folder?
> If so, Vista don't let you edit/change/save files in that location.
> The solution is simply to install into a different folder. Or you can 
> redirect all files to a user provided alternate folder.
> 


No, sorry I should have said this is XP.  I'm well aware of the Vista 
issues though, and this is not that.  See the link.

Thanks,
Charles


Post a reply to this message

From: Samuel Benge
Subject: Re: "Failed to save file:"
Date: 2 Nov 2007 20:09:08
Message: <472bca34@news.povray.org>
Charles C wrote:
> I've been assuming (correctly) that this was a known issue and I haven't 
> worried too much about it, so it's taken me quite a while to get around 
> to asking or looking into it at all.   Anyway I get:
> 
> "Failed to save file:
> 
> The process cannot access the file because it is being used by another 
> process."

Whenever I have received that message it was because the file was still 
open in some other application.

Try ctrl+alt+delete to see if there's something running in the 
background which may be using the file.

Sam


Post a reply to this message

From: Nicolas Alvarez
Subject: Re: "Failed to save file:"
Date: 2 Nov 2007 21:04:56
Message: <472bd748$1@news.povray.org>

> Charles C wrote:
>> I've been assuming (correctly) that this was a known issue and I 
>> haven't worried too much about it, so it's taken me quite a while to 
>> get around to asking or looking into it at all.   Anyway I get:
>>
>> "Failed to save file:
>>
>> The process cannot access the file because it is being used by another 
>> process."
> 
> Whenever I have received that message it was because the file was still 
> open in some other application.
> 
> Try ctrl+alt+delete to see if there's something running in the 
> background which may be using the file.

Or get Sysinternals Process Explorer which is a far more powerful task 
manager, it can actually tell you what files each app has open (and 
search for a filename to see *which* app has it open).


Post a reply to this message

From: Alain
Subject: Re: "Failed to save file:"
Date: 2 Nov 2007 22:16:19
Message: <472be803$1@news.povray.org>
Charles C nous apporta ses lumieres en ce 2007/11/02 18:22:
> 
> 
> Alain wrote:
> 
>> Are you on Windows Vista? Is POV-Ray installed in the "program files" 
>> folder?
>> If so, Vista don't let you edit/change/save files in that location.
>> The solution is simply to install into a different folder. Or you can 
>> redirect all files to a user provided alternate folder.
>>
> 
> 
> No, sorry I should have said this is XP.  I'm well aware of the Vista 
> issues though, and this is not that.  See the link.
> 
> Thanks,
> Charles
OK
Check if the file exist and if it's read only or system. Same with the folder 
itself.
Can you open the offending file, edit it with another application and save it back?
Is the file opened by any other application?
Do you have ownership of the file? I had some instances where files and folders 
on my system got eroneous ownership, with only one user. Some folders/files had 
been set with an owner whose name was just a bunch of random characters.
Is you drive full?

-- 
Alain
-------------------------------------------------
To the world you may be one person, but to one person you may be the world.


Post a reply to this message

From: Charles C
Subject: Re: "Failed to save file:"
Date: 2 Nov 2007 23:23:22
Message: <472bf7ba@news.povray.org>
Nicolas Alvarez wrote:
> Or get Sysinternals Process Explorer which is a far more powerful task 
> manager, it can actually tell you what files each app has open (and 
> search for a filename to see *which* app has it open).

This is pretty cool.  Thanks for telling me about it.  Now to run into 
the problem and see what it can tell me.  I'm pretty sure it'll tell me 
that POV-Ray is using the file but this'll show it for sure.

Charles


Post a reply to this message

From: Charles C
Subject: Re: "Failed to save file:"
Date: 2 Nov 2007 23:25:19
Message: <472bf82f@news.povray.org>
Samuel Benge wrote:

> Whenever I have received that message it was because the file was still 
> open in some other application.

I'm pretty sure it's just POV-Ray.  Re-starting POV-Ray and not changing 
  anything else lets me make the change and save again.
Charles


Post a reply to this message

From: Charles C
Subject: Re: "Failed to save file:"
Date: 2 Nov 2007 23:34:41
Message: <472bfa61@news.povray.org>
Alain wrote:
> OK
> Check if the file exist and if it's read only or system. Same with the 
> folder itself.
> Can you open the offending file, edit it with another application and 
> save it back?
> Is the file opened by any other application?
> Do you have ownership of the file? I had some instances where files and 
> folders on my system got eroneous ownership, with only one user. Some 
> folders/files had been set with an owner whose name was just a bunch of 
> random characters.
> Is you drive full?
> 

Thanks Alain.  This happens with any non-read-only file in my P-Scenes 
directory (which btw is not next to the installation directory) where I 
continually save and re-save as I edit and test and edit and test.  It 
seems to happen with just POV-Ray running, and maybe Windows Explorer. 
The drive has dozens of gigs left.  It's pretty reproducable when it 
happens, but it doesn't always happen.  It only happens following a 
parse-error and an attempted *minor* edit and save.

Here's a better version of the link.  Hopefully it'll work a little better:
http://news.povray.org/povray.beta-test/thread/%3C430daeda@news.povray.org%3E/?ttop=249422&toff=150

Charles


Post a reply to this message

From: Jan Dvorak
Subject: Re: "Failed to save file:"
Date: 3 Nov 2007 02:24:14
Message: <472c221e@news.povray.org>
Charles C napsal(a):
> 
> 
> Samuel Benge wrote:
> 
>> Whenever I have received that message it was because the file was 
>> still open in some other application.
> 
> I'm pretty sure it's just POV-Ray.  Re-starting POV-Ray and not changing 
>  anything else lets me make the change and save again.
> Charles
It seems to me POVray doesn't close the file handle and tries to open a 
new one. This fails because there cannot be two file handles to the same 
file if one of them is a writable one.
I've never seen the POVray code but if handle closing depends on a 
garbage collector+destructor then this is certainly wrong. In this case 
either force GC before opening a file or, if that fails, trace the 
references to it (if you don't mind debugging yourself).
You can use Sysinternals taskmanager to see if the image handle is still 
open by POVray.


Post a reply to this message

Goto Latest 10 Messages Next 8 Messages >>>

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.