inducer / tagpy

Python wrapper around TagLib. See https://github.com/palfrey/tagpy for a maintained fork.
MIT License
9 stars 6 forks source link

Please make a new release #5

Open mgorny opened 6 years ago

mgorny commented 6 years ago

Given that the current release spits confusing anti-setuptools messages at users building it, could you please make a new release package?

inducer commented 6 years ago

Done. Let me know if that helped.

mgorny commented 6 years ago

The pypi tarball seems to be missing README.rst which causes setup.py to error out:


/usr/bin/python2.7 setup.py build
Traceback (most recent call last):
  File "setup.py", line 95, in <module>
    main()
  File "setup.py", line 55, in main
    long_description=open("README.rst", "rt").read(),
IOError: [Errno 2] No such file or directory: 'README.rst'
inducer commented 6 years ago

How about now?

mgorny commented 6 years ago

I'm sorry, I suppose I should've tested building from git first. Now I get boost-related build failure (it didn't fail with 2013.1). This is against boost-1.65.0. Do you want me to report a separate bug for it?

running build_ext
building '_tagpy' extension
creating /tmp/portage/dev-python/tagpy-2018.1.1/work/tagpy-2018.1.1-python2_7/build/temp.linux-x86_64-2.7
creating /tmp/portage/dev-python/tagpy-2018.1.1/work/tagpy-2018.1.1-python2_7/build/temp.linux-x86_64-2.7/src
creating /tmp/portage/dev-python/tagpy-2018.1.1/work/tagpy-2018.1.1-python2_7/build/temp.linux-x86_64-2.7/src/wrapper
x86_64-pc-linux-gnu-g++-6.4.0 -march=k8-sse3 -mcx16 -msahf --param l1-cache-size=64 --param l1-cache-line-size=64 --param l2-cache-size=512 -O2 -pipe -frecord-gcc-switches -fPIC -I/usr/include/taglib -I/usr/include/python2.7 -c src/wrapper/basics.cpp -o /tmp/portage/dev-python/tagpy-2018.1.1/work/tagpy-2018.1.1-python2_7/build/temp.linux-x86_64-2.7/src/wrapper/basics.o
In file included from src/wrapper/basics.cpp:34:0:
src/wrapper/common.hpp:191:62: warning: ‘template<class> class std::auto_ptr’ is deprecated [-Wdeprecated-declarations]
   void PointerList_setitem(List<Value *> &l, TagLib::uint i, auto_ptr<Value> v)
                                                              ^~~~~~~~
In file included from /usr/lib/gcc/x86_64-pc-linux-gnu/6.4.0/include/g++-v6/memory:81:0,
                 from /usr/include/boost/function/function_base.hpp:16,
                 from /usr/include/boost/function/detail/prologue.hpp:17,
                 from /usr/include/boost/function/function_template.hpp:13,
                 from /usr/include/boost/function/detail/maybe_include.hpp:13,
                 from /usr/include/boost/function/function0.hpp:11,
                 from /usr/include/boost/python/errors.hpp:13,
                 from /usr/include/boost/python/handle.hpp:11,
                 from /usr/include/boost/python/args_fwd.hpp:10,
                 from /usr/include/boost/python/args.hpp:10,
                 from /usr/include/boost/python.hpp:11,
                 from src/wrapper/common.hpp:24,
                 from src/wrapper/basics.cpp:34:
/usr/lib/gcc/x86_64-pc-linux-gnu/6.4.0/include/g++-v6/bits/unique_ptr.h:49:28: note: declared here
   template<typename> class auto_ptr;
                            ^~~~~~~~
In file included from src/wrapper/basics.cpp:34:0:
src/wrapper/common.hpp:202:45: warning: ‘template<class> class std::auto_ptr’ is deprecated [-Wdeprecated-declarations]
   void PointerList_append(List<Value *> &l, auto_ptr<Value> v)
                                             ^~~~~~~~
In file included from /usr/lib/gcc/x86_64-pc-linux-gnu/6.4.0/include/g++-v6/memory:81:0,
                 from /usr/include/boost/function/function_base.hpp:16,
                 from /usr/include/boost/function/detail/prologue.hpp:17,
                 from /usr/include/boost/function/function_template.hpp:13,
                 from /usr/include/boost/function/detail/maybe_include.hpp:13,
                 from /usr/include/boost/function/function0.hpp:11,
                 from /usr/include/boost/python/errors.hpp:13,
                 from /usr/include/boost/python/handle.hpp:11,
                 from /usr/include/boost/python/args_fwd.hpp:10,
                 from /usr/include/boost/python/args.hpp:10,
                 from /usr/include/boost/python.hpp:11,
                 from src/wrapper/common.hpp:24,
                 from src/wrapper/basics.cpp:34:
/usr/lib/gcc/x86_64-pc-linux-gnu/6.4.0/include/g++-v6/bits/unique_ptr.h:49:28: note: declared here
   template<typename> class auto_ptr;
                            ^~~~~~~~
x86_64-pc-linux-gnu-g++-6.4.0 -march=k8-sse3 -mcx16 -msahf --param l1-cache-size=64 --param l1-cache-line-size=64 --param l2-cache-size=512 -O2 -pipe -frecord-gcc-switches -fPIC -I/usr/include/taglib -I/usr/include/python2.7 -c src/wrapper/id3.cpp -o /tmp/portage/dev-python/tagpy-2018.1.1/work/tagpy-2018.1.1-python2_7/build/temp.linux-x86_64-2.7/src/wrapper/id3.o
distcc[29292] (dcc_readx) ERROR: unexpected eof on fd6
distcc[29292] Warning: failed to distribute src/wrapper/id3.cpp to pomiocik.local/2, running locally instead
distcc[29292] ERROR: compile src/wrapper/id3.cpp on localhost failed
In file included from src/wrapper/id3.cpp:40:0:
src/wrapper/common.hpp:191:62: warning: ‘template<class> class std::auto_ptr’ is deprecated [-Wdeprecated-declarations]
   void PointerList_setitem(List<Value *> &l, TagLib::uint i, auto_ptr<Value> v)
                                                              ^~~~~~~~
In file included from /usr/lib/gcc/x86_64-pc-linux-gnu/6.4.0/include/g++-v6/memory:81:0,
                 from /usr/include/boost/function/function_base.hpp:16,
                 from /usr/include/boost/function/detail/prologue.hpp:17,
                 from /usr/include/boost/function/function_template.hpp:13,
                 from /usr/include/boost/function/detail/maybe_include.hpp:13,
                 from /usr/include/boost/function/function0.hpp:11,
                 from /usr/include/boost/python/errors.hpp:13,
                 from /usr/include/boost/python/handle.hpp:11,
                 from /usr/include/boost/python/args_fwd.hpp:10,
                 from /usr/include/boost/python/args.hpp:10,
                 from /usr/include/boost/python.hpp:11,
                 from src/wrapper/common.hpp:24,
                 from src/wrapper/id3.cpp:40:
/usr/lib/gcc/x86_64-pc-linux-gnu/6.4.0/include/g++-v6/bits/unique_ptr.h:49:28: note: declared here
   template<typename> class auto_ptr;
                            ^~~~~~~~
In file included from src/wrapper/id3.cpp:40:0:
src/wrapper/common.hpp:202:45: warning: ‘template<class> class std::auto_ptr’ is deprecated [-Wdeprecated-declarations]
   void PointerList_append(List<Value *> &l, auto_ptr<Value> v)
                                             ^~~~~~~~
In file included from /usr/lib/gcc/x86_64-pc-linux-gnu/6.4.0/include/g++-v6/memory:81:0,
                 from /usr/include/boost/function/function_base.hpp:16,
                 from /usr/include/boost/function/detail/prologue.hpp:17,
                 from /usr/include/boost/function/function_template.hpp:13,
                 from /usr/include/boost/function/detail/maybe_include.hpp:13,
                 from /usr/include/boost/function/function0.hpp:11,
                 from /usr/include/boost/python/errors.hpp:13,
                 from /usr/include/boost/python/handle.hpp:11,
                 from /usr/include/boost/python/args_fwd.hpp:10,
                 from /usr/include/boost/python/args.hpp:10,
                 from /usr/include/boost/python.hpp:11,
                 from src/wrapper/common.hpp:24,
                 from src/wrapper/id3.cpp:40:
/usr/lib/gcc/x86_64-pc-linux-gnu/6.4.0/include/g++-v6/bits/unique_ptr.h:49:28: note: declared here
   template<typename> class auto_ptr;
                            ^~~~~~~~
In file included from /usr/include/boost/type_traits/type_with_alignment.hpp:13:0,
                 from /usr/include/boost/type_traits/alignment_traits.hpp:13,
                 from /usr/include/boost/python/detail/type_traits.hpp:31,
                 from /usr/include/boost/python/cast.hpp:9,
                 from /usr/include/boost/python/handle.hpp:10,
                 from /usr/include/boost/python/args_fwd.hpp:10,
                 from /usr/include/boost/python/args.hpp:10,
                 from /usr/include/boost/python.hpp:11,
                 from src/wrapper/common.hpp:24,
                 from src/wrapper/id3.cpp:40:
/usr/include/boost/python/detail/defaults_def.hpp: In instantiation of ‘void boost::python::detail::define_with_defaults(const char*, const OverloadsT&, NameSpaceT&, const SigT&) [with OverloadsT = {anonymous}::render_overloads; NameSpaceT = boost::python::class_<TagLib::ID3v2::Tag, boost::noncopyable_::noncopyable, boost::python::bases<TagLib::Tag> >; SigT = boost::mpl::vector2<TagLib::ByteVector, TagLib::ID3v2::Tag&>]’:
/usr/include/boost/python/class.hpp:551:37:   required from ‘void boost::python::class_<T, X1, X2, X3>::def_maybe_overloads(const char*, SigT, const OverloadsT&, const boost::python::detail::overloads_base*) [with OverloadsT = {anonymous}::render_overloads; SigT = TagLib::ByteVector (TagLib::ID3v2::Tag::*)() const; W = TagLib::ID3v2::Tag; X1 = boost::noncopyable_::noncopyable; X2 = boost::python::bases<TagLib::Tag>; X3 = boost::python::detail::not_specified]’
/usr/include/boost/python/class.hpp:240:9:   required from ‘boost::python::class_<T, X1, X2, X3>::self& boost::python::class_<T, X1, X2, X3>::def(const char*, A1, const A2&) [with A1 = TagLib::ByteVector (TagLib::ID3v2::Tag::*)() const; A2 = {anonymous}::render_overloads; W = TagLib::ID3v2::Tag; X1 = boost::noncopyable_::noncopyable; X2 = boost::python::bases<TagLib::Tag>; X3 = boost::python::detail::not_specified; boost::python::class_<T, X1, X2, X3>::self = boost::python::class_<TagLib::ID3v2::Tag, boost::noncopyable_::noncopyable, boost::python::bases<TagLib::Tag> >]’
src/wrapper/id3.cpp:224:10:   required from here
/usr/include/boost/python/detail/defaults_def.hpp:246:7: error: static assertion failed: (stubs_type::max_args) <= mpl::size<SigT>::value
       BOOST_STATIC_ASSERT(
       ^
In file included from /usr/include/boost/python/overloads.hpp:11:0,
                 from /usr/include/boost/python.hpp:51,
                 from src/wrapper/common.hpp:24,
                 from src/wrapper/id3.cpp:40:
/usr/include/boost/python/detail/defaults_def.hpp:162:7: warning: ‘static void boost::python::detail::define_with_defaults_helper<N>::def(const char*, StubsT, boost::python::detail::keyword_range, const CallPolicies&, NameSpaceT&, const char*) [with StubsT = {anonymous}::render_overloads::non_void_return_type::gen<boost::mpl::vector2<TagLib::ByteVector, TagLib::ID3v2::Tag&> >; CallPolicies = boost::python::default_call_policies; NameSpaceT = boost::python::class_<TagLib::ID3v2::Tag, boost::noncopyable_::noncopyable, boost::python::bases<TagLib::Tag> >; int N = 1]’ used but never defined
       def(
       ^~~
In file included from /usr/include/boost/python/detail/defaults_def.hpp:14:0,
                 from /usr/include/boost/python/overloads.hpp:11,
                 from /usr/include/boost/python.hpp:51,
                 from src/wrapper/common.hpp:24,
                 from src/wrapper/id3.cpp:40:
/usr/include/boost/python/detail/defaults_gen.hpp:102:7: warning: ‘boost::python::default_call_policies boost::python::detail::overloads_common<DerivedT>::call_policies() const [with DerivedT = {anonymous}::render_overloads]’ used but never defined
       call_policies() const
       ^~~~~~~~~~~~~
error: command 'x86_64-pc-linux-gnu-g++-6.4.0' failed with exit status 1
inducer commented 6 years ago

For that, I would be happy to take a patch.

LeeiFrankJaw commented 5 years ago

I hit exactly the same error message when compiling with GCC.

usr/include/boost/python/detail/defaults_def.hpp:246:7: error: static assertion failed: (stubs_type::max_args) <= mpl::size<SigT>::value

However, with the output message of Clang, I was able to trace back to the cause and deleted one line to make it compile as mentioned in https://github.com/inducer/tagpy/commit/fb6d9a95f8ed1b0f347a82569a13e60a75c7e6d6#r34204294 .

src/wrapper/id3.cpp:83:11: error: no matching member function for call to 'render'
    MF_OL(render, 0, 1);
    ~~~~~~^~~~~~~~~~~~~
src/wrapper/id3.cpp:72:58: note: expanded from macro 'MF_OL'
  BOOST_PYTHON_MEMBER_FUNCTION_OVERLOADS(MF##_overloads, MF, MIN, MAX);
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~
/usr/include/boost/python/detail/defaults_gen.hpp:376:9: note: expanded from macro 'BOOST_PYTHON_MEMBER_FUNCTION_OVERLOADS'
        fname,                                                                              \
        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/boost/python/detail/defaults_gen.hpp:273:13: note: expanded from macro 'BOOST_PYTHON_GEN_MEM_FUNCTION_STUB'
            fname, non_void_return_type, n_args, n_dflts, return)                       \
            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
note: (skipping 15 expansions in backtrace; use -fmacro-backtrace-limit=0 to see all)
/usr/include/boost/preprocessor/tuple/rem.hpp:29:31: note: expanded from macro 'BOOST_PP_REM'
#    define BOOST_PP_REM(...) __VA_ARGS__
                              ^
/usr/include/boost/preprocessor/variadic/elem.hpp:26:89: note: expanded from macro 'BOOST_PP_VARIADIC_ELEM'
#        define BOOST_PP_VARIADIC_ELEM(n, ...) BOOST_PP_CAT(BOOST_PP_VARIADIC_ELEM_, n)(__VA_ARGS__,)
                                                                                        ^
/usr/include/boost/preprocessor/variadic/elem.hpp:28:47: note: expanded from macro 'BOOST_PP_VARIADIC_ELEM_0'
#    define BOOST_PP_VARIADIC_ELEM_0(e0, ...) e0
                                              ^
/usr/include/boost/python/detail/defaults_def.hpp:283:24: note: in instantiation of member function '(anonymous
      namespace)::render_overloads::non_void_return_type::gen<boost::mpl::vector2<TagLib::ByteVector, TagLib::ID3v2::Tag &> >::func_1'
      requested here
            , &StubsT::BOOST_PP_CAT(func_, BOOST_PP_ITERATION())
                       ^
/usr/include/boost/preprocessor/cat.hpp:22:32: note: expanded from macro 'BOOST_PP_CAT'
#    define BOOST_PP_CAT(a, b) BOOST_PP_CAT_I(a, b)
                               ^
/usr/include/boost/preprocessor/cat.hpp:29:34: note: expanded from macro 'BOOST_PP_CAT_I'
#    define BOOST_PP_CAT_I(a, b) a ## b
                                 ^
<scratch space>:95:1: note: expanded from here
func_1
^
/usr/include/boost/python/detail/defaults_def.hpp:171:36: note: in instantiation of function template specialization
      'boost::python::detail::define_stub_function<1>::define<(anonymous
      namespace)::render_overloads::non_void_return_type::gen<boost::mpl::vector2<TagLib::ByteVector, TagLib::ID3v2::Tag &> >,
      boost::python::default_call_policies, boost::python::class_<TagLib::ID3v2::Tag, boost::noncopyable_::noncopyable,
      boost::python::bases<TagLib::Tag, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_,
      mpl_::void_, mpl_::void_>, boost::python::detail::not_specified> >' requested here
          define_stub_function<N>::define(name, stubs, kw, policies, name_space, doc);
                                   ^
/usr/include/boost/python/detail/defaults_def.hpp:250:59: note: in instantiation of function template specialization
      'boost::python::detail::define_with_defaults_helper<1>::def<(anonymous
      namespace)::render_overloads::non_void_return_type::gen<boost::mpl::vector2<TagLib::ByteVector, TagLib::ID3v2::Tag &> >,
      boost::python::default_call_policies, boost::python::class_<TagLib::ID3v2::Tag, boost::noncopyable_::noncopyable,
      boost::python::bases<TagLib::Tag, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_,
      mpl_::void_, mpl_::void_>, boost::python::detail::not_specified> >' requested here
      define_with_defaults_helper<stubs_type::n_funcs-1>::def(
                                                          ^
/usr/include/boost/python/class.hpp:551:17: note: in instantiation of function template specialization
      'boost::python::detail::define_with_defaults<(anonymous namespace)::render_overloads, boost::python::class_<TagLib::ID3v2::Tag,
      boost::noncopyable_::noncopyable, boost::python::bases<TagLib::Tag, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_,
      mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_>, boost::python::detail::not_specified>,
      boost::mpl::vector2<TagLib::ByteVector, TagLib::ID3v2::Tag &> >' requested here
        detail::define_with_defaults(
                ^
/usr/include/boost/python/class.hpp:240:15: note: in instantiation of function template specialization
      'boost::python::class_<TagLib::ID3v2::Tag, boost::noncopyable_::noncopyable, boost::python::bases<TagLib::Tag, mpl_::void_,
      mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_>,
      boost::python::detail::not_specified>::def_maybe_overloads<(anonymous namespace)::render_overloads, TagLib::ByteVector
      (TagLib::ID3v2::Tag::*)() const>' requested here
        this->def_maybe_overloads(name, a1, a2, &a2);
              ^
src/wrapper/id3.cpp:224:10: note: in instantiation of function template specialization 'boost::python::class_<TagLib::ID3v2::Tag,
      boost::noncopyable_::noncopyable, boost::python::bases<TagLib::Tag, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_,
      mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_, mpl_::void_>, boost::python::detail::not_specified>::def<TagLib::ByteVector
      (TagLib::ID3v2::Tag::*)() const, (anonymous namespace)::render_overloads>' requested here
        .DEF_OVERLOADED_METHOD(render, ByteVector (cl::*)() const)
         ^
src/wrapper/common.hpp:44:3: note: expanded from macro 'DEF_OVERLOADED_METHOD'
  def(#NAME, (CAST) &cl::NAME, NAME##_overloads())
  ^
/usr/include/taglib/id3v2tag.h:355:18: note: candidate function not viable: no known conversion from '(anonymous
      namespace)::render_overloads::non_void_return_type::gen<boost::mpl::vector2<TagLib::ByteVector, TagLib::ID3v2::Tag &> >::T0'
      (aka 'mpl_::void_') to 'int' for 1st argument
      ByteVector render(int version) const;
                 ^
/usr/include/taglib/id3v2tag.h:346:18: note: candidate function not viable: requires 0 arguments, but 1 was provided
      ByteVector render() const;
                 ^
8 warnings and 2 errors generated.
error: command 'clang' failed with exit status 1