Propeller Tool has problems with VirtualStore
RossH
Posts: 5,463
I've struck this problem yet again, so I am again posting to let others know that the Propeller tool does not "play nice" with Micro$oft's VirtualStore functionality.
For those who don't know about VirtualStore, it is a mind-bogglingly stupid "feature" introduced by Micro$oft in Vista, but it also seems to infect Windows 7, and will no doubt infect Windows 8 as well. It is apparently intended to support programs that need to write to files in certain "protected" folders (such as the "Program Files" folders).
If you try to write to a file protected by VirtualStore, then instead of modifying the real file, VirtualStore will sometimes (and only sometimes) create a second copy of the file instead. Unfortunately, this means that two different programs can end up seeing two different versions of the same file.
The problem typically occurs when you use two different programs to access the same file, and especially if one of them is a "legacy" program such as the Propeller Tool. In my case I tend to edit my Spin programs in a modern text editor - but then I may use the legacy Parallax Propeller tool to compile them. If you do this you can end up with two different files - e.g. you edit one version of the file, but end up compilng the other. Confusing? You bet!
In the most recent instance of this problem, every other program I have would find the version of the file in the Program Files folder - but the Propeller Tool would only find an older (and incorrect) version of the file stored in the VirtualStore folder. The end result was that the program would run correctly when compiled under Homespun, but not when compiled with the Propeller Tool - and until I realized what was going on, nothing I did seemed able to fix it.
This kind of thing seems to happen at random, but once it has occurred it can be very difficult to track down. The only real solution I have found is to disable VirtualStore.
There are many reports of this kind of problem on the web - but here is one that is short and clear, and may help you resolve the problem if it hits you. I would recommend at least perioidically looking in the VirtualStore folder and seeing what files VirtualStore has squirrelled away in there. You will find that even Windows itself sometimes puts files in there.
Ross.
For those who don't know about VirtualStore, it is a mind-bogglingly stupid "feature" introduced by Micro$oft in Vista, but it also seems to infect Windows 7, and will no doubt infect Windows 8 as well. It is apparently intended to support programs that need to write to files in certain "protected" folders (such as the "Program Files" folders).
If you try to write to a file protected by VirtualStore, then instead of modifying the real file, VirtualStore will sometimes (and only sometimes) create a second copy of the file instead. Unfortunately, this means that two different programs can end up seeing two different versions of the same file.
The problem typically occurs when you use two different programs to access the same file, and especially if one of them is a "legacy" program such as the Propeller Tool. In my case I tend to edit my Spin programs in a modern text editor - but then I may use the legacy Parallax Propeller tool to compile them. If you do this you can end up with two different files - e.g. you edit one version of the file, but end up compilng the other. Confusing? You bet!
In the most recent instance of this problem, every other program I have would find the version of the file in the Program Files folder - but the Propeller Tool would only find an older (and incorrect) version of the file stored in the VirtualStore folder. The end result was that the program would run correctly when compiled under Homespun, but not when compiled with the Propeller Tool - and until I realized what was going on, nothing I did seemed able to fix it.
This kind of thing seems to happen at random, but once it has occurred it can be very difficult to track down. The only real solution I have found is to disable VirtualStore.
There are many reports of this kind of problem on the web - but here is one that is short and clear, and may help you resolve the problem if it hits you. I would recommend at least perioidically looking in the VirtualStore folder and seeing what files VirtualStore has squirrelled away in there. You will find that even Windows itself sometimes puts files in there.
Ross.
Comments
Also, don't store your spin files in the program files folder. Instead put them someplace like your user folder or documents folder or something.
Hi Roy,
I don't tend to use the Propeller Tool very often except when I am working with Spin programs - I was just warning those who do. The Propeller Tool stores Spin files in the Program Files folder - for example, it installs the libraries and examples there. The same problem may not exist with other programs that don't do that, but it certainly does for the Propeller Tool.
Ross.
P.S. By "modern" editor, I really just meant any non-legacy editor. For instance, Notepad always seems to edit the real file, whereas the Propeller Tool always seems to edit the VirtualStore file.
Usually, I'll copy the whole Prop Tool folder with all the drivers somewhere else so this kind of trouble doesn't happen...
Does the Prop Tool find the library okay? What if you want to add a file to the library will the Prop Tool find the non-program files version?
I frequently have stuff end up in the virtual store which is a big pain. I have a shortcut on my desktop to "C:\Users\Duane\AppData\Local\VirtualStore\Program Files (x86)\Parallax Inc\Propeller Tool v1.2.7 (R2)" so I can find my recently saved files.
I'm off you read the link RossH gave in post #1. Thanks.
works perfectly in Win7 if you do the above. :-) Virtual store is only about accessing programs from the program files, or windows directory.
And you can avoid the whole mess by keeping your programs in your /user location.
Linux has had a system that it a lot simpler to enforce this with Unix rights. Creating a virtual duplicate is just going to confound users that never catch on to the fact that there is a virtual duplicate, or a way to avoid creating one.
It solves the problem where an application stores configuration files (i.e. userconfig.ini) and registry settings in its Program files and HKLM hive locations respectively, and doesn't account for multiple users of the app by storing settings in the users profile and the HKCU hive, as it should do.
Essentially, Microsoft is trying to protect you from badly written applications. I am not suggesting that the propeller tool is a bad application BTW.
But what about files you want to add to the library folder? I don't see an option of changing where the Prop Tool looks for the library folder. So any object you want accessible from multiple projects (such as F32) will need to be the in the program files' "library" folder. The Prop Tool will only find child objects from within the same folder as the parent object or the library folder.
I frequently save a different version of one of my library objects and these often end up in the VirtualStore.
So the process would look like:
-> Try the parallax library
-> Try the user library folder
-> Try the current directory
But, what I do is keep any modified files in a project folder. I have a different folder for each project I'm working on...