🌐 AI搜索 & 代理 主页
Skip to content

Commit 0679254

Browse files
Update translation
Co-Authored-By: Rafael Fontenelle <rffontenelle@gmail.com> Co-Authored-By: Rainer Terroso
1 parent 557e2fd commit 0679254

File tree

5 files changed

+73
-19
lines changed

5 files changed

+73
-19
lines changed

extending/newtypes_tutorial.po

Lines changed: 39 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ msgid ""
1212
msgstr ""
1313
"Project-Id-Version: Python 3.11\n"
1414
"Report-Msgid-Bugs-To: \n"
15-
"POT-Creation-Date: 2025-11-17 16:39+0000\n"
15+
"POT-Creation-Date: 2025-11-19 17:32+0000\n"
1616
"PO-Revision-Date: 2025-09-22 16:49+0000\n"
1717
"Last-Translator: Rainer Terroso, 2025\n"
1818
"Language-Team: Portuguese (Brazil) (https://app.transifex.com/python-doc/"
@@ -428,6 +428,13 @@ msgid ""
428428
"object's type might not be :class:`!CustomType`, because the object may be "
429429
"an instance of a subclass."
430430
msgstr ""
431+
"Esse método primeiro limpa a contagem de referências dos dois atributos "
432+
"Python. :c:func:`Py_XDECREF`lida corretamente com o caso em que seu "
433+
"argumento é ``NULL`` (o que pode acontecer aqui se ``tp_new`` falhou no meio "
434+
"do processo). Em seguida, ele chama o membro :c:member:`~PyTypeObject."
435+
"tp_free` do tipo do objeto (obtido por ``Py_TYPE(self)``) para liberar a "
436+
"memória do objeto. Observe que o tipo do objeto pode não ser :class:`!"
437+
"CustomType`, pois o objeto pode ser uma instância de uma subclasse."
431438

432439
#: ../../extending/newtypes_tutorial.rst:286
433440
msgid ""
@@ -443,10 +450,13 @@ msgid ""
443450
"We want to make sure that the first and last names are initialized to empty "
444451
"strings, so we provide a ``tp_new`` implementation::"
445452
msgstr ""
453+
"Queremos nos certificar de que o primeiro e o último nome sejam "
454+
"inicializados como strings vazias, portanto, fornecemos uma implementação:: "
455+
"``tp_new`` "
446456

447457
#: ../../extending/newtypes_tutorial.rst:316
448458
msgid "and install it in the :c:member:`~PyTypeObject.tp_new` member::"
449-
msgstr ""
459+
msgstr "e instale-o no membro:: :c:member:`~PyTypeObject.tp_new`"
450460

451461
#: ../../extending/newtypes_tutorial.rst:320
452462
msgid ""
@@ -458,6 +468,13 @@ msgid ""
458468
"type above. In this case, we use the ``tp_new`` handler to initialize the "
459469
"``first`` and ``last`` attributes to non-``NULL`` default values."
460470
msgstr ""
471+
"O manipulador ``tp_new`` é responsável por criar (em oposição a inicializar) "
472+
"os objetos do tipo. Ele é exposto no Python como o método :meth:`~object."
473+
"__new__`. Não é obrigatório definir um membro ``tp_new`` e, de fato, muitos "
474+
"tipos de extensão simplesmente reutilizam :c:func:`PyType_GenericNew`, como "
475+
"na primeira versão do tipo :class:`!Custom` acima. Neste caso, usamos o "
476+
"manipulador ``tp_new`` para inicializar os atributos ``first`` e ``last`` "
477+
"com valores padrão que não sejam ``NULL``."
461478

462479
#: ../../extending/newtypes_tutorial.rst:328
463480
msgid ""
@@ -468,24 +485,37 @@ msgid ""
468485
"often ignore the arguments, leaving the argument handling to initializer (a."
469486
"k.a. ``tp_init`` in C or ``__init__`` in Python) methods."
470487
msgstr ""
488+
"O ``tp_new`` recebe o tipo que está sendo instanciado (não necessariamente "
489+
"``CustomType``, caso uma subclasse esteja sendo instanciada) e quaisquer "
490+
"argumentos passados quando o tipo foi chamado, e deve devolver a instância "
491+
"criada. Manipuladores ``tp_new`` sempre aceitam argumentos posicionais e "
492+
"argumentos nomeados, mas frequentemente os ignoram, deixando o tratamento "
493+
"dos argumentos para os métodos inicializadores (ou seja, ``tp_init`` em C ou "
494+
"``__init__`` em Python)."
471495

