Character encoding and line ending in OSSubprocess

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Character encoding and line ending in OSSubprocess

Nicolas Passerini
Hi, I am using OSSubprocess for throwing git commands (using Iceberg with the GitFileTree backend), and I find that  characters (for example spanish áéíóúñ) and line endings are not correctly encoded/decoded.

Does someone have the same problem? 
Are we doing something wrong?

I am working on linux, and latest Pharo 6.

With Guille Polito we tried some time ago a little fix that seemed to work but maybe it needs more testing, and before investing more time on it I thought that it would be a good idea to have more opinions on the topic.

Reply | Threaded
Open this post in threaded view
|

Re: Character encoding and line ending in OSSubprocess

Thierry Goubier
Hi Nicolas,

does this happens when you are using one of the GitFileTree generated command or when you use directly the command line api (runGitCommand and friends)? Does this happens with OSProcess as well?

Thierry

2016-08-22 15:09 GMT+02:00 Nicolas Passerini <[hidden email]>:
Hi, I am using OSSubprocess for throwing git commands (using Iceberg with the GitFileTree backend), and I find that  characters (for example spanish áéíóúñ) and line endings are not correctly encoded/decoded.

Does someone have the same problem? 
Are we doing something wrong?

I am working on linux, and latest Pharo 6.

With Guille Polito we tried some time ago a little fix that seemed to work but maybe it needs more testing, and before investing more time on it I thought that it would be a good idea to have more opinions on the topic.


Reply | Threaded
Open this post in threaded view
|

Re: Character encoding and line ending in OSSubprocess

Nicolas Passerini

On Mon, Aug 22, 2016 at 3:31 PM, Thierry Goubier <[hidden email]> wrote:
does this happens when you are using one of the GitFileTree generated command or when you use directly the command line api (runGitCommand and friends)?

I think that it happens in both cases, the most obvious is that it fails to bring my github name, which happens to have an "á".
But I will check your idea, to be sure.
 
Does this happens with OSProcess as well?

I am not sure about this, can I use gitfiletree with OSProcess, how can I test it?

Reply | Threaded
Open this post in threaded view
|

Re: Character encoding and line ending in OSSubprocess

Thierry Goubier


2016-08-22 16:08 GMT+02:00 Nicolas Passerini <[hidden email]>:

On Mon, Aug 22, 2016 at 3:31 PM, Thierry Goubier <[hidden email]> wrote:
does this happens when you are using one of the GitFileTree generated command or when you use directly the command line api (runGitCommand and friends)?

I think that it happens in both cases, the most obvious is that it fails to bring my github name, which happens to have an "á".

Hum, I may be missing a string convert on some arguments of the git clone command...
 
But I will check your idea, to be sure.
 
Does this happens with OSProcess as well?

I am not sure about this, can I use gitfiletree with OSProcess, how can I test it?


Just load OSProcess before loading GitFileTree, it should notice it and avoid loading OSSubprocess.

Thierry

Reply | Threaded
Open this post in threaded view
|

Re: Character encoding and line ending in OSSubprocess

Nicolas Passerini


On Mon, Aug 22, 2016 at 4:29 PM, Thierry Goubier <[hidden email]> wrote:


2016-08-22 16:08 GMT+02:00 Nicolas Passerini <[hidden email]>:

On Mon, Aug 22, 2016 at 3:31 PM, Thierry Goubier <[hidden email]> wrote:
does this happens when you are using one of the GitFileTree generated command or when you use directly the command line api (runGitCommand and friends)?

I think that it happens in both cases, the most obvious is that it fails to bring my github name, which happens to have an "á".

Hum, I may be missing a string convert on some arguments of the git clone command...
 
Ok, if that's the way to go I can try to fix it and send you a pull request. 
I was thinking if it can not be resolved by OSSubprocess itself. 
 
But I will check your idea, to be sure.
 
Does this happens with OSProcess as well?

I am not sure about this, can I use gitfiletree with OSProcess, how can I test it?


Just load OSProcess before loading GitFileTree, it should notice it and avoid loading OSSubprocess.


Ok, I will try that, thankyou. 
Reply | Threaded
Open this post in threaded view
|

Re: Character encoding and line ending in OSSubprocess

Mariano Martinez Peck
Hi Nico,

I am on holidays now, so my answer will be short. I would like to provide some encoding facility if you think if may make sense to provide that at that level. This issue is the second time it appeared, that's why I am asking.

Whenever you make the PR, can I see the changes and see if I could put that in OSSubprocess itself ?

Thanks


On Tue, Aug 23, 2016 at 5:00 AM, Nicolas Passerini <[hidden email]> wrote:


On Mon, Aug 22, 2016 at 4:29 PM, Thierry Goubier <[hidden email]> wrote:


2016-08-22 16:08 GMT+02:00 Nicolas Passerini <[hidden email]>:

On Mon, Aug 22, 2016 at 3:31 PM, Thierry Goubier <[hidden email]> wrote:
does this happens when you are using one of the GitFileTree generated command or when you use directly the command line api (runGitCommand and friends)?

I think that it happens in both cases, the most obvious is that it fails to bring my github name, which happens to have an "á".

Hum, I may be missing a string convert on some arguments of the git clone command...
 
Ok, if that's the way to go I can try to fix it and send you a pull request. 
I was thinking if it can not be resolved by OSSubprocess itself. 
 
But I will check your idea, to be sure.
 
Does this happens with OSProcess as well?

I am not sure about this, can I use gitfiletree with OSProcess, how can I test it?


Just load OSProcess before loading GitFileTree, it should notice it and avoid loading OSSubprocess.


Ok, I will try that, thankyou. 



--