Pb subprocess

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Méta-MCI

    #1

    Pb subprocess

    Hi!


    This code :
    p=subprocess.Po pen(chaine, shell=True, stdout=subproce ss.PIPE,
    stdin=subproces s.PIPE, stderr=subproce ss.PIPE)
    data=p.stdout.r ead()

    Run OK, except when stdout.read() give unicode data, with char>255 (this
    give many "?")

    How read real unicode data in stdout.read() ?


    Thanks for all anwers


    Michel Claveau





  • Méta-MCI

    #2
    Re: Pb subprocess

    Solved.

    Thank to Amaury.

    Solution :
    change (in register), Command Processor, for to force using of "CMD /U/C"
    Then, STDOUT is in utf-16 (but win-console stay in cp850)

    HGD

    Michel Claveau





    Comment

    Working...