Translations by Jose Luis Tirado
Jose Luis Tirado has submitted the following strings to this translation. Contributions are visually coded: currently used translations, unreviewed suggestions, rejected suggestions.
~ |
Along with ``lintian``, there is a special tool for checking Python packages — ``lintian4py``. It is available in the `lintian4python`_ package. For example, these two commands invoke both versions of ``lintian`` and check source and binary packages::
|
|
2012-10-23 |
Junto con ``lintian``, hay una herramienta especial para comprobar paquetes Python, ``lintian4py``. Está disponible en el paquete `lintian4python`_. Por ejemplo, estas dos órdenes invocan a las dos versiones de ``lintian`` y comprueban los paquetes fuentes y binarios::
|
|
~ |
In our case we established that we have a problem with the packaging, both in Ubuntu and Debian. As Ubuntu is based on Debian, we will send the fix to Debian. Once it is included there, it will be picked up by Ubuntu eventually. The issue in our tutorial is clearly non-critical, so this approach makes sense. If it is important to fix the issue as soon as possible, you will need to send the solution to multiple bug trackers. Provided the issue affects all parties in question.
|
|
2012-10-23 |
En nuestro caso establecimos que tenemos un problema con el empaquetado, tanto en Ubuntu como en Debian. Como Ubuntu se basa en Debian, enviaremos la corrección a Debian. Una vez que se incluya ahí, será recogida por Ubuntu en algún momento. La incidencia en nuestro tutorial claramente es no crítica, así que este enfoque tiene sentido. Si fuera importante corregir la incidencia cuanto antes, necesitará enviar la corrección a varios registros de errores, suponiendo que la incidencia afecte a todas las partes en cuestión.
|
|
~ |
In some cases, you may need to use these tools instead of UDD. So it is good to be familiar with them. Before you begin, you should already have read the article :doc:`Getting Set Up. <./getting-set-up>`
|
|
2012-10-23 |
En algunos casos, puede que necesite estas herramientas en lugar de UDD. Así que es recomendable estar familiarizado con ellas. Antes de que comience, debería haber leído ya el artículo sobre la preparación de la configuración (:doc:`Getting Set Up. <./getting-set-up>`).
|
|
~ |
The majority of this guide deals with :doc:`Ubuntu Distributed Development <./udd-intro>` (UDD) which utilizes the distributed version control system (DVCS) Bazaar for :ref:`retrieving package sources <branching>` and submitting fixes with :ref:`merge proposals. <merge-proposal>` This article will discuss what we will call traditional packaging methods for lack of a better word. Before Bazaar was adopted for Ubuntu development, these were the typical methods for contributing to Ubuntu.
|
|
2012-10-23 |
La mayor parte de esta guía trata del desarrollo distribuido de Ubuntu (:doc:`Ubuntu Distributed Development <./udd-intro>` (UDD)) que emplea el sistema de control de versiones distribuido (DVCS) Bazaar para obtener los paquetes fuentes ( :ref:`retrieving package sources <branching>`) y enviar correcciones con propuestas de integración (:ref:`merge proposals. <merge-proposal>`). Esta artículo explicará lo que denominamos métodos de empaquetado tradicional, a falta de una palabra mejor. Antes de que se adoptara Bazaar para el desarrollo de Ubuntu estos eran los métodos típicos para contribuir a Ubuntu.
|
|
~ |
At the time of writing this article this was not fixed yet. When you are reading the article this might actually be fixed. Take this as an example and try to adapt it to the specific problem you are facing.
|
|
2012-10-23 |
En el momento de escribir este artículo esto no había sido corregido todavía, aunque es posible que para cuando esté leyéndolo ya se haya solucionado. Tómelo como un ejemplo e intente adaptarlo al problema concreto que está afrontando.
|
|
~ |
For our example, let's pretend we got a bug report saying that "colour" in the description of ``xicc`` should be "color," and we want to fix it. *(Note: This is just an example of something to change and not really a bug.)* To get the source, run::
|
|
2012-10-23 |
Para nuestro ejemplo, vamos a suponer que tenemos un informe de error que dice que el «colour» en la descripción de ``xicc`` debería ser «color» y deseamos corregirlo *(tenga en cuenta que esto es sólo un ejemplo de algo a cambiar y no un error de verdad)*. Para obtener el código fuente, ejecute::
|
|
~ |
Thousands of source packages, billions of lines of code, hundreds of contributors require a lot of communication and planning to maintain high standards of quality. At the beginning of each release cycle we have the Ubuntu Developer Summit where developers and contributors come together to plan the features of the next releases. Every feature is discussed by its stakeholders and a specification is written that contains detailed information about its assumptions, implementation, the necessary changes in other places, how to test it and so on. This is all done in an open and transparent fashion, so even if you cannot attend the event in person, you can participate remotely and listen to a streamcast, chat with attendants and subscribe to changes of specifications, so you are always up to date.
|
|
2012-10-23 |
Miles de los paquetes fuente, miles de millones de líneas de código, cientos de contribuyentes requieren de mucha comunicación y de una planificación para mantener altos estándares de calidad. Al principio de cada ciclo de emisión tiene lugar la «Ubuntu Developer Summit» (cumbre de desarrolladores de Ubuntu) en la que los desarrolladores y contribuyentes se juntan para planificar las características de las próximas versiones. Cada característica es discutida por sus accionistas y se escribe una especificación que contiene información detallada sobre sus supuestos, implementación, cambios necesarios en otras partes, cómo probarla y así sucesivamente. Todo esto se hace de forma abierta y transparente, así que incluso si no puede asistir al evento en persona, puede participar de forma remota y escuchar una transmisión, chalar con los asistentes y suscribirse a cambios en las especificaciones, de forma que siempre esté al día.
|
|
~ |
If your package is an application and has private Python modules, they should be installed in ``/usr/share/module``, or ``/usr/lib/module`` if the modules are architecture-dependent (e.g. extensions) (see “`Programs Shipping Private Modules`_” section of the Policy).
|
|
2012-10-23 |
Si su paquete es una aplicación y tiene módulos de Python privados, debería instalarse en ``/usr/share/module`` o en ``/usr/lib/module` si los módulos son dependientes de la arquitectura (por ejemplo, extensiones). Véase la sección de programas que incluyen módulos privados (“`Programs Shipping Private Modules`_”) de la política.
|
|
~ |
If the problem is just in Ubuntu, you might want to consider :doc:`Seeking Review and Sponsorship<./udd-sponsorship>` to get the fix included.
|
|
2012-10-23 |
Si el problema está solo en Ubuntu, debería considerar pedir que lo revisen y lo patrocinen (:doc:`Seeking Review and Sponsorship<./udd-sponsorship>`) para que se incluya la corrección.
|
|
~ |
to pull the source from the ``precise`` release, or::
|
|
2012-10-23 |
para extraer el código fuente de la emisión ``precise`` o::
|
|
~ |
This method has some draw backs though. It downloads the version of the source that is available on **your system.** You are likely running the current stable release, but you want to contribute your change against the package in the development release. Luckily, the ``ubuntu-dev-tools`` package provides a helper script::
|
|
2012-10-23 |
Este método, sin embargo, tiene algunos inconvenientes. Descarga la versión del código fuente que está disponible en **su sistema**. El probable que esté corriendo la emisión estable actual, pero que desee contribuir su cambio contra el paquete de la versión en desarrollo. Afortunadamente, el paquete ``ubuntu-dev-tools`` le proporciona un asistente::
|
|
~ |
If you read :doc:`the Debian Directory Overview<./debian-dir-overview>` before, you might remember, that the homepage for a package is specified in the first part of ``debian/control``, the section which starts with ``Source:``.
|
|
2012-10-23 |
Si ha leído antes sobre la visión general del directorio de Debian (:doc:`the Debian Directory Overview<./debian-dir-overview>`), podría recordar que la página web para un paquete se indica en la primera parte del archivo ``debian/control``, la sección que comienza con ``Source:``.
|
|
~ |
and edit ``debian/control`` to add ``Homepage: http://www.linux-games.com/bumprace/``. At the end of the first section should be a good place for it. Once you have done this, save the file.
|
|
2012-10-23 |
y editar ``debian/control`` para añadir ``Homepage: http://www.linux-games.com/bumprace/``. Al final de la primera sección debería ser un buen lugar. Una vez que lo haya hecho, guarde el archivo.
|
|
~ |
The diff is pretty simple to understand. The ``+`` indicates a line which was added. In our cases it was added just before the second section, starting with ``Package``, which indicates a resulting binary package.
|
|
2012-10-23 |
Este diff es bastante simple de comprender. El ``+`` indica una línea que ha sido añadida. En nuestros caso se ha añadido justo antes de la segunda sección, comenzado con ``Package``, lo que indica un paquete binario resultante.
|
|
~ |
It is important to explain to your fellow developers what exactly you did. If you run::
|
|
2012-10-23 |
Es importante explicar a sus compañeros desarrolladores lo que hizo exactamente. Si ejecuta::
|
|
~ |
By default, the latest version in the development release will be downloaded. You can also specify a version or Ubuntu release like::
|
|
2012-10-23 |
De forma predeterminada, se descargará la última versión de la emisión en desarrollo. Puede también indicar una versión o emisión de Ubuntu como::
|
|
~ |
this will start an editor with a boilerplate changelog entry which you just have to fill out. In our case something like ``debian/control: Added project's homepage.`` should do. Then save the file. To double-check this worked out, run::
|
|
2012-10-23 |
esto iniciará un editor con una entrada modelo del registro de cambios (changelog) que solo tiene que rellenar. En nuestro caso bastaría algo como ``debian/control: Added project's homepage.`` (debian/control: añadida página web del proyecto). A continuación guarde el archivo. Para comprobar nuevamente que ha funcionado, ejecute::
|
|
~ |
To test the fix, you need to :doc:`have your development environment set up<./getting-set-up>`, then to build the package, install it and verify the problem is solved. In our case this would be::
|
|
2012-10-23 |
Para probar la corrección necesita configurar su entorno de desarrollo (:doc:`have your development environment set up<./getting-set-up>`), luego compilar el paquete, instalarlo y verificar que se ha solucionado el problema. En nuestro caso sería::
|
|
~ |
Python 2.x modules are installed into ``/usr/share/pyshared/`` directory, and symbolic links are created in ``/usr/lib/python2.x/dist-packages/`` for every interpreter version, while Python 3.x ones are all installed into ``/usr/lib/python3/dist-packages/``.
|
|
2012-10-23 |
Los módulos de Python ".x se instalan en el directorio ``/usr/share/pyshared/`` y se crean enlaces simbólicos en ``/usr/lib/python2.x/dist-packages/`` para cada versión del intérprete, mientras que los de Python 3.x se instalan en ``/usr/lib/python3/dist-packages/``.
|
|
~ |
In step one we build the source package from the branch, then build it by using ``pbuilder``, then inspect the resulting package to check if the Homepage field was added properly.
|
|
2012-10-23 |
En el primer paso compilamos el paquete fuente desde la rama, y luego lo compilamos usando ``pbuilder``, luego inspeccionamos el paquete resultante para comprobar si el campo «Homepage» (página web) se ha añadido correctamente.
|
|
~ |
to download version ``1.0-1ubuntu1`` of the package. For more information on the command, see ``man pull-lp-source``.
|
|
2012-10-23 |
para descargar la versión ``1.0-1ubuntu1`` del paquete. Para más información sobre la orden, véase ``man pull-lp-source``.
|
|
~ |
So, our ``python-markdown.install`` file will look like this (we’ll also want to install a ``markdown_py`` executable)::
|
|
2012-10-23 |
Así que nuestro archivo ``python-markdown.install`` se parecerá a esto (también queremos instalar un ejecutable ``markdown_py``)::
|
|
~ |
While the mechanics for :doc:`fixing a bug<./fixing-a-bug>` are the same for every bug, every problem you look at is likely to be different from another. An example of a concrete problem might help to get an idea what to consider generally.
|
|
2012-10-23 |
Aunque los mecanismos para corregir un error (:doc:`fixing a bug<./fixing-a-bug>`) son los mismos para cada error, cada problema al que se enfrente es probable que sea distinto de los demás. Un ejemplo de un problema concreto le podría ayudar a formar una idea de lo que tener en cuenta de forma general.
|
|
~ |
To submit the patch to Debian, simply run::
|
|
2012-10-21 |
Para enviar el parche a Debian, simplemente ejecute::
|
|
~ |
``bzr-builddeb`` (and ``bzr``, a dependency) -- distributed version control with Bazaar, a new way of working with packages for Ubuntu that will make it easy for many developers to collaborate and work on the same code while keeping it trivial to merge each other's work.
|
|
2012-10-21 |
``bzr-builddeb`` (y ``bzr``, una dependencia) -- sistema de control de versiones distribuido con Bazaar, una nueva forma de trabajar con paquetes para Ubuntu que facilitará a muchos desarrolladores colaborar y trabajar sobre el mismo código, haciendo que resulte sencillo combinar el trabajo de los demás.
|
|
~ |
If your branch fixes issues in stable releases or it is a security fix, you might want to have a look at our :doc:`Security and stable release updates<./security-and-stable-release-updates>` article.
|
|
2012-10-21 |
Si su rama correge incidencias en versiones estables o es una corrección de seguridad, es posible que le interese echar un vistazo al artículo :doc:`Security and stable release updates<./security-and-stable-release-updates>`.
|
|
~ |
Tutorial: Fixing a bug in Ubuntu
|
|
2012-10-21 |
Tutorial: corregir un error en Ubuntu
|
|
~ |
Download main package::
|
|
2012-10-21 |
Descargar el paquete «main»::
|
|
~ |
Sometimes you might want to make new functionality available in a stable release which is not connected to a critical bug fix. For these scenarios you have two options: either you `upload to a PPA <https://help.launchpad.net/Packaging/PPA>`_ or prepare a backport.
|
|
2012-10-21 |
En ocasiones podría desear hacer disponible una nueva funcionalidad de una emisión estable que no está relacionada con la corrección de un error crítico. Para estos escenarios existen dos opciones: o bien `upload to a PPA <https://help.launchpad.net/Packaging/PPA>`_ o bien prepara una adaptación a la versión antigua.
|
|
~ |
The `PPA documentation on Launchpad`_ is fairly comprehensive and should get you up and running in no time.
|
|
2012-10-21 |
`PPA documentation on Launchpad`_ es bastante completo y debería tenerlo funcionando en poco tiempo.
|
|
~ |
Our article about :doc:`seeking sponsorship<./udd-sponsorship>` goes into more detail about getting feedback for your proposed changes.
|
|
2012-10-21 |
Nuestro artículo sobre :doc:`seeking sponsorship<./udd-sponsorship>` entra en más detalle sobre cómo obtener respuesta a los cambios propuestos.
|
|
~ |
For this specific example it is enough to search the web for ``bumprace`` and find the homepage of it. Be sure it is a live site and not just a software catalogue. http://www.linux-games.com/bumprace/ looks like it is the proper place.
|
|
2012-10-21 |
Para este ejemplo concreto es suficiente con buscar en la web ``bumprace`` y encontrar su página web. asegúrese de que es un sitio que está vivo y no solo un catálogo de software. http://www.linux-games.com/bumprace/ tiene pinta de ser el lugar apropiado.
|
|
~ |
``bzr-builddeb`` includes a plugin to create a new package from a template. The plugin is a wrapper around the ``dh_make`` command. You should already have these if you installed ``packaging-dev``. Run the command providing the package name, version number, and path to the upstream tarball::
|
|
2012-10-21 |
``bzr-builddeb`` incluye un complemento para crear nuevos paquetes a partir de una plantilla. El complemento es un envoltorio alrededor de la orden ``dh_make``. Ya debería tenerlos instalados si instaló ``packaging-dev``. Ejecute la orden indicando el nombre del paquete, número de versión y la ruta al archivo tar de aguas arriba::
|
|
~ |
Packages which have ``autopkgtest`` enabled will have their tests run whenever they get uploaded or any of their reverse-dependencies change. The output of `automatically run autopkgtest tests`_ can be viewed on the web and is regularly updated.
|
|
2012-10-21 |
Los paquetes que tienen activado ``autopkgtest`` ejecutarán sus pruebas siempre que se suban o cambie alguna de sus dependencias inversas. La salida de `automatically run autopkgtest tests`_ se puede ver en la web y se actualiza de forma regular.
|
|
~ |
While Debian does not have an automatic testing infrastructure set up yet, they should still be submitted to Debian, as DEP-8 is a Debian specification and Debian developers or users can still manually run the tests.
|
|
2012-10-21 |
Aunque Debian no tiene todavía una infraestructura de pruebas automáticas, se deberían enviar igualmente a Debian, ya que DEP-8 es una especificación de Debian y sus desarrolladores o usuarios pueden ejecutar las pruebas manualmente.
|
|
~ |
In the `ubiquity tests`_ the upstream test-suite is executed.
|
|
2012-10-21 |
En `ubiquity tests`_ se ejecuta en conjunto de pruebas de aguas arriba.
|
|
~ |
The `gvfs tests`_ have comprehensive testing of their functionality and are very interesting because they emulate usage of CDs, Samba, DAV and other bits.
|
|
2012-10-21 |
`gvfs tests`_ realiza pruebas exhaustivas de su funcionalidad y son muy interesantes porque emulan el uso de CDs, Samba, DAV y otras cosas.
|
|
~ |
Packages in Debian with a testsuite header will also be automatically added when they are synced to Ubuntu.
|
|
2012-10-21 |
Los paquetes en Debian con una cabecera de conjunto de pruebas también serán añadidos automáticamente cuando se sincronicen con Ubuntu.
|
|
~ |
While this test is very small and basic, it tests quite a number of core components on a system. This may help to uncover critical issues early on.
|
|
2012-10-21 |
Aunque esta prueba es muy pequeña y básica, prueba un buen número de componentes del sistema. Esto puede ayudar a descubrir de forma temprana incidencias críticas.
|
|
~ |
In ``debian/tests/control`` you specify what to expect from the testbed. So for example you list all the required packages for the tests, if the testbed gets broken during the build or if ``root`` permissions are required. The `DEP 8 specification`_ lists all available options.
|
|
2012-10-21 |
En ``debian/tests/control`` se especifica lo que se espera del banco de pruebas. Así, por ejemplo, debe recoger todos los paquetes necesarios para las pruebas, si el banco de pruebas falla durante la compilación o si hacen falta permisos de ``root``.`DEP 8 specification`_ recoge todas las opciones disponibles.
|
|
~ |
The `libxml2 tests`_ are very similar. They also run a test-build of a simple piece of C code and execute it.
|
|
2012-10-21 |
`libxml2 tests`_ son muy parecidos. También realizan una generación de una prueba a partir de una porción de código C sencilla y la ejecutan.
|
|
~ |
add the following to the Source section in ``debian/control``::
|
|
2012-10-21 |
añadir lo siguiente a la sección Source de ``debian/control``::
|
|
~ |
The `gtk+3.0 tests`_ also do a compile/link/run check in the "build" test. There is an additional "python3-gi" test which verifies that the GTK library can also be used through introspection.
|
|
2012-10-21 |
`gtk+3.0 tests`_ también realiza una comprobación de compilación/enlace/ejecución en la prueba «build». Hay una prueba adicional «python3-gi» que verifica que la biblioteca GTK es accesible también mediante introspección.
|
|
~ |
write the ``debian/tests/control`` based on the `DEP 8 Specification`_,
|
|
2012-10-21 |
escribir el ``debian/tests/control`` basado en`DEP 8 Specification`_,
|
|
~ |
To address the issue in the source package, we first need the source and we can easily get it by running::
|
|
2012-10-21 |
Para afrontar la incidencia en el paquete fuente, necesitamos antes el código fuente, que puede ser obtenido fácilmente ejecuntando::
|
|
~ |
Then upgrade to the new version::
|
|
2012-10-21 |
Luego actualice a la nueva versión::
|
|
~ |
If you want to get your fix included in Debian, for a Debian bug the syntax is ``(Closes: #<bug number>)``, ie: ``(Closes: #123456)``.
|
|
2012-10-21 |
Si quiere hacer que su corrección se incluya en Debian, la sintaxis para un bug de Debian es ``(Closes: #<bug number>)``, por ejemplo: ``(Closes: #123456)``.
|
|
~ |
If it is a reference to an upstream or Debian bug or a mailing list discussion, mention it as well.
|
|
2012-10-21 |
Si es una referencia a un error aguas arriba o de Debian o a una discusión en una lista de correo, menciónelo también.
|
|
~ |
If you have a reference to a Launchpad bug which is fixed by the issue, add (``LP: #<bug number>``) to the changelog entry line, ie: ``(LP: #123456)``.
|
|
2012-10-21 |
Si tiene una referencia a un error en Launchpad que ha sido corregido por la incidencia, añada (``LP: #<bug number>``) a la línea de entrada del changelog, por ejemplo ``(LP: #123456)``.
|
|
~ |
Try to wrap your lines at 80 characters.
|
|
2012-10-21 |
Intente cortar las líneas a 80 caracteres.
|