{"title":"Mengajukan bantuan","version":"6.0","locale":"id","docname":"internals/contributing/writing-code/submitting-patches","url":"/id/6.0/internals/contributing/writing-code/submitting-patches/","canonical":"https://djangodocs.dev/id/6.0/internals/contributing/writing-code/submitting-patches/","summary":"We're always grateful for contributions to Django's code. Indeed, bug reports with associated contributions will get fixed far more quickly than those without a…","html":"<h1>Mengajukan bantuan<a class=\"heading-anchor\" href=\"#submitting-contributions\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h1>\n<p>We're always grateful for contributions to Django's code. Indeed, bug reports\nwith associated contributions will get fixed <em>far</em> more quickly than those\nwithout a solution.</p>\n<section id=\"typo-fixes-and-trivial-documentation-changes\">\n<span id=\"trivial-change\"></span><h2>Perbaikan kesalahan ketik dan perubahan dokumentasi sepele.<a class=\"heading-anchor\" href=\"#typo-fixes-and-trivial-documentation-changes\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h2>\n<p>Jika anda sedang memperbaiki masalah sepele, sebagai contoh merubah sebuah kata di dokumentasi, cara dipilih untuk menyediakan tambalan adalah menggunakan menarik permintaan GitHub tanpa tiket Trac.</p>\n<p>See <a class=\"reference internal\" href=\"/id/6.0/internals/contributing/writing-code/working-with-git/\"><span class=\"doc\">Bekerja dengan Git dan GitHub</span></a> for more\ndetails on how to use pull requests.</p>\n</section>\n<section id=\"claiming-tickets\">\n<span id=\"id1\"></span><h2>Tiket &quot;Meminta&quot;<a class=\"heading-anchor\" href=\"#claiming-tickets\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h2>\n<p>Dalam sebuah proyek sumber-terbuka dengan ratusan penyumbang diseluruh dunia, adalah sangat penting untuk mengelola komunikasi secara efektif sehingga pekerjaan tidak ganda dan penyumbang dapat menjadi seefektif mungkin.</p>\n<p>Oleh sebab itu, kebijakan kami untuk penyumbang dalam &quot;menagih&quot; tiket agar membiarkan pengembang lain mengetahui bahwa kesalahan atau fitur tertentu sedang dikerjakan.</p>\n<p>Jika anda telah mencirikan bantuan anda ingin membuat dan anda mampu memperbaikinya (yang diukur dengan kemampuan pengkodean anda, pengetahuan dari internal Django dan ketersediaan waktu), tagih dia dengan mengikuti langkah-langkah berikut:</p>\n<ul class=\"simple\">\n<li><p><a class=\"reference external\" href=\"https://code.djangoproject.com/github/login\">Log in using your GitHub account</a> or <a class=\"reference external\" href=\"https://www.djangoproject.com/accounts/register/\">create an account</a> in our ticket\nsystem. If you have an account but have forgotten your password, you can\nreset it using the <a class=\"reference external\" href=\"https://www.djangoproject.com/accounts/password/reset/\">password reset page</a>.</p></li>\n<li><p>If a ticket for this issue doesn't exist yet, create one in our\n<a class=\"reference external\" href=\"https://code.djangoproject.com/\">ticket tracker</a>. Remember that proposals for new features should follow\nthe <a class=\"reference internal\" href=\"/id/6.0/internals/contributing/bugs-and-features/#requesting-features\"><span class=\"std std-ref\">process for suggesting new features</span></a>.</p></li>\n<li><p>If a ticket for this issue already exists and has been accepted, make sure\nnobody else has claimed it. To do this, look at the &quot;Owned by&quot; section of\nthe ticket. If it's assigned to &quot;nobody,&quot; then it's available to be claimed.\nOtherwise, somebody else may be working on this ticket. Either find another\nbug/feature to work on, or contact the developer working on the ticket to\noffer your help. If a ticket has been assigned for weeks or months without\nany activity, it's probably safe to reassign it to yourself. If a ticket\nhasn't been approved yet, join the conversation.</p></li>\n<li><p>Log into your account, if you haven't already, by clicking &quot;GitHub Login&quot;\nor &quot;DjangoProject Login&quot; in the upper left of the ticket page. Once logged\nin, you can then click the &quot;Modify Ticket&quot; button near the bottom of the\npage.</p></li>\n<li><p>Claim the ticket by clicking the &quot;assign to&quot; radio button in the &quot;Action&quot;\nsection. Your username will be filled in the text box by default.</p></li>\n<li><p>Finally, click the &quot;Submit changes&quot; button at the bottom to save.</p></li>\n</ul>\n<aside class=\"admonition admonition-note\" role=\"note\">\n<p class=\"admonition-title\">Catatan</p>\n<p>If your change is not <a class=\"reference internal\" href=\"#trivial-change\"><span class=\"std std-ref\">trivial</span></a>, you have the option\nto sign and submit a <a class=\"reference external\" href=\"https://www.djangoproject.com/foundation/cla/\">Contributor License Agreement</a> clarifying the status\nof your contribution. This ensures that the Django Software Foundation has\nclear license to your contribution.</p>\n</aside>\n<section id=\"ticket-claimers-responsibility\">\n<h3>Tanggung jawab pengaku tiket<a class=\"heading-anchor\" href=\"#ticket-claimers-responsibility\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h3>\n<p>Sekali anda mengakui sebuah tiket, anda mempunyai tanggung jawab untuk bekerja pada tiket tepat waktu. Jika anda tidak mempunyai waktu untuk bekerja padanya, salah satu batalkan pengakuannya atau jangan mengakuinya di tempat pertama!</p>\n<p>Jika tidak ada tanda kemajuan pada tiket tertentu yang diakui selama seminggu atau dua minggu, pengembang lain mungkin meminta anda melepaskan pengakuan tiket sehingga itu tidak lagi dikuasai dan seseorang lain dapat mengakuinya.</p>\n<p>Jika anda telah mengakui tiket dan itu memakan waktu lama (harian atau mingguan) untuk membuat kode, jaga semua orang terperbaharui dengan menempatkan komentar pada tiket. Jika anda tidak menyediakan pembaharuan reguler, dan anda tidak menjawab pada permintaan untuk laporan kemajuan, pengakuan anda pada tiket mungkin ditarik.</p>\n<p>Seperti biasa, komunikasi lebih lebih baik daripada komunikasi kurang!</p>\n</section>\n<section id=\"which-tickets-should-be-claimed\">\n<h3>Tiket mana harus diminta?<a class=\"heading-anchor\" href=\"#which-tickets-should-be-claimed\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h3>\n<p>Going through the steps of claiming tickets is overkill in some cases.</p>\n<p>In the case of small changes, such as typos in the documentation or small bugs\nthat will only take a few minutes to fix, you don't need to jump through the\nhoops of claiming tickets. Submit your changes directly and you're done!</p>\n<p>It is <em>always</em> acceptable, regardless of whether someone has claimed it or not,\nto link proposals to a ticket if you happen to have the changes ready.</p>\n</section>\n</section>\n<section id=\"contribution-style\">\n<span id=\"patch-style\"></span><h2>Contribution style<a class=\"heading-anchor\" href=\"#contribution-style\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h2>\n<p>Pastikan bahwa tiap sumbangan anda lakukan memenuhi setidaknya persyaratan berikut:</p>\n<ul class=\"simple\">\n<li><p>The code required to fix a problem or add a feature is an essential part\nof a solution, but it is not the only part. A good fix should also include a\n<a class=\"reference internal\" href=\"/id/6.0/internals/contributing/writing-code/unit-tests/\"><span class=\"doc\">regression test</span></a> to\nvalidate the behavior that has been fixed and to prevent the problem from\narising again. Also, if some tickets are relevant to the code that you've\nwritten, mention the ticket numbers in some comments in the test so that one\ncan easily trace back the relevant discussions after your patch gets\ncommitted, and the tickets get closed.</p></li>\n<li><p>If the code adds a new feature, or modifies the behavior of an existing\nfeature, the change should also contain documentation.</p></li>\n</ul>\n<p>When you think your work is ready to be reviewed, send <a class=\"reference internal\" href=\"/id/6.0/internals/contributing/writing-code/working-with-git/\"><span class=\"doc\">a GitHub pull\nrequest</span></a>. If you can't\nsend a pull request for some reason, you can also use patches in Trac. When\nusing this style, follow these guidelines.</p>\n<ul class=\"simple\">\n<li><p>Ajukan tambalan-tambalan dalam bentuk dikembalikan oleh perintah <code class=\"docutils literal notranslate\"><span class=\"pre\">git</span> <span class=\"pre\">diff</span></code>.</p></li>\n<li><p>Lampirkan tambalan ke sebuah tiket dalam <a class=\"reference external\" href=\"https://code.djangoproject.com/\">ticket tracker</a>, menggunakan tombol &quot;attach file&quot;. Tolong <em>jangan</em> taruh tambalan dalam gambaran tiket atau komentar meskipun dia hanya sebuah tambalan baris tunggal.</p></li>\n<li><p>Nama berkas tambalan dengan perpanjangan <code class=\"docutils literal notranslate\"><span class=\"pre\">.diff</span></code>; ini akan membuat pelacak tiket memberlakukan penyorotan sintaksis benar, yang tentunya sangat membantu.</p></li>\n</ul>\n<p>Tanpa memperhatikan cara anda mengajukan pekerjaan anda, ikuti langkah-langkah ini.</p>\n<ul class=\"simple\">\n<li><p>Make sure your code fulfills the requirements in our <a class=\"reference internal\" href=\"#patch-review-checklist\"><span class=\"std std-ref\">contribution\nchecklist</span></a>.</p></li>\n<li><p>Centang kotak &quot;Has patch&quot; pada tiket dan pastikan kotak-kotak &quot;Butuh dokumentasi&quot;, &quot;Butuh percobaan&quot;, and &quot;Tambalan butuh perbaikan&quot; tidak dicentang. Ini membuat tiket muncul di antrian &quot;Tambahan butuh ditinjau&quot; pada <a class=\"reference external\" href=\"https://dashboard.djangoproject.com/\">Development dashboard</a>.</p></li>\n</ul>\n</section>\n<section id=\"contributions-which-require-community-feedback\">\n<h2>Contributions which require community feedback<a class=\"heading-anchor\" href=\"#contributions-which-require-community-feedback\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h2>\n<p>A wider community discussion is required when a patch introduces new Django\nfunctionality and makes some sort of design decision. This is especially\nimportant if the approach involves a <a class=\"reference internal\" href=\"#deprecating-a-feature\"><span class=\"std std-ref\">deprecation</span></a>\nor introduces breaking changes.</p>\n<p>The following are different approaches for gaining feedback from the community.</p>\n<section id=\"the-new-feature-ideas-tracker\">\n<h3>The new feature ideas tracker<a class=\"heading-anchor\" href=\"#the-new-feature-ideas-tracker\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h3>\n<p>If you have an idea for a new feature, please create a new proposal (or join an\nexisting discussion) following the <a class=\"reference internal\" href=\"/id/6.0/internals/contributing/bugs-and-features/#requesting-features\"><span class=\"std std-ref\">process for suggesting new features</span></a>. You should explain the need for the change, go into\ndetails of the approach and discuss alternatives.</p>\n</section>\n<section id=\"the-django-forum\">\n<h3>The Django Forum<a class=\"heading-anchor\" href=\"#the-django-forum\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h3>\n<p>You can propose a change (that is not a new feature idea) on the\n<a class=\"reference external\" href=\"https://forum.djangoproject.com/\">Django Forum</a>. You should explain the need for the change, go into details of\nthe approach and discuss alternatives.</p>\n<p>Please include a link to such discussions in your contributions.</p>\n</section>\n<section id=\"third-party-package\">\n<h3>Third party package<a class=\"heading-anchor\" href=\"#third-party-package\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h3>\n<p>Django does not accept experimental features. All features must follow our\n<a class=\"reference internal\" href=\"/id/6.0/internals/release-process/#internal-release-deprecation-policy\"><span class=\"std std-ref\">deprecation policy</span></a>. Hence, it can\ntake months or years for Django to iterate on an API design.</p>\n<p>If you need user feedback on a public interface, it is better to create a\nthird-party package first. You can iterate on the public API much faster, while\nalso validating the need for the feature.</p>\n<p>Once this package becomes stable and there are clear benefits of incorporating\naspects into Django core, the next step is to propose its inclusion by\nfollowing the <a class=\"reference internal\" href=\"/id/6.0/internals/contributing/bugs-and-features/#requesting-features\"><span class=\"std std-ref\">process for suggesting new features</span></a>.</p>\n</section>\n<section id=\"django-enhancement-proposal-dep\">\n<h3>Django Enhancement Proposal (DEP)<a class=\"heading-anchor\" href=\"#django-enhancement-proposal-dep\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h3>\n<p>Similar to Python’s PEPs, Django has <a class=\"reference external\" href=\"https://github.com/django/deps\">Django Enhancement Proposals</a> or DEPs. A\nDEP is a design document which provides information to the Django community, or\ndescribes a new feature or process for Django. They provide concise technical\nspecifications of features, along with rationales. DEPs are also the primary\nmechanism for proposing and collecting community input on major new features.</p>\n<p>Before considering writing a DEP, it is recommended to first open a discussion\nfollowing the <a class=\"reference internal\" href=\"/id/6.0/internals/contributing/bugs-and-features/#requesting-features\"><span class=\"std std-ref\">process for suggesting new features</span></a>.\nThis allows the community to provide feedback and helps refine the proposal.\nOnce the DEP is ready, the <a class=\"reference internal\" href=\"/id/6.0/internals/organization/#steering-council\"><span class=\"std std-ref\">Steering Council</span></a> votes on\nwhether to accept it.</p>\n<p>Some examples of DEPs that have been approved and fully implemented:</p>\n<ul class=\"simple\">\n<li><p><a class=\"reference external\" href=\"https://github.com/django/deps/blob/main/final/0181-orm-expressions.rst\">DEP 181: ORM Expressions</a></p></li>\n<li><p><a class=\"reference external\" href=\"https://github.com/django/deps/blob/main/final/0182-multiple-template-engines.rst\">DEP 182: Multiple Template Engines</a></p></li>\n<li><p><a class=\"reference external\" href=\"https://github.com/django/deps/blob/main/final/0201-simplified-routing-syntax.rst\">DEP 201: Simplified routing syntax</a></p></li>\n</ul>\n</section>\n</section>\n<section id=\"deprecating-a-feature\">\n<span id=\"id2\"></span><h2>Mengusangkan fitur<a class=\"heading-anchor\" href=\"#deprecating-a-feature\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h2>\n<p>Ada sepasang alasan dimana dalam Django mungkin diusangkan:</p>\n<ul class=\"simple\">\n<li><p>Jika sebuah fitur telah ditingkatkan atau dirubah di cara ketidaksesuaian-kebelakang, fitur atau kebiasaan lama akan diusangkan.</p></li>\n<li><p>Terkadang Django akan menyertakan backport dari pustaka Python yang tidak disertakan dalam versi dari Python yang Django saat ini dukung. Ketika Django tidak lagi butuh mendukung versi lama dari Python yang tidak menyertakan pustaka, pustakan akan diusangkan di Django.</p></li>\n</ul>\n<p>Seperti <a class=\"reference internal\" href=\"/id/6.0/internals/release-process/#internal-release-deprecation-policy\"><span class=\"std std-ref\">deprecation policy</span></a> gambarkan, terbitan pertama dari Django yang mengusangkan sebuah fitur (<code class=\"docutils literal notranslate\"><span class=\"pre\">A.B</span></code>) harus memunculkan <code class=\"docutils literal notranslate\"><span class=\"pre\">RemovedInDjangoXXWarning</span></code> (dimana XX adalah versi Django dimana fitur akan dipindahkan) ketika fitur diusangkan dipanggil. Menganggp kami mempunyai cakupan percobaan baik, peringatan ini dirubah ke kesalahan ketika <a class=\"reference internal\" href=\"/id/6.0/internals/contributing/writing-code/unit-tests/#running-unit-tests\"><span class=\"std std-ref\">running the test suite</span></a> dengan peringatan diadakan: <code class=\"docutils literal notranslate\"><span class=\"pre\">python</span> <span class=\"pre\">-Wa</span> <span class=\"pre\">runtests.py</span></code>. Dengan demikian, ketika menambahkan <code class=\"docutils literal notranslate\"><span class=\"pre\">RemovedInDjangoXXWarning</span></code> anda butuh mengurangi atau mensenyapkan tiap peringatan yang dibangkitkan ketika menjalankan percobaan.</p>\n<p>Langkah pertama adalah memindahkan tiap penggunaan dari kebiasaan diusangkan oleh Django itu sendiri. Selanjutnya anda dapat peringatan senyap di percobaan yang sebenarnya mencoba kebiasaan diusangkan dengan menggunakan penghias <code class=\"docutils literal notranslate\"><span class=\"pre\">ignore_warnings</span></code>, antara pada tingkatan percobaan atau kelas:</p>\n<ol class=\"arabic\">\n<li><p>Di percobaan khusus:</p>\n<div class=\"code-block\" data-language=\"default\"><div class=\"code-block-toolbar\"><span class=\"code-block-language\">Code</span><button type=\"button\" class=\"copy-button\" data-copy hidden><span class=\"copy-button-label\">Copy</span></button></div><pre role=\"group\" tabindex=\"0\" aria-label=\"Code code\"><code><span class=\"kn\">from</span><span class=\"w\"> </span><span class=\"nn\">django.test</span><span class=\"w\"> </span><span class=\"kn\">import</span> <span class=\"n\">ignore_warnings</span>\n<span class=\"kn\">from</span><span class=\"w\"> </span><span class=\"nn\">django.utils.deprecation</span><span class=\"w\"> </span><span class=\"kn\">import</span> <span class=\"n\">RemovedInDjangoXXWarning</span>\n\n\n<span class=\"nd\">@ignore_warnings</span><span class=\"p\">(</span><span class=\"n\">category</span><span class=\"o\">=</span><span class=\"n\">RemovedInDjangoXXWarning</span><span class=\"p\">)</span>\n<span class=\"k\">def</span><span class=\"w\"> </span><span class=\"nf\">test_foo</span><span class=\"p\">(</span><span class=\"bp\">self</span><span class=\"p\">):</span> <span class=\"o\">...</span>\n</code></pre></div>\n</li>\n<li><p>Untuk kasus percobaan keseluruhan:</p>\n<div class=\"code-block\" data-language=\"default\"><div class=\"code-block-toolbar\"><span class=\"code-block-language\">Code</span><button type=\"button\" class=\"copy-button\" data-copy hidden><span class=\"copy-button-label\">Copy</span></button></div><pre role=\"group\" tabindex=\"0\" aria-label=\"Code code\"><code><span class=\"kn\">from</span><span class=\"w\"> </span><span class=\"nn\">django.test</span><span class=\"w\"> </span><span class=\"kn\">import</span> <span class=\"n\">ignore_warnings</span>\n<span class=\"kn\">from</span><span class=\"w\"> </span><span class=\"nn\">django.utils.deprecation</span><span class=\"w\"> </span><span class=\"kn\">import</span> <span class=\"n\">RemovedInDjangoXXWarning</span>\n\n\n<span class=\"nd\">@ignore_warnings</span><span class=\"p\">(</span><span class=\"n\">category</span><span class=\"o\">=</span><span class=\"n\">RemovedInDjangoXXWarning</span><span class=\"p\">)</span>\n<span class=\"k\">class</span><span class=\"w\"> </span><span class=\"nc\">MyDeprecatedTests</span><span class=\"p\">(</span><span class=\"n\">unittest</span><span class=\"o\">.</span><span class=\"n\">TestCase</span><span class=\"p\">):</span> <span class=\"o\">...</span>\n</code></pre></div>\n</li>\n</ol>\n<p>Anda juga harus menambahkan pengujian untuk peringatan pengusangan:</p>\n<div class=\"code-block\" data-language=\"default\"><div class=\"code-block-toolbar\"><span class=\"code-block-language\">Code</span><button type=\"button\" class=\"copy-button\" data-copy hidden><span class=\"copy-button-label\">Copy</span></button></div><pre role=\"group\" tabindex=\"0\" aria-label=\"Code code\"><code><span class=\"kn\">from</span><span class=\"w\"> </span><span class=\"nn\">django.utils.deprecation</span><span class=\"w\"> </span><span class=\"kn\">import</span> <span class=\"n\">RemovedInDjangoXXWarning</span>\n\n\n<span class=\"k\">def</span><span class=\"w\"> </span><span class=\"nf\">test_foo_deprecation_warning</span><span class=\"p\">(</span><span class=\"bp\">self</span><span class=\"p\">):</span>\n    <span class=\"n\">msg</span> <span class=\"o\">=</span> <span class=\"s2\">&quot;Expected deprecation message&quot;</span>\n    <span class=\"k\">with</span> <span class=\"bp\">self</span><span class=\"o\">.</span><span class=\"n\">assertWarnsMessage</span><span class=\"p\">(</span><span class=\"n\">RemovedInDjangoXXWarning</span><span class=\"p\">,</span> <span class=\"n\">msg</span><span class=\"p\">)</span> <span class=\"k\">as</span> <span class=\"n\">ctx</span><span class=\"p\">:</span>\n        <span class=\"c1\"># invoke deprecated behavior</span>\n        <span class=\"o\">...</span>\n    <span class=\"bp\">self</span><span class=\"o\">.</span><span class=\"n\">assertEqual</span><span class=\"p\">(</span><span class=\"n\">ctx</span><span class=\"o\">.</span><span class=\"n\">filename</span><span class=\"p\">,</span> <span class=\"vm\">__file__</span><span class=\"p\">)</span>\n</code></pre></div>\n<p>Sangat penting untuk menyertakan komentar <code class=\"docutils literal notranslate\"><span class=\"pre\">RemovedInDjangoXXWarning</span></code> diatas kode yang tidak mempunyai acuan peringatan, tetapi akan butuh dirubah atau dihapus ketika pengusangan berakhir. Ini dapat menyertakan kaitan yang telah ditambahkan untuk menjaga perilaku sebelumnya, atau barang berdiri sendiri yang tidak butuh atau tidak digunakan ketika pengusangan berakhir. Sebagai contoh:</p>\n<div class=\"code-block\" data-language=\"default\"><div class=\"code-block-toolbar\"><span class=\"code-block-language\">Code</span><button type=\"button\" class=\"copy-button\" data-copy hidden><span class=\"copy-button-label\">Copy</span></button></div><pre role=\"group\" tabindex=\"0\" aria-label=\"Code code\"><code><span class=\"kn\">import</span><span class=\"w\"> </span><span class=\"nn\">warnings</span>\n<span class=\"kn\">from</span><span class=\"w\"> </span><span class=\"nn\">django.utils.deprecation</span><span class=\"w\"> </span><span class=\"kn\">import</span> <span class=\"n\">RemovedInDjangoXXWarning</span><span class=\"p\">,</span> <span class=\"n\">django_file_prefixes</span>\n\n\n<span class=\"c1\"># RemovedInDjangoXXWarning.</span>\n<span class=\"k\">def</span><span class=\"w\"> </span><span class=\"nf\">old_private_helper</span><span class=\"p\">():</span>\n    <span class=\"c1\"># Helper function that is only used in foo().</span>\n    <span class=\"k\">pass</span>\n\n\n<span class=\"k\">def</span><span class=\"w\"> </span><span class=\"nf\">foo</span><span class=\"p\">():</span>\n    <span class=\"n\">warnings</span><span class=\"o\">.</span><span class=\"n\">warn</span><span class=\"p\">(</span>\n        <span class=\"s2\">&quot;foo() is deprecated.&quot;</span><span class=\"p\">,</span>\n        <span class=\"n\">category</span><span class=\"o\">=</span><span class=\"n\">RemovedInDjangoXXWarning</span><span class=\"p\">,</span>\n        <span class=\"n\">skip_file_prefixes</span><span class=\"o\">=</span><span class=\"n\">django_file_prefixes</span><span class=\"p\">(),</span>\n    <span class=\"p\">)</span>\n    <span class=\"n\">old_private_helper</span><span class=\"p\">()</span>\n    <span class=\"o\">...</span>\n</code></pre></div>\n<p>Akhirnya, ada sepasang pembaharuan ke dokumentasi Django untuk dibuat:</p>\n<ol class=\"arabic simple\">\n<li><p>Jika fitur yang ada didokumentasikan, tandai dia diusangkan di dokumentasi menggunakan keterangan <code class=\"docutils literal notranslate\"><span class=\"pre\">..</span> <span class=\"pre\">deprecated::</span> <span class=\"pre\">A.B</span></code>. Termasuk gambaran pendek dan catatan tentang jalur peningkatan jika berlaku.</p></li>\n<li><p>Tambah gambaran dari kebiasaan pengusangan, dan tingkatkan jalur jika dapat diterapkan, pada catatan terbitaan saat ini (<code class=\"docutils literal notranslate\"><span class=\"pre\">docs/releases/A.B.txt</span></code>) dibawah kepala &quot;Fitur-fitur diusangkan dalam A.B&quot;.</p></li>\n<li><p>Tambah sebuah masukan dalam linimasa pengusangan (<code class=\"docutils literal notranslate\"><span class=\"pre\">docs/internals/deprecation.txt</span></code>) dibawah versi yang sesuai menggambarkan kode apa akan dipindahkan.</p></li>\n</ol>\n<p>Once you have completed these steps, you are finished with the deprecation.\nIn each <a class=\"reference internal\" href=\"/id/6.0/internals/release-process/#term-Feature-release\"><span class=\"xref std std-term\">feature release</span></a>, all\n<code class=\"docutils literal notranslate\"><span class=\"pre\">RemovedInDjangoXXWarning</span></code>s matching the new version are removed.</p>\n<p>The <code class=\"docutils literal notranslate\"><span class=\"pre\">django.utils.deprecation</span></code> module provides some helpful deprecation\nutilities, such as a <code class=\"docutils literal notranslate\"><span class=\"pre\">&#64;deprecate_posargs</span></code> decorator to assist with converting\npositional-or-keyword arguments to keyword-only. See the inline documentation\nin the module source.</p>\n</section>\n<section id=\"testing-with-a-django-project\">\n<h2>Testing with a Django project<a class=\"heading-anchor\" href=\"#testing-with-a-django-project\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h2>\n<p>It's important to test local changes using a Django project. This allows\nensuring that the changes behave as expected in a real environment, especially\nfor user-facing features such as templates, forms, or the admin.</p>\n<p>To do this:</p>\n<ol class=\"arabic simple\">\n<li><p>Create a virtual environment and <a class=\"reference internal\" href=\"/id/6.0/intro/contributing/#intro-contributing-install-local-copy\"><span class=\"std std-ref\">install the cloned copy of Django in\neditable mode</span></a>.</p></li>\n<li><p>Set up a Django project outside the source tree (you can use the <a class=\"reference internal\" href=\"/id/6.0/intro/tutorial01/\"><span class=\"doc\">first\npart of the tutorial</span></a> for guidance).</p></li>\n</ol>\n<p>With this setup, any changes made to the Django checkout will take effect\nimmediately in the test project, allowing manual testing of contributions\nagainst a new or existing app.</p>\n</section>\n<section id=\"javascript-contributions\">\n<h2>Bantuan JavaScript<a class=\"heading-anchor\" href=\"#javascript-contributions\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h2>\n<p>For information on JavaScript contributions, see the <a class=\"reference internal\" href=\"/id/6.0/internals/contributing/writing-code/javascript/#javascript-patches\"><span class=\"std std-ref\">Tambalan JavaScript</span></a>\ndocumentation.</p>\n</section>\n<section id=\"optimization-patches\">\n<h2>Optimalisasi tambahan<a class=\"heading-anchor\" href=\"#optimization-patches\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h2>\n<p>Patches aiming to deliver a performance improvement should provide benchmarks\nshowing the before and after impact of the patch and sharing the commands for\nreviewers to reproduce.</p>\n<section id=\"django-asv-benchmarks\">\n<span id=\"id3\"></span><h3>Tolok ukur <code class=\"docutils literal notranslate\"><span class=\"pre\">django-asv</span></code><a class=\"heading-anchor\" href=\"#django-asv-benchmarks\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h3>\n<p><a class=\"reference external\" href=\"https://github.com/django/django-asv/\">django-asv</a> monitors the performance of Django code over time. These\nbenchmarks can be run on a pull request by labeling the pull request with\n<code class=\"docutils literal notranslate\"><span class=\"pre\">benchmark</span></code>. Adding to these benchmarks is highly encouraged.</p>\n</section>\n</section>\n<section id=\"contribution-checklist\">\n<span id=\"patch-review-checklist\"></span><h2>Daftar centang bantuan<a class=\"heading-anchor\" href=\"#contribution-checklist\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h2>\n<p>Use this checklist to review a pull request. If this contribution would not be\n<a class=\"reference internal\" href=\"#trivial-change\"><span class=\"std std-ref\">considered trivial</span></a>, first ensure it has an accepted\nticket before proceeding with the review.</p>\n<p>If the pull request passes all the criteria below and is not your own, please\nset the &quot;Triage Stage&quot; on the corresponding Trac ticket to &quot;Ready for checkin&quot;.\nIf you've left comments for improvement on the pull request, please tick the\nappropriate flags on the Trac ticket based on the results of your review:\n&quot;Patch needs improvement&quot;, &quot;Needs documentation&quot;, and/or &quot;Needs tests&quot;. As time\nand interest permit, mergers do final reviews of &quot;Ready for checkin&quot; tickets\nand will either commit the changes or bump it back to &quot;Accepted&quot; if further\nwork needs to be done.</p>\n<p>If you're looking to become a member of the <a class=\"reference external\" href=\"https://www.djangoproject.com/foundation/teams/#triage-review-team\">triage &amp; review team</a>, doing\nthorough reviews of contributions is a great way to earn trust.</p>\n<p>Looking for a patch to review? Check out the &quot;Patches needing review&quot; section\nof the <a class=\"reference external\" href=\"https://dashboard.djangoproject.com/\">Django Development Dashboard</a>.</p>\n<p>Looking to get your pull request reviewed? Ensure the Trac flags on the ticket\nare set so that the ticket appears in that queue.</p>\n<section id=\"all-tickets\">\n<h3>Semua tiket<a class=\"heading-anchor\" href=\"#all-tickets\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h3>\n<ul class=\"simple\">\n<li><p>Apakah pull request perbaikan lumatan tunggal dengan pesan yang mengikuti <a class=\"reference internal\" href=\"/id/6.0/internals/contributing/committing-code/#committing-guidelines\"><span class=\"std std-ref\">commit message format</span></a> kami?</p></li>\n<li><p>Are you the patch author and a new contributor? Please add yourself to the\n<a class=\"extlink-source reference external\" href=\"https://github.com/django/django/blob/stable/6.0.x/AUTHORS\">AUTHORS</a> file. At your option, submit a\n<a class=\"reference external\" href=\"https://www.djangoproject.com/foundation/cla/\">Contributor License Agreement</a>.</p></li>\n<li><p>Does this have an accepted ticket on Trac? All contributions require a ticket\nunless the <a class=\"reference internal\" href=\"#trivial-change\"><span class=\"std std-ref\">change is considered trivial</span></a>.</p></li>\n</ul>\n</section>\n<section id=\"all-code-changes\">\n<h3>Semua kode perubahan<a class=\"heading-anchor\" href=\"#all-code-changes\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h3>\n<ul class=\"simple\">\n<li><p>Does the <a class=\"reference internal\" href=\"/id/6.0/internals/contributing/writing-code/coding-style/\"><span class=\"doc\">coding style</span></a> conform to our\nguidelines? Are there any  <code class=\"docutils literal notranslate\"><span class=\"pre\">black</span></code>, <code class=\"docutils literal notranslate\"><span class=\"pre\">blacken-docs</span></code>, <code class=\"docutils literal notranslate\"><span class=\"pre\">flake8</span></code>,\n<code class=\"docutils literal notranslate\"><span class=\"pre\">isort</span></code>, or <code class=\"docutils literal notranslate\"><span class=\"pre\">zizmor</span></code> errors? You can install the <a class=\"reference internal\" href=\"/id/6.0/internals/contributing/writing-code/coding-style/#coding-style-pre-commit\"><span class=\"std std-ref\">pre-commit</span></a> hooks to automatically catch these errors.</p></li>\n<li><p>Jika perubahan adalah kesesuaian kebelakang denganc ara apapun, apakah ada dalam catatan terbitan (<code class=\"docutils literal notranslate\"><span class=\"pre\">docs/releases/A.B.txt</span></code>)?</p></li>\n<li><p>Apakah rangkaian percobaan Django lewat?</p></li>\n<li><p>If there is a <a class=\"reference internal\" href=\"/id/6.0/internals/contributing/writing-code/unit-tests/#code-coverage-on-pull-requests\"><span class=\"std std-ref\">code coverage report</span></a>\ncomment on the pull request, have you reviewed the missing coverage in\ncontext (considering database/platform-specific limitations)?</p></li>\n<li><p>If the change affects the Django admin or rendered HTML output, has\n<a class=\"reference internal\" href=\"/id/6.0/internals/contributing/accessibility/#accessibility-testing-baseline\"><span class=\"std std-ref\">accessibility testing</span></a> been done?</p></li>\n</ul>\n</section>\n<section id=\"documentation\">\n<h3>Dokumentasi<a class=\"heading-anchor\" href=\"#documentation\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h3>\n<ul class=\"simple\">\n<li><p>Apakah dokumentasi dibangun tanpa kesalahan apapun (<code class=\"docutils literal notranslate\"><span class=\"pre\">make</span> <span class=\"pre\">html</span></code>, atau <code class=\"docutils literal notranslate\"><span class=\"pre\">make.bat</span> <span class=\"pre\">html</span></code>  pada Windows, dari direktori <code class=\"docutils literal notranslate\"><span class=\"pre\">docs</span></code>)?</p></li>\n<li><p>Apakah dokumentasi mengikuti panduan gaya penulisan dalam <a class=\"reference internal\" href=\"/id/6.0/internals/contributing/writing-documentation/\"><span class=\"doc\">Menulis dokumentasi</span></a>?</p></li>\n<li><p>Apakah ada <a class=\"reference internal\" href=\"/id/6.0/internals/contributing/writing-documentation/#documentation-spelling-check\"><span class=\"std std-ref\">kesalahan pengejaan</span></a>?</p></li>\n</ul>\n</section>\n<section id=\"bugs\">\n<h3>Kesalahan<a class=\"heading-anchor\" href=\"#bugs\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h3>\n<ul class=\"simple\">\n<li><p>Apakah ada percobaan pemulihan yang sesuai (percobaan harus gagal sebelum perbaikan diberlakukan)?</p></li>\n<li><p>If it's a bug that <a class=\"reference internal\" href=\"/id/6.0/internals/release-process/#supported-versions-policy\"><span class=\"std std-ref\">qualifies for a backport</span></a> to the stable version of Django, is there a\nrelease note in <code class=\"docutils literal notranslate\"><span class=\"pre\">docs/releases/A.B.C.txt</span></code>? Bug fixes that will be applied\nonly to the main branch don't need a release note.</p></li>\n</ul>\n</section>\n<section id=\"new-features\">\n<h3>Fitur Baru<a class=\"heading-anchor\" href=\"#new-features\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h3>\n<ul class=\"simple\">\n<li><p>Apakah ada percobaan untuk &quot;latihan&quot; semua kode baru?</p></li>\n<li><p>Apakah ada sebuah catatan terbitan di <code class=\"docutils literal notranslate\"><span class=\"pre\">docs/releases/A.B.txt</span></code>?</p></li>\n<li><p>Apakah ada dokumentasi untuk fitur dan apakah dia <a class=\"reference internal\" href=\"/id/6.0/internals/contributing/writing-documentation/#documenting-new-features\"><span class=\"std std-ref\">dijelaskan dengan tepat</span></a> dengan <code class=\"docutils literal notranslate\"><span class=\"pre\">..</span> <span class=\"pre\">versionadded::</span> <span class=\"pre\">A.B</span></code> atau <code class=\"docutils literal notranslate\"><span class=\"pre\">..</span> <span class=\"pre\">versionchanged::</span> <span class=\"pre\">A.B</span></code>?</p></li>\n</ul>\n</section>\n<section id=\"id4\">\n<h3>Mengusangkan fitur<a class=\"heading-anchor\" href=\"#id4\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h3>\n<p>Lihat panduan <a class=\"reference internal\" href=\"#deprecating-a-feature\"><span class=\"std std-ref\">Mengusangkan fitur</span></a>.</p>\n</section>\n</section>","rootId":"submitting-contributions","toc":[{"title":"Perbaikan kesalahan ketik dan perubahan dokumentasi sepele.","anchor":"typo-fixes-and-trivial-documentation-changes","children":[]},{"title":"Tiket \"Meminta\"","anchor":"claiming-tickets","children":[{"title":"Tanggung jawab pengaku tiket","anchor":"ticket-claimers-responsibility","children":[]},{"title":"Tiket mana harus diminta?","anchor":"which-tickets-should-be-claimed","children":[]}]},{"title":"Contribution style","anchor":"contribution-style","children":[]},{"title":"Contributions which require community feedback","anchor":"contributions-which-require-community-feedback","children":[{"title":"The new feature ideas tracker","anchor":"the-new-feature-ideas-tracker","children":[]},{"title":"The Django Forum","anchor":"the-django-forum","children":[]},{"title":"Third party package","anchor":"third-party-package","children":[]},{"title":"Django Enhancement Proposal (DEP)","anchor":"django-enhancement-proposal-dep","children":[]}]},{"title":"Mengusangkan fitur","anchor":"deprecating-a-feature","children":[]},{"title":"Testing with a Django project","anchor":"testing-with-a-django-project","children":[]},{"title":"Bantuan JavaScript","anchor":"javascript-contributions","children":[]},{"title":"Optimalisasi tambahan","anchor":"optimization-patches","children":[{"title":"Tolok ukur django-asv","anchor":"django-asv-benchmarks","children":[]}]},{"title":"Daftar centang bantuan","anchor":"contribution-checklist","children":[{"title":"Semua tiket","anchor":"all-tickets","children":[]},{"title":"Semua kode perubahan","anchor":"all-code-changes","children":[]},{"title":"Dokumentasi","anchor":"documentation","children":[]},{"title":"Kesalahan","anchor":"bugs","children":[]},{"title":"Fitur Baru","anchor":"new-features","children":[]},{"title":"Mengusangkan fitur","anchor":"id4","children":[]}]}],"breadcrumbs":[{"docname":"internals/index","title":"Dalam Django","url":"/id/6.0/internals/"},{"docname":"internals/contributing/index","title":"Membantu untuk Django","url":"/id/6.0/internals/contributing/"},{"docname":"internals/contributing/writing-code/index","title":"Kode bantuan","url":"/id/6.0/internals/contributing/writing-code/"}],"prev":{"docname":"internals/contributing/writing-code/index","title":"Kode bantuan","url":"/id/6.0/internals/contributing/writing-code/"},"next":{"docname":"internals/contributing/writing-code/unit-tests","title":"Satuan percobaan","url":"/id/6.0/internals/contributing/writing-code/unit-tests/"},"formats":{"html":"/id/6.0/internals/contributing/writing-code/submitting-patches/","markdown":"/id/6.0/internals/contributing/writing-code/submitting-patches.md","json":"/id/6.0/internals/contributing/writing-code/submitting-patches.json"},"source":"https://github.com/django/django/blob/stable/6.0.x/docs/internals/contributing/writing-code/submitting-patches.txt","official":"https://docs.djangoproject.com/id/6.0/internals/contributing/writing-code/submitting-patches/","inVersions":["6.1","6.0","5.2","5.1","5.0","4.2","4.1","4.0","3.2","3.1","3.0","2.2","2.1","2.0","1.11","1.10","1.9"],"inLocales":["en","sv","zh-hans","ga","fr","ja","id","it","pt-br","ko","es","el","pl"]}