Skip to content

Commit 8524013

Browse files
avallbonanessita
authored andcommitted
Replaced usage of "patch" with more precise terms in faq, howto, and intro docs.
1 parent 3556f63 commit 8524013

File tree

4 files changed

+60
-61
lines changed

4 files changed

+60
-61
lines changed

docs/faq/contributing.txt

+16-16
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ How can I get started contributing code to Django?
1010
Thanks for asking! We've written an entire document devoted to this question.
1111
It's titled :doc:`Contributing to Django </internals/contributing/index>`.
1212

13-
I submitted a bug fix in the ticket system several weeks ago. Why are you ignoring my patch?
14-
============================================================================================
13+
I submitted a bug fix several weeks ago. Why are you ignoring my contribution?
14+
==============================================================================
1515

1616
Don't worry: We're not ignoring you!
1717

@@ -34,21 +34,21 @@ that area of the code, to understand the problem and verify the fix:
3434
database, are those instructions clear enough even for someone not
3535
familiar with it?
3636

37-
* If there are several patches attached to the ticket, is it clear what
38-
each one does, which ones can be ignored and which matter?
37+
* If there are several branches linked to the ticket, is it clear what each one
38+
does, which ones can be ignored and which matter?
3939

40-
* Does the patch include a unit test? If not, is there a very clear
40+
* Does the change include a unit test? If not, is there a very clear
4141
explanation why not? A test expresses succinctly what the problem is,
42-
and shows that the patch actually fixes it.
42+
and shows that the branch actually fixes it.
4343

44-
If your patch stands no chance of inclusion in Django, we won't ignore it --
45-
we'll just close the ticket. So if your ticket is still open, it doesn't mean
44+
If your contribution is not suitable for inclusion in Django, we won't ignore
45+
it -- we'll close the ticket. So if your ticket is still open, it doesn't mean
4646
we're ignoring you; it just means we haven't had time to look at it yet.
4747

48-
When and how might I remind the team of a patch I care about?
49-
=============================================================
48+
When and how might I remind the team of a change I care about?
49+
==============================================================
5050

51-
A polite, well-timed message to the mailing list is one way to get attention.
51+
A polite, well-timed message in the forum/branch is one way to get attention.
5252
To determine the right time, you need to keep an eye on the schedule. If you
5353
post your message right before a release deadline, you're not likely to get the
5454
sort of attention you require.
@@ -68,11 +68,11 @@ issue over and over again. This sort of behavior will not gain you any
6868
additional attention -- certainly not the attention that you need in order to
6969
get your issue addressed.
7070

71-
But I've reminded you several times and you keep ignoring my patch!
72-
===================================================================
71+
But I've reminded you several times and you keep ignoring my contribution!
72+
==========================================================================
7373

74-
Seriously - we're not ignoring you. If your patch stands no chance of
75-
inclusion in Django, we'll close the ticket. For all the other tickets, we
74+
Seriously - we're not ignoring you. If your contribution is not suitable for
75+
inclusion in Django, we will close the ticket. For all the other tickets, we
7676
need to prioritize our efforts, which means that some tickets will be
7777
addressed before others.
7878

@@ -83,7 +83,7 @@ are edge cases.
8383

8484
Another reason that a bug might be ignored for a while is if the bug is a
8585
symptom of a larger problem. While we can spend time writing, testing and
86-
applying lots of little patches, sometimes the right solution is to rebuild. If
86+
applying lots of little changes, sometimes the right solution is to rebuild. If
8787
a rebuild or refactor of a particular component has been proposed or is
8888
underway, you may find that bugs affecting that component will not get as much
8989
attention. Again, this is a matter of prioritizing scarce resources. By

docs/howto/windows.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ This document will guide you through installing Python 3.12 and Django on
66
Windows. It also provides instructions for setting up a virtual environment,
77
which makes it easier to work on Python projects. This is meant as a beginner's
88
guide for users working on Django projects and does not reflect how Django
9-
should be installed when developing patches for Django itself.
9+
should be installed when developing changes for Django itself.
1010

1111
The steps in this guide have been tested with Windows 10. In other
1212
versions, the steps would be similar. You will need to be familiar with using

docs/index.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ Are you new to Django or to programming? This is the place to start!
2727

2828
* **Advanced Tutorials:**
2929
:doc:`How to write reusable apps <intro/reusable-apps>` |
30-
:doc:`Writing your first patch for Django <intro/contributing>`
30+
:doc:`Writing your first contribution to Django <intro/contributing>`
3131

3232
Getting help
3333
============

docs/intro/contributing.txt

+42-43
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
===================================
2-
Writing your first patch for Django
3-
===================================
1+
==========================================
2+
Writing your first contribution for Django
3+
==========================================
44

