fedora-infra / pkgwat.api

Python API for querying the Fedora Packages webapp
http://pkgwat.rtfd.org
Other
9 stars 9 forks source link

not found renamed packets #9

Closed arielb2 closed 11 years ago

arielb2 commented 11 years ago

Using the method pkgwat.api.get not find renamed packages. results = pkgwat.api.get(paquete)

apparently this prevents display information. ---method get if pkg['name'] == package:

https://github.com/fedora-infra/pkgwat.api/blob/develop/pkgwat/api/__init__.py#L215

]$ python test_pkgwat.py {u'upstream_url': u'http://texstudio.sourceforge.net', u'description': u'TeXstudio, formerly known as TexmakerX is a fork of the\nLaTeX IDE TexMaker and gives you an environment where you can\neasily create and manage LaTeX documents.\nIt provides modern writing support, like interactive spell checking,\ncode folding and syntax highlighting.\nAlso it serves as a starting point from where you can easily run\nall necessary LaTeX tools.\nAlthough TeXstudio has a lot of additional features,\nit tries to be like an improved version of Texmaker,\nso it keeps it look .', u'summary': u'A feature-rich editor for LaTeX documents', u'link': u'texstudio', u'devel_owner': u'hannes', u'icon': u'texstudio', u'sub_pkgs': [], u'name': u'texstudio'} Traceback (most recent call last): File "test_pkgwat.py", line 34, in results = pkgwat.api.get(paquete) File "/usr/lib/python2.7/site-packages/pkgwat/api/init.py", line 218, in get raise KeyError("No such package %r found" % package) KeyError: "No such package 'texmakerx' found"

]# pkgwat search texmakerx Starting new HTTPS connection (1): apps.fedoraproject.org +-----------+-------------------------------------------+ | name | summary | +-----------+-------------------------------------------+ | texstudio | A feature-rich editor for LaTeX documents | +-----------+-------------------------------------------+

]# pkgwat info texmakerx Starting new HTTPS connection (1): apps.fedoraproject.org +--------------+----------------------------------------------------------------------+ | Field | Value | +--------------+----------------------------------------------------------------------+ | upstream_url | http://texstudio.sourceforge.net | | description | TeXstudio, formerly known as TexmakerX is a fork of the | | | LaTeX IDE TexMaker and gives you an environment where you can | | | easily create and manage LaTeX documents. | | | It provides modern writing support, like interactive spell checking, | | | code folding and syntax highlighting. | | | Also it serves as a starting point from where you can easily run | | | all necessary LaTeX tools. | | | Although TeXstudio has a lot of additional features, | | | it tries to be like an improved version of Texmaker, | | | so it keeps it look . | | summary | A feature-rich editor for LaTeX documents | | link | https://apps.fedoraproject.org/packages/texstudio | | devel_owner | hannes | | name | texmakerx | +--------------+----------------------------------------------------------------------+

other case is django

ralphbean commented 11 years ago

@arielb2, why did you close the issue? Did you find a solution?

arielb2 commented 11 years ago

sorry, I closed it by mistake

arielb2 commented 11 years ago

consulting the xapian database

]$ python query.py texmakerx texmakerx EXtexmakerxEX 50 0 8.70469120529 {u'upstream_url': u'http://texstudio.sourceforge.net', u'description': u'TeXstudio, formerly known as TexmakerX is a fork of the\nLaTeX IDE TexMaker and gives you an environment where you can\neasily create and manage LaTeX documents.\nIt provides modern writing support, like interactive spell checking,\ncode folding and syntax highlighting.\nAlso it serves as a starting point from where you can easily run\nall necessary LaTeX tools.\nAlthough TeXstudio has a lot of additional features,\nit tries to be like an improved version of Texmaker,\nso it keeps it look&feel.', u'name': u'texstudio', u'devel_owner': u'hannes', u'summary': u'A feature-rich editor for LaTeX documents', u'sub_pkgs': [], u'icon': u'texstudio'}

]$ python query.py texstudio texstudio EXtexstudioEX 100 0 28.973324271 {u'upstream_url': u'http://texstudio.sourceforge.net', u'description': u'TeXstudio, formerly known as TexmakerX is a fork of the\nLaTeX IDE TexMaker and gives you an environment where you can\neasily create and manage LaTeX documents.\nIt provides modern writing support, like interactive spell checking,\ncode folding and syntax highlighting.\nAlso it serves as a starting point from where you can easily run\nall necessary LaTeX tools.\nAlthough TeXstudio has a lot of additional features,\nit tries to be like an improved version of Texmaker,\nso it keeps it look&feel.', u'name': u'texstudio', u'devel_owner': u'hannes', u'summary': u'A feature-rich editor for LaTeX documents', u'sub_pkgs': [], u'icon': u'texstudio'}

arielb2 commented 11 years ago

What do you think of this patch? https://github.com/arielb2/pkgwat.api/commit/2ec8e1c8bf90df50f290d55b76774fe555bc477e

ralphbean commented 11 years ago

Commented on the commit.

ralphbean commented 11 years ago

@arielb2, should this issue be closed now that #10 has been merged?

arielb2 commented 11 years ago

so is