472496
#: ../../extending/newtypes_tutorial.rst:336
473497
msgid ""
474498
"``tp_new`` shouldn't call ``tp_init`` explicitly, as the interpreter will do "
475499
"it itself."
476500
msgstr ""
501+
"``tp_new`` não deve chamar ``tp_init`` explicitamente, pois o interpretador "
502+
"fará isso por conta própria."
477503

478504
#: ../../extending/newtypes_tutorial.rst:339
479505
msgid ""
480506
"The ``tp_new`` implementation calls the :c:member:`~PyTypeObject.tp_alloc` "
481507
"slot to allocate memory::"
482508
msgstr ""
509+
"A implementação de ``tp_new`` chama o slot :c:member:`~PyTypeObject."
510+
"tp_alloc` para alocar memória::"
483511

484512
#: ../../extending/newtypes_tutorial.rst:344
485513
msgid ""
486514
"Since memory allocation may fail, we must check the :c:member:`~PyTypeObject."
487515
"tp_alloc` result against ``NULL`` before proceeding."
488516
msgstr ""
517+
"Como a alocação de memória pode falhar, precisamos verificar se o resultado "
518+
"de :c:member:`~PyTypeObject.tp_alloc` é ``NULL`` antes de prosseguir."
489519

490520
#: ../../extending/newtypes_tutorial.rst:348
491521
msgid ""
@@ -494,6 +524,10 @@ msgid ""
494524
"class, which is :class:`object` by default. Most types use the default "
495525
"allocation strategy."
496526
msgstr ""
527+
"Nós não preenchemos o campo :c:member:`~PyTypeObject.tp_alloc` por conta "
528+
"própria. Em vez disso, :c:func:`PyType_Ready` o preenche herdando-o da nossa "
529+
"classe base, que por padrão é :class:`object`. A maioria dos tipos usa a "
530+
"estratégia de alocação padrão."
497531

498532
#: ../../extending/newtypes_tutorial.rst:354
499533
msgid ""
@@ -513,10 +547,12 @@ msgid ""
513547
"We also define an initialization function which accepts arguments to provide "
514548
"initial values for our instance::"
515549
msgstr ""
550+
"Também definimos uma função de inicialização que aceita argumentos para "
551+
"fornecer valores iniciais para nosso instância::"
516552

517553
#: ../../extending/newtypes_tutorial.rst:393
518554
msgid "by filling the :c:member:`~PyTypeObject.tp_init` slot. ::"
519-
msgstr ""
555+
msgstr "preenchendo o campo :c:member:`~PyTypeObject.tp_init`::"
520556

521557
#: ../../extending/newtypes_tutorial.rst:397
522558
msgid ""

howto/urllib2.po

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,16 @@
55
#
66
# Translators:
77
# python-doc bot, 2025
8+
# Rafael Fontenelle <rffontenelle@gmail.com>, 2025
89
#
910
#, fuzzy
1011
msgid ""
1112
msgstr ""
1213
"Project-Id-Version: Python 3.11\n"
1314
"Report-Msgid-Bugs-To: \n"
14-
"POT-Creation-Date: 2025-09-22 20:37+0000\n"
15+
"POT-Creation-Date: 2025-11-19 17:32+0000\n"
1516
"PO-Revision-Date: 2025-09-22 16:49+0000\n"
16-
"Last-Translator: python-doc bot, 2025\n"
17+
"Last-Translator: Rafael Fontenelle <rffontenelle@gmail.com>, 2025\n"
1718
"Language-Team: Portuguese (Brazil) (https://app.transifex.com/python-doc/"
1819
"teams/5390/pt_BR/)\n"
1920
"Language: pt_BR\n"
@@ -406,6 +407,9 @@ msgid ""
406407
"of response codes in that shows all the response codes used by :rfc:`2616`. "
407408
"The dictionary is reproduced here for convenience ::"
408409
msgstr ""
410+
":attr:`http.server.BaseHTTPRequestHandler.responses` é um dicionário útil de "
411+
"códigos de resposta que mostra todos os códigos de resposta usados ​​pela :rfc:"
412+
"`2616`. O dicionário é reproduzido aqui para sua conveniência."
409413

