forked from AFPy/python-docs-fr
Make merge (#1695)
* Make merge * FIX: spelling for pospell. * Uniformisation des entêtes po.
This commit is contained in:
parent 0086ed1f76
commit 17d5f9cebe
257 changed files with 43019 additions and 31747 deletions
314 howto/annotations.po Normal file
314
howto/annotations.po Normal file | | @ -0,0 +1,314 @@ | |||
# Copyright (C) 2001-2018, Python Software Foundation | ||||
# For licence information, see README file. | ||||
# | ||||
msgid "" | ||||
msgstr "" | ||||
"Project-Id-Version: Python 3\n" | ||||
"Report-Msgid-Bugs-To: \n" | ||||
"POT-Creation-Date: 2021-09-23 16:16+0200\n" | ||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" | ||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" | ||||
"Language-Team: FRENCH <traductions@lists.afpy.org>\n" | ||||
"Language: fr\n" | ||||
"MIME-Version: 1.0\n" | ||||
"Content-Type: text/plain; charset=UTF-8\n" | ||||
"Content-Transfer-Encoding: 8bit\n" | ||||
| ||||
#: howto/annotations.rst:5 | ||||
msgid "Annotations Best Practices" | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:0 | ||||
msgid "author" | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:7 | ||||
msgid "Larry Hastings" | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:None | ||||
msgid "Abstract" | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:11 | ||||
msgid "" | ||||
"This document is designed to encapsulate the best practices for working with " | ||||
"annotations dicts. If you write Python code that examines " | ||||
"``__annotations__`` on Python objects, we encourage you to follow the " | ||||
"guidelines described below." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:16 | ||||
msgid "" | ||||
"The document is organized into four sections: best practices for accessing " | ||||
"the annotations of an object in Python versions 3.10 and newer, best " | ||||
"practices for accessing the annotations of an object in Python versions 3.9 " | ||||
"and older, other best practices for ``__annotations__`` that apply to any " | ||||
"Python version, and quirks of ``__annotations__``." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:26 | ||||
msgid "" | ||||
"Note that this document is specifically about working with " | ||||
"``__annotations__``, not uses *for* annotations. If you're looking for " | ||||
"information on how to use \"type hints\" in your code, please see the :mod:" | ||||
"`typing` module." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:33 | ||||
msgid "Accessing The Annotations Dict Of An Object In Python 3.10 And Newer" | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:35 | ||||
msgid "" | ||||
"Python 3.10 adds a new function to the standard library: :func:`inspect." | ||||
"get_annotations`. In Python versions 3.10 and newer, calling this function " | ||||
"is the best practice for accessing the annotations dict of any object that " | ||||
"supports annotations. This function can also \"un-stringize\" stringized " | ||||
"annotations for you." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:42 | ||||
msgid "" | ||||
"If for some reason :func:`inspect.get_annotations` isn't viable for your use " | ||||
"case, you may access the ``__annotations__`` data member manually. Best " | ||||
"practice for this changed in Python 3.10 as well: as of Python 3.10, ``o." | ||||
"__annotations__`` is guaranteed to *always* work on Python functions, " | ||||
"classes, and modules. If you're certain the object you're examining is one " | ||||
"of these three *specific* objects, you may simply use ``o.__annotations__`` " | ||||
"to get at the object's annotations dict." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:52 | ||||
msgid "" | ||||
"However, other types of callables--for example, callables created by :func:" | ||||
"`functools.partial`--may not have an ``__annotations__`` attribute defined. " | ||||
"When accessing the ``__annotations__`` of a possibly unknown object, best " | ||||
"practice in Python versions 3.10 and newer is to call :func:`getattr` with " | ||||
"three arguments, for example ``getattr(o, '__annotations__', None)``." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:62 | ||||
msgid "Accessing The Annotations Dict Of An Object In Python 3.9 And Older" | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:64 | ||||
msgid "" | ||||
"In Python 3.9 and older, accessing the annotations dict of an object is much " | ||||
"more complicated than in newer versions. The problem is a design flaw in " | ||||
"these older versions of Python, specifically to do with class annotations." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:69 | ||||
msgid "" | ||||
"Best practice for accessing the annotations dict of other objects--" | ||||
"functions, other callables, and modules--is the same as best practice for " | ||||
"3.10, assuming you aren't calling :func:`inspect.get_annotations`: you " | ||||
"should use three-argument :func:`getattr` to access the object's " | ||||
"``__annotations__`` attribute." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:76 | ||||
msgid "" | ||||
"Unfortunately, this isn't best practice for classes. The problem is that, " | ||||
"since ``__annotations__`` is optional on classes, and because classes can " | ||||
"inherit attributes from their base classes, accessing the " | ||||
"``__annotations__`` attribute of a class may inadvertently return the " | ||||
"annotations dict of a *base class.* As an example::" | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:92 | ||||
msgid "This will print the annotations dict from ``Base``, not ``Derived``." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:95 | ||||
msgid "" | ||||
"Your code will have to have a separate code path if the object you're " | ||||
"examining is a class (``isinstance(o, type)``). In that case, best practice " | ||||
"relies on an implementation detail of Python 3.9 and before: if a class has " | ||||
"annotations defined, they are stored in the class's ``__dict__`` " | ||||
"dictionary. Since the class may or may not have annotations defined, best " | ||||
"practice is to call the ``get`` method on the class dict." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:103 | ||||
msgid "" | ||||
"To put it all together, here is some sample code that safely accesses the " | ||||
"``__annotations__`` attribute on an arbitrary object in Python 3.9 and " | ||||
"before::" | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:112 | ||||
msgid "" | ||||
"After running this code, ``ann`` should be either a dictionary or ``None``. " | ||||
"You're encouraged to double-check the type of ``ann`` using :func:" | ||||
"`isinstance` before further examination." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:117 | ||||
msgid "" | ||||
"Note that some exotic or malformed type objects may not have a ``__dict__`` " | ||||
"attribute, so for extra safety you may also wish to use :func:`getattr` to " | ||||
"access ``__dict__``." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:123 | ||||
msgid "Manually Un-Stringizing Stringized Annotations" | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:125 | ||||
msgid "" | ||||
"In situations where some annotations may be \"stringized\", and you wish to " | ||||
"evaluate those strings to produce the Python values they represent, it " | ||||
"really is best to call :func:`inspect.get_annotations` to do this work for " | ||||
"you." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:131 | ||||
msgid "" | ||||
"If you're using Python 3.9 or older, or if for some reason you can't use :" | ||||
"func:`inspect.get_annotations`, you'll need to duplicate its logic. You're " | ||||
"encouraged to examine the implementation of :func:`inspect.get_annotations` " | ||||
"in the current Python version and follow a similar approach." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:137 | ||||
msgid "" | ||||
"In a nutshell, if you wish to evaluate a stringized annotation on an " | ||||
"arbitrary object ``o``:" | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:140 | ||||
msgid "" | ||||
"If ``o`` is a module, use ``o.__dict__`` as the ``globals`` when calling :" | ||||
"func:`eval`." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:142 | ||||
msgid "" | ||||
"If ``o`` is a class, use ``sys.modules[o.__module__].__dict__`` as the " | ||||
"``globals``, and ``dict(vars(o))`` as the ``locals``, when calling :func:" | ||||
"`eval`." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:145 | ||||
msgid "" | ||||
"If ``o`` is a wrapped callable using :func:`functools.update_wrapper`, :func:" | ||||
"`functools.wraps`, or :func:`functools.partial`, iteratively unwrap it by " | ||||
"accessing either ``o.__wrapped__`` or ``o.func`` as appropriate, until you " | ||||
"have found the root unwrapped function." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:149 | ||||
msgid "" | ||||
"If ``o`` is a callable (but not a class), use ``o.__globals__`` as the " | ||||
"globals when calling :func:`eval`." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:152 | ||||
msgid "" | ||||
"However, not all string values used as annotations can be successfully " | ||||
"turned into Python values by :func:`eval`. String values could theoretically " | ||||
"contain any valid string, and in practice there are valid use cases for type " | ||||
"hints that require annotating with string values that specifically *can't* " | ||||
"be evaluated. For example:" | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:159 | ||||
msgid "" | ||||
":pep:`604` union types using `|`, before support for this was added to " | ||||
"Python 3.10." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:161 | ||||
msgid "" | ||||
"Definitions that aren't needed at runtime, only imported when :const:`typing." | ||||
"TYPE_CHECKING` is true." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:164 | ||||
msgid "" | ||||
"If :func:`eval` attempts to evaluate such values, it will fail and raise an " | ||||
"exception. So, when designing a library API that works with annotations, " | ||||
"it's recommended to only attempt to evaluate string values when explicitly " | ||||
"requested to by the caller." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:172 | ||||
msgid "Best Practices For ``__annotations__`` In Any Python Version" | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:174 | ||||
msgid "" | ||||
"You should avoid assigning to the ``__annotations__`` member of objects " | ||||
"directly. Let Python manage setting ``__annotations__``." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:177 | ||||
msgid "" | ||||
"If you do assign directly to the ``__annotations__`` member of an object, " | ||||
"you should always set it to a ``dict`` object." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:180 | ||||
msgid "" | ||||
"If you directly access the ``__annotations__`` member of an object, you " | ||||
"should ensure that it's a dictionary before attempting to examine its " | ||||
"contents." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:184 | ||||
msgid "You should avoid modifying ``__annotations__`` dicts." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:186 | ||||
msgid "" | ||||
"You should avoid deleting the ``__annotations__`` attribute of an object." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:191 | ||||
msgid "``__annotations__`` Quirks" | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:193 | ||||
msgid "" | ||||
"In all versions of Python 3, function objects lazy-create an annotations " | ||||
"dict if no annotations are defined on that object. You can delete the " | ||||
"``__annotations__`` attribute using ``del fn.__annotations__``, but if you " | ||||
"then access ``fn.__annotations__`` the object will create a new empty dict " | ||||
"that it will store and return as its annotations. Deleting the annotations " | ||||
"on a function before it has lazily created its annotations dict will throw " | ||||
"an ``AttributeError``; using ``del fn.__annotations__`` twice in a row is " | ||||
"guaranteed to always throw an ``AttributeError``." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:203 | ||||
msgid "" | ||||
"Everything in the above paragraph also applies to class and module objects " | ||||
"in Python 3.10 and newer." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:206 | ||||
msgid "" | ||||
"In all versions of Python 3, you can set ``__annotations__`` on a function " | ||||
"object to ``None``. However, subsequently accessing the annotations on that " | ||||
"object using ``fn.__annotations__`` will lazy-create an empty dictionary as " | ||||
"per the first paragraph of this section. This is *not* true of modules and " | ||||
"classes, in any Python version; those objects permit setting " | ||||
"``__annotations__`` to any Python value, and will retain whatever value is " | ||||
"set." | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:214 | ||||
msgid "" | ||||
"If Python stringizes your annotations for you (using ``from __future__ " | ||||
"import annotations``), and you specify a string as an annotation, the string " | ||||
"will itself be quoted. In effect the annotation is quoted *twice.* For " | ||||
"example::" | ||||
msgstr "" | ||||
| ||||
#: howto/annotations.rst:225 | ||||
msgid "" | ||||
"This prints ``{'a': \"'str'\"}``. This shouldn't really be considered a " | ||||
"\"quirk\"; it's mentioned here simply because it might be surprising." | ||||
msgstr "" | ||||
| | @ -5,7 +5,7 @@ msgid "" | |||
msgstr "" | ||||
"Project-Id-Version: Python 3\n" | ||||
"Report-Msgid-Bugs-To: \n" | ||||
"POT-Creation-Date: 2020-10-01 16:00+0200\n" | ||||
"POT-Creation-Date: 2021-09-23 16:16+0200\n" | ||||
"PO-Revision-Date: 2019-07-25 16:44+0200\n" | ||||
"Last-Translator: Antonin Décimo <antonin.decimo@gmail.com>\n" | ||||
"Language-Team: FRENCH <traductions@lists.afpy.org>\n" | ||||
| | @ -417,14 +417,15 @@ msgstr "" | |||
"de la commande ``python --help``) ::" | ||||
| ||||
#: howto/argparse.rst:470 | ||||
#, fuzzy | ||||
msgid "" | ||||
"We have introduced another action, \"count\", to count the number of " | ||||
"occurrences of a specific optional arguments:" | ||||
"occurrences of specific options." | ||||
msgstr "" | ||||
"Nous avons introduit une autre action, ``\"count\"``, pour compter le nombre " | ||||
"d’occurrences d'une argument optionnel en particulier :" | ||||
| ||||
#: howto/argparse.rst:498 | ||||
#: howto/argparse.rst:499 | ||||
msgid "" | ||||
"Yes, it's now more of a flag (similar to ``action=\"store_true\"``) in the " | ||||
"previous version of our script. That should explain the complaint." | ||||
| | @ -433,11 +434,11 @@ msgstr "" | |||
"\"store_true\"``) de la version précédente de notre script. Cela devrait " | ||||
"expliquer le message d'erreur." | ||||
| ||||
#: howto/argparse.rst:501 | ||||
#: howto/argparse.rst:502 | ||||
msgid "It also behaves similar to \"store_true\" action." | ||||
msgstr "Cela se comporte de la même manière que l'action ``\"store_true\"``." | ||||
| ||||
#: howto/argparse.rst:503 | ||||
#: howto/argparse.rst:504 | ||||
msgid "" | ||||
"Now here's a demonstration of what the \"count\" action gives. You've " | ||||
"probably seen this sort of usage before." | ||||
| | @ -445,7 +446,7 @@ msgstr "" | |||
"Maintenant voici une démonstration de ce que l'action ``\"count\"`` fait. " | ||||
"Vous avez sûrement vu ce genre d'utilisation auparavant." | ||||
| ||||
#: howto/argparse.rst:506 | ||||
#: howto/argparse.rst:507 | ||||
msgid "" | ||||
"And if you don't specify the ``-v`` flag, that flag is considered to have " | ||||
"``None`` value." | ||||
| | @ -453,7 +454,7 @@ msgstr "" | |||
"Et si vous ne spécifiez pas l'option ``-v``, cette option prendra la valeur " | ||||
"``None``." | ||||
| ||||
#: howto/argparse.rst:509 | ||||
#: howto/argparse.rst:510 | ||||
msgid "" | ||||
"As should be expected, specifying the long form of the flag, we should get " | ||||
"the same output." | ||||
| | @ -461,7 +462,7 @@ msgstr "" | |||
"Comme on s'y attend, en spécifiant l'option dans sa forme longue, on devrait " | ||||
"obtenir la même sortie." | ||||
| ||||
#: howto/argparse.rst:512 | ||||
#: howto/argparse.rst:513 | ||||
msgid "" | ||||
"Sadly, our help output isn't very informative on the new ability our script " | ||||
"has acquired, but that can always be fixed by improving the documentation " | ||||
| | @ -471,19 +472,19 @@ msgstr "" | |||
"nouvelles possibilités de notre programme, mais cela peut toujours être " | ||||
"corrigé en améliorant sa documentation (en utilisant l'argument ``help``)." | ||||
| ||||
#: howto/argparse.rst:516 | ||||
#: howto/argparse.rst:517 | ||||
msgid "That last output exposes a bug in our program." | ||||
msgstr "La dernière sortie du programme montre que celui-ci contient un bogue." | ||||
| ||||
#: howto/argparse.rst:519 | ||||
#: howto/argparse.rst:520 | ||||
msgid "Let's fix::" | ||||
msgstr "Corrigeons ::" | ||||
| ||||
#: howto/argparse.rst:538 | ||||
#: howto/argparse.rst:539 | ||||
msgid "And this is what it gives:" | ||||
msgstr "Et c'est ce que ça donne :" | ||||
| ||||
#: howto/argparse.rst:553 | ||||
#: howto/argparse.rst:554 | ||||
msgid "" | ||||
"First output went well, and fixes the bug we had before. That is, we want " | ||||
"any value >= 2 to be as verbose as possible." | ||||
| | @ -492,15 +493,15 @@ msgstr "" | |||
"avons eu est corrigé. Cela dit, nous voulons que n'importe quelle valeur >= " | ||||
"2 rende le programme aussi verbeux que possible." | ||||
| ||||
#: howto/argparse.rst:556 | ||||
#: howto/argparse.rst:557 | ||||
msgid "Third output not so good." | ||||
msgstr "La troisième sortie de programme n'est pas si bien que ça." | ||||
| ||||
#: howto/argparse.rst:558 | ||||
#: howto/argparse.rst:559 | ||||
msgid "Let's fix that bug::" | ||||
msgstr "Corrigeons ce bogue ::" | ||||
| ||||
#: howto/argparse.rst:575 | ||||
#: howto/argparse.rst:576 | ||||
msgid "" | ||||
"We've just introduced yet another keyword, ``default``. We've set it to " | ||||
"``0`` in order to make it comparable to the other int values. Remember that " | ||||
| | @ -514,11 +515,11 @@ msgstr "" | |||
"il sera définit à ``None``, et ne pourra pas être comparé à une valeur de " | ||||
"type entier (une erreur :exc:`TypeError` serait alors levée)." | ||||
| ||||
#: howto/argparse.rst:582 | ||||
#: howto/argparse.rst:583 | ||||
msgid "And:" | ||||
msgstr "Et :" | ||||
| ||||
#: howto/argparse.rst:589 | ||||
#: howto/argparse.rst:590 | ||||
msgid "" | ||||
"You can go quite far just with what we've learned so far, and we have only " | ||||
"scratched the surface. The :mod:`argparse` module is very powerful, and " | ||||
| | @ -529,11 +530,11 @@ msgstr "" | |||
"est très puissant, et nous allons l'explorer un peu plus avant la fin de ce " | ||||
"tutoriel." | ||||
| ||||
#: howto/argparse.rst:596 | ||||
#: howto/argparse.rst:597 | ||||
msgid "Getting a little more advanced" | ||||
msgstr "Aller un peu plus loin" | ||||
| ||||
#: howto/argparse.rst:598 | ||||
#: howto/argparse.rst:599 | ||||
msgid "" | ||||
"What if we wanted to expand our tiny program to perform other powers, not " | ||||
"just squares::" | ||||
| | @ -541,11 +542,11 @@ msgstr "" | |||
"Qu'en est-il si nous souhaitons étendre notre mini programme pour le rendre " | ||||
"capable de calculer d'autres puissances, et pas seulement des carrés ::" | ||||
| ||||
#: howto/argparse.rst:653 | ||||
#: howto/argparse.rst:654 | ||||
msgid "Output:" | ||||
msgstr "Sortie :" | ||||
| ||||
#: howto/argparse.rst:636 | ||||
#: howto/argparse.rst:637 | ||||
msgid "" | ||||
"Notice that so far we've been using verbosity level to *change* the text " | ||||
"that gets displayed. The following example instead uses verbosity level to " | ||||
| | @ -555,11 +556,11 @@ msgstr "" | |||
"pour *changer* le texte qui est affiché. L'exemple suivant au contraire " | ||||
"utilise le niveau de verbosité pour afficher *plus* de texte à la place ::" | ||||
| ||||
#: howto/argparse.rst:667 | ||||
#: howto/argparse.rst:668 | ||||
msgid "Conflicting options" | ||||
msgstr "Paramètres en conflit" | ||||
| ||||
#: howto/argparse.rst:669 | ||||
#: howto/argparse.rst:670 | ||||
msgid "" | ||||
"So far, we have been working with two methods of an :class:`argparse." | ||||
"ArgumentParser` instance. Let's introduce a third one, :meth:" | ||||
| | @ -576,7 +577,7 @@ msgstr "" | |||
"introduire l'option ``--quiet``, qui va avoir l'effet opposé de l'option ``--" | ||||
"verbose`` ::" | ||||
| ||||
#: howto/argparse.rst:695 | ||||
#: howto/argparse.rst:696 | ||||
msgid "" | ||||
"Our program is now simpler, and we've lost some functionality for the sake " | ||||
"of demonstration. Anyways, here's the output:" | ||||
| | @ -585,7 +586,7 @@ msgstr "" | |||
"fonctionnalités pour faire cette démonstration. Peu importe, voici la sortie " | ||||
"du programme :" | ||||
| ||||
#: howto/argparse.rst:713 | ||||
#: howto/argparse.rst:714 | ||||
msgid "" | ||||
"That should be easy to follow. I've added that last output so you can see " | ||||
"the sort of flexibility you get, i.e. mixing long form options with short " | ||||
| | @ -595,7 +596,7 @@ msgstr "" | |||
"que vous puissiez voir le genre de flexibilité que vous pouvez avoir, par " | ||||
"exemple pour faire un mélange entre des paramètres courts et longs." | ||||
| ||||
#: howto/argparse.rst:717 | ||||
#: howto/argparse.rst:718 | ||||
msgid "" | ||||
"Before we conclude, you probably want to tell your users the main purpose of " | ||||
"your program, just in case they don't know::" | ||||
| | @ -604,7 +605,7 @@ msgstr "" | |||
"le but principal de votre programme, juste dans le cas ou ils ne le " | ||||
"sauraient pas ::" | ||||
| ||||
#: howto/argparse.rst:738 | ||||
#: howto/argparse.rst:739 | ||||
msgid "" | ||||
"Note that slight difference in the usage text. Note the ``[-v | -q]``, which " | ||||
"tells us that we can either use ``-v`` or ``-q``, but not both at the same " | ||||
| | @ -614,11 +615,11 @@ msgstr "" | |||
"nous disent que nous pouvons utiliser au choix ``-v`` ou ``-q``, mais pas " | ||||
"les deux ensemble :" | ||||
| ||||
#: howto/argparse.rst:760 | ||||
#: howto/argparse.rst:761 | ||||
msgid "Conclusion" | ||||
msgstr "Conclusion" | ||||
| ||||
#: howto/argparse.rst:762 | ||||
#: howto/argparse.rst:763 | ||||
msgid "" | ||||
"The :mod:`argparse` module offers a lot more than shown here. Its docs are " | ||||
"quite detailed and thorough, and full of examples. Having gone through this " | ||||
| | | |||
317 howto/clinic.po
317
howto/clinic.po | | @ -5,7 +5,7 @@ msgid "" | |||
msgstr "" | ||||
"Project-Id-Version: Python 3\n" | ||||
"Report-Msgid-Bugs-To: \n" | ||||
"POT-Creation-Date: 2020-10-01 16:00+0200\n" | ||||
"POT-Creation-Date: 2021-09-23 16:16+0200\n" | ||||
"PO-Revision-Date: 2021-06-04 15:16+0200\n" | ||||
"Last-Translator: Mindiell <mindiell@mindiell.net>\n" | ||||
"Language-Team: FRENCH <traductions@lists.afpy.org>\n" | ||||
| | @ -1221,7 +1221,7 @@ msgstr "" | |||
"Tous les arguments passés aux adaptateurs d'Argument Clinic sont nommés. " | ||||
"Tous les adaptateurs d'Argument Clinic acceptent les arguments suivants :" | ||||
| ||||
#: howto/clinic.rst:1252 | ||||
#: howto/clinic.rst:1314 | ||||
msgid "``c_default``" | ||||
msgstr "``c_default``" | ||||
| ||||
| | @ -1292,7 +1292,7 @@ msgstr "" | |||
"argument Python sera transcrite dans le paramètre sans aucune vérification " | ||||
"de plage, même pour des valeurs négatives." | ||||
| ||||
#: howto/clinic.rst:1266 | ||||
#: howto/clinic.rst:1328 | ||||
msgid "``converter``" | ||||
msgstr "``converter``" | ||||
| ||||
| | @ -1331,7 +1331,7 @@ msgstr "" | |||
"Autorisé seulement pour l'adaptateur ``object``. Nécessite que la valeur " | ||||
"Python soit une sous-classe d'un type Python, telle qu'exprimée en C." | ||||
| ||||
#: howto/clinic.rst:1238 | ||||
#: howto/clinic.rst:1300 | ||||
msgid "``type``" | ||||
msgstr "``type``" | ||||
| ||||
| | @ -2186,11 +2186,70 @@ msgid "" | |||
"``self_converter`` but overwriting the ``type`` member::" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1211 | ||||
#: howto/clinic.rst:1210 | ||||
msgid "Using a \"defining class\" converter" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1212 | ||||
msgid "" | ||||
"Argument Clinic facilitates gaining access to the defining class of a " | ||||
"method. This is useful for :ref:`heap type <heap-types>` methods that need " | ||||
"to fetch module level state. Use :c:func:`PyType_FromModuleAndSpec` to " | ||||
"associate a new heap type with a module. You can now use :c:func:" | ||||
"`PyType_GetModuleState` on the defining class to fetch the module state, for " | ||||
"example from a module method." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1218 | ||||
msgid "" | ||||
"Example from ``Modules/zlibmodule.c``. First, ``defining_class`` is added " | ||||
"to the clinic input::" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1230 | ||||
msgid "" | ||||
"After running the Argument Clinic tool, the following function signature is " | ||||
"generated::" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1240 | ||||
msgid "" | ||||
"The following code can now use ``PyType_GetModuleState(cls)`` to fetch the " | ||||
"module state::" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1246 | ||||
msgid "" | ||||
"Each method may only have one argument using this converter, and it must " | ||||
"appear after ``self``, or, if ``self`` is not used, as the first argument. " | ||||
"The argument will be of type ``PyTypeObject *``. The argument will not " | ||||
"appear in the ``__text_signature__``." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1251 | ||||
msgid "" | ||||
"The ``defining_class`` converter is not compatible with ``__init__`` and " | ||||
"``__new__`` methods, which cannot use the ``METH_METHOD`` convention." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1254 | ||||
msgid "" | ||||
"It is not possible to use ``defining_class`` with slot methods. In order to " | ||||
"fetch the module state from such methods, use ``_PyType_GetModuleByDef`` to " | ||||
"look up the module and then :c:func:`PyModule_GetState` to fetch the module " | ||||
"state. Example from the ``setattro`` slot method in ``Modules/_threadmodule." | ||||
"c``::" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1269 | ||||
msgid "See also :pep:`573`." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1273 | ||||
msgid "Writing a custom converter" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1213 | ||||
#: howto/clinic.rst:1275 | ||||
msgid "" | ||||
"As we hinted at in the previous section... you can write your own " | ||||
"converters! A converter is simply a Python class that inherits from " | ||||
| | @ -2199,7 +2258,7 @@ msgid "" | |||
"a :c:func:`PyArg_ParseTuple` \"converter function\"." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1219 | ||||
#: howto/clinic.rst:1281 | ||||
msgid "" | ||||
"Your converter class should be named ``*something*_converter``. If the name " | ||||
"follows this convention, then your converter class will be automatically " | ||||
| | @ -2208,7 +2267,7 @@ msgid "" | |||
"metaclass.)" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1225 | ||||
#: howto/clinic.rst:1287 | ||||
msgid "" | ||||
"You shouldn't subclass ``CConverter.__init__``. Instead, you should write a " | ||||
"``converter_init()`` function. ``converter_init()`` always accepts a " | ||||
| | @ -2217,50 +2276,50 @@ msgid "" | |||
"passed along to your ``converter_init()``." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1232 | ||||
#: howto/clinic.rst:1294 | ||||
msgid "" | ||||
"There are some additional members of ``CConverter`` you may wish to specify " | ||||
"in your subclass. Here's the current list:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1236 | ||||
#: howto/clinic.rst:1298 | ||||
msgid "" | ||||
"The C type to use for this variable. ``type`` should be a Python string " | ||||
"specifying the type, e.g. ``int``. If this is a pointer type, the type " | ||||
"string should end with ``' *'``." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1242 | ||||
#: howto/clinic.rst:1304 | ||||
msgid "``default``" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1241 | ||||
#: howto/clinic.rst:1303 | ||||
msgid "" | ||||
"The Python default value for this parameter, as a Python value. Or the magic " | ||||
"value ``unspecified`` if there is no default." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1247 | ||||
#: howto/clinic.rst:1309 | ||||
msgid "``py_default``" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1245 | ||||
#: howto/clinic.rst:1307 | ||||
msgid "" | ||||
"``default`` as it should appear in Python code, as a string. Or ``None`` if " | ||||
"there is no default." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1250 | ||||
#: howto/clinic.rst:1312 | ||||
msgid "" | ||||
"``default`` as it should appear in C code, as a string. Or ``None`` if there " | ||||
"is no default." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1263 | ||||
#: howto/clinic.rst:1325 | ||||
msgid "``c_ignored_default``" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1255 | ||||
#: howto/clinic.rst:1317 | ||||
msgid "" | ||||
"The default value used to initialize the C variable when there is no " | ||||
"default, but not specifying a default may result in an \"uninitialized " | ||||
| | @ -2271,37 +2330,37 @@ msgid "" | |||
"non-empty string." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1266 | ||||
#: howto/clinic.rst:1328 | ||||
msgid "The name of the C converter function, as a string." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1271 | ||||
#: howto/clinic.rst:1333 | ||||
msgid "``impl_by_reference``" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1269 | ||||
#: howto/clinic.rst:1331 | ||||
msgid "" | ||||
"A boolean value. If true, Argument Clinic will add a ``&`` in front of the " | ||||
"name of the variable when passing it into the impl function." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1277 | ||||
#: howto/clinic.rst:1339 | ||||
msgid "``parse_by_reference``" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1274 | ||||
#: howto/clinic.rst:1336 | ||||
msgid "" | ||||
"A boolean value. If true, Argument Clinic will add a ``&`` in front of the " | ||||
"name of the variable when passing it into :c:func:`PyArg_ParseTuple`." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1279 | ||||
#: howto/clinic.rst:1341 | ||||
msgid "" | ||||
"Here's the simplest example of a custom converter, from ``Modules/zlibmodule." | ||||
"c``::" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1290 | ||||
#: howto/clinic.rst:1352 | ||||
msgid "" | ||||
"This block adds a converter to Argument Clinic named ``ssize_t``. " | ||||
"Parameters declared as ``ssize_t`` will be declared as type ``Py_ssize_t``, " | ||||
| | @ -2310,25 +2369,25 @@ msgid "" | |||
"automatically support default values." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1296 | ||||
#: howto/clinic.rst:1358 | ||||
msgid "" | ||||
"More sophisticated custom converters can insert custom C code to handle " | ||||
"initialization and cleanup. You can see more examples of custom converters " | ||||
"in the CPython source tree; grep the C files for the string ``CConverter``." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1302 | ||||
#: howto/clinic.rst:1364 | ||||
msgid "Writing a custom return converter" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1304 | ||||
#: howto/clinic.rst:1366 | ||||
msgid "" | ||||
"Writing a custom return converter is much like writing a custom converter. " | ||||
"Except it's somewhat simpler, because return converters are themselves much " | ||||
"simpler." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1308 | ||||
#: howto/clinic.rst:1370 | ||||
msgid "" | ||||
"Return converters must subclass ``CReturnConverter``. There are no examples " | ||||
"yet of custom return converters, because they are not widely used yet. If " | ||||
| | @ -2337,59 +2396,59 @@ msgid "" | |||
"its subclasses." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1316 | ||||
#: howto/clinic.rst:1378 | ||||
msgid "METH_O and METH_NOARGS" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1318 | ||||
#: howto/clinic.rst:1380 | ||||
msgid "" | ||||
"To convert a function using ``METH_O``, make sure the function's single " | ||||
"argument is using the ``object`` converter, and mark the arguments as " | ||||
"positional-only::" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1330 | ||||
#: howto/clinic.rst:1392 | ||||
msgid "" | ||||
"To convert a function using ``METH_NOARGS``, just don't specify any " | ||||
"arguments." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1333 | ||||
#: howto/clinic.rst:1395 | ||||
msgid "" | ||||
"You can still use a self converter, a return converter, and specify a " | ||||
"``type`` argument to the object converter for ``METH_O``." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1337 | ||||
#: howto/clinic.rst:1399 | ||||
msgid "tp_new and tp_init functions" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1339 | ||||
#: howto/clinic.rst:1401 | ||||
msgid "" | ||||
"You can convert ``tp_new`` and ``tp_init`` functions. Just name them " | ||||
"``__new__`` or ``__init__`` as appropriate. Notes:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1342 | ||||
#: howto/clinic.rst:1404 | ||||
msgid "" | ||||
"The function name generated for ``__new__`` doesn't end in ``__new__`` like " | ||||
"it would by default. It's just the name of the class, converted into a " | ||||
"valid C identifier." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1346 | ||||
#: howto/clinic.rst:1408 | ||||
msgid "No ``PyMethodDef`` ``#define`` is generated for these functions." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1348 | ||||
#: howto/clinic.rst:1410 | ||||
msgid "``__init__`` functions return ``int``, not ``PyObject *``." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1350 | ||||
#: howto/clinic.rst:1412 | ||||
msgid "Use the docstring as the class docstring." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1352 | ||||
#: howto/clinic.rst:1414 | ||||
msgid "" | ||||
"Although ``__new__`` and ``__init__`` functions must always accept both the " | ||||
"``args`` and ``kwargs`` objects, when converting you may specify any " | ||||
| | @ -2398,11 +2457,11 @@ msgid "" | |||
"it receives any.)" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1359 | ||||
#: howto/clinic.rst:1421 | ||||
msgid "Changing and redirecting Clinic's output" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1361 | ||||
#: howto/clinic.rst:1423 | ||||
msgid "" | ||||
"It can be inconvenient to have Clinic's output interspersed with your " | ||||
"conventional hand-edited C code. Luckily, Clinic is configurable: you can " | ||||
| | @ -2411,7 +2470,7 @@ msgid "" | |||
"Clinic's generated output." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1367 | ||||
#: howto/clinic.rst:1429 | ||||
msgid "" | ||||
"While changing Clinic's output in this manner can be a boon to readability, " | ||||
"it may result in Clinic code using types before they are defined, or your " | ||||
| | @ -2423,15 +2482,15 @@ msgid "" | |||
"rearranging your code to fix definition-before-use problems.)" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1376 | ||||
#: howto/clinic.rst:1438 | ||||
msgid "Let's start with defining some terminology:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1403 | ||||
#: howto/clinic.rst:1465 | ||||
msgid "*field*" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1379 | ||||
#: howto/clinic.rst:1441 | ||||
msgid "" | ||||
"A field, in this context, is a subsection of Clinic's output. For example, " | ||||
"the ``#define`` for the ``PyMethodDef`` structure is a field, called " | ||||
| | @ -2439,7 +2498,7 @@ msgid "" | |||
"function definition:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1394 | ||||
#: howto/clinic.rst:1456 | ||||
msgid "" | ||||
"All the names are of the form ``\"<a>_<b>\"``, where ``\"<a>\"`` is the " | ||||
"semantic object represented (the parsing function, the impl function, the " | ||||
| | @ -2452,42 +2511,42 @@ msgid "" | |||
"\"``, representing that it's a preprocessor #define.)" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1437 | ||||
#: howto/clinic.rst:1499 | ||||
msgid "*destination*" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1406 | ||||
#: howto/clinic.rst:1468 | ||||
msgid "" | ||||
"A destination is a place Clinic can write output to. There are five built-" | ||||
"in destinations:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1486 howto/clinic.rst:1564 | ||||
#: howto/clinic.rst:1548 howto/clinic.rst:1626 | ||||
msgid "``block``" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1410 | ||||
#: howto/clinic.rst:1472 | ||||
msgid "" | ||||
"The default destination: printed in the output section of the current Clinic " | ||||
"block." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1513 howto/clinic.rst:1567 | ||||
#: howto/clinic.rst:1575 howto/clinic.rst:1629 | ||||
msgid "``buffer``" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1414 | ||||
#: howto/clinic.rst:1476 | ||||
msgid "" | ||||
"A text buffer where you can save text for later. Text sent here is appended " | ||||
"to the end of any existing text. It's an error to have any text left in the " | ||||
"buffer when Clinic finishes processing a file." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1499 howto/clinic.rst:1593 | ||||
#: howto/clinic.rst:1561 howto/clinic.rst:1655 | ||||
msgid "``file``" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1420 | ||||
#: howto/clinic.rst:1482 | ||||
msgid "" | ||||
"A separate \"clinic file\" that will be created automatically by Clinic. The " | ||||
"filename chosen for the file is ``{basename}.clinic{extension}``, where " | ||||
| | @ -2496,64 +2555,64 @@ msgid "" | |||
"for ``_pickle.c`` would be written to ``_pickle.clinic.c``.)" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1427 | ||||
#: howto/clinic.rst:1489 | ||||
msgid "" | ||||
"**Important: When using a** ``file`` **destination, you** *must check in* " | ||||
"**the generated file!**" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1526 howto/clinic.rst:1597 | ||||
#: howto/clinic.rst:1588 howto/clinic.rst:1659 | ||||
msgid "``two-pass``" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1431 | ||||
#: howto/clinic.rst:1493 | ||||
msgid "" | ||||
"A buffer like ``buffer``. However, a two-pass buffer can only be dumped " | ||||
"once, and it prints out all text sent to it during all processing, even from " | ||||
"Clinic blocks *after* the dumping point." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1560 | ||||
#: howto/clinic.rst:1622 | ||||
msgid "``suppress``" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1436 | ||||
#: howto/clinic.rst:1498 | ||||
msgid "The text is suppressed—thrown away." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1439 | ||||
#: howto/clinic.rst:1501 | ||||
msgid "Clinic defines five new directives that let you reconfigure its output." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1441 | ||||
#: howto/clinic.rst:1503 | ||||
msgid "The first new directive is ``dump``:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1447 | ||||
#: howto/clinic.rst:1509 | ||||
msgid "" | ||||
"This dumps the current contents of the named destination into the output of " | ||||
"the current block, and empties it. This only works with ``buffer`` and " | ||||
"``two-pass`` destinations." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1451 | ||||
#: howto/clinic.rst:1513 | ||||
msgid "" | ||||
"The second new directive is ``output``. The most basic form of ``output`` " | ||||
"is like this:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1458 | ||||
#: howto/clinic.rst:1520 | ||||
msgid "" | ||||
"This tells Clinic to output *field* to *destination*. ``output`` also " | ||||
"supports a special meta-destination, called ``everything``, which tells " | ||||
"Clinic to output *all* fields to that *destination*." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1462 | ||||
#: howto/clinic.rst:1524 | ||||
msgid "``output`` has a number of other functions:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1471 | ||||
#: howto/clinic.rst:1533 | ||||
msgid "" | ||||
"``output push`` and ``output pop`` allow you to push and pop configurations " | ||||
"on an internal configuration stack, so that you can temporarily modify the " | ||||
| | @ -2562,25 +2621,25 @@ msgid "" | |||
"when you wish to restore the previous configuration." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1478 | ||||
#: howto/clinic.rst:1540 | ||||
msgid "" | ||||
"``output preset`` sets Clinic's output to one of several built-in preset " | ||||
"configurations, as follows:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1482 | ||||
#: howto/clinic.rst:1544 | ||||
msgid "" | ||||
"Clinic's original starting configuration. Writes everything immediately " | ||||
"after the input block." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1485 | ||||
#: howto/clinic.rst:1547 | ||||
msgid "" | ||||
"Suppress the ``parser_prototype`` and ``docstring_prototype``, write " | ||||
"everything else to ``block``." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1489 | ||||
#: howto/clinic.rst:1551 | ||||
msgid "" | ||||
"Designed to write everything to the \"clinic file\" that it can. You then " | ||||
"``#include`` this file near the top of your file. You may need to rearrange " | ||||
| | @ -2588,17 +2647,17 @@ msgid "" | |||
"declarations for various ``typedef`` and ``PyTypeObject`` definitions." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1495 | ||||
#: howto/clinic.rst:1557 | ||||
msgid "" | ||||
"Suppress the ``parser_prototype`` and ``docstring_prototype``, write the " | ||||
"``impl_definition`` to ``block``, and write everything else to ``file``." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1499 | ||||
#: howto/clinic.rst:1561 | ||||
msgid "The default filename is ``\"{dirname}/clinic/{basename}.h\"``." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1502 | ||||
#: howto/clinic.rst:1564 | ||||
msgid "" | ||||
"Save up most of the output from Clinic, to be written into your file near " | ||||
"the end. For Python files implementing modules or builtin types, it's " | ||||
| | @ -2608,14 +2667,14 @@ msgid "" | |||
"static ``PyMethodDef`` arrays defined in the middle of the file." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1511 | ||||
#: howto/clinic.rst:1573 | ||||
msgid "" | ||||
"Suppress the ``parser_prototype``, ``impl_prototype``, and " | ||||
"``docstring_prototype``, write the ``impl_definition`` to ``block``, and " | ||||
"write everything else to ``file``." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1516 | ||||
#: howto/clinic.rst:1578 | ||||
msgid "" | ||||
"Similar to the ``buffer`` preset, but writes forward declarations to the " | ||||
"``two-pass`` buffer, and definitions to the ``buffer``. This is similar to " | ||||
| | @ -2624,18 +2683,18 @@ msgid "" | |||
"near the end just like you would when using the ``buffer`` preset." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1523 | ||||
#: howto/clinic.rst:1585 | ||||
msgid "" | ||||
"Suppresses the ``impl_prototype``, write the ``impl_definition`` to " | ||||
"``block``, write ``docstring_prototype``, ``methoddef_define``, and " | ||||
"``parser_prototype`` to ``two-pass``, write everything else to ``buffer``." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1537 | ||||
#: howto/clinic.rst:1599 | ||||
msgid "``partial-buffer``" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1529 | ||||
#: howto/clinic.rst:1591 | ||||
msgid "" | ||||
"Similar to the ``buffer`` preset, but writes more things to ``block``, only " | ||||
"writing the really big chunks of generated code to ``buffer``. This avoids " | ||||
| | @ -2645,137 +2704,137 @@ msgid "" | |||
"preset." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1536 | ||||
#: howto/clinic.rst:1598 | ||||
msgid "" | ||||
"Suppresses the ``impl_prototype``, write the ``docstring_definition`` and " | ||||
"``parser_definition`` to ``buffer``, write everything else to ``block``." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1539 | ||||
#: howto/clinic.rst:1601 | ||||
msgid "The third new directive is ``destination``:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1545 | ||||
#: howto/clinic.rst:1607 | ||||
msgid "This performs an operation on the destination named ``name``." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1547 | ||||
#: howto/clinic.rst:1609 | ||||
msgid "There are two defined subcommands: ``new`` and ``clear``." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1549 | ||||
#: howto/clinic.rst:1611 | ||||
msgid "The ``new`` subcommand works like this:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1555 | ||||
#: howto/clinic.rst:1617 | ||||
msgid "" | ||||
"This creates a new destination with name ``<name>`` and type ``<type>``." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1557 | ||||
#: howto/clinic.rst:1619 | ||||
msgid "There are five destination types:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1560 | ||||
#: howto/clinic.rst:1622 | ||||
msgid "Throws the text away." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1563 | ||||
#: howto/clinic.rst:1625 | ||||
msgid "" | ||||
"Writes the text to the current block. This is what Clinic originally did." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1567 | ||||
#: howto/clinic.rst:1629 | ||||
msgid "A simple text buffer, like the \"buffer\" builtin destination above." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1570 | ||||
#: howto/clinic.rst:1632 | ||||
msgid "" | ||||
"A text file. The file destination takes an extra argument, a template to " | ||||
"use for building the filename, like so:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1573 | ||||
#: howto/clinic.rst:1635 | ||||
msgid "destination <name> new <type> <file_template>" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1575 | ||||
#: howto/clinic.rst:1637 | ||||
msgid "" | ||||
"The template can use three strings internally that will be replaced by bits " | ||||
"of the filename:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1578 | ||||
#: howto/clinic.rst:1640 | ||||
msgid "{path}" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1579 | ||||
#: howto/clinic.rst:1641 | ||||
msgid "The full path to the file, including directory and full filename." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1580 | ||||
#: howto/clinic.rst:1642 | ||||
msgid "{dirname}" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1581 | ||||
#: howto/clinic.rst:1643 | ||||
msgid "The name of the directory the file is in." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1582 | ||||
#: howto/clinic.rst:1644 | ||||
msgid "{basename}" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1583 | ||||
#: howto/clinic.rst:1645 | ||||
msgid "Just the name of the file, not including the directory." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1585 | ||||
#: howto/clinic.rst:1647 | ||||
msgid "{basename_root}" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1585 | ||||
#: howto/clinic.rst:1647 | ||||
msgid "" | ||||
"Basename with the extension clipped off (everything up to but not including " | ||||
"the last '.')." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1589 | ||||
#: howto/clinic.rst:1651 | ||||
msgid "{basename_extension}" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1588 | ||||
#: howto/clinic.rst:1650 | ||||
msgid "" | ||||
"The last '.' and everything after it. If the basename does not contain a " | ||||
"period, this will be the empty string." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1591 | ||||
#: howto/clinic.rst:1653 | ||||
msgid "" | ||||
"If there are no periods in the filename, {basename} and {filename} are the " | ||||
"same, and {extension} is empty. \"{basename}{extension}\" is always exactly " | ||||
"the same as \"{filename}\".\"" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1596 | ||||
#: howto/clinic.rst:1658 | ||||
msgid "A two-pass buffer, like the \"two-pass\" builtin destination above." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1599 | ||||
#: howto/clinic.rst:1661 | ||||
msgid "The ``clear`` subcommand works like this:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1605 | ||||
#: howto/clinic.rst:1667 | ||||
msgid "" | ||||
"It removes all the accumulated text up to this point in the destination. (I " | ||||
"don't know what you'd need this for, but I thought maybe it'd be useful " | ||||
"while someone's experimenting.)" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1609 | ||||
#: howto/clinic.rst:1671 | ||||
msgid "The fourth new directive is ``set``:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1616 | ||||
#: howto/clinic.rst:1678 | ||||
msgid "" | ||||
"``set`` lets you set two internal variables in Clinic. ``line_prefix`` is a " | ||||
"string that will be prepended to every line of Clinic's output; " | ||||
| | @ -2783,35 +2842,35 @@ msgid "" | |||
"output." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1620 | ||||
#: howto/clinic.rst:1682 | ||||
msgid "Both of these support two format strings:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1623 | ||||
#: howto/clinic.rst:1685 | ||||
msgid "``{block comment start}``" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1623 | ||||
#: howto/clinic.rst:1685 | ||||
msgid "" | ||||
"Turns into the string ``/*``, the start-comment text sequence for C files." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1626 | ||||
#: howto/clinic.rst:1688 | ||||
msgid "``{block comment end}``" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1626 | ||||
#: howto/clinic.rst:1688 | ||||
msgid "" | ||||
"Turns into the string ``*/``, the end-comment text sequence for C files." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1628 | ||||
#: howto/clinic.rst:1690 | ||||
msgid "" | ||||
"The final new directive is one you shouldn't need to use directly, called " | ||||
"``preserve``:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1635 | ||||
#: howto/clinic.rst:1697 | ||||
msgid "" | ||||
"This tells Clinic that the current contents of the output should be kept, " | ||||
"unmodified. This is used internally by Clinic when dumping output into " | ||||
| | @ -2820,36 +2879,36 @@ msgid "" | |||
"gets overwritten." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1642 | ||||
#: howto/clinic.rst:1704 | ||||
msgid "The #ifdef trick" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1644 | ||||
#: howto/clinic.rst:1706 | ||||
msgid "" | ||||
"If you're converting a function that isn't available on all platforms, " | ||||
"there's a trick you can use to make life a little easier. The existing code " | ||||
"probably looks like this::" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1655 | ||||
#: howto/clinic.rst:1717 | ||||
msgid "" | ||||
"And then in the ``PyMethodDef`` structure at the bottom the existing code " | ||||
"will have:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1664 | ||||
#: howto/clinic.rst:1726 | ||||
msgid "" | ||||
"In this scenario, you should enclose the body of your impl function inside " | ||||
"the ``#ifdef``, like so::" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1678 | ||||
#: howto/clinic.rst:1740 | ||||
msgid "" | ||||
"Then, remove those three lines from the ``PyMethodDef`` structure, replacing " | ||||
"them with the macro Argument Clinic generated:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1685 | ||||
#: howto/clinic.rst:1747 | ||||
msgid "" | ||||
"(You can find the real name for this macro inside the generated code. Or you " | ||||
"can calculate it yourself: it's the name of your function as defined on the " | ||||
| | @ -2857,27 +2916,27 @@ msgid "" | |||
"uppercased, and ``\"_METHODDEF\"`` added to the end.)" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1690 | ||||
#: howto/clinic.rst:1752 | ||||
msgid "" | ||||
"Perhaps you're wondering: what if ``HAVE_FUNCTIONNAME`` isn't defined? The " | ||||
"``MODULE_FUNCTIONNAME_METHODDEF`` macro won't be defined either!" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1693 | ||||
#: howto/clinic.rst:1755 | ||||
msgid "" | ||||
"Here's where Argument Clinic gets very clever. It actually detects that the " | ||||
"Argument Clinic block might be deactivated by the ``#ifdef``. When that " | ||||
"happens, it generates a little extra code that looks like this::" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1701 | ||||
#: howto/clinic.rst:1763 | ||||
msgid "" | ||||
"That means the macro always works. If the function is defined, this turns " | ||||
"into the correct structure, including the trailing comma. If the function " | ||||
"is undefined, this turns into nothing." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1705 | ||||
#: howto/clinic.rst:1767 | ||||
msgid "" | ||||
"However, this causes one ticklish problem: where should Argument Clinic put " | ||||
"this extra code when using the \"block\" output preset? It can't go in the " | ||||
| | @ -2885,24 +2944,24 @@ msgid "" | |||
"the whole point!)" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1709 | ||||
#: howto/clinic.rst:1771 | ||||
msgid "" | ||||
"In this situation, Argument Clinic writes the extra code to the \"buffer\" " | ||||
"destination. This may mean that you get a complaint from Argument Clinic:" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1717 | ||||
#: howto/clinic.rst:1779 | ||||
msgid "" | ||||
"When this happens, just open your file, find the ``dump buffer`` block that " | ||||
"Argument Clinic added to your file (it'll be at the very bottom), then move " | ||||
"it above the ``PyMethodDef`` structure where that macro is used." | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1724 | ||||
#: howto/clinic.rst:1786 | ||||
msgid "Using Argument Clinic in Python files" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1726 | ||||
#: howto/clinic.rst:1788 | ||||
msgid "" | ||||
"It's actually possible to use Argument Clinic to preprocess Python files. " | ||||
"There's no point to using Argument Clinic blocks, of course, as the output " | ||||
| | @ -2910,7 +2969,7 @@ msgid "" | |||
"Clinic to run Python blocks lets you use Python as a Python preprocessor!" | ||||
msgstr "" | ||||
| ||||
#: howto/clinic.rst:1731 | ||||
#: howto/clinic.rst:1793 | ||||
msgid "" | ||||
"Since Python comments are different from C comments, Argument Clinic blocks " | ||||
"embedded in Python files look slightly different. They look like this:" | ||||
| | | |||
| | @ -5,7 +5,7 @@ msgid "" | |||
msgstr "" | ||||
"Project-Id-Version: Python 3\n" | ||||
"Report-Msgid-Bugs-To: \n" | ||||
"POT-Creation-Date: 2021-05-19 22:36+0200\n" | ||||
"POT-Creation-Date: 2021-09-23 16:16+0200\n" | ||||
"PO-Revision-Date: 2020-12-17 21:41+0100\n" | ||||
"Last-Translator: Mathieu Dupuy <deronnax@gmail.com>\n" | ||||
"Language-Team: FRENCH <traductions@lists.afpy.org>\n" | ||||
| | @ -92,8 +92,8 @@ msgstr "" | |||
| ||||
#: howto/descriptor.rst:45 | ||||
msgid "" | ||||
"The :class:`Ten` class is a descriptor that always returns the constant " | ||||
"``10`` from its :meth:`__get__` method:" | ||||
"The :class:`Ten` class is a descriptor whose :meth:`__get__` method always " | ||||
"returns the constant ``10``:" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:54 | ||||
| | @ -110,10 +110,10 @@ msgstr "" | |||
| ||||
#: howto/descriptor.rst:73 | ||||
msgid "" | ||||
"In the ``a.x`` attribute lookup, the dot operator finds the key ``x`` and " | ||||
"the value ``5`` in the class dictionary. In the ``a.y`` lookup, the dot " | ||||
"operator finds a descriptor instance, recognized by its ``__get__`` method, " | ||||
"and calls that method which returns ``10``." | ||||
"In the ``a.x`` attribute lookup, the dot operator finds ``'x': 5`` in the " | ||||
"class dictionary. In the ``a.y`` lookup, the dot operator finds a " | ||||
"descriptor instance, recognized by its ``__get__`` method. Calling that " | ||||
"method returns ``10``." | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:78 | ||||
| | @ -247,8 +247,8 @@ msgstr "" | |||
| ||||
#: howto/descriptor.rst:305 | ||||
msgid "" | ||||
"Descriptors get invoked by the dot \"operator\" during attribute lookup. If " | ||||
"a descriptor is accessed indirectly with ``vars(some_class)" | ||||
"Descriptors get invoked by the dot operator during attribute lookup. If a " | ||||
"descriptor is accessed indirectly with ``vars(some_class)" | ||||
"[descriptor_name]``, the descriptor instance is returned without invoking it." | ||||
msgstr "" | ||||
| ||||
| | @ -826,7 +826,7 @@ msgstr "" | |||
"Pour voir comment :func:`property` est implémenté dans le protocole du " | ||||
"descripteur, voici un un équivalent Python pur ::" | ||||
| ||||
#: howto/descriptor.rst:1063 | ||||
#: howto/descriptor.rst:1073 | ||||
msgid "" | ||||
"The :func:`property` builtin helps whenever a user interface has granted " | ||||
"attribute access and then subsequent changes require the intervention of a " | ||||
| | @ -836,7 +836,7 @@ msgstr "" | |||
"utilisateur a accordé l'accès à un attribut et que des modifications " | ||||
"ultérieures nécessitent l'intervention d'une méthode." | ||||
| ||||
#: howto/descriptor.rst:1067 | ||||
#: howto/descriptor.rst:1077 | ||||
#, fuzzy | ||||
msgid "" | ||||
"For instance, a spreadsheet class may grant access to a cell value through " | ||||
| | @ -853,18 +853,18 @@ msgstr "" | |||
"directement à l'attribut. La solution consiste à envelopper l'accès à " | ||||
"l'attribut de valeur dans un descripteur de données de propriété ::" | ||||
| ||||
#: howto/descriptor.rst:1084 | ||||
#: howto/descriptor.rst:1094 | ||||
msgid "" | ||||
"Either the built-in :func:`property` or our :func:`Property` equivalent " | ||||
"would work in this example." | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1089 | ||||
#: howto/descriptor.rst:1099 | ||||
#, fuzzy | ||||
msgid "Functions and methods" | ||||
msgstr "Fonctions et méthodes" | ||||
| ||||
#: howto/descriptor.rst:1091 | ||||
#: howto/descriptor.rst:1101 | ||||
msgid "" | ||||
"Python's object oriented features are built upon a function based " | ||||
"environment. Using non-data descriptors, the two are merged seamlessly." | ||||
| | @ -873,7 +873,7 @@ msgstr "" | |||
"environnement basé sur des fonctions. À l'aide de descripteurs *non-data*, " | ||||
"les deux sont fusionnés de façon transparente." | ||||
| ||||
#: howto/descriptor.rst:1094 | ||||
#: howto/descriptor.rst:1104 | ||||
#, fuzzy | ||||
msgid "" | ||||
"Functions stored in class dictionaries get turned into methods when invoked. " | ||||
| | @ -889,13 +889,13 @@ msgstr "" | |||
"convention Python, la référence de l'instance est appelée *self* mais peut " | ||||
"être appelée *this* ou tout autre nom de variable." | ||||
| ||||
#: howto/descriptor.rst:1099 | ||||
#: howto/descriptor.rst:1109 | ||||
msgid "" | ||||
"Methods can be created manually with :class:`types.MethodType` which is " | ||||
"roughly equivalent to:" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1116 | ||||
#: howto/descriptor.rst:1126 | ||||
#, fuzzy | ||||
msgid "" | ||||
"To support automatic creation of methods, functions include the :meth:" | ||||
| | @ -909,7 +909,7 @@ msgstr "" | |||
"*non-data* qui renvoient des méthodes liées lorsqu'elles sont appelées " | ||||
"depuis un objet. En Python pur, il fonctionne comme ceci ::" | ||||
| ||||
#: howto/descriptor.rst:1132 | ||||
#: howto/descriptor.rst:1142 | ||||
#, fuzzy | ||||
msgid "" | ||||
"Running the following class in the interpreter shows how the function " | ||||
| | @ -918,47 +918,47 @@ msgstr "" | |||
"L'exécution de l'interpréteur montre comment le descripteur de fonction se " | ||||
"comporte dans la pratique ::" | ||||
| ||||
#: howto/descriptor.rst:1141 | ||||
#: howto/descriptor.rst:1151 | ||||
msgid "" | ||||
"The function has a :term:`qualified name` attribute to support introspection:" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1148 | ||||
#: howto/descriptor.rst:1158 | ||||
msgid "" | ||||
"Accessing the function through the class dictionary does not invoke :meth:" | ||||
"`__get__`. Instead, it just returns the underlying function object::" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1154 | ||||
#: howto/descriptor.rst:1164 | ||||
msgid "" | ||||
"Dotted access from a class calls :meth:`__get__` which just returns the " | ||||
"underlying function unchanged::" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1160 | ||||
#: howto/descriptor.rst:1170 | ||||
msgid "" | ||||
"The interesting behavior occurs during dotted access from an instance. The " | ||||
"dotted lookup calls :meth:`__get__` which returns a bound method object::" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1167 | ||||
#: howto/descriptor.rst:1177 | ||||
msgid "" | ||||
"Internally, the bound method stores the underlying function and the bound " | ||||
"instance::" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1176 | ||||
#: howto/descriptor.rst:1186 | ||||
msgid "" | ||||
"If you have ever wondered where *self* comes from in regular methods or " | ||||
"where *cls* comes from in class methods, this is it!" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1181 | ||||
#: howto/descriptor.rst:1191 | ||||
#, fuzzy | ||||
msgid "Kinds of methods" | ||||
msgstr "Fonctions et méthodes" | ||||
| ||||
#: howto/descriptor.rst:1183 | ||||
#: howto/descriptor.rst:1193 | ||||
msgid "" | ||||
"Non-data descriptors provide a simple mechanism for variations on the usual " | ||||
"patterns of binding functions into methods." | ||||
| | @ -966,7 +966,7 @@ msgstr "" | |||
"Les descripteurs *non-data* fournissent un mécanisme simple pour les " | ||||
"variations des patrons habituels des fonctions de liaison dans les méthodes." | ||||
| ||||
#: howto/descriptor.rst:1186 | ||||
#: howto/descriptor.rst:1196 | ||||
#, fuzzy | ||||
msgid "" | ||||
"To recap, functions have a :meth:`__get__` method so that they can be " | ||||
| | @ -979,60 +979,60 @@ msgstr "" | |||
"descripteur *non-data* transforme un appel ``obj.f(*args)``en ``f(obj, " | ||||
"*args)``. Appeler ``klass.f(*args)`` devient ``f(*args)``." | ||||
| ||||
#: howto/descriptor.rst:1191 | ||||
#: howto/descriptor.rst:1201 | ||||
msgid "This chart summarizes the binding and its two most useful variants:" | ||||
msgstr "" | ||||
"Ce tableau résume le lien (*binding*) et ses deux variantes les plus " | ||||
"utiles ::" | ||||
| ||||
#: howto/descriptor.rst:1194 | ||||
#: howto/descriptor.rst:1204 | ||||
msgid "Transformation" | ||||
msgstr "Transformation" | ||||
| ||||
#: howto/descriptor.rst:1194 | ||||
#: howto/descriptor.rst:1204 | ||||
#, fuzzy | ||||
msgid "Called from an object" | ||||
msgstr "Appelé depuis un Objet" | ||||
| ||||
#: howto/descriptor.rst:1194 | ||||
#: howto/descriptor.rst:1204 | ||||
#, fuzzy | ||||
msgid "Called from a class" | ||||
msgstr "Appelé depuis un Classe" | ||||
| ||||
#: howto/descriptor.rst:1197 | ||||
#: howto/descriptor.rst:1207 | ||||
msgid "function" | ||||
msgstr "fonction" | ||||
| ||||
#: howto/descriptor.rst:1197 | ||||
#: howto/descriptor.rst:1207 | ||||
msgid "f(obj, \\*args)" | ||||
msgstr "f(obj, \\*args)" | ||||
| ||||
#: howto/descriptor.rst:1199 | ||||
#: howto/descriptor.rst:1209 | ||||
msgid "f(\\*args)" | ||||
msgstr "f(\\*args)" | ||||
| ||||
#: howto/descriptor.rst:1199 | ||||
#: howto/descriptor.rst:1209 | ||||
msgid "staticmethod" | ||||
msgstr "méthode statique" | ||||
| ||||
#: howto/descriptor.rst:1201 | ||||
#: howto/descriptor.rst:1211 | ||||
msgid "classmethod" | ||||
msgstr "méthode de classe" | ||||
| ||||
#: howto/descriptor.rst:1201 | ||||
#: howto/descriptor.rst:1211 | ||||
msgid "f(type(obj), \\*args)" | ||||
msgstr "f(type(obj), \\*args)" | ||||
| ||||
#: howto/descriptor.rst:1201 | ||||
#: howto/descriptor.rst:1211 | ||||
msgid "f(cls, \\*args)" | ||||
msgstr "f(cls, \\*args)" | ||||
| ||||
#: howto/descriptor.rst:1206 | ||||
#: howto/descriptor.rst:1216 | ||||
#, fuzzy | ||||
msgid "Static methods" | ||||
msgstr "méthode statique" | ||||
| ||||
#: howto/descriptor.rst:1208 | ||||
#: howto/descriptor.rst:1218 | ||||
msgid "" | ||||
"Static methods return the underlying function without changes. Calling " | ||||
"either ``c.f`` or ``C.f`` is the equivalent of a direct lookup into ``object." | ||||
| | @ -1046,7 +1046,7 @@ msgstr "" | |||
"__getattribute__(C, \"f\")``. Par conséquent, la fonction devient accessible " | ||||
"de manière identique à partir d'un objet ou d'une classe." | ||||
| ||||
#: howto/descriptor.rst:1214 | ||||
#: howto/descriptor.rst:1224 | ||||
msgid "" | ||||
"Good candidates for static methods are methods that do not reference the " | ||||
"``self`` variable." | ||||
| | @ -1054,7 +1054,7 @@ msgstr "" | |||
"Les bonnes candidates pour être méthode statique sont des méthodes qui ne " | ||||
"font pas référence à la variable ``self``." | ||||
| ||||
#: howto/descriptor.rst:1217 | ||||
#: howto/descriptor.rst:1227 | ||||
msgid "" | ||||
"For instance, a statistics package may include a container class for " | ||||
"experimental data. The class provides normal methods for computing the " | ||||
| | @ -1076,7 +1076,7 @@ msgstr "" | |||
"appelée à partir d'un objet ou de la classe : ``s.erf(1.5) --> .9332``` ou " | ||||
"``Sample.erf(1.5) --> .9332``." | ||||
| ||||
#: howto/descriptor.rst:1226 | ||||
#: howto/descriptor.rst:1236 | ||||
#, fuzzy | ||||
msgid "" | ||||
"Since static methods return the underlying function with no changes, the " | ||||
| | @ -1085,7 +1085,7 @@ msgstr "" | |||
"Depuis que les méthodes statiques renvoient la fonction sous-jacente sans " | ||||
"changement, les exemples d’appels ne sont pas excitants ::" | ||||
| ||||
#: howto/descriptor.rst:1243 | ||||
#: howto/descriptor.rst:1253 | ||||
#, fuzzy | ||||
msgid "" | ||||
"Using the non-data descriptor protocol, a pure Python version of :func:" | ||||
| | @ -1094,12 +1094,12 @@ msgstr "" | |||
"En utilisant le protocole de descripteur *non-data*, une version Python pure " | ||||
"de :func:`staticmethod` ressemblerait à ceci ::" | ||||
| ||||
#: howto/descriptor.rst:1275 | ||||
#: howto/descriptor.rst:1285 | ||||
#, fuzzy | ||||
msgid "Class methods" | ||||
msgstr "méthode de classe" | ||||
| ||||
#: howto/descriptor.rst:1277 | ||||
#: howto/descriptor.rst:1287 | ||||
#, fuzzy | ||||
msgid "" | ||||
"Unlike static methods, class methods prepend the class reference to the " | ||||
| | @ -1110,7 +1110,7 @@ msgstr "" | |||
"référence de classe dans la liste d'arguments avant d'appeler la fonction. " | ||||
"Ce format est le même que l'appelant soit un objet ou une classe ::" | ||||
| ||||
#: howto/descriptor.rst:1295 | ||||
#: howto/descriptor.rst:1305 | ||||
#, fuzzy | ||||
msgid "" | ||||
"This behavior is useful whenever the method only needs to have a class " | ||||
| | @ -1126,14 +1126,14 @@ msgstr "" | |||
"nouveau dictionnaire à partir d'une liste de clés. L'équivalent Python pur " | ||||
"est ::" | ||||
| ||||
#: howto/descriptor.rst:1312 | ||||
#: howto/descriptor.rst:1322 | ||||
#, fuzzy | ||||
msgid "Now a new dictionary of unique keys can be constructed like this:" | ||||
msgstr "" | ||||
"Maintenant un nouveau dictionnaire de clés uniques peut être construit comme " | ||||
"ceci ::" | ||||
| ||||
#: howto/descriptor.rst:1322 | ||||
#: howto/descriptor.rst:1332 | ||||
#, fuzzy | ||||
msgid "" | ||||
"Using the non-data descriptor protocol, a pure Python version of :func:" | ||||
| | @ -1142,7 +1142,7 @@ msgstr "" | |||
"En utilisant le protocole de descripteur *non-data*, une version Python pure " | ||||
"de :func:`classmethod` ressemblerait à ceci ::" | ||||
| ||||
#: howto/descriptor.rst:1371 | ||||
#: howto/descriptor.rst:1381 | ||||
msgid "" | ||||
"The code path for ``hasattr(type(self.f), '__get__')`` was added in Python " | ||||
"3.9 and makes it possible for :func:`classmethod` to support chained " | ||||
| | @ -1150,30 +1150,30 @@ msgid "" | |||
"together:" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1391 | ||||
#: howto/descriptor.rst:1401 | ||||
msgid "Member objects and __slots__" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1393 | ||||
#: howto/descriptor.rst:1403 | ||||
msgid "" | ||||
"When a class defines ``__slots__``, it replaces instance dictionaries with a " | ||||
"fixed-length array of slot values. From a user point of view that has " | ||||
"several effects:" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1397 | ||||
#: howto/descriptor.rst:1407 | ||||
msgid "" | ||||
"1. Provides immediate detection of bugs due to misspelled attribute " | ||||
"assignments. Only attribute names specified in ``__slots__`` are allowed:" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1413 | ||||
#: howto/descriptor.rst:1423 | ||||
msgid "" | ||||
"2. Helps create immutable objects where descriptors manage access to private " | ||||
"attributes stored in ``__slots__``:" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1448 | ||||
#: howto/descriptor.rst:1458 | ||||
msgid "" | ||||
"3. Saves memory. On a 64-bit Linux build, an instance with two attributes " | ||||
"takes 48 bytes with ``__slots__`` and 152 bytes without. This `flyweight " | ||||
| | @ -1181,13 +1181,19 @@ msgid "" | |||
"only matters when a large number of instances are going to be created." | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1453 | ||||
#: howto/descriptor.rst:1463 | ||||
msgid "" | ||||
"4. Blocks tools like :func:`functools.cached_property` which require an " | ||||
"4. Improves speed. Reading instance variables is 35% faster with " | ||||
"``__slots__`` (as measured with Python 3.10 on an Apple M1 processor)." | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1466 | ||||
msgid "" | ||||
"5. Blocks tools like :func:`functools.cached_property` which require an " | ||||
"instance dictionary to function correctly:" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1475 | ||||
#: howto/descriptor.rst:1488 | ||||
msgid "" | ||||
"It is not possible to create an exact drop-in pure Python version of " | ||||
"``__slots__`` because it requires direct access to C structures and control " | ||||
| | @ -1197,37 +1203,37 @@ msgid "" | |||
"managed by member descriptors:" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1518 | ||||
#: howto/descriptor.rst:1531 | ||||
msgid "" | ||||
"The :meth:`type.__new__` method takes care of adding member objects to class " | ||||
"variables:" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1534 | ||||
#: howto/descriptor.rst:1547 | ||||
msgid "" | ||||
"The :meth:`object.__new__` method takes care of creating instances that have " | ||||
"slots instead of an instance dictionary. Here is a rough simulation in pure " | ||||
"Python:" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1569 | ||||
#: howto/descriptor.rst:1582 | ||||
msgid "" | ||||
"To use the simulation in a real class, just inherit from :class:`Object` and " | ||||
"set the :term:`metaclass` to :class:`Type`:" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1583 | ||||
#: howto/descriptor.rst:1596 | ||||
msgid "" | ||||
"At this point, the metaclass has loaded member objects for *x* and *y*::" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1604 | ||||
#: howto/descriptor.rst:1617 | ||||
msgid "" | ||||
"When instances are created, they have a ``slot_values`` list where the " | ||||
"attributes are stored:" | ||||
msgstr "" | ||||
| ||||
#: howto/descriptor.rst:1616 | ||||
#: howto/descriptor.rst:1629 | ||||
msgid "Misspelled or unassigned attributes will raise an exception:" | ||||
msgstr "" | ||||
| ||||
| | | |||
| | @ -5,7 +5,7 @@ msgid "" | |||
msgstr "" | ||||
"Project-Id-Version: Python 3\n" | ||||
"Report-Msgid-Bugs-To: \n" | ||||
"POT-Creation-Date: 2020-10-01 16:00+0200\n" | ||||
"POT-Creation-Date: 2021-09-23 16:16+0200\n" | ||||
"PO-Revision-Date: 2021-01-28 15:41+0100\n" | ||||
"Last-Translator: Jules Lasne <jules.lasne@gmail.com>\n" | ||||
"Language-Team: FRENCH <traductions@lists.afpy.org>\n" | ||||
| | @ -100,10 +100,13 @@ msgid "or::" | |||
msgstr "ou ::" | ||||
| ||||
#: howto/instrumentation.rst:49 | ||||
msgid "CPython must then be configured ``--with-dtrace``:" | ||||
#, fuzzy | ||||
msgid "" | ||||
"CPython must then be :option:`configured with the --with-dtrace option <--" | ||||
"with-dtrace>`:" | ||||
msgstr "CPython doit être configuré avec l'option ``--with-dtrace`` ::" | ||||
| ||||
#: howto/instrumentation.rst:55 | ||||
#: howto/instrumentation.rst:56 | ||||
msgid "" | ||||
"On macOS, you can list available DTrace probes by running a Python process " | ||||
"in the background and listing all probes made available by the Python " | ||||
| | @ -113,7 +116,7 @@ msgstr "" | |||
"un processus Python en arrière-plan et en listant toutes les sondes mises à " | ||||
"disposition par le fournisseur Python ::" | ||||
| ||||
#: howto/instrumentation.rst:72 | ||||
#: howto/instrumentation.rst:73 | ||||
msgid "" | ||||
"On Linux, you can verify if the SystemTap static markers are present in the " | ||||
"built binary by seeing if it contains a \".note.stapsdt\" section." | ||||
| | @ -122,22 +125,24 @@ msgstr "" | |||
"présents dans le binaire compilé, il suffit de regarder s'il contient une " | ||||
"section ``.note.stapsdt``." | ||||
| ||||
#: howto/instrumentation.rst:80 | ||||
#: howto/instrumentation.rst:81 | ||||
#, fuzzy | ||||
msgid "" | ||||
"If you've built Python as a shared library (with --enable-shared), you need " | ||||
"to look instead within the shared library. For example::" | ||||
"If you've built Python as a shared library (with the :option:`--enable-" | ||||
"shared` configure option), you need to look instead within the shared " | ||||
"library. For example::" | ||||
msgstr "" | ||||
"Si vous avez compilé Python en tant que bibliothèque partagée (avec ``--" | ||||
"enable-shared``), vous devez plutôt regarder dans la bibliothèque partagée. " | ||||
"Par exemple ::" | ||||
| ||||
#: howto/instrumentation.rst:86 | ||||
#: howto/instrumentation.rst:88 | ||||
msgid "Sufficiently modern readelf can print the metadata::" | ||||
msgstr "" | ||||
"Une version suffisamment moderne de *readelf* peut afficher les " | ||||
"métadonnées ::" | ||||
| ||||
#: howto/instrumentation.rst:123 | ||||
#: howto/instrumentation.rst:125 | ||||
msgid "" | ||||
"The above metadata contains information for SystemTap describing how it can " | ||||
"patch strategically-placed machine code instructions to enable the tracing " | ||||
| | @ -148,11 +153,11 @@ msgstr "" | |||
"stratégiquement placées pour activer les crochets de traçage utilisés par un " | ||||
"script *SystemTap*." | ||||
| ||||
#: howto/instrumentation.rst:129 | ||||
#: howto/instrumentation.rst:131 | ||||
msgid "Static DTrace probes" | ||||
msgstr "Sondes DTrace statiques" | ||||
| ||||
#: howto/instrumentation.rst:131 | ||||
#: howto/instrumentation.rst:133 | ||||
msgid "" | ||||
"The following example DTrace script can be used to show the call/return " | ||||
"hierarchy of a Python script, only tracing within the invocation of a " | ||||
| | @ -164,19 +169,19 @@ msgstr "" | |||
"En d'autres termes, les appels de fonctions lors de la phase d'import ne " | ||||
"seront pas répertoriées ::" | ||||
| ||||
#: howto/instrumentation.rst:228 | ||||
#: howto/instrumentation.rst:230 | ||||
msgid "It can be invoked like this::" | ||||
msgstr "Il peut être utilisé de cette manière ::" | ||||
| ||||
#: howto/instrumentation.rst:234 | ||||
#: howto/instrumentation.rst:236 | ||||
msgid "The output looks like this:" | ||||
msgstr "La sortie ressemble à ceci ::" | ||||
| ||||
#: howto/instrumentation.rst:199 | ||||
#: howto/instrumentation.rst:201 | ||||
msgid "Static SystemTap markers" | ||||
msgstr "Marqueurs statiques *SystemTap*" | ||||
| ||||
#: howto/instrumentation.rst:201 | ||||
#: howto/instrumentation.rst:203 | ||||
msgid "" | ||||
"The low-level way to use the SystemTap integration is to use the static " | ||||
"markers directly. This requires you to explicitly state the binary file " | ||||
| | @ -186,7 +191,7 @@ msgstr "" | |||
"directement les marqueurs statiques. Pour cela vous devez pointer " | ||||
"explicitement le fichier binaire qui les contient." | ||||
| ||||
#: howto/instrumentation.rst:205 | ||||
#: howto/instrumentation.rst:207 | ||||
msgid "" | ||||
"For example, this SystemTap script can be used to show the call/return " | ||||
"hierarchy of a Python script:" | ||||
| | @ -194,52 +199,54 @@ msgstr "" | |||
"Par exemple, ce script *SystemTap* peut être utilisé pour afficher la " | ||||
"hiérarchie d'appel/retour d'un script Python ::" | ||||
| ||||
#: howto/instrumentation.rst:245 | ||||
#: howto/instrumentation.rst:247 | ||||
msgid "where the columns are:" | ||||
msgstr "où les colonnes sont ::" | ||||
| ||||
#: howto/instrumentation.rst:247 | ||||
#: howto/instrumentation.rst:249 | ||||
msgid "time in microseconds since start of script" | ||||
msgstr "temps en microsecondes depuis le début du script" | ||||
| ||||
#: howto/instrumentation.rst:249 | ||||
#: howto/instrumentation.rst:251 | ||||
msgid "name of executable" | ||||
msgstr "nom de l'exécutable" | ||||
| ||||
#: howto/instrumentation.rst:251 | ||||
#: howto/instrumentation.rst:253 | ||||
msgid "PID of process" | ||||
msgstr "PID du processus" | ||||
| ||||
#: howto/instrumentation.rst:253 | ||||
#: howto/instrumentation.rst:255 | ||||
msgid "" | ||||
"and the remainder indicates the call/return hierarchy as the script executes." | ||||
msgstr "" | ||||
"et le reste indique la hiérarchie d'appel/retour lorsque le script s'exécute." | ||||
| ||||
#: howto/instrumentation.rst:255 | ||||
#: howto/instrumentation.rst:257 | ||||
#, fuzzy | ||||
msgid "" | ||||
"For a `--enable-shared` build of CPython, the markers are contained within " | ||||
"the libpython shared library, and the probe's dotted path needs to reflect " | ||||
"this. For example, this line from the above example:" | ||||
"For a :option:`--enable-shared` build of CPython, the markers are contained " | ||||
"within the libpython shared library, and the probe's dotted path needs to " | ||||
"reflect this. For example, this line from the above example:" | ||||
msgstr "" | ||||
"Pour une compilation `--enable-shared` de CPython, les marqueurs sont " | ||||
"contenus dans la bibliothèque partagée *libpython*, et le chemin du module " | ||||
"de la sonde doit le refléter. Par exemple, la ligne de l'exemple ci-dessus :" | ||||
| ||||
#: howto/instrumentation.rst:263 | ||||
#: howto/instrumentation.rst:265 | ||||
msgid "should instead read:" | ||||
msgstr "doit plutôt se lire comme ::" | ||||
| ||||
#: howto/instrumentation.rst:269 | ||||
msgid "(assuming a debug build of CPython 3.6)" | ||||
#: howto/instrumentation.rst:271 | ||||
#, fuzzy | ||||
msgid "(assuming a :ref:`debug build <debug-build>` of CPython 3.6)" | ||||
msgstr "" | ||||
"(en supposant une version compilée avec le débogage activé de CPython 3.6)" | ||||
| ||||
#: howto/instrumentation.rst:273 | ||||
#: howto/instrumentation.rst:275 | ||||
msgid "Available static markers" | ||||
msgstr "Marqueurs statiques disponibles" | ||||
| ||||
#: howto/instrumentation.rst:277 | ||||
#: howto/instrumentation.rst:279 | ||||
msgid "" | ||||
"This marker indicates that execution of a Python function has begun. It is " | ||||
"only triggered for pure-Python (bytecode) functions." | ||||
| | @ -247,7 +254,7 @@ msgstr "" | |||
"Ce marqueur indique que l'exécution d'une fonction Python a commencé. Il " | ||||
"n'est déclenché que pour les fonctions en Python pur (code intermédiaire)." | ||||
| ||||
#: howto/instrumentation.rst:280 | ||||
#: howto/instrumentation.rst:282 | ||||
msgid "" | ||||
"The filename, function name, and line number are provided back to the " | ||||
"tracing script as positional arguments, which must be accessed using ``" | ||||
| | @ -257,7 +264,7 @@ msgstr "" | |||
"au script de traçage sous forme d'arguments positionnels, auxquels il faut " | ||||
"accéder en utilisant ``$arg1``, ``$arg2``, ``$arg3`` :" | ||||
| ||||
#: howto/instrumentation.rst:284 | ||||
#: howto/instrumentation.rst:286 | ||||
msgid "" | ||||
"``$arg1`` : ``(const char *)`` filename, accessible using " | ||||
"``user_string($arg1)``" | ||||
| | @ -265,7 +272,7 @@ msgstr "" | |||
"``$arg1`` : ``(const char *)`` nom de fichier, accessible via " | ||||
"``user_string($arg1)``" | ||||
| ||||
#: howto/instrumentation.rst:286 | ||||
#: howto/instrumentation.rst:288 | ||||
msgid "" | ||||
"``$arg2`` : ``(const char *)`` function name, accessible using " | ||||
"``user_string($arg2)``" | ||||
| | @ -273,11 +280,11 @@ msgstr "" | |||
"``$arg2`` : ``(const char *)`` nom de la fonction, accessible via " | ||||
"``user_string($arg2)``" | ||||
| ||||
#: howto/instrumentation.rst:289 | ||||
#: howto/instrumentation.rst:291 | ||||
msgid "``$arg3`` : ``int`` line number" | ||||
msgstr "``$arg3`` : numéro de ligne ``int``" | ||||
| ||||
#: howto/instrumentation.rst:293 | ||||
#: howto/instrumentation.rst:295 | ||||
msgid "" | ||||
"This marker is the converse of :c:func:`function__entry`, and indicates that " | ||||
"execution of a Python function has ended (either via ``return``, or via an " | ||||
| | @ -288,11 +295,11 @@ msgstr "" | |||
"via une exception). Il n'est déclenché que pour les fonctions en Python pur " | ||||
"(code intermédiaire)." | ||||
| ||||
#: howto/instrumentation.rst:297 | ||||
#: howto/instrumentation.rst:299 | ||||
msgid "The arguments are the same as for :c:func:`function__entry`" | ||||
msgstr "Les arguments sont les mêmes que pour :c:func:`function__entry`" | ||||
| ||||
#: howto/instrumentation.rst:301 | ||||
#: howto/instrumentation.rst:303 | ||||
msgid "" | ||||
"This marker indicates a Python line is about to be executed. It is the " | ||||
"equivalent of line-by-line tracing with a Python profiler. It is not " | ||||
| | @ -302,11 +309,11 @@ msgstr "" | |||
"C'est l'équivalent du traçage ligne par ligne avec un profileur Python. Il " | ||||
"n'est pas déclenché dans les fonctions C." | ||||
| ||||
#: howto/instrumentation.rst:305 | ||||
#: howto/instrumentation.rst:307 | ||||
msgid "The arguments are the same as for :c:func:`function__entry`." | ||||
msgstr "Les arguments sont les mêmes que pour :c:func:`function__entry`." | ||||
| ||||
#: howto/instrumentation.rst:309 | ||||
#: howto/instrumentation.rst:311 | ||||
msgid "" | ||||
"Fires when the Python interpreter starts a garbage collection cycle. " | ||||
"``arg0`` is the generation to scan, like :func:`gc.collect()`." | ||||
| | @ -315,7 +322,7 @@ msgstr "" | |||
"ramasse-miettes. ``arg0`` est la génération à scanner, comme :func:`gc." | ||||
"collect()`." | ||||
| ||||
#: howto/instrumentation.rst:314 | ||||
#: howto/instrumentation.rst:316 | ||||
msgid "" | ||||
"Fires when the Python interpreter finishes a garbage collection cycle. " | ||||
"``arg0`` is the number of collected objects." | ||||
| | @ -323,7 +330,7 @@ msgstr "" | |||
"Fonction appelée lorsque l'interpréteur Python termine un cycle de collecte " | ||||
"du ramasse-miettes. ``Arg0`` est le nombre d'objets collectés." | ||||
| ||||
#: howto/instrumentation.rst:319 | ||||
#: howto/instrumentation.rst:321 | ||||
msgid "" | ||||
"Fires before :mod:`importlib` attempts to find and load the module. ``arg0`` " | ||||
"is the module name." | ||||
| | @ -331,7 +338,7 @@ msgstr "" | |||
"Fonction appelée avant que :mod:`importlib` essaye de trouver et de charger " | ||||
"le module. ``arg0`` est le nom du module." | ||||
| ||||
#: howto/instrumentation.rst:326 | ||||
#: howto/instrumentation.rst:328 | ||||
msgid "" | ||||
"Fires after :mod:`importlib`'s find_and_load function is called. ``arg0`` is " | ||||
"the module name, ``arg1`` indicates if module was successfully loaded." | ||||
| | @ -340,7 +347,7 @@ msgstr "" | |||
"`importlib` soit appelée. ``arg0`` est le nom du module, ``arg1`` indique si " | ||||
"le module a été chargé avec succès." | ||||
| ||||
#: howto/instrumentation.rst:335 | ||||
#: howto/instrumentation.rst:337 | ||||
msgid "" | ||||
"Fires when :func:`sys.audit` or :c:func:`PySys_Audit` is called. ``arg0`` is " | ||||
"the event name as C string, ``arg1`` is a :c:type:`PyObject` pointer to a " | ||||
| | @ -351,11 +358,11 @@ msgstr "" | |||
"chaîne de caractère C. ``arg1`` est un pointeur sur un *n*-uplet d'objet de " | ||||
"type :c:type:`PyObject`." | ||||
| ||||
#: howto/instrumentation.rst:343 | ||||
#: howto/instrumentation.rst:345 | ||||
msgid "SystemTap Tapsets" | ||||
msgstr "*Tapsets* de *SystemTap*" | ||||
| ||||
#: howto/instrumentation.rst:345 | ||||
#: howto/instrumentation.rst:347 | ||||
msgid "" | ||||
"The higher-level way to use the SystemTap integration is to use a \"tapset" | ||||
"\": SystemTap's equivalent of a library, which hides some of the lower-level " | ||||
| | @ -365,13 +372,13 @@ msgstr "" | |||
"un *« tapset »*. L'équivalent pour *SystemTap* d'une bibliothèque, qui " | ||||
"permet de masquer les détails de niveau inférieur des marqueurs statiques." | ||||
| ||||
#: howto/instrumentation.rst:349 | ||||
#: howto/instrumentation.rst:351 | ||||
msgid "Here is a tapset file, based on a non-shared build of CPython:" | ||||
msgstr "" | ||||
"Voici un fichier *tapset*, basé sur une version non partagée compilée de " | ||||
"CPython ::" | ||||
| ||||
#: howto/instrumentation.rst:372 | ||||
#: howto/instrumentation.rst:374 | ||||
msgid "" | ||||
"If this file is installed in SystemTap's tapset directory (e.g. ``/usr/share/" | ||||
"systemtap/tapset``), then these additional probepoints become available:" | ||||
| | @ -380,7 +387,7 @@ msgstr "" | |||
"exemple ``/usr/share/systemtap/tapset``), alors ces sondes supplémentaires " | ||||
"deviennent disponibles ::" | ||||
| ||||
#: howto/instrumentation.rst:378 | ||||
#: howto/instrumentation.rst:380 | ||||
msgid "" | ||||
"This probe point indicates that execution of a Python function has begun. It " | ||||
"is only triggered for pure-Python (bytecode) functions." | ||||
| | @ -388,7 +395,7 @@ msgstr "" | |||
"Cette sonde indique que l'exécution d'une fonction Python a commencé. Elle " | ||||
"n'est déclenchée que pour les fonctions en Python pur (code intermédiaire)." | ||||
| ||||
#: howto/instrumentation.rst:383 | ||||
#: howto/instrumentation.rst:385 | ||||
msgid "" | ||||
"This probe point is the converse of ``python.function.return``, and " | ||||
"indicates that execution of a Python function has ended (either via " | ||||
| | @ -400,11 +407,11 @@ msgstr "" | |||
"via une exception). Elle est uniquement déclenchée pour les fonctions en " | ||||
"Python pur (code intermédiaire ou *bytecode*)." | ||||
| ||||
#: howto/instrumentation.rst:390 | ||||
#: howto/instrumentation.rst:392 | ||||
msgid "Examples" | ||||
msgstr "Exemples" | ||||
| ||||
#: howto/instrumentation.rst:391 | ||||
#: howto/instrumentation.rst:393 | ||||
msgid "" | ||||
"This SystemTap script uses the tapset above to more cleanly implement the " | ||||
"example given above of tracing the Python function-call hierarchy, without " | ||||
| | @ -415,7 +422,7 @@ msgstr "" | |||
"fonctions Python, sans avoir besoin de nommer directement les marqueurs " | ||||
"statiques ::" | ||||
| ||||
#: howto/instrumentation.rst:410 | ||||
#: howto/instrumentation.rst:412 | ||||
msgid "" | ||||
"The following script uses the tapset above to provide a top-like view of all " | ||||
"running CPython code, showing the top 20 most frequently-entered bytecode " | ||||
| | | |||
| | @ -5,7 +5,7 @@ msgid "" | |||
msgstr "" | ||||
"Project-Id-Version: Python 3\n" | ||||
"Report-Msgid-Bugs-To: \n" | ||||
"POT-Creation-Date: 2020-08-24 09:01+0200\n" | ||||
"POT-Creation-Date: 2021-09-23 16:16+0200\n" | ||||
"PO-Revision-Date: 2019-01-11 23:02+0100\n" | ||||
"Last-Translator: BAILLY Geoffroy <dev@zest-labs.fr>\n" | ||||
"Language-Team: FRENCH <traductions@lists.afpy.org>\n" | ||||
| | @ -69,13 +69,15 @@ msgid "A Note on IP Versions" | |||
msgstr "Note sur les versions d'IP" | ||||
| ||||
#: howto/ipaddress.rst:34 | ||||
#, fuzzy | ||||
msgid "" | ||||
"For readers that aren't particularly familiar with IP addressing, it's " | ||||
"important to know that the Internet Protocol is currently in the process of " | ||||
"moving from version 4 of the protocol to version 6. This transition is " | ||||
"occurring largely because version 4 of the protocol doesn't provide enough " | ||||
"addresses to handle the needs of the whole world, especially given the " | ||||
"increasing number of devices with direct connections to the internet." | ||||
"important to know that the Internet Protocol (IP) is currently in the " | ||||
"process of moving from version 4 of the protocol to version 6. This " | ||||
"transition is occurring largely because version 4 of the protocol doesn't " | ||||
"provide enough addresses to handle the needs of the whole world, especially " | ||||
"given the increasing number of devices with direct connections to the " | ||||
"internet." | ||||
msgstr "" | ||||
"Pour les lecteurs qui ne sont pas particulièrement familiers avec " | ||||
"l'adressage IP il est important de savoir que le protocole IP est " | ||||
| | | |||
| | @ -5,7 +5,7 @@ msgid "" | |||
msgstr "" | ||||
"Project-Id-Version: Python 3\n" | ||||
"Report-Msgid-Bugs-To: \n" | ||||
"POT-Creation-Date: 2020-10-01 16:00+0200\n" | ||||
"POT-Creation-Date: 2021-09-23 16:16+0200\n" | ||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" | ||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" | ||||
"Language-Team: FRENCH <traductions@lists.afpy.org>\n" | ||||
| | @ -166,7 +166,7 @@ msgstr "" | |||
#: howto/logging-cookbook.rst:334 | ||||
msgid "" | ||||
"Sometimes you have to get your logging handlers to do their work without " | ||||
"blocking the thread you're logging from. This is common in Web applications, " | ||||
"blocking the thread you're logging from. This is common in web applications, " | ||||
"though of course it also occurs in other scenarios." | ||||
msgstr "" | ||||
| ||||
| | @ -1521,3 +1521,118 @@ msgid "" | |||
"Qt. Please refer to the comments in the code snippet for more detailed " | ||||
"information." | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:2987 | ||||
msgid "Patterns to avoid" | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:2989 | ||||
msgid "" | ||||
"Although the preceding sections have described ways of doing things you " | ||||
"might need to do or deal with, it is worth mentioning some usage patterns " | ||||
"which are *unhelpful*, and which should therefore be avoided in most cases. " | ||||
"The following sections are in no particular order." | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:2996 | ||||
msgid "Opening the same log file multiple times" | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:2998 | ||||
msgid "" | ||||
"On Windows, you will generally not be able to open the same file multiple " | ||||
"times as this will lead to a \"file is in use by another process\" error. " | ||||
"However, on POSIX platforms you'll not get any errors if you open the same " | ||||
"file multiple times. This could be done accidentally, for example by:" | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:3003 | ||||
msgid "" | ||||
"Adding a file handler more than once which references the same file (e.g. by " | ||||
"a copy/paste/forget-to-change error)." | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:3006 | ||||
msgid "" | ||||
"Opening two files that look different, as they have different names, but are " | ||||
"the same because one is a symbolic link to the other." | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:3009 | ||||
msgid "" | ||||
"Forking a process, following which both parent and child have a reference to " | ||||
"the same file. This might be through use of the :mod:`multiprocessing` " | ||||
"module, for example." | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:3013 | ||||
msgid "" | ||||
"Opening a file multiple times might *appear* to work most of the time, but " | ||||
"can lead to a number of problems in practice:" | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:3016 | ||||
msgid "" | ||||
"Logging output can be garbled because multiple threads or processes try to " | ||||
"write to the same file. Although logging guards against concurrent use of " | ||||
"the same handler instance by multiple threads, there is no such protection " | ||||
"if concurrent writes are attempted by two different threads using two " | ||||
"different handler instances which happen to point to the same file." | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:3022 | ||||
msgid "" | ||||
"An attempt to delete a file (e.g. during file rotation) silently fails, " | ||||
"because there is another reference pointing to it. This can lead to " | ||||
"confusion and wasted debugging time - log entries end up in unexpected " | ||||
"places, or are lost altogether." | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:3027 | ||||
msgid "" | ||||
"Use the techniques outlined in :ref:`multiple-processes` to circumvent such " | ||||
"issues." | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:3031 | ||||
msgid "Using loggers as attributes in a class or passing them as parameters" | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:3033 | ||||
msgid "" | ||||
"While there might be unusual cases where you'll need to do this, in general " | ||||
"there is no point because loggers are singletons. Code can always access a " | ||||
"given logger instance by name using ``logging.getLogger(name)``, so passing " | ||||
"instances around and holding them as instance attributes is pointless. Note " | ||||
"that in other languages such as Java and C#, loggers are often static class " | ||||
"attributes. However, this pattern doesn't make sense in Python, where the " | ||||
"module (and not the class) is the unit of software decomposition." | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:3043 | ||||
msgid "" | ||||
"Adding handlers other than :class:`NullHandler` to a logger in a library" | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:3045 | ||||
msgid "" | ||||
"Configuring logging by adding handlers, formatters and filters is the " | ||||
"responsibility of the application developer, not the library developer. If " | ||||
"you are maintaining a library, ensure that you don't add handlers to any of " | ||||
"your loggers other than a :class:`~logging.NullHandler` instance." | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:3052 | ||||
msgid "Creating a lot of loggers" | ||||
msgstr "" | ||||
| ||||
#: howto/logging-cookbook.rst:3054 | ||||
msgid "" | ||||
"Loggers are singletons that are never freed during a script execution, and " | ||||
"so creating lots of loggers will use up memory which can't then be freed. " | ||||
"Rather than create a logger per e.g. file processed or network connection " | ||||
"made, use the :ref:`existing mechanisms <context-info>` for passing " | ||||
"contextual information into your logs and restrict the loggers created to " | ||||
"those describing areas within your application (generally modules, but " | ||||
"occasionally slightly more fine-grained than that)." | ||||
msgstr "" | ||||
| | | |||
218 howto/logging.po
218
howto/logging.po | | @ -4,7 +4,7 @@ msgid "" | |||
msgstr "" | ||||
"Project-Id-Version: Python 3\n" | ||||
"Report-Msgid-Bugs-To: \n" | ||||
"POT-Creation-Date: 2020-10-01 16:00+0200\n" | ||||
"POT-Creation-Date: 2021-09-23 16:16+0200\n" | ||||
"PO-Revision-Date: 2021-01-28 15:44+0100\n" | ||||
"Last-Translator: Jules Lasne <jules.lasne@gmail.com>\n" | ||||
"Language-Team: FRENCH <traductions@lists.afpy.org>\n" | ||||
| | @ -161,7 +161,7 @@ msgstr "" | |||
"sévérité des évènements qu'elles suivent. Les niveaux standards et leurs " | ||||
"applications sont décrits ci-dessous (par ordre croissant de sévérité) :" | ||||
| ||||
#: howto/logging.rst:855 | ||||
#: howto/logging.rst:854 | ||||
msgid "Level" | ||||
msgstr "Niveau" | ||||
| ||||
| | @ -169,7 +169,7 @@ msgstr "Niveau" | |||
msgid "When it's used" | ||||
msgstr "Quand il est utilisé" | ||||
| ||||
#: howto/logging.rst:865 | ||||
#: howto/logging.rst:864 | ||||
msgid "``DEBUG``" | ||||
msgstr "``DEBUG``" | ||||
| ||||
| | @ -180,7 +180,7 @@ msgstr "" | |||
"Information détaillée, intéressante seulement lorsqu'on diagnostique un " | ||||
"problème." | ||||
| ||||
#: howto/logging.rst:863 | ||||
#: howto/logging.rst:862 | ||||
msgid "``INFO``" | ||||
msgstr "``INFO``" | ||||
| ||||
| | @ -188,7 +188,7 @@ msgstr "``INFO``" | |||
msgid "Confirmation that things are working as expected." | ||||
msgstr "Confirmation que tout fonctionne comme prévu." | ||||
| ||||
#: howto/logging.rst:861 | ||||
#: howto/logging.rst:860 | ||||
msgid "``WARNING``" | ||||
msgstr "``WARNING``" | ||||
| ||||
| | @ -202,7 +202,7 @@ msgstr "" | |||
"d'un problème dans un futur proche (par exemple « espace disque faible »). " | ||||
"Le logiciel fonctionne encore normalement." | ||||
| ||||
#: howto/logging.rst:859 | ||||
#: howto/logging.rst:858 | ||||
msgid "``ERROR``" | ||||
msgstr "``ERROR``" | ||||
| ||||
| | @ -214,7 +214,7 @@ msgstr "" | |||
"Du fait d'un problème plus sérieux, le logiciel n'a pas été capable de " | ||||
"réaliser une tâche." | ||||
| ||||
#: howto/logging.rst:857 | ||||
#: howto/logging.rst:856 | ||||
msgid "``CRITICAL``" | ||||
msgstr "``CRITICAL``" | ||||
| ||||
| | @ -1170,14 +1170,14 @@ msgstr "" | |||
msgid "Here is the logging.conf file:" | ||||
msgstr "Voici le fichier *logging.conf* :" | ||||
| ||||
#: howto/logging.rst:689 | ||||
#: howto/logging.rst:688 | ||||
msgid "" | ||||
"The output is nearly identical to that of the non-config-file-based example:" | ||||
msgstr "" | ||||
"La sortie est presque identique à celle de l'exemple qui n'est pas basé sur " | ||||
"un fichier de configuration :" | ||||
| ||||
#: howto/logging.rst:700 | ||||
#: howto/logging.rst:699 | ||||
msgid "" | ||||
"You can see that the config file approach has a few advantages over the " | ||||
"Python code approach, mainly separation of configuration and code and the " | ||||
| | @ -1188,7 +1188,7 @@ msgstr "" | |||
"séparation de la configuration et du code, et la possibilité pour une " | ||||
"personne qui ne code pas de modifier facilement les propriétés de `logging`." | ||||
| ||||
#: howto/logging.rst:704 | ||||
#: howto/logging.rst:703 | ||||
msgid "" | ||||
"The :func:`fileConfig` function takes a default parameter, " | ||||
"``disable_existing_loggers``, which defaults to ``True`` for reasons of " | ||||
| | @ -1207,7 +1207,7 @@ msgstr "" | |||
"documentation pour plus de détails, et donner la valeur ``False`` à ce " | ||||
"paramètre si vous le souhaitez." | ||||
| ||||
#: howto/logging.rst:712 | ||||
#: howto/logging.rst:711 | ||||
msgid "" | ||||
"The dictionary passed to :func:`dictConfig` can also specify a Boolean value " | ||||
"with key ``disable_existing_loggers``, which if not specified explicitly in " | ||||
| | @ -1222,7 +1222,7 @@ msgstr "" | |||
"forcément celui que vous souhaitez ; dans ce cas, donnez explicitement la " | ||||
"valeur ``False`` à cette clef." | ||||
| ||||
#: howto/logging.rst:722 | ||||
#: howto/logging.rst:721 | ||||
msgid "" | ||||
"Note that the class names referenced in config files need to be either " | ||||
"relative to the logging module, or absolute values which can be resolved " | ||||
| | @ -1240,7 +1240,7 @@ msgstr "" | |||
"une classe définie dans le paquet ``mypackage`` et le module ``mymodule``, " | ||||
"si ``mypackage`` est disponible dans les chemins d'importation de Python)." | ||||
| ||||
#: howto/logging.rst:730 | ||||
#: howto/logging.rst:729 | ||||
msgid "" | ||||
"In Python 3.2, a new means of configuring logging has been introduced, using " | ||||
"dictionaries to hold configuration information. This provides a superset of " | ||||
| | @ -1269,7 +1269,7 @@ msgstr "" | |||
"forme de *pickle* sur un connecteur, ou utiliser n'importe quelle approche " | ||||
"suivant la logique de votre application." | ||||
| ||||
#: howto/logging.rst:742 | ||||
#: howto/logging.rst:741 | ||||
msgid "" | ||||
"Here's an example of the same configuration as above, in YAML format for the " | ||||
"new dictionary-based approach:" | ||||
| | @ -1277,7 +1277,7 @@ msgstr "" | |||
"Voici un exemple définissant la même configuration que ci-dessus, au format " | ||||
"YAML pour le dictionnaire correspondant à cette nouvelle approche :" | ||||
| ||||
#: howto/logging.rst:766 | ||||
#: howto/logging.rst:765 | ||||
msgid "" | ||||
"For more information about logging using a dictionary, see :ref:`logging-" | ||||
"config-api`." | ||||
| | @ -1285,11 +1285,11 @@ msgstr "" | |||
"Pour plus d'informations sur la journalisation à l'aide d'un dictionnaire, " | ||||
"consultez :ref:`logging-config-api`." | ||||
| ||||
#: howto/logging.rst:770 | ||||
#: howto/logging.rst:769 | ||||
msgid "What happens if no configuration is provided" | ||||
msgstr "Comportement par défaut (si aucune configuration n'est fournie)" | ||||
| ||||
#: howto/logging.rst:772 | ||||
#: howto/logging.rst:771 | ||||
msgid "" | ||||
"If no logging configuration is provided, it is possible to have a situation " | ||||
"where a logging event needs to be output, but no handlers can be found to " | ||||
| | @ -1302,13 +1302,13 @@ msgstr "" | |||
"l'événement. Le comportement du paquet ``logging`` dans ces circonstances " | ||||
"dépend de la version Python." | ||||
| ||||
#: howto/logging.rst:777 | ||||
#: howto/logging.rst:776 | ||||
msgid "For versions of Python prior to 3.2, the behaviour is as follows:" | ||||
msgstr "" | ||||
"Pour les versions de Python antérieures à 3.2, le comportement est le " | ||||
"suivant :" | ||||
| ||||
#: howto/logging.rst:779 | ||||
#: howto/logging.rst:778 | ||||
msgid "" | ||||
"If *logging.raiseExceptions* is ``False`` (production mode), the event is " | ||||
"silently dropped." | ||||
| | @ -1316,7 +1316,7 @@ msgstr "" | |||
"Si *logging.raiseExceptions* vaut ``False`` (mode production), l’événement " | ||||
"est silencieusement abandonné." | ||||
| ||||
#: howto/logging.rst:782 | ||||
#: howto/logging.rst:781 | ||||
msgid "" | ||||
"If *logging.raiseExceptions* is ``True`` (development mode), a message 'No " | ||||
"handlers could be found for logger X.Y.Z' is printed once." | ||||
| | @ -1325,11 +1325,11 @@ msgstr "" | |||
"message *No handlers could be found for logger X.Y.Z* est écrit sur la " | ||||
"sortie standard une fois." | ||||
| ||||
#: howto/logging.rst:785 | ||||
#: howto/logging.rst:784 | ||||
msgid "In Python 3.2 and later, the behaviour is as follows:" | ||||
msgstr "Dans Python 3.2 et ultérieur, le comportement est le suivant :" | ||||
| ||||
#: howto/logging.rst:787 | ||||
#: howto/logging.rst:786 | ||||
msgid "" | ||||
"The event is output using a 'handler of last resort', stored in ``logging." | ||||
"lastResort``. This internal handler is not associated with any logger, and " | ||||
| | @ -1350,7 +1350,7 @@ msgstr "" | |||
"gestionnaire est défini sur ``WARNING``, de sorte que tous les événements de " | ||||
"cette sévérité et plus seront écrits." | ||||
| ||||
#: howto/logging.rst:796 | ||||
#: howto/logging.rst:795 | ||||
msgid "" | ||||
"To obtain the pre-3.2 behaviour, ``logging.lastResort`` can be set to " | ||||
"``None``." | ||||
| | @ -1358,11 +1358,11 @@ msgstr "" | |||
"Pour obtenir un comportement antérieur à 3.2, ``logging.lastResort`` peut " | ||||
"être mis à ``None``." | ||||
| ||||
#: howto/logging.rst:801 | ||||
#: howto/logging.rst:800 | ||||
msgid "Configuring Logging for a Library" | ||||
msgstr "Configuration de la journalisation pour une bibliothèque" | ||||
| ||||
#: howto/logging.rst:803 | ||||
#: howto/logging.rst:802 | ||||
msgid "" | ||||
"When developing a library which uses logging, you should take care to " | ||||
"document how the library uses logging - for example, the names of loggers " | ||||
| | @ -1382,7 +1382,7 @@ msgstr "" | |||
"``WARNING`` et au-dessus seront écrits sur ``sys.stderr``. Cela est " | ||||
"considéré comme le meilleur comportement par défaut." | ||||
| ||||
#: howto/logging.rst:811 | ||||
#: howto/logging.rst:810 | ||||
msgid "" | ||||
"If for some reason you *don't* want these messages printed in the absence of " | ||||
"any logging configuration, you can attach a do-nothing handler to the top-" | ||||
| | @ -1405,7 +1405,7 @@ msgstr "" | |||
"appels effectués dans le code de bibliothèque enverra la sortie à ces " | ||||
"gestionnaires, comme d'habitude." | ||||
| ||||
#: howto/logging.rst:820 | ||||
#: howto/logging.rst:819 | ||||
msgid "" | ||||
"A do-nothing handler is included in the logging package: :class:`~logging." | ||||
"NullHandler` (since Python 3.1). An instance of this handler could be added " | ||||
| | @ -1425,7 +1425,7 @@ msgstr "" | |||
"effectuée en utilisant des enregistreurs avec des noms correspondant à *foo." | ||||
"x*, *foo.x.y*, etc., alors le code ::" | ||||
| ||||
#: howto/logging.rst:831 | ||||
#: howto/logging.rst:830 | ||||
msgid "" | ||||
"should have the desired effect. If an organisation produces a number of " | ||||
"libraries, then the logger name specified can be 'orgname.foo' rather than " | ||||
| | @ -1435,7 +1435,7 @@ msgstr "" | |||
"bibliothèques, le nom de l'enregistreur spécifié peut être ``orgname.foo`` " | ||||
"plutôt que simplement ``foo``." | ||||
| ||||
#: howto/logging.rst:835 | ||||
#: howto/logging.rst:834 | ||||
msgid "" | ||||
"It is strongly advised that you *do not add any handlers other than* :class:" | ||||
"`~logging.NullHandler` *to your library's loggers*. This is because the " | ||||
| | @ -1454,11 +1454,11 @@ msgstr "" | |||
"le manteau », vous pourriez bien interférer avec les tests unitaires et la " | ||||
"journalisation qui convient à ses exigences." | ||||
| ||||
#: howto/logging.rst:846 | ||||
#: howto/logging.rst:845 | ||||
msgid "Logging Levels" | ||||
msgstr "Niveaux de journalisation" | ||||
| ||||
#: howto/logging.rst:848 | ||||
#: howto/logging.rst:847 | ||||
msgid "" | ||||
"The numeric values of logging levels are given in the following table. These " | ||||
"are primarily of interest if you want to define your own levels, and need " | ||||
| | @ -1472,39 +1472,39 @@ msgstr "" | |||
"prédéfinis. Si vous définissez un niveau avec la même valeur numérique, il " | ||||
"écrase la valeur prédéfinie ; le nom prédéfini est perdu." | ||||
| ||||
#: howto/logging.rst:855 | ||||
#: howto/logging.rst:854 | ||||
msgid "Numeric value" | ||||
msgstr "Valeur numérique" | ||||
| ||||
#: howto/logging.rst:857 | ||||
#: howto/logging.rst:856 | ||||
msgid "50" | ||||
msgstr "50" | ||||
| ||||
#: howto/logging.rst:859 | ||||
#: howto/logging.rst:858 | ||||
msgid "40" | ||||
msgstr "40" | ||||
| ||||
#: howto/logging.rst:861 | ||||
#: howto/logging.rst:860 | ||||
msgid "30" | ||||
msgstr "30" | ||||
| ||||
#: howto/logging.rst:863 | ||||
#: howto/logging.rst:862 | ||||
msgid "20" | ||||
msgstr "20" | ||||
| ||||
#: howto/logging.rst:865 | ||||
#: howto/logging.rst:864 | ||||
msgid "10" | ||||
msgstr "10" | ||||
| ||||
#: howto/logging.rst:867 | ||||
#: howto/logging.rst:866 | ||||
msgid "``NOTSET``" | ||||
msgstr "``NOTSET``" | ||||
| ||||
#: howto/logging.rst:867 | ||||
#: howto/logging.rst:866 | ||||
msgid "0" | ||||
msgstr "0" | ||||
| ||||
#: howto/logging.rst:870 | ||||
#: howto/logging.rst:869 | ||||
msgid "" | ||||
"Levels can also be associated with loggers, being set either by the " | ||||
"developer or through loading a saved logging configuration. When a logging " | ||||
| | @ -1522,7 +1522,7 @@ msgstr "" | |||
"réellement généré. C'est le mécanisme de base contrôlant la verbosité de la " | ||||
"sortie de journalisation." | ||||
| ||||
#: howto/logging.rst:877 | ||||
#: howto/logging.rst:876 | ||||
msgid "" | ||||
"Logging messages are encoded as instances of the :class:`~logging.LogRecord` " | ||||
"class. When a logger decides to actually log an event, a :class:`~logging." | ||||
| | @ -1533,7 +1533,7 @@ msgstr "" | |||
"enregistrer un événement, une instance de :class:`~logging.LogRecord` est " | ||||
"créée à partir du message de journalisation." | ||||
| ||||
#: howto/logging.rst:881 | ||||
#: howto/logging.rst:880 | ||||
msgid "" | ||||
"Logging messages are subjected to a dispatch mechanism through the use of :" | ||||
"dfn:`handlers`, which are instances of subclasses of the :class:`Handler` " | ||||
| | @ -1567,7 +1567,7 @@ msgstr "" | |||
"enregistreur soit défini sur la valeur ``False``, auquel cas le passage à " | ||||
"l'ancêtre gestionnaires s'arrête)." | ||||
| ||||
#: howto/logging.rst:895 | ||||
#: howto/logging.rst:894 | ||||
msgid "" | ||||
"Just as for loggers, handlers can have levels associated with them. A " | ||||
"handler's level acts as a filter in the same way as a logger's level does. " | ||||
| | @ -1584,11 +1584,11 @@ msgstr "" | |||
"classes définies par l'utilisateur de :class:`Handler` devront remplacer ce :" | ||||
"meth:`~Handler.emit`." | ||||
| ||||
#: howto/logging.rst:904 | ||||
#: howto/logging.rst:903 | ||||
msgid "Custom Levels" | ||||
msgstr "Niveaux personnalisés" | ||||
| ||||
#: howto/logging.rst:906 | ||||
#: howto/logging.rst:905 | ||||
msgid "" | ||||
"Defining your own levels is possible, but should not be necessary, as the " | ||||
"existing levels have been chosen on the basis of practical experience. " | ||||
| | @ -1612,11 +1612,11 @@ msgstr "" | |||
"contrôler et/ou interpréter, car une valeur numérique donnée peut signifier " | ||||
"des choses différentes pour différentes bibliothèques." | ||||
| ||||
#: howto/logging.rst:919 | ||||
#: howto/logging.rst:918 | ||||
msgid "Useful Handlers" | ||||
msgstr "Gestionnaires utiles" | ||||
| ||||
#: howto/logging.rst:921 | ||||
#: howto/logging.rst:920 | ||||
msgid "" | ||||
"In addition to the base :class:`Handler` class, many useful subclasses are " | ||||
"provided:" | ||||
| | @ -1624,7 +1624,7 @@ msgstr "" | |||
"En plus de la classe de base :class:`Handler`, de nombreuses sous-classes " | ||||
"utiles sont fournies :" | ||||
| ||||
#: howto/logging.rst:924 | ||||
#: howto/logging.rst:923 | ||||
msgid "" | ||||
":class:`StreamHandler` instances send messages to streams (file-like " | ||||
"objects)." | ||||
| | @ -1632,13 +1632,13 @@ msgstr "" | |||
"Les instances :class:`StreamHandler` envoient des messages aux flux (objets " | ||||
"de type fichier)." | ||||
| ||||
#: howto/logging.rst:927 | ||||
#: howto/logging.rst:926 | ||||
msgid ":class:`FileHandler` instances send messages to disk files." | ||||
msgstr "" | ||||
"Les instances :class:`FileHandler` envoient des messages à des fichiers sur " | ||||
"le disque." | ||||
| ||||
#: howto/logging.rst:929 | ||||
#: howto/logging.rst:928 | ||||
msgid "" | ||||
":class:`~handlers.BaseRotatingHandler` is the base class for handlers that " | ||||
"rotate log files at a certain point. It is not meant to be instantiated " | ||||
| | @ -1651,7 +1651,7 @@ msgstr "" | |||
"directement. Utilisez plutôt :class:`~handlers.RotatingFileHandler` ou :" | ||||
"class:`~handlers.TimedRotatingFileHandler`." | ||||
| ||||
#: howto/logging.rst:934 | ||||
#: howto/logging.rst:933 | ||||
msgid "" | ||||
":class:`~handlers.RotatingFileHandler` instances send messages to disk " | ||||
"files, with support for maximum log file sizes and log file rotation." | ||||
| | @ -1660,7 +1660,7 @@ msgstr "" | |||
"des fichiers sur le disque, avec la prise en charge des tailles maximales de " | ||||
"fichiers de journalisation et de la rotation des fichiers de journalisation." | ||||
| ||||
#: howto/logging.rst:937 | ||||
#: howto/logging.rst:936 | ||||
msgid "" | ||||
":class:`~handlers.TimedRotatingFileHandler` instances send messages to disk " | ||||
"files, rotating the log file at certain timed intervals." | ||||
| | @ -1669,7 +1669,7 @@ msgstr "" | |||
"messages aux fichiers de disque, en permutant le fichier journal à " | ||||
"intervalles réguliers." | ||||
| ||||
#: howto/logging.rst:940 | ||||
#: howto/logging.rst:939 | ||||
msgid "" | ||||
":class:`~handlers.SocketHandler` instances send messages to TCP/IP sockets. " | ||||
"Since 3.4, Unix domain sockets are also supported." | ||||
| | @ -1678,7 +1678,7 @@ msgstr "" | |||
"connecteurs TCP/IP. Depuis 3.4, les connecteurs UNIX sont également pris en " | ||||
"charge." | ||||
| ||||
#: howto/logging.rst:943 | ||||
#: howto/logging.rst:942 | ||||
msgid "" | ||||
":class:`~handlers.DatagramHandler` instances send messages to UDP sockets. " | ||||
"Since 3.4, Unix domain sockets are also supported." | ||||
| | @ -1687,7 +1687,7 @@ msgstr "" | |||
"aux connecteurs UDP. Depuis 3.4, les connecteurs UNIX sont également pris en " | ||||
"charge." | ||||
| ||||
#: howto/logging.rst:946 | ||||
#: howto/logging.rst:945 | ||||
msgid "" | ||||
":class:`~handlers.SMTPHandler` instances send messages to a designated email " | ||||
"address." | ||||
| | @ -1695,7 +1695,7 @@ msgstr "" | |||
"Les instances de :class:`~handlers.SMTPHandler` envoient des messages à une " | ||||
"adresse e-mail désignée." | ||||
| ||||
#: howto/logging.rst:949 | ||||
#: howto/logging.rst:948 | ||||
msgid "" | ||||
":class:`~handlers.SysLogHandler` instances send messages to a Unix syslog " | ||||
"daemon, possibly on a remote machine." | ||||
| | @ -1703,7 +1703,7 @@ msgstr "" | |||
"Les instances de :class:`~handlers.SysLogHandler` envoient des messages à un " | ||||
"*daemon* *syslog* UNIX, éventuellement sur un ordinateur distant." | ||||
| ||||
#: howto/logging.rst:952 | ||||
#: howto/logging.rst:951 | ||||
msgid "" | ||||
":class:`~handlers.NTEventLogHandler` instances send messages to a Windows " | ||||
"NT/2000/XP event log." | ||||
| | @ -1711,7 +1711,7 @@ msgstr "" | |||
"Les instances de :class:`~handlers.NTEventLogHandler` envoient des messages " | ||||
"à un journal des événements Windows NT/2000/XP." | ||||
| ||||
#: howto/logging.rst:955 | ||||
#: howto/logging.rst:954 | ||||
msgid "" | ||||
":class:`~handlers.MemoryHandler` instances send messages to a buffer in " | ||||
"memory, which is flushed whenever specific criteria are met." | ||||
| | @ -1720,7 +1720,7 @@ msgstr "" | |||
"tampon en mémoire, qui est vidé chaque fois que des critères spécifiques " | ||||
"sont remplis." | ||||
| ||||
#: howto/logging.rst:958 | ||||
#: howto/logging.rst:957 | ||||
msgid "" | ||||
":class:`~handlers.HTTPHandler` instances send messages to an HTTP server " | ||||
"using either ``GET`` or ``POST`` semantics." | ||||
| | @ -1728,7 +1728,7 @@ msgstr "" | |||
"Les instances de :class:`~handlers.HTTPHandler` envoient des messages à un " | ||||
"serveur HTTP à l'aide de la sémantique ``GET`` ou ``POST``." | ||||
| ||||
#: howto/logging.rst:961 | ||||
#: howto/logging.rst:960 | ||||
msgid "" | ||||
":class:`~handlers.WatchedFileHandler` instances watch the file they are " | ||||
"logging to. If the file changes, it is closed and reopened using the file " | ||||
| | @ -1741,7 +1741,7 @@ msgstr "" | |||
"les systèmes de type UNIX ; Windows ne prend pas en charge le mécanisme sous-" | ||||
"jacent utilisé." | ||||
| ||||
#: howto/logging.rst:966 | ||||
#: howto/logging.rst:965 | ||||
msgid "" | ||||
":class:`~handlers.QueueHandler` instances send messages to a queue, such as " | ||||
"those implemented in the :mod:`queue` or :mod:`multiprocessing` modules." | ||||
| | @ -1750,7 +1750,7 @@ msgstr "" | |||
"file d'attente, telles que celles implémentées dans les modules :mod:`queue` " | ||||
"ou :mod:`multiprocessing`." | ||||
| ||||
#: howto/logging.rst:969 | ||||
#: howto/logging.rst:968 | ||||
msgid "" | ||||
":class:`NullHandler` instances do nothing with error messages. They are used " | ||||
"by library developers who want to use logging, but want to avoid the 'No " | ||||
| | @ -1765,15 +1765,15 @@ msgstr "" | |||
"n'a pas configuré la journalisation. Voir :ref:`library-config` pour plus " | ||||
"d'informations." | ||||
| ||||
#: howto/logging.rst:975 | ||||
#: howto/logging.rst:974 | ||||
msgid "The :class:`NullHandler` class." | ||||
msgstr "La classe :class:`NullHandler`." | ||||
| ||||
#: howto/logging.rst:978 | ||||
#: howto/logging.rst:977 | ||||
msgid "The :class:`~handlers.QueueHandler` class." | ||||
msgstr "La classe :class:`~handlers.QueueHandler`." | ||||
| ||||
#: howto/logging.rst:981 | ||||
#: howto/logging.rst:980 | ||||
msgid "" | ||||
"The :class:`NullHandler`, :class:`StreamHandler` and :class:`FileHandler` " | ||||
"classes are defined in the core logging package. The other handlers are " | ||||
| | @ -1786,7 +1786,7 @@ msgstr "" | |||
"handlers` (il existe également un autre sous-module, :mod:`logging.config`, " | ||||
"pour la fonctionnalité de configuration)." | ||||
| ||||
#: howto/logging.rst:986 | ||||
#: howto/logging.rst:985 | ||||
msgid "" | ||||
"Logged messages are formatted for presentation through instances of the :" | ||||
"class:`Formatter` class. They are initialized with a format string suitable " | ||||
| | @ -1797,7 +1797,7 @@ msgstr "" | |||
"chaîne de format appropriée pour une utilisation avec l'opérateur % et un " | ||||
"dictionnaire." | ||||
| ||||
#: howto/logging.rst:990 | ||||
#: howto/logging.rst:989 | ||||
msgid "" | ||||
"For formatting multiple messages in a batch, instances of :class:`~handlers." | ||||
"BufferingFormatter` can be used. In addition to the format string (which is " | ||||
| | @ -1809,7 +1809,7 @@ msgstr "" | |||
"de format (qui est appliquée à chaque message dans le lot), il existe des " | ||||
"dispositions pour les chaînes de format d'en-tête et de fin." | ||||
| ||||
#: howto/logging.rst:995 | ||||
#: howto/logging.rst:994 | ||||
msgid "" | ||||
"When filtering based on logger level and/or handler level is not enough, " | ||||
"instances of :class:`Filter` can be added to both :class:`Logger` and :class:" | ||||
| | @ -1826,7 +1826,7 @@ msgstr "" | |||
"consultent tous leurs filtres pour obtenir l'autorisation. Si un filtre " | ||||
"renvoie une valeur ``False``, le traitement du message est arrêté." | ||||
| ||||
#: howto/logging.rst:1002 | ||||
#: howto/logging.rst:1001 | ||||
msgid "" | ||||
"The basic :class:`Filter` functionality allows filtering by specific logger " | ||||
"name. If this feature is used, messages sent to the named logger and its " | ||||
| | @ -1837,11 +1837,11 @@ msgstr "" | |||
"envoyés à l'enregistreur nommé et à ses enfants sont autorisés via le filtre " | ||||
"et tous les autres sont abandonnés." | ||||
| ||||
#: howto/logging.rst:1010 | ||||
#: howto/logging.rst:1009 | ||||
msgid "Exceptions raised during logging" | ||||
msgstr "Exceptions levées par la journalisation" | ||||
| ||||
#: howto/logging.rst:1012 | ||||
#: howto/logging.rst:1011 | ||||
msgid "" | ||||
"The logging package is designed to swallow exceptions which occur while " | ||||
"logging in production. This is so that errors which occur while handling " | ||||
| | @ -1855,7 +1855,7 @@ msgstr "" | |||
"journalisation, une erreur réseau ou d'autres erreurs similaires) ne " | ||||
"provoquent pas l'arrêt de l'application utilisant la journalisation." | ||||
| ||||
#: howto/logging.rst:1017 | ||||
#: howto/logging.rst:1016 | ||||
msgid "" | ||||
":class:`SystemExit` and :class:`KeyboardInterrupt` exceptions are never " | ||||
"swallowed. Other exceptions which occur during the :meth:`~Handler.emit` " | ||||
| | @ -1867,7 +1867,7 @@ msgstr "" | |||
"la méthode :meth:`~Handler.emit` d'une sous classe :class:`Handler` sont " | ||||
"passées à sa méthode :meth:`~Handler.handleError`." | ||||
| ||||
#: howto/logging.rst:1022 | ||||
#: howto/logging.rst:1021 | ||||
msgid "" | ||||
"The default implementation of :meth:`~Handler.handleError` in :class:" | ||||
"`Handler` checks to see if a module-level variable, :data:`raiseExceptions`, " | ||||
| | @ -1880,7 +1880,7 @@ msgstr "" | |||
"pile d'appels est affichée sur :data:`sys.stderr`. Si elle n'est pas " | ||||
"définie, l'exception est passée sous silence." | ||||
| ||||
#: howto/logging.rst:1027 | ||||
#: howto/logging.rst:1026 | ||||
msgid "" | ||||
"The default value of :data:`raiseExceptions` is ``True``. This is because " | ||||
"during development, you typically want to be notified of any exceptions that " | ||||
| | @ -1892,11 +1892,11 @@ msgstr "" | |||
"toutes les exceptions qui se produisent. Il est conseillé de définir :data:" | ||||
"`raiseExceptions` à ``False`` pour une utilisation en production." | ||||
| ||||
#: howto/logging.rst:1037 | ||||
#: howto/logging.rst:1036 | ||||
msgid "Using arbitrary objects as messages" | ||||
msgstr "Utilisation d'objets arbitraires comme messages" | ||||
| ||||
#: howto/logging.rst:1039 | ||||
#: howto/logging.rst:1038 | ||||
msgid "" | ||||
"In the preceding sections and examples, it has been assumed that the message " | ||||
"passed when logging the event is a string. However, this is not the only " | ||||
| | @ -1917,11 +1917,11 @@ msgstr "" | |||
"gestionnaires :class:`~handlers.SocketHandler` émettent un événement en lui " | ||||
"appliquant *pickle* et en l'envoyant sur le réseau." | ||||
| ||||
#: howto/logging.rst:1050 | ||||
#: howto/logging.rst:1049 | ||||
msgid "Optimization" | ||||
msgstr "Optimisation" | ||||
| ||||
#: howto/logging.rst:1052 | ||||
#: howto/logging.rst:1051 | ||||
msgid "" | ||||
"Formatting of message arguments is deferred until it cannot be avoided. " | ||||
"However, computing the arguments passed to the logging method can also be " | ||||
| | @ -1940,7 +1940,7 @@ msgstr "" | |||
"renvoie ``True`` si un événement est créé par l'enregistreur pour ce niveau " | ||||
"d'appel. Vous pouvez écrire un code qui ressemble à ça ::" | ||||
| ||||
#: howto/logging.rst:1064 | ||||
#: howto/logging.rst:1063 | ||||
msgid "" | ||||
"so that if the logger's threshold is set above ``DEBUG``, the calls to :func:" | ||||
"`expensive_func1` and :func:`expensive_func2` are never made." | ||||
| | @ -1949,7 +1949,7 @@ msgstr "" | |||
"les appels à :func:`expensive_func1` et :func:`expensive_func2` ne sont " | ||||
"jamais faits." | ||||
| ||||
#: howto/logging.rst:1067 | ||||
#: howto/logging.rst:1066 | ||||
msgid "" | ||||
"In some cases, :meth:`~Logger.isEnabledFor` can itself be more expensive " | ||||
"than you'd like (e.g. for deeply nested loggers where an explicit level is " | ||||
| | @ -1971,7 +1971,7 @@ msgstr "" | |||
"configuration de journalisation change dynamiquement pendant l'exécution de " | ||||
"l'application (ce qui est rarement le cas)." | ||||
| ||||
#: howto/logging.rst:1076 | ||||
#: howto/logging.rst:1075 | ||||
msgid "" | ||||
"There are other optimizations which can be made for specific applications " | ||||
"which need more precise control over what logging information is collected. " | ||||
| | @ -1984,19 +1984,19 @@ msgstr "" | |||
"vous pouvez faire pour éviter le traitement pendant la journalisation dont " | ||||
"vous n'avez pas besoin :" | ||||
| ||||
#: howto/logging.rst:1082 | ||||
#: howto/logging.rst:1081 | ||||
msgid "What you don't want to collect" | ||||
msgstr "Ce que vous ne voulez pas collecter" | ||||
| ||||
#: howto/logging.rst:1082 | ||||
#: howto/logging.rst:1081 | ||||
msgid "How to avoid collecting it" | ||||
msgstr "Comment éviter de le collecter" | ||||
| ||||
#: howto/logging.rst:1084 | ||||
#: howto/logging.rst:1083 | ||||
msgid "Information about where calls were made from." | ||||
msgstr "Informations sur l'endroit où les appels ont été faits." | ||||
| ||||
#: howto/logging.rst:1084 | ||||
#: howto/logging.rst:1083 | ||||
msgid "" | ||||
"Set ``logging._srcfile`` to ``None``. This avoids calling :func:`sys." | ||||
"_getframe`, which may help to speed up your code in environments like PyPy " | ||||
| | @ -2007,23 +2007,36 @@ msgstr "" | |||
"comme PyPy (qui ne peut pas accélérer le code qui utilise :func:`sys." | ||||
"_getframe`)." | ||||
| ||||
#: howto/logging.rst:1091 | ||||
#: howto/logging.rst:1089 | ||||
msgid "Threading information." | ||||
msgstr "Informations de *threading*." | ||||
| ||||
#: howto/logging.rst:1091 | ||||
msgid "Set ``logging.logThreads`` to ``0``." | ||||
#: howto/logging.rst:1089 | ||||
#, fuzzy | ||||
msgid "Set ``logging.logThreads`` to ``False``." | ||||
msgstr "Mettez ``logging.logThreads`` à ``0``." | ||||
| ||||
#: howto/logging.rst:1093 | ||||
msgid "Process information." | ||||
msgstr "Informations sur le processus." | ||||
#: howto/logging.rst:1091 | ||||
msgid "Current process ID (:func:`os.getpid`)" | ||||
msgstr "" | ||||
| ||||
#: howto/logging.rst:1093 | ||||
msgid "Set ``logging.logProcesses`` to ``0``." | ||||
#: howto/logging.rst:1091 | ||||
#, fuzzy | ||||
msgid "Set ``logging.logProcesses`` to ``False``." | ||||
msgstr "Mettez ``logging.logProcesses`` à ``0``." | ||||
| ||||
#: howto/logging.rst:1096 | ||||
#: howto/logging.rst:1093 | ||||
msgid "" | ||||
"Current process name when using ``multiprocessing`` to manage multiple " | ||||
"processes." | ||||
msgstr "" | ||||
| ||||
#: howto/logging.rst:1093 | ||||
#, fuzzy | ||||
msgid "Set ``logging.logMultiprocessing`` to ``False``." | ||||
msgstr "Mettez ``logging.logProcesses`` à ``0``." | ||||
| ||||
#: howto/logging.rst:1097 | ||||
msgid "" | ||||
"Also note that the core logging module only includes the basic handlers. If " | ||||
"you don't import :mod:`logging.handlers` and :mod:`logging.config`, they " | ||||
| | @ -2033,30 +2046,33 @@ msgstr "" | |||
"les gestionnaires de base. Si vous n'importez pas :mod:`logging.handlers` " | ||||
"et :mod:`logging.config`, ils ne prendront pas de mémoire." | ||||
| ||||
#: howto/logging.rst:1103 | ||||
#: howto/logging.rst:1104 | ||||
msgid "Module :mod:`logging`" | ||||
msgstr "Module :mod:`logging`" | ||||
| ||||
#: howto/logging.rst:1103 | ||||
#: howto/logging.rst:1104 | ||||
msgid "API reference for the logging module." | ||||
msgstr "Référence d'API pour le module de journalisation." | ||||
| ||||
#: howto/logging.rst:1106 | ||||
#: howto/logging.rst:1107 | ||||
msgid "Module :mod:`logging.config`" | ||||
msgstr "Module :mod:`logging.config`" | ||||
| ||||
#: howto/logging.rst:1106 | ||||
#: howto/logging.rst:1107 | ||||
msgid "Configuration API for the logging module." | ||||
msgstr "API de configuration pour le module de journalisation." | ||||
| ||||
#: howto/logging.rst:1109 | ||||
#: howto/logging.rst:1110 | ||||
msgid "Module :mod:`logging.handlers`" | ||||
msgstr "Module :mod:`logging.handlers`" | ||||
| ||||
#: howto/logging.rst:1109 | ||||
#: howto/logging.rst:1110 | ||||
msgid "Useful handlers included with the logging module." | ||||
msgstr "Gestionnaires utiles inclus avec le module de journalisation." | ||||
| ||||
#: howto/logging.rst:1111 | ||||
#: howto/logging.rst:1112 | ||||
msgid ":ref:`A logging cookbook <logging-cookbook>`" | ||||
msgstr ":ref:`A logging cookbook <logging-cookbook>`" | ||||
| ||||
#~ msgid "Process information." | ||||
#~ msgstr "Informations sur le processus." | ||||
| | | |||
| | @ -5,7 +5,7 @@ msgid "" | |||
msgstr "" | ||||
"Project-Id-Version: Python 3\n" | ||||
"Report-Msgid-Bugs-To: \n" | ||||
"POT-Creation-Date: 2020-10-01 16:00+0200\n" | ||||
"POT-Creation-Date: 2021-09-23 16:16+0200\n" | ||||
"PO-Revision-Date: 2021-01-28 15:50+0100\n" | ||||
"Last-Translator: Jules Lasne <jules.lasne@gmail.com>\n" | ||||
"Language-Team: FRENCH <traductions@lists.afpy.org>\n" | ||||
| | @ -61,10 +61,11 @@ msgstr "" | |||
"qui a motivé la création de Python 3, vous pouvez lire le `Python 3 Q & A`_ " | ||||
"de Nick Coghlan ou bien `Why Python 3 exists`_ de Brett Cannon." | ||||
| ||||
#: howto/pyporting.rst:23 | ||||
#: howto/pyporting.rst:24 | ||||
#, fuzzy | ||||
msgid "" | ||||
"For help with porting, you can email the python-porting_ mailing list with " | ||||
"questions." | ||||
"For help with porting, you can view the archived python-porting_ mailing " | ||||
"list." | ||||
msgstr "" | ||||
"Vous pouvez solliciter par courriel l'aide de la liste de diffusion python-" | ||||
"porting_ pour vos questions liées au portage." | ||||
| | | |||
| | @ -5,7 +5,7 @@ msgid "" | |||
msgstr "" | ||||
"Project-Id-Version: Python 3\n" | ||||
"Report-Msgid-Bugs-To: \n" | ||||
"POT-Creation-Date: 2020-08-24 09:01+0200\n" | ||||
"POT-Creation-Date: 2021-09-23 16:16+0200\n" | ||||
"PO-Revision-Date: 2020-09-30 17:07+0200\n" | ||||
"Last-Translator: Mathieu Dupuy <deronnax@gmail.com>\n" | ||||
"Language-Team: FRENCH <traductions@lists.afpy.org>\n" | ||||
| | @ -111,9 +111,10 @@ msgstr "" | |||
"près la seule solution valable." | ||||
| ||||
#: howto/sockets.rst:47 | ||||
#, fuzzy | ||||
msgid "" | ||||
"They were invented in Berkeley as part of the BSD flavor of Unix. They " | ||||
"spread like wildfire with the Internet. With good reason --- the combination " | ||||
"spread like wildfire with the internet. With good reason --- the combination " | ||||
"of sockets with INET makes talking to arbitrary machines around the world " | ||||
"unbelievably easy (at least compared to other schemes)." | ||||
msgstr "" | ||||
| | | |||
101 howto/sorting.po
101
howto/sorting.po | | @ -5,7 +5,7 @@ msgid "" | |||
msgstr "" | ||||
"Project-Id-Version: Python 3\n" | ||||
"Report-Msgid-Bugs-To: \n" | ||||
"POT-Creation-Date: 2020-08-24 09:01+0200\n" | ||||
"POT-Creation-Date: 2021-09-23 16:16+0200\n" | ||||
"PO-Revision-Date: 2021-01-28 15:46+0100\n" | ||||
"Last-Translator: Jules Lasne <jules.lasne@gmail.com>\n" | ||||
"Language-Team: FRENCH <traductions@lists.afpy.org>\n" | ||||
| | @ -58,14 +58,15 @@ msgid "Sorting Basics" | |||
msgstr "Les bases du tri" | ||||
| ||||
#: howto/sorting.rst:20 | ||||
#, fuzzy | ||||
msgid "" | ||||
"A simple ascending sort is very easy: just call the :func:`sorted` function. " | ||||
"It returns a new sorted list::" | ||||
"It returns a new sorted list:" | ||||
msgstr "" | ||||
"Un tri ascendant simple est très facile : il suffit d'appeler la fonction :" | ||||
"func:`sorted`. Elle renvoie une nouvelle liste triée ::" | ||||
| ||||
#: howto/sorting.rst:26 | ||||
#: howto/sorting.rst:28 | ||||
msgid "" | ||||
"You can also use the :meth:`list.sort` method. It modifies the list in-place " | ||||
"(and returns ``None`` to avoid confusion). Usually it's less convenient " | ||||
| | @ -78,7 +79,7 @@ msgstr "" | |||
"`sorted` -- mais si vous n'avez pas besoin de la liste originale, cette " | ||||
"technique est légèrement plus efficace." | ||||
| ||||
#: howto/sorting.rst:36 | ||||
#: howto/sorting.rst:40 | ||||
msgid "" | ||||
"Another difference is that the :meth:`list.sort` method is only defined for " | ||||
"lists. In contrast, the :func:`sorted` function accepts any iterable." | ||||
| | @ -87,11 +88,11 @@ msgstr "" | |||
"définie pour les listes. Au contraire, la fonction :func:`sorted` accepte " | ||||
"n'importe quel itérable." | ||||
| ||||
#: howto/sorting.rst:43 | ||||
#: howto/sorting.rst:49 | ||||
msgid "Key Functions" | ||||
msgstr "Fonctions clef" | ||||
| ||||
#: howto/sorting.rst:45 | ||||
#: howto/sorting.rst:51 | ||||
msgid "" | ||||
"Both :meth:`list.sort` and :func:`sorted` have a *key* parameter to specify " | ||||
"a function (or other callable) to be called on each list element prior to " | ||||
| | @ -101,11 +102,11 @@ msgstr "" | |||
"une fonction (ou autre appelable) qui peut être appelée sur chaque élément " | ||||
"de la liste avant d'effectuer des comparaisons." | ||||
| ||||
#: howto/sorting.rst:49 | ||||
#: howto/sorting.rst:55 | ||||
msgid "For example, here's a case-insensitive string comparison:" | ||||
msgstr "Par exemple, voici une comparaison de texte insensible à la casse:" | ||||
| ||||
#: howto/sorting.rst:54 | ||||
#: howto/sorting.rst:62 | ||||
msgid "" | ||||
"The value of the *key* parameter should be a function (or other callable) " | ||||
"that takes a single argument and returns a key to use for sorting purposes. " | ||||
| | @ -117,7 +118,7 @@ msgstr "" | |||
"Cette technique est rapide car la fonction clef est appelée exactement une " | ||||
"seule fois pour chaque enregistrement en entrée." | ||||
| ||||
#: howto/sorting.rst:59 | ||||
#: howto/sorting.rst:67 | ||||
msgid "" | ||||
"A common pattern is to sort complex objects using some of the object's " | ||||
"indices as keys. For example:" | ||||
| | @ -125,18 +126,18 @@ msgstr "" | |||
"Un usage fréquent est de faire un tri sur des objets complexes en utilisant " | ||||
"les indices des objets en tant que clef. Par exemple :" | ||||
| ||||
#: howto/sorting.rst:70 | ||||
#: howto/sorting.rst:80 | ||||
msgid "" | ||||
"The same technique works for objects with named attributes. For example:" | ||||
msgstr "" | ||||
"La même technique marche pour des objets avec des attributs nommés. Par " | ||||
"exemple :" | ||||
| ||||
#: howto/sorting.rst:89 | ||||
#: howto/sorting.rst:101 | ||||
msgid "Operator Module Functions" | ||||
msgstr "Fonctions du module *operator*" | ||||
| ||||
#: howto/sorting.rst:91 | ||||
#: howto/sorting.rst:103 | ||||
msgid "" | ||||
"The key-function patterns shown above are very common, so Python provides " | ||||
"convenience functions to make accessor functions easier and faster. The :mod:" | ||||
| | @ -149,13 +150,13 @@ msgstr "" | |||
"func:`~operator.itemgetter`, :func:`~operator.attrgetter`, et :func:" | ||||
"`~operator.methodcaller`." | ||||
| ||||
#: howto/sorting.rst:96 | ||||
#: howto/sorting.rst:108 | ||||
msgid "Using those functions, the above examples become simpler and faster:" | ||||
msgstr "" | ||||
"En utilisant ces fonctions, les exemples au dessus deviennent plus simples " | ||||
"et plus rapides :" | ||||
| ||||
#: howto/sorting.rst:106 | ||||
#: howto/sorting.rst:120 | ||||
msgid "" | ||||
"The operator module functions allow multiple levels of sorting. For example, " | ||||
"to sort by *grade* then by *age*:" | ||||
| | @ -163,11 +164,11 @@ msgstr "" | |||
"Les fonctions du module *operator* permettent plusieurs niveaux de tri. Par " | ||||
"exemple, pour trier par *grade* puis par *age* :" | ||||
| ||||
#: howto/sorting.rst:116 | ||||
#: howto/sorting.rst:132 | ||||
msgid "Ascending and Descending" | ||||
msgstr "Ascendant et descendant" | ||||
| ||||
#: howto/sorting.rst:118 | ||||
#: howto/sorting.rst:134 | ||||
msgid "" | ||||
"Both :meth:`list.sort` and :func:`sorted` accept a *reverse* parameter with " | ||||
"a boolean value. This is used to flag descending sorts. For example, to get " | ||||
| | @ -178,11 +179,11 @@ msgstr "" | |||
"des tris. Par exemple, pour avoir les données des étudiants dans l'ordre " | ||||
"inverse par *age* :" | ||||
| ||||
#: howto/sorting.rst:129 | ||||
#: howto/sorting.rst:147 | ||||
msgid "Sort Stability and Complex Sorts" | ||||
msgstr "Stabilité des tris et tris complexes" | ||||
| ||||
#: howto/sorting.rst:131 | ||||
#: howto/sorting.rst:149 | ||||
msgid "" | ||||
"Sorts are guaranteed to be `stable <https://en.wikipedia.org/wiki/" | ||||
"Sorting_algorithm#Stability>`_\\. That means that when multiple records have " | ||||
| | @ -192,7 +193,7 @@ msgstr "" | |||
"Algorithme_de_tri#Caract.C3.A8re_stable>`_\\. Cela signifie que lorsque " | ||||
"plusieurs enregistrements on la même clef, leur ordre original est préservé." | ||||
| ||||
#: howto/sorting.rst:139 | ||||
#: howto/sorting.rst:159 | ||||
msgid "" | ||||
"Notice how the two records for *blue* retain their original order so that " | ||||
"``('blue', 1)`` is guaranteed to precede ``('blue', 2)``." | ||||
| | @ -201,7 +202,7 @@ msgstr "" | |||
"et que par conséquent il est garanti que ``('blue', 1)`` précède ``('blue', " | ||||
"2)``." | ||||
| ||||
#: howto/sorting.rst:142 | ||||
#: howto/sorting.rst:162 | ||||
msgid "" | ||||
"This wonderful property lets you build complex sorts in a series of sorting " | ||||
"steps. For example, to sort the student data by descending *grade* and then " | ||||
| | @ -212,7 +213,7 @@ msgstr "" | |||
"des étudiants en ordre descendant par *grade* puis en ordre ascendant par " | ||||
"*age*, effectuez un tri par *age* en premier puis un second tri par *grade* :" | ||||
| ||||
#: howto/sorting.rst:150 | ||||
#: howto/sorting.rst:172 | ||||
msgid "" | ||||
"This can be abstracted out into a wrapper function that can take a list and " | ||||
"tuples of field and order to sort them on multiple passes." | ||||
| | @ -220,7 +221,7 @@ msgstr "" | |||
"Ceci peut être encapsulé dans une fonction qui prend une liste et des n-" | ||||
"uplets (attribut, ordre) pour les trier en plusieurs passes." | ||||
| ||||
#: howto/sorting.rst:161 | ||||
#: howto/sorting.rst:185 | ||||
msgid "" | ||||
"The `Timsort <https://en.wikipedia.org/wiki/Timsort>`_ algorithm used in " | ||||
"Python does multiple sorts efficiently because it can take advantage of any " | ||||
| | @ -230,17 +231,17 @@ msgstr "" | |||
"Python effectue de multiples tris efficacement parce qu'il peut tirer " | ||||
"avantage de l'ordre existant dans un jeu de données." | ||||
| ||||
#: howto/sorting.rst:166 | ||||
#: howto/sorting.rst:190 | ||||
msgid "The Old Way Using Decorate-Sort-Undecorate" | ||||
msgstr "La méthode traditionnelle utilisant Decorate-Sort-Undecorate" | ||||
| ||||
#: howto/sorting.rst:168 | ||||
#: howto/sorting.rst:192 | ||||
msgid "This idiom is called Decorate-Sort-Undecorate after its three steps:" | ||||
msgstr "" | ||||
"Cette technique est appelée Decorate-Sort-Undecorate et se base sur trois " | ||||
"étapes :" | ||||
| ||||
#: howto/sorting.rst:170 | ||||
#: howto/sorting.rst:194 | ||||
msgid "" | ||||
"First, the initial list is decorated with new values that control the sort " | ||||
"order." | ||||
| | @ -248,11 +249,11 @@ msgstr "" | |||
"Premièrement, la liste de départ est décorée avec les nouvelles valeurs qui " | ||||
"contrôlent l'ordre du tri." | ||||
| ||||
#: howto/sorting.rst:172 | ||||
#: howto/sorting.rst:196 | ||||
msgid "Second, the decorated list is sorted." | ||||
msgstr "En second lieu, la liste décorée est triée." | ||||
| ||||
#: howto/sorting.rst:174 | ||||
#: howto/sorting.rst:198 | ||||
msgid "" | ||||
"Finally, the decorations are removed, creating a list that contains only the " | ||||
"initial values in the new order." | ||||
| | @ -260,14 +261,14 @@ msgstr "" | |||
"Enfin, la décoration est supprimée, créant ainsi une liste qui contient " | ||||
"seulement la valeur initiale dans le nouvel ordre." | ||||
| ||||
#: howto/sorting.rst:177 | ||||
#: howto/sorting.rst:201 | ||||
msgid "" | ||||
"For example, to sort the student data by *grade* using the DSU approach:" | ||||
msgstr "" | ||||
"Par exemple, pour trier les données étudiant par *grade* en utilisant " | ||||
"l'approche DSU :" | ||||
| ||||
#: howto/sorting.rst:184 | ||||
#: howto/sorting.rst:208 | ||||
msgid "" | ||||
"This idiom works because tuples are compared lexicographically; the first " | ||||
"items are compared; if they are the same then the second items are compared, " | ||||
| | @ -277,7 +278,7 @@ msgstr "" | |||
"lexicographique; les premiers objets sont comparés; si il y a des objets " | ||||
"identiques, alors l'objet suivant est comparé, et ainsi de suite." | ||||
| ||||
#: howto/sorting.rst:188 | ||||
#: howto/sorting.rst:212 | ||||
msgid "" | ||||
"It is not strictly necessary in all cases to include the index *i* in the " | ||||
"decorated list, but including it gives two benefits:" | ||||
| | @ -285,7 +286,7 @@ msgstr "" | |||
"Il n'est pas strictement nécessaire dans tous les cas d’inclure l'indice *i* " | ||||
"dans la liste décorée, mais l'inclure donne deux avantages :" | ||||
| ||||
#: howto/sorting.rst:191 | ||||
#: howto/sorting.rst:215 | ||||
msgid "" | ||||
"The sort is stable -- if two items have the same key, their order will be " | ||||
"preserved in the sorted list." | ||||
| | @ -293,7 +294,7 @@ msgstr "" | |||
"Le tri est stable -- si deux objets on la même clef, leur ordre sera " | ||||
"préservé dans la liste triée." | ||||
| ||||
#: howto/sorting.rst:194 | ||||
#: howto/sorting.rst:218 | ||||
msgid "" | ||||
"The original items do not have to be comparable because the ordering of the " | ||||
"decorated tuples will be determined by at most the first two items. So for " | ||||
| | @ -305,7 +306,7 @@ msgstr "" | |||
"par exemple la liste originale pourrait contenir des nombres complexes qui " | ||||
"pourraient ne pas être triés directement." | ||||
| ||||
#: howto/sorting.rst:199 | ||||
#: howto/sorting.rst:223 | ||||
msgid "" | ||||
"Another name for this idiom is `Schwartzian transform <https://en.wikipedia." | ||||
"org/wiki/Schwartzian_transform>`_\\, after Randal L. Schwartz, who " | ||||
| | @ -315,7 +316,7 @@ msgstr "" | |||
"wikipedia.org/wiki/Schwartzian_transform>`_\\, après que Randal L. Schwartz " | ||||
"l'ait popularisé chez les développeurs Perl." | ||||
| ||||
#: howto/sorting.rst:203 | ||||
#: howto/sorting.rst:227 | ||||
msgid "" | ||||
"Now that Python sorting provides key-functions, this technique is not often " | ||||
"needed." | ||||
| | @ -323,11 +324,11 @@ msgstr "" | |||
"Maintenant que le tri Python fournit des fonctions-clef, cette technique " | ||||
"n'est plus souvent utilisée." | ||||
| ||||
#: howto/sorting.rst:207 | ||||
#: howto/sorting.rst:231 | ||||
msgid "The Old Way Using the *cmp* Parameter" | ||||
msgstr "La méthode traditionnelle d'utiliser le paramètre *cmp*" | ||||
| ||||
#: howto/sorting.rst:209 | ||||
#: howto/sorting.rst:233 | ||||
msgid "" | ||||
"Many constructs given in this HOWTO assume Python 2.4 or later. Before that, " | ||||
"there was no :func:`sorted` builtin and :meth:`list.sort` took no keyword " | ||||
| | @ -340,7 +341,7 @@ msgstr "" | |||
"versions Python 2.x utilisaient un paramètre *cmp* pour prendre en charge " | ||||
"les fonctions de comparaisons définies par les utilisateurs." | ||||
| ||||
#: howto/sorting.rst:214 | ||||
#: howto/sorting.rst:238 | ||||
msgid "" | ||||
"In Py3.0, the *cmp* parameter was removed entirely (as part of a larger " | ||||
"effort to simplify and unify the language, eliminating the conflict between " | ||||
| | @ -350,7 +351,7 @@ msgstr "" | |||
"effort plus général pour simplifier et unifier le langage, en éliminant le " | ||||
"conflit entre les comparaisons riches et la méthode magique :meth:`__cmp__`)." | ||||
| ||||
#: howto/sorting.rst:218 | ||||
#: howto/sorting.rst:242 | ||||
msgid "" | ||||
"In Py2.x, sort allowed an optional function which can be called for doing " | ||||
"the comparisons. That function should take two arguments to be compared and " | ||||
| | @ -363,28 +364,29 @@ msgstr "" | |||
"inférieur-à, renvoyer zéro si ils sont égaux, ou renvoyer une valeur " | ||||
"positive pour supérieur-à. Par exemple, nous pouvons faire :" | ||||
| ||||
#: howto/sorting.rst:228 | ||||
#: howto/sorting.rst:254 | ||||
msgid "Or you can reverse the order of comparison with:" | ||||
msgstr "Ou nous pouvons inverser l'ordre de comparaison avec :" | ||||
| ||||
#: howto/sorting.rst:235 | ||||
#: howto/sorting.rst:263 | ||||
#, fuzzy | ||||
msgid "" | ||||
"When porting code from Python 2.x to 3.x, the situation can arise when you " | ||||
"have the user supplying a comparison function and you need to convert that " | ||||
"to a key function. The following wrapper makes that easy to do::" | ||||
"to a key function. The following wrapper makes that easy to do:" | ||||
msgstr "" | ||||
"En portant du code depuis Python 2.X vers 3.x, des problèmes peuvent " | ||||
"survenir quand des utilisateurs fournissent une fonction de comparaison et " | ||||
"qu'il faut convertir cette fonction en une fonction-clef. La fonction " | ||||
"d'encapsulation suivante rend cela plus facile à faire ::" | ||||
| ||||
#: howto/sorting.rst:258 | ||||
#: howto/sorting.rst:294 | ||||
msgid "To convert to a key function, just wrap the old comparison function:" | ||||
msgstr "" | ||||
"Pour convertir une fonction clef, ils suffit d'encapsuler l'ancienne " | ||||
"fonction de comparaison :" | ||||
| ||||
#: howto/sorting.rst:269 | ||||
#: howto/sorting.rst:305 | ||||
msgid "" | ||||
"In Python 3.2, the :func:`functools.cmp_to_key` function was added to the :" | ||||
"mod:`functools` module in the standard library." | ||||
| | @ -392,11 +394,11 @@ msgstr "" | |||
"En Python 3.2, la fonction :func:`functools.cmp_to_key` à été ajoutée au " | ||||
"module :mod:`functools` dans la librairie standard." | ||||
| ||||
#: howto/sorting.rst:273 | ||||
#: howto/sorting.rst:309 | ||||
msgid "Odd and Ends" | ||||
msgstr "Curiosités et conclusion" | ||||
| ||||
#: howto/sorting.rst:275 | ||||
#: howto/sorting.rst:311 | ||||
msgid "" | ||||
"For locale aware sorting, use :func:`locale.strxfrm` for a key function or :" | ||||
"func:`locale.strcoll` for a comparison function." | ||||
| | @ -404,7 +406,7 @@ msgstr "" | |||
"Pour du tri de texte localisé, utilisez :func:`locale.strxfrm` en tant que " | ||||
"fonction clef ou :func:`locale.strcoll` comme fonction de comparaison." | ||||
| ||||
#: howto/sorting.rst:278 | ||||
#: howto/sorting.rst:314 | ||||
msgid "" | ||||
"The *reverse* parameter still maintains sort stability (so that records with " | ||||
"equal keys retain the original order). Interestingly, that effect can be " | ||||
| | @ -416,18 +418,19 @@ msgstr "" | |||
"cet effet peut être simulé sans le paramètre en utilisant la fonction " | ||||
"native :func:`reversed` deux fois :" | ||||
| ||||
#: howto/sorting.rst:290 | ||||
#: howto/sorting.rst:328 | ||||
#, fuzzy | ||||
msgid "" | ||||
"The sort routines are guaranteed to use :meth:`__lt__` when making " | ||||
"comparisons between two objects. So, it is easy to add a standard sort order " | ||||
"to a class by defining an :meth:`__lt__` method::" | ||||
"to a class by defining an :meth:`__lt__` method:" | ||||
msgstr "" | ||||
"Il est garanti que les routines de tri utilisent les méthodes :meth:`__lt__` " | ||||
"lorsqu'elles effectuent des comparaisons entre deux objets. Donc il est " | ||||
"facile d'ajouter un ordre de tri standard à une classe en définissant sa " | ||||
"méthode :meth:`__lt__` ::" | ||||
| ||||
#: howto/sorting.rst:298 | ||||
#: howto/sorting.rst:338 | ||||
msgid "" | ||||
"Key functions need not depend directly on the objects being sorted. A key " | ||||
"function can also access external resources. For instance, if the student " | ||||
| | | |||
| | @ -5,7 +5,7 @@ msgid "" | |||
msgstr "" | ||||
"Project-Id-Version: Python 3\n" | ||||
"Report-Msgid-Bugs-To: \n" | ||||
"POT-Creation-Date: 2020-10-01 16:00+0200\n" | ||||
"POT-Creation-Date: 2021-09-23 16:16+0200\n" | ||||
"PO-Revision-Date: 2020-09-30 17:16+0200\n" | ||||
"Last-Translator: Melançon Victor <victor.melancon0@gmail.com>\n" | ||||
"Language-Team: FRENCH <traductions@lists.afpy.org>\n" | ||||
| | @ -1027,15 +1027,17 @@ msgid "Unicode filenames" | |||
msgstr "Noms de fichiers Unicode" | ||||
| ||||
#: howto/unicode.rst:606 | ||||
#, fuzzy | ||||
msgid "" | ||||
"Most of the operating systems in common use today support filenames that " | ||||
"contain arbitrary Unicode characters. Usually this is implemented by " | ||||
"converting the Unicode string into some encoding that varies depending on " | ||||
"the system. Today Python is converging on using UTF-8: Python on MacOS has " | ||||
"used UTF-8 for several versions, and Python 3.6 switched to using UTF-8 on " | ||||
"Windows as well. On Unix systems, there will only be a filesystem encoding " | ||||
"if you've set the ``LANG`` or ``LC_CTYPE`` environment variables; if you " | ||||
"haven't, the default encoding is again UTF-8." | ||||
"Windows as well. On Unix systems, there will only be a :term:`filesystem " | ||||
"encoding <filesystem encoding and error handler>`. if you've set the " | ||||
"``LANG`` or ``LC_CTYPE`` environment variables; if you haven't, the default " | ||||
"encoding is again UTF-8." | ||||
msgstr "" | ||||
"La plupart des systèmes d'exploitation couramment utilisés aujourd'hui " | ||||
"prennent en charge les noms de fichiers qui contiennent des caractères " | ||||
| | @ -1071,6 +1073,7 @@ msgstr "" | |||
"également les noms de fichiers Unicode." | ||||
| ||||
#: howto/unicode.rst:629 | ||||
#, fuzzy | ||||
msgid "" | ||||
"The :func:`os.listdir` function returns filenames, which raises an issue: " | ||||
"should it return the Unicode version of filenames, or should it return bytes " | ||||
| | @ -1079,8 +1082,8 @@ msgid "" | |||
"you pass a Unicode string as the path, filenames will be decoded using the " | ||||
"filesystem's encoding and a list of Unicode strings will be returned, while " | ||||
"passing a byte path will return the filenames as bytes. For example, " | ||||
"assuming the default filesystem encoding is UTF-8, running the following " | ||||
"program::" | ||||
"assuming the default :term:`filesystem encoding <filesystem encoding and " | ||||
"error handler>` is UTF-8, running the following program::" | ||||
msgstr "" | ||||
"La fonction :func:`os.listdir` renvoie des noms de fichiers, ce qui soulève " | ||||
"un problème : doit-elle renvoyer la version Unicode des noms de fichiers ou " | ||||
| | | |||
Loading…
Add table
Add a link
Reference in a new issue