#3312: RSB macro calls such as define fail on unicode keys.
--------------------------+-------------------------
  Reporter:  Chris Johns  |      Owner:  Chris Johns
      Type:  defect       |     Status:  assigned
  Priority:  normal       |  Milestone:  5.1
 Component:  tool/rsb     |    Version:  5
  Severity:  normal       |   Keywords:
Blocked By:               |   Blocking:
--------------------------+-------------------------
 The `define` call in `macros.py` checks for a `str` while the
 `__setitem__` call can convert a `unicode` string to `str`. Remove the
 check.

 Remove the other places in `macros.py` a `key` `str` check is made and see
 if they can be improved.

 The following has been reported to me:
 {{{
 cd rtems-source-builder-4.11.3/rtems
 ../source-builder/sb-set-builder --prefix=/home/user/rtems/4.11
 --log=arm.txt --without-rtems 4.11/rtems-arm
 Traceback (most recent call last):
   File "../source-builder/sb-set-builder", line 29, in <module>
     setbuilder.run()
   File "../source-builder/sb/setbuilder.py", line 526, in run
     opts = options.load(sys.argv, optargs)
   File "../source-builder/sb/options.py", line 668, in load
     version.load_release_settings(o.defaults)
   File "../source-builder/sb/version.py", line 123, in
 load_release_settings
     sources.hash((hs[0], hash[0], hs[1]), macros, setting_error)
   File "../source-builder/sb/sources.py", line 105, in hash
     macros.define(_file, '%s %s' % (args[0], args[2]))
   File "../source-builder/sb/macros.py", line 439, in define
     raise TypeError('bad key type: %s' % (type(key)))
 TypeError: bad key type: <type 'unicode'>
 }}}

--
Ticket URL: <http://devel.rtems.org/ticket/3312>
RTEMS Project <http://www.rtems.org/>
RTEMS Project
_______________________________________________
bugs mailing list
bugs@rtems.org
http://lists.rtems.org/mailman/listinfo/bugs

Reply via email to