ZIP Support (so I can finally retire "PowerDersk Pro")
Re: ZIP Support (so I can finally retire "PowerDersk Pro")
I can :-( But the number of error messages during the compressing decreased to 2. Before it was many.
-
admin
- Site Admin
- Posts: 64836
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
Re: ZIP Support (so I can finally retire "PowerDersk Pro")
Is your machine rather slow? Or are you working on a network drive?
FAQ | XY News RSS | XY X
Re: ZIP Support (so I can finally retire "PowerDersk Pro")
I don't consider it slow. Older Pentium E6300, but dual-core 2.8 GHz.admin wrote:Is your machine rather slow? Or are you working on a network drive?
Re: ZIP Support (so I can finally retire "PowerDersk Pro")
There is another way that shows that XYplorer is doing post processing faster than it should. I just made a simplye Test.xys:
and put it in the script directory. Download: http://download.xnview.com/XnViewMP-win.zip and extract it somewhere. Then select that folder and then load the script. Drag the Windows zipping progress window out of the way and then you will see that the msg window pops up before the zipping even completely finish.
In terms of LittleBiG, I cannot reproduce it with the beta (on the old one yes). Going to do more testing later as well to see if it can be reproduce again.
EDIT: A more practical example is
EDIT: Nevermind. It seems to work for me now.
EDIT2: Nevermind. Is it normal that each line of the script will normally try to run one after another quickly? For example:
The Delete command here will try to run even before the BackutpTo command have not finished. As a result, I always get BackupTo/Moveto/Related Command to fail because the file gets deleted before it any of the copy type function finish. I had to add a Wait command here so that it won't happen.
Code: Select all
Zip_Add("Test.zip");
Msg "Before Zip"In terms of LittleBiG, I cannot reproduce it with the beta (on the old one yes). Going to do more testing later as well to see if it can be reproduce again.
EDIT: A more practical example is
Code: Select all
Zip_Add("%DesktopReal%\XnViewMP.zip","%DesktopReal%\XnViewMP\");
MoveTo "%DesktopReal%\Apps\", "%DesktopReal%\XnViewMP.zip";Code: Select all
Zip_Add("%DesktopReal%\XnViewMP.zip","%DesktopReal%\XnViewMP\");
//MoveTo "%DesktopReal%\Apps\", "%DesktopReal%\XnViewMP.zip";
BackupTo "%DesktopReal%\Apps\", "%DesktopReal%\XnViewMP.zip",1,0,0,1,1,2,0;Code: Select all
BackupTo $Archive_Path, "<xypath>\$Name_Pattern",1,0,0,1,1,2,0;
//[on_collision],[preserve_dates],[create_log],[pop_stats],[skip_junctions],[verify],[show_progress]
Wait 1000;
Delete 1, 0, "<xypath>\$Name_Pattern";
Last edited by Enternal on 20 Nov 2013 23:32, edited 3 times in total.
Re: ZIP Support (so I can finally retire "PowerDersk Pro")
here is compressing process:
- Attachments
-
- TodayIssue8.gif (1.04 MiB) Viewed 2527 times
-
admin
- Site Admin
- Posts: 64836
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
Re: ZIP Support (so I can finally retire "PowerDersk Pro")
Probably because of background processing. This will help:Enternal wrote:EDIT2: Nevermind. Is it normal that each line of the script will normally try to run one after another quickly? For example:The Delete command here will try to run even before the BackutpTo command have not finished. As a result, I always get BackupTo/Moveto/Related Command to fail because the file gets deleted before it any of the copy type function finish. I had to add a Wait command here so that it won't happen.Code: Select all
BackupTo $Archive_Path, "<xypath>\$Name_Pattern",1,0,0,1,1,2,0; //[on_collision],[preserve_dates],[create_log],[pop_stats],[skip_junctions],[verify],[show_progress] Wait 1000; Delete 1, 0, "<xypath>\$Name_Pattern";
Code: Select all
+ Scripting commands enhanced:
- setting, settingp
New named argument "backgroundfileops"
0 = Disable background processing of file operations
1 = Enable background processing of file operations
Example:
::setting "backgroundfileops", 1;
FAQ | XY News RSS | XY X
-
admin
- Site Admin
- Posts: 64836
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
Re: ZIP Support (so I can finally retire "PowerDersk Pro")
ZipFolder technology is not perfect. One day I will write my own zipping code.
FAQ | XY News RSS | XY X
Re: ZIP Support (so I can finally retire "PowerDersk Pro")
Ah awesome! Thanks!
I do have background operations on but not for the delete operation so:should solve all my problems. 
Question though, in the manual:
I do have background operations on but not for the delete operation so:
Code: Select all
Setting "BackgroundedFileOps", 31;Question though, in the manual:
What do you mean by this?1 [x] Backup (currently unused; has yet to be coded)
Hehe. We all look forward to that one day. Your own custom contro... I mean zip code (not to be confused with the US stats Zip Codes).admin wrote:ZipFolder technology is not perfect. One day I will write my own zipping code.
Re: ZIP Support (so I can finally retire "PowerDersk Pro")
Aaargh. This is my code that I like to use to backup my Data folder:
I like the move the Thumbnails folders out of the way because sometimes it's over 250 MB. Don't need it to be backed up.
So it backups the file fine (although once in a while, it pops up a renaming error since the file is still being zipped) yet in the Background Jobs log, it always show something like:
Completed 3mins ago after 1 sec (Canceled or Failed)
Basically it said that it failed but it did not. I think that's a bug or something.
Code: Select all
Setting "BackgroundFileOps", 1;
Setting "BackgroundedFileOps", 31;
MoveTo "<xypath>", "<xydata>\Thumbnails\";
$Tab_Ini = FormatList(FolderReport("files","r",<xydata>,"r",,"|"),f,"|",*tab*.ini);
If $Tab_Ini != "" {
Delete 1, 0, "$Tab_Ini";
}
Zip_Add("<xypath>\Data.zip", "<xydata>");
//Wait 2500;
MoveTo "<xydata>", "<xypath>\Thumbnails\";
$Archive_Path = "\\CrimsonRose\Public\Documents\XYplorer\Backup";
$Date = Property("Write", "<xypath>\Data.zip");
$Date = FormatDate("$Date", "mm-dd-yyyy");
$Hash = Hash("crc32", "<xypath>\Data.zip", "1");
$Name_Pattern = "Data_%ComputerName%_[$Date]_[$Hash].zip";
RenameItem($Name_Pattern, "<xypath>\Data.zip");
BackupTo $Archive_Path, "<xypath>\$Name_Pattern",1,0,0,1,1,2,0;
//[on_collision],[preserve_dates],[create_log],[pop_stats],[skip_junctions],[verify],[show_progress]
//Wait 2500;
Delete 1, 0, "<xypath>\$Name_Pattern";
AttrStamp("ar", "2", "$Archive_Path\Data_%ComputerName%_[$Date]_[$Hash].rar");So it backups the file fine (although once in a while, it pops up a renaming error since the file is still being zipped) yet in the Background Jobs log, it always show something like:
Completed 3mins ago after 1 sec (Canceled or Failed)
Basically it said that it failed but it did not. I think that's a bug or something.
-
admin
- Site Admin
- Posts: 64836
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
Re: ZIP Support (so I can finally retire "PowerDersk Pro")
Does it also happen when you step through it?
FAQ | XY News RSS | XY X
Re: ZIP Support (so I can finally retire "PowerDersk Pro")
It works perfectly when I step through it. It's pretty much like adding a "Wait" at every other line isn't it? When you step through it, it "Waits" until it gets feedback from you to continue. In the case that you run it straight, it will "try to do everything as fast as it can" in which it then fails. It seems that even though background ops is on with all settings enabled, it still wants to delete the file a bit too early. Without backgroundops, it delete files waay to early so backupto completely failed (no final file in backup location) but with backgroundops, it's able to copy it successfuly but the report shows that it failed. Probably checksum errors or something?
-
admin
- Site Admin
- Posts: 64836
- Joined: 22 May 2004 16:48
- Location: Win8.1, Win10, Win11, all @100%
- Contact:
Re: ZIP Support (so I can finally retire "PowerDersk Pro")
Well, actually you should do this:
= Turn them OFF, because they run async, creating the problems you see.
Code: Select all
Setting "BackgroundFileOps", 0;FAQ | XY News RSS | XY X
Re: ZIP Support (so I can finally retire "PowerDersk Pro")
Ah! I did not understand background ops so now that I read it again, I understand how it works. Anyway, that script now works perfectly! Rename does not rename the file either until zip_add() finish. That's awesome! Thank you!
XYplorer Beta Club