55
Introduction
66
============
@@ -52,16 +52,16 @@ __ https://web.libera.chat/#django-dev
5252
What does this tutorial cover?
5353
------------------------------
5454

55-
We'll be walking you through contributing a patch to Django for the first time.
55+
We'll be walking you through contributing to Django for the first time.
5656
By the end of this tutorial, you should have a basic understanding of both the
5757
tools and the processes involved. Specifically, we'll be covering the following:
5858

5959
* Installing Git.
6060
* Downloading a copy of Django's development version.
6161
* Running Django's test suite.
62-
* Writing a test for your patch.
63-
* Writing the code for your patch.
64-
* Testing your patch.
62+
* Writing a test for your changes.
63+
* Writing the code for your changes.
64+
* Testing your changes.
6565
* Submitting a pull request.
6666
* Where to look for more information.
6767

@@ -91,7 +91,7 @@ Installing Git
9191
==============
9292

9393
For this tutorial, you'll need Git installed to download the current
94-
development version of Django and to generate patch files for the changes you
94+
development version of Django and to generate a branch for the changes you
9595
make.
9696

9797
To check whether or not you have Git installed, enter ``git`` into the command
@@ -178,7 +178,7 @@ Go ahead and install the previously cloned copy of Django:
178178

179179
The installed version of Django is now pointing at your local copy by installing
180180
in editable mode. You will immediately see any changes you make to it, which is
181-
of great help when writing your first patch.
181+
of great help when writing your first contribution.
182182

183183
Creating projects with a local copy of Django
184184
---------------------------------------------
@@ -188,8 +188,8 @@ have to create a new virtual environment, :ref:`install the previously cloned
188188
local copy of Django in editable mode <intro-contributing-install-local-copy>`,
189189
and create a new Django project outside of your local copy of Django. You will
190190
immediately see any changes you make to Django in your new project, which is
191-
of great help when writing your first patch, especially if testing any changes
192-
to the UI.
191+
of great help when writing your first contribution, especially if testing
192+
any changes to the UI.
193193

194194
You can follow the :doc:`tutorial</intro/tutorial01>` for help in creating a
195195
Django project.
@@ -279,8 +279,8 @@ imaginary details:
279279

280280
We'll now implement this feature and associated tests.
281281

282-
Creating a branch for your patch
283-
================================
282+
Creating a branch
283+
=================
284284

285285
Before making any changes, create a new branch for the ticket:
286286

@@ -295,19 +295,19 @@ won't affect the main copy of the code that we cloned earlier.
295295
Writing some tests for your ticket
296296
==================================
297297

298-
In most cases, for a patch to be accepted into Django it has to include tests.
299-
For bug fix patches, this means writing a regression test to ensure that the
300-
bug is never reintroduced into Django later on. A regression test should be
301-
written in such a way that it will fail while the bug still exists and pass
302-
once the bug has been fixed. For patches containing new features, you'll need
303-
to include tests which ensure that the new features are working correctly.
304-
They too should fail when the new feature is not present, and then pass once it
305-
has been implemented.
298+
In most cases, for a contribution to be accepted into Django it has to include
299+
tests. For bug fix contributions, this means writing a regression test to
300+
ensure that the bug is never reintroduced into Django later on. A regression
301+
test should be written in such a way that it will fail while the bug still
302+
exists and pass once the bug has been fixed. For contributions containing new
303+
features, you'll need to include tests which ensure that the new features are
304+
working correctly. They too should fail when the new feature is not present,
305+
and then pass once it has been implemented.
306306

307307
A good way to do this is to write your new tests first, before making any
308308
changes to the code. This style of development is called
309309
`test-driven development`__ and can be applied to both entire projects and
310-
single patches. After writing your tests, you then run them to make sure that
310+
single changes. After writing your tests, you then run them to make sure that
311311
they do indeed fail (since you haven't fixed that bug or added that feature
312312
yet). If your new tests don't fail, you'll need to fix them so that they do.
313313
After all, a regression test that passes regardless of whether a bug is present
@@ -398,7 +398,7 @@ function to the correct file.
398398
Running Django's test suite for the second time
399399
===============================================
400400

401-
Once you've verified that your patch and your test are working correctly, it's
401+
Once you've verified that your changes and test are working correctly, it's
402402
a good idea to run the entire Django test suite to verify that your change
403403
hasn't introduced any bugs into other areas of Django. While successfully
404404
passing the entire test suite doesn't guarantee your code is bug free, it does
@@ -450,7 +450,7 @@ preview the HTML that will be generated.
450450
Previewing your changes
451451
=======================
452452

453-
Now it's time to go through all the changes made in our patch. To stage all the
453+
Now it's time to review the changes made in the branch. To stage all the
454454
changes ready for commit, run:
455455

