Django utiliza Trac para gestionar el trabajo realizado sobre la base de código. Trac es como un jardín cuidado por la comunidad contentivo de bugs que las personas han encontrado y las funcionalidades que desearían ver añadidas. Como en cualquier jardín, a veces hay maleza que arrancar y a veces hay flores y verduras que necesitan ser recogidas. Necesitamos su ayuda para separar unas de las otras y al final todos nos beneficiamos.
Como en todos los jardines, podemos aspirar a la perfección aunque en realidad no exista tal cosa. Incluso en el jardín más limpio todavía hay caracoles e insectos. En un jardín comunitario también hay personas útiles que, con las mejores intenciones, abonan la maleza y envenenan las rosas. Es tarea de la comunidad en su conjunto autogestionar, mantener los problemas al mínimo y educar a aquellos que entran a la comunidad, de modo que puedan convertirse en valiosos colaboradores.
Del mismo modo, aunque aspiramos a que Trac sea una perfecta representación del estado de avance de Django, reconocemos que esto simplemente no va a suceder. Admitimos que habrá errores distribuyendo la carga del mantenimiento de Trac. Trac es “preciso en la mayoría de los casos”, y tenemos en cuenta que a veces algo saldrá mal. Eso está bien. Somos perfeccionistas con las fechas de entrega.
Confiamos en que la comunidad siga participando, mantenga los tickets lo más exactos posibles, y presente temas de discusión en nuestras listas de correo cuando haya confusión o desacuerdo.
Django es un proyecto comunitario y cualquier contribución es de ayuda. ¡No podemos hacer esto sin usted!
Desafortunadamente, no todos los informes de errores y solicitudes de funcionalidades en el rastreador de tickets proporcionan todos los :doc: detalles necesarios <bugs-and-features>. Varios tickets podrían tener parches, pero dichos parches podrían no cumplircon todos los requisitos de un :ref: buen parche <patch-style>`.
One way to help out is to triage tickets that have been created by other users.
La mayor parte del flujo de trabajo se basa en el concepto de :ref: las etapas de clasificación de un ticket <triage-stages>. Cada etapa describe en que período de su ciclo de vida se encuentra un determinado ticket. Junto con un puñado de marcadores, este atributo fácilmente nos indica qué y por quién espera cada ticket.
Ya que una imagen vale más que mil palabras, vamos a empezar por ahí:
Tenemos dos roles en este esquema:
A modo de ejemplo, aquí vemos el ciclo de vida de un ticket promedio:
Algunos tickets necesitan mucha menos retroalimentación que este, pero, por otro lado, algunos tickets necesitan muchísima más.
A continuación, describimos con más detalles las diferentes etapas por las que tiene que pasar un ticket durante su ciclo de vida.
El ticket no ha sido revisado por alguien que se sintiera calificado para evaluar si el mismo contiene un tema válido, una funcionalidad viable o si se debe cerrar por cualquiera de los diversos motivos.
¡La gran zona gris! El significado absoluto de «aceptado» es que el problema descrito en el ticket es válido y está en alguna etapa en la que se puede trabajar. Además de eso existen varias consideraciones:
Aceptado + Sin Marcadores
The ticket is valid, but no one has submitted a patch for it yet. Often this means you could safely start writing a patch for it. This is generally more true for the case of accepted bugs than accepted features. A ticket for a bug that has been accepted means that the issue has been verified by at least one triager as a legitimate bug - and should probably be fixed if possible. An accepted new feature may only mean that one triager thought the feature would be good to have, but this alone does not represent a consensus view or imply with any certainty that a patch will be accepted for that feature. Seek more feedback before writing an extensive patch if you are in doubt.
Aceptado + Tiene Parche
The ticket is waiting for people to review the supplied patch. This means downloading the patch and trying it out, verifying that it contains tests and docs, running the test suite with the included patch, and leaving feedback on the ticket.
Aceptado + Tiene Parche + Necesita …
This means the ticket has been reviewed, and has been found to need further work. «Needs tests» and «Needs documentation» are self-explanatory. «Patch needs improvement» will generally be accompanied by a comment on the ticket explaining what is needed to improve the code.
The ticket was reviewed by any member of the community other than the person who supplied the patch and found to meet all the requirements for a commit-ready patch. A committer now needs to give the patch a final review prior to being committed. See the New contributors” FAQ for «My ticket has been in RFC forever! What should I do?»
This stage isn’t shown on the diagram. It’s used sparingly to keep track of high-level ideas or long term feature requests.
These tickets are uncommon and overall less useful since they don’t describe concrete actionable issues. They are enhancement requests that we might consider adding someday to the framework if an excellent patch is submitted. They are not a high priority.
A number of flags, appearing as checkboxes in Trac, can be set on a ticket:
This means the ticket has an associated patch. These will be reviewed to see if the patch is «good».
The following three fields (Needs documentation, Needs tests, Patch needs improvement) apply only if a patch has been supplied.
This flag is used for tickets with patches that need associated documentation. Complete documentation of features is a prerequisite before we can check them into the codebase.
This flags the patch as needing associated unit tests. Again, this is a required part of a valid patch.
This flag means that although the ticket has a patch, it’s not quite ready for checkin. This could mean the patch no longer applies cleanly, there is a flaw in the implementation, or that the code doesn’t meet our standards.
Tickets que requerirían parches pequeños y fáciles.
Los tickets deberían ser clasificados por tipos entre:
Los tickets se deben clasificar en componentes que indican a que área de la base del código Django pertenecen. Esto hace que los tickets estén mejor organizados y sean más fáciles de encontrar.
The severity attribute is used to identify blockers, that is, issues which should get fixed before releasing the next version of Django. Typically those issues are bugs causing regressions from earlier versions or potentially causing severe data losses. This attribute is quite rarely used and the vast majority of tickets have a severity of «Normal».
Es posible utilizar el atributo versión para indicar en qué versión se identificó el error reportado.
This flag is used for tickets that relate to User Interface and User Experiences questions. For example, this flag would be appropriate for user-facing features in forms or the admin interface.
You may add your username or email address to this field to be notified when new contributions are made to the ticket.
With this field you may label a ticket with multiple keywords. This can be useful, for example, to group several tickets of a same theme. Keywords can either be comma or space separated. Keyword search finds the keyword string anywhere in the keywords. For example, clicking on a ticket with the keyword «form» will yield similar tickets tagged with keywords containing strings such as «formset», «modelformset», and «ManagementForm».
When a ticket has completed its useful lifecycle, it’s time for it to be closed. Closing a ticket is a big responsibility, though. You have to be sure that the issue is really resolved, and you need to keep in mind that the reporter of the ticket may not be happy to have their ticket closed (unless it’s fixed, of course). If you’re not certain about closing a ticket, just leave a comment with your thoughts instead.
Si cierra un ticket, usted siempre debería asegurarse de lo siguiente:
Un ticket se puede solucionar de varias maneras:
If you believe that the ticket was closed in error – because you’re still having the issue, or it’s popped up somewhere else, or the triagers have made a mistake – please reopen the ticket and provide further information. Again, please do not reopen tickets that have been marked as «wontfix» and bring the issue to django-developers instead.
The triage process is primarily driven by community members. Really, ANYONE can help.
To get involved, start by creating an account on Trac. If you have an account but have forgotten your password, you can reset it using the password reset page.
Then, you can help out by:
Nota
The Reports page contains links to many useful Trac queries, including several that are useful for triaging tickets and reviewing patches as suggested above.
You can also find more Consejos para los nuevos colaboradores.
However, we do ask the following of all general community members working in the ticket database:
A regression is a bug that’s present in some newer version of Django but not in an older one. An extremely helpful piece of information is the commit that introduced the regression. Knowing the commit that caused the change in behavior helps identify if the change was intentional or if it was an inadvertent side-effect. Here’s how you can determine this.
Begin by writing a regression test for Django’s test suite for the issue. For
example, we’ll pretend we’re debugging a regression in migrations. After you’ve
written the test and confirmed that it fails on the latest master, put it in a
separate file that you can run standalone. For our example, we’ll pretend we
created tests/migrations/test_regression.py
, which can be run with:
$ ./runtests.py migrations.test_regression
Next, we mark the current point in history as being «bad» since the test fails:
$ git bisect bad
You need to start by "git bisect start"
Do you want me to do it for you [Y/n]? y
Now, we need to find a point in git history before the regression was
introduced (i.e. a point where the test passes). Use something like
git checkout HEAD~100
to checkout an earlier revision (100 commits earlier,
in this case). Check if the test fails. If so, mark that point as «bad»
(git bisect bad
), then checkout an earlier revision and recheck. Once you
find a revision where your test passes, mark it as «good»:
$ git bisect good
Bisecting: X revisions left to test after this (roughly Y steps)
...
Now we’re ready for the fun part: using git bisect run
to automate the rest
of the process:
$ git bisect run tests/runtests.py migrations.test_regression
You should see git bisect
use a binary search to automatically checkout
revisions between the good and bad commits until it finds the first «bad»
commit where the test fails.
Now, report your results on the Trac ticket, and please include the regression test as an attachment. When someone writes a fix for the bug, they’ll already have your test as a starting point.
dic. 02, 2019