export failed transfers in human readable paths

Need help with FileZilla Client? Something does not work as expected? In this forum you may find an answer.

Moderator: Project members

Post Reply
Message
Author
imthenachoman
500 Syntax error
Posts: 13
Joined: 2018-12-06 13:48
First name: Anchal
Last name: Nigam

export failed transfers in human readable paths

#1 Post by imthenachoman » 2018-12-12 10:56

For reasons I do not understand, when you export the transfer lists it uses some funky format for remote folders/files.

For example, for this remote file:

Code: Select all

/mnt/usb/path/to/some folder/file.txt
This is what the XML export will have:

Code: Select all

<File>
	<LocalFile>C:\Users\me\path\to\some folder\file.txt</LocalFile>
	<RemoteFile>file.txt</RemoteFile>
	<RemotePath>1 0 4 mnt 6 usb 14 path 2 to 11 some folder</RemotePath>
	<Download>1</Download>
	<Size>1234567890</Size>
	<DataType>1</DataType>
</File>
And those numbers between each folder are not always the same.

So I have two questions:
  • Why is this? Why not use use a normal format?
  • How can I convert the above into a normal format? I basically want a list of all the files that failed to transfer.

User avatar
botg
Site Admin
Posts: 35509
Joined: 2004-02-23 20:49
First name: Tim
Last name: Kosse

Re: export failed transfers in human readable paths

#2 Post by botg » 2018-12-12 12:21

Not all servers have the same syntax for paths. Converting a path into a human-readable representation and back into something the machine understands can lose information on some of the more exotic path syntaxes. That's why the path is stored in a machine-readable form.

First number denotes the type. It's followed by length-value pairs. First pair denotes the prefix, which is empty on contemporary syntaxes.

imthenachoman
500 Syntax error
Posts: 13
Joined: 2018-12-06 13:48
First name: Anchal
Last name: Nigam

Re: export failed transfers in human readable paths

#3 Post by imthenachoman » 2018-12-12 13:53

That make sense but I have a few follow up questions/comments:
  • Why doesn’t it do that for the local files? If one is exporting to import on a different OS then its likely the local OS might be different too.
  • For the example I pasted, I changed the folder names for security reasons so the formula you provided doesn’t work there. I’m not in front of my home computer so I wanted to confirm with you my understanding of the formula. The first number, 1, can be tells me the field seperator is /. The next number, 0, can be ignored. The next number tells the number of characters for the folder name. Right?
  • Is there any script/fast way to convert the remote paths/files to human readable format? I have 1000+ files that won’t transfer because of illegal file names so I was hoping to export them as a list so I can tar them up on the remote side.
And I will see if I can find out how to submit a feature/enhancement request to add a configuration option to not convert the remote files/paths to human readable and/or offer a way to export transfer lists as a text file with human readable paths.

User avatar
botg
Site Admin
Posts: 35509
Joined: 2004-02-23 20:49
First name: Tim
Last name: Kosse

Re: export failed transfers in human readable paths

#4 Post by botg » 2018-12-12 14:52

Why doesn’t it do that for the local files? If one is exporting to import on a different OS then its likely the local OS might be different too.
Well, strictly speaking exporting local paths makes no sense at all as the paths are local to the machine they get exported on.
The first number, 1, can be tells me the field seperator is /. The next number, 0, can be ignored.
For prefix-less types, such as 1, the prefix length is always 0.
The next number tells the number of characters for the folder name. Right?
Yes.

And I will see if I can find out how to submit a feature/enhancement request to add a configuration option to not convert the remote files/paths to human readable and/or offer a way to export transfer lists as a text file with human readable paths.
The exported file is not meant to be human-readable. It is meant to be imported by FileZilla.

imthenachoman
500 Syntax error
Posts: 13
Joined: 2018-12-06 13:48
First name: Anchal
Last name: Nigam

Re: export failed transfers in human readable paths

#5 Post by imthenachoman » 2018-12-12 15:16

Understood but there is a need for it to be human readable to address errors/situations like mine. I am sure I'm not the only one.

Any word on an easy way to translate the XML RemotePath attribute to human readable so I can finish my transfers?

User avatar
botg
Site Admin
Posts: 35509
Joined: 2004-02-23 20:49
First name: Tim
Last name: Kosse

Re: export failed transfers in human readable paths

#6 Post by botg » 2018-12-12 16:17

Basic string processing, an easy task in every procedural programming language. Unless you want to deal with exotic IBM mainframes you already have all the information you need to write a simple program to do this.

imthenachoman
500 Syntax error
Posts: 13
Joined: 2018-12-06 13:48
First name: Anchal
Last name: Nigam

Re: export failed transfers in human readable paths

#7 Post by imthenachoman » 2018-12-12 16:48

Laf. Yes. But I don't want to recreate the wheel. That's why I was first checking if something already exists before I write one.

Post Reply