{"title":"对新贡献者的建议","version":"3.1","locale":"zh-hans","docname":"internals/contributing/new-contributors","url":"/zh-hans/3.1/internals/contributing/new-contributors/","canonical":"https://djangodocs.dev/zh-hans/3.1/internals/contributing/new-contributors/","summary":"新来的贡献者，不知道该怎么办？ 想要提供帮助但是不知道如何开始？ 那这就是为你准备的部分。 Get up and running! 如果您是 Django 新的贡献者，那么 :文档:`/intro/contributing` 教程将为您介绍这些工具和工作流程。 This page contains more general…","html":"<h1>对新贡献者的建议<a class=\"heading-anchor\" href=\"#advice-for-new-contributors\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h1>\n<p>新来的贡献者，不知道该怎么办？ 想要提供帮助但是不知道如何开始？ 那这就是为你准备的部分。</p>\n<aside class=\"admonition-get-up-and-running admonition\">\n<p class=\"admonition-title\">Get up and running!</p>\n<p>如果您是 Django 新的贡献者，那么 <a href=\"#id1\"><span class=\"problematic\" id=\"id2\">:文档:`/intro/contributing`</span></a> 教程将为您介绍这些工具和工作流程。</p>\n</aside>\n<p>This page contains more general advice on ways you can contribute to Django,\nand how to approach that.</p>\n<p>If you are looking for a reference on the details of making code contributions,\nsee the <a class=\"reference internal\" href=\"/zh-hans/3.1/internals/contributing/writing-code/\"><span class=\"doc\">编写代码</span></a> documentation.</p>\n<section id=\"first-steps\">\n<h2>快速入门<a class=\"heading-anchor\" href=\"#first-steps\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h2>\n<p>从这些任务开始，去发现 Django 的开发过程。</p>\n<ul>\n<li><p><strong>分类工单</strong></p>\n<p>如果一个`未审查的工单`_报告了一个错误，请尝试验证并重现它。如果您可以重现它并且它似乎是有效的，写一条记录以表明你确认了该错误并接受该工单。确保该工单归档在正确的组件区域。即使你不去修复bug本身，你也可以写一个用于测试bug的行为的补丁。查看更多内容请点击:ref:“我如何在分类方面帮忙”</p>\n</li>\n<li><p><strong>寻找已被接受的工单并审查补丁，以建立对代码库和流程的熟悉</strong></p>\n<p>如果修补程序需要文档或测试，请标记相应的标志。查看补丁程序所做的更改，并留意与旧版但仍受支持的Python不兼容的语法。 :doc:<a href=\"#id1\"><span class=\"problematic\" id=\"id2\">`</span></a>Run the tests ` 并确保它们通过。在可能的和相关的地方，在SQLite之外的数据库上尝试它们。留下评论和反馈！</p>\n</li>\n<li><p><strong>更新旧的的修补程序</strong></p>\n<p>通常情况下，代码库会在提交补丁和审阅补丁之间发生变化。确保它仍然干净地应用，并按预期运行。更新补丁既有用又重要！更多信息请参见代码 <a class=\"reference internal\" href=\"/zh-hans/3.1/internals/contributing/writing-code/submitting-patches/\"><span class=\"doc\">提交补丁</span></a> 。</p>\n</li>\n<li><p><strong>撰写一些文档</strong></p>\n<p>Django的文档很好，但它总是可以改进的。你发现打字错误了吗？你认为有什么需要澄清的吗？继续并建议一个文档修补程序！另请参阅指南 <a class=\"reference internal\" href=\"/zh-hans/3.1/internals/contributing/writing-documentation/\"><span class=\"doc\">编写文档</span></a> 。</p>\n<aside class=\"admonition admonition-note\" role=\"note\">\n<p class=\"admonition-title\">Note</p>\n<p><a href=\"#id1\"><span class=\"problematic\" id=\"id2\">`</span></a>报告页`_包含了许多有用的Trac查询链接，包括一些像上面建议的那样对分类工单和审查补丁有用的链接。</p>\n</aside>\n</li>\n<li><p><strong>签署贡献者许可协议</strong></p>\n<p>您编写的代码属于您或您的雇主。 如果您的贡献超过一至两行代码，则需要签署 <a class=\"reference external\" href=\"https://www.djangoproject.com/foundation/cla/\">CLA</a> 。 有关更详尽的解释，请参阅  <a class=\"reference external\" href=\"https://www.djangoproject.com/foundation/cla/faq/\">Contributor License Agreement FAQ</a>”。</p>\n</li>\n</ul>\n</section>\n<section id=\"guidelines\">\n<h2>方针<a class=\"heading-anchor\" href=\"#guidelines\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h2>\n<p>作为大型项目的新手，很容易感到沮丧。 这里有一些建议可以使你在 Django 上的工作更加有用、 有收获。</p>\n<ul>\n<li><p><strong>选择一个您关心的，您熟悉的或您想了解的主题区</strong></p>\n<p>你不必已是你想要工作的领域的专家; 您将通过对代码的持续贡献成为专家。</p>\n</li>\n<li><p><strong>Analyze tickets' context and history</strong></p>\n<p>Trac不是绝对的；上下文和名词一样重要。在阅读Trac时，你需要考虑到账户谁说了什么，什么时候说的。两年前对一个想法的支持并不意味着这个想法还会得到支持。您还需要注意哪些人没有发言--例如，如果一位有经验的贡献者最近没有参与讨论，那么这份工单可能就不需要Django支持。</p>\n</li>\n<li><p><strong>从小的地方开始</strong></p>\n<p>在小问题上得到反馈比在大问题上得到反馈要容易得多。请参阅 <a class=\"reference external\" href=\"https://code.djangoproject.com/query?status=!closed&amp;easy=1\">easy pickings</a>。</p>\n</li>\n<li><p><strong>If you're going to engage in a big task, make sure that your idea has\nsupport first</strong></p>\n<p>这意味着在您解决问题之前让其他人确认一个bug是真实的，并确保在您开始实现一个建议的特性之前有一个共识。</p>\n</li>\n<li><p><strong>Be bold! Leave feedback!</strong></p>\n<p>有时候，把你的观点向全世界发表，说“这个工单是正确的”或者“这个补丁需要工作”，这可能会让人害怕，但这是项目向前推进的唯一途径。广泛的Django社区的贡献最终会比任何一个人的贡献产生更大的影响。没有**你**我们做不到！</p>\n</li>\n<li><p><strong>在标记要接收的提议时要小心</strong></p>\n<p>如果你真的不确定一张工单是否准备好了，不要这样标记。留下注释，让别人知道你的想法。如果你基本上是肯定的，但不是完全确定，你也可以试着问一下IRC，看看是否有人能证实你的怀疑。</p>\n</li>\n<li><p><strong>等待反馈，并对收到的反馈做出回应</strong></p>\n<p>专注于一两张工单，从头到尾看完，然后重复。短期途径接手很多工单，让一些工单在半路上掉下来，这样做的结果是弊大于利。</p>\n</li>\n<li><p><strong>Be rigorous</strong></p>\n<p>当我们说 &quot;<span class=\"target\" id=\"index-2\"></span><a class=\"pep reference external\" href=\"https://peps.python.org/pep-0008/\"><strong>PEP 8</strong></a>,  并且必须有文档和测试&quot; 时，我们是认真的。如果补丁没有文档和测试，最好有一个好的理由。像“我找不到这个特性的任何现有测试”这样的论据不会有多少说服力——虽然这可能是真的，但这意味着你要为这个特性编写最初的测试，而不是完全通过编写测试获得通过。</p>\n</li>\n</ul>\n</section>\n<section id=\"faq\">\n<span id=\"new-contributors-faq\"></span><h2>FAQ<a class=\"heading-anchor\" href=\"#faq\"><span class=\"visually-hidden\">Link to this heading</span><span aria-hidden=\"true\">#</span></a></h2>\n<ol class=\"arabic\">\n<li><p><strong>我关心的这份工单已经被忽略了好几天/几周/几个月了！我该怎么做才能让它接受？</strong></p>\n<p>首先，这不是私人的。有时候，Django完全是由志愿者开发出来的（除了Django团队成员），只是有些时候没有。最好的办法是给 <a class=\"reference internal\" href=\"/zh-hans/3.1/internals/mailing-lists/#django-developers-mailing-list\"><span class=\"std std-ref\">django-developers</span></a> 邮件列表发送一个温和的提醒，要求对工单进行复查，或者在 <code class=\"docutils literal notranslate\"><span class=\"pre\">#django-dev</span></code> IRC频道中提出。</p>\n</li>\n<li><p><strong>I'm sure my ticket is absolutely 100% perfect, can I mark it as RFC\nmyself?</strong></p>\n<p>简单回答：不，在工单上再找一个人总是更好的。如果你找的那个人有问题，请看上面的问题1。</p>\n</li>\n</ol>\n</section>","rootId":"advice-for-new-contributors","toc":[{"title":"快速入门","anchor":"first-steps","children":[]},{"title":"方针","anchor":"guidelines","children":[]},{"title":"FAQ","anchor":"faq","children":[]}],"breadcrumbs":[{"docname":"internals/index","title":"Django internals","url":"/zh-hans/3.1/internals/"},{"docname":"internals/contributing/index","title":"为 Django 做贡献","url":"/zh-hans/3.1/internals/contributing/"}],"prev":{"docname":"internals/contributing/index","title":"为 Django 做贡献","url":"/zh-hans/3.1/internals/contributing/"},"next":{"docname":"internals/contributing/bugs-and-features","title":"报告问题和请求新功能","url":"/zh-hans/3.1/internals/contributing/bugs-and-features/"},"formats":{"html":"/zh-hans/3.1/internals/contributing/new-contributors/","markdown":"/zh-hans/3.1/internals/contributing/new-contributors.md","json":"/zh-hans/3.1/internals/contributing/new-contributors.json"},"source":"https://github.com/django/django/blob/stable/3.1.x/docs/internals/contributing/new-contributors.txt","official":"https://docs.djangoproject.com/zh-hans/3.1/internals/contributing/new-contributors/","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"],"inLocales":["en","zh-hans","fr","ja","id","pt-br","ko","es","el","pl"]}