[rtems-docs commit] Version change, forgot to add wscript to the commit.

Sebastian Huber sebastian.huber at embedded-brains.de
Fri Feb 8 06:33:40 UTC 2019


On 08/02/2019 07:29, Sebastian Huber wrote:
> On 07/02/2019 18:28, Chris Johns wrote:
>> On 8/2/19 11:09 pm, Sebastian Huber wrote:
>>> After the update I get:
>>>
>>>    File "/home/EB/sebastian_h/git-rtems-docs/wscript", line 67, in 
>>> build
>>>      ver_version, ver_date, ver_released = version.get(ctx, 
>>> rtems_major_version)
>>> AttributeError: 'module' object has no attribute 'get'
>> It works on MacOS, FreeBSD 11.2-p5 and sync.rtems.org (docs.rtems.org 
>> shows the
>> patch I pushed built).
>>
>> I wonder if you are loading a different `version.py`.
>>
>> On MacOS with Python2 I have:
>>
>> $ python
>> Python 2.7.10 (default, Aug 17 2018, 19:45:58)
>> [GCC 4.2.1 Compatible Apple LLVM 10.0.0 (clang-1000.0.42)] on darwin
>> Type "help", "copyright", "credits" or "license" for more information.
>>>>> import sys
>>>>> import os.path
>>>>> sys.path.append(os.path.abspath('common'))
>>>>> import version
>>>>> version.__file__
>> '/Users/chris/development/rtems/docs/rtems-docs.git/common/version.pyc'
>>>>> version.__dict__['get']
>> <function get at 0x107b69410>
>>
>> And on FreeBSD 11.2-p5 with python3 I have:
>>
>> $ python3
>> Python 3.6.6 (default, Oct  2 2018, 01:22:29)
>> [GCC 4.2.1 Compatible FreeBSD Clang 6.0.0 (tags/RELEASE_600/final 
>> 326565)] on
>> freebsd11
>> Type "help", "copyright", "credits" or "license" for more information.
>>>>> import sys
>>>>> import os.path
>>>>> sys.path.append(os.path.abspath('common'))
>>>>> import version
>>>>> version.__file__
>> '/opt/work/chris/rtems/docs/rtems-docs.git/common/version.py'
>>>>> version.__dict__['get']
>> <function get at 0x8007b7730>
>>
>> What are you seeing?
>
> Yes, there seems to be a conflict with another version module:
>
> python
> Python 2.7.14 (default, Oct 12 2017, 15:50:02) [GCC] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
> >>> import sys
> >>> import os.path
> >>> sys.path.append(os.path.abspath('common'))
> >>> import version
> >>> version.__file__
> '/usr/lib64/python2.7/site-packages/PIL/version.pyc'
> >>> version.__dict__['get']
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
> KeyError: 'get'
>
> The module concept is not really the greatest thing in Python.
>

It works if I use:

sys.path.insert(0, os.path.abspath('common'))

-- 
Sebastian Huber, embedded brains GmbH

Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone   : +49 89 189 47 41-16
Fax     : +49 89 189 47 41-09
E-Mail  : sebastian.huber at embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.




More information about the devel mailing list