456456
.. console::
@@ -528,12 +528,11 @@ Use the arrow keys to move up and down.
528528
+ def test_make_toast(self):
529529
+ self.assertEqual(make_toast(), 'toast')
530530

531-
When you're done previewing the patch, hit the ``q`` key to return to the
532-
command line. If the patch's content looked okay, it's time to commit the
533-
changes.
531+
When you're done previewing the changes, hit the ``q`` key to return to the
532+
command line. If the diff looked okay, it's time to commit the changes.
534533

535-
Committing the changes in the patch
536-
===================================
534+
Committing the changes
535+
======================
537536

538537
To commit the changes:
539538

@@ -551,7 +550,7 @@ message guidelines <committing-guidelines>` and write a message like:
551550
Pushing the commit and making a pull request
552551
============================================
553552

554-
After committing the patch, send it to your fork on GitHub (substitute
553+
After committing the changes, send it to your fork on GitHub (substitute
555554
"ticket_99999" with the name of your branch if it's different):
556555

557556
.. console::
@@ -563,7 +562,7 @@ You can create a pull request by visiting the `Django GitHub page
563562
recently pushed branches". Click "Compare & pull request" next to it.
564563

565564
Please don't do it for this tutorial, but on the next page that displays a
566-
preview of the patch, you would click "Create pull request".
565+
preview of the changes, you would click "Create pull request".
567566

568567
Next steps
569568
==========
@@ -578,14 +577,14 @@ codebase.
578577
More information for new contributors
579578
-------------------------------------
580579

581-
Before you get too into writing patches for Django, there's a little more
580+
Before you get too into contributing to Django, there's a little more
582581
information on contributing that you should probably take a look at:
583582

584583
* You should make sure to read Django's documentation on
585-
:doc:`claiming tickets and submitting patches
584+
:doc:`claiming tickets and submitting pull requests
586585
</internals/contributing/writing-code/submitting-patches>`.
587586
It covers Trac etiquette, how to claim tickets for yourself, expected
588-
coding style for patches, and many other important details.
587+
coding style (both for code and docs), and many other important details.
589588
* First time contributors should also read Django's :doc:`documentation
590589
for first time contributors</internals/contributing/new-contributors/>`.
591590
It has lots of good advice for those of us who are new to helping out
@@ -600,19 +599,19 @@ Finding your first real ticket
600599
------------------------------
601600

602601
Once you've looked through some of that information, you'll be ready to go out
603-
and find a ticket of your own to write a patch for. Pay special attention to
602+
and find a ticket of your own to contribute to. Pay special attention to
604603
tickets with the "easy pickings" criterion. These tickets are often much
605604
simpler in nature and are great for first time contributors. Once you're
606-
familiar with contributing to Django, you can move on to writing patches for
607-
more difficult and complicated tickets.
605+
familiar with contributing to Django, you can start working on more difficult
606+
and complicated tickets.
608607

609608
If you just want to get started already (and nobody would blame you!), try
610-
taking a look at the list of `easy tickets that need patches`__ and the
611-
`easy tickets that have patches which need improvement`__. If you're familiar
609+
taking a look at the list of `easy tickets without a branch`__ and the
610+
`easy tickets that have branches which need improvement`__. If you're familiar
612611
with writing tests, you can also look at the list of
613612
`easy tickets that need tests`__. Remember to follow the guidelines about
614613
claiming tickets that were mentioned in the link to Django's documentation on
615-
:doc:`claiming tickets and submitting patches
614+
:doc:`claiming tickets and submitting branches
616615
</internals/contributing/writing-code/submitting-patches>`.
617616

618617
__ https://code.djangoproject.com/query?status=new&status=reopened&has_patch=0&easy=1&col=id&col=summary&col=status&col=owner&col=type&col=milestone&order=priority
@@ -622,9 +621,9 @@ __ https://code.djangoproject.com/query?status=new&status=reopened&needs_tests=1
622621
What's next after creating a pull request?
623622
------------------------------------------
624623

625-
After a ticket has a patch, it needs to be reviewed by a second set of eyes.
624+
After a ticket has a branch, it needs to be reviewed by a second set of eyes.
626625
After submitting a pull request, update the ticket metadata by setting the
627626
flags on the ticket to say "has patch", "doesn't need tests", etc, so others
628-
can find it for review. Contributing doesn't necessarily always mean writing a
629-
patch from scratch. Reviewing existing patches is also a very helpful
627+
can find it for review. Contributing doesn't necessarily always mean writing
628+
code from scratch. Reviewing open pull requests is also a very helpful
630629
contribution. See :doc:`/internals/contributing/triaging-tickets` for details.

0 commit comments

Comments
 (0)