Skip to contentSkip to conversation

: update some python packages bb

PATCH In review [email protected] 2 participants 10 messages Jun 28, 2016 – Jun 29, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 : update some python packages bb

1,
Remove pytest for python-mccabe to avoid dependency on python-runner as only one file test_mccabe.py import pytest and this test_mccabe.py file not install on our target eventually.

2, Add python-pbr bb file as python-mock depends on
python-pbr-native

3, Add python-pbr-native dependency for python-mock

#1 lore raw

PATCH 1/3 python-mccabe: Remove pytest

From: Mingli Yu <[email protected]>

* Remove pytest to avoid dependency on python-runner as only one file test_mccabe.py import pytest and this test_mccabe.py file not install on our target eventually.

---
 .../python-mccabe-Remove-pytest.patch              | 32 ++++++++++++++++++++++
 .../recipes-devtools/python/python-mccabe_0.4.0.bb |  1 +
 2 files changed, 33 insertions(+)
 create mode 100644 meta-python/recipes-devtools/python/python-mccabe/python-mccabe-Remove-pytest.patch
meta-python/recipes-devtools/python/python-mccabe/python-mccabe-Remove-pytest.patch new file +32 -0
new file mode 100644
index 0000000..ebe70c5
@@ -0,0 +1,32 @@
+From 7c0dc893cd3e57df16cf43d2c51c047997ea5c69 Mon Sep 17 00:00:00 2001
+From: Mingli Yu <[email protected]>
+Date: Wed, 22 Jun 2016 02:33:48 +0000
+Subject: [PATCH] python-mccabe: Remove pytest
+
+* Remove pytest to avoid dependency on python-runner
+  as only one file test_mccabe.py import pytest and this
+  test_mccabe.py file not install on our target eventually.
+
+Upstream-Status: Inappropriate[oe specific]
+
+Signed-off-by: Mingli Yu <[email protected]>
+---
+ setup.py | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/setup.py b/setup.py
+index e59903d..64c3ded 100644
+--- a/setup.py
++++ b/setup.py
+@@ -33,8 +33,6 @@ setup(
+     license='Expat license',
+     py_modules=['mccabe'],
+     zip_safe=False,
+-    setup_requires=['pytest-runner'],
+-    tests_require=['pytest'],
+     entry_points={
+         'flake8.extension': [
+             'C90 = mccabe:McCabeChecker',
+-- 
+2.8.2
+
meta-python/recipes-devtools/python/python-mccabe_0.4.0.bb +1 -0
index 0958f75..1377446 100644
@@ -3,6 +3,7 @@ HOMEPAGE = "https://github.com/dreamhost/cliff"
 LICENSE = "Apache-2.0"
 LIC_FILES_CHKSUM = "file://README.rst;md5=f8b50fba1711ecac6bcdb6324f85a66d"
 
+SRC_URI = "file://python-mccabe-Remove-pytest.patch"
 SRC_URI[md5sum] = "8c425db05f310adcd4bb174b991f26f5"
 SRC_URI[sha256sum] = "9a2b12ebd876e77c72e41ebf401cc2e7c5b566649d50105ca49822688642207b"
 
Signature · 1 line
2.8.1
#2 lore raw

Re: [PATCH 1/3] python-mccabe: Remove pytest

Quoted 7 lines · On Tue, Jun 28, 2016 at 1:36 AM, <[email protected]> wrote:

From: Mingli Yu <[email protected]>

* Remove pytest to avoid dependency on python-runner as only one file test_mccabe.py import pytest and this test_mccabe.py file not install on our target eventually.

That "one file" is where all the tests are housed. Just because you don't

plan to install the tests on target is no reason to disable testing. If anything we need to see more testing of recipes, not less. The solution is to add a recipe for the dependency of python-pytest-runner. Then you can inherit ptest and package the tests separately.

Quoted 74 lines
---
 .../python-mccabe-Remove-pytest.patch              | 32
++++++++++++++++++++++
 .../recipes-devtools/python/python-mccabe_0.4.0.bb |  1 +
 2 files changed, 33 insertions(+)
 create mode 100644

meta-python/recipes-devtools/python/python-mccabe/python-mccabe-Remove-pytest.patch

diff --git a/meta-python/recipes-devtools/python/python-mccabe/python-mccabe-Remove-pytest.patch b/meta-python/recipes-devtools/python/python-mccabe/python-mccabe-Remove-pytest.patch new file mode 100644
index 0000000..ebe70c5
--- /dev/null
+++
b/meta-python/recipes-devtools/python/python-mccabe/python-mccabe-Remove-pytest.patch

meta-python/recipes-devtools/python/python-mccabe/python-mccabe-Remove-pytest.patch new file +32 -0
@@ -0,0 +1,32 @@
+From 7c0dc893cd3e57df16cf43d2c51c047997ea5c69 Mon Sep 17 00:00:00 2001
+From: Mingli Yu <[email protected]>
+Date: Wed, 22 Jun 2016 02:33:48 +0000
+Subject: [PATCH] python-mccabe: Remove pytest
+
+* Remove pytest to avoid dependency on python-runner
+  as only one file test_mccabe.py import pytest and this
+  test_mccabe.py file not install on our target eventually.
+
+Upstream-Status: Inappropriate[oe specific]
+
+Signed-off-by: Mingli Yu <[email protected]>
+---
+ setup.py | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/setup.py b/setup.py
+index e59903d..64c3ded 100644
+--- a/setup.py
++++ b/setup.py
+@@ -33,8 +33,6 @@ setup(
+     license='Expat license',
+     py_modules=['mccabe'],
+     zip_safe=False,
+-    setup_requires=['pytest-runner'],
+-    tests_require=['pytest'],
+     entry_points={
+         'flake8.extension': [
+             'C90 = mccabe:McCabeChecker',
+--
+2.8.2
+
meta-python/recipes-devtools/python/python-mccabe_0.4.0.bb +0 -0
index 0958f75..1377446 100644
@@ -3,6 +3,7 @@ HOMEPAGE = "https://github.com/dreamhost/cliff"
 LICENSE = "Apache-2.0"
 LIC_FILES_CHKSUM =

"file://README.rst;md5=f8b50fba1711ecac6bcdb6324f85a66d"

+SRC_URI = "file://python-mccabe-Remove-pytest.patch"
SRC_URI[md5sum] = "8c425db05f310adcd4bb174b991f26f5" SRC_URI[sha256sum] =
"9a2b12ebd876e77c72e41ebf401cc2e7c5b566649d50105ca49822688642207b"

--
2.8.1

--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

author
#3 lore raw

Re: [PATCH 1/3] python-mccabe: Remove pytest

Quoted 8 lines · Tim Orling
Quoted 6 lines · On Tue, Jun 28, 2016 at 1:36 AM, <[email protected]> wrote:

From: Mingli Yu <[email protected]>

* Remove pytest to avoid dependency on python-runner as only one file test_mccabe.py import pytest and this test_mccabe.py file not install on our target eventually.

Quoted 5 lines
Quoted 1 line

That "one file" is where all the tests are housed. Just because you don't

plan to install the tests on target is no reason to disable testing. If anything we need to see more testing of recipes, not less. The solution is to add a recipe for the dependency of python-pytest-runner. Then you can inherit ptest and package the tests separately.

Thanks! Already update to add python-pytest-runner dependency in new commit.

Quoted 76 lines
Quoted 76 lines
---
  .../python-mccabe-Remove-pytest.patch              | 32
++++++++++++++++++++++
  .../recipes-devtools/python/python-mccabe_0.4.0.bb |  1 +
  2 files changed, 33 insertions(+)

create mode 100644
meta-python/recipes-devtools/python/python-mccabe/python-mccabe-Remove-pytest.patch

diff --git a/meta-python/recipes-devtools/python/python-mccabe/python-mccabe-Remove-pytest.patch b/meta-python/recipes-devtools/python/python-mccabe/python-mccabe-Remove-pytest.patch new file mode 100644
index 0000000..ebe70c5
--- /dev/null
+++
b/meta-python/recipes-devtools/python/python-mccabe/python-mccabe-Remove-pytest.patch

meta-python/recipes-devtools/python/python-mccabe/python-mccabe-Remove-pytest.patch new file +32 -0
@@ -0,0 +1,32 @@
+From 7c0dc893cd3e57df16cf43d2c51c047997ea5c69 Mon Sep 17 00:00:00 2001
+From: Mingli Yu <[email protected]>
+Date: Wed, 22 Jun 2016 02:33:48 +0000
+Subject: [PATCH] python-mccabe: Remove pytest
+
+* Remove pytest to avoid dependency on python-runner
+  as only one file test_mccabe.py import pytest and this
+  test_mccabe.py file not install on our target eventually.
+
+Upstream-Status: Inappropriate[oe specific]
+
+Signed-off-by: Mingli Yu <[email protected]>
+---
+ setup.py | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/setup.py b/setup.py
+index e59903d..64c3ded 100644
+--- a/setup.py
++++ b/setup.py
+@@ -33,8 +33,6 @@ setup(
+     license='Expat license',
+     py_modules=['mccabe'],
+     zip_safe=False,
+-    setup_requires=['pytest-runner'],
+-    tests_require=['pytest'],
+     entry_points={
+         'flake8.extension': [
+             'C90 = mccabe:McCabeChecker',
+--
+2.8.2
+
meta-python/recipes-devtools/python/python-mccabe_0.4.0.bb +0 -0
index 0958f75..1377446 100644
@@ -3,6 +3,7 @@ HOMEPAGE = "https://github.com/dreamhost/cliff"
  LICENSE = "Apache-2.0"
  LIC_FILES_CHKSUM =

"file://README.rst;md5=f8b50fba1711ecac6bcdb6324f85a66d"

+SRC_URI = "file://python-mccabe-Remove-pytest.patch"
SRC_URI[md5sum] = "8c425db05f310adcd4bb174b991f26f5" SRC_URI[sha256sum] =
"9a2b12ebd876e77c72e41ebf401cc2e7c5b566649d50105ca49822688642207b"

--
2.8.1

--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

#4 lore raw

PATCH 2/3 python-pbr: add python-pbr bb

In reply to [email protected]

From: Mingli Yu <[email protected]>

* Add python-pbr bb file as python-mock depends on python-pbr-native

---
 .../recipes-devtools/python/python-pbr_1.10.0.bb   | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)
 create mode 100644 meta-python/recipes-devtools/python/python-pbr_1.10.0.bb
meta-python/recipes-devtools/python/python-pbr_1.10.0.bb new file +22 -0
new file mode 100644
index 0000000..4a08bde
@@ -0,0 +1,22 @@
+DESCRIPTION = "Python Build Reasonableness: PBR is a library that injects some useful and sensible default behaviors into your setuptools run"
+HOMEPAGE = "https://pypi.python.org/pypi/pbr"
+SECTION = "devel/python"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=1dece7821bf3fd70fe1309eaa37d52a2"
+
+SRCNAME = "pbr"
+
+SRC_URI = "https://pypi.python.org/packages/source/p/${SRCNAME}/${SRCNAME}-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "8e4968c587268f030e38329feb9c8f17"
+SRC_URI[sha256sum] = "186428c270309e6fdfe2d5ab0949ab21ae5f7dea831eab96701b86bd666af39c"
+
+S = "${WORKDIR}/${SRCNAME}-${PV}"
+
+inherit setuptools
+
+DEPENDS_class-target += " \
+        python-pip \
+        "
+
+BBCLASSEXTEND = "native"
Signature · 1 line
2.8.1
#5 lore raw

Re: [PATCH 2/3] python-pbr: add python-pbr bb

Quoted 30 lines · On Tue, Jun 28, 2016 at 1:36 AM, <[email protected]> wrote:

From: Mingli Yu <[email protected]>

* Add python-pbr bb file as python-mock depends on python-pbr-native

---
 .../recipes-devtools/python/python-pbr_1.10.0.bb   | 22
++++++++++++++++++++++
 1 file changed, 22 insertions(+)
 create mode 100644 meta-python/recipes-devtools/python/

python-pbr_1.10.0.bb

meta-python/recipes-devtools/python/python-pbr_1.10.0.bb new file +1 -0
new file mode 100644
index 0000000..4a08bde
@@ -0,0 +1,22 @@
+DESCRIPTION = "Python Build Reasonableness: PBR is a library that injects

some useful and sensible default behaviors into your setuptools run"

meta-python/recipes-devtools/python/python-pbr_1.10.0.bb new file +8 -0
+HOMEPAGE = "https://pypi.python.org/pypi/pbr"
+SECTION = "devel/python"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=1dece7821bf3fd70fe1309eaa37d52a2"
+
+SRCNAME = "pbr"
+
+SRC_URI = "
Quoted 3 lines

https://pypi.python.org/packages/source/p/${SRCNAME}/${SRCNAME}-${PV}.tar.gz
"

You don't need to do this if you inherit pypi.

Quoted 23 lines
meta-python/recipes-devtools/python/python-pbr_1.10.0.bb new file +3 -0
+
+SRC_URI[md5sum] = "8e4968c587268f030e38329feb9c8f17"
+SRC_URI[sha256sum] =

"186428c270309e6fdfe2d5ab0949ab21ae5f7dea831eab96701b86bd666af39c"

meta-python/recipes-devtools/python/python-pbr_1.10.0.bb new file +10 -1
+
+S = "${WORKDIR}/${SRCNAME}-${PV}"
+
+inherit setuptools
+
+DEPENDS_class-target += " \
+        python-pip \
+        "
+
+BBCLASSEXTEND = "native"
--

2.8.1

--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

author
#6 lore raw

Re: [PATCH 2/3] python-pbr: add python-pbr bb

Quoted 29 lines · Tim Orling
Quoted 27 lines · On Tue, Jun 28, 2016 at 1:36 AM, <[email protected]> wrote:

From: Mingli Yu <[email protected]>

* Add python-pbr bb file as python-mock depends on python-pbr-native

---
  .../recipes-devtools/python/python-pbr_1.10.0.bb   | 22
++++++++++++++++++++++
  1 file changed, 22 insertions(+)

create mode 100644 meta-python/recipes-devtools/python/
python-pbr_1.10.0.bb

meta-python/recipes-devtools/python/python-pbr_1.10.0.bb new file +1 -0
new file mode 100644
index 0000000..4a08bde
@@ -0,0 +1,22 @@
+DESCRIPTION = "Python Build Reasonableness: PBR is a library that injects

some useful and sensible default behaviors into your setuptools run"

meta-python/recipes-devtools/python/python-pbr_1.10.0.bb new file +5 -0
+HOMEPAGE = "https://pypi.python.org/pypi/pbr"
+SECTION = "devel/python"
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=1dece7821bf3fd70fe1309eaa37d52a2"
+
Quoted 8 lines
Quoted 6 lines
meta-python/recipes-devtools/python/python-pbr_1.10.0.bb new file +3 -0
+SRCNAME = "pbr"
+
+SRC_URI = "

https://pypi.python.org/packages/source/p/${SRCNAME}/${SRCNAME}-${PV}.tar.gz
"

You don't need to do this if you inherit pypi.

Thanks! Update to inherit pypi.

Quoted 25 lines
Quoted 25 lines
meta-python/recipes-devtools/python/python-pbr_1.10.0.bb new file +3 -0
+
+SRC_URI[md5sum] = "8e4968c587268f030e38329feb9c8f17"
+SRC_URI[sha256sum] =

"186428c270309e6fdfe2d5ab0949ab21ae5f7dea831eab96701b86bd666af39c"

meta-python/recipes-devtools/python/python-pbr_1.10.0.bb new file +10 -1
+
+S = "${WORKDIR}/${SRCNAME}-${PV}"
+
+inherit setuptools
+
+DEPENDS_class-target += " \
+        python-pip \
+        "
+
+BBCLASSEXTEND = "native"
--

2.8.1

--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

#7 lore raw

PATCH 3/3 python-mock: add python-pbr-native dependency

In reply to [email protected]

From: Mingli Yu <[email protected]>

* Add python-pbr-native dependency for python-mock

---
 meta-python/recipes-devtools/python/python-mock_2.0.0.bb | 3 +++
 1 file changed, 3 insertions(+)
meta-python/recipes-devtools/python/python-mock_2.0.0.bb +3 -0
index eb473d2..849c99e 100644
@@ -8,6 +8,9 @@ PYPI_PACKAGE_HASH = "0c53014354fc93c591ccc4abff12c473ad565a2eb24dcd82490fae33dbf
 
 inherit pypi setuptools
 
+DEPENDS += " \
+    python-pbr-native"
+
 RDEPENDS_${PN} += " \
     python-prettytable \
     python-cmd2 \
Signature · 1 line
2.8.1
#8 lore raw
In reply to [email protected]

The subject line is misleading, as you are actually adding recipes for python-pbr and python-mock, not updating them.
Also, please make sure that EACH patch has [meta-python] in the subject line, these patches are consumed by automated processes.

Quoted 7 lines · On Tue, Jun 28, 2016 at 1:36 AM, <[email protected]> wrote:

1,
Remove pytest for python-mccabe to avoid dependency on python-runner as only one file test_mccabe.py import pytest and this test_mccabe.py file not install on our target eventually.

This is not the right direction to go in. If anything we need MORE testing

of recipes, not less. The solution is to add a python-pytest-runner recipe to meet the dependency.

Quoted 10 lines

2, Add python-pbr bb file as python-mock depends on
python-pbr-native

3, Add python-pbr-native dependency for python-mock --
_______________________________________________
Openembedded-devel mailing list [email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

author
#9 lore raw
Quoted 2 lines · Tim Orling

The subject line is misleading, as you are actually adding recipes for python-pbr and python-mock, not updating them.

Thanks! will update the subject then.

Quoted 2 lines

Also, please make sure that EACH patch has [meta-python] in the subject line, these patches are consumed by automated processes.

Thanks! Will make each patch has [meta-python] in the subject.

Quoted 9 lines · On Tue, Jun 28, 2016 at 1:36 AM, <[email protected]> wrote:
Quoted 7 lines

1,
Remove pytest for python-mccabe to avoid dependency on python-runner as only one file test_mccabe.py import pytest and this test_mccabe.py file not install on our target eventually.

Quoted 3 lines
Quoted 1 line

This is not the right direction to go in. If anything we need MORE testing

of recipes, not less. The solution is to add a python-pytest-runner recipe to meet the dependency.

Thanks! Will add the dependency then.

Quoted 12 lines
Quoted 12 lines

2, Add python-pbr bb file as python-mock depends on
python-pbr-native

3, Add python-pbr-native dependency for python-mock --
_______________________________________________
Openembedded-devel mailing list [email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel