rpms/python-meliae/devel import.log, NONE, 1.1 meliae-0.2.0-fix-builtintype-heap-assertion.patch, NONE, 1.1 python-meliae.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
dmalcolm
dmalcolm at fedoraproject.org
Thu Apr 22 15:07:40 UTC 2010
- Previous message: File meliae-0.2.0.tar.gz uploaded to lookaside cache by dmalcolm
- Next message: rpms/python-meliae/F-13 import.log, NONE, 1.1 meliae-0.2.0-fix-builtintype-heap-assertion.patch, NONE, 1.1 python-meliae.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: dmalcolm
Update of /cvs/pkgs/rpms/python-meliae/devel
In directory cvs01.phx2.fedoraproject.org:/tmp/cvs-serv12700/devel
Modified Files:
.cvsignore sources
Added Files:
import.log meliae-0.2.0-fix-builtintype-heap-assertion.patch
python-meliae.spec
Log Message:
Initial import from review (rhbz:577398)
--- NEW FILE import.log ---
python-meliae-0_2_0-2_fc12:HEAD:python-meliae-0.2.0-2.fc12.src.rpm:1271948778
meliae-0.2.0-fix-builtintype-heap-assertion.patch:
_scanner_core.c | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
--- NEW FILE meliae-0.2.0-fix-builtintype-heap-assertion.patch ---
diff -up meliae-0.2.0/meliae/_scanner_core.c.fix-builtintype-heap-assertion meliae-0.2.0/meliae/_scanner_core.c
--- meliae-0.2.0/meliae/_scanner_core.c.fix-builtintype-heap-assertion 2010-01-08 18:09:13.000000000 -0500
+++ meliae-0.2.0/meliae/_scanner_core.c 2010-03-26 17:17:28.065744255 -0400
@@ -473,12 +473,14 @@ _dump_object_to_ref_info(struct ref_info
_write_to_ref_info(info, ", \"len\": " SSIZET_FMT, PyDict_Size(c_obj));
}
_write_static_to_info(info, ", \"refs\": [");
- if (Py_TYPE(c_obj)->tp_traverse != NULL) {
+ if (Py_TYPE(c_obj)->tp_traverse != NULL
+ && Py_TYPE(c_obj)->tp_flags & Py_TPFLAGS_HEAPTYPE) {
info->first = 1;
Py_TYPE(c_obj)->tp_traverse(c_obj, _dump_reference, info);
}
_write_static_to_info(info, "]}\n");
- if (Py_TYPE(c_obj)->tp_traverse != NULL && recurse != 0) {
+ if (Py_TYPE(c_obj)->tp_traverse != NULL && recurse != 0
+ && Py_TYPE(c_obj)->tp_flags & Py_TPFLAGS_HEAPTYPE) {
if (recurse == 2) { /* Always dump one layer deeper */
Py_TYPE(c_obj)->tp_traverse(c_obj, _dump_child, info);
} else if (recurse == 1) {
@@ -514,7 +516,9 @@ PyObject *_get_referents(PyObject *c_obj
if (lst == NULL) {
return NULL;
}
- if (Py_TYPE(c_obj)->tp_traverse != NULL) {
+ if (Py_TYPE(c_obj)->tp_traverse != NULL
+ && Py_TYPE(c_obj)->tp_flags & Py_TPFLAGS_HEAPTYPE) {
+
Py_TYPE(c_obj)->tp_traverse(c_obj, _append_object, lst);
}
return lst;
--- NEW FILE python-meliae.spec ---
%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")}
Name: python-meliae
Version: 0.2.0
Release: 2%{?dist}
Summary: Python memory usage statistics
Group: Development/Languages
License: GPLv3
URL: https://launchpad.net/meliae
Source0: http://launchpad.net/meliae/0.2/0.2.0/+download/meliae-0.2.0.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
# I've seen assertion failures of the form:
# python: Objects/typeobject.c:2672: type_traverse: Assertion `type->tp_flags & (1L<<9)' failed.
# which is:
# assert(type->tp_flags & Py_TPFLAGS_HEAPTYPE)
# when visiting the <type> "object" (the most basic type)
#
# This patch bulletproofs against it:
Patch1: meliae-0.2.0-fix-builtintype-heap-assertion.patch
BuildRequires: python-devel
BuildRequires: Cython
%description
"meliae" provides a way to dump python memory usage information to a JSON disk
format, which can then be parsed into useful things like graph representations.
The name is simply a fun word (means Ash-wood Nymph).
%prep
%setup -q -n meliae-%{version}
%patch1 -p1 -b .fix-builtintype-heap-assertion
%build
CFLAGS="$RPM_OPT_FLAGS" %{__python} setup.py build
%install
rm -rf $RPM_BUILD_ROOT
%{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root,-)
%doc CHANGES.txt COPYING.txt README.txt TODO.txt
%{_bindir}/strip_duplicates.py
%{python_sitearch}/*
%changelog
* Fri Mar 26 2010 David Malcolm <dmalcolm at redhat.com> - 0.2.0-2
- fix assertion failure seen with non-heap types
* Fri Mar 26 2010 David Malcolm <dmalcolm at redhat.com> - 0.2.0-1
- initial packaging
Index: .cvsignore
===================================================================
RCS file: /cvs/pkgs/rpms/python-meliae/devel/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -p -r1.1 -r1.2
--- .cvsignore 21 Apr 2010 04:15:45 -0000 1.1
+++ .cvsignore 22 Apr 2010 15:07:38 -0000 1.2
@@ -0,0 +1 @@
+meliae-0.2.0.tar.gz
Index: sources
===================================================================
RCS file: /cvs/pkgs/rpms/python-meliae/devel/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -p -r1.1 -r1.2
--- sources 21 Apr 2010 04:15:46 -0000 1.1
+++ sources 22 Apr 2010 15:07:39 -0000 1.2
@@ -0,0 +1 @@
+21846ab82299ae1e30d3123a92a05ac0 meliae-0.2.0.tar.gz
- Previous message: File meliae-0.2.0.tar.gz uploaded to lookaside cache by dmalcolm
- Next message: rpms/python-meliae/F-13 import.log, NONE, 1.1 meliae-0.2.0-fix-builtintype-heap-assertion.patch, NONE, 1.1 python-meliae.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the scm-commits
mailing list