Qwt layer adding in OE core

I am using below link to add QWT layer and getting error as below
http://developer.toradex.com/software-resources/arm-family/linux/board-support-package/openembedded-(core)#Adding_the_Qt5_Layer

Error:

agd@toradex:~/oe-core/build$ MACHINE=colibri-vf bitbake -DDD angstrom-lxde-image
Traceback (most recent call last):
  File "/home/agd/oe-core/stuff/openembedded-core/bitbake/bin/bitbake", line 34, in 
    import bb
  File "/home/agd/oe-core/stuff/openembedded-core/bitbake/lib/bb/__init__.py", line 75, in 
    import bb.msg
  File "/home/agd/oe-core/stuff/openembedded-core/bitbake/lib/bb/msg.py", line 32, in 
    import bb.event
  File "/home/agd/oe-core/stuff/openembedded-core/bitbake/lib/bb/event.py", line 34, in 
    import bb.utils
  File "/home/agd/oe-core/stuff/openembedded-core/bitbake/lib/bb/utils.py", line 35, in 
    from contextlib import contextmanager
ImportError: No module named contextlib
agd@toradex:~/oe-core/build$

As mentioned on the link you referenced, Qt5 layer has only been tested for Tegra and iMX6 modules.

Can you provide the following details?

  1. OE core/repo has been initialized to?
  2. What Linux distribution are you seeing this error on?
  3. Are all the necessary prerequisites installed?

@amolyp
Do you have the information we requested? We might be able to give you more hints once we know more about your setup. Thanks.

Hello,

  1. OE core/repo has been initialized to?
    Ans: Please clarify

  2. What Linux distribution are you seeing this error on?
    Ans:
    agd@toradex:~$ uname -a
    Linux toradex 3.16.0-51-generic #69~14.04.1-Ubuntu SMP Wed Oct 7 15:32:41 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
    agd@toradex:~$

  3. Are all the necessary prerequisites installed?
    Ans: Yes

Hello,

What I am referring to is the below step mentioned in OE core setup article.

repo init -u Index of /toradex-bsp-platform.git -b LinuxImageV2.5

What was the image version you used during initialization of repo?

Consulting our records, I find that you had already interacted with my colleague Mr. Bhuvan who had advised you to start with a new OE core setup as we suspect that some configuration error has occurred with your existing setup since invoking bitbake itself is met with failure.

What I am referring to is the below step mentioned in OE core setup article.
repo init -u http://git.toradex.com/toradex-bsp-platform.git -b LinuxImageV2.5

repo init -u http://git.toradex.com/toradex-bsp-platform.git -b LinuxImageV2.4
What was the image version you used during initialization of repo?
LinuxImageV2.4
Consulting our records,
But reinstalling is not the solution to existing problem since it is very time consuming, what if it occurs again after reinstalling.

The Python trace back shows that bitbake could not load contextlib. contextlib has been part of the standard library in Python since 2.5 as per the Python docs.

https://docs.python.org/2/library/contextlib.html

Can you invoke python from the command line and check by trying import contextlib and from contextlib import contextmanager. Also please share the console output of the above directly and the default Python version on host PC?

I was not able to add qwt layer to plot graph, however I found a solution to using graph on QT by using QCustomPlot . Very simple to use graph plotting and open source.
Thank you all for the support.

You can also investigate https://doc.qt.io/qt-5/qtcharts-overview.html it’s available in qt since 5.6 release.