<html>
  <head>
    <meta content="text/html; charset=windows-1252"
      http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <br>
    <br>
    <div class="moz-cite-prefix">On 14.01.2016 11:42, Karl Forner wrote:<br>
    </div>
    <blockquote
cite="mid:CAMd4_Aee06YQ0Nvr=ODCf7mjySnoE2nLC_Wf9fdWHgbE2RP_Ew@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div>
          <div>
            <div>
              <div>
                <div>
                  <div>Hello,<br>
                    <br>
                  </div>
                  When I do:<br>
                  ipa  user-find --login=$login<br>
                </div>
                I get:<br>
                <br>
                ipa: ERROR: UnicodeEncodeError: 'ascii' codec can't
                encode character u'\xf1' in position 25: ordinal not in
                range(128)<br>
                Traceback (most recent call last):<br>
                  File "/usr/lib/python2.7/site-packages/ipalib/cli.py",
                line 1340, in run<br>
                    sys.exit(api.Backend.cli.run(argv))<br>
                  File "/usr/lib/python2.7/site-packages/ipalib/cli.py",
                line 1105, in run<br>
                    rv = cmd.output_for_cli(self.api.Backend.textui,
                result, *args, **options)<br>
                  File
                "/usr/lib/python2.7/site-packages/ipalib/frontend.py",
                line 1030, in output_for_cli<br>
                    textui.print_entries(result, order, labels, flags,
                print_all)<br>
                  File "/usr/lib/python2.7/site-packages/ipalib/cli.py",
                line 355, in print_entries<br>
                    self.print_entry(entry, order, labels, flags,
                print_all, format, indent)<br>
                  File "/usr/lib/python2.7/site-packages/ipalib/cli.py",
                line 395, in print_entry<br>
                    label, value, format, indent, one_value_per_line<br>
                  File "/usr/lib/python2.7/site-packages/ipalib/cli.py",
                line 318, in print_attribute<br>
                    self.print_indented(format % (attr, text[0]),
                indent)<br>
                  File "/usr/lib/python2.7/site-packages/ipalib/cli.py",
                line 241, in print_indented<br>
                    print (CLI_TAB * indent + text)<br>
                UnicodeEncodeError: 'ascii' codec can't encode character
                u'\xf1' in position 25: ordinal not in range(128)<br>
                ipa: ERROR: an internal error has occurred<br>
                <br>
              </div>
              I checked that the last name of this user has a n with
              tilde (spanish for "gn" sound).<br>
            </div>
            Is this a system configuration error, or a freeIPA problem ?
            <br>
            <br>
          </div>
          Thanks,<br>
        </div>
        Karl<br>
        <div>
          <div>
            <div>
              <div>
                <div><br>
                  <br>
                </div>
              </div>
            </div>
          </div>
        </div>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
    </blockquote>
    <br>
    Hello,<br>
    <br>
    what is your lang settings?<br>
    <br>
    $ locale<br>
    <br>
    It works for me with utf-8, I was able to reproduce this only with
    LC_ALL=C, what is somehow expected<br>
    <br>
    <br>
  </body>
</html>