410414
#: ../../howto/urllib2.rst:319
411415
msgid ""

library/html.parser.po

Lines changed: 19 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ msgid ""
1212
msgstr ""
1313
"Project-Id-Version: Python 3.11\n"
1414
"Report-Msgid-Bugs-To: \n"
15-
"POT-Creation-Date: 2025-11-03 16:37+0000\n"
15+
"POT-Creation-Date: 2025-11-19 17:32+0000\n"
1616
"PO-Revision-Date: 2025-09-22 16:50+0000\n"
1717
"Last-Translator: Rafael Fontenelle <rffontenelle@gmail.com>, 2025\n"
1818
"Language-Team: Portuguese (Brazil) (https://app.transifex.com/python-doc/"
@@ -114,6 +114,9 @@ msgid ""
114114
"`HTMLParser` class to print out start tags, end tags, and data as they are "
115115
"encountered::"
116116
msgstr ""
117+
"Como exemplo básico, abaixo está um analisador HTML simples que usa a "
118+
"classe :class:`HTMLParser` para exibir as tags de abertura, tags de "
119+
"fechamento e dados à medida que são encontrados::"
117120

118121
#: ../../library/html.parser.rst:71
119122
msgid "The output will then be:"
@@ -382,46 +385,57 @@ msgid ""
382385
"The following class implements a parser that will be used to illustrate more "
383386
"examples::"
384387
msgstr ""
388+
"A classe a seguir implementa um analisador sintático que será usado para "
389+
"ilustrar mais exemplos::"
385390

386391
#: ../../library/html.parser.rst:276
387392
msgid "Parsing a doctype::"
388-
msgstr ""
393+
msgstr "Analisando um doctype::"
389394

390395
#: ../../library/html.parser.rst:282
391396
msgid "Parsing an element with a few attributes and a title::"
392-
msgstr ""
397+
msgstr "Analisando um elemento com alguns atributos e um título::"
393398

394399
#: ../../library/html.parser.rst:294
395400
msgid ""
396401
"The content of elements like ``script`` and ``style`` is returned as is, "
397402
"without further parsing::"
398403
msgstr ""
404+
"O conteúdo de elementos como ``script`` e ``style`` é retornado como está, "
405+
"sem mais análises::"
399406

400407
#: ../../library/html.parser.rst:310
401408
msgid "Parsing comments::"
402-
msgstr ""
409+
msgstr "Analisando comentários::"
403410

404411
#: ../../library/html.parser.rst:317
405412
msgid ""
406413
"Parsing named and numeric character references and converting them to the "
407414
"correct char (note: these 3 references are all equivalent to ``'>'``)::"
408415
msgstr ""
416+
"Analisando referências de caracteres nomeadas e numéricas e convertendo-as "
417+
"para o caractere correto (nota: essas 3 referências são todas equivalentes a "
418+
"``'>'``)::"
409419

410420
#: ../../library/html.parser.rst:325
411421
msgid ""
412422
"Feeding incomplete chunks to :meth:`~HTMLParser.feed` works, but :meth:"
413423
"`~HTMLParser.handle_data` might be called more than once if "
414424
"*convert_charrefs* is false::"
415425
msgstr ""
426+
"Alimentar o :meth:`~HTMLParser.feed` com blocos incompletos funciona, mas :"
427+
"meth:`~HTMLParser.handle_data` pode ser chamado mais de uma vez se "
428+
"*convert_charrefs* for falso."
416429

417430
#: ../../library/html.parser.rst:338
418431
msgid "Parsing invalid HTML (e.g. unquoted attributes) also works::"
419432
msgstr ""
433+
"Analisando HTML inválido (por exemplo, atributos sem aspas) também funciona::"
420434

421435
#: ../../library/html.parser.rst:9
422436
msgid "HTML"
423437
msgstr "HTML"
424438

425439
#: ../../library/html.parser.rst:9
426440
msgid "XHTML"
427-
msgstr ""
441+
msgstr "XHTML"

potodo.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
1 directory 63.74% done
2-
└── 3.11/ 63.74% done
1+
1 directory 63.78% done
2+
└── 3.11/ 63.78% done
33
├── distutils/ 25.82% done
44
│ ├── apiref.po 88 / 414 ( 21.0% translated)
55
│ ├── builtdist.po 52 / 128 ( 40.0% translated)
@@ -22,7 +22,7 @@
2222
│ ├── executionmodel.po 73 / 75 ( 97.0% translated)
2323
│ ├── import.po 192 / 207 ( 92.0% translated)
2424
│ └── lexical_analysis.po 288 / 299 ( 96.0% translated)
25-
├── library/ 56.89% done
25+
├── library/ 56.91% done
2626
│ ├── _thread.po 49 / 51 ( 96.0% translated)
2727
│ ├── abc.po 48 / 49 ( 97.0% translated)
2828
│ ├── argparse.po 305 / 335 ( 91.0% translated)
@@ -92,7 +92,7 @@
9292
│ ├── hashlib.po 82 / 161 ( 50.0% translated)
9393
│ ├── heapq.po 50 / 51 ( 98.0% translated)
9494
│ ├── hmac.po 26 / 27 ( 96.0% translated)
95-
│ ├── html.parser.po 41 / 52 ( 78.0% translated)
95+
│ ├── html.parser.po 51 / 52 ( 98.0% translated)
9696
│ ├── http.client.po 49 / 107 ( 45.0% translated)
9797
│ ├── http.cookiejar.po 9 / 155 ( 5.0% translated)
9898
│ ├── http.cookies.po 8 / 47 ( 17.0% translated)
@@ -198,7 +198,7 @@
198198
│ ├── zipapp.po 66 / 79 ( 83.0% translated)
199199
│ ├── zipimport.po 34 / 38 ( 89.0% translated)
200200
│ └── zoneinfo.po 34 / 75 ( 45.0% translated)
201-
├── howto/ 64.70% done
201+
├── howto/ 64.75% done
202202
│ ├── curses.po 103 / 105 ( 98.0% translated)
203203
│ ├── descriptor.po 120 / 177 ( 67.0% translated)
204204
│ ├── enum.po 88 / 224 ( 39.0% translated)
@@ -210,15 +210,15 @@
210210
│ ├── sockets.po 35 / 58 ( 60.0% translated)
211211
│ ├── sorting.po 45 / 52 ( 86.0% translated)
212212
│ ├── unicode.po 30 / 121 ( 24.0% translated)
213-
│ └── urllib2.po 82 / 84 ( 97.0% translated)
213+
│ └── urllib2.po 83 / 84 ( 98.0% translated)
214214
├── install/ 71.32% done
215215
│ └── index.po 166 / 226 ( 73.0% translated)
216216
├── tutorial/ 100.00% done
217-
├── extending/ 30.93% done
217+
├── extending/ 32.87% done
218218
│ ├── embedding.po 5 / 45 ( 11.0% translated)
219219
│ ├── extending.po 58 / 162 ( 35.0% translated)
220220
│ ├── newtypes.po 11 / 105 ( 10.0% translated)
221-
│ └── newtypes_tutorial.po 52 / 123 ( 42.0% translated)
221+
│ └── newtypes_tutorial.po 63 / 123 ( 51.0% translated)
222222
├── whatsnew/ 75.28% done
223223
│ ├── 2.0.po 181 / 183 ( 98.0% translated)
224224
│ ├── 2.1.po 138 / 139 ( 99.0% translated)

stats.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{"completion": "63.74%", "translated": 38916, "entries": 55813, "updated_at": "2025-11-18T23:51:11+00:00Z"}
1+
{"completion": "63.78%", "translated": 38938, "entries": 55813, "updated_at": "2025-11-19T23:50:51+00:00Z"}

0 commit comments

Comments
 (0)