From 76b5c8ea624381399659d98a915f836e1fc531c7 Mon Sep 17 00:00:00 2001 From: Julien Palard Date: Mon, 29 Nov 2021 14:13:01 +0100 Subject: [PATCH] Make merge (#1782) Co-authored-by: Christophe Nanteuil <35002064+christopheNan@users.noreply.github.com> --- Makefile | 2 +- c-api/iter.po | 33 +- c-api/typeobj.po | 16 +- extending/extending.po | 294 +++--- faq/library.po | 215 ++--- faq/programming.po | 5 +- glossary.po | 422 +++++---- howto/descriptor.po | 42 +- library/__main__.po | 12 +- library/asyncio-eventloop.po | 462 ++++----- library/asyncio-future.po | 98 +- library/asyncio-task.po | 292 +++--- library/audioop.po | 4 +- library/bz2.po | 4 +- library/codeop.po | 4 +- library/contextlib.po | 210 ++--- library/copy.po | 5 +- library/enum.po | 4 +- library/functions.po | 670 +++++++------- library/functools.po | 197 ++-- library/keyword.po | 19 +- library/sqlite3.po | 482 +++++----- library/stdtypes.po | 1644 +++++++++++++++++---------------- library/sys.po | 250 +++-- library/sysconfig.po | 140 +-- library/typing.po | 610 ++++++------ library/unittest.po | 5 +- reference/compound_stmts.po | 383 ++++---- reference/datamodel.po | 418 ++++++--- reference/executionmodel.po | 149 ++- reference/expressions.po | 603 ++++++------ reference/lexical_analysis.po | 12 +- tutorial/controlflow.po | 5 +- whatsnew/3.10.po | 3 +- whatsnew/3.9.po | 139 ++- 35 files changed, 4068 insertions(+), 3785 deletions(-) diff --git a/Makefile b/Makefile index 006187fd..51f0e5f2 100644 --- a/Makefile +++ b/Makefile @@ -20,7 +20,7 @@ # from which we generated our po files. We use it here so when we # test build, we're building with the .rst files that generated our # .po files. -CPYTHON_CURRENT_COMMIT := 75ed2ce9e86a7f213fa54e6f8cbbb3ab6f25b5a2 +CPYTHON_CURRENT_COMMIT := 57100c86baa8451a568348646834380cd425b858 LANGUAGE := fr BRANCH := 3.10 diff --git a/c-api/iter.po b/c-api/iter.po index 195bef5c..5a033377 100644 --- a/c-api/iter.po +++ b/c-api/iter.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2018-02-15 00:33+0100\n" "Last-Translator: Julien Palard \n" "Language-Team: FRENCH \n" @@ -25,8 +25,8 @@ msgstr "Il existe deux fonctions dédiées à l'interaction avec les itérateurs #: c-api/iter.rst:12 #, fuzzy msgid "" -"Return non-zero if the object *o* supports the iterator protocol, and ``0`` " -"otherwise. This function always succeeds." +"Return non-zero if the object *o* can be safely passed to :c:func:" +"`PyIter_Next`, and ``0`` otherwise. This function always succeeds." msgstr "Renvoie vrai si l'objet *o* supporte le protocole d'itération." #: c-api/iter.rst:17 @@ -39,10 +39,11 @@ msgstr "Renvoie vrai si l'objet *o* supporte le protocole d'itération." #: c-api/iter.rst:24 #, fuzzy msgid "" -"Return the next value from the iteration *o*. The object must be an " -"iterator (it is up to the caller to check this). If there are no remaining " -"values, returns ``NULL`` with no exception set. If an error occurs while " -"retrieving the item, returns ``NULL`` and passes along the exception." +"Return the next value from the iterator *o*. The object must be an iterator " +"according to :c:func:`PyIter_Check` (it is up to the caller to check this). " +"If there are no remaining values, returns ``NULL`` with no exception set. If " +"an error occurs while retrieving the item, returns ``NULL`` and passes along " +"the exception." msgstr "" "Renvoie la valeur suivante d'une itération de *o*. L'objet doit être un " "itérateur (c'est à l'appelant de faire cette vérification). Renvoie *NULL* " @@ -50,7 +51,7 @@ msgstr "" "déclarant une exception si une erreur survient lors de la récupération d'un " "élément." -#: c-api/iter.rst:29 +#: c-api/iter.rst:30 msgid "" "To write a loop which iterates over an iterator, the C code should look " "something like this::" @@ -58,27 +59,27 @@ msgstr "" "Pour écrire une boucle itérant un itérateur, le code C devrait ressembler " "à ::" -#: c-api/iter.rst:58 +#: c-api/iter.rst:59 msgid "" "The enum value used to represent different results of :c:func:`PyIter_Send`." msgstr "" -#: c-api/iter.rst:65 +#: c-api/iter.rst:66 msgid "Sends the *arg* value into the iterator *iter*. Returns:" msgstr "" -#: c-api/iter.rst:67 -msgid "" -"``PYGEN_RETURN`` if iterator returns. Return value is returned via *presult*." -msgstr "" - #: c-api/iter.rst:68 msgid "" -"``PYGEN_NEXT`` if iterator yields. Yielded value is returned via *presult*." +"``PYGEN_RETURN`` if iterator returns. Return value is returned via *presult*." msgstr "" #: c-api/iter.rst:69 msgid "" +"``PYGEN_NEXT`` if iterator yields. Yielded value is returned via *presult*." +msgstr "" + +#: c-api/iter.rst:70 +msgid "" "``PYGEN_ERROR`` if iterator has raised and exception. *presult* is set to " "``NULL``." msgstr "" diff --git a/c-api/typeobj.po b/c-api/typeobj.po index f50d54b8..711799c9 100644 --- a/c-api/typeobj.po +++ b/c-api/typeobj.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-11-04 18:14+0100\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: FRENCH \n" @@ -2282,9 +2282,9 @@ msgstr "" #: c-api/typeobj.rst:1523 msgid "" -"An optional pointer to a function that returns an iterator for the object. " -"Its presence normally signals that the instances of this type are iterable " -"(although sequences may be iterable without this function)." +"An optional pointer to a function that returns an :term:`iterator` for the " +"object. Its presence normally signals that the instances of this type are :" +"term:`iterable` (although sequences may be iterable without this function)." msgstr "" #: c-api/typeobj.rst:1527 @@ -2293,8 +2293,8 @@ msgstr "" #: c-api/typeobj.rst:1538 msgid "" -"An optional pointer to a function that returns the next item in an iterator. " -"The signature is::" +"An optional pointer to a function that returns the next item in an :term:" +"`iterator`. The signature is::" msgstr "" #: c-api/typeobj.rst:1543 @@ -3174,8 +3174,8 @@ msgstr "" #: c-api/typeobj.rst:2431 msgid "" -"The returned object must be an iterator, i.e. :c:func:`PyIter_Check` must " -"return ``1`` for it." +"The returned object must be an :term:`iterator`, i.e. :c:func:`PyIter_Check` " +"must return ``1`` for it." msgstr "" #: c-api/typeobj.rst:2434 diff --git a/extending/extending.po b/extending/extending.po index 7a7b2920..a754e4c6 100644 --- a/extending/extending.po +++ b/extending/extending.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-02-07 22:27+0100\n" "Last-Translator: Julien Palard \n" "Language-Team: FRENCH \n" @@ -230,18 +230,16 @@ msgid "Intermezzo: Errors and Exceptions" msgstr "Intermezzo : Les erreurs et les exceptions" #: extending/extending.rst:128 +#, fuzzy msgid "" "An important convention throughout the Python interpreter is the following: " "when a function fails, it should set an exception condition and return an " -"error value (usually a ``NULL`` pointer). Exceptions are stored in a static " -"global variable inside the interpreter; if this variable is ``NULL`` no " -"exception has occurred. A second global variable stores the \"associated " -"value\" of the exception (the second argument to :keyword:`raise`). A third " -"variable contains the stack traceback in case the error originated in Python " -"code. These three variables are the C equivalents of the result in Python " -"of :meth:`sys.exc_info` (see the section on module :mod:`sys` in the Python " -"Library Reference). It is important to know about them to understand how " -"errors are passed around." +"error value (usually ``-1`` or a ``NULL`` pointer). Exception information " +"is stored in three members of the interpreter's thread state. These are " +"``NULL`` if there is no exception. Otherwise they are the C equivalents of " +"the members of the Python tuple returned by :meth:`sys.exc_info`. These are " +"the exception type, exception instance, and a traceback object. It is " +"important to know about them to understand how errors are passed around." msgstr "" "Une convention primordiale imprégnant tout l'interpréteur Python est : quand " "une fonction échoue, elle devrait laisser une exception et renvoyer une " @@ -256,7 +254,7 @@ msgstr "" "Reference*). Il est important de les connaître pour comprendre comment les " "erreurs sont propagées." -#: extending/extending.rst:139 +#: extending/extending.rst:137 msgid "" "The Python API defines a number of functions to set various types of " "exceptions." @@ -264,7 +262,7 @@ msgstr "" "L'API Python définit un certain nombre de fonctions pour créer différents " "types d'exceptions." -#: extending/extending.rst:141 +#: extending/extending.rst:139 msgid "" "The most common one is :c:func:`PyErr_SetString`. Its arguments are an " "exception object and a C string. The exception object is usually a " @@ -278,7 +276,7 @@ msgstr "" "cause de l'erreur et est convertie en une chaîne Python puis stockée en tant " "que \"valeur associée\" à l'exception." -#: extending/extending.rst:147 +#: extending/extending.rst:145 msgid "" "Another useful function is :c:func:`PyErr_SetFromErrno`, which only takes an " "exception argument and constructs the associated value by inspection of the " @@ -293,7 +291,7 @@ msgstr "" "arguments : l'exception et sa valeur associée. Vous ne devez pas appliquer :" "c:func:`Py_INCREF` aux objets transmis à ces fonctions." -#: extending/extending.rst:154 +#: extending/extending.rst:152 msgid "" "You can test non-destructively whether an exception has been set with :c:" "func:`PyErr_Occurred`. This returns the current exception object, or " @@ -308,7 +306,7 @@ msgstr "" "survenue durant l'appel d'une fonction, puisque vous devriez être en mesure " "de le déterminer à partir de la valeur renvoyée." -#: extending/extending.rst:160 +#: extending/extending.rst:158 #, fuzzy msgid "" "When a function *f* that calls another function *g* detects that the latter " @@ -334,7 +332,7 @@ msgstr "" "interrompt le code en cours d'exécution et essaie de trouver un gestionnaire " "d'exception spécifié par le développeur Python." -#: extending/extending.rst:170 +#: extending/extending.rst:168 msgid "" "(There are situations where a module can actually give a more detailed error " "message by calling another :c:func:`PyErr_\\*` function, and in such cases " @@ -349,7 +347,7 @@ msgstr "" "sur la cause de l'erreur : la plupart des opérations peuvent échouer pour " "tout un tas de raisons.)" -#: extending/extending.rst:176 +#: extending/extending.rst:174 msgid "" "To ignore an exception set by a function call that failed, the exception " "condition must be cleared explicitly by calling :c:func:`PyErr_Clear`. The " @@ -364,7 +362,7 @@ msgstr "" "l'interpréteur, mais souhaite la gérer lui-même (peut-être en essayant " "quelque chose d'autre, ou en prétendant que rien n'a mal tourné)." -#: extending/extending.rst:182 +#: extending/extending.rst:180 msgid "" "Every failing :c:func:`malloc` call must be turned into an exception --- the " "direct caller of :c:func:`malloc` (or :c:func:`realloc`) must call :c:func:" @@ -379,7 +377,7 @@ msgstr "" "`PyLong_FromLong`) le font déjà, donc cette note ne concerne que ceux qui " "appellent :c:func:`malloc` directement." -#: extending/extending.rst:188 +#: extending/extending.rst:186 msgid "" "Also note that, with the important exception of :c:func:`PyArg_ParseTuple` " "and friends, functions that return an integer status usually return a " @@ -391,7 +389,7 @@ msgstr "" "donnent généralement une valeur positive ou zéro en cas de succès et ``-1`` " "en cas d'échec, comme les appels du système Unix." -#: extending/extending.rst:192 +#: extending/extending.rst:190 msgid "" "Finally, be careful to clean up garbage (by making :c:func:`Py_XDECREF` or :" "c:func:`Py_DECREF` calls for objects you have already created) when you " @@ -401,7 +399,7 @@ msgstr "" "de nettoyage (en appelant :c:func:`Py_XDECREF` ou :c:func:`Py_DECREF` avec " "les objets que vous auriez déjà créés) !" -#: extending/extending.rst:196 +#: extending/extending.rst:194 msgid "" "The choice of which exception to raise is entirely yours. There are " "predeclared C objects corresponding to all built-in Python exceptions, such " @@ -425,7 +423,7 @@ msgstr "" "satisfaire d'autres conditions, :c:data:`PyExc_ValueError` sera plus " "appropriée." -#: extending/extending.rst:206 +#: extending/extending.rst:204 msgid "" "You can also define a new exception that is unique to your module. For this, " "you usually declare a static object variable at the beginning of your file::" @@ -433,7 +431,7 @@ msgstr "" "Vous pouvez également créer une exception spécifique à votre module. Pour " "cela, déclarez simplement une variable statique au début de votre fichier ::" -#: extending/extending.rst:211 +#: extending/extending.rst:209 msgid "" "and initialize it in your module's initialization function (:c:func:" "`PyInit_spam`) with an exception object::" @@ -441,7 +439,7 @@ msgstr "" "et initialisez-la dans la fonction d'initialisation de votre module (:c:func:" "`PyInit_spam`) avec un objet exception ::" -#: extending/extending.rst:235 +#: extending/extending.rst:233 msgid "" "Note that the Python name for the exception object is :exc:`spam.error`. " "The :c:func:`PyErr_NewException` function may create a class with the base " @@ -453,7 +451,7 @@ msgstr "" "`Exception` (à moins qu'une autre classe ne lui soit fournie à la place de " "``NULL``), voir :ref:`bltin-exceptions`." -#: extending/extending.rst:240 +#: extending/extending.rst:238 msgid "" "Note also that the :c:data:`SpamError` variable retains a reference to the " "newly created exception class; this is intentional! Since the exception " @@ -471,7 +469,7 @@ msgstr "" "code qui lève cette exception peut engendrer un *core dump* ou des effets " "secondaires inattendus." -#: extending/extending.rst:247 +#: extending/extending.rst:245 msgid "" "We discuss the use of ``PyMODINIT_FUNC`` as a function return type later in " "this sample." @@ -479,7 +477,7 @@ msgstr "" "Nous traiterons de l'utilisation de ``PyMODINIT_FUNC`` comme un type de " "renvoi de fonction plus tard dans cette section." -#: extending/extending.rst:250 +#: extending/extending.rst:248 msgid "" "The :exc:`spam.error` exception can be raised in your extension module using " "a call to :c:func:`PyErr_SetString` as shown below::" @@ -487,11 +485,11 @@ msgstr "" "L'exception :exc:`spam.error` peut être levée dans votre module d'extension " "en appelant :c:func:`PyErr_SetString` comme montré ci-dessous ::" -#: extending/extending.rst:273 +#: extending/extending.rst:271 msgid "Back to the Example" msgstr "Retour vers l'exemple" -#: extending/extending.rst:275 +#: extending/extending.rst:273 msgid "" "Going back to our example function, you should now be able to understand " "this statement::" @@ -499,7 +497,7 @@ msgstr "" "En revenant vers notre fonction exemple, vous devriez maintenant être " "capable de comprendre cette affirmation ::" -#: extending/extending.rst:281 +#: extending/extending.rst:279 msgid "" "It returns ``NULL`` (the error indicator for functions returning object " "pointers) if an error is detected in the argument list, relying on the " @@ -518,7 +516,7 @@ msgstr "" "Standard, la variable :c:data:`command` doit être clairement déclarée comme " "``const char *command``)." -#: extending/extending.rst:289 +#: extending/extending.rst:287 msgid "" "The next statement is a call to the Unix function :c:func:`system`, passing " "it the string we just got from :c:func:`PyArg_ParseTuple`::" @@ -527,7 +525,7 @@ msgstr "" "en lui passant la chaîne que nous venons d'obtenir à partir de :c:func:" "`PyArg_ParseTuple` ::" -#: extending/extending.rst:294 +#: extending/extending.rst:292 msgid "" "Our :func:`spam.system` function must return the value of :c:data:`sts` as a " "Python object. This is done using the function :c:func:`PyLong_FromLong`. ::" @@ -536,7 +534,7 @@ msgstr "" "comme un objet Python. Cela est effectué par l'utilisation de la fonction :c:" "func:`PyLong_FromLong`. ::" -#: extending/extending.rst:299 +#: extending/extending.rst:297 msgid "" "In this case, it will return an integer object. (Yes, even integers are " "objects on the heap in Python!)" @@ -544,7 +542,7 @@ msgstr "" "Dans ce cas, elle renverra un objet entier. (Oui, même les entiers sont des " "objets dans le tas en Python !)" -#: extending/extending.rst:302 +#: extending/extending.rst:300 msgid "" "If you have a C function that returns no useful argument (a function " "returning :c:type:`void`), the corresponding Python function must return " @@ -556,7 +554,7 @@ msgstr "" "renvoyer ``None``. Vous aurez besoin de cette locution pour cela (qui est " "implémentée par la macro :c:macro:`Py_RETURN_NONE`) ::" -#: extending/extending.rst:310 +#: extending/extending.rst:308 msgid "" ":c:data:`Py_None` is the C name for the special Python object ``None``. It " "is a genuine Python object rather than a ``NULL`` pointer, which means " @@ -567,11 +565,11 @@ msgstr "" "qui signifie qu'une erreur est survenue, dans la plupart des situations, " "comme nous l'avons vu." -#: extending/extending.rst:318 +#: extending/extending.rst:316 msgid "The Module's Method Table and Initialization Function" msgstr "La fonction d'initialisation et le tableau des méthodes du module" -#: extending/extending.rst:320 +#: extending/extending.rst:318 msgid "" "I promised to show how :c:func:`spam_system` is called from Python programs. " "First, we need to list its name and address in a \"method table\"::" @@ -580,7 +578,7 @@ msgstr "" "depuis les programmes Python. D'abord, nous avons besoin d'avoir son nom et " "son adresse dans un « tableau des méthodes » ::" -#: extending/extending.rst:331 +#: extending/extending.rst:329 msgid "" "Note the third entry (``METH_VARARGS``). This is a flag telling the " "interpreter the calling convention to be used for the C function. It should " @@ -594,7 +592,7 @@ msgstr "" "METH_KEYWORDS`` ; la valeur ``0`` indique qu'une variante obsolète de :c:" "func:`PyArg_ParseTuple` est utilisée." -#: extending/extending.rst:336 +#: extending/extending.rst:334 msgid "" "When using only ``METH_VARARGS``, the function should expect the Python-" "level parameters to be passed in as a tuple acceptable for parsing via :c:" @@ -605,7 +603,7 @@ msgstr "" "*via* :c:func:`PyArg_ParseTuple` ; des informations supplémentaires sont " "fournies plus bas." -#: extending/extending.rst:340 +#: extending/extending.rst:338 msgid "" "The :const:`METH_KEYWORDS` bit may be set in the third field if keyword " "arguments should be passed to the function. In this case, the C function " @@ -619,14 +617,14 @@ msgstr "" "dictionnaire des mots-clés. Utilisez :c:func:`PyArg_ParseTupleAndKeywords` " "pour analyser les arguments d'une telle fonction." -#: extending/extending.rst:346 +#: extending/extending.rst:344 msgid "" "The method table must be referenced in the module definition structure::" msgstr "" "Le tableau des méthodes doit être référencé dans la structure de définition " "du module ::" -#: extending/extending.rst:357 +#: extending/extending.rst:355 msgid "" "This structure, in turn, must be passed to the interpreter in the module's " "initialization function. The initialization function must be named :c:func:" @@ -638,7 +636,7 @@ msgstr "" "nommée :c:func:`PyInit_name`, où *nom* est le nom du module, et doit être le " "seul élément non ``static`` défini dans le fichier du module ::" -#: extending/extending.rst:368 +#: extending/extending.rst:366 msgid "" "Note that PyMODINIT_FUNC declares the function as ``PyObject *`` return " "type, declares any special linkage declarations required by the platform, " @@ -649,7 +647,7 @@ msgstr "" "spéciale requise par la plate-forme, et pour le C++ déclare la fonction " "comme un C ``extern``." -#: extending/extending.rst:372 +#: extending/extending.rst:370 msgid "" "When the Python program imports module :mod:`spam` for the first time, :c:" "func:`PyInit_spam` is called. (See below for comments about embedding " @@ -674,7 +672,7 @@ msgstr "" "manière satisfaisante. La fonction `*init* doit renvoyer l'objet module à " "son appelant, afin qu'il soit ensuite inséré dans ``sys.modules``." -#: extending/extending.rst:383 +#: extending/extending.rst:381 msgid "" "When embedding Python, the :c:func:`PyInit_spam` function is not called " "automatically unless there's an entry in the :c:data:`PyImport_Inittab` " @@ -687,7 +685,7 @@ msgstr "" "utilisez :c:func:`PyImport_AppendInittab`, suivi éventuellement d'une " "importation du module ::" -#: extending/extending.rst:427 +#: extending/extending.rst:425 msgid "" "Removing entries from ``sys.modules`` or importing compiled modules into " "multiple interpreters within a process (or following a :c:func:`fork` " @@ -702,7 +700,7 @@ msgstr "" "doivent faire preuve de prudence lorsqu'ils initialisent des structures de " "données internes." -#: extending/extending.rst:433 +#: extending/extending.rst:431 msgid "" "A more substantial example module is included in the Python source " "distribution as :file:`Modules/xxmodule.c`. This file may be used as a " @@ -712,7 +710,7 @@ msgstr "" "sources Python sous le nom :file:`Modules/xxmodule.c`. Ce fichier peut être " "utilisé comme modèle ou simplement lu comme exemple." -#: extending/extending.rst:439 +#: extending/extending.rst:437 msgid "" "Unlike our ``spam`` example, ``xxmodule`` uses *multi-phase initialization* " "(new in Python 3.5), where a PyModuleDef structure is returned from " @@ -725,11 +723,11 @@ msgstr "" "module est laissée au mécanisme d'importation. Pour plus de détails sur " "l'initialisation multi-phase, voir :PEP:`489`." -#: extending/extending.rst:448 +#: extending/extending.rst:446 msgid "Compilation and Linkage" msgstr "Compilation et liaison" -#: extending/extending.rst:450 +#: extending/extending.rst:448 msgid "" "There are two more things to do before you can use your new extension: " "compiling and linking it with the Python system. If you use dynamic " @@ -739,7 +737,7 @@ msgid "" "Windows (chapter :ref:`building-on-windows`) for more information about this." msgstr "" -#: extending/extending.rst:457 +#: extending/extending.rst:455 msgid "" "If you can't use dynamic loading, or if you want to make your module a " "permanent part of the Python interpreter, you will have to change the " @@ -749,7 +747,7 @@ msgid "" "line to the file :file:`Modules/Setup.local` describing your file:" msgstr "" -#: extending/extending.rst:468 +#: extending/extending.rst:466 msgid "" "and rebuild the interpreter by running :program:`make` in the toplevel " "directory. You can also run :program:`make` in the :file:`Modules/` " @@ -758,17 +756,17 @@ msgid "" "the :file:`Setup` file.)" msgstr "" -#: extending/extending.rst:474 +#: extending/extending.rst:472 msgid "" "If your module requires additional libraries to link with, these can be " "listed on the line in the configuration file as well, for instance:" msgstr "" -#: extending/extending.rst:485 +#: extending/extending.rst:483 msgid "Calling Python Functions from C" msgstr "Appeler des fonctions Python en C" -#: extending/extending.rst:487 +#: extending/extending.rst:485 msgid "" "So far we have concentrated on making C functions callable from Python. The " "reverse is also useful: calling Python functions from C. This is especially " @@ -779,7 +777,7 @@ msgid "" "uses are also imaginable." msgstr "" -#: extending/extending.rst:495 +#: extending/extending.rst:493 msgid "" "Fortunately, the Python interpreter is easily called recursively, and there " "is a standard interface to call a Python function. (I won't dwell on how to " @@ -788,7 +786,7 @@ msgid "" "line option in :file:`Modules/main.c` from the Python source code.)" msgstr "" -#: extending/extending.rst:501 +#: extending/extending.rst:499 msgid "" "Calling a Python function is easy. First, the Python program must somehow " "pass you the Python function object. You should provide a function (or some " @@ -798,7 +796,7 @@ msgid "" "function might be part of a module definition::" msgstr "" -#: extending/extending.rst:531 +#: extending/extending.rst:529 msgid "" "This function must be registered with the interpreter using the :const:" "`METH_VARARGS` flag; this is described in section :ref:`methodtable`. The :" @@ -810,7 +808,7 @@ msgstr "" "fonction :c:func:`PyArg_ParseTuple` et ses arguments sont documentés dans la " "section :ref:`parsetuple`." -#: extending/extending.rst:536 +#: extending/extending.rst:534 msgid "" "The macros :c:func:`Py_XINCREF` and :c:func:`Py_XDECREF` increment/decrement " "the reference count of an object and are safe in the presence of ``NULL`` " @@ -823,7 +821,7 @@ msgstr "" "dans ce contexte). Plus d'informations à ce sujet dans la section :ref:" "`refcounts`." -#: extending/extending.rst:543 +#: extending/extending.rst:541 msgid "" "Later, when it is time to call the function, you call the C function :c:func:" "`PyObject_CallObject`. This function has two arguments, both pointers to " @@ -835,7 +833,7 @@ msgid "" "or more format codes between parentheses. For example::" msgstr "" -#: extending/extending.rst:563 +#: extending/extending.rst:561 msgid "" ":c:func:`PyObject_CallObject` returns a Python object pointer: this is the " "return value of the Python function. :c:func:`PyObject_CallObject` is " @@ -844,7 +842,7 @@ msgid "" "`Py_DECREF`\\ -ed immediately after the :c:func:`PyObject_CallObject` call." msgstr "" -#: extending/extending.rst:570 +#: extending/extending.rst:568 msgid "" "The return value of :c:func:`PyObject_CallObject` is \"new\": either it is a " "brand new object, or it is an existing object whose reference count has been " @@ -853,7 +851,7 @@ msgid "" "not interested in its value." msgstr "" -#: extending/extending.rst:576 +#: extending/extending.rst:574 msgid "" "Before you do this, however, it is important to check that the return value " "isn't ``NULL``. If it is, the Python function terminated by raising an " @@ -873,7 +871,7 @@ msgstr "" "souhaitable, l'exception doit être effacée en appelant :c:func:" "`PyErr_Clear`. Par exemple ::" -#: extending/extending.rst:589 +#: extending/extending.rst:587 msgid "" "Depending on the desired interface to the Python callback function, you may " "also have to provide an argument list to :c:func:`PyObject_CallObject`. In " @@ -895,7 +893,7 @@ msgstr "" "`Py_BuildValue`. Par exemple, si vous voulez passer un code d'événement " "intégral, vous pouvez utiliser le code suivant ::" -#: extending/extending.rst:608 +#: extending/extending.rst:606 msgid "" "Note the placement of ``Py_DECREF(arglist)`` immediately after the call, " "before the error check! Also note that strictly speaking this code is not " @@ -903,7 +901,7 @@ msgid "" "checked." msgstr "" -#: extending/extending.rst:612 +#: extending/extending.rst:610 msgid "" "You may also call a function with keyword arguments by using :c:func:" "`PyObject_Call`, which supports arguments and keyword arguments. As in the " @@ -914,15 +912,15 @@ msgstr "" "arguments nommés. Comme dans l'exemple ci-dessus, nous utilisons :c:func:" "`Py_BuildValue` pour construire le dictionnaire. ::" -#: extending/extending.rst:630 +#: extending/extending.rst:628 msgid "Extracting Parameters in Extension Functions" msgstr "Extraire des paramètres dans des fonctions d'extension" -#: extending/extending.rst:634 +#: extending/extending.rst:632 msgid "The :c:func:`PyArg_ParseTuple` function is declared as follows::" msgstr "La fonction :c:func:`PyArg_ParseTuple` est déclarée ainsi ::" -#: extending/extending.rst:638 +#: extending/extending.rst:636 msgid "" "The *arg* argument must be a tuple object containing an argument list passed " "from Python to a C function. The *format* argument must be a format string, " @@ -931,7 +929,7 @@ msgid "" "whose type is determined by the format string." msgstr "" -#: extending/extending.rst:644 +#: extending/extending.rst:642 msgid "" "Note that while :c:func:`PyArg_ParseTuple` checks that the Python arguments " "have the required types, it cannot check the validity of the addresses of C " @@ -939,7 +937,7 @@ msgid "" "probably crash or at least overwrite random bits in memory. So be careful!" msgstr "" -#: extending/extending.rst:649 +#: extending/extending.rst:647 msgid "" "Note that any Python object references which are provided to the caller are " "*borrowed* references; do not decrement their reference count!" @@ -948,21 +946,21 @@ msgstr "" "à l'appelant sont des références *empruntées* ; ne décrémentez pas leur " "compteur de références !" -#: extending/extending.rst:652 +#: extending/extending.rst:650 msgid "Some example calls::" msgstr "Quelques exemples d'appels ::" -#: extending/extending.rst:722 +#: extending/extending.rst:720 msgid "Keyword Parameters for Extension Functions" msgstr "Paramètres nommés pour des fonctions d'extension" -#: extending/extending.rst:726 +#: extending/extending.rst:724 msgid "" "The :c:func:`PyArg_ParseTupleAndKeywords` function is declared as follows::" msgstr "" "La fonction :c:func:`PyArg_ParseTupleAndKeywords` est déclarée ainsi ::" -#: extending/extending.rst:731 +#: extending/extending.rst:729 msgid "" "The *arg* and *format* parameters are identical to those of the :c:func:" "`PyArg_ParseTuple` function. The *kwdict* parameter is the dictionary of " @@ -982,7 +980,7 @@ msgstr "" "processus, :c:func:`PyArg_ParseTupleAndKeywords` renvoie vrai, sinon il " "renvoie faux et lève une exception appropriée." -#: extending/extending.rst:741 +#: extending/extending.rst:739 msgid "" "Nested tuples cannot be parsed when using keyword arguments! Keyword " "parameters passed in which are not present in the *kwlist* will cause :exc:" @@ -992,7 +990,7 @@ msgstr "" "arguments de type mot-clé ! Ceux-ci doivent apparaître dans dans *kwlist*, " "dans le cas contraire une exception :exc:`TypeError` est levée." -#: extending/extending.rst:747 +#: extending/extending.rst:745 msgid "" "Here is an example module which uses keywords, based on an example by Geoff " "Philbrick (philbrick@hks.com)::" @@ -1000,11 +998,11 @@ msgstr "" "Voici un exemple de module qui utilise des mots-clés, basé sur un exemple de " "*Geoff Philbrick* (philbrick@hks.com) ::" -#: extending/extending.rst:802 +#: extending/extending.rst:800 msgid "Building Arbitrary Values" msgstr "Créer des valeurs arbitraires" -#: extending/extending.rst:804 +#: extending/extending.rst:802 msgid "" "This function is the counterpart to :c:func:`PyArg_ParseTuple`. It is " "declared as follows::" @@ -1012,7 +1010,7 @@ msgstr "" "Cette fonction est le complément de :c:func:`PyArg_ParseTuple`. Elle est " "déclarée comme suit ::" -#: extending/extending.rst:809 +#: extending/extending.rst:807 msgid "" "It recognizes a set of format units similar to the ones recognized by :c:" "func:`PyArg_ParseTuple`, but the arguments (which are input to the function, " @@ -1025,7 +1023,7 @@ msgstr "" "mais juste des valeurs. Il renvoie un nouvel objet Python, adapté pour être " "renvoyé par une fonction C appelée depuis Python." -#: extending/extending.rst:814 +#: extending/extending.rst:812 #, fuzzy msgid "" "One difference with :c:func:`PyArg_ParseTuple`: while the latter requires " @@ -1041,17 +1039,17 @@ msgstr "" "dernier nécessite que son premier argument soit un *n*-uplet (puisque les " "listes d'arguments Python sont toujours représentées par des *n*-uplets en " -#: extending/extending.rst:822 +#: extending/extending.rst:820 msgid "" "Examples (to the left the call, to the right the resulting Python value):" msgstr "" "Exemples (à gauche l'appel, à droite la valeur résultante, en Python) :" -#: extending/extending.rst:848 +#: extending/extending.rst:846 msgid "Reference Counts" msgstr "Compteurs de références" -#: extending/extending.rst:850 +#: extending/extending.rst:848 msgid "" "In languages like C or C++, the programmer is responsible for dynamic " "allocation and deallocation of memory on the heap. In C, this is done using " @@ -1066,7 +1064,7 @@ msgstr "" "essentiellement la même signification et nous limiterons la discussion " "suivante au cas du C." -#: extending/extending.rst:856 +#: extending/extending.rst:854 msgid "" "Every block of memory allocated with :c:func:`malloc` should eventually be " "returned to the pool of available memory by exactly one call to :c:func:" @@ -1081,7 +1079,7 @@ msgid "" "crashes." msgstr "" -#: extending/extending.rst:867 +#: extending/extending.rst:865 msgid "" "Common causes of memory leaks are unusual paths through the code. For " "instance, a function may allocate a block of memory, do some calculation, " @@ -1098,7 +1096,7 @@ msgid "" "of errors." msgstr "" -#: extending/extending.rst:880 +#: extending/extending.rst:878 msgid "" "Since Python makes heavy use of :c:func:`malloc` and :c:func:`free`, it " "needs a strategy to avoid memory leaks as well as the use of freed memory. " @@ -1117,7 +1115,7 @@ msgstr "" "supprimée. Lorsque le compteur atteint zéro, la dernière référence à l'objet " "a été supprimée et l'objet est libéré." -#: extending/extending.rst:888 +#: extending/extending.rst:886 msgid "" "An alternative strategy is called :dfn:`automatic garbage collection`. " "(Sometimes, reference counting is also referred to as a garbage collection " @@ -1146,7 +1144,7 @@ msgstr "" "ramasse-miettes suffisamment portable sera disponible pour C. D'ici là, nous " "devrons utiliser les compteurs des références." -#: extending/extending.rst:900 +#: extending/extending.rst:898 msgid "" "While Python uses the traditional reference counting implementation, it also " "offers a cycle detector that works to detect reference cycles. This allows " @@ -1172,7 +1170,7 @@ msgstr "" "référencés à partir des objets dans le cycle, même s'il n'y a pas d'autres " "références au cycle lui-même." -#: extending/extending.rst:911 +#: extending/extending.rst:909 msgid "" "The cycle detector is able to detect garbage cycles and can reclaim them. " "The :mod:`gc` module exposes a way to run the detector (the :func:`~gc." @@ -1180,11 +1178,11 @@ msgid "" "disable the detector at runtime." msgstr "" -#: extending/extending.rst:920 +#: extending/extending.rst:918 msgid "Reference Counting in Python" msgstr "Comptage de références en Python" -#: extending/extending.rst:922 +#: extending/extending.rst:920 msgid "" "There are two macros, ``Py_INCREF(x)`` and ``Py_DECREF(x)``, which handle " "the incrementing and decrementing of the reference count. :c:func:" @@ -1202,7 +1200,7 @@ msgstr "" "objet` de l'objet. À cette fin (et pour d'autres), chaque objet contient " "également un pointeur vers son objet type." -#: extending/extending.rst:929 +#: extending/extending.rst:927 msgid "" "The big question now remains: when to use ``Py_INCREF(x)`` and " "``Py_DECREF(x)``? Let's first introduce some terms. Nobody \"owns\" an " @@ -1225,7 +1223,7 @@ msgstr "" "c:func:`Py_DECREF`. Oublier de se débarrasser d'une référence crée une fuite " "de mémoire." -#: extending/extending.rst:938 +#: extending/extending.rst:936 msgid "" "It is also possible to :dfn:`borrow` [#]_ a reference to an object. The " "borrower of a reference should not call :c:func:`Py_DECREF`. The borrower " @@ -1234,7 +1232,7 @@ msgid "" "risks using freed memory and should be avoided completely [#]_." msgstr "" -#: extending/extending.rst:944 +#: extending/extending.rst:942 msgid "" "The advantage of borrowing over owning a reference is that you don't need to " "take care of disposing of the reference on all possible paths through the " @@ -1253,7 +1251,7 @@ msgstr "" "correct, une référence empruntée peut être utilisée après que le " "propriétaire auquel elle a été empruntée l'a en fait éliminée." -#: extending/extending.rst:952 +#: extending/extending.rst:950 msgid "" "A borrowed reference can be changed into an owned reference by calling :c:" "func:`Py_INCREF`. This does not affect the status of the owner from which " @@ -1262,11 +1260,11 @@ msgid "" "properly, as well as the previous owner)." msgstr "" -#: extending/extending.rst:962 +#: extending/extending.rst:960 msgid "Ownership Rules" msgstr "Règles concernant la propriété de références" -#: extending/extending.rst:964 +#: extending/extending.rst:962 msgid "" "Whenever an object reference is passed into or out of a function, it is part " "of the function's interface specification whether ownership is transferred " @@ -1277,7 +1275,7 @@ msgstr "" "l'interface de la fonction, peu importe que la propriété soit transférée " "avec la référence ou non." -#: extending/extending.rst:968 +#: extending/extending.rst:966 msgid "" "Most functions that return a reference to an object pass on ownership with " "the reference. In particular, all functions whose function it is to create " @@ -1288,7 +1286,7 @@ msgid "" "reference to a cached item." msgstr "" -#: extending/extending.rst:976 +#: extending/extending.rst:974 msgid "" "Many functions that extract objects from other objects also transfer " "ownership with the reference, for instance :c:func:" @@ -1299,14 +1297,14 @@ msgid "" "list or dictionary." msgstr "" -#: extending/extending.rst:983 +#: extending/extending.rst:981 msgid "" "The function :c:func:`PyImport_AddModule` also returns a borrowed reference, " "even though it may actually create the object it returns: this is possible " "because an owned reference to the object is stored in ``sys.modules``." msgstr "" -#: extending/extending.rst:987 +#: extending/extending.rst:985 msgid "" "When you pass an object reference into another function, in general, the " "function borrows the reference from you --- if it needs to store it, it will " @@ -1317,7 +1315,7 @@ msgid "" "don't take over ownership --- they are \"normal.\")" msgstr "" -#: extending/extending.rst:995 +#: extending/extending.rst:993 msgid "" "When a C function is called from Python, it borrows references to its " "arguments from the caller. The caller owns a reference to the object, so " @@ -1326,18 +1324,18 @@ msgid "" "turned into an owned reference by calling :c:func:`Py_INCREF`." msgstr "" -#: extending/extending.rst:1001 +#: extending/extending.rst:999 msgid "" "The object reference returned from a C function that is called from Python " "must be an owned reference --- ownership is transferred from the function to " "its caller." msgstr "" -#: extending/extending.rst:1009 +#: extending/extending.rst:1007 msgid "Thin Ice" msgstr "Terrain dangereux" -#: extending/extending.rst:1011 +#: extending/extending.rst:1009 msgid "" "There are a few situations where seemingly harmless use of a borrowed " "reference can lead to problems. These all have to do with implicit " @@ -1349,7 +1347,7 @@ msgstr "" "lien avec des invocations implicites de l’interpréteur, et peuvent amener le " "propriétaire d'une référence à s'en défaire." -#: extending/extending.rst:1015 +#: extending/extending.rst:1013 msgid "" "The first and most important case to know about is using :c:func:`Py_DECREF` " "on an unrelated object while borrowing a reference to a list item. For " @@ -1359,7 +1357,7 @@ msgstr "" "de :c:func:`Py_DECREF` à un objet non relié, tout en empruntant une " "référence à un élément de liste. Par exemple ::" -#: extending/extending.rst:1027 +#: extending/extending.rst:1025 msgid "" "This function first borrows a reference to ``list[0]``, then replaces " "``list[1]`` with the value ``0``, and finally prints the borrowed reference. " @@ -1369,7 +1367,7 @@ msgstr "" "``list[1]`` par la valeur ``0``, et enfin affiche la référence empruntée. " "Ça a l'air inoffensif, n'est-ce pas ? Mais ce n'est pas le cas !" -#: extending/extending.rst:1031 +#: extending/extending.rst:1029 msgid "" "Let's follow the control flow into :c:func:`PyList_SetItem`. The list owns " "references to all its items, so when item 1 is replaced, it has to dispose " @@ -1386,7 +1384,7 @@ msgstr "" "meth:`__del__`. Si l'instance de cette classe a un nombre des références de " "1, sa destruction appellera sa méthode :meth:`__del__`." -#: extending/extending.rst:1038 +#: extending/extending.rst:1036 msgid "" "Since it is written in Python, the :meth:`__del__` method can execute " "arbitrary Python code. Could it perhaps do something to invalidate the " @@ -1404,20 +1402,20 @@ msgstr "" "supposant que ce soit la dernière référence à cet objet, elle libérerait la " "mémoire qui lui est associée, invalidant ainsi ``item``." -#: extending/extending.rst:1046 +#: extending/extending.rst:1044 msgid "" "The solution, once you know the source of the problem, is easy: temporarily " "increment the reference count. The correct version of the function reads::" msgstr "" -#: extending/extending.rst:1060 +#: extending/extending.rst:1058 msgid "" "This is a true story. An older version of Python contained variants of this " "bug and someone spent a considerable amount of time in a C debugger to " "figure out why his :meth:`__del__` methods would fail..." msgstr "" -#: extending/extending.rst:1064 +#: extending/extending.rst:1062 msgid "" "The second case of problems with a borrowed reference is a variant involving " "threads. Normally, multiple threads in the Python interpreter can't get in " @@ -1440,11 +1438,11 @@ msgstr "" "processeur en attendant que les E/S soient terminées. Évidemment, la " "fonction suivante a le même problème que la précédente ::" -#: extending/extending.rst:1087 +#: extending/extending.rst:1085 msgid "NULL Pointers" msgstr "Pointeurs ``NULL``" -#: extending/extending.rst:1089 +#: extending/extending.rst:1087 msgid "" "In general, functions that take object references as arguments do not expect " "you to pass them ``NULL`` pointers, and will dump core (or cause later core " @@ -1466,7 +1464,7 @@ msgstr "" "devait tester pour ``NULL``, il y aurait beaucoup de tests redondants et le " "code s'exécuterait plus lentement." -#: extending/extending.rst:1097 +#: extending/extending.rst:1095 msgid "" "It is better to test for ``NULL`` only at the \"source:\" when a pointer " "that may be ``NULL`` is received, for example, from :c:func:`malloc` or from " @@ -1476,7 +1474,7 @@ msgstr "" "lorsqu'un pointeur qui peut être ``NULL`` est reçu, par exemple, de :c:func:" "`malloc` ou d'une fonction qui peut lever une exception." -#: extending/extending.rst:1101 +#: extending/extending.rst:1099 msgid "" "The macros :c:func:`Py_INCREF` and :c:func:`Py_DECREF` do not check for " "``NULL`` pointers --- however, their variants :c:func:`Py_XINCREF` and :c:" @@ -1486,7 +1484,7 @@ msgstr "" "pointeurs ``NULL``. Cependant, leurs variantes :c:func:`Py_XINCREF` et :c:" "func:`Py_XDECREF` le font." -#: extending/extending.rst:1105 +#: extending/extending.rst:1103 msgid "" "The macros for checking for a particular object type (``Pytype_Check()``) " "don't check for ``NULL`` pointers --- again, there is much code that calls " @@ -1495,7 +1493,7 @@ msgid "" "variants with ``NULL`` checking." msgstr "" -#: extending/extending.rst:1111 +#: extending/extending.rst:1109 msgid "" "The C function calling mechanism guarantees that the argument list passed to " "C functions (``args`` in the examples) is never ``NULL`` --- in fact it " @@ -1505,7 +1503,7 @@ msgstr "" "aux fonctions C (``args`` dans les exemples) n'est jamais ``NULL``. En fait, " "il garantit qu'il s'agit toujours d'un n-uplet [#]_." -#: extending/extending.rst:1115 +#: extending/extending.rst:1113 msgid "" "It is a severe error to ever let a ``NULL`` pointer \"escape\" to the Python " "user." @@ -1513,11 +1511,11 @@ msgstr "" "C'est une grave erreur de laisser un pointeur ``NULL`` \"échapper\" à " "l'utilisateur Python." -#: extending/extending.rst:1126 +#: extending/extending.rst:1124 msgid "Writing Extensions in C++" msgstr "Écrire des extensions en C++" -#: extending/extending.rst:1128 +#: extending/extending.rst:1126 msgid "" "It is possible to write extension modules in C++. Some restrictions apply. " "If the main program (the Python interpreter) is compiled and linked by the C " @@ -1541,11 +1539,11 @@ msgstr "" "``__cplusplus`` est défini (tous les compilateurs C++ récents définissent ce " "symbole)." -#: extending/extending.rst:1142 +#: extending/extending.rst:1140 msgid "Providing a C API for an Extension Module" msgstr "Fournir une API en langage C pour un module d'extension" -#: extending/extending.rst:1147 +#: extending/extending.rst:1145 msgid "" "Many extension modules just provide new functions and types to be used from " "Python, but sometimes the code in an extension module can be useful for " @@ -1565,7 +1563,7 @@ msgstr "" "collection devrait posséder un ensemble de fonctions C pour une manipulation " "directe à partir d'autres modules d'extension." -#: extending/extending.rst:1155 +#: extending/extending.rst:1153 msgid "" "At first sight this seems easy: just write the functions (without declaring " "them ``static``, of course), provide an appropriate header file, and " @@ -1595,7 +1593,7 @@ msgstr "" "*Unix*). Et même si les symboles sont globalement visibles, le module dont " "on souhaite appeler les fonctions n'est peut-être pas encore chargé !" -#: extending/extending.rst:1167 +#: extending/extending.rst:1165 msgid "" "Portability therefore requires not to make any assumptions about symbol " "visibility. This means that all symbols in extension modules should be " @@ -1613,7 +1611,7 @@ msgstr "" "accessibles à partir d'autres modules d'extension doivent être exportés " "d'une manière différente." -#: extending/extending.rst:1174 +#: extending/extending.rst:1172 msgid "" "Python provides a special mechanism to pass C-level information (pointers) " "from one extension module to another one: Capsules. A Capsule is a Python " @@ -1625,7 +1623,7 @@ msgid "" "the Capsule." msgstr "" -#: extending/extending.rst:1182 +#: extending/extending.rst:1180 msgid "" "There are many ways in which Capsules can be used to export the C API of an " "extension module. Each function could get its own Capsule, or all C API " @@ -1642,7 +1640,7 @@ msgstr "" "différentes manières entre le module fournissant le code et les modules " "clients." -#: extending/extending.rst:1188 +#: extending/extending.rst:1186 #, fuzzy msgid "" "Whichever method you choose, it's important to name your Capsules properly. " @@ -1660,13 +1658,13 @@ msgstr "" "concernant un éventuel conflit de types, car il n'y a pas de moyen de " "distinguer deux ou plusieurs Capsules non nommée entre elles." -#: extending/extending.rst:1195 +#: extending/extending.rst:1193 msgid "" "In particular, Capsules used to expose C APIs should be given a name " "following this convention::" msgstr "" -#: extending/extending.rst:1200 +#: extending/extending.rst:1198 #, fuzzy msgid "" "The convenience function :c:func:`PyCapsule_Import` makes it easy to load a " @@ -1680,7 +1678,7 @@ msgstr "" "utilisateurs d'API C un degré élevé de certitude que la Capsule qu'ils " "chargent contient l'API C correcte." -#: extending/extending.rst:1205 +#: extending/extending.rst:1203 msgid "" "The following example demonstrates an approach that puts most of the burden " "on the writer of the exporting module, which is appropriate for commonly " @@ -1699,7 +1697,7 @@ msgstr "" "le module et de récupérer ses pointeurs d'API C. Les modules clients n'ont " "qu'à appeler cette macro avant d'accéder à l'API C." -#: extending/extending.rst:1213 +#: extending/extending.rst:1211 msgid "" "The exporting module is a modification of the :mod:`spam` module from " "section :ref:`extending-simpleexample`. The function :func:`spam.system` " @@ -1716,25 +1714,25 @@ msgstr "" "Cette fonction :c:func:`PySpam_System` est également exportée vers d'autres " "modules d'extension." -#: extending/extending.rst:1220 +#: extending/extending.rst:1218 msgid "" "The function :c:func:`PySpam_System` is a plain C function, declared " "``static`` like everything else::" msgstr "" -#: extending/extending.rst:1229 +#: extending/extending.rst:1227 msgid "The function :c:func:`spam_system` is modified in a trivial way::" msgstr "La fonction :c:func:`spam_system` est modifiée de manière simple ::" -#: extending/extending.rst:1243 +#: extending/extending.rst:1241 msgid "In the beginning of the module, right after the line ::" msgstr "Au début du module, immédiatement après la ligne ::" -#: extending/extending.rst:1247 +#: extending/extending.rst:1245 msgid "two more lines must be added::" msgstr "on doit ajouter deux lignes supplémentaires ::" -#: extending/extending.rst:1252 +#: extending/extending.rst:1250 msgid "" "The ``#define`` is used to tell the header file that it is being included in " "the exporting module, not a client module. Finally, the module's " @@ -1746,7 +1744,7 @@ msgstr "" "Enfin, la fonction d'initialisation du module doit prendre en charge " "l'initialisation du tableau de pointeurs de l'API C ::" -#: extending/extending.rst:1282 +#: extending/extending.rst:1280 msgid "" "Note that ``PySpam_API`` is declared ``static``; otherwise the pointer array " "would disappear when :func:`PyInit_spam` terminates!" @@ -1754,7 +1752,7 @@ msgstr "" "Notez que ``PySpam_API`` est déclaré ``static`` ; sinon le tableau de " "pointeurs disparaîtrait lorsque :func:`PyInit_spam`` se finit !" -#: extending/extending.rst:1285 +#: extending/extending.rst:1283 msgid "" "The bulk of the work is in the header file :file:`spammodule.h`, which looks " "like this::" @@ -1762,7 +1760,7 @@ msgstr "" "L'essentiel du travail se trouve dans le fichier d'en-tête :file:`spammodule." "h`, qui ressemble à ceci ::" -#: extending/extending.rst:1336 +#: extending/extending.rst:1334 msgid "" "All that a client module must do in order to have access to the function :c:" "func:`PySpam_System` is to call the function (or rather macro) :c:func:" @@ -1772,7 +1770,7 @@ msgstr "" "func:`PySpam_System` est d'appeler la fonction (ou plutôt la macro) :c:func:" "`import_spam` dans sa fonction d'initialisation ::" -#: extending/extending.rst:1354 +#: extending/extending.rst:1352 msgid "" "The main disadvantage of this approach is that the file :file:`spammodule.h` " "is rather complicated. However, the basic structure is the same for each " @@ -1783,7 +1781,7 @@ msgstr "" "même pour chaque fonction exportée, ce qui fait qu'elle ne doit être apprise " "qu'une seule fois." -#: extending/extending.rst:1358 +#: extending/extending.rst:1356 msgid "" "Finally it should be mentioned that Capsules offer additional functionality, " "which is especially useful for memory allocation and deallocation of the " @@ -1800,11 +1798,11 @@ msgstr "" "file:`Include/pycapsule.h` et :file:`Objects/pycapsule.c` dans la " "distribution du code source Python)." -#: extending/extending.rst:1366 +#: extending/extending.rst:1364 msgid "Footnotes" msgstr "Notes" -#: extending/extending.rst:1367 +#: extending/extending.rst:1365 msgid "" "An interface for this function already exists in the standard module :mod:" "`os` --- it was chosen as a simple and straightforward example." @@ -1812,7 +1810,7 @@ msgstr "" "Une interface pour cette fonction existe déjà dans le module standard :mod:" "`os`, elle a été choisie comme un exemple simple et direct." -#: extending/extending.rst:1370 +#: extending/extending.rst:1368 msgid "" "The metaphor of \"borrowing\" a reference is not completely correct: the " "owner still has a copy of the reference." @@ -1820,7 +1818,7 @@ msgstr "" "L'expression « emprunter une référence » n'est pas tout à fait correcte, car " "le propriétaire a toujours une copie de la référence." -#: extending/extending.rst:1373 +#: extending/extending.rst:1371 msgid "" "Checking that the reference count is at least 1 **does not work** --- the " "reference count itself could be in freed memory and may thus be reused for " @@ -1830,7 +1828,7 @@ msgstr "" "pas**, le compte de référence lui-même pourrait être en mémoire libérée et " "peut donc être réutilisé pour un autre objet !" -#: extending/extending.rst:1377 +#: extending/extending.rst:1375 msgid "" "These guarantees don't hold when you use the \"old\" style calling " "convention --- this is still found in much existing code." diff --git a/faq/library.po b/faq/library.po index da02e2cc..25f4c899 100644 --- a/faq/library.po +++ b/faq/library.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-10-17 18:53+0200\n" "Last-Translator: Jean Abou Samra \n" "Language-Team: FRENCH \n" @@ -388,19 +388,11 @@ msgstr "" "`_thread`. Le module :mod:`threading` fournit une abstraction plus facile à " "manipuler que les primitives de bas-niveau du module :mod:`_thread`." -#: faq/library.rst:246 -msgid "" -"Aahz has a set of slides from his threading tutorial that are helpful; see " -"http://www.pythoncraft.com/OSCON2001/." -msgstr "" -"Un ensemble de diapositives issues du didacticiel de Aahz sur les fils " -"d'exécution est disponible à http://www.pythoncraft.com/OSCON2001/." - -#: faq/library.rst:251 +#: faq/library.rst:248 msgid "None of my threads seem to run: why?" msgstr "Aucun de mes fils ne semble s'exécuter : pourquoi ?" -#: faq/library.rst:253 +#: faq/library.rst:250 msgid "" "As soon as the main thread exits, all threads are killed. Your main thread " "is running too quickly, giving the threads no time to do any work." @@ -409,7 +401,7 @@ msgstr "" "fil principal s'exécute trop rapidement, sans laisser le temps aux autres " "fils de faire quoi que ce soit." -#: faq/library.rst:256 +#: faq/library.rst:253 msgid "" "A simple fix is to add a sleep to the end of the program that's long enough " "for all the threads to finish::" @@ -417,7 +409,7 @@ msgstr "" "Une correction simple consiste à ajouter un temps d'attente suffisamment " "long à la fin du programme pour que tous les fils puissent se terminer ::" -#: faq/library.rst:271 +#: faq/library.rst:268 msgid "" "But now (on many platforms) the threads don't run in parallel, but appear to " "run sequentially, one at a time! The reason is that the OS thread scheduler " @@ -428,13 +420,13 @@ msgstr "" "l'autre ! En réalité, l'ordonnanceur de fils du système d'exploitation ne " "démarre pas de nouveau fil avant que le précédent ne soit bloqué." -#: faq/library.rst:275 +#: faq/library.rst:272 msgid "A simple fix is to add a tiny sleep to the start of the run function::" msgstr "" "Une correction simple consiste à ajouter un petit temps d'attente au début " "de la fonction ::" -#: faq/library.rst:288 +#: faq/library.rst:285 msgid "" "Instead of trying to guess a good delay value for :func:`time.sleep`, it's " "better to use some kind of semaphore mechanism. One idea is to use the :mod:" @@ -449,13 +441,13 @@ msgstr "" "quand il se termine, et que le fil principal retire autant de jetons de la " "file qu'il y a de fils." -#: faq/library.rst:296 +#: faq/library.rst:293 msgid "How do I parcel out work among a bunch of worker threads?" msgstr "" "Comment découper et répartir une tâche au sein d'un ensemble de fils " "d'exécutions ?" -#: faq/library.rst:298 +#: faq/library.rst:295 msgid "" "The easiest way is to use the :mod:`concurrent.futures` module, especially " "the :mod:`~concurrent.futures.ThreadPoolExecutor` class." @@ -464,7 +456,7 @@ msgstr "" "futures`, en particulier la classe :mod:`~concurrent.futures." "ThreadPoolExecutor`." -#: faq/library.rst:301 +#: faq/library.rst:298 msgid "" "Or, if you want fine control over the dispatching algorithm, you can write " "your own logic manually. Use the :mod:`queue` module to create a queue " @@ -481,15 +473,15 @@ msgstr "" "pour les récupérer. La classe s'occupe de gérer les verrous pour que chaque " "tâche soit exécutée une et une seule fois." -#: faq/library.rst:308 +#: faq/library.rst:305 msgid "Here's a trivial example::" msgstr "Voici un exemple trivial ::" -#: faq/library.rst:346 +#: faq/library.rst:343 msgid "When run, this will produce the following output:" msgstr "Quand celui-ci est exécuté, il produit la sortie suivante :" -#: faq/library.rst:364 +#: faq/library.rst:361 msgid "" "Consult the module's documentation for more details; the :class:`~queue." "Queue` class provides a featureful interface." @@ -497,13 +489,13 @@ msgstr "" "Consultez la documentation du module pour plus de détails ; la classe :class:" "`~queue.Queue` fournit une interface pleine de fonctionnalités." -#: faq/library.rst:369 +#: faq/library.rst:366 msgid "What kinds of global value mutation are thread-safe?" msgstr "" "Quels types de mutations sur des variables globales sont compatibles avec " "les programmes à fils d'exécution multiples ? sécurisé ?" -#: faq/library.rst:371 +#: faq/library.rst:368 msgid "" "A :term:`global interpreter lock` (GIL) is used internally to ensure that " "only one thread runs in the Python VM at a time. In general, Python offers " @@ -521,7 +513,7 @@ msgstr "" "intermédiaire, et, par conséquent, tout le code C appelé par cette " "instruction est donc atomique du point de vue d'un programme Python." -#: faq/library.rst:378 +#: faq/library.rst:375 msgid "" "In theory, this means an exact accounting requires an exact understanding of " "the PVM bytecode implementation. In practice, it means that operations on " @@ -534,7 +526,7 @@ msgstr "" "listes, les dictionnaires etc.) qui « semblent atomiques » le sont " "réellement." -#: faq/library.rst:383 +#: faq/library.rst:380 msgid "" "For example, the following operations are all atomic (L, L1, L2 are lists, " "D, D1, D2 are dicts, x, y are objects, i, j are ints)::" @@ -543,11 +535,11 @@ msgstr "" "*L2* sont des listes, *D*, *D1* et *D2* sont des dictionnaires, *x* et *y* " "sont des objets, *i* et *j* des entiers) ::" -#: faq/library.rst:398 +#: faq/library.rst:395 msgid "These aren't::" msgstr "Les suivantes ne le sont pas ::" -#: faq/library.rst:405 +#: faq/library.rst:402 msgid "" "Operations that replace other objects may invoke those other objects' :meth:" "`__del__` method when their reference count reaches zero, and that can " @@ -560,11 +552,11 @@ msgstr "" "des changements massifs sur des dictionnaires ou des listes. En cas de " "doute, il vaut mieux utiliser un mutex." -#: faq/library.rst:412 +#: faq/library.rst:409 msgid "Can't we get rid of the Global Interpreter Lock?" msgstr "Pourquoi ne pas se débarrasser du verrou global de l'interpréteur ?" -#: faq/library.rst:416 +#: faq/library.rst:413 msgid "" "The :term:`global interpreter lock` (GIL) is often seen as a hindrance to " "Python's deployment on high-end multiprocessor server machines, because a " @@ -578,7 +570,7 @@ msgstr "" "Presque tout le code Python ne peut en effet être exécuté qu'avec le GIL " "acquis." -#: faq/library.rst:421 +#: faq/library.rst:418 msgid "" "Back in the days of Python 1.5, Greg Stein actually implemented a " "comprehensive patch set (the \"free threading\" patches) that removed the " @@ -598,7 +590,7 @@ msgstr "" "un seul fil d'exécution, à cause de la quantité de verrouillage plus " "granulaire nécessaire pour contrebalancer la suppression du GIL." -#: faq/library.rst:429 +#: faq/library.rst:426 msgid "" "This doesn't mean that you can't make good use of Python on multi-CPU " "machines! You just have to be creative with dividing the work up between " @@ -616,7 +608,7 @@ msgstr "" "le module :mod:`multiprocessing` fournit une API de plus bas-niveau pour un " "meilleur contrôle sur la distribution des tâches." -#: faq/library.rst:437 +#: faq/library.rst:434 msgid "" "Judicious use of C extensions will also help; if you use a C extension to " "perform a time-consuming task, the extension can release the GIL while the " @@ -630,7 +622,7 @@ msgstr "" "fils travailler. Des modules de la bibliothèque standard comme :mod:`zlib` " "ou :mod:`hashlib` utilisent cette technique." -#: faq/library.rst:443 +#: faq/library.rst:440 msgid "" "It has been suggested that the GIL should be a per-interpreter-state lock " "rather than truly global; interpreters then wouldn't be able to share " @@ -651,7 +643,7 @@ msgstr "" "ont leur propre liste de suppression, ces listes devraient être déplacées au " "niveau de l'interpréteur et ainsi de suite." -#: faq/library.rst:452 +#: faq/library.rst:449 msgid "" "And I doubt that it can even be done in finite time, because the same " "problem exists for 3rd party extensions. It is likely that 3rd party " @@ -663,7 +655,7 @@ msgstr "" "qu'il ne soit possible de les corriger pour les faire stocker leur état au " "niveau de l'interpréteur et non plus au niveau global." -#: faq/library.rst:457 +#: faq/library.rst:454 msgid "" "And finally, once you have multiple interpreters not sharing any state, what " "have you gained over running each interpreter in a separate process?" @@ -672,15 +664,15 @@ msgstr "" "partagent pas d'état, par rapport à faire tourner chaque interpréteur dans " "un processus différent ?" -#: faq/library.rst:462 +#: faq/library.rst:459 msgid "Input and Output" msgstr "Les entrées/sorties" -#: faq/library.rst:465 +#: faq/library.rst:462 msgid "How do I delete a file? (And other file questions...)" msgstr "Comment supprimer un fichier ? (et autres questions sur les fichiers…)" -#: faq/library.rst:467 +#: faq/library.rst:464 msgid "" "Use ``os.remove(filename)`` or ``os.unlink(filename)``; for documentation, " "see the :mod:`os` module. The two functions are identical; :func:`~os." @@ -691,7 +683,7 @@ msgstr "" "identiques, :func:`~os.unlink` n'est tout simplement que le nom de l'appel " "système à cette fonction sous Unix." -#: faq/library.rst:471 +#: faq/library.rst:468 msgid "" "To remove a directory, use :func:`os.rmdir`; use :func:`os.mkdir` to create " "one. ``os.makedirs(path)`` will create any intermediate directories in " @@ -705,12 +697,12 @@ msgstr "" "supprime les dossiers intermédiaires si ceux-ci sont vides. Pour supprimer " "une arborescence et tout son contenu, utilisez :func:`shutil.rmtree`." -#: faq/library.rst:477 +#: faq/library.rst:474 msgid "To rename a file, use ``os.rename(old_path, new_path)``." msgstr "" "``os.rename(ancien_chemin, nouveau_chemin)`` permet de renommer un fichier." -#: faq/library.rst:479 +#: faq/library.rst:476 msgid "" "To truncate a file, open it using ``f = open(filename, \"rb+\")``, and use " "``f.truncate(offset)``; offset defaults to the current seek position. " @@ -723,7 +715,7 @@ msgstr "" "existe aussi ``os.ftruncate(df, décalage)`` pour les fichiers ouverts avec :" "func:`os.open`, où *df* est le descripteur de fichier (un entier court)." -#: faq/library.rst:484 +#: faq/library.rst:481 msgid "" "The :mod:`shutil` module also contains a number of functions to work on " "files including :func:`~shutil.copyfile`, :func:`~shutil.copytree`, and :" @@ -733,11 +725,11 @@ msgstr "" "effectuer des opérations sur des fichiers comme :func:`~shutil.copyfile`, :" "func:`~shutil.copytree` et :func:`~shutil.rmtree`." -#: faq/library.rst:490 +#: faq/library.rst:487 msgid "How do I copy a file?" msgstr "Comment copier un fichier ?" -#: faq/library.rst:492 +#: faq/library.rst:489 msgid "" "The :mod:`shutil` module contains a :func:`~shutil.copyfile` function. Note " "that on MacOS 9 it doesn't copy the resource fork and Finder info." @@ -746,11 +738,11 @@ msgstr "" "MacOS 9, celle-ci ne copie pas le clonage de ressources ni les informations " "du chercheur." -#: faq/library.rst:497 +#: faq/library.rst:494 msgid "How do I read (or write) binary data?" msgstr "Comment lire (ou écrire) des données binaires ?" -#: faq/library.rst:499 +#: faq/library.rst:496 msgid "" "To read or write complex binary data formats, it's best to use the :mod:" "`struct` module. It allows you to take a string containing binary data " @@ -761,7 +753,7 @@ msgstr "" "une chaîne de caractères qui contient des données binaires, souvent des " "nombres, en objets Python, et vice-versa." -#: faq/library.rst:503 +#: faq/library.rst:500 msgid "" "For example, the following code reads two 2-byte integers and one 4-byte " "integer in big-endian format from a file::" @@ -769,7 +761,7 @@ msgstr "" "Par exemple, le code suivant lit, depuis un fichier, deux entiers codés sur " "2 octets et un entier codé sur 4 octets, en format gros-boutiste ::" -#: faq/library.rst:512 +#: faq/library.rst:509 msgid "" "The '>' in the format string forces big-endian data; the letter 'h' reads " "one \"short integer\" (2 bytes), and 'l' reads one \"long integer\" (4 " @@ -779,7 +771,7 @@ msgstr "" "mode gros-boutiste, la lettre « h » indique un entier court (2 octets) et la " "lettre « l » indique un entier long (4 octets)." -#: faq/library.rst:516 +#: faq/library.rst:513 msgid "" "For data that is more regular (e.g. a homogeneous list of ints or floats), " "you can also use the :mod:`array` module." @@ -788,7 +780,7 @@ msgstr "" "nombres à virgule flottante), il est possible d'utiliser le module :mod:" "`array`." -#: faq/library.rst:521 +#: faq/library.rst:518 msgid "" "To read and write binary data, it is mandatory to open the file in binary " "mode (here, passing ``\"rb\"`` to :func:`open`). If you use ``\"r\"`` " @@ -801,13 +793,13 @@ msgstr "" "en mode textuel et ``f.read()`` renvoie des objets :class:`str` au lieu " "d'objets :class:`bytes`." -#: faq/library.rst:529 +#: faq/library.rst:526 msgid "I can't seem to use os.read() on a pipe created with os.popen(); why?" msgstr "" "Il me semble impossible d'utiliser ``os.read()`` sur un tube créé avec ``os." "popen()`` ; pourquoi ?" -#: faq/library.rst:531 +#: faq/library.rst:528 msgid "" ":func:`os.read` is a low-level function which takes a file descriptor, a " "small integer representing the opened file. :func:`os.popen` creates a high-" @@ -822,34 +814,35 @@ msgstr "" "octets d'un tube *p* créé avec :func:`os.popen`, il faut utiliser ``p." "read(n)``." -#: faq/library.rst:618 +#: faq/library.rst:615 msgid "How do I access the serial (RS232) port?" msgstr "Comment accéder au port de transmission en série (RS-232) ?" -#: faq/library.rst:620 -msgid "For Win32, POSIX (Linux, BSD, etc.), Jython:" +#: faq/library.rst:617 +#, fuzzy +msgid "For Win32, OSX, Linux, BSD, Jython, IronPython:" msgstr "Pour Win32, POSIX (Linux, BSD, etc.) et Jython :" -#: faq/library.rst:622 -msgid "http://pyserial.sourceforge.net" -msgstr "http://pyserial.sourceforge.net" +#: faq/library.rst:619 +msgid "https://pypi.org/project/pyserial/" +msgstr "" -#: faq/library.rst:624 +#: faq/library.rst:621 msgid "For Unix, see a Usenet post by Mitch Chapman:" msgstr "" "Pour Unix, référez-vous à une publication sur Usenet de Mitch Chapman :" -#: faq/library.rst:626 +#: faq/library.rst:623 msgid "https://groups.google.com/groups?selm=34A04430.CF9@ohioee.com" msgstr "https://groups.google.com/groups?selm=34A04430.CF9@ohioee.com" -#: faq/library.rst:630 +#: faq/library.rst:627 msgid "Why doesn't closing sys.stdout (stdin, stderr) really close it?" msgstr "" "Pourquoi fermer *sys.stdout*, *sys.stdin*, *sys.stderr* ne les ferme pas " "réellement ?" -#: faq/library.rst:632 +#: faq/library.rst:629 msgid "" "Python :term:`file objects ` are a high-level layer of " "abstraction on low-level C file descriptors." @@ -857,7 +850,7 @@ msgstr "" "Les :term:`objets fichiers ` en Python sont des abstractions de " "haut niveau sur les descripteurs de fichier C de bas niveau." -#: faq/library.rst:635 +#: faq/library.rst:632 msgid "" "For most file objects you create in Python via the built-in :func:`open` " "function, ``f.close()`` marks the Python file object as being closed from " @@ -871,7 +864,7 @@ msgstr "" "enclenché automatiquement dans le destructeur de ``f``, lorsque ``f`` est " "recyclé." -#: faq/library.rst:641 +#: faq/library.rst:638 msgid "" "But stdin, stdout and stderr are treated specially by Python, because of the " "special status also given to them by C. Running ``sys.stdout.close()`` " @@ -883,7 +876,7 @@ msgstr "" "close()`` marque l'objet fichier comme fermé du point de vue de Python, mais " "le descripteur de fichier C associé n'est *pas* fermé." -#: faq/library.rst:646 +#: faq/library.rst:643 msgid "" "To close the underlying C file descriptor for one of these three, you should " "first be sure that's what you really want to do (e.g., you may confuse " @@ -894,21 +887,21 @@ msgstr "" "exemple, perturber le bon fonctionnement de modules qui font des opérations " "d'entrée-sortie). Si c'est le cas, utilisez :func:`os.close` ::" -#: faq/library.rst:654 +#: faq/library.rst:651 msgid "Or you can use the numeric constants 0, 1 and 2, respectively." msgstr "" "Il est aussi possible de fermer respectivement les constantes numériques 0, " "1 ou 2." -#: faq/library.rst:658 +#: faq/library.rst:655 msgid "Network/Internet Programming" msgstr "Programmation réseau et Internet" -#: faq/library.rst:661 +#: faq/library.rst:658 msgid "What WWW tools are there for Python?" msgstr "Quels sont les outils Python dédiés à la Toile ?" -#: faq/library.rst:663 +#: faq/library.rst:660 msgid "" "See the chapters titled :ref:`internet` and :ref:`netdata` in the Library " "Reference Manual. Python has many modules that will help you build server-" @@ -918,7 +911,7 @@ msgstr "" "le manuel de référence de la bibliothèque. Python a de nombreux modules pour " "construire des applications de Toile côté client comme côté serveur." -#: faq/library.rst:669 +#: faq/library.rst:666 msgid "" "A summary of available frameworks is maintained by Paul Boddie at https://" "wiki.python.org/moin/WebProgramming\\ ." @@ -926,7 +919,7 @@ msgstr "" "Un résumé des cadriciels disponibles est maintenu par Paul Boddie à " "l'adresse https://wiki.python.org/moin/WebProgramming\\ ." -#: faq/library.rst:672 +#: faq/library.rst:669 msgid "" "Cameron Laird maintains a useful set of pages about Python web technologies " "at http://phaseit.net/claird/comp.lang.python/web_python." @@ -935,11 +928,11 @@ msgstr "" "technologies Python dédiées à la Toile à l'adresse http://phaseit.net/claird/" "comp.lang.python/web_python." -#: faq/library.rst:677 +#: faq/library.rst:674 msgid "How can I mimic CGI form submission (METHOD=POST)?" msgstr "Comment reproduire un envoi de formulaire CGI (``METHOD=POST``) ?" -#: faq/library.rst:679 +#: faq/library.rst:676 msgid "" "I would like to retrieve web pages that are the result of POSTing a form. Is " "there existing code that would let me do this easily?" @@ -947,11 +940,11 @@ msgstr "" "J'aimerais récupérer la page de retour d'un envoi de formulaire sur la " "Toile. Existe-t'il déjà du code qui pourrait m'aider à le faire facilement ?" -#: faq/library.rst:682 +#: faq/library.rst:679 msgid "Yes. Here's a simple example that uses :mod:`urllib.request`::" msgstr "Oui. Voici un exemple simple d'utilisation de :mod:`urllib.request` ::" -#: faq/library.rst:697 +#: faq/library.rst:694 msgid "" "Note that in general for percent-encoded POST operations, query strings must " "be quoted using :func:`urllib.parse.urlencode`. For example, to send " @@ -962,15 +955,15 @@ msgstr "" "`urllib.parse.urlencode`. Par exemple pour envoyer ``name=Guy Steele, Jr." "`` ::" -#: faq/library.rst:705 +#: faq/library.rst:702 msgid ":ref:`urllib-howto` for extensive examples." msgstr ":ref:`urllib-howto` pour des exemples complets." -#: faq/library.rst:709 +#: faq/library.rst:706 msgid "What module should I use to help with generating HTML?" msgstr "Quel module utiliser pour générer du HTML ?" -#: faq/library.rst:713 +#: faq/library.rst:710 msgid "" "You can find a collection of useful links on the `Web Programming wiki page " "`_." @@ -978,15 +971,15 @@ msgstr "" "La `page wiki de la programmation Toile `_ (en anglais) répertorie un ensemble de liens pertinents." -#: faq/library.rst:718 +#: faq/library.rst:715 msgid "How do I send mail from a Python script?" msgstr "Comment envoyer un courriel avec un script Python ?" -#: faq/library.rst:720 +#: faq/library.rst:717 msgid "Use the standard library module :mod:`smtplib`." msgstr "Utilisez le module :mod:`smtplib` de la bibliothèque standard." -#: faq/library.rst:722 +#: faq/library.rst:719 msgid "" "Here's a very simple interactive mail sender that uses it. This method will " "work on any host that supports an SMTP listener. ::" @@ -994,7 +987,7 @@ msgstr "" "Voici un exemple très simple d'un envoyeur de courriel qui l'utilise. Cette " "méthode fonctionne sur tous les serveurs qui implémentent SMTP. ::" -#: faq/library.rst:742 +#: faq/library.rst:739 msgid "" "A Unix-only alternative uses sendmail. The location of the sendmail program " "varies between systems; sometimes it is ``/usr/lib/sendmail``, sometimes ``/" @@ -1006,13 +999,13 @@ msgstr "" "sendmail`` ou ``/usr/sbin/sendmail``, la page de manuel de *sendmail* peut " "vous aider. Par exemple ::" -#: faq/library.rst:762 +#: faq/library.rst:759 msgid "How do I avoid blocking in the connect() method of a socket?" msgstr "" "Comment éviter de bloquer dans la méthode ``connect()`` d'un connecteur " "réseau ?" -#: faq/library.rst:764 +#: faq/library.rst:761 msgid "" "The :mod:`select` module is commonly used to help with asynchronous I/O on " "sockets." @@ -1020,7 +1013,7 @@ msgstr "" "Le module :mod:`select` est fréquemment utilisé pour effectuer des entrées-" "sorties asynchrones sur des connecteurs réseaux." -#: faq/library.rst:767 +#: faq/library.rst:764 msgid "" "To prevent the TCP connect from blocking, you can set the socket to non-" "blocking mode. Then when you do the :meth:`socket.connect`, you will either " @@ -1037,7 +1030,7 @@ msgstr "" "n'a pas encore aboutie. La valeur dépend du système d'exploitation, donc " "renseignez-vous sur la valeur utilisée par votre système." -#: faq/library.rst:774 +#: faq/library.rst:771 msgid "" "You can use the :meth:`socket.connect_ex` method to avoid creating an " "exception. It will just return the errno value. To poll, you can call :" @@ -1052,7 +1045,7 @@ msgstr "" "argument de :meth:`select.select` pour vérifier si le connecteur est prêt à " "recevoir des entrées." -#: faq/library.rst:780 +#: faq/library.rst:777 msgid "" "The :mod:`asyncio` module provides a general purpose single-threaded and " "concurrent asynchronous library, which can be used for writing non-blocking " @@ -1064,20 +1057,20 @@ msgstr "" "`Twisted `_ en est une alternative " "plébiscitée, avec un grand nombre de fonctionnalités." -#: faq/library.rst:788 +#: faq/library.rst:785 msgid "Databases" msgstr "Bases de données" -#: faq/library.rst:791 +#: faq/library.rst:788 msgid "Are there any interfaces to database packages in Python?" msgstr "" "Existe-t'il des modules Python pour s'interfacer avec des bases de données ?" -#: faq/library.rst:793 +#: faq/library.rst:790 msgid "Yes." msgstr "Oui." -#: faq/library.rst:795 +#: faq/library.rst:792 msgid "" "Interfaces to disk-based hashes such as :mod:`DBM ` and :mod:`GDBM " "` are also included with standard Python. There is also the :mod:" @@ -1089,7 +1082,7 @@ msgstr "" "aussi le module :mod:`sqlite3` qui implémente une base de données " "relationelle légère sur disque." -#: faq/library.rst:800 +#: faq/library.rst:797 msgid "" "Support for most relational databases is available. See the " "`DatabaseProgramming wiki page `_ pour plus de détails." -#: faq/library.rst:806 +#: faq/library.rst:803 msgid "How do you implement persistent objects in Python?" msgstr "Comment implémenter la persistance d'objets en Python ?" -#: faq/library.rst:808 +#: faq/library.rst:805 msgid "" "The :mod:`pickle` library module solves this in a very general way (though " "you still can't store things like open files, sockets or windows), and the :" @@ -1115,15 +1108,15 @@ msgstr "" "fenêtres par exemple), et le module :mod:`shelve` de la bibliothèque utilise " "*pickle* et *(g)dbm* pour créer des liens persistants vers des objets Python." -#: faq/library.rst:815 +#: faq/library.rst:812 msgid "Mathematics and Numerics" msgstr "Mathématiques et calcul numérique" -#: faq/library.rst:818 +#: faq/library.rst:815 msgid "How do I generate random numbers in Python?" msgstr "Comment générer des nombres aléatoires en Python ?" -#: faq/library.rst:820 +#: faq/library.rst:817 msgid "" "The standard module :mod:`random` implements a random number generator. " "Usage is simple::" @@ -1131,51 +1124,61 @@ msgstr "" "Le module :mod:`random` de la bibliothèque standard comprend un générateur " "de nombres aléatoires. Son utilisation est simple ::" -#: faq/library.rst:826 +#: faq/library.rst:823 msgid "This returns a random floating point number in the range [0, 1)." msgstr "" "Le code précédent renvoie un nombre à virgule flottante aléatoire dans " "l'intervalle [0, 1[." -#: faq/library.rst:828 +#: faq/library.rst:825 msgid "" "There are also many other specialized generators in this module, such as:" msgstr "Ce module fournit beaucoup d'autres générateurs spécialisés comme :" -#: faq/library.rst:830 +#: faq/library.rst:827 msgid "``randrange(a, b)`` chooses an integer in the range [a, b)." msgstr "``randrange(a, b)`` génère un entier dans l'intervalle [a, b[." -#: faq/library.rst:831 +#: faq/library.rst:828 msgid "``uniform(a, b)`` chooses a floating point number in the range [a, b)." msgstr "" "``uniform(a, b)`` génère un nombre à virgule flottante aléatoire dans " "l'intervalle [a, b[." -#: faq/library.rst:832 +#: faq/library.rst:829 msgid "" "``normalvariate(mean, sdev)`` samples the normal (Gaussian) distribution." msgstr "``normalvariate(mean, sdev)`` simule la loi normale (Gaussienne)." -#: faq/library.rst:834 +#: faq/library.rst:831 msgid "Some higher-level functions operate on sequences directly, such as:" msgstr "" "Des fonctions de haut niveau opèrent directement sur des séquences comme :" -#: faq/library.rst:836 +#: faq/library.rst:833 msgid "``choice(S)`` chooses a random element from a given sequence." msgstr "``choice(S)`` sélectionne au hasard un élément d'une séquence donnée." -#: faq/library.rst:837 +#: faq/library.rst:834 msgid "``shuffle(L)`` shuffles a list in-place, i.e. permutes it randomly." msgstr "" "``shuffle(L)`` mélange une liste en-place, c.-à-d. lui applique une " "permutation aléatoire." -#: faq/library.rst:839 +#: faq/library.rst:836 msgid "" "There's also a ``Random`` class you can instantiate to create independent " "multiple random number generators." msgstr "" "Il existe aussi une classe ``Random`` qu'il est possible d'instancier pour " "créer des générateurs aléatoires indépendants." + +#~ msgid "" +#~ "Aahz has a set of slides from his threading tutorial that are helpful; " +#~ "see http://www.pythoncraft.com/OSCON2001/." +#~ msgstr "" +#~ "Un ensemble de diapositives issues du didacticiel de Aahz sur les fils " +#~ "d'exécution est disponible à http://www.pythoncraft.com/OSCON2001/." + +#~ msgid "http://pyserial.sourceforge.net" +#~ msgstr "http://pyserial.sourceforge.net" diff --git a/faq/programming.po b/faq/programming.po index 7ed65747..9cbd7734 100644 --- a/faq/programming.po +++ b/faq/programming.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-11-04 18:14+0100\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-11-06 19:21+0100\n" "Last-Translator: Jean Abou Samra \n" "Language-Team: FRENCH \n" @@ -3163,8 +3163,9 @@ msgstr "" "valeurs importées)." #: faq/programming.rst:2095 +#, fuzzy msgid "" -"van Rossum doesn't like this approach much because the imports appear in a " +"Van Rossum doesn't like this approach much because the imports appear in a " "strange place, but it does work." msgstr "" "van Rossum désapprouve cette approche car les importations se trouvent à un " diff --git a/glossary.po b/glossary.po index 7f630676..8691b4cf 100644 --- a/glossary.po +++ b/glossary.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-10-31 18:43+0100\n" "Last-Translator: Jules Lasne \n" "Language-Team: FRENCH \n" @@ -1210,36 +1210,35 @@ msgid "generic type" msgstr "type générique" #: glossary.rst:523 +#, fuzzy msgid "" -"A :term:`type` that can be parameterized; typically a container like :class:" -"`list`. Used for :term:`type hints ` and :term:`annotations " -"`." +"A :term:`type` that can be parameterized; typically a :ref:`container " +"class` such as :class:`list` or :class:`dict`. Used for :" +"term:`type hints ` and :term:`annotations `." msgstr "" "Un :term:`type` qui peut être paramétré ; typiquement un conteneur comme " "une :class:`list`. Utilisé pour les :term:`indications de type ` " "et les :term:`annotations `." -#: glossary.rst:527 +#: glossary.rst:528 msgid "" -"See :pep:`483` for more details, and :mod:`typing` or :ref:`generic alias " -"type ` for its uses." +"For more details, see :ref:`generic alias types`, :pep:" +"`483`, :pep:`484`, :pep:`585`, and the :mod:`typing` module." msgstr "" -"Voir la :pep:`483` pour plus de détails, et :mod:`typing` ou :ref:`alias " -"générique de type ` pour ses utilisations." -#: glossary.rst:529 +#: glossary.rst:530 msgid "GIL" msgstr "GIL" -#: glossary.rst:531 +#: glossary.rst:532 msgid "See :term:`global interpreter lock`." msgstr "Voir :term:`global interpreter lock`." -#: glossary.rst:532 +#: glossary.rst:533 msgid "global interpreter lock" msgstr "verrou global de l'interpréteur" -#: glossary.rst:534 +#: glossary.rst:535 msgid "" "The mechanism used by the :term:`CPython` interpreter to assure that only " "one thread executes Python :term:`bytecode` at a time. This simplifies the " @@ -1259,7 +1258,7 @@ msgstr "" "au détriment malheureusement de beaucoup du parallélisme possible sur les " "machines ayant plusieurs processeurs." -#: glossary.rst:543 +#: glossary.rst:544 msgid "" "However, some extension modules, either standard or third-party, are " "designed so as to release the GIL when doing computationally-intensive tasks " @@ -1271,7 +1270,7 @@ msgstr "" "compression ou le hachage. De la même manière, le GIL est toujours libéré " "lors des entrées / sorties." -#: glossary.rst:548 +#: glossary.rst:549 msgid "" "Past efforts to create a \"free-threaded\" interpreter (one which locks " "shared data at a much finer granularity) have not been successful because " @@ -1285,11 +1284,11 @@ msgstr "" "corriger ce problème de performance induit mènerait à une implémentation " "beaucoup plus compliquée et donc plus coûteuse à maintenir." -#: glossary.rst:554 +#: glossary.rst:555 msgid "hash-based pyc" msgstr "*pyc* utilisant le hachage" -#: glossary.rst:556 +#: glossary.rst:557 msgid "" "A bytecode cache file that uses the hash rather than the last-modified time " "of the corresponding source file to determine its validity. See :ref:`pyc-" @@ -1300,11 +1299,11 @@ msgstr "" "source correspondant pour déterminer sa validité. Voir :ref:`pyc-" "invalidation`." -#: glossary.rst:559 +#: glossary.rst:560 msgid "hashable" msgstr "hachable" -#: glossary.rst:561 +#: glossary.rst:562 msgid "" "An object is *hashable* if it has a hash value which never changes during " "its lifetime (it needs a :meth:`__hash__` method), and can be compared to " @@ -1317,7 +1316,7 @@ msgstr "" "hachables dont la comparaison par ``__eq__`` est vraie doivent avoir la même " "empreinte." -#: glossary.rst:566 +#: glossary.rst:567 msgid "" "Hashability makes an object usable as a dictionary key and a set member, " "because these data structures use the hash value internally." @@ -1326,7 +1325,7 @@ msgstr "" "en tant que membre d'un ensemble (type *set*), car ces structures de données " "utilisent ce *hash*." -#: glossary.rst:569 +#: glossary.rst:570 msgid "" "Most of Python's immutable built-in objects are hashable; mutable containers " "(such as lists or dictionaries) are not; immutable containers (such as " @@ -1343,11 +1342,11 @@ msgstr "" "considérées différentes (sauf avec elles-mêmes) et leur valeur de hachage " "est calculée à partir de leur :func:`id`." -#: glossary.rst:576 +#: glossary.rst:577 msgid "IDLE" msgstr "IDLE" -#: glossary.rst:578 +#: glossary.rst:579 msgid "" "An Integrated Development Environment for Python. IDLE is a basic editor " "and interpreter environment which ships with the standard distribution of " @@ -1356,11 +1355,11 @@ msgstr "" "Environnement de développement intégré pour Python. IDLE est un éditeur " "basique et un interpréteur livré avec la distribution standard de Python." -#: glossary.rst:581 +#: glossary.rst:582 msgid "immutable" msgstr "immuable" -#: glossary.rst:583 +#: glossary.rst:584 msgid "" "An object with a fixed value. Immutable objects include numbers, strings " "and tuples. Such an object cannot be altered. A new object has to be " @@ -1374,11 +1373,11 @@ msgstr "" "quand une valeur de *hash* constante est requise, typiquement en clé de " "dictionnaire." -#: glossary.rst:588 +#: glossary.rst:589 msgid "import path" msgstr "chemin des importations" -#: glossary.rst:590 +#: glossary.rst:591 msgid "" "A list of locations (or :term:`path entries `) that are searched " "by the :term:`path based finder` for modules to import. During import, this " @@ -1391,21 +1390,21 @@ msgstr "" "pour les sous-paquets, elle peut aussi venir de l'attribut ``__path__`` du " "paquet parent." -#: glossary.rst:595 +#: glossary.rst:596 msgid "importing" msgstr "importing" -#: glossary.rst:597 +#: glossary.rst:598 msgid "" "The process by which Python code in one module is made available to Python " "code in another module." msgstr "Processus rendant le code Python d'un module disponible dans un autre." -#: glossary.rst:599 +#: glossary.rst:600 msgid "importer" msgstr "importateur" -#: glossary.rst:601 +#: glossary.rst:602 msgid "" "An object that both finds and loads a module; both a :term:`finder` and :" "term:`loader` object." @@ -1413,11 +1412,11 @@ msgstr "" "Objet qui trouve et charge un module, en même temps un :term:`chercheur " "` et un :term:`chargeur `." -#: glossary.rst:603 +#: glossary.rst:604 msgid "interactive" msgstr "interactif" -#: glossary.rst:605 +#: glossary.rst:606 msgid "" "Python has an interactive interpreter which means you can enter statements " "and expressions at the interpreter prompt, immediately execute them and see " @@ -1432,11 +1431,11 @@ msgstr "" "de votre ordinateur). C'est un moyen puissant pour tester de nouvelles idées " "ou étudier de nouveaux modules (souvenez-vous de ``help(x)``)." -#: glossary.rst:611 +#: glossary.rst:612 msgid "interpreted" msgstr "interprété" -#: glossary.rst:613 +#: glossary.rst:614 msgid "" "Python is an interpreted language, as opposed to a compiled one, though the " "distinction can be blurry because of the presence of the bytecode compiler. " @@ -1453,11 +1452,11 @@ msgstr "" "développement / débogage plus court que les langages compilés. Cependant, " "ils s'exécutent généralement plus lentement. Voir aussi :term:`interactif`." -#: glossary.rst:620 +#: glossary.rst:621 msgid "interpreter shutdown" msgstr "arrêt de l'interpréteur" -#: glossary.rst:622 +#: glossary.rst:623 msgid "" "When asked to shut down, the Python interpreter enters a special phase where " "it gradually releases all allocated resources, such as modules and various " @@ -1478,7 +1477,7 @@ msgstr "" "fonctionner, (typiquement les modules des bibliothèques ou le mécanisme de " "*warning*)." -#: glossary.rst:631 +#: glossary.rst:632 msgid "" "The main reason for interpreter shutdown is that the ``__main__`` module or " "the script being run has finished executing." @@ -1486,11 +1485,11 @@ msgstr "" "La principale raison d'arrêt de l'interpréteur est que le module " "``__main__`` ou le script en cours d'exécution a terminé de s'exécuter." -#: glossary.rst:633 +#: glossary.rst:634 msgid "iterable" msgstr "itérable" -#: glossary.rst:635 +#: glossary.rst:636 msgid "" "An object capable of returning its members one at a time. Examples of " "iterables include all sequence types (such as :class:`list`, :class:`str`, " @@ -1505,7 +1504,7 @@ msgstr "" "tout objet d'une classe ayant une méthode :meth:`__iter__` ou :meth:" "`__getitem__` qui implémente la sémantique d'une :term:`Sequence `." -#: glossary.rst:642 +#: glossary.rst:643 msgid "" "Iterables can be used in a :keyword:`for` loop and in many other places " "where a sequence is needed (:func:`zip`, :func:`map`, ...). When an " @@ -1528,11 +1527,11 @@ msgstr "" "temporaire anonyme pour garder l'itérateur durant la boucle. Voir aussi :" "term:`itérateur`, :term:`séquence` et :term:`générateur`." -#: glossary.rst:652 +#: glossary.rst:653 msgid "iterator" msgstr "itérateur" -#: glossary.rst:654 +#: glossary.rst:655 msgid "" "An object representing a stream of data. Repeated calls to the iterator's :" "meth:`~iterator.__next__` method (or passing it to the built-in function :" @@ -1565,15 +1564,21 @@ msgstr "" "itérateur donnerait simplement le même objet itérateur épuisé utilisé dans " "son itération précédente, le faisant ressembler à un conteneur vide." -#: glossary.rst:669 +#: glossary.rst:670 msgid "More information can be found in :ref:`typeiter`." msgstr "Vous trouverez davantage d'informations dans :ref:`typeiter`." -#: glossary.rst:670 +#: glossary.rst:674 +msgid "" +"CPython does not consistently apply the requirement that an iterator define :" +"meth:`__iter__`." +msgstr "" + +#: glossary.rst:676 msgid "key function" msgstr "fonction clé" -#: glossary.rst:672 +#: glossary.rst:678 msgid "" "A key function or collation function is a callable that returns a value used " "for sorting or ordering. For example, :func:`locale.strxfrm` is used to " @@ -1584,7 +1589,7 @@ msgstr "" "utilisée pour générer une clé de classement prenant en compte les " "conventions de classement spécifiques aux paramètres régionaux courants." -#: glossary.rst:677 +#: glossary.rst:683 msgid "" "A number of tools in Python accept key functions to control how elements are " "ordered or grouped. They include :func:`min`, :func:`max`, :func:`sorted`, :" @@ -1597,7 +1602,7 @@ msgstr "" "merge`, :func:`heapq.nsmallest`, :func:`heapq.nlargest` et :func:`itertools." "groupby`." -#: glossary.rst:683 +#: glossary.rst:689 msgid "" "There are several ways to create a key function. For example. the :meth:" "`str.lower` method can serve as a key function for case insensitive sorts. " @@ -1618,19 +1623,19 @@ msgstr "" "Trier ` pour des exemples de création et d'utilisation de " "fonctions clefs." -#: glossary.rst:691 +#: glossary.rst:697 msgid "keyword argument" msgstr "argument nommé" -#: glossary.rst:982 +#: glossary.rst:988 msgid "See :term:`argument`." msgstr "Voir :term:`argument`." -#: glossary.rst:694 +#: glossary.rst:700 msgid "lambda" msgstr "lambda" -#: glossary.rst:696 +#: glossary.rst:702 msgid "" "An anonymous inline function consisting of a single :term:`expression` which " "is evaluated when the function is called. The syntax to create a lambda " @@ -1641,11 +1646,11 @@ msgstr "" "syntaxe pour créer des fonctions lambda est : ``lambda [parameters]: " "expression``" -#: glossary.rst:699 +#: glossary.rst:705 msgid "LBYL" msgstr "LBYL" -#: glossary.rst:701 +#: glossary.rst:707 msgid "" "Look before you leap. This coding style explicitly tests for pre-conditions " "before making calls or lookups. This style contrasts with the :term:`EAFP` " @@ -1657,7 +1662,7 @@ msgstr "" "appels ou des accès. Ce style contraste avec le style :term:`EAFP` et se " "caractérise par la présence de beaucoup d'instructions :keyword:`if`." -#: glossary.rst:706 +#: glossary.rst:712 msgid "" "In a multi-threaded environment, the LBYL approach can risk introducing a " "race condition between \"the looking\" and \"the leaping\". For example, " @@ -1673,11 +1678,11 @@ msgstr "" "l'accès. Ce problème peut être résolu avec des verrous (*locks*) ou avec " "l'approche EAFP." -#: glossary.rst:711 +#: glossary.rst:717 msgid "locale encoding" msgstr "encodage régional" -#: glossary.rst:713 +#: glossary.rst:719 msgid "" "On Unix, it is the encoding of the LC_CTYPE locale. It can be set with " "``locale.setlocale(locale.LC_CTYPE, new_locale)``." @@ -1685,11 +1690,11 @@ msgstr "" "Sous Unix, il est défini par la variable régionale LC_CTYPE. Il peut être " "modifié par ``locale.setlocale(locale.LC_CTYPE, new_locale)``." -#: glossary.rst:716 +#: glossary.rst:722 msgid "On Windows, it is the ANSI code page (ex: ``cp1252``)." msgstr "Sous Windows, c'est un encodage ANSI (ex. : ``cp1252``)." -#: glossary.rst:718 +#: glossary.rst:724 msgid "" "``locale.getpreferredencoding(False)`` can be used to get the locale " "encoding." @@ -1697,7 +1702,7 @@ msgstr "" "``locale.getpreferredencoding(False)`` permet de récupérer l'encodage " "régional." -#: glossary.rst:721 +#: glossary.rst:727 msgid "" "Python uses the :term:`filesystem encoding and error handler` to convert " "between Unicode filenames and bytes filenames." @@ -1706,11 +1711,11 @@ msgstr "" "d'erreur` pour les conversions de " "noms de fichier entre Unicode et octets." -#: glossary.rst:723 +#: glossary.rst:729 msgid "list" msgstr "list" -#: glossary.rst:725 +#: glossary.rst:731 msgid "" "A built-in Python :term:`sequence`. Despite its name it is more akin to an " "array in other languages than to a linked list since access to elements is " @@ -1720,11 +1725,11 @@ msgstr "" "``list`` ressemble plus à un tableau (*array* dans la plupart des langages) " "qu'à une liste chaînée puisque les accès se font en O(1)." -#: glossary.rst:728 +#: glossary.rst:734 msgid "list comprehension" msgstr "liste en compréhension (ou liste en intention)" -#: glossary.rst:730 +#: glossary.rst:736 msgid "" "A compact way to process all or part of the elements in a sequence and " "return a list with the results. ``result = ['{:#04x}'.format(x) for x in " @@ -1739,11 +1744,11 @@ msgstr "" "hexadécimal (``0x…``). La clause :keyword:`if` est optionnelle. Si elle est " "omise, tous les éléments du ``range(256)`` seront utilisés." -#: glossary.rst:736 +#: glossary.rst:742 msgid "loader" msgstr "chargeur" -#: glossary.rst:738 +#: glossary.rst:744 msgid "" "An object that loads a module. It must define a method named :meth:" "`load_module`. A loader is typically returned by a :term:`finder`. See :pep:" @@ -1755,19 +1760,19 @@ msgstr "" "`. Voir la :pep:`302` pour plus de détails et :class:`importlib.ABC." "Loader` pour sa :term:`classe de base abstraite`." -#: glossary.rst:742 +#: glossary.rst:748 msgid "magic method" msgstr "méthode magique" -#: glossary.rst:746 +#: glossary.rst:752 msgid "An informal synonym for :term:`special method`." msgstr "Un synonyme informel de :term:`special method`." -#: glossary.rst:747 +#: glossary.rst:753 msgid "mapping" msgstr "tableau de correspondances" -#: glossary.rst:749 +#: glossary.rst:755 msgid "" "A container object that supports arbitrary key lookups and implements the " "methods specified in the :class:`~collections.abc.Mapping` or :class:" @@ -1784,11 +1789,11 @@ msgstr "" "`dict`, :class:`collections.defaultdict`, :class:`collections.OrderedDict` " "et :class:`collections.Counter`." -#: glossary.rst:755 +#: glossary.rst:761 msgid "meta path finder" msgstr "chercheur dans les méta-chemins" -#: glossary.rst:757 +#: glossary.rst:763 msgid "" "A :term:`finder` returned by a search of :data:`sys.meta_path`. Meta path " "finders are related to, but different from :term:`path entry finders `." -#: glossary.rst:761 +#: glossary.rst:767 msgid "" "See :class:`importlib.abc.MetaPathFinder` for the methods that meta path " "finders implement." @@ -1806,11 +1811,11 @@ msgstr "" "Voir :class:`importlib.abc.MetaPathFinder` pour les méthodes que les " "chercheurs dans les méta-chemins doivent implémenter." -#: glossary.rst:763 +#: glossary.rst:769 msgid "metaclass" msgstr "métaclasse" -#: glossary.rst:765 +#: glossary.rst:771 msgid "" "The class of a class. Class definitions create a class name, a class " "dictionary, and a list of base classes. The metaclass is responsible for " @@ -1834,15 +1839,15 @@ msgstr "" "*multi-threads*, suivre la création d'objets, implémenter des singletons et " "bien d'autres tâches." -#: glossary.rst:775 +#: glossary.rst:781 msgid "More information can be found in :ref:`metaclasses`." msgstr "Plus d'informations sont disponibles dans : :ref:`metaclasses`." -#: glossary.rst:776 +#: glossary.rst:782 msgid "method" msgstr "méthode" -#: glossary.rst:778 +#: glossary.rst:784 msgid "" "A function which is defined inside a class body. If called as an attribute " "of an instance of that class, the method will get the instance object as its " @@ -1854,11 +1859,11 @@ msgstr "" "premier :term:`argument` (qui, par convention, est habituellement nommé " "``self``). Voir :term:`function` et :term:`nested scope`." -#: glossary.rst:782 +#: glossary.rst:788 msgid "method resolution order" msgstr "ordre de résolution des méthodes" -#: glossary.rst:784 +#: glossary.rst:790 msgid "" "Method Resolution Order is the order in which base classes are searched for " "a member during lookup. See `The Python 2.3 Method Resolution Order `_ pour plus de détails sur l'algorithme utilisé par " "l'interpréteur Python depuis la version 2.3." -#: glossary.rst:788 +#: glossary.rst:794 msgid "module" msgstr "module" -#: glossary.rst:790 +#: glossary.rst:796 msgid "" "An object that serves as an organizational unit of Python code. Modules " "have a namespace containing arbitrary Python objects. Modules are loaded " @@ -1886,15 +1891,15 @@ msgstr "" "modules ont un espace de nommage et peuvent contenir n'importe quels objets " "Python. Charger des modules est appelé :term:`importer `." -#: glossary.rst:794 +#: glossary.rst:800 msgid "See also :term:`package`." msgstr "Voir aussi :term:`paquet`." -#: glossary.rst:795 +#: glossary.rst:801 msgid "module spec" msgstr "spécificateur de module" -#: glossary.rst:797 +#: glossary.rst:803 msgid "" "A namespace containing the import-related information used to load a module. " "An instance of :class:`importlib.machinery.ModuleSpec`." @@ -1903,19 +1908,19 @@ msgstr "" "utilisées pour charger un module. C'est une instance de la classe :class:" "`importlib.machinery.ModuleSpec`." -#: glossary.rst:799 +#: glossary.rst:805 msgid "MRO" msgstr "MRO" -#: glossary.rst:801 +#: glossary.rst:807 msgid "See :term:`method resolution order`." msgstr "Voir :term:`ordre de résolution des méthodes`." -#: glossary.rst:802 +#: glossary.rst:808 msgid "mutable" msgstr "muable" -#: glossary.rst:804 +#: glossary.rst:810 msgid "" "Mutable objects can change their value but keep their :func:`id`. See also :" "term:`immutable`." @@ -1923,11 +1928,11 @@ msgstr "" "Un objet muable peut changer de valeur tout en gardant le même :func:`id`. " "Voir aussi :term:`immuable`." -#: glossary.rst:806 +#: glossary.rst:812 msgid "named tuple" msgstr "n-uplet nommé" -#: glossary.rst:808 +#: glossary.rst:814 msgid "" "The term \"named tuple\" applies to any type or class that inherits from " "tuple and whose indexable elements are also accessible using named " @@ -1938,7 +1943,7 @@ msgstr "" "accessibles en utilisant des attributs nommés. Les types et classes peuvent " "avoir aussi d'autres caractéristiques." -#: glossary.rst:812 +#: glossary.rst:818 msgid "" "Several built-in types are named tuples, including the values returned by :" "func:`time.localtime` and :func:`os.stat`. Another example is :data:`sys." @@ -1948,7 +1953,7 @@ msgstr "" "retournées par :func:`time.localtime` et :func:`os.stat`. Un autre exemple " "est :data:`sys.float_info` ::" -#: glossary.rst:823 +#: glossary.rst:829 msgid "" "Some named tuples are built-in types (such as the above examples). " "Alternatively, a named tuple can be created from a regular class definition " @@ -1965,11 +1970,11 @@ msgstr "" "méthodes supplémentaires qui ne seront pas trouvées dans celles écrites à la " "main ni dans les n-uplets nommés natifs." -#: glossary.rst:830 +#: glossary.rst:836 msgid "namespace" msgstr "espace de nommage" -#: glossary.rst:832 +#: glossary.rst:838 msgid "" "The place where a variable is stored. Namespaces are implemented as " "dictionaries. There are the local, global and built-in namespaces as well " @@ -1993,11 +1998,11 @@ msgstr "" "implémentées respectivement dans les modules :mod:`random` et :mod:" "`itertools`." -#: glossary.rst:842 +#: glossary.rst:848 msgid "namespace package" msgstr "paquet-espace de nommage" -#: glossary.rst:844 +#: glossary.rst:850 msgid "" "A :pep:`420` :term:`package` which serves only as a container for " "subpackages. Namespace packages may have no physical representation, and " @@ -2009,15 +2014,15 @@ msgstr "" "aucune représentation physique et, plus spécifiquement, ne sont pas comme " "un :term:`paquet classique` puisqu'ils n'ont pas de fichier ``__init__.py``." -#: glossary.rst:849 +#: glossary.rst:855 msgid "See also :term:`module`." msgstr "Voir aussi :term:`module`." -#: glossary.rst:850 +#: glossary.rst:856 msgid "nested scope" msgstr "portée imbriquée" -#: glossary.rst:852 +#: glossary.rst:858 msgid "" "The ability to refer to a variable in an enclosing definition. For " "instance, a function defined inside another function can refer to variables " @@ -2035,11 +2040,11 @@ msgstr "" "dans l'espace de nommage global, le mot clef :keyword:`nonlocal` permet " "d'écrire dans l'espace de nommage dans lequel est déclarée la variable." -#: glossary.rst:859 +#: glossary.rst:865 msgid "new-style class" msgstr "nouvelle classe" -#: glossary.rst:861 +#: glossary.rst:867 msgid "" "Old name for the flavor of classes now used for all class objects. In " "earlier Python versions, only new-style classes could use Python's newer, " @@ -2052,11 +2057,11 @@ msgstr "" "__slots__`, les descripteurs, les propriétés, :meth:`__getattribute__`, les " "méthodes de classe et les méthodes statiques." -#: glossary.rst:865 +#: glossary.rst:871 msgid "object" msgstr "objet" -#: glossary.rst:867 +#: glossary.rst:873 msgid "" "Any data with state (attributes or value) and defined behavior (methods). " "Also the ultimate base class of any :term:`new-style class`." @@ -2066,11 +2071,11 @@ msgstr "" "l'ancêtre commun à absolument toutes les :term:`nouvelles classes `." -#: glossary.rst:870 +#: glossary.rst:876 msgid "package" msgstr "paquet" -#: glossary.rst:872 +#: glossary.rst:878 msgid "" "A Python :term:`module` which can contain submodules or recursively, " "subpackages. Technically, a package is a Python module with an ``__path__`` " @@ -2080,15 +2085,15 @@ msgstr "" "paquets. Techniquement, un paquet est un module qui possède un attribut " "``__path__``." -#: glossary.rst:876 +#: glossary.rst:882 msgid "See also :term:`regular package` and :term:`namespace package`." msgstr "Voir aussi :term:`paquet classique` et :term:`namespace package`." -#: glossary.rst:877 +#: glossary.rst:883 msgid "parameter" msgstr "paramètre" -#: glossary.rst:879 +#: glossary.rst:885 msgid "" "A named entity in a :term:`function` (or method) definition that specifies " "an :term:`argument` (or in some cases, arguments) that the function can " @@ -2098,7 +2103,7 @@ msgstr "" "décrivant un :term:`argument` (ou dans certains cas des arguments) que la " "fonction accepte. Il existe cinq sortes de paramètres :" -#: glossary.rst:883 +#: glossary.rst:889 msgid "" ":dfn:`positional-or-keyword`: specifies an argument that can be passed " "either :term:`positionally ` or as a :term:`keyword argument " @@ -2110,7 +2115,7 @@ msgstr "" "C'est le type de paramètre par défaut. Par exemple, *foo* et *bar* dans " "l'exemple suivant ::" -#: glossary.rst:892 +#: glossary.rst:898 msgid "" ":dfn:`positional-only`: specifies an argument that can be supplied only by " "position. Positional-only parameters can be defined by including a ``/`` " @@ -2122,7 +2127,7 @@ msgstr "" "un caractère \"/\" dans la liste de paramètres de la définition de fonction " "après eux. Par exemple : *posonly1* et *posonly2* dans le code suivant ::" -#: glossary.rst:901 +#: glossary.rst:907 msgid "" ":dfn:`keyword-only`: specifies an argument that can be supplied only by " "keyword. Keyword-only parameters can be defined by including a single var-" @@ -2136,7 +2141,7 @@ msgstr "" "liste des paramètres avant eux. Par exemple, *kw_only1* et *kw_only2* dans " "le code suivant ::" -#: glossary.rst:909 +#: glossary.rst:915 msgid "" ":dfn:`var-positional`: specifies that an arbitrary sequence of positional " "arguments can be provided (in addition to any positional arguments already " @@ -2149,7 +2154,7 @@ msgstr "" "d'autres paramètres). Un tel paramètre peut être défini en préfixant son nom " "par une ``*``. Par exemple *args* ci-après ::" -#: glossary.rst:917 +#: glossary.rst:923 msgid "" ":dfn:`var-keyword`: specifies that arbitrarily many keyword arguments can be " "provided (in addition to any keyword arguments already accepted by other " @@ -2161,7 +2166,7 @@ msgstr "" "d'autres paramètres). Un tel paramètre est défini en préfixant le nom du " "paramètre par ``**``. Par exemple, *kwargs* ci-dessus." -#: glossary.rst:923 +#: glossary.rst:929 msgid "" "Parameters can specify both optional and required arguments, as well as " "default values for some optional arguments." @@ -2169,7 +2174,7 @@ msgstr "" "Les paramètres peuvent spécifier des arguments obligatoires ou optionnels, " "ainsi que des valeurs par défaut pour les arguments optionnels." -#: glossary.rst:926 +#: glossary.rst:932 msgid "" "See also the :term:`argument` glossary entry, the FAQ question on :ref:`the " "difference between arguments and parameters `, " @@ -2181,11 +2186,11 @@ msgstr "" "parameter>` dans la FAQ, la classe :class:`inspect.Parameter`, la section :" "ref:`function` et la :pep:`362`." -#: glossary.rst:930 +#: glossary.rst:936 msgid "path entry" msgstr "entrée de chemin" -#: glossary.rst:932 +#: glossary.rst:938 msgid "" "A single location on the :term:`import path` which the :term:`path based " "finder` consults to find modules for importing." @@ -2194,11 +2199,11 @@ msgstr "" "path* en anglais, d'où le *path*) que le :term:`chercheur basé sur les " "chemins ` consulte pour trouver des modules à importer." -#: glossary.rst:934 +#: glossary.rst:940 msgid "path entry finder" msgstr "chercheur de chemins" -#: glossary.rst:936 +#: glossary.rst:942 msgid "" "A :term:`finder` returned by a callable on :data:`sys.path_hooks` (i.e. a :" "term:`path entry hook`) which knows how to locate modules given a :term:" @@ -2209,7 +2214,7 @@ msgstr "" "path `) qui sait où trouver des modules lorsqu'on lui donne " "une :term:`entrée de path `." -#: glossary.rst:940 +#: glossary.rst:946 msgid "" "See :class:`importlib.abc.PathEntryFinder` for the methods that path entry " "finders implement." @@ -2217,11 +2222,11 @@ msgstr "" "Voir :class:`importlib.abc.PathEntryFinder` pour les méthodes qu'un " "chercheur d'entrée dans *path* doit implémenter." -#: glossary.rst:942 +#: glossary.rst:948 msgid "path entry hook" msgstr "point d'entrée pour la recherche dans *path*" -#: glossary.rst:944 +#: glossary.rst:950 msgid "" "A callable on the :data:`sys.path_hook` list which returns a :term:`path " "entry finder` if it knows how to find modules on a specific :term:`path " @@ -2231,11 +2236,11 @@ msgstr "" "d'entrée dans path ` s'il sait où trouver des modules " "pour une :term:`entrée dans path ` donnée." -#: glossary.rst:947 +#: glossary.rst:953 msgid "path based finder" msgstr "chercheur basé sur les chemins" -#: glossary.rst:949 +#: glossary.rst:955 msgid "" "One of the default :term:`meta path finders ` which " "searches an :term:`import path` for modules." @@ -2244,11 +2249,11 @@ msgstr "" "défaut qui cherche des modules dans un :term:`chemin des importations " "`." -#: glossary.rst:951 +#: glossary.rst:957 msgid "path-like object" msgstr "objet simili-chemin" -#: glossary.rst:953 +#: glossary.rst:959 msgid "" "An object representing a file system path. A path-like object is either a :" "class:`str` or :class:`bytes` object representing a path, or an object " @@ -2268,11 +2273,11 @@ msgstr "" "peuvent être utilisées, respectivement, pour garantir un résultat de type :" "class:`str` ou :class:`bytes` à la place. A été Introduit par la :pep:`519`." -#: glossary.rst:961 +#: glossary.rst:967 msgid "PEP" msgstr "PEP" -#: glossary.rst:963 +#: glossary.rst:969 msgid "" "Python Enhancement Proposal. A PEP is a design document providing " "information to the Python community, or describing a new feature for Python " @@ -2285,7 +2290,7 @@ msgstr "" "ou son environnement. Les PEP doivent fournir une spécification technique " "concise et une justification des fonctionnalités proposées." -#: glossary.rst:969 +#: glossary.rst:975 msgid "" "PEPs are intended to be the primary mechanisms for proposing major new " "features, for collecting community input on an issue, and for documenting " @@ -2300,15 +2305,15 @@ msgstr "" "l’établissement d’un consensus au sein de la communauté et de documenter les " "opinions contradictoires." -#: glossary.rst:975 +#: glossary.rst:981 msgid "See :pep:`1`." msgstr "Voir :pep:`1`." -#: glossary.rst:976 +#: glossary.rst:982 msgid "portion" msgstr "portion" -#: glossary.rst:978 +#: glossary.rst:984 msgid "" "A set of files in a single directory (possibly stored in a zip file) that " "contribute to a namespace package, as defined in :pep:`420`." @@ -2317,15 +2322,15 @@ msgstr "" "fichier zip) qui contribue à l'espace de nommage d'un paquet, tel que défini " "dans la :pep:`420`." -#: glossary.rst:980 +#: glossary.rst:986 msgid "positional argument" msgstr "argument positionnel" -#: glossary.rst:983 +#: glossary.rst:989 msgid "provisional API" msgstr "API provisoire" -#: glossary.rst:985 +#: glossary.rst:991 msgid "" "A provisional API is one which has been deliberately excluded from the " "standard library's backwards compatibility guarantees. While major changes " @@ -2344,7 +2349,7 @@ msgstr "" "surviendront que si de sérieux problèmes sont découverts et qu'ils n'avaient " "pas été identifiés avant l'ajout de l'API." -#: glossary.rst:994 +#: glossary.rst:1000 msgid "" "Even for provisional APIs, backwards incompatible changes are seen as a " "\"solution of last resort\" - every attempt will still be made to find a " @@ -2355,7 +2360,7 @@ msgstr "" "possible sera fait pour tenter de résoudre les problèmes en conservant la " "rétrocompatibilité." -#: glossary.rst:998 +#: glossary.rst:1004 msgid "" "This process allows the standard library to continue to evolve over time, " "without locking in problematic design errors for extended periods of time. " @@ -2365,19 +2370,19 @@ msgstr "" "le temps, sans se bloquer longtemps sur des erreurs d'architecture. Voir la :" "pep:`411` pour plus de détails." -#: glossary.rst:1001 +#: glossary.rst:1007 msgid "provisional package" msgstr "paquet provisoire" -#: glossary.rst:1003 +#: glossary.rst:1009 msgid "See :term:`provisional API`." msgstr "Voir :term:`provisional API`." -#: glossary.rst:1004 +#: glossary.rst:1010 msgid "Python 3000" msgstr "Python 3000" -#: glossary.rst:1006 +#: glossary.rst:1012 msgid "" "Nickname for the Python 3.x release line (coined long ago when the release " "of version 3 was something in the distant future.) This is also abbreviated " @@ -2386,11 +2391,11 @@ msgstr "" "Surnom donné à la série des Python 3.x (très vieux surnom donné à l'époque " "où Python 3 représentait un futur lointain). Aussi abrégé *Py3k*." -#: glossary.rst:1009 +#: glossary.rst:1015 msgid "Pythonic" msgstr "*Pythonique*" -#: glossary.rst:1011 +#: glossary.rst:1017 msgid "" "An idea or piece of code which closely follows the most common idioms of the " "Python language, rather than implementing code using concepts common to " @@ -2406,16 +2411,16 @@ msgstr "" "les gens qui ne sont pas habitués à Python utilisent parfois un compteur " "numérique à la place ::" -#: glossary.rst:1021 +#: glossary.rst:1027 msgid "As opposed to the cleaner, Pythonic method::" msgstr "" "Plutôt qu'utiliser la méthode, plus propre et élégante, donc *Pythonique* ::" -#: glossary.rst:1025 +#: glossary.rst:1031 msgid "qualified name" msgstr "nom qualifié" -#: glossary.rst:1027 +#: glossary.rst:1033 msgid "" "A dotted name showing the \"path\" from a module's global scope to a class, " "function or method defined in that module, as defined in :pep:`3155`. For " @@ -2427,7 +2432,7 @@ msgstr "" "module, tel que défini dans la :pep:`3155`. Pour les fonctions et classes de " "premier niveau, le nom qualifié est le même que le nom de l'objet ::" -#: glossary.rst:1044 +#: glossary.rst:1050 msgid "" "When used to refer to modules, the *fully qualified name* means the entire " "dotted path to the module, including any parent packages, e.g. ``email.mime." @@ -2438,11 +2443,11 @@ msgstr "" "par des points) vers le module, incluant tous les paquets parents. Par " "exemple : ``email.mime.text`` ::" -#: glossary.rst:1051 +#: glossary.rst:1057 msgid "reference count" msgstr "nombre de références" -#: glossary.rst:1053 +#: glossary.rst:1059 msgid "" "The number of references to an object. When the reference count of an " "object drops to zero, it is deallocated. Reference counting is generally " @@ -2458,11 +2463,11 @@ msgstr "" "func:`~sys.getrefcount` que les développeurs peuvent utiliser pour obtenir " "le nombre de références à un objet donné." -#: glossary.rst:1059 +#: glossary.rst:1065 msgid "regular package" msgstr "paquet classique" -#: glossary.rst:1061 +#: glossary.rst:1067 msgid "" "A traditional :term:`package`, such as a directory containing an ``__init__." "py`` file." @@ -2470,15 +2475,15 @@ msgstr "" ":term:`paquet` traditionnel, tel qu'un dossier contenant un fichier " "``__init__.py``." -#: glossary.rst:1064 +#: glossary.rst:1070 msgid "See also :term:`namespace package`." msgstr "Voir aussi :term:`paquet-espace de nommage `." -#: glossary.rst:1065 +#: glossary.rst:1071 msgid "__slots__" msgstr "__slots__" -#: glossary.rst:1067 +#: glossary.rst:1073 msgid "" "A declaration inside a class that saves memory by pre-declaring space for " "instance attributes and eliminating instance dictionaries. Though popular, " @@ -2493,11 +2498,11 @@ msgstr "" "nombre d'instances dans une application devient un sujet critique pour la " "mémoire." -#: glossary.rst:1072 +#: glossary.rst:1078 msgid "sequence" msgstr "séquence" -#: glossary.rst:1074 +#: glossary.rst:1080 msgid "" "An :term:`iterable` which supports efficient element access using integer " "indices via the :meth:`__getitem__` special method and defines a :meth:" @@ -2516,7 +2521,7 @@ msgstr "" "*mapping* plutôt qu'une séquence, car ses accès se font par une clé " "arbitraire :term:`immuable` plutôt qu'un nombre entier." -#: glossary.rst:1083 +#: glossary.rst:1089 msgid "" "The :class:`collections.abc.Sequence` abstract base class defines a much " "richer interface that goes beyond just :meth:`__getitem__` and :meth:" @@ -2530,11 +2535,11 @@ msgstr "" "et :meth:`__reversed__`. Les types qui implémentent cette interface étendue " "peuvent s'enregistrer explicitement en utilisant :func:`~abc.register`." -#: glossary.rst:1090 +#: glossary.rst:1096 msgid "set comprehension" msgstr "ensemble en compréhension (ou ensemble en intension)" -#: glossary.rst:1092 +#: glossary.rst:1098 msgid "" "A compact way to process all or part of the elements in an iterable and " "return a set with the results. ``results = {c for c in 'abracadabra' if c " @@ -2546,11 +2551,11 @@ msgstr "" "'abracadabra' if c not in 'abc'}`` génère l'ensemble contenant les lettres " "« r » et « d » ``{'r', 'd'}``. Voir :ref:`comprehensions`." -#: glossary.rst:1096 +#: glossary.rst:1102 msgid "single dispatch" msgstr "distribution simple" -#: glossary.rst:1098 +#: glossary.rst:1104 msgid "" "A form of :term:`generic function` dispatch where the implementation is " "chosen based on the type of a single argument." @@ -2559,11 +2564,11 @@ msgstr "" "générique>`, où l'implémentation est choisie en fonction du type d'un seul " "argument." -#: glossary.rst:1100 +#: glossary.rst:1106 msgid "slice" msgstr "tranche" -#: glossary.rst:1102 +#: glossary.rst:1108 msgid "" "An object usually containing a portion of a :term:`sequence`. A slice is " "created using the subscript notation, ``[]`` with colons between numbers " @@ -2576,11 +2581,11 @@ msgstr "" "``variable_name[1:3:5]``. Cette notation utilise des objets :class:`slice` " "en interne." -#: glossary.rst:1106 +#: glossary.rst:1112 msgid "special method" msgstr "méthode spéciale" -#: glossary.rst:1110 +#: glossary.rst:1116 msgid "" "A method that is called implicitly by Python to execute a certain operation " "on a type, such as addition. Such methods have names starting and ending " @@ -2592,11 +2597,11 @@ msgstr "" "ont des noms commençant et terminant par des doubles tirets bas. Les " "méthodes spéciales sont documentées dans :ref:`specialnames`." -#: glossary.rst:1114 +#: glossary.rst:1120 msgid "statement" msgstr "instruction" -#: glossary.rst:1116 +#: glossary.rst:1122 msgid "" "A statement is part of a suite (a \"block\" of code). A statement is either " "an :term:`expression` or one of several constructs with a keyword, such as :" @@ -2607,18 +2612,18 @@ msgstr "" "constructions basées sur un mot-clé, comme :keyword:`if`, :keyword:`while` " "ou :keyword:`for`." -#: glossary.rst:1119 +#: glossary.rst:1125 msgid "strong reference" msgstr "référence forte" -#: glossary.rst:1121 +#: glossary.rst:1127 msgid "" "In Python's C API, a strong reference is a reference to an object which " "increments the object's reference count when it is created and decrements " "the object's reference count when it is deleted." msgstr "" -#: glossary.rst:1125 +#: glossary.rst:1131 msgid "" "The :c:func:`Py_NewRef` function can be used to create a strong reference to " "an object. Usually, the :c:func:`Py_DECREF` function must be called on the " @@ -2626,25 +2631,25 @@ msgid "" "leaking one reference." msgstr "" -#: glossary.rst:1130 +#: glossary.rst:1136 msgid "See also :term:`borrowed reference`." msgstr "Voir aussi :term:`référence empruntée`." -#: glossary.rst:1131 +#: glossary.rst:1137 msgid "text encoding" msgstr "encodage de texte" -#: glossary.rst:1133 +#: glossary.rst:1139 msgid "A codec which encodes Unicode strings to bytes." msgstr "" "Codec (codeur-décodeur) qui convertit des chaînes de caractères Unicode en " "octets (classe *bytes*)." -#: glossary.rst:1134 +#: glossary.rst:1140 msgid "text file" msgstr "fichier texte" -#: glossary.rst:1136 +#: glossary.rst:1142 msgid "" "A :term:`file object` able to read and write :class:`str` objects. Often, a " "text file actually accesses a byte-oriented datastream and handles the :term:" @@ -2659,7 +2664,7 @@ msgstr "" "ou ``'w'``), :data:`sys.stdin`, :data:`sys.stdout` et les instances de :" "class:`io.StringIO`." -#: glossary.rst:1143 +#: glossary.rst:1149 msgid "" "See also :term:`binary file` for a file object able to read and write :term:" "`bytes-like objects `." @@ -2667,11 +2672,11 @@ msgstr "" "Voir aussi :term:`binary file` pour un objet fichier capable de lire et " "d'écrire :term:`bytes-like objects `." -#: glossary.rst:1145 +#: glossary.rst:1151 msgid "triple-quoted string" msgstr "chaîne entre triple guillemets" -#: glossary.rst:1147 +#: glossary.rst:1153 msgid "" "A string which is bound by three instances of either a quotation mark (\") " "or an apostrophe ('). While they don't provide any functionality not " @@ -2690,11 +2695,11 @@ msgstr "" "\\``. Elle est ainsi particulièrement utile pour les chaînes de " "documentation (*docstrings*)." -#: glossary.rst:1154 +#: glossary.rst:1160 msgid "type" msgstr "type" -#: glossary.rst:1156 +#: glossary.rst:1162 msgid "" "The type of a Python object determines what kind of object it is; every " "object has a type. An object's type is accessible as its :attr:`~instance." @@ -2704,15 +2709,15 @@ msgstr "" "objets ont un type. Le type d'un objet peut être obtenu via son attribut :" "attr:`~instance.__class__` ou via ``type(obj)``." -#: glossary.rst:1160 +#: glossary.rst:1166 msgid "type alias" msgstr "alias de type" -#: glossary.rst:1162 +#: glossary.rst:1168 msgid "A synonym for a type, created by assigning the type to an identifier." msgstr "Synonyme d'un type, créé en affectant le type à un identifiant." -#: glossary.rst:1164 +#: glossary.rst:1170 msgid "" "Type aliases are useful for simplifying :term:`type hints `. For " "example::" @@ -2720,19 +2725,19 @@ msgstr "" "Les alias de types sont utiles pour simplifier les :term:`indications de " "types `. Par exemple ::" -#: glossary.rst:1171 +#: glossary.rst:1177 msgid "could be made more readable like this::" msgstr "pourrait être rendu plus lisible comme ceci ::" -#: glossary.rst:1192 +#: glossary.rst:1198 msgid "See :mod:`typing` and :pep:`484`, which describe this functionality." msgstr "Voir :mod:`typing` et :pep:`484`, qui décrivent cette fonctionnalité." -#: glossary.rst:1179 +#: glossary.rst:1185 msgid "type hint" msgstr "indication de type" -#: glossary.rst:1181 +#: glossary.rst:1187 msgid "" "An :term:`annotation` that specifies the expected type for a variable, a " "class attribute, or a function parameter or return value." @@ -2740,7 +2745,7 @@ msgstr "" "Le :term:`annotation` qui spécifie le type attendu pour une variable, un " "attribut de classe, un paramètre de fonction ou une valeur de retour." -#: glossary.rst:1184 +#: glossary.rst:1190 msgid "" "Type hints are optional and are not enforced by Python but they are useful " "to static type analysis tools, and aid IDEs with code completion and " @@ -2751,7 +2756,7 @@ msgstr "" "statique et aident les IDE à compléter et à réusiner (*code refactoring* en " "anglais) le code." -#: glossary.rst:1188 +#: glossary.rst:1194 msgid "" "Type hints of global variables, class attributes, and functions, but not " "local variables, can be accessed using :func:`typing.get_type_hints`." @@ -2760,11 +2765,11 @@ msgstr "" "fonctions, mais pas de variables locales, peuvent être consultés en " "utilisant :func:`typing.get_type_hints`." -#: glossary.rst:1193 +#: glossary.rst:1199 msgid "universal newlines" msgstr "retours à la ligne universels" -#: glossary.rst:1195 +#: glossary.rst:1201 msgid "" "A manner of interpreting text streams in which all of the following are " "recognized as ending a line: the Unix end-of-line convention ``'\\n'``, the " @@ -2778,22 +2783,22 @@ msgstr "" "``'\\r'``. Voir la :pep:`278` et la :pep:`3116`, ainsi que la fonction :func:" "`bytes.splitlines` pour d'autres usages." -#: glossary.rst:1200 +#: glossary.rst:1206 msgid "variable annotation" msgstr "annotation de variable" -#: glossary.rst:1202 +#: glossary.rst:1208 msgid "An :term:`annotation` of a variable or a class attribute." msgstr ":term:`annotation` d'une variable ou d'un attribut de classe." -#: glossary.rst:1204 +#: glossary.rst:1210 msgid "" "When annotating a variable or a class attribute, assignment is optional::" msgstr "" "Lorsque vous annotez une variable ou un attribut de classe, l'affectation " "est facultative ::" -#: glossary.rst:1209 +#: glossary.rst:1215 msgid "" "Variable annotations are usually used for :term:`type hints `: " "for example this variable is expected to take :class:`int` values::" @@ -2802,13 +2807,13 @@ msgstr "" "`indications de types ` : par exemple, cette variable devrait " "prendre des valeurs de type :class:`int` ::" -#: glossary.rst:1215 +#: glossary.rst:1221 msgid "Variable annotation syntax is explained in section :ref:`annassign`." msgstr "" "La syntaxe d'annotation de la variable est expliquée dans la section :ref:" "`annassign`." -#: glossary.rst:1217 +#: glossary.rst:1223 msgid "" "See :term:`function annotation`, :pep:`484` and :pep:`526`, which describe " "this functionality. Also see :ref:`annotations-howto` for best practices on " @@ -2818,11 +2823,11 @@ msgstr "" "pep:`484` et à la :pep:`526` qui décrivent cette fonctionnalité. Voir aussi :" "ref:`annotations-howto` sur les bonnes pratiques concernant les annotations." -#: glossary.rst:1221 +#: glossary.rst:1227 msgid "virtual environment" msgstr "environnement virtuel" -#: glossary.rst:1223 +#: glossary.rst:1229 msgid "" "A cooperatively isolated runtime environment that allows Python users and " "applications to install and upgrade Python distribution packages without " @@ -2834,15 +2839,15 @@ msgstr "" "des paquets sans interférer avec d'autres applications Python fonctionnant " "sur le même système." -#: glossary.rst:1228 +#: glossary.rst:1234 msgid "See also :mod:`venv`." msgstr "Voir aussi :mod:`venv`." -#: glossary.rst:1229 +#: glossary.rst:1235 msgid "virtual machine" msgstr "machine virtuelle" -#: glossary.rst:1231 +#: glossary.rst:1237 msgid "" "A computer defined entirely in software. Python's virtual machine executes " "the :term:`bytecode` emitted by the bytecode compiler." @@ -2851,11 +2856,11 @@ msgstr "" "(*virtual machine*) de Python exécute le :term:`bytecode` produit par le " "compilateur de *bytecode*." -#: glossary.rst:1233 +#: glossary.rst:1239 msgid "Zen of Python" msgstr "Le zen de Python" -#: glossary.rst:1235 +#: glossary.rst:1241 msgid "" "Listing of Python design principles and philosophies that are helpful in " "understanding and using the language. The listing can be found by typing " @@ -2865,6 +2870,13 @@ msgstr "" "langage. Cette liste peut être obtenue en tapant \"``import this``\" dans " "une invite Python interactive." +#~ msgid "" +#~ "See :pep:`483` for more details, and :mod:`typing` or :ref:`generic alias " +#~ "type ` for its uses." +#~ msgstr "" +#~ "Voir la :pep:`483` pour plus de détails, et :mod:`typing` ou :ref:`alias " +#~ "générique de type ` pour ses utilisations." + #~ msgid "" #~ "A pseudo-module which programmers can use to enable new language features " #~ "which are not compatible with the current interpreter." diff --git a/howto/descriptor.po b/howto/descriptor.po index 110ce990..53ac3e6c 100644 --- a/howto/descriptor.po +++ b/howto/descriptor.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2020-12-17 21:41+0100\n" "Last-Translator: Mathieu Dupuy \n" "Language-Team: FRENCH \n" @@ -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:1285 +#: howto/descriptor.rst:1292 #, fuzzy msgid "Class methods" msgstr "méthode de classe" -#: howto/descriptor.rst:1287 +#: howto/descriptor.rst:1294 #, 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:1305 +#: howto/descriptor.rst:1312 #, 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:1322 +#: howto/descriptor.rst:1329 #, 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:1332 +#: howto/descriptor.rst:1339 #, 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:1381 +#: howto/descriptor.rst:1388 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:1401 +#: howto/descriptor.rst:1408 msgid "Member objects and __slots__" msgstr "" -#: howto/descriptor.rst:1403 +#: howto/descriptor.rst:1410 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:1407 +#: howto/descriptor.rst:1414 msgid "" "1. Provides immediate detection of bugs due to misspelled attribute " "assignments. Only attribute names specified in ``__slots__`` are allowed:" msgstr "" -#: howto/descriptor.rst:1423 +#: howto/descriptor.rst:1430 msgid "" "2. Helps create immutable objects where descriptors manage access to private " "attributes stored in ``__slots__``:" msgstr "" -#: howto/descriptor.rst:1458 +#: howto/descriptor.rst:1465 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,19 +1181,19 @@ msgid "" "only matters when a large number of instances are going to be created." msgstr "" -#: howto/descriptor.rst:1463 +#: howto/descriptor.rst:1470 msgid "" "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 +#: howto/descriptor.rst:1473 msgid "" "5. Blocks tools like :func:`functools.cached_property` which require an " "instance dictionary to function correctly:" msgstr "" -#: howto/descriptor.rst:1488 +#: howto/descriptor.rst:1495 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 " @@ -1203,37 +1203,37 @@ msgid "" "managed by member descriptors:" msgstr "" -#: howto/descriptor.rst:1531 +#: howto/descriptor.rst:1538 msgid "" "The :meth:`type.__new__` method takes care of adding member objects to class " "variables:" msgstr "" -#: howto/descriptor.rst:1547 +#: howto/descriptor.rst:1554 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:1582 +#: howto/descriptor.rst:1589 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:1596 +#: howto/descriptor.rst:1603 msgid "" "At this point, the metaclass has loaded member objects for *x* and *y*::" msgstr "" -#: howto/descriptor.rst:1617 +#: howto/descriptor.rst:1624 msgid "" "When instances are created, they have a ``slot_values`` list where the " "attributes are stored:" msgstr "" -#: howto/descriptor.rst:1629 +#: howto/descriptor.rst:1636 msgid "Misspelled or unassigned attributes will raise an exception:" msgstr "" diff --git a/library/__main__.po b/library/__main__.po index 1150d8d3..1e303bd3 100644 --- a/library/__main__.po +++ b/library/__main__.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-10-28 17:30+0200\n" "Last-Translator: Jean Abou Samra \n" "Language-Team: FRENCH \n" @@ -163,11 +163,12 @@ msgid "Idiomatic Usage" msgstr "Utilisation idiomatique" #: library/__main__.rst:118 +#, fuzzy msgid "" "Some modules contain code that is intended for script use only, like parsing " -"command-line arguments or fetching data from standard input. When a module " -"like this were to be imported from a different module, for example to unit " -"test it, the script code would unintentionally execute as well." +"command-line arguments or fetching data from standard input. If a module " +"like this was imported from a different module, for example to unit test it, " +"the script code would unintentionally execute as well." msgstr "" "Il arrive qu'un module contienne du code qui ne doit s'exécuter que lorsque " "le module est utilisé comme script. On peut penser à l'analyse des arguments " @@ -329,9 +330,10 @@ msgstr "" "données ::" #: library/__main__.rst:233 +#, fuzzy msgid "" "Note that ``from .student import search_students`` is an example of a " -"relative import. This import style must be used when referencing modules " +"relative import. This import style can be used when referencing modules " "within a package. For more details, see :ref:`intra-package-references` in " "the :ref:`tut-modules` section of the tutorial." msgstr "" diff --git a/library/asyncio-eventloop.po b/library/asyncio-eventloop.po index 3f8a3f29..bbb02562 100644 --- a/library/asyncio-eventloop.po +++ b/library/asyncio-eventloop.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2019-06-10 15:50+0200\n" "Last-Translator: Julien Palard \n" "Language-Team: FRENCH \n" @@ -246,8 +246,8 @@ msgid "" "used." msgstr "" -#: library/asyncio-eventloop.rst:171 library/asyncio-eventloop.rst:1083 -#: library/asyncio-eventloop.rst:1468 +#: library/asyncio-eventloop.rst:171 library/asyncio-eventloop.rst:1088 +#: library/asyncio-eventloop.rst:1473 msgid "Example::" msgstr "Exemple ::" @@ -480,8 +480,8 @@ msgstr "" msgid "The socket type will be :py:data:`~socket.SOCK_STREAM`." msgstr "" -#: library/asyncio-eventloop.rst:383 library/asyncio-eventloop.rst:999 -#: library/asyncio-eventloop.rst:1015 +#: library/asyncio-eventloop.rst:383 library/asyncio-eventloop.rst:1004 +#: library/asyncio-eventloop.rst:1020 msgid "" "*protocol_factory* must be a callable returning an :ref:`asyncio protocol " "` implementation." @@ -596,7 +596,7 @@ msgid "" "``getaddrinfo()``, similarly to *host* and *port*." msgstr "" -#: library/asyncio-eventloop.rst:455 library/asyncio-eventloop.rst:808 +#: library/asyncio-eventloop.rst:455 library/asyncio-eventloop.rst:813 msgid "" "*ssl_handshake_timeout* is (for a TLS connection) the time in seconds to " "wait for the TLS handshake to complete before aborting the connection. " @@ -623,17 +623,17 @@ msgid "For more information: https://tools.ietf.org/html/rfc6555" msgstr "" #: library/asyncio-eventloop.rst:476 library/asyncio-eventloop.rst:593 -#: library/asyncio-eventloop.rst:746 +#: library/asyncio-eventloop.rst:751 msgid "The *ssl_handshake_timeout* parameter." msgstr "" -#: library/asyncio-eventloop.rst:480 library/asyncio-eventloop.rst:676 +#: library/asyncio-eventloop.rst:480 library/asyncio-eventloop.rst:681 msgid "" "The socket option :py:data:`~socket.TCP_NODELAY` is set by default for all " "TCP connections." msgstr "" -#: library/asyncio-eventloop.rst:485 library/asyncio-eventloop.rst:681 +#: library/asyncio-eventloop.rst:485 library/asyncio-eventloop.rst:686 msgid "Added support for SSL/TLS in :class:`ProactorEventLoop`." msgstr "" @@ -682,7 +682,7 @@ msgid "The socket type will be :py:data:`~socket.SOCK_DGRAM`." msgstr "" #: library/asyncio-eventloop.rst:522 library/asyncio-eventloop.rst:618 -#: library/asyncio-eventloop.rst:729 +#: library/asyncio-eventloop.rst:734 msgid "" "*protocol_factory* must be a callable returning a :ref:`protocol ` implementation." @@ -782,8 +782,8 @@ msgid "" "information about arguments to this method." msgstr "" -#: library/asyncio-eventloop.rst:590 library/asyncio-eventloop.rst:710 -#: library/asyncio-eventloop.rst:1066 +#: library/asyncio-eventloop.rst:590 library/asyncio-eventloop.rst:715 +#: library/asyncio-eventloop.rst:1071 msgid ":ref:`Availability `: Unix." msgstr ":ref:`Disponibilité ` : Unix." @@ -837,55 +837,63 @@ msgstr "" #: library/asyncio-eventloop.rst:634 msgid "" +"The *port* parameter can be set to specify which port the server should " +"listen on. If ``0`` or ``None`` (the default), a random unused port will be " +"selected (note that if *host* resolves to multiple network interfaces, a " +"different random port will be selected for each interface)." +msgstr "" + +#: library/asyncio-eventloop.rst:639 +msgid "" "*family* can be set to either :data:`socket.AF_INET` or :data:`~socket." "AF_INET6` to force the socket to use IPv4 or IPv6. If not set, the *family* " "will be determined from host name (defaults to :data:`~socket.AF_UNSPEC`)." msgstr "" -#: library/asyncio-eventloop.rst:639 +#: library/asyncio-eventloop.rst:644 msgid "*flags* is a bitmask for :meth:`getaddrinfo`." msgstr "*flags* est un masque de bits pour :meth:`getaddrinfo`." -#: library/asyncio-eventloop.rst:641 +#: library/asyncio-eventloop.rst:646 msgid "" "*sock* can optionally be specified in order to use a preexisting socket " "object. If specified, *host* and *port* must not be specified." msgstr "" -#: library/asyncio-eventloop.rst:644 +#: library/asyncio-eventloop.rst:649 msgid "" "*backlog* is the maximum number of queued connections passed to :meth:" "`~socket.socket.listen` (defaults to 100)." msgstr "" -#: library/asyncio-eventloop.rst:647 +#: library/asyncio-eventloop.rst:652 msgid "" "*ssl* can be set to an :class:`~ssl.SSLContext` instance to enable TLS over " "the accepted connections." msgstr "" -#: library/asyncio-eventloop.rst:650 +#: library/asyncio-eventloop.rst:655 msgid "" "*reuse_address* tells the kernel to reuse a local socket in ``TIME_WAIT`` " "state, without waiting for its natural timeout to expire. If not specified " "will automatically be set to ``True`` on Unix." msgstr "" -#: library/asyncio-eventloop.rst:655 +#: library/asyncio-eventloop.rst:660 msgid "" "*reuse_port* tells the kernel to allow this endpoint to be bound to the same " "port as other existing endpoints are bound to, so long as they all set this " "flag when being created. This option is not supported on Windows." msgstr "" -#: library/asyncio-eventloop.rst:660 +#: library/asyncio-eventloop.rst:665 msgid "" "*ssl_handshake_timeout* is (for a TLS server) the time in seconds to wait " "for the TLS handshake to complete before aborting the connection. ``60.0`` " "seconds if ``None`` (default)." msgstr "" -#: library/asyncio-eventloop.rst:664 +#: library/asyncio-eventloop.rst:669 msgid "" "*start_serving* set to ``True`` (the default) causes the created server to " "start accepting connections immediately. When set to ``False``, the user " @@ -893,103 +901,103 @@ msgid "" "to make the server to start accepting connections." msgstr "" -#: library/asyncio-eventloop.rst:672 +#: library/asyncio-eventloop.rst:677 msgid "Added *ssl_handshake_timeout* and *start_serving* parameters." msgstr "" -#: library/asyncio-eventloop.rst:685 +#: library/asyncio-eventloop.rst:690 msgid "The *host* parameter can be a sequence of strings." msgstr "" -#: library/asyncio-eventloop.rst:689 +#: library/asyncio-eventloop.rst:694 msgid "" "The :func:`start_server` function is a higher-level alternative API that " "returns a pair of :class:`StreamReader` and :class:`StreamWriter` that can " "be used in an async/await code." msgstr "" -#: library/asyncio-eventloop.rst:698 +#: library/asyncio-eventloop.rst:703 msgid "" "Similar to :meth:`loop.create_server` but works with the :py:data:`~socket." "AF_UNIX` socket family." msgstr "" -#: library/asyncio-eventloop.rst:701 +#: library/asyncio-eventloop.rst:706 msgid "" "*path* is the name of a Unix domain socket, and is required, unless a *sock* " "argument is provided. Abstract Unix sockets, :class:`str`, :class:`bytes`, " "and :class:`~pathlib.Path` paths are supported." msgstr "" -#: library/asyncio-eventloop.rst:706 +#: library/asyncio-eventloop.rst:711 msgid "" "See the documentation of the :meth:`loop.create_server` method for " "information about arguments to this method." msgstr "" -#: library/asyncio-eventloop.rst:713 +#: library/asyncio-eventloop.rst:718 msgid "The *ssl_handshake_timeout* and *start_serving* parameters." msgstr "" -#: library/asyncio-eventloop.rst:717 +#: library/asyncio-eventloop.rst:722 msgid "The *path* parameter can now be a :class:`~pathlib.Path` object." msgstr "" -#: library/asyncio-eventloop.rst:722 +#: library/asyncio-eventloop.rst:727 msgid "Wrap an already accepted connection into a transport/protocol pair." msgstr "" -#: library/asyncio-eventloop.rst:724 +#: library/asyncio-eventloop.rst:729 msgid "" "This method can be used by servers that accept connections outside of " "asyncio but that use asyncio to handle them." msgstr "" -#: library/asyncio-eventloop.rst:727 library/asyncio-eventloop.rst:794 +#: library/asyncio-eventloop.rst:732 library/asyncio-eventloop.rst:799 msgid "Parameters:" msgstr "Paramètres :" -#: library/asyncio-eventloop.rst:732 +#: library/asyncio-eventloop.rst:737 msgid "" "*sock* is a preexisting socket object returned from :meth:`socket.accept " "`." msgstr "" -#: library/asyncio-eventloop.rst:735 +#: library/asyncio-eventloop.rst:740 msgid "" "*ssl* can be set to an :class:`~ssl.SSLContext` to enable SSL over the " "accepted connections." msgstr "" -#: library/asyncio-eventloop.rst:738 +#: library/asyncio-eventloop.rst:743 msgid "" "*ssl_handshake_timeout* is (for an SSL connection) the time in seconds to " "wait for the SSL handshake to complete before aborting the connection. " "``60.0`` seconds if ``None`` (default)." msgstr "" -#: library/asyncio-eventloop.rst:742 +#: library/asyncio-eventloop.rst:747 msgid "Returns a ``(transport, protocol)`` pair." msgstr "" -#: library/asyncio-eventloop.rst:752 +#: library/asyncio-eventloop.rst:757 msgid "Transferring files" msgstr "" -#: library/asyncio-eventloop.rst:757 +#: library/asyncio-eventloop.rst:762 msgid "" "Send a *file* over a *transport*. Return the total number of bytes sent." msgstr "" -#: library/asyncio-eventloop.rst:760 +#: library/asyncio-eventloop.rst:765 msgid "The method uses high-performance :meth:`os.sendfile` if available." msgstr "" -#: library/asyncio-eventloop.rst:762 +#: library/asyncio-eventloop.rst:767 msgid "*file* must be a regular file object opened in binary mode." msgstr "" -#: library/asyncio-eventloop.rst:764 library/asyncio-eventloop.rst:954 +#: library/asyncio-eventloop.rst:769 library/asyncio-eventloop.rst:959 msgid "" "*offset* tells from where to start reading the file. If specified, *count* " "is the total number of bytes to transmit as opposed to sending the file " @@ -998,97 +1006,97 @@ msgid "" "obtain the actual number of bytes sent." msgstr "" -#: library/asyncio-eventloop.rst:771 +#: library/asyncio-eventloop.rst:776 msgid "" "*fallback* set to ``True`` makes asyncio to manually read and send the file " "when the platform does not support the sendfile system call (e.g. Windows or " "SSL socket on Unix)." msgstr "" -#: library/asyncio-eventloop.rst:775 +#: library/asyncio-eventloop.rst:780 msgid "" "Raise :exc:`SendfileNotAvailableError` if the system does not support the " "*sendfile* syscall and *fallback* is ``False``." msgstr "" -#: library/asyncio-eventloop.rst:782 +#: library/asyncio-eventloop.rst:787 msgid "TLS Upgrade" msgstr "" -#: library/asyncio-eventloop.rst:788 +#: library/asyncio-eventloop.rst:793 msgid "Upgrade an existing transport-based connection to TLS." msgstr "Convertit une connexion existante en connexion TLS." -#: library/asyncio-eventloop.rst:790 +#: library/asyncio-eventloop.rst:795 msgid "" "Return a new transport instance, that the *protocol* must start using " "immediately after the *await*. The *transport* instance passed to the " "*start_tls* method should never be used again." msgstr "" -#: library/asyncio-eventloop.rst:796 +#: library/asyncio-eventloop.rst:801 msgid "" "*transport* and *protocol* instances that methods like :meth:`~loop." "create_server` and :meth:`~loop.create_connection` return." msgstr "" -#: library/asyncio-eventloop.rst:800 +#: library/asyncio-eventloop.rst:805 msgid "*sslcontext*: a configured instance of :class:`~ssl.SSLContext`." msgstr "" -#: library/asyncio-eventloop.rst:802 +#: library/asyncio-eventloop.rst:807 msgid "" "*server_side* pass ``True`` when a server-side connection is being upgraded " "(like the one created by :meth:`~loop.create_server`)." msgstr "" -#: library/asyncio-eventloop.rst:805 +#: library/asyncio-eventloop.rst:810 msgid "" "*server_hostname*: sets or overrides the host name that the target server's " "certificate will be matched against." msgstr "" -#: library/asyncio-eventloop.rst:816 +#: library/asyncio-eventloop.rst:821 msgid "Watching file descriptors" msgstr "Surveiller des descripteurs de fichiers" -#: library/asyncio-eventloop.rst:820 +#: library/asyncio-eventloop.rst:825 msgid "" "Start monitoring the *fd* file descriptor for read availability and invoke " "*callback* with the specified arguments once *fd* is available for reading." msgstr "" -#: library/asyncio-eventloop.rst:826 +#: library/asyncio-eventloop.rst:831 msgid "Stop monitoring the *fd* file descriptor for read availability." msgstr "" -#: library/asyncio-eventloop.rst:830 +#: library/asyncio-eventloop.rst:835 msgid "" "Start monitoring the *fd* file descriptor for write availability and invoke " "*callback* with the specified arguments once *fd* is available for writing." msgstr "" -#: library/asyncio-eventloop.rst:834 library/asyncio-eventloop.rst:1053 +#: library/asyncio-eventloop.rst:839 library/asyncio-eventloop.rst:1058 msgid "" "Use :func:`functools.partial` :ref:`to pass keyword arguments ` to *callback*." msgstr "" -#: library/asyncio-eventloop.rst:839 +#: library/asyncio-eventloop.rst:844 msgid "Stop monitoring the *fd* file descriptor for write availability." msgstr "" -#: library/asyncio-eventloop.rst:841 +#: library/asyncio-eventloop.rst:846 msgid "" "See also :ref:`Platform Support ` section for some " "limitations of these methods." msgstr "" -#: library/asyncio-eventloop.rst:846 +#: library/asyncio-eventloop.rst:851 msgid "Working with socket objects directly" msgstr "" -#: library/asyncio-eventloop.rst:848 +#: library/asyncio-eventloop.rst:853 msgid "" "In general, protocol implementations that use transport-based APIs such as :" "meth:`loop.create_connection` and :meth:`loop.create_server` are faster than " @@ -1097,46 +1105,46 @@ msgid "" "socket` objects directly is more convenient." msgstr "" -#: library/asyncio-eventloop.rst:857 +#: library/asyncio-eventloop.rst:862 msgid "" "Receive up to *nbytes* from *sock*. Asynchronous version of :meth:`socket." "recv() `." msgstr "" -#: library/asyncio-eventloop.rst:860 +#: library/asyncio-eventloop.rst:865 msgid "Return the received data as a bytes object." msgstr "" -#: library/asyncio-eventloop.rst:862 library/asyncio-eventloop.rst:876 -#: library/asyncio-eventloop.rst:891 library/asyncio-eventloop.rst:904 -#: library/asyncio-eventloop.rst:930 library/asyncio-eventloop.rst:968 +#: library/asyncio-eventloop.rst:867 library/asyncio-eventloop.rst:881 +#: library/asyncio-eventloop.rst:896 library/asyncio-eventloop.rst:909 +#: library/asyncio-eventloop.rst:935 library/asyncio-eventloop.rst:973 msgid "*sock* must be a non-blocking socket." msgstr "Le connecteur *sock* ne doit pas être bloquant." -#: library/asyncio-eventloop.rst:864 +#: library/asyncio-eventloop.rst:869 msgid "" "Even though this method was always documented as a coroutine method, " "releases before Python 3.7 returned a :class:`Future`. Since Python 3.7 this " "is an ``async def`` method." msgstr "" -#: library/asyncio-eventloop.rst:871 +#: library/asyncio-eventloop.rst:876 msgid "" "Receive data from *sock* into the *buf* buffer. Modeled after the blocking :" "meth:`socket.recv_into() ` method." msgstr "" -#: library/asyncio-eventloop.rst:874 +#: library/asyncio-eventloop.rst:879 msgid "Return the number of bytes written to the buffer." msgstr "" -#: library/asyncio-eventloop.rst:882 +#: library/asyncio-eventloop.rst:887 msgid "" "Send *data* to the *sock* socket. Asynchronous version of :meth:`socket." "sendall() `." msgstr "" -#: library/asyncio-eventloop.rst:885 +#: library/asyncio-eventloop.rst:890 msgid "" "This method continues to send to the socket until either all data in *data* " "has been sent or an error occurs. ``None`` is returned on success. On " @@ -1145,23 +1153,23 @@ msgid "" "the connection." msgstr "" -#: library/asyncio-eventloop.rst:893 +#: library/asyncio-eventloop.rst:898 msgid "" "Even though the method was always documented as a coroutine method, before " "Python 3.7 it returned an :class:`Future`. Since Python 3.7, this is an " "``async def`` method." msgstr "" -#: library/asyncio-eventloop.rst:900 +#: library/asyncio-eventloop.rst:905 msgid "Connect *sock* to a remote socket at *address*." msgstr "" -#: library/asyncio-eventloop.rst:902 +#: library/asyncio-eventloop.rst:907 msgid "" "Asynchronous version of :meth:`socket.connect() `." msgstr "" -#: library/asyncio-eventloop.rst:906 +#: library/asyncio-eventloop.rst:911 msgid "" "``address`` no longer needs to be resolved. ``sock_connect`` will try to " "check if the *address* is already resolved by calling :func:`socket." @@ -1169,19 +1177,19 @@ msgid "" "*address*." msgstr "" -#: library/asyncio-eventloop.rst:915 +#: library/asyncio-eventloop.rst:920 msgid "" ":meth:`loop.create_connection` and :func:`asyncio.open_connection() " "`." msgstr "" -#: library/asyncio-eventloop.rst:921 +#: library/asyncio-eventloop.rst:926 msgid "" "Accept a connection. Modeled after the blocking :meth:`socket.accept() " "` method." msgstr "" -#: library/asyncio-eventloop.rst:924 +#: library/asyncio-eventloop.rst:929 msgid "" "The socket must be bound to an address and listening for connections. The " "return value is a pair ``(conn, address)`` where *conn* is a *new* socket " @@ -1189,64 +1197,64 @@ msgid "" "the address bound to the socket on the other end of the connection." msgstr "" -#: library/asyncio-eventloop.rst:932 +#: library/asyncio-eventloop.rst:937 msgid "" "Even though the method was always documented as a coroutine method, before " "Python 3.7 it returned a :class:`Future`. Since Python 3.7, this is an " "``async def`` method." msgstr "" -#: library/asyncio-eventloop.rst:939 +#: library/asyncio-eventloop.rst:944 msgid ":meth:`loop.create_server` and :func:`start_server`." msgstr "" -#: library/asyncio-eventloop.rst:944 +#: library/asyncio-eventloop.rst:949 msgid "" "Send a file using high-performance :mod:`os.sendfile` if possible. Return " "the total number of bytes sent." msgstr "" -#: library/asyncio-eventloop.rst:947 +#: library/asyncio-eventloop.rst:952 msgid "" "Asynchronous version of :meth:`socket.sendfile() `." msgstr "" -#: library/asyncio-eventloop.rst:949 +#: library/asyncio-eventloop.rst:954 msgid "" "*sock* must be a non-blocking :const:`socket.SOCK_STREAM` :class:`~socket." "socket`." msgstr "" -#: library/asyncio-eventloop.rst:952 +#: library/asyncio-eventloop.rst:957 msgid "*file* must be a regular file object open in binary mode." msgstr "" -#: library/asyncio-eventloop.rst:961 +#: library/asyncio-eventloop.rst:966 msgid "" "*fallback*, when set to ``True``, makes asyncio manually read and send the " "file when the platform does not support the sendfile syscall (e.g. Windows " "or SSL socket on Unix)." msgstr "" -#: library/asyncio-eventloop.rst:965 +#: library/asyncio-eventloop.rst:970 msgid "" "Raise :exc:`SendfileNotAvailableError` if the system does not support " "*sendfile* syscall and *fallback* is ``False``." msgstr "" -#: library/asyncio-eventloop.rst:974 +#: library/asyncio-eventloop.rst:979 msgid "DNS" msgstr "" -#: library/asyncio-eventloop.rst:979 +#: library/asyncio-eventloop.rst:984 msgid "Asynchronous version of :meth:`socket.getaddrinfo`." msgstr "" -#: library/asyncio-eventloop.rst:983 +#: library/asyncio-eventloop.rst:988 msgid "Asynchronous version of :meth:`socket.getnameinfo`." msgstr "" -#: library/asyncio-eventloop.rst:985 +#: library/asyncio-eventloop.rst:990 msgid "" "Both *getaddrinfo* and *getnameinfo* methods were always documented to " "return a coroutine, but prior to Python 3.7 they were, in fact, returning :" @@ -1254,67 +1262,67 @@ msgid "" "coroutines." msgstr "" -#: library/asyncio-eventloop.rst:993 +#: library/asyncio-eventloop.rst:998 msgid "Working with pipes" msgstr "" -#: library/asyncio-eventloop.rst:997 +#: library/asyncio-eventloop.rst:1002 msgid "Register the read end of *pipe* in the event loop." msgstr "" "Branche l'extrémité en lecture du tube *pipe* à la boucle d'évènements." -#: library/asyncio-eventloop.rst:1002 +#: library/asyncio-eventloop.rst:1007 msgid "*pipe* is a :term:`file-like object `." msgstr "" -#: library/asyncio-eventloop.rst:1004 +#: library/asyncio-eventloop.rst:1009 msgid "" "Return pair ``(transport, protocol)``, where *transport* supports the :class:" "`ReadTransport` interface and *protocol* is an object instantiated by the " "*protocol_factory*." msgstr "" -#: library/asyncio-eventloop.rst:1008 library/asyncio-eventloop.rst:1024 +#: library/asyncio-eventloop.rst:1013 library/asyncio-eventloop.rst:1029 msgid "" "With :class:`SelectorEventLoop` event loop, the *pipe* is set to non-" "blocking mode." msgstr "" -#: library/asyncio-eventloop.rst:1013 +#: library/asyncio-eventloop.rst:1018 msgid "Register the write end of *pipe* in the event loop." msgstr "Branche l'extrémité en écriture de *pipe* à la boucle d'évènements." -#: library/asyncio-eventloop.rst:1018 +#: library/asyncio-eventloop.rst:1023 msgid "*pipe* is :term:`file-like object `." msgstr "" -#: library/asyncio-eventloop.rst:1020 +#: library/asyncio-eventloop.rst:1025 msgid "" "Return pair ``(transport, protocol)``, where *transport* supports :class:" "`WriteTransport` interface and *protocol* is an object instantiated by the " "*protocol_factory*." msgstr "" -#: library/asyncio-eventloop.rst:1029 +#: library/asyncio-eventloop.rst:1034 msgid "" ":class:`SelectorEventLoop` does not support the above methods on Windows. " "Use :class:`ProactorEventLoop` instead for Windows." msgstr "" -#: library/asyncio-eventloop.rst:1034 +#: library/asyncio-eventloop.rst:1039 msgid "" "The :meth:`loop.subprocess_exec` and :meth:`loop.subprocess_shell` methods." msgstr "" -#: library/asyncio-eventloop.rst:1039 +#: library/asyncio-eventloop.rst:1044 msgid "Unix signals" msgstr "Signaux Unix" -#: library/asyncio-eventloop.rst:1043 +#: library/asyncio-eventloop.rst:1048 msgid "Set *callback* as the handler for the *signum* signal." msgstr "" -#: library/asyncio-eventloop.rst:1045 +#: library/asyncio-eventloop.rst:1050 msgid "" "The callback will be invoked by *loop*, along with other queued callbacks " "and runnable coroutines of that event loop. Unlike signal handlers " @@ -1322,56 +1330,56 @@ msgid "" "function is allowed to interact with the event loop." msgstr "" -#: library/asyncio-eventloop.rst:1050 +#: library/asyncio-eventloop.rst:1055 msgid "" "Raise :exc:`ValueError` if the signal number is invalid or uncatchable. " "Raise :exc:`RuntimeError` if there is a problem setting up the handler." msgstr "" -#: library/asyncio-eventloop.rst:1056 +#: library/asyncio-eventloop.rst:1061 msgid "" "Like :func:`signal.signal`, this function must be invoked in the main thread." msgstr "" -#: library/asyncio-eventloop.rst:1061 +#: library/asyncio-eventloop.rst:1066 msgid "Remove the handler for the *sig* signal." msgstr "Supprime le gestionnaire du signal *sig*." -#: library/asyncio-eventloop.rst:1063 +#: library/asyncio-eventloop.rst:1068 msgid "" "Return ``True`` if the signal handler was removed, or ``False`` if no " "handler was set for the given signal." msgstr "" -#: library/asyncio-eventloop.rst:1070 +#: library/asyncio-eventloop.rst:1075 msgid "The :mod:`signal` module." msgstr "Le module :mod:`signal`." -#: library/asyncio-eventloop.rst:1074 +#: library/asyncio-eventloop.rst:1079 msgid "Executing code in thread or process pools" msgstr "" -#: library/asyncio-eventloop.rst:1078 +#: library/asyncio-eventloop.rst:1083 msgid "Arrange for *func* to be called in the specified executor." msgstr "" -#: library/asyncio-eventloop.rst:1080 +#: library/asyncio-eventloop.rst:1085 msgid "" "The *executor* argument should be an :class:`concurrent.futures.Executor` " "instance. The default executor is used if *executor* is ``None``." msgstr "" -#: library/asyncio-eventloop.rst:1124 +#: library/asyncio-eventloop.rst:1129 msgid "This method returns a :class:`asyncio.Future` object." msgstr "" -#: library/asyncio-eventloop.rst:1126 +#: library/asyncio-eventloop.rst:1131 msgid "" "Use :func:`functools.partial` :ref:`to pass keyword arguments ` to *func*." msgstr "" -#: library/asyncio-eventloop.rst:1129 +#: library/asyncio-eventloop.rst:1134 msgid "" ":meth:`loop.run_in_executor` no longer configures the ``max_workers`` of the " "thread pool executor it creates, instead leaving it up to the thread pool " @@ -1379,38 +1387,38 @@ msgid "" "default." msgstr "" -#: library/asyncio-eventloop.rst:1138 +#: library/asyncio-eventloop.rst:1143 msgid "" "Set *executor* as the default executor used by :meth:`run_in_executor`. " "*executor* should be an instance of :class:`~concurrent.futures." "ThreadPoolExecutor`." msgstr "" -#: library/asyncio-eventloop.rst:1142 +#: library/asyncio-eventloop.rst:1147 msgid "" "Using an executor that is not an instance of :class:`~concurrent.futures." "ThreadPoolExecutor` is deprecated and will trigger an error in Python 3.9." msgstr "" -#: library/asyncio-eventloop.rst:1147 +#: library/asyncio-eventloop.rst:1152 msgid "" "*executor* must be an instance of :class:`concurrent.futures." "ThreadPoolExecutor`." msgstr "" -#: library/asyncio-eventloop.rst:1152 +#: library/asyncio-eventloop.rst:1157 msgid "Error Handling API" msgstr "API de gestion d'erreur" -#: library/asyncio-eventloop.rst:1154 +#: library/asyncio-eventloop.rst:1159 msgid "Allows customizing how exceptions are handled in the event loop." msgstr "" -#: library/asyncio-eventloop.rst:1158 +#: library/asyncio-eventloop.rst:1163 msgid "Set *handler* as the new event loop exception handler." msgstr "" -#: library/asyncio-eventloop.rst:1160 +#: library/asyncio-eventloop.rst:1165 msgid "" "If *handler* is ``None``, the default exception handler will be set. " "Otherwise, *handler* must be a callable with the signature matching ``(loop, " @@ -1419,161 +1427,161 @@ msgid "" "(see :meth:`call_exception_handler` documentation for details about context)." msgstr "" -#: library/asyncio-eventloop.rst:1170 +#: library/asyncio-eventloop.rst:1175 msgid "" "Return the current exception handler, or ``None`` if no custom exception " "handler was set." msgstr "" -#: library/asyncio-eventloop.rst:1177 +#: library/asyncio-eventloop.rst:1182 msgid "Default exception handler." msgstr "Gestionnaire d'exception par défaut." -#: library/asyncio-eventloop.rst:1179 +#: library/asyncio-eventloop.rst:1184 msgid "" "This is called when an exception occurs and no exception handler is set. " "This can be called by a custom exception handler that wants to defer to the " "default handler behavior." msgstr "" -#: library/asyncio-eventloop.rst:1183 +#: library/asyncio-eventloop.rst:1188 msgid "" "*context* parameter has the same meaning as in :meth:" "`call_exception_handler`." msgstr "" -#: library/asyncio-eventloop.rst:1188 +#: library/asyncio-eventloop.rst:1193 msgid "Call the current event loop exception handler." msgstr "" "Appelle le gestionnaire d'exception de la boucle d'évènements actuelle." -#: library/asyncio-eventloop.rst:1190 +#: library/asyncio-eventloop.rst:1195 msgid "" "*context* is a ``dict`` object containing the following keys (new keys may " "be introduced in future Python versions):" msgstr "" -#: library/asyncio-eventloop.rst:1193 +#: library/asyncio-eventloop.rst:1198 msgid "'message': Error message;" msgstr "``message`` : Message d'erreur ;" -#: library/asyncio-eventloop.rst:1194 +#: library/asyncio-eventloop.rst:1199 msgid "'exception' (optional): Exception object;" msgstr "``exception`` (optionnel): Un objet exception ;" -#: library/asyncio-eventloop.rst:1195 +#: library/asyncio-eventloop.rst:1200 msgid "'future' (optional): :class:`asyncio.Future` instance;" msgstr "" -#: library/asyncio-eventloop.rst:1196 +#: library/asyncio-eventloop.rst:1201 msgid "'task' (optional): :class:`asyncio.Task` instance;" msgstr "" -#: library/asyncio-eventloop.rst:1197 +#: library/asyncio-eventloop.rst:1202 msgid "'handle' (optional): :class:`asyncio.Handle` instance;" msgstr "" -#: library/asyncio-eventloop.rst:1198 +#: library/asyncio-eventloop.rst:1203 msgid "'protocol' (optional): :ref:`Protocol ` instance;" msgstr "" -#: library/asyncio-eventloop.rst:1199 +#: library/asyncio-eventloop.rst:1204 msgid "'transport' (optional): :ref:`Transport ` instance;" msgstr "" -#: library/asyncio-eventloop.rst:1200 +#: library/asyncio-eventloop.rst:1205 msgid "'socket' (optional): :class:`socket.socket` instance;" msgstr "" -#: library/asyncio-eventloop.rst:1202 +#: library/asyncio-eventloop.rst:1207 msgid "'asyncgen' (optional): Asynchronous generator that caused" msgstr "" -#: library/asyncio-eventloop.rst:1202 +#: library/asyncio-eventloop.rst:1207 #, fuzzy msgid "the exception." msgstr "Gestionnaire d'exception par défaut." -#: library/asyncio-eventloop.rst:1206 +#: library/asyncio-eventloop.rst:1211 msgid "" "This method should not be overloaded in subclassed event loops. For custom " "exception handling, use the :meth:`set_exception_handler()` method." msgstr "" -#: library/asyncio-eventloop.rst:1211 +#: library/asyncio-eventloop.rst:1216 msgid "Enabling debug mode" msgstr "Active le mode débogage" -#: library/asyncio-eventloop.rst:1215 +#: library/asyncio-eventloop.rst:1220 msgid "Get the debug mode (:class:`bool`) of the event loop." msgstr "" -#: library/asyncio-eventloop.rst:1217 +#: library/asyncio-eventloop.rst:1222 msgid "" "The default value is ``True`` if the environment variable :envvar:" "`PYTHONASYNCIODEBUG` is set to a non-empty string, ``False`` otherwise." msgstr "" -#: library/asyncio-eventloop.rst:1223 +#: library/asyncio-eventloop.rst:1228 msgid "Set the debug mode of the event loop." msgstr "Active le mode débogage pour la boucle d'évènements." -#: library/asyncio-eventloop.rst:1227 +#: library/asyncio-eventloop.rst:1232 msgid "" "The new :ref:`Python Development Mode ` can now also be used to " "enable the debug mode." msgstr "" -#: library/asyncio-eventloop.rst:1232 +#: library/asyncio-eventloop.rst:1237 msgid "The :ref:`debug mode of asyncio `." msgstr "" -#: library/asyncio-eventloop.rst:1236 +#: library/asyncio-eventloop.rst:1241 msgid "Running Subprocesses" msgstr "" -#: library/asyncio-eventloop.rst:1238 +#: library/asyncio-eventloop.rst:1243 msgid "" "Methods described in this subsections are low-level. In regular async/await " "code consider using the high-level :func:`asyncio.create_subprocess_shell` " "and :func:`asyncio.create_subprocess_exec` convenience functions instead." msgstr "" -#: library/asyncio-eventloop.rst:1245 +#: library/asyncio-eventloop.rst:1250 msgid "" "The default asyncio event loop on **Windows** does not support subprocesses. " "See :ref:`Subprocess Support on Windows ` for " "details." msgstr "" -#: library/asyncio-eventloop.rst:1253 +#: library/asyncio-eventloop.rst:1258 msgid "" "Create a subprocess from one or more string arguments specified by *args*." msgstr "" -#: library/asyncio-eventloop.rst:1256 +#: library/asyncio-eventloop.rst:1261 msgid "*args* must be a list of strings represented by:" msgstr "" -#: library/asyncio-eventloop.rst:1258 +#: library/asyncio-eventloop.rst:1263 #, fuzzy msgid ":class:`str`;" msgstr ":class:`str`" -#: library/asyncio-eventloop.rst:1259 +#: library/asyncio-eventloop.rst:1264 msgid "" "or :class:`bytes`, encoded to the :ref:`filesystem encoding `." msgstr "" -#: library/asyncio-eventloop.rst:1262 +#: library/asyncio-eventloop.rst:1267 msgid "" "The first string specifies the program executable, and the remaining strings " "specify the arguments. Together, string arguments form the ``argv`` of the " "program." msgstr "" -#: library/asyncio-eventloop.rst:1266 +#: library/asyncio-eventloop.rst:1271 msgid "" "This is similar to the standard library :class:`subprocess.Popen` class " "called with ``shell=False`` and the list of strings passed as the first " @@ -1581,133 +1589,133 @@ msgid "" "which is list of strings, *subprocess_exec* takes multiple string arguments." msgstr "" -#: library/asyncio-eventloop.rst:1272 +#: library/asyncio-eventloop.rst:1277 msgid "" "The *protocol_factory* must be a callable returning a subclass of the :class:" "`asyncio.SubprocessProtocol` class." msgstr "" -#: library/asyncio-eventloop.rst:1275 +#: library/asyncio-eventloop.rst:1280 msgid "Other parameters:" msgstr "Autres paramètres :" -#: library/asyncio-eventloop.rst:1277 +#: library/asyncio-eventloop.rst:1282 msgid "*stdin* can be any of these:" msgstr "" -#: library/asyncio-eventloop.rst:1279 +#: library/asyncio-eventloop.rst:1284 msgid "" "a file-like object representing a pipe to be connected to the subprocess's " "standard input stream using :meth:`~loop.connect_write_pipe`" msgstr "" -#: library/asyncio-eventloop.rst:1282 library/asyncio-eventloop.rst:1294 -#: library/asyncio-eventloop.rst:1306 +#: library/asyncio-eventloop.rst:1287 library/asyncio-eventloop.rst:1299 +#: library/asyncio-eventloop.rst:1311 msgid "" "the :const:`subprocess.PIPE` constant (default) which will create a new pipe " "and connect it," msgstr "" -#: library/asyncio-eventloop.rst:1284 library/asyncio-eventloop.rst:1296 -#: library/asyncio-eventloop.rst:1308 +#: library/asyncio-eventloop.rst:1289 library/asyncio-eventloop.rst:1301 +#: library/asyncio-eventloop.rst:1313 msgid "" "the value ``None`` which will make the subprocess inherit the file " "descriptor from this process" msgstr "" -#: library/asyncio-eventloop.rst:1286 library/asyncio-eventloop.rst:1298 -#: library/asyncio-eventloop.rst:1310 +#: library/asyncio-eventloop.rst:1291 library/asyncio-eventloop.rst:1303 +#: library/asyncio-eventloop.rst:1315 msgid "" "the :const:`subprocess.DEVNULL` constant which indicates that the special :" "data:`os.devnull` file will be used" msgstr "" -#: library/asyncio-eventloop.rst:1289 +#: library/asyncio-eventloop.rst:1294 msgid "*stdout* can be any of these:" msgstr "" -#: library/asyncio-eventloop.rst:1291 +#: library/asyncio-eventloop.rst:1296 msgid "" "a file-like object representing a pipe to be connected to the subprocess's " "standard output stream using :meth:`~loop.connect_write_pipe`" msgstr "" -#: library/asyncio-eventloop.rst:1301 +#: library/asyncio-eventloop.rst:1306 msgid "*stderr* can be any of these:" msgstr "" -#: library/asyncio-eventloop.rst:1303 +#: library/asyncio-eventloop.rst:1308 msgid "" "a file-like object representing a pipe to be connected to the subprocess's " "standard error stream using :meth:`~loop.connect_write_pipe`" msgstr "" -#: library/asyncio-eventloop.rst:1312 +#: library/asyncio-eventloop.rst:1317 msgid "" "the :const:`subprocess.STDOUT` constant which will connect the standard " "error stream to the process' standard output stream" msgstr "" -#: library/asyncio-eventloop.rst:1315 +#: library/asyncio-eventloop.rst:1320 msgid "" "All other keyword arguments are passed to :class:`subprocess.Popen` without " "interpretation, except for *bufsize*, *universal_newlines*, *shell*, *text*, " "*encoding* and *errors*, which should not be specified at all." msgstr "" -#: library/asyncio-eventloop.rst:1320 +#: library/asyncio-eventloop.rst:1325 msgid "" "The ``asyncio`` subprocess API does not support decoding the streams as " "text. :func:`bytes.decode` can be used to convert the bytes returned from " "the stream to text." msgstr "" -#: library/asyncio-eventloop.rst:1324 +#: library/asyncio-eventloop.rst:1329 msgid "" "See the constructor of the :class:`subprocess.Popen` class for documentation " "on other arguments." msgstr "" -#: library/asyncio-eventloop.rst:1327 +#: library/asyncio-eventloop.rst:1332 msgid "" "Returns a pair of ``(transport, protocol)``, where *transport* conforms to " "the :class:`asyncio.SubprocessTransport` base class and *protocol* is an " "object instantiated by the *protocol_factory*." msgstr "" -#: library/asyncio-eventloop.rst:1335 +#: library/asyncio-eventloop.rst:1340 msgid "" "Create a subprocess from *cmd*, which can be a :class:`str` or a :class:" "`bytes` string encoded to the :ref:`filesystem encoding `, using the platform's \"shell\" syntax." msgstr "" -#: library/asyncio-eventloop.rst:1340 +#: library/asyncio-eventloop.rst:1345 msgid "" "This is similar to the standard library :class:`subprocess.Popen` class " "called with ``shell=True``." msgstr "" -#: library/asyncio-eventloop.rst:1343 +#: library/asyncio-eventloop.rst:1348 msgid "" "The *protocol_factory* must be a callable returning a subclass of the :class:" "`SubprocessProtocol` class." msgstr "" -#: library/asyncio-eventloop.rst:1346 +#: library/asyncio-eventloop.rst:1351 msgid "" "See :meth:`~loop.subprocess_exec` for more details about the remaining " "arguments." msgstr "" -#: library/asyncio-eventloop.rst:1349 +#: library/asyncio-eventloop.rst:1354 msgid "" "Returns a pair of ``(transport, protocol)``, where *transport* conforms to " "the :class:`SubprocessTransport` base class and *protocol* is an object " "instantiated by the *protocol_factory*." msgstr "" -#: library/asyncio-eventloop.rst:1354 +#: library/asyncio-eventloop.rst:1359 msgid "" "It is the application's responsibility to ensure that all whitespace and " "special characters are quoted appropriately to avoid `shell injection " @@ -1717,105 +1725,105 @@ msgid "" "used to construct shell commands." msgstr "" -#: library/asyncio-eventloop.rst:1363 +#: library/asyncio-eventloop.rst:1368 msgid "Callback Handles" msgstr "" -#: library/asyncio-eventloop.rst:1367 +#: library/asyncio-eventloop.rst:1372 msgid "" "A callback wrapper object returned by :meth:`loop.call_soon`, :meth:`loop." "call_soon_threadsafe`." msgstr "" -#: library/asyncio-eventloop.rst:1372 +#: library/asyncio-eventloop.rst:1377 msgid "" "Cancel the callback. If the callback has already been canceled or executed, " "this method has no effect." msgstr "" -#: library/asyncio-eventloop.rst:1377 +#: library/asyncio-eventloop.rst:1382 msgid "Return ``True`` if the callback was cancelled." msgstr "Renvoie ``True`` si la fonction de rappel à été annulé." -#: library/asyncio-eventloop.rst:1383 +#: library/asyncio-eventloop.rst:1388 msgid "" "A callback wrapper object returned by :meth:`loop.call_later`, and :meth:" "`loop.call_at`." msgstr "" -#: library/asyncio-eventloop.rst:1386 +#: library/asyncio-eventloop.rst:1391 msgid "This class is a subclass of :class:`Handle`." msgstr "" -#: library/asyncio-eventloop.rst:1390 +#: library/asyncio-eventloop.rst:1395 msgid "Return a scheduled callback time as :class:`float` seconds." msgstr "" -#: library/asyncio-eventloop.rst:1392 +#: library/asyncio-eventloop.rst:1397 msgid "" "The time is an absolute timestamp, using the same time reference as :meth:" "`loop.time`." msgstr "" -#: library/asyncio-eventloop.rst:1399 +#: library/asyncio-eventloop.rst:1404 msgid "Server Objects" msgstr "Objets Serveur" -#: library/asyncio-eventloop.rst:1401 +#: library/asyncio-eventloop.rst:1406 msgid "" "Server objects are created by :meth:`loop.create_server`, :meth:`loop." "create_unix_server`, :func:`start_server`, and :func:`start_unix_server` " "functions." msgstr "" -#: library/asyncio-eventloop.rst:1405 +#: library/asyncio-eventloop.rst:1410 msgid "Do not instantiate the class directly." msgstr "" -#: library/asyncio-eventloop.rst:1409 +#: library/asyncio-eventloop.rst:1414 msgid "" "*Server* objects are asynchronous context managers. When used in an ``async " "with`` statement, it's guaranteed that the Server object is closed and not " "accepting new connections when the ``async with`` statement is completed::" msgstr "" -#: library/asyncio-eventloop.rst:1422 +#: library/asyncio-eventloop.rst:1427 msgid "Server object is an asynchronous context manager since Python 3.7." msgstr "" -#: library/asyncio-eventloop.rst:1427 +#: library/asyncio-eventloop.rst:1432 msgid "" "Stop serving: close listening sockets and set the :attr:`sockets` attribute " "to ``None``." msgstr "" -#: library/asyncio-eventloop.rst:1430 +#: library/asyncio-eventloop.rst:1435 msgid "" "The sockets that represent existing incoming client connections are left " "open." msgstr "" -#: library/asyncio-eventloop.rst:1433 +#: library/asyncio-eventloop.rst:1438 msgid "" "The server is closed asynchronously, use the :meth:`wait_closed` coroutine " "to wait until the server is closed." msgstr "" -#: library/asyncio-eventloop.rst:1438 +#: library/asyncio-eventloop.rst:1443 msgid "Return the event loop associated with the server object." msgstr "" -#: library/asyncio-eventloop.rst:1444 +#: library/asyncio-eventloop.rst:1449 msgid "Start accepting connections." msgstr "Commence à accepter les connexions." -#: library/asyncio-eventloop.rst:1446 +#: library/asyncio-eventloop.rst:1451 msgid "" "This method is idempotent, so it can be called when the server is already " "being serving." msgstr "" -#: library/asyncio-eventloop.rst:1449 +#: library/asyncio-eventloop.rst:1454 msgid "" "The *start_serving* keyword-only parameter to :meth:`loop.create_server` " "and :meth:`asyncio.start_server` allows creating a Server object that is not " @@ -1824,97 +1832,97 @@ msgid "" "accepting connections." msgstr "" -#: library/asyncio-eventloop.rst:1460 +#: library/asyncio-eventloop.rst:1465 msgid "" "Start accepting connections until the coroutine is cancelled. Cancellation " "of ``serve_forever`` task causes the server to be closed." msgstr "" -#: library/asyncio-eventloop.rst:1464 +#: library/asyncio-eventloop.rst:1469 msgid "" "This method can be called if the server is already accepting connections. " "Only one ``serve_forever`` task can exist per one *Server* object." msgstr "" -#: library/asyncio-eventloop.rst:1486 +#: library/asyncio-eventloop.rst:1491 msgid "Return ``True`` if the server is accepting new connections." msgstr "Donne ``True`` si le serveur accepte de nouvelles connexions." -#: library/asyncio-eventloop.rst:1492 +#: library/asyncio-eventloop.rst:1497 msgid "Wait until the :meth:`close` method completes." msgstr "Attends que la méthode :meth:`close` se termine." -#: library/asyncio-eventloop.rst:1496 +#: library/asyncio-eventloop.rst:1501 msgid "List of :class:`socket.socket` objects the server is listening on." msgstr "" -#: library/asyncio-eventloop.rst:1498 +#: library/asyncio-eventloop.rst:1503 msgid "" "Prior to Python 3.7 ``Server.sockets`` used to return an internal list of " "server sockets directly. In 3.7 a copy of that list is returned." msgstr "" -#: library/asyncio-eventloop.rst:1507 +#: library/asyncio-eventloop.rst:1512 msgid "Event Loop Implementations" msgstr "Implémentations de boucle d'évènements" -#: library/asyncio-eventloop.rst:1509 +#: library/asyncio-eventloop.rst:1514 msgid "" "asyncio ships with two different event loop implementations: :class:" "`SelectorEventLoop` and :class:`ProactorEventLoop`." msgstr "" -#: library/asyncio-eventloop.rst:1512 +#: library/asyncio-eventloop.rst:1517 msgid "" "By default asyncio is configured to use :class:`SelectorEventLoop` on Unix " "and :class:`ProactorEventLoop` on Windows." msgstr "" -#: library/asyncio-eventloop.rst:1518 +#: library/asyncio-eventloop.rst:1523 msgid "An event loop based on the :mod:`selectors` module." msgstr "" -#: library/asyncio-eventloop.rst:1520 +#: library/asyncio-eventloop.rst:1525 msgid "" "Uses the most efficient *selector* available for the given platform. It is " "also possible to manually configure the exact selector implementation to be " "used::" msgstr "" -#: library/asyncio-eventloop.rst:1532 +#: library/asyncio-eventloop.rst:1537 msgid ":ref:`Availability `: Unix, Windows." msgstr ":ref:`Disponibilité ` : Unix, Windows." -#: library/asyncio-eventloop.rst:1537 +#: library/asyncio-eventloop.rst:1542 msgid "An event loop for Windows that uses \"I/O Completion Ports\" (IOCP)." msgstr "" -#: library/asyncio-eventloop.rst:1540 +#: library/asyncio-eventloop.rst:1545 msgid ":ref:`Availability `: Windows." msgstr ":ref:`Disponibilité ` : Windows." -#: library/asyncio-eventloop.rst:1543 +#: library/asyncio-eventloop.rst:1548 msgid "" "`MSDN documentation on I/O Completion Ports `_." msgstr "" -#: library/asyncio-eventloop.rst:1549 +#: library/asyncio-eventloop.rst:1554 msgid "Abstract base class for asyncio-compliant event loops." msgstr "" -#: library/asyncio-eventloop.rst:1551 +#: library/asyncio-eventloop.rst:1556 msgid "" "The :ref:`Event Loop Methods ` section lists all methods " "that an alternative implementation of ``AbstractEventLoop`` should have " "defined." msgstr "" -#: library/asyncio-eventloop.rst:1557 +#: library/asyncio-eventloop.rst:1562 msgid "Examples" msgstr "Exemples" -#: library/asyncio-eventloop.rst:1559 +#: library/asyncio-eventloop.rst:1564 msgid "" "Note that all examples in this section **purposefully** show how to use the " "low-level event loop APIs, such as :meth:`loop.run_forever` and :meth:`loop." @@ -1922,70 +1930,70 @@ msgid "" "consider using the high-level functions like :func:`asyncio.run`." msgstr "" -#: library/asyncio-eventloop.rst:1569 +#: library/asyncio-eventloop.rst:1574 msgid "Hello World with call_soon()" msgstr "\"Hello World\" avec ``call_soon()``" -#: library/asyncio-eventloop.rst:1571 +#: library/asyncio-eventloop.rst:1576 msgid "" "An example using the :meth:`loop.call_soon` method to schedule a callback. " "The callback displays ``\"Hello World\"`` and then stops the event loop::" msgstr "" -#: library/asyncio-eventloop.rst:1595 +#: library/asyncio-eventloop.rst:1600 msgid "" "A similar :ref:`Hello World ` example created with a coroutine " "and the :func:`run` function." msgstr "" -#: library/asyncio-eventloop.rst:1602 +#: library/asyncio-eventloop.rst:1607 msgid "Display the current date with call_later()" msgstr "Afficher la date actuelle avec ``call_later()``" -#: library/asyncio-eventloop.rst:1604 +#: library/asyncio-eventloop.rst:1609 msgid "" "An example of a callback displaying the current date every second. The " "callback uses the :meth:`loop.call_later` method to reschedule itself after " "5 seconds, and then stops the event loop::" msgstr "" -#: library/asyncio-eventloop.rst:1632 +#: library/asyncio-eventloop.rst:1637 msgid "" "A similar :ref:`current date ` example created with a " "coroutine and the :func:`run` function." msgstr "" -#: library/asyncio-eventloop.rst:1639 +#: library/asyncio-eventloop.rst:1644 msgid "Watch a file descriptor for read events" msgstr "" -#: library/asyncio-eventloop.rst:1641 +#: library/asyncio-eventloop.rst:1646 msgid "" "Wait until a file descriptor received some data using the :meth:`loop." "add_reader` method and then close the event loop::" msgstr "" -#: library/asyncio-eventloop.rst:1679 +#: library/asyncio-eventloop.rst:1684 msgid "" "A similar :ref:`example ` using " "transports, protocols, and the :meth:`loop.create_connection` method." msgstr "" -#: library/asyncio-eventloop.rst:1683 +#: library/asyncio-eventloop.rst:1688 msgid "" "Another similar :ref:`example ` " "using the high-level :func:`asyncio.open_connection` function and streams." msgstr "" -#: library/asyncio-eventloop.rst:1691 +#: library/asyncio-eventloop.rst:1696 msgid "Set signal handlers for SIGINT and SIGTERM" msgstr "Définit les gestionnaires de signaux pour *SIGINT* et *SIGTERM*" -#: library/asyncio-eventloop.rst:1693 +#: library/asyncio-eventloop.rst:1698 msgid "(This ``signals`` example only works on Unix.)" msgstr "(Cet exemple ne fonctionne que sur Unix.)" -#: library/asyncio-eventloop.rst:1695 +#: library/asyncio-eventloop.rst:1700 msgid "" "Register handlers for signals :py:data:`SIGINT` and :py:data:`SIGTERM` using " "the :meth:`loop.add_signal_handler` method::" diff --git a/library/asyncio-future.po b/library/asyncio-future.po index b7873b09..e6e7ab3b 100644 --- a/library/asyncio-future.po +++ b/library/asyncio-future.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: FRENCH \n" @@ -84,52 +84,58 @@ msgid "" msgstr "" #: library/asyncio-future.rst:57 +msgid "" +"Save a reference to the result of this function, to avoid a task " +"disappearing mid execution." +msgstr "" + +#: library/asyncio-future.rst:60 msgid "The function accepts any :term:`awaitable` object." msgstr "La fonction accepte n'importe quel objet :term:`awaitable`." -#: library/asyncio-future.rst:60 +#: library/asyncio-future.rst:63 msgid "" "Deprecation warning is emitted if *obj* is not a Future-like object and " "*loop* is not specified and there is no running event loop." msgstr "" -#: library/asyncio-future.rst:67 +#: library/asyncio-future.rst:70 msgid "" "Wrap a :class:`concurrent.futures.Future` object in a :class:`asyncio." "Future` object." msgstr "" -#: library/asyncio-future.rst:70 +#: library/asyncio-future.rst:73 msgid "" "Deprecation warning is emitted if *future* is not a Future-like object and " "*loop* is not specified and there is no running event loop." msgstr "" -#: library/asyncio-future.rst:76 +#: library/asyncio-future.rst:79 msgid "Future Object" msgstr "" -#: library/asyncio-future.rst:80 +#: library/asyncio-future.rst:83 msgid "" "A Future represents an eventual result of an asynchronous operation. Not " "thread-safe." msgstr "" -#: library/asyncio-future.rst:83 +#: library/asyncio-future.rst:86 msgid "" "Future is an :term:`awaitable` object. Coroutines can await on Future " "objects until they either have a result or an exception set, or until they " "are cancelled." msgstr "" -#: library/asyncio-future.rst:87 +#: library/asyncio-future.rst:90 msgid "" "Typically Futures are used to enable low-level callback-based code (e.g. in " "protocols implemented using asyncio :ref:`transports `) to interoperate with high-level async/await code." msgstr "" -#: library/asyncio-future.rst:92 +#: library/asyncio-future.rst:95 msgid "" "The rule of thumb is to never expose Future objects in user-facing APIs, and " "the recommended way to create a Future object is to call :meth:`loop." @@ -137,33 +143,33 @@ msgid "" "their own optimized implementations of a Future object." msgstr "" -#: library/asyncio-future.rst:98 +#: library/asyncio-future.rst:101 msgid "Added support for the :mod:`contextvars` module." msgstr "Ajout du support du module :mod:`contextvars`." -#: library/asyncio-future.rst:101 +#: library/asyncio-future.rst:104 msgid "" "Deprecation warning is emitted if *loop* is not specified and there is no " "running event loop." msgstr "" -#: library/asyncio-future.rst:107 +#: library/asyncio-future.rst:110 msgid "Return the result of the Future." msgstr "" -#: library/asyncio-future.rst:109 +#: library/asyncio-future.rst:112 msgid "" "If the Future is *done* and has a result set by the :meth:`set_result` " "method, the result value is returned." msgstr "" -#: library/asyncio-future.rst:112 +#: library/asyncio-future.rst:115 msgid "" "If the Future is *done* and has an exception set by the :meth:" "`set_exception` method, this method raises the exception." msgstr "" -#: library/asyncio-future.rst:203 +#: library/asyncio-future.rst:206 #, fuzzy msgid "" "If the Future has been *cancelled*, this method raises a :exc:" @@ -172,7 +178,7 @@ msgstr "" "Si la tâche a été *annulée*, cette méthode lève une exception :exc:" "`CancelledError`." -#: library/asyncio-future.rst:118 +#: library/asyncio-future.rst:121 #, fuzzy msgid "" "If the Future's result isn't yet available, this method raises a :exc:" @@ -181,110 +187,110 @@ msgstr "" "Si le résultat de la tâche n'est pas encore disponible, cette méthode lève " "une exception :exc:`InvalidStateError`." -#: library/asyncio-future.rst:123 +#: library/asyncio-future.rst:126 #, fuzzy msgid "Mark the Future as *done* and set its result." msgstr "Marque le futur comme terminé et définit son résultat." -#: library/asyncio-future.rst:132 +#: library/asyncio-future.rst:135 msgid "" "Raises a :exc:`InvalidStateError` error if the Future is already *done*." msgstr "" -#: library/asyncio-future.rst:130 +#: library/asyncio-future.rst:133 #, fuzzy msgid "Mark the Future as *done* and set an exception." msgstr "Marque le futur comme terminé et définit une exception." -#: library/asyncio-future.rst:137 +#: library/asyncio-future.rst:140 msgid "Return ``True`` if the Future is *done*." msgstr "" -#: library/asyncio-future.rst:139 +#: library/asyncio-future.rst:142 msgid "" "A Future is *done* if it was *cancelled* or if it has a result or an " "exception set with :meth:`set_result` or :meth:`set_exception` calls." msgstr "" -#: library/asyncio-future.rst:145 +#: library/asyncio-future.rst:148 msgid "Return ``True`` if the Future was *cancelled*." msgstr "" -#: library/asyncio-future.rst:147 +#: library/asyncio-future.rst:150 msgid "" "The method is usually used to check if a Future is not *cancelled* before " "setting a result or an exception for it::" msgstr "" -#: library/asyncio-future.rst:155 +#: library/asyncio-future.rst:158 msgid "Add a callback to be run when the Future is *done*." msgstr "" -#: library/asyncio-future.rst:157 +#: library/asyncio-future.rst:160 msgid "The *callback* is called with the Future object as its only argument." msgstr "" -#: library/asyncio-future.rst:160 +#: library/asyncio-future.rst:163 msgid "" "If the Future is already *done* when this method is called, the callback is " "scheduled with :meth:`loop.call_soon`." msgstr "" -#: library/asyncio-future.rst:163 +#: library/asyncio-future.rst:166 msgid "" "An optional keyword-only *context* argument allows specifying a custom :" "class:`contextvars.Context` for the *callback* to run in. The current " "context is used when no *context* is provided." msgstr "" -#: library/asyncio-future.rst:167 +#: library/asyncio-future.rst:170 msgid "" ":func:`functools.partial` can be used to pass parameters to the callback, e." "g.::" msgstr "" -#: library/asyncio-future.rst:174 +#: library/asyncio-future.rst:177 msgid "" "The *context* keyword-only parameter was added. See :pep:`567` for more " "details." msgstr "" -#: library/asyncio-future.rst:180 +#: library/asyncio-future.rst:183 msgid "Remove *callback* from the callbacks list." msgstr "Retire *callback* de la liste de fonctions de rappel." -#: library/asyncio-future.rst:182 +#: library/asyncio-future.rst:185 msgid "" "Returns the number of callbacks removed, which is typically 1, unless a " "callback was added more than once." msgstr "" -#: library/asyncio-future.rst:187 +#: library/asyncio-future.rst:190 msgid "Cancel the Future and schedule callbacks." msgstr "" -#: library/asyncio-future.rst:189 +#: library/asyncio-future.rst:192 msgid "" "If the Future is already *done* or *cancelled*, return ``False``. Otherwise, " "change the Future's state to *cancelled*, schedule the callbacks, and return " "``True``." msgstr "" -#: library/asyncio-future.rst:193 +#: library/asyncio-future.rst:196 msgid "Added the ``msg`` parameter." msgstr "" -#: library/asyncio-future.rst:198 +#: library/asyncio-future.rst:201 msgid "Return the exception that was set on this Future." msgstr "" -#: library/asyncio-future.rst:200 +#: library/asyncio-future.rst:203 msgid "" "The exception (or ``None`` if no exception was set) is returned only if the " "Future is *done*." msgstr "" -#: library/asyncio-future.rst:206 +#: library/asyncio-future.rst:209 #, fuzzy msgid "" "If the Future isn't *done* yet, this method raises an :exc:" @@ -293,53 +299,53 @@ msgstr "" "Si la tâche n'est pas encore *achevée*, cette méthode lève une exception :" "exc:`InvalidStateError`." -#: library/asyncio-future.rst:211 +#: library/asyncio-future.rst:214 msgid "Return the event loop the Future object is bound to." msgstr "" -#: library/asyncio-future.rst:218 +#: library/asyncio-future.rst:221 msgid "" "This example creates a Future object, creates and schedules an asynchronous " "Task to set result for the Future, and waits until the Future has a result::" msgstr "" -#: library/asyncio-future.rst:253 +#: library/asyncio-future.rst:256 msgid "" "The Future object was designed to mimic :class:`concurrent.futures.Future`. " "Key differences include:" msgstr "" -#: library/asyncio-future.rst:256 +#: library/asyncio-future.rst:259 msgid "" "unlike asyncio Futures, :class:`concurrent.futures.Future` instances cannot " "be awaited." msgstr "" -#: library/asyncio-future.rst:259 +#: library/asyncio-future.rst:262 msgid "" ":meth:`asyncio.Future.result` and :meth:`asyncio.Future.exception` do not " "accept the *timeout* argument." msgstr "" -#: library/asyncio-future.rst:262 +#: library/asyncio-future.rst:265 msgid "" ":meth:`asyncio.Future.result` and :meth:`asyncio.Future.exception` raise an :" "exc:`InvalidStateError` exception when the Future is not *done*." msgstr "" -#: library/asyncio-future.rst:266 +#: library/asyncio-future.rst:269 msgid "" "Callbacks registered with :meth:`asyncio.Future.add_done_callback` are not " "called immediately. They are scheduled with :meth:`loop.call_soon` instead." msgstr "" -#: library/asyncio-future.rst:270 +#: library/asyncio-future.rst:273 msgid "" "asyncio Future is not compatible with the :func:`concurrent.futures.wait` " "and :func:`concurrent.futures.as_completed` functions." msgstr "" -#: library/asyncio-future.rst:274 +#: library/asyncio-future.rst:277 msgid "" ":meth:`asyncio.Future.cancel` accepts an optional ``msg`` argument, but :" "func:`concurrent.futures.cancel` does not." diff --git a/library/asyncio-task.po b/library/asyncio-task.po index a57814f8..8e238c74 100644 --- a/library/asyncio-task.po +++ b/library/asyncio-task.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2020-09-22 17:11+0200\n" "Last-Translator: Philippe GALVAN \n" "Language-Team: FRENCH \n" @@ -267,7 +267,7 @@ msgstr "" "fin. Elle doit être utilisée comme point d'entrée principal des programmes " "*asyncio* et ne doit être idéalement appelée qu'une seule fois." -#: library/asyncio-task.rst:374 library/asyncio-task.rst:665 +#: library/asyncio-task.rst:379 library/asyncio-task.rst:670 msgid "Example::" msgstr "Exemple ::" @@ -321,19 +321,25 @@ msgstr "" "antérieures à la 3.7, la fonction de bas-niveau :func:`asyncio." "ensure_future` peut-être utilisée ::" -#: library/asyncio-task.rst:857 +#: library/asyncio-task.rst:279 +msgid "" +"Save a reference to the result of this function, to avoid a task " +"disappearing mid execution." +msgstr "" + +#: library/asyncio-task.rst:862 msgid "Added the ``name`` parameter." msgstr "ajout du paramètre ``name``." -#: library/asyncio-task.rst:284 +#: library/asyncio-task.rst:289 msgid "Sleeping" msgstr "Attente" -#: library/asyncio-task.rst:288 +#: library/asyncio-task.rst:293 msgid "Block for *delay* seconds." msgstr "Attend pendant *delay* secondes." -#: library/asyncio-task.rst:290 +#: library/asyncio-task.rst:295 msgid "" "If *result* is provided, it is returned to the caller when the coroutine " "completes." @@ -341,41 +347,41 @@ msgstr "" "Si *result* est spécifié, il est renvoyé à l'appelant quand la coroutine se " "termine." -#: library/asyncio-task.rst:293 +#: library/asyncio-task.rst:298 msgid "" "``sleep()`` always suspends the current task, allowing other tasks to run." msgstr "" "``sleep()`` suspend systématiquement la tâche courante, ce qui permet aux " "autres tâches de s'exécuter." -#: library/asyncio-task.rst:296 +#: library/asyncio-task.rst:301 msgid "" "Setting the delay to 0 provides an optimized path to allow other tasks to " "run. This can be used by long-running functions to avoid blocking the event " "loop for the full duration of the function call." msgstr "" -#: library/asyncio-task.rst:328 library/asyncio-task.rst:428 -#: library/asyncio-task.rst:513 library/asyncio-task.rst:608 -#: library/asyncio-task.rst:664 library/asyncio-task.rst:676 +#: library/asyncio-task.rst:333 library/asyncio-task.rst:433 +#: library/asyncio-task.rst:518 library/asyncio-task.rst:613 +#: library/asyncio-task.rst:669 library/asyncio-task.rst:681 msgid "" "The ``loop`` parameter. This function has been implicitly getting the " "current running loop since 3.7. See :ref:`What's New in 3.10's Removed " "section ` for more information." msgstr "" -#: library/asyncio-task.rst:308 +#: library/asyncio-task.rst:313 msgid "" "Example of coroutine displaying the current date every second for 5 seconds::" msgstr "" "Exemple d'une coroutine affichant la date toutes les secondes pendant 5 " "secondes ::" -#: library/asyncio-task.rst:335 +#: library/asyncio-task.rst:340 msgid "Running Tasks Concurrently" msgstr "Exécution de tâches de manière concurrente" -#: library/asyncio-task.rst:339 +#: library/asyncio-task.rst:344 msgid "" "Run :ref:`awaitable objects ` in the *aws* sequence " "*concurrently*." @@ -383,7 +389,7 @@ msgstr "" "Exécute les objets :ref:`awaitable ` de la séquence " "*aws*, *de manière concurrente*." -#: library/asyncio-task.rst:342 +#: library/asyncio-task.rst:347 msgid "" "If any awaitable in *aws* is a coroutine, it is automatically scheduled as a " "Task." @@ -391,7 +397,7 @@ msgstr "" "Si un *attendable* de *aws* est une coroutine, celui-ci est automatiquement " "planifié comme une tâche *Task*." -#: library/asyncio-task.rst:345 +#: library/asyncio-task.rst:350 msgid "" "If all awaitables are completed successfully, the result is an aggregate " "list of returned values. The order of result values corresponds to the " @@ -401,7 +407,7 @@ msgstr "" "des valeurs renvoyées. L'ordre de cette liste correspond à l'ordre des " "*awaitables* dans *aws*." -#: library/asyncio-task.rst:349 +#: library/asyncio-task.rst:354 msgid "" "If *return_exceptions* is ``False`` (default), the first raised exception is " "immediately propagated to the task that awaits on ``gather()``. Other " @@ -413,7 +419,7 @@ msgstr "" "``gather()``. Les autres *attendables* dans la séquence *aws* **ne sont pas " "annulés** et poursuivent leur exécution." -#: library/asyncio-task.rst:354 +#: library/asyncio-task.rst:359 msgid "" "If *return_exceptions* is ``True``, exceptions are treated the same as " "successful results, and aggregated in the result list." @@ -422,7 +428,7 @@ msgstr "" "même manière que les exécutions normales, et incluses dans la liste des " "résultats." -#: library/asyncio-task.rst:357 +#: library/asyncio-task.rst:362 msgid "" "If ``gather()`` is *cancelled*, all submitted awaitables (that have not " "completed yet) are also *cancelled*." @@ -430,7 +436,7 @@ msgstr "" "Si ``gather()`` est *annulé*, tous les *awaitables* en cours (ceux qui n'ont " "pas encore fini de s'exécuter) sont également *annulés*." -#: library/asyncio-task.rst:360 +#: library/asyncio-task.rst:365 msgid "" "If any Task or Future from the *aws* sequence is *cancelled*, it is treated " "as if it raised :exc:`CancelledError` -- the ``gather()`` call is **not** " @@ -443,7 +449,7 @@ msgstr "" "l'annulation d'une tâche ou d'un futur entraîne l'annulation des autres " "tâches ou futurs." -#: library/asyncio-task.rst:412 +#: library/asyncio-task.rst:417 msgid "" "If *return_exceptions* is False, cancelling gather() after it has been " "marked done won't cancel any submitted awaitables. For instance, gather can " @@ -452,7 +458,7 @@ msgid "" "the awaitables) from gather won't cancel any other awaitables." msgstr "" -#: library/asyncio-task.rst:419 +#: library/asyncio-task.rst:424 msgid "" "If the *gather* itself is cancelled, the cancellation is propagated " "regardless of *return_exceptions*." @@ -460,18 +466,18 @@ msgstr "" "Si *gather* est lui-même annulé, l'annulation est propagée indépendamment de " "*return_exceptions*." -#: library/asyncio-task.rst:429 +#: library/asyncio-task.rst:434 msgid "" "Deprecation warning is emitted if no positional arguments are provided or " "not all positional arguments are Future-like objects and there is no running " "event loop." msgstr "" -#: library/asyncio-task.rst:436 +#: library/asyncio-task.rst:441 msgid "Shielding From Cancellation" msgstr "Protection contre l'annulation" -#: library/asyncio-task.rst:440 +#: library/asyncio-task.rst:445 msgid "" "Protect an :ref:`awaitable object ` from being :meth:" "`cancelled `." @@ -479,21 +485,21 @@ msgstr "" "Empêche qu'un objet :ref:`awaitable ` puisse être :meth:" "`annulé `." -#: library/asyncio-task.rst:490 +#: library/asyncio-task.rst:495 msgid "If *aw* is a coroutine it is automatically scheduled as a Task." msgstr "" "Si *aw* est une coroutine, elle est planifiée automatiquement comme une " "tâche." -#: library/asyncio-task.rst:445 +#: library/asyncio-task.rst:450 msgid "The statement::" msgstr "L'instruction ::" -#: library/asyncio-task.rst:449 +#: library/asyncio-task.rst:454 msgid "is equivalent to::" msgstr "est équivalente à ::" -#: library/asyncio-task.rst:453 +#: library/asyncio-task.rst:458 msgid "" "*except* that if the coroutine containing it is cancelled, the Task running " "in ``something()`` is not cancelled. From the point of view of " @@ -506,7 +512,7 @@ msgstr "" "``something()``, il n'y a pas eu d'annulation. Cependant, son appelant est " "bien annulé, donc l'expression *await* lève bien une :exc:`CancelledError`." -#: library/asyncio-task.rst:459 +#: library/asyncio-task.rst:464 msgid "" "If ``something()`` is cancelled by other means (i.e. from within itself) " "that would also cancel ``shield()``." @@ -514,7 +520,7 @@ msgstr "" "Si ``something()`` est annulée d'une autre façon (c.-à-d. depuis elle-même) " "ceci annule également ``shield()``." -#: library/asyncio-task.rst:462 +#: library/asyncio-task.rst:467 msgid "" "If it is desired to completely ignore cancellation (not recommended) the " "``shield()`` function should be combined with a try/except clause, as " @@ -524,17 +530,17 @@ msgstr "" "``shield()`` peut être combinée à une clause *try* / *except*, comme dans le " "code ci-dessous ::" -#: library/asyncio-task.rst:477 +#: library/asyncio-task.rst:482 msgid "" "Deprecation warning is emitted if *aw* is not Future-like object and there " "is no running event loop." msgstr "" -#: library/asyncio-task.rst:483 +#: library/asyncio-task.rst:488 msgid "Timeouts" msgstr "Délais d'attente" -#: library/asyncio-task.rst:487 +#: library/asyncio-task.rst:492 msgid "" "Wait for the *aw* :ref:`awaitable ` to complete with a " "timeout." @@ -542,7 +548,7 @@ msgstr "" "Attend la fin de l':ref:`awaitable ` *aw* avec délai " "d'attente." -#: library/asyncio-task.rst:492 +#: library/asyncio-task.rst:497 msgid "" "*timeout* can either be ``None`` or a float or int number of seconds to wait " "for. If *timeout* is ``None``, block until the future completes." @@ -551,7 +557,7 @@ msgstr "" "décimal) d'attente. Si *timeout* vaut ``None``, la fonction s'interrompt " "jusqu'à ce que le futur s'achève." -#: library/asyncio-task.rst:496 +#: library/asyncio-task.rst:501 msgid "" "If a timeout occurs, it cancels the task and raises :exc:`asyncio." "TimeoutError`." @@ -559,7 +565,7 @@ msgstr "" "Si le délai d'attente maximal est dépassé, la tâche est annulée et " "l'exception :exc:`asyncio.TimeoutError` est levée." -#: library/asyncio-task.rst:499 +#: library/asyncio-task.rst:504 msgid "" "To avoid the task :meth:`cancellation `, wrap it in :func:" "`shield`." @@ -567,7 +573,7 @@ msgstr "" "Pour empêcher :meth:`l'annulation ` de la tâche, il est " "nécessaire de l'encapsuler dans une fonction :func:`shield`." -#: library/asyncio-task.rst:502 +#: library/asyncio-task.rst:507 #, fuzzy msgid "" "The function will wait until the future is actually cancelled, so the total " @@ -577,11 +583,11 @@ msgstr "" "Cette fonction attend que le futur soit réellement annulé, donc le temps " "d'attente total peut être supérieur à *timeout*." -#: library/asyncio-task.rst:506 +#: library/asyncio-task.rst:511 msgid "If the wait is cancelled, the future *aw* is also cancelled." msgstr "Si l'attente est annulée, le futur *aw* est également annulé." -#: library/asyncio-task.rst:536 +#: library/asyncio-task.rst:541 msgid "" "When *aw* is cancelled due to a timeout, ``wait_for`` waits for *aw* to be " "cancelled. Previously, it raised :exc:`asyncio.TimeoutError` immediately." @@ -590,11 +596,11 @@ msgstr "" "``wait_for`` attend que *aw* soit annulée. Auparavant, l'exception :exc:" "`asyncio.TimeoutError` était immédiatement levée." -#: library/asyncio-task.rst:549 +#: library/asyncio-task.rst:554 msgid "Waiting Primitives" msgstr "Primitives d'attente" -#: library/asyncio-task.rst:553 +#: library/asyncio-task.rst:558 #, fuzzy msgid "" "Run :ref:`awaitable objects ` in the *aws* iterable " @@ -604,19 +610,19 @@ msgstr "" "*aws* de manière concurrente, et s'interrompt jusqu'à ce que la condition " "décrite dans *return_when* soit vraie." -#: library/asyncio-task.rst:557 +#: library/asyncio-task.rst:562 msgid "The *aws* iterable must not be empty." msgstr "" -#: library/asyncio-task.rst:559 +#: library/asyncio-task.rst:564 msgid "Returns two sets of Tasks/Futures: ``(done, pending)``." msgstr "Renvoie deux ensembles de *Tasks* / *Futures* : ``(done, pending)``." -#: library/asyncio-task.rst:561 +#: library/asyncio-task.rst:566 msgid "Usage::" msgstr "Utilisation ::" -#: library/asyncio-task.rst:565 +#: library/asyncio-task.rst:570 msgid "" "*timeout* (a float or int), if specified, can be used to control the maximum " "number of seconds to wait before returning." @@ -624,7 +630,7 @@ msgstr "" "*timeout* (entier ou décimal), si précisé, peut-être utilisé pour contrôler " "le nombre maximal de secondes d'attente avant de se terminer." -#: library/asyncio-task.rst:568 +#: library/asyncio-task.rst:573 msgid "" "Note that this function does not raise :exc:`asyncio.TimeoutError`. Futures " "or Tasks that aren't done when the timeout occurs are simply returned in the " @@ -634,7 +640,7 @@ msgstr "" "tâches qui ne sont pas finis quand le délai d'attente maximal est dépassé " "sont tout simplement renvoyés dans le second ensemble." -#: library/asyncio-task.rst:572 +#: library/asyncio-task.rst:577 msgid "" "*return_when* indicates when this function should return. It must be one of " "the following constants:" @@ -642,28 +648,28 @@ msgstr "" "*return_when* indique quand la fonction doit se terminer. Il peut prendre " "les valeurs suivantes :" -#: library/asyncio-task.rst:578 +#: library/asyncio-task.rst:583 msgid "Constant" msgstr "Constante" -#: library/asyncio-task.rst:578 +#: library/asyncio-task.rst:583 msgid "Description" msgstr "Description" -#: library/asyncio-task.rst:580 +#: library/asyncio-task.rst:585 msgid ":const:`FIRST_COMPLETED`" msgstr ":const:`FIRST_COMPLETED`" -#: library/asyncio-task.rst:580 +#: library/asyncio-task.rst:585 msgid "The function will return when any future finishes or is cancelled." msgstr "" "La fonction se termine lorsque n'importe quel futur se termine ou est annulé." -#: library/asyncio-task.rst:583 +#: library/asyncio-task.rst:588 msgid ":const:`FIRST_EXCEPTION`" msgstr ":const:`FIRST_EXCEPTION`" -#: library/asyncio-task.rst:583 +#: library/asyncio-task.rst:588 msgid "" "The function will return when any future finishes by raising an exception. " "If no future raises an exception then it is equivalent to :const:" @@ -673,16 +679,16 @@ msgstr "" "exception. Si aucun *futur* ne lève d'exception, équivaut à :const:" "`ALL_COMPLETED`." -#: library/asyncio-task.rst:589 +#: library/asyncio-task.rst:594 msgid ":const:`ALL_COMPLETED`" msgstr ":const:`ALL_COMPLETED`" -#: library/asyncio-task.rst:589 +#: library/asyncio-task.rst:594 msgid "The function will return when all futures finish or are cancelled." msgstr "" "La fonction se termine lorsque les *futurs* sont tous finis ou annulés." -#: library/asyncio-task.rst:593 +#: library/asyncio-task.rst:598 msgid "" "Unlike :func:`~asyncio.wait_for`, ``wait()`` does not cancel the futures " "when a timeout occurs." @@ -690,7 +696,7 @@ msgstr "" "À la différence de :func:`~asyncio.wait_for`, ``wait()`` n'annule pas les " "futurs quand le délai d'attente est dépassé." -#: library/asyncio-task.rst:598 +#: library/asyncio-task.rst:603 msgid "" "If any awaitable in *aws* is a coroutine, it is automatically scheduled as a " "Task. Passing coroutines objects to ``wait()`` directly is deprecated as it " @@ -701,7 +707,7 @@ msgstr "" "``wait()`` est obsolète, car ceci conduisait :ref:`à un comportement portant " "à confusion `." -#: library/asyncio-task.rst:612 +#: library/asyncio-task.rst:617 msgid "" "``wait()`` schedules coroutines as Tasks automatically and later returns " "those implicitly created Task objects in ``(done, pending)`` sets. " @@ -711,15 +717,15 @@ msgstr "" "renvoie les objets *Task* ainsi créés dans les ensembles ``(done, " "pending)``. Le code suivant ne fonctionne donc pas comme voulu ::" -#: library/asyncio-task.rst:625 +#: library/asyncio-task.rst:630 msgid "Here is how the above snippet can be fixed::" msgstr "Voici comment corriger le morceau de code ci-dessus ::" -#: library/asyncio-task.rst:645 +#: library/asyncio-task.rst:650 msgid "Passing coroutine objects to ``wait()`` directly is deprecated." msgstr "Passer directement des objets coroutines à ``wait()`` est obsolète." -#: library/asyncio-task.rst:651 +#: library/asyncio-task.rst:656 #, fuzzy msgid "" "Run :ref:`awaitable objects ` in the *aws* iterable " @@ -732,7 +738,7 @@ msgstr "" "`Future`. Chaque objet *futur* renvoyé représente le résultat le plus récent " "de l'ensemble des *awaitables* restants." -#: library/asyncio-task.rst:656 +#: library/asyncio-task.rst:661 msgid "" "Raises :exc:`asyncio.TimeoutError` if the timeout occurs before all Futures " "are done." @@ -740,21 +746,21 @@ msgstr "" "Lève une exception :exc:`asyncio.TimeoutError` si le délai d'attente est " "dépassé avant que tous les futurs ne soient achevés." -#: library/asyncio-task.rst:677 +#: library/asyncio-task.rst:682 msgid "" "Deprecation warning is emitted if not all awaitable objects in the *aws* " "iterable are Future-like objects and there is no running event loop." msgstr "" -#: library/asyncio-task.rst:683 +#: library/asyncio-task.rst:688 msgid "Running in Threads" msgstr "" -#: library/asyncio-task.rst:687 +#: library/asyncio-task.rst:692 msgid "Asynchronously run function *func* in a separate thread." msgstr "" -#: library/asyncio-task.rst:689 +#: library/asyncio-task.rst:694 msgid "" "Any \\*args and \\*\\*kwargs supplied for this function are directly passed " "to *func*. Also, the current :class:`contextvars.Context` is propagated, " @@ -762,19 +768,19 @@ msgid "" "separate thread." msgstr "" -#: library/asyncio-task.rst:694 +#: library/asyncio-task.rst:699 msgid "" "Return a coroutine that can be awaited to get the eventual result of *func*." msgstr "" -#: library/asyncio-task.rst:696 +#: library/asyncio-task.rst:701 msgid "" "This coroutine function is primarily intended to be used for executing IO-" "bound functions/methods that would otherwise block the event loop if they " "were ran in the main thread. For example::" msgstr "" -#: library/asyncio-task.rst:726 +#: library/asyncio-task.rst:731 msgid "" "Directly calling `blocking_io()` in any coroutine would block the event loop " "for its duration, resulting in an additional 1 second of run time. Instead, " @@ -782,7 +788,7 @@ msgid "" "blocking the event loop." msgstr "" -#: library/asyncio-task.rst:733 +#: library/asyncio-task.rst:738 msgid "" "Due to the :term:`GIL`, `asyncio.to_thread()` can typically only be used to " "make IO-bound functions non-blocking. However, for extension modules that " @@ -790,18 +796,18 @@ msgid "" "`asyncio.to_thread()` can also be used for CPU-bound functions." msgstr "" -#: library/asyncio-task.rst:742 +#: library/asyncio-task.rst:747 msgid "Scheduling From Other Threads" msgstr "Planification depuis d'autres fils d'exécution" -#: library/asyncio-task.rst:746 +#: library/asyncio-task.rst:751 msgid "Submit a coroutine to the given event loop. Thread-safe." msgstr "" "Enregistre une coroutine dans la boucle d'exécution actuelle. Cette " "opération est compatible avec les programmes à multiples fils d'exécution " "(*thread-safe*)." -#: library/asyncio-task.rst:748 +#: library/asyncio-task.rst:753 msgid "" "Return a :class:`concurrent.futures.Future` to wait for the result from " "another OS thread." @@ -809,7 +815,7 @@ msgstr "" "Renvoie un :class:`concurrent.futures.Future` pour attendre le résultat d'un " "autre fil d'exécution du système d'exploitation." -#: library/asyncio-task.rst:751 +#: library/asyncio-task.rst:756 msgid "" "This function is meant to be called from a different OS thread than the one " "where the event loop is running. Example::" @@ -817,7 +823,7 @@ msgstr "" "Cette fonction est faite pour être appelée par un fil d'exécution distinct " "de celui dans laquelle la boucle d'événement s'exécute. Exemple ::" -#: library/asyncio-task.rst:763 +#: library/asyncio-task.rst:768 msgid "" "If an exception is raised in the coroutine, the returned Future will be " "notified. It can also be used to cancel the task in the event loop::" @@ -826,7 +832,7 @@ msgstr "" "averti. Elle peut également être utilisée pour annuler la tâche de la boucle " "d'événement ::" -#: library/asyncio-task.rst:777 +#: library/asyncio-task.rst:782 msgid "" "See the :ref:`concurrency and multithreading ` " "section of the documentation." @@ -834,7 +840,7 @@ msgstr "" "Voir la section :ref:`exécution concurrente et multi-fils d'exécution " "` de la documentation." -#: library/asyncio-task.rst:780 +#: library/asyncio-task.rst:785 msgid "" "Unlike other asyncio functions this function requires the *loop* argument to " "be passed explicitly." @@ -842,11 +848,11 @@ msgstr "" "À la différence des autres fonctions d'*asyncio*, cette fonction requiert " "que *loop* soit passé de manière explicite." -#: library/asyncio-task.rst:787 +#: library/asyncio-task.rst:792 msgid "Introspection" msgstr "Introspection" -#: library/asyncio-task.rst:792 +#: library/asyncio-task.rst:797 msgid "" "Return the currently running :class:`Task` instance, or ``None`` if no task " "is running." @@ -854,7 +860,7 @@ msgstr "" "Renvoie l'instance de la :class:`Task` en cours d'exécution, ou ``None`` " "s'il n'y a pas de tâche en cours." -#: library/asyncio-task.rst:795 +#: library/asyncio-task.rst:800 msgid "" "If *loop* is ``None`` :func:`get_running_loop` is used to get the current " "loop." @@ -862,13 +868,13 @@ msgstr "" "Si *loop* vaut ``None``, :func:`get_running_loop` est appelée pour récupérer " "la boucle en cours d'exécution." -#: library/asyncio-task.rst:803 +#: library/asyncio-task.rst:808 msgid "Return a set of not yet finished :class:`Task` objects run by the loop." msgstr "" "Renvoie l'ensemble des :class:`Task` non terminés en cours d'exécution dans " "la boucle." -#: library/asyncio-task.rst:806 +#: library/asyncio-task.rst:811 msgid "" "If *loop* is ``None``, :func:`get_running_loop` is used for getting current " "loop." @@ -876,11 +882,11 @@ msgstr "" "Si *loop* vaut ``None``, :func:`get_running_loop` est appelée pour récupérer " "la boucle en cours d'exécution." -#: library/asyncio-task.rst:813 +#: library/asyncio-task.rst:818 msgid "Task Object" msgstr "Objets *Task*" -#: library/asyncio-task.rst:817 +#: library/asyncio-task.rst:822 msgid "" "A :class:`Future-like ` object that runs a Python :ref:`coroutine " "`. Not thread-safe." @@ -889,7 +895,7 @@ msgstr "" "`coroutine ` Python. Cet objet n'est pas utilisable dans des " "programmes à fils d'exécution multiples." -#: library/asyncio-task.rst:820 +#: library/asyncio-task.rst:825 msgid "" "Tasks are used to run coroutines in event loops. If a coroutine awaits on a " "Future, the Task suspends the execution of the coroutine and waits for the " @@ -901,7 +907,7 @@ msgstr "" "attend la fin de ce *futur*. Quand celui-ci est terminé, l'exécution de la " "coroutine encapsulée reprend." -#: library/asyncio-task.rst:826 +#: library/asyncio-task.rst:831 msgid "" "Event loops use cooperative scheduling: an event loop runs one Task at a " "time. While a Task awaits for the completion of a Future, the event loop " @@ -912,7 +918,7 @@ msgstr "" "futur, la boucle d'événement exécute d'autres tâches, des fonctions de " "rappel, ou effectue des opérations d'entrées-sorties." -#: library/asyncio-task.rst:831 +#: library/asyncio-task.rst:836 msgid "" "Use the high-level :func:`asyncio.create_task` function to create Tasks, or " "the low-level :meth:`loop.create_task` or :func:`ensure_future` functions. " @@ -923,7 +929,7 @@ msgstr "" "créer des tâches. Il est déconseillé d'instancier manuellement des objets " "*Task*." -#: library/asyncio-task.rst:836 +#: library/asyncio-task.rst:841 msgid "" "To cancel a running Task use the :meth:`cancel` method. Calling it will " "cause the Task to throw a :exc:`CancelledError` exception into the wrapped " @@ -935,7 +941,7 @@ msgstr "" "`CancelledError` dans la coroutine encapsulée. Si la coroutine attendait un " "*futur* au moment de l'annulation, celui-ci est annulé." -#: library/asyncio-task.rst:841 +#: library/asyncio-task.rst:846 msgid "" ":meth:`cancelled` can be used to check if the Task was cancelled. The method " "returns ``True`` if the wrapped coroutine did not suppress the :exc:" @@ -945,7 +951,7 @@ msgstr "" "Elle renvoie ``True`` si la coroutine encapsulée n'a pas ignoré l'exception :" "exc:`CancelledError` et a bien été annulée." -#: library/asyncio-task.rst:846 +#: library/asyncio-task.rst:851 msgid "" ":class:`asyncio.Task` inherits from :class:`Future` all of its APIs except :" "meth:`Future.set_result` and :meth:`Future.set_exception`." @@ -953,7 +959,7 @@ msgstr "" ":class:`asyncio.Task` hérite de :class:`Future`, de toute son API, à " "l'exception de :meth:`Future.set_result` et de :meth:`Future.set_exception`." -#: library/asyncio-task.rst:850 +#: library/asyncio-task.rst:855 msgid "" "Tasks support the :mod:`contextvars` module. When a Task is created it " "copies the current context and later runs its coroutine in the copied " @@ -963,25 +969,25 @@ msgstr "" "tâche effectue une copie du contexte actuel et exécutera ses coroutines dans " "cette copie." -#: library/asyncio-task.rst:854 +#: library/asyncio-task.rst:859 msgid "Added support for the :mod:`contextvars` module." msgstr "Ajout du support du module :mod:`contextvars`." -#: library/asyncio-task.rst:862 +#: library/asyncio-task.rst:867 msgid "The *loop* parameter." msgstr "Le paramètre *loop*." -#: library/asyncio-task.rst:863 +#: library/asyncio-task.rst:868 msgid "" "Deprecation warning is emitted if *loop* is not specified and there is no " "running event loop." msgstr "" -#: library/asyncio-task.rst:869 +#: library/asyncio-task.rst:874 msgid "Request the Task to be cancelled." msgstr "Demande l'annulation d'une tâche." -#: library/asyncio-task.rst:871 +#: library/asyncio-task.rst:876 msgid "" "This arranges for a :exc:`CancelledError` exception to be thrown into the " "wrapped coroutine on the next cycle of the event loop." @@ -990,7 +996,7 @@ msgstr "" "encapsulée. L'exception sera levée au prochain cycle de la boucle " "d'exécution." -#: library/asyncio-task.rst:874 +#: library/asyncio-task.rst:879 msgid "" "The coroutine then has a chance to clean up or even deny the request by " "suppressing the exception with a :keyword:`try` ... ... ``except " @@ -1006,11 +1012,11 @@ msgstr "" "annulée, bien qu'ignorer totalement une annulation ne soit ni une pratique " "courante, ni encouragé." -#: library/asyncio-task.rst:882 +#: library/asyncio-task.rst:887 msgid "Added the ``msg`` parameter." msgstr "" -#: library/asyncio-task.rst:887 +#: library/asyncio-task.rst:892 msgid "" "The following example illustrates how coroutines can intercept the " "cancellation request::" @@ -1018,11 +1024,11 @@ msgstr "" "L'exemple ci-dessous illustre comment une coroutine peut intercepter une " "requête d'annulation ::" -#: library/asyncio-task.rst:926 +#: library/asyncio-task.rst:931 msgid "Return ``True`` if the Task is *cancelled*." msgstr "Renvoie ``True`` si la tâche est *annulée*." -#: library/asyncio-task.rst:928 +#: library/asyncio-task.rst:933 msgid "" "The Task is *cancelled* when the cancellation was requested with :meth:" "`cancel` and the wrapped coroutine propagated the :exc:`CancelledError` " @@ -1032,11 +1038,11 @@ msgstr "" "et la coroutine encapsulée a propagé l'exception :exc:`CancelledError` qui a " "été levée en son sein." -#: library/asyncio-task.rst:934 +#: library/asyncio-task.rst:939 msgid "Return ``True`` if the Task is *done*." msgstr "Renvoie ``True`` si la tâche est *achevée*." -#: library/asyncio-task.rst:936 +#: library/asyncio-task.rst:941 msgid "" "A Task is *done* when the wrapped coroutine either returned a value, raised " "an exception, or the Task was cancelled." @@ -1044,11 +1050,11 @@ msgstr "" "Une tâche est dite *achevée* quand la coroutine encapsulée a soit renvoyé " "une valeur, soit levé une exception, ou que la tâche a été annulée." -#: library/asyncio-task.rst:941 +#: library/asyncio-task.rst:946 msgid "Return the result of the Task." msgstr "Renvoie le résultat de la tâche." -#: library/asyncio-task.rst:943 +#: library/asyncio-task.rst:948 msgid "" "If the Task is *done*, the result of the wrapped coroutine is returned (or " "if the coroutine raised an exception, that exception is re-raised.)" @@ -1057,7 +1063,7 @@ msgstr "" "renvoyé (sinon, dans le cas où la coroutine a levé une exception, cette " "exception est de nouveau levée)." -#: library/asyncio-task.rst:961 +#: library/asyncio-task.rst:966 msgid "" "If the Task has been *cancelled*, this method raises a :exc:`CancelledError` " "exception." @@ -1065,7 +1071,7 @@ msgstr "" "Si la tâche a été *annulée*, cette méthode lève une exception :exc:" "`CancelledError`." -#: library/asyncio-task.rst:950 +#: library/asyncio-task.rst:955 msgid "" "If the Task's result isn't yet available, this method raises a :exc:" "`InvalidStateError` exception." @@ -1073,11 +1079,11 @@ msgstr "" "Si le résultat de la tâche n'est pas encore disponible, cette méthode lève " "une exception :exc:`InvalidStateError`." -#: library/asyncio-task.rst:955 +#: library/asyncio-task.rst:960 msgid "Return the exception of the Task." msgstr "Renvoie l'exception de la tâche." -#: library/asyncio-task.rst:957 +#: library/asyncio-task.rst:962 msgid "" "If the wrapped coroutine raised an exception that exception is returned. If " "the wrapped coroutine returned normally this method returns ``None``." @@ -1085,7 +1091,7 @@ msgstr "" "Si la coroutine encapsulée lève une exception, cette exception est renvoyée. " "Si la coroutine s'est exécutée normalement, cette méthode renvoie ``None``." -#: library/asyncio-task.rst:964 +#: library/asyncio-task.rst:969 msgid "" "If the Task isn't *done* yet, this method raises an :exc:`InvalidStateError` " "exception." @@ -1093,30 +1099,30 @@ msgstr "" "Si la tâche n'est pas encore *achevée*, cette méthode lève une exception :" "exc:`InvalidStateError`." -#: library/asyncio-task.rst:969 +#: library/asyncio-task.rst:974 msgid "Add a callback to be run when the Task is *done*." msgstr "" "Ajoute une fonction de rappel qui sera exécutée quand la tâche sera " "*achevée*." -#: library/asyncio-task.rst:980 +#: library/asyncio-task.rst:985 msgid "This method should only be used in low-level callback-based code." msgstr "" "Cette méthode ne doit être utilisée que dans du code basé sur les fonctions " "de rappel de bas-niveau." -#: library/asyncio-task.rst:973 +#: library/asyncio-task.rst:978 msgid "" "See the documentation of :meth:`Future.add_done_callback` for more details." msgstr "" "Se référer à la documentation de :meth:`Future.add_done_callback` pour plus " "de détails." -#: library/asyncio-task.rst:978 +#: library/asyncio-task.rst:983 msgid "Remove *callback* from the callbacks list." msgstr "Retire *callback* de la liste de fonctions de rappel." -#: library/asyncio-task.rst:982 +#: library/asyncio-task.rst:987 msgid "" "See the documentation of :meth:`Future.remove_done_callback` for more " "details." @@ -1124,11 +1130,11 @@ msgstr "" "Se référer à la documentation de :meth:`Future.remove_done_callback` pour " "plus de détails." -#: library/asyncio-task.rst:987 +#: library/asyncio-task.rst:992 msgid "Return the list of stack frames for this Task." msgstr "Renvoie une liste représentant la pile d'appels de la tâche." -#: library/asyncio-task.rst:989 +#: library/asyncio-task.rst:994 msgid "" "If the wrapped coroutine is not done, this returns the stack where it is " "suspended. If the coroutine has completed successfully or was cancelled, " @@ -1141,15 +1147,15 @@ msgstr "" "renvoie une liste vide. Si la coroutine a été terminée par une exception, " "ceci renvoie la pile d'erreurs." -#: library/asyncio-task.rst:995 +#: library/asyncio-task.rst:1000 msgid "The frames are always ordered from oldest to newest." msgstr "La pile est toujours affichée de l'appelant à l'appelé." -#: library/asyncio-task.rst:997 +#: library/asyncio-task.rst:1002 msgid "Only one stack frame is returned for a suspended coroutine." msgstr "Une seule ligne est renvoyée si la coroutine est suspendue." -#: library/asyncio-task.rst:999 +#: library/asyncio-task.rst:1004 msgid "" "The optional *limit* argument sets the maximum number of frames to return; " "by default all available frames are returned. The ordering of the returned " @@ -1163,11 +1169,11 @@ msgstr "" "renvoyés, si la pile est une pile d'erreurs, ce sont les appels les plus " "anciens qui le sont (dans un souci de cohérence avec le module *traceback*)." -#: library/asyncio-task.rst:1008 +#: library/asyncio-task.rst:1013 msgid "Print the stack or traceback for this Task." msgstr "Affiche la pile d'appels ou d'erreurs de la tâche." -#: library/asyncio-task.rst:1010 +#: library/asyncio-task.rst:1015 msgid "" "This produces output similar to that of the traceback module for the frames " "retrieved by :meth:`get_stack`." @@ -1175,11 +1181,11 @@ msgstr "" "Le format de sortie des appels produits par :meth:`get_stack` est similaire " "à celui du module *traceback*." -#: library/asyncio-task.rst:1013 +#: library/asyncio-task.rst:1018 msgid "The *limit* argument is passed to :meth:`get_stack` directly." msgstr "Le paramètre *limit* est directement passé à :meth:`get_stack`." -#: library/asyncio-task.rst:1015 +#: library/asyncio-task.rst:1020 msgid "" "The *file* argument is an I/O stream to which the output is written; by " "default output is written to :data:`sys.stderr`." @@ -1187,15 +1193,15 @@ msgstr "" "Le paramètre *file* est un flux d'entrées-sorties sur lequel le résultat est " "écrit ; par défaut, :data:`sys.stderr`." -#: library/asyncio-task.rst:1020 +#: library/asyncio-task.rst:1025 msgid "Return the coroutine object wrapped by the :class:`Task`." msgstr "Renvoie l’objet *coroutine* encapsulé par la :class:`Task`." -#: library/asyncio-task.rst:1026 +#: library/asyncio-task.rst:1031 msgid "Return the name of the Task." msgstr "Renvoie le nom de la tâche." -#: library/asyncio-task.rst:1028 +#: library/asyncio-task.rst:1033 msgid "" "If no name has been explicitly assigned to the Task, the default asyncio " "Task implementation generates a default name during instantiation." @@ -1204,18 +1210,18 @@ msgstr "" "défaut d’une *Task* *asyncio* génère un nom par défaut durant " "l’instanciation." -#: library/asyncio-task.rst:1036 +#: library/asyncio-task.rst:1041 msgid "Set the name of the Task." msgstr "Définit le nom de la tâche." -#: library/asyncio-task.rst:1038 +#: library/asyncio-task.rst:1043 msgid "" "The *value* argument can be any object, which is then converted to a string." msgstr "" "L’argument *value* peut être n’importe quel objet qui sera ensuite converti " "en chaine de caractères." -#: library/asyncio-task.rst:1041 +#: library/asyncio-task.rst:1046 msgid "" "In the default Task implementation, the name will be visible in the :func:" "`repr` output of a task object." @@ -1223,11 +1229,11 @@ msgstr "" "Dans l’implémentation par défaut de *Task*, le nom sera visible dans le " "résultat de :func:`repr` d’un objet *Task*." -#: library/asyncio-task.rst:1050 +#: library/asyncio-task.rst:1055 msgid "Generator-based Coroutines" msgstr "Coroutines basées sur des générateurs" -#: library/asyncio-task.rst:1054 +#: library/asyncio-task.rst:1059 msgid "" "Support for generator-based coroutines is **deprecated** and is scheduled " "for removal in Python 3.10." @@ -1235,7 +1241,7 @@ msgstr "" "Les coroutines basées sur des générateurs sont **obsolètes** et il est prévu " "de les supprimer en Python 3.10." -#: library/asyncio-task.rst:1057 +#: library/asyncio-task.rst:1062 msgid "" "Generator-based coroutines predate async/await syntax. They are Python " "generators that use ``yield from`` expressions to await on Futures and other " @@ -1245,7 +1251,7 @@ msgstr "" "*async* / *await*. Il existe des générateurs *Python* qui utilisent les " "expressions ``yield from`` pour attendre des *futurs* et autres coroutines." -#: library/asyncio-task.rst:1061 +#: library/asyncio-task.rst:1066 msgid "" "Generator-based coroutines should be decorated with :func:`@asyncio." "coroutine `, although this is not enforced." @@ -1254,11 +1260,11 @@ msgstr "" "`@asyncio.coroutine `, même si ce n'est pas vérifié par " "l'interpréteur." -#: library/asyncio-task.rst:1068 +#: library/asyncio-task.rst:1073 msgid "Decorator to mark generator-based coroutines." msgstr "Décorateur pour coroutines basées sur des générateurs." -#: library/asyncio-task.rst:1070 +#: library/asyncio-task.rst:1075 msgid "" "This decorator enables legacy generator-based coroutines to be compatible " "with async/await code::" @@ -1266,22 +1272,22 @@ msgstr "" "Ce décorateur rend compatibles les coroutines basées sur des générateurs " "avec le code *async* / *await* ::" -#: library/asyncio-task.rst:1080 +#: library/asyncio-task.rst:1085 msgid "This decorator should not be used for :keyword:`async def` coroutines." msgstr "" "Ce décorateur ne doit pas être utilisé avec des coroutines :keyword:`async " "def`." # pas de majuscule car suit un deux-points -#: library/asyncio-task.rst:1085 +#: library/asyncio-task.rst:1090 msgid "Use :keyword:`async def` instead." msgstr "utilisez :keyword:`async def` à la place." -#: library/asyncio-task.rst:1089 +#: library/asyncio-task.rst:1094 msgid "Return ``True`` if *obj* is a :ref:`coroutine object `." msgstr "Renvoie ``True`` si *obj* est un :ref:`objet coroutine `." -#: library/asyncio-task.rst:1091 +#: library/asyncio-task.rst:1096 msgid "" "This method is different from :func:`inspect.iscoroutine` because it returns " "``True`` for generator-based coroutines." @@ -1289,12 +1295,12 @@ msgstr "" "Cette méthode est différente de :func:`inspect.iscoroutine` car elle renvoie " "``True`` pour des coroutines basées sur des générateurs." -#: library/asyncio-task.rst:1096 +#: library/asyncio-task.rst:1101 msgid "Return ``True`` if *func* is a :ref:`coroutine function `." msgstr "" "Renvoie ``True`` si *func* est une :ref:`fonction coroutine `." -#: library/asyncio-task.rst:1099 +#: library/asyncio-task.rst:1104 msgid "" "This method is different from :func:`inspect.iscoroutinefunction` because it " "returns ``True`` for generator-based coroutine functions decorated with :" diff --git a/library/audioop.po b/library/audioop.po index 4b090157..c7943d12 100644 --- a/library/audioop.po +++ b/library/audioop.po @@ -5,14 +5,14 @@ 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-11-27 10:27+0100\n" "PO-Revision-Date: 2021-11-15 19:06-0500\n" +"Last-Translator: Edith Viau \n" "Language-Team: FRENCH \n" "Language: fr\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"Last-Translator: Edith Viau \n" "X-Generator: Poedit 2.3\n" #: library/audioop.rst:2 diff --git a/library/bz2.po b/library/bz2.po index b1a2b3cf..cab82e5f 100644 --- a/library/bz2.po +++ b/library/bz2.po @@ -5,15 +5,15 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-11-06 20:24+0100\n" +"Last-Translator: Jean Abou Samra \n" "Language-Team: FRENCH \n" "Language: fr\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "X-Generator: Poedit 3.0\n" -"Last-Translator: Jean Abou Samra \n" #: library/bz2.rst:2 msgid ":mod:`bz2` --- Support for :program:`bzip2` compression" diff --git a/library/codeop.po b/library/codeop.po index 6ada7c0f..1d77275e 100644 --- a/library/codeop.po +++ b/library/codeop.po @@ -5,14 +5,14 @@ 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-11-27 10:27+0100\n" "PO-Revision-Date: 2021-11-06 20:25+0100\n" +"Last-Translator: Jean Abou Samra \n" "Language-Team: FRENCH \n" "Language: fr\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"Last-Translator: Jean Abou Samra \n" "X-Generator: Poedit 3.0\n" #: library/codeop.rst:2 diff --git a/library/contextlib.po b/library/contextlib.po index 7360e26b..51a86ab8 100644 --- a/library/contextlib.po +++ b/library/contextlib.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-11-06 21:37+0100\n" "Last-Translator: Jean Abou Samra \n" "Language-Team: FRENCH \n" @@ -203,7 +203,7 @@ msgstr "" "peuvent s'utiliser comme décorateurs ou dans les instructions :keyword:" "`async with` :" -#: library/contextlib.rst:145 +#: library/contextlib.rst:147 msgid "" "When used as a decorator, a new generator instance is implicitly created on " "each function call. This allows the otherwise \"one-shot\" context managers " @@ -211,7 +211,7 @@ msgid "" "managers support multiple invocations in order to be used as decorators." msgstr "" -#: library/contextlib.rst:150 +#: library/contextlib.rst:152 #, fuzzy msgid "" "Async context managers created with :func:`asynccontextmanager` can be used " @@ -220,7 +220,7 @@ msgstr "" "Une classe mère qui permet à un gestionnaire de contexte d'être aussi " "utilisé comme décorateur." -#: library/contextlib.rst:157 +#: library/contextlib.rst:159 msgid "" "Return a context manager that closes *thing* upon completion of the block. " "This is basically equivalent to::" @@ -228,11 +228,11 @@ msgstr "" "Renvoie un gestionnaire de contexte qui ferme *thing* à la fin du bloc. " "C'est essentiellement équivalent à ::" -#: library/contextlib.rst:169 +#: library/contextlib.rst:171 msgid "And lets you write code like this::" msgstr "Et cela vous permet d'écrire du code tel que ::" -#: library/contextlib.rst:178 +#: library/contextlib.rst:180 msgid "" "without needing to explicitly close ``page``. Even if an error occurs, " "``page.close()`` will be called when the :keyword:`with` block is exited." @@ -240,7 +240,7 @@ msgstr "" "sans besoin de fermer explicitement ``page``. Même si une erreur survient, " "``page.close()`` est appelée à la fermeture du bloc :keyword:`with`." -#: library/contextlib.rst:184 +#: library/contextlib.rst:186 #, fuzzy msgid "" "Return an async context manager that calls the ``aclose()`` method of " @@ -249,14 +249,14 @@ msgstr "" "Renvoie un gestionnaire de contexte qui ferme *thing* à la fin du bloc. " "C'est essentiellement équivalent à ::" -#: library/contextlib.rst:196 +#: library/contextlib.rst:198 msgid "" "Significantly, ``aclosing()`` supports deterministic cleanup of async " "generators when they happen to exit early by :keyword:`break` or an " "exception. For example::" msgstr "" -#: library/contextlib.rst:207 +#: library/contextlib.rst:209 msgid "" "This pattern ensures that the generator's async exit code is executed in the " "same context as its iterations (so that exceptions and context variables " @@ -264,7 +264,7 @@ msgid "" "task it depends on)." msgstr "" -#: library/contextlib.rst:219 +#: library/contextlib.rst:221 msgid "" "Return a context manager that returns *enter_result* from ``__enter__``, but " "otherwise does nothing. It is intended to be used as a stand-in for an " @@ -274,11 +274,11 @@ msgstr "" "*enter_result*, mais ne fait rien d'autre. L'idée est de l'utiliser comme " "remplaçant pour un gestionnaire de contexte optionnel, par exemple ::" -#: library/contextlib.rst:233 +#: library/contextlib.rst:235 msgid "An example using *enter_result*::" msgstr "Un exemple utilisant *enter_result* ::" -#: library/contextlib.rst:246 +#: library/contextlib.rst:248 #, fuzzy msgid "" "It can also be used as a stand-in for :ref:`asynchronous context managers " @@ -287,11 +287,11 @@ msgstr "" "Similaire à :func:`~contextlib.contextmanager`, mais crée un :ref:" "`gestionnaire de contexte asynchrone `." -#: library/contextlib.rst:262 +#: library/contextlib.rst:264 msgid ":term:`asynchronous context manager` support was added." msgstr "" -#: library/contextlib.rst:269 +#: library/contextlib.rst:271 #, fuzzy msgid "" "Return a context manager that suppresses any of the specified exceptions if " @@ -303,7 +303,7 @@ msgstr "" "spécifiées si elles surviennent dans le corps du bloc *with*, et reprend " "l'exécution sur la première instruction qui suit la fin du bloc *with*." -#: library/contextlib.rst:274 +#: library/contextlib.rst:276 msgid "" "As with any other mechanism that completely suppresses exceptions, this " "context manager should be used only to cover very specific errors where " @@ -315,19 +315,19 @@ msgstr "" "très spécifiques d'erreurs où il est certain que continuer silencieusement " "l'exécution du programme est la bonne chose à faire." -#: library/contextlib.rst:279 +#: library/contextlib.rst:281 msgid "For example::" msgstr "Par exemple ::" -#: library/contextlib.rst:289 +#: library/contextlib.rst:291 msgid "This code is equivalent to::" msgstr "Ce code est équivalent à ::" -#: library/contextlib.rst:341 library/contextlib.rst:351 +#: library/contextlib.rst:343 library/contextlib.rst:353 msgid "This context manager is :ref:`reentrant `." msgstr "Ce gestionnaire de contexte est :ref:`réentrant `." -#: library/contextlib.rst:308 +#: library/contextlib.rst:310 msgid "" "Context manager for temporarily redirecting :data:`sys.stdout` to another " "file or file-like object." @@ -335,7 +335,7 @@ msgstr "" "Gestionnaire de contexte servant à rediriger temporairement :data:`sys." "stdout` vers un autre fichier ou objet fichier-compatible." -#: library/contextlib.rst:311 +#: library/contextlib.rst:313 msgid "" "This tool adds flexibility to existing functions or classes whose output is " "hardwired to stdout." @@ -343,7 +343,7 @@ msgstr "" "Cet outil ajoute une certaine flexibilité aux fonctions ou classes " "existantes dont la sortie est envoyée vers la sortie standard." -#: library/contextlib.rst:314 +#: library/contextlib.rst:316 #, fuzzy msgid "" "For example, the output of :func:`help` normally is sent to *sys.stdout*. " @@ -356,7 +356,7 @@ msgstr "" "stdout*. Vous pouvez capturer cette sortie dans une chaîne de caractères en " "la redirigeant vers un objet :class:`io.StringIO` ::" -#: library/contextlib.rst:324 +#: library/contextlib.rst:326 msgid "" "To send the output of :func:`help` to a file on disk, redirect the output to " "a regular file::" @@ -364,11 +364,11 @@ msgstr "" "Pour envoyer la sortie de :func:`help` vers un fichier sur le disque, " "redirigez-la sur un fichier normal ::" -#: library/contextlib.rst:331 +#: library/contextlib.rst:333 msgid "To send the output of :func:`help` to *sys.stderr*::" msgstr "Pour envoyer la sortie de :func:`help` sur *sys.stderr* ::" -#: library/contextlib.rst:336 +#: library/contextlib.rst:338 msgid "" "Note that the global side effect on :data:`sys.stdout` means that this " "context manager is not suitable for use in library code and most threaded " @@ -382,7 +382,7 @@ msgstr "" "Cependant, cela reste une approche utile pour beaucoup de scripts " "utilitaires." -#: library/contextlib.rst:348 +#: library/contextlib.rst:350 msgid "" "Similar to :func:`~contextlib.redirect_stdout` but redirecting :data:`sys." "stderr` to another file or file-like object." @@ -390,14 +390,14 @@ msgstr "" "Similaire à :func:`~contextlib.redirect_stdout` mais redirige :data:`sys." "stderr` vers un autre fichier ou objet fichier-compatible." -#: library/contextlib.rst:358 +#: library/contextlib.rst:360 msgid "" "A base class that enables a context manager to also be used as a decorator." msgstr "" "Une classe mère qui permet à un gestionnaire de contexte d'être aussi " "utilisé comme décorateur." -#: library/contextlib.rst:360 +#: library/contextlib.rst:362 msgid "" "Context managers inheriting from ``ContextDecorator`` have to implement " "``__enter__`` and ``__exit__`` as normal. ``__exit__`` retains its optional " @@ -408,7 +408,7 @@ msgstr "" "conserve sa gestion optionnelle des exceptions même lors de l'utilisation en " "décorateur." -#: library/contextlib.rst:364 +#: library/contextlib.rst:366 msgid "" "``ContextDecorator`` is used by :func:`contextmanager`, so you get this " "functionality automatically." @@ -416,22 +416,22 @@ msgstr "" "``ContextDecorator`` est utilisé par :func:`contextmanager`, donc vous " "bénéficiez automatiquement de cette fonctionnalité." -#: library/contextlib.rst:367 +#: library/contextlib.rst:369 msgid "Example of ``ContextDecorator``::" msgstr "Exemple de ``ContextDecorator`` ::" -#: library/contextlib.rst:396 +#: library/contextlib.rst:398 msgid "" "This change is just syntactic sugar for any construct of the following form::" msgstr "" "Ce changement est simplement un sucre syntaxique pour les constructions de " "la forme suivante ::" -#: library/contextlib.rst:402 +#: library/contextlib.rst:404 msgid "``ContextDecorator`` lets you instead write::" msgstr "``ContextDecorator`` vous permet d'écrire à la place ::" -#: library/contextlib.rst:408 +#: library/contextlib.rst:410 msgid "" "It makes it clear that the ``cm`` applies to the whole function, rather than " "just a piece of it (and saving an indentation level is nice, too)." @@ -440,7 +440,7 @@ msgstr "" "seulement à un morceau en particulier (et gagner un niveau d'indentation est " "toujours appréciable)." -#: library/contextlib.rst:411 +#: library/contextlib.rst:413 msgid "" "Existing context managers that already have a base class can be extended by " "using ``ContextDecorator`` as a mixin class::" @@ -448,7 +448,7 @@ msgstr "" "Les gestionnaires de contexte existants qui ont déjà une classe mère peuvent " "être étendus en utilisant ``ContextDecorator`` comme une *mixin* ::" -#: library/contextlib.rst:424 +#: library/contextlib.rst:426 msgid "" "As the decorated function must be able to be called multiple times, the " "underlying context manager must support use in multiple :keyword:`with` " @@ -461,7 +461,7 @@ msgstr "" "construction d'origine avec de multiples instructions :keyword:`!with` au " "sein de la fonction doit être utilisée." -#: library/contextlib.rst:434 +#: library/contextlib.rst:436 #, fuzzy msgid "" "Similar to :class:`ContextDecorator` but only for asynchronous functions." @@ -469,12 +469,12 @@ msgstr "" "Similaire à :meth:`enter_context` mais attend un gestionnaire de contexte " "asynchrone." -#: library/contextlib.rst:436 +#: library/contextlib.rst:438 #, fuzzy msgid "Example of ``AsyncContextDecorator``::" msgstr "Exemple de ``ContextDecorator`` ::" -#: library/contextlib.rst:473 +#: library/contextlib.rst:475 msgid "" "A context manager that is designed to make it easy to programmatically " "combine other context managers and cleanup functions, especially those that " @@ -485,7 +485,7 @@ msgstr "" "nettoyage, spécifiquement ceux qui sont optionnels ou pilotés par des " "données d'entrée." -#: library/contextlib.rst:477 +#: library/contextlib.rst:479 msgid "" "For example, a set of files may easily be handled in a single with statement " "as follows::" @@ -493,7 +493,7 @@ msgstr "" "Par exemple, un ensemble de fichiers peut facilement être géré dans une " "unique instruction *with* comme suit ::" -#: library/contextlib.rst:486 +#: library/contextlib.rst:488 msgid "" "Each instance maintains a stack of registered callbacks that are called in " "reverse order when the instance is closed (either explicitly or implicitly " @@ -506,7 +506,7 @@ msgstr "" "que ces fonctions ne sont *pas* invoquées implicitement quand l'instance de " "la pile de contextes est collectée par le ramasse-miettes." -#: library/contextlib.rst:491 +#: library/contextlib.rst:493 msgid "" "This stack model is used so that context managers that acquire their " "resources in their ``__init__`` method (such as file objects) can be handled " @@ -516,7 +516,7 @@ msgstr "" "acquièrent leurs ressources dans leur méthode ``__init__`` (tels que les " "objets-fichiers) puissent être gérés correctement." -#: library/contextlib.rst:495 +#: library/contextlib.rst:497 msgid "" "Since registered callbacks are invoked in the reverse order of registration, " "this ends up behaving as if multiple nested :keyword:`with` statements had " @@ -532,7 +532,7 @@ msgstr "" "de rappel intérieure supprime ou remplace une exception, alors les fonctions " "extérieures reçoivent des arguments basés sur ce nouvel état." -#: library/contextlib.rst:502 +#: library/contextlib.rst:504 msgid "" "This is a relatively low level API that takes care of the details of " "correctly unwinding the stack of exit callbacks. It provides a suitable " @@ -544,7 +544,7 @@ msgstr "" "pour des gestionnaires de contexte de plus haut niveau qui manipulent la " "pile de sortie de manière spécifique à l'application." -#: library/contextlib.rst:511 +#: library/contextlib.rst:513 msgid "" "Enters a new context manager and adds its :meth:`__exit__` method to the " "callback stack. The return value is the result of the context manager's own :" @@ -554,7 +554,7 @@ msgstr "" "`__exit__` à la pile d'appels. La valeur de retour est le résultat de la " "méthode :meth:`__enter__` du gestionnaire de contexte donné." -#: library/contextlib.rst:515 +#: library/contextlib.rst:517 msgid "" "These context managers may suppress exceptions just as they normally would " "if used directly as part of a :keyword:`with` statement." @@ -563,13 +563,13 @@ msgstr "" "feraient normalement s'ils étaient utilisés directement derrière une " "instruction :keyword:`with`." -#: library/contextlib.rst:520 +#: library/contextlib.rst:522 msgid "Adds a context manager's :meth:`__exit__` method to the callback stack." msgstr "" "Ajoute la méthode :meth:`__exit__` d'un gestionnaire de contexte à la pile " "d'appels." -#: library/contextlib.rst:522 +#: library/contextlib.rst:524 msgid "" "As ``__enter__`` is *not* invoked, this method can be used to cover part of " "an :meth:`__enter__` implementation with a context manager's own :meth:" @@ -579,7 +579,7 @@ msgstr "" "pour couvrir une partie de l'implémentation de :meth:`__enter__` avec la " "propre méthode :meth:`__exit__` d'un gestionnaire de contexte." -#: library/contextlib.rst:526 +#: library/contextlib.rst:528 msgid "" "If passed an object that is not a context manager, this method assumes it is " "a callback with the same signature as a context manager's :meth:`__exit__` " @@ -590,7 +590,7 @@ msgstr "" "meth:`__exit__` des gestionnaires de contexte pour l'ajouter directement à " "la pile d'appels." -#: library/contextlib.rst:530 +#: library/contextlib.rst:532 msgid "" "By returning true values, these callbacks can suppress exceptions the same " "way context manager :meth:`__exit__` methods can." @@ -599,7 +599,7 @@ msgstr "" "exceptions de la même manière que le peuvent les méthodes :meth:`__exit__` " "des gestionnaires de contexte." -#: library/contextlib.rst:533 +#: library/contextlib.rst:535 msgid "" "The passed in object is returned from the function, allowing this method to " "be used as a function decorator." @@ -607,7 +607,7 @@ msgstr "" "L'objet passé en paramètre est renvoyé par la fonction, ce qui permet à la " "méthode d'être utilisée comme décorateur de fonction." -#: library/contextlib.rst:538 +#: library/contextlib.rst:540 msgid "" "Accepts an arbitrary callback function and arguments and adds it to the " "callback stack." @@ -615,7 +615,7 @@ msgstr "" "Accepte une fonction arbitraire et ses arguments et les ajoute à la pile des " "fonctions de rappel." -#: library/contextlib.rst:541 +#: library/contextlib.rst:543 msgid "" "Unlike the other methods, callbacks added this way cannot suppress " "exceptions (as they are never passed the exception details)." @@ -624,7 +624,7 @@ msgstr "" "cette manière ne peuvent pas supprimer les exceptions (puisqu'elles ne " "reçoivent jamais les détails de l'exception)." -#: library/contextlib.rst:544 +#: library/contextlib.rst:546 msgid "" "The passed in callback is returned from the function, allowing this method " "to be used as a function decorator." @@ -632,7 +632,7 @@ msgstr "" "La fonction passée en paramètre est renvoyée par la méthode, ce qui permet à " "la méthode d'être utilisée comme décorateur de fonction." -#: library/contextlib.rst:549 +#: library/contextlib.rst:551 msgid "" "Transfers the callback stack to a fresh :class:`ExitStack` instance and " "returns it. No callbacks are invoked by this operation - instead, they will " @@ -644,7 +644,7 @@ msgstr "" "la place, elles sont dorénavant invoquées quand la nouvelle pile sera close " "(soit explicitement soit implicitement à la fin d'un bloc :keyword:`with`)." -#: library/contextlib.rst:554 +#: library/contextlib.rst:556 msgid "" "For example, a group of files can be opened as an \"all or nothing\" " "operation as follows::" @@ -652,7 +652,7 @@ msgstr "" "Par exemple, un groupe de fichiers peut être ouvert comme une opération " "« tout ou rien » comme suit ::" -#: library/contextlib.rst:568 +#: library/contextlib.rst:570 msgid "" "Immediately unwinds the callback stack, invoking callbacks in the reverse " "order of registration. For any context managers and exit callbacks " @@ -663,7 +663,7 @@ msgstr "" "et fonction de sortie enregistré, les arguments passés indiqueront qu'aucune " "exception n'est survenue." -#: library/contextlib.rst:575 +#: library/contextlib.rst:577 msgid "" "An :ref:`asynchronous context manager `, similar to :" "class:`ExitStack`, that supports combining both synchronous and asynchronous " @@ -674,7 +674,7 @@ msgstr "" "de contexte synchrones et asynchrones, ainsi que la gestion de coroutines " "pour la logique de nettoyage." -#: library/contextlib.rst:580 +#: library/contextlib.rst:582 msgid "" "The :meth:`close` method is not implemented, :meth:`aclose` must be used " "instead." @@ -682,14 +682,14 @@ msgstr "" "La méthode :meth:`close` n'est pas implémentée, :meth:`aclose` doit plutôt " "être utilisée." -#: library/contextlib.rst:585 +#: library/contextlib.rst:587 msgid "" "Similar to :meth:`enter_context` but expects an asynchronous context manager." msgstr "" "Similaire à :meth:`enter_context` mais attend un gestionnaire de contexte " "asynchrone." -#: library/contextlib.rst:590 +#: library/contextlib.rst:592 msgid "" "Similar to :meth:`push` but expects either an asynchronous context manager " "or a coroutine function." @@ -697,24 +697,24 @@ msgstr "" "Similaire à :meth:`push` mais attend soit un gestionnaire de contexte " "asynchrone soit une fonction coroutine." -#: library/contextlib.rst:595 +#: library/contextlib.rst:597 msgid "Similar to :meth:`callback` but expects a coroutine function." msgstr "Similaire à :meth:`callback` mais attend une fonction coroutine." -#: library/contextlib.rst:599 +#: library/contextlib.rst:601 msgid "Similar to :meth:`close` but properly handles awaitables." msgstr "" "Similaire à :meth:`close` mais gère correctement les tâches asynchrones." -#: library/contextlib.rst:601 +#: library/contextlib.rst:603 msgid "Continuing the example for :func:`asynccontextmanager`::" msgstr "En continuité de l'exemple de :func:`asynccontextmanager` ::" -#: library/contextlib.rst:613 +#: library/contextlib.rst:615 msgid "Examples and Recipes" msgstr "Exemples et Recettes" -#: library/contextlib.rst:615 +#: library/contextlib.rst:617 msgid "" "This section describes some examples and recipes for making effective use of " "the tools provided by :mod:`contextlib`." @@ -722,11 +722,11 @@ msgstr "" "Cette section décrit quelques exemples et recettes pour décrire une " "utilisation réelle des outils fournis par :mod:`contextlib`." -#: library/contextlib.rst:620 +#: library/contextlib.rst:622 msgid "Supporting a variable number of context managers" msgstr "Gérer un nombre variable de gestionnaires de contexte" -#: library/contextlib.rst:622 +#: library/contextlib.rst:624 msgid "" "The primary use case for :class:`ExitStack` is the one given in the class " "documentation: supporting a variable number of context managers and other " @@ -743,7 +743,7 @@ msgstr "" "collection spécifique de fichiers de l'utilisateur), ou de certains " "gestionnaires de contexte qui peuvent être optionnels ::" -#: library/contextlib.rst:637 +#: library/contextlib.rst:639 msgid "" "As shown, :class:`ExitStack` also makes it quite easy to use :keyword:`with` " "statements to manage arbitrary resources that don't natively support the " @@ -753,11 +753,11 @@ msgstr "" "instructions :keyword:`with` pour gérer des ressources arbitraires qui ne " "gèrent pas nativement le protocole des gestionnaires de contexte." -#: library/contextlib.rst:643 +#: library/contextlib.rst:645 msgid "Catching exceptions from ``__enter__`` methods" msgstr "Attraper des exceptions depuis les méthodes ``__enter__``" -#: library/contextlib.rst:645 +#: library/contextlib.rst:647 msgid "" "It is occasionally desirable to catch exceptions from an ``__enter__`` " "method implementation, *without* inadvertently catching exceptions from the :" @@ -772,7 +772,7 @@ msgstr "" "`ExitStack`, les étapes du protocole des gestionnaires de contexte peuvent " "être légèrement séparées pour permettre le code suivant ::" -#: library/contextlib.rst:660 +#: library/contextlib.rst:662 msgid "" "Actually needing to do this is likely to indicate that the underlying API " "should be providing a direct resource management interface for use with :" @@ -791,11 +791,11 @@ msgstr "" "gestion de plusieurs situations qui ne peuvent pas être traitées directement " "dans une instruction :keyword:`with`." -#: library/contextlib.rst:670 +#: library/contextlib.rst:672 msgid "Cleaning up in an ``__enter__`` implementation" msgstr "Nettoyer dans une méthode ``__enter__``" -#: library/contextlib.rst:672 +#: library/contextlib.rst:674 msgid "" "As noted in the documentation of :meth:`ExitStack.push`, this method can be " "useful in cleaning up an already allocated resource if later steps in the :" @@ -805,7 +805,7 @@ msgstr "" "peut être utile pour nettoyer une ressource déjà allouée si les dernières " "étapes de l'implémentation de :meth:`__enter__` échouent." -#: library/contextlib.rst:676 +#: library/contextlib.rst:678 msgid "" "Here's an example of doing this for a context manager that accepts resource " "acquisition and release functions, along with an optional validation " @@ -815,11 +815,11 @@ msgstr "" "d'acquisition de ressources et de libération, avec une méthode de validation " "optionnelle, et qui les adapte au protocole des gestionnaires de contexte ::" -#: library/contextlib.rst:716 +#: library/contextlib.rst:718 msgid "Replacing any use of ``try-finally`` and flag variables" msgstr "Remplacer un ``try-finally`` avec une option variable" -#: library/contextlib.rst:718 +#: library/contextlib.rst:720 msgid "" "A pattern you will sometimes see is a ``try-finally`` statement with a flag " "variable to indicate whether or not the body of the ``finally`` clause " @@ -831,7 +831,7 @@ msgstr "" "ou non. Dans sa forme la plus simple (qui ne peut pas déjà être gérée avec " "juste une clause ``except``), cela ressemble à ::" -#: library/contextlib.rst:732 +#: library/contextlib.rst:734 msgid "" "As with any ``try`` statement based code, this can cause problems for " "development and review, because the setup code and the cleanup code can end " @@ -842,7 +842,7 @@ msgstr "" "codes d'installation et de nettoyage peuvent finir par être séparés par des " "sections de code arbitrairement longues." -#: library/contextlib.rst:736 +#: library/contextlib.rst:738 msgid "" ":class:`ExitStack` makes it possible to instead register a callback for " "execution at the end of a ``with`` statement, and then later decide to skip " @@ -852,7 +852,7 @@ msgstr "" "rappel pour être exécutée à la fin d'une instruction ``with``, et décider " "ensuite de passer l'exécution de cet appel ::" -#: library/contextlib.rst:748 +#: library/contextlib.rst:750 msgid "" "This allows the intended cleanup up behaviour to be made explicit up front, " "rather than requiring a separate flag variable." @@ -860,7 +860,7 @@ msgstr "" "Cela permet de rendre explicite dès le départ le comportement de nettoyage " "attendu, plutôt que de nécessiter une option séparée." -#: library/contextlib.rst:751 +#: library/contextlib.rst:753 msgid "" "If a particular application uses this pattern a lot, it can be simplified " "even further by means of a small helper class::" @@ -868,7 +868,7 @@ msgstr "" "Si une application particulière utilise beaucoup ce modèle, cela peut-être " "simplifié encore plus au moyen d'une petite classe d'aide ::" -#: library/contextlib.rst:769 +#: library/contextlib.rst:771 msgid "" "If the resource cleanup isn't already neatly bundled into a standalone " "function, then it is still possible to use the decorator form of :meth:" @@ -879,7 +879,7 @@ msgstr "" "`ExitStack.callback` pour déclarer la fonction de nettoyage de ressource en " "avance ::" -#: library/contextlib.rst:784 +#: library/contextlib.rst:786 msgid "" "Due to the way the decorator protocol works, a callback function declared " "this way cannot take any parameters. Instead, any resources to be released " @@ -890,12 +890,12 @@ msgstr "" "doivent être récupérées depuis l'extérieur comme des variables de fermeture " "(*closure*)." -#: library/contextlib.rst:790 +#: library/contextlib.rst:792 msgid "Using a context manager as a function decorator" msgstr "" "Utiliser un gestionnaire de contexte en tant que décorateur de fonction" -#: library/contextlib.rst:792 +#: library/contextlib.rst:794 msgid "" ":class:`ContextDecorator` makes it possible to use a context manager in both " "an ordinary ``with`` statement and also as a function decorator." @@ -904,7 +904,7 @@ msgstr "" "contexte à la fois ordinairement avec une instruction ``with`` ou comme un " "décorateur de fonction." -#: library/contextlib.rst:795 +#: library/contextlib.rst:797 msgid "" "For example, it is sometimes useful to wrap functions or groups of " "statements with a logger that can track the time of entry and time of exit. " @@ -919,17 +919,17 @@ msgstr "" "`ContextDecorator` fournit les deux fonctionnalités en une seule " "définition ::" -#: library/contextlib.rst:816 +#: library/contextlib.rst:818 msgid "Instances of this class can be used as both a context manager::" msgstr "" "Les instances de cette classe peuvent être utilisées comme gestionnaires de " "contexte ::" -#: library/contextlib.rst:822 +#: library/contextlib.rst:824 msgid "And also as a function decorator::" msgstr "Et comme décorateurs de fonctions ::" -#: library/contextlib.rst:829 +#: library/contextlib.rst:831 msgid "" "Note that there is one additional limitation when using context managers as " "function decorators: there's no way to access the return value of :meth:" @@ -941,11 +941,11 @@ msgstr "" "de retour de :meth:`__enter__`. Si cette valeur est nécessaire, il faut " "utiliser explicitement une instruction ``with``." -#: library/contextlib.rst:837 +#: library/contextlib.rst:839 msgid ":pep:`343` - The \"with\" statement" msgstr ":pep:`343` - The \"with\" statement" -#: library/contextlib.rst:837 +#: library/contextlib.rst:839 msgid "" "The specification, background, and examples for the Python :keyword:`with` " "statement." @@ -953,11 +953,11 @@ msgstr "" "La spécification, les motivations et des exemples de l'instruction :keyword:" "`with` en Python." -#: library/contextlib.rst:843 +#: library/contextlib.rst:845 msgid "Single use, reusable and reentrant context managers" msgstr "Gestionnaires de contexte à usage unique, réutilisables et réentrants" -#: library/contextlib.rst:845 +#: library/contextlib.rst:847 msgid "" "Most context managers are written in a way that means they can only be used " "effectively in a :keyword:`with` statement once. These single use context " @@ -970,7 +970,7 @@ msgstr "" "chaque fois qu'ils sont utilisés — tenter de les utiliser une seconde fois " "lève une exception ou ne fonctionne pas correctement." -#: library/contextlib.rst:851 +#: library/contextlib.rst:853 msgid "" "This common limitation means that it is generally advisable to create " "context managers directly in the header of the :keyword:`with` statement " @@ -981,7 +981,7 @@ msgstr "" "`with` où ils sont utilisés (comme montré dans tous les exemples " "d'utilisation au-dessus)." -#: library/contextlib.rst:855 +#: library/contextlib.rst:857 msgid "" "Files are an example of effectively single use context managers, since the " "first :keyword:`with` statement will close the file, preventing any further " @@ -992,7 +992,7 @@ msgstr "" "`with` ferme le fichier, empêchant d'autres opérations d'entrée/sortie " "d'être exécutées sur ce fichier." -#: library/contextlib.rst:859 +#: library/contextlib.rst:861 msgid "" "Context managers created using :func:`contextmanager` are also single use " "context managers, and will complain about the underlying generator failing " @@ -1002,11 +1002,11 @@ msgstr "" "usage unique, et se plaindront du fait que le générateur sous-jacent ne " "produise plus de valeur si vous essayez de les utiliser une seconde fois ::" -#: library/contextlib.rst:887 +#: library/contextlib.rst:889 msgid "Reentrant context managers" msgstr "Gestionnaires de contexte réentrants" -#: library/contextlib.rst:889 +#: library/contextlib.rst:891 msgid "" "More sophisticated context managers may be \"reentrant\". These context " "managers can not only be used in multiple :keyword:`with` statements, but " @@ -1019,7 +1019,7 @@ msgstr "" "l'intérieur* d'une instruction :keyword:`!with` qui utilise déjà ce même " "gestionnaire de contexte." -#: library/contextlib.rst:894 +#: library/contextlib.rst:896 msgid "" ":class:`threading.RLock` is an example of a reentrant context manager, as " "are :func:`suppress` and :func:`redirect_stdout`. Here's a very simple " @@ -1029,7 +1029,7 @@ msgstr "" "réentrant, comme le sont aussi :func:`suppress` et :func:`redirect_stdout`. " "Voici un très simple exemple d'utilisation réentrante ::" -#: library/contextlib.rst:913 +#: library/contextlib.rst:915 msgid "" "Real world examples of reentrancy are more likely to involve multiple " "functions calling each other and hence be far more complicated than this " @@ -1039,7 +1039,7 @@ msgstr "" "fonctions s'entre-appelant, et donc être bien plus compliqués que cet " "exemple." -#: library/contextlib.rst:917 +#: library/contextlib.rst:919 msgid "" "Note also that being reentrant is *not* the same thing as being thread " "safe. :func:`redirect_stdout`, for example, is definitely not thread safe, " @@ -1051,11 +1051,11 @@ msgstr "" "puisqu'il effectue des changements globaux sur l'état du système en " "branchant :data:`sys.stdout` sur différents flux." -#: library/contextlib.rst:926 +#: library/contextlib.rst:928 msgid "Reusable context managers" msgstr "Gestionnaires de contexte réutilisables" -#: library/contextlib.rst:928 +#: library/contextlib.rst:930 msgid "" "Distinct from both single use and reentrant context managers are \"reusable" "\" context managers (or, to be completely explicit, \"reusable, but not " @@ -1073,7 +1073,7 @@ msgstr "" "contexte référencée a déjà été utilisée dans une instruction *with* " "englobante." -#: library/contextlib.rst:935 +#: library/contextlib.rst:937 msgid "" ":class:`threading.Lock` is an example of a reusable, but not reentrant, " "context manager (for a reentrant lock, it is necessary to use :class:" @@ -1083,7 +1083,7 @@ msgstr "" "réutilisable mais pas réentrant (pour un verrou réentrant, il faut à la " "place utiliser :class:`threading.RLock`)." -#: library/contextlib.rst:939 +#: library/contextlib.rst:941 msgid "" "Another example of a reusable, but not reentrant, context manager is :class:" "`ExitStack`, as it invokes *all* currently registered callbacks when leaving " @@ -1094,7 +1094,7 @@ msgstr "" "actuellement enregistrées en quittant l'instruction *with*, sans regarder où " "ces fonctions ont été ajoutées ::" -#: library/contextlib.rst:970 +#: library/contextlib.rst:972 msgid "" "As the output from the example shows, reusing a single stack object across " "multiple with statements works correctly, but attempting to nest them will " @@ -1106,7 +1106,7 @@ msgstr "" "imbriquer fait que la pile est vidée à la fin du *with* le plus imbriqué, ce " "qui n'est probablement pas le comportement voulu." -#: library/contextlib.rst:975 +#: library/contextlib.rst:977 msgid "" "Using separate :class:`ExitStack` instances instead of reusing a single " "instance avoids that problem::" diff --git a/library/copy.po b/library/copy.po index 264fc7cb..1647e32a 100644 --- a/library/copy.po +++ b/library/copy.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2019-02-21 17:18+0100\n" "Last-Translator: \n" "Language-Team: FRENCH \n" @@ -127,9 +127,10 @@ msgstr "" "ou l'ensemble de composants copiés." #: library/copy.rst:62 +#, fuzzy msgid "" "This module does not copy types like module, method, stack trace, stack " -"frame, file, socket, window, array, or any similar types. It does \"copy\" " +"frame, file, socket, window, or any similar types. It does \"copy\" " "functions and classes (shallow and deeply), by returning the original object " "unchanged; this is compatible with the way these are treated by the :mod:" "`pickle` module." diff --git a/library/enum.po b/library/enum.po index d733bcdc..c3fbc63a 100644 --- a/library/enum.po +++ b/library/enum.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-11-04 18:14+0100\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2019-12-11 11:26+0100\n" "Last-Translator: Antoine Wecxsteen\n" "Language-Team: FRENCH \n" @@ -1308,7 +1308,7 @@ msgstr "" "majuscules) ::" #: library/enum.rst:1155 -msgid "This behavior is deprecated and will be removed in 3.12." +msgid "This behavior is deprecated and will be removed in 3.11." msgstr "" #: library/enum.rst:1161 diff --git a/library/functions.po b/library/functions.po index 9592d998..51a83e36 100644 --- a/library/functions.po +++ b/library/functions.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-11-04 18:14+0100\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2020-08-30 23:21+0200\n" "Last-Translator: Antoine Wecxsteen\n" "Language-Team: FRENCH \n" @@ -411,16 +411,10 @@ msgid "" msgstr "" #: library/functions.rst:69 -msgid "" -"``aiter(x)`` itself has an ``__aiter__()`` method that returns ``x``, so " -"``aiter(aiter(x))`` is the same as ``aiter(x)``." -msgstr "" - -#: library/functions.rst:72 msgid "Note: Unlike :func:`iter`, :func:`aiter` has no 2-argument variant." msgstr "" -#: library/functions.rst:78 +#: library/functions.rst:75 msgid "" "Return ``True`` if all elements of the *iterable* are true (or if the " "iterable is empty). Equivalent to::" @@ -428,18 +422,18 @@ msgstr "" "Renvoie ``True`` si tous les éléments de *iterable* sont vrais (ou s'il est " "vide). Équivaut à ::" -#: library/functions.rst:90 +#: library/functions.rst:87 msgid "" "When awaited, return the next item from the given :term:`asynchronous " "iterator`, or *default* if given and the iterator is exhausted." msgstr "" -#: library/functions.rst:93 +#: library/functions.rst:90 msgid "" "This is the async variant of the :func:`next` builtin, and behaves similarly." msgstr "" -#: library/functions.rst:96 +#: library/functions.rst:93 #, fuzzy msgid "" "This calls the :meth:`~object.__anext__` method of *async_iterator*, " @@ -451,7 +445,7 @@ msgstr "" "__next__`. Si *default* est fourni, il sera renvoyé si l'itérateur est " "épuisé, sinon :exc:`StopIteration` est levée." -#: library/functions.rst:105 +#: library/functions.rst:102 msgid "" "Return ``True`` if any element of the *iterable* is true. If the iterable " "is empty, return ``False``. Equivalent to::" @@ -459,7 +453,7 @@ msgstr "" "Renvoie ``True`` si au moins un élément de *iterable* est vrai. ``False`` " "est renvoyé dans le cas où *iterable* est vide. Équivaut à ::" -#: library/functions.rst:117 +#: library/functions.rst:114 #, fuzzy msgid "" "As :func:`repr`, return a string containing a printable representation of an " @@ -473,7 +467,7 @@ msgstr "" "ou ``\\U``. Cela génère une chaîne similaire à ce que renvoie :func:`repr` " "dans Python 2." -#: library/functions.rst:125 +#: library/functions.rst:122 msgid "" "Convert an integer number to a binary string prefixed with \"0b\". The " "result is a valid Python expression. If *x* is not a Python :class:`int` " @@ -485,7 +479,7 @@ msgstr "" "class:`int`, il doit définir une méthode :meth:`__index__` donnant un nombre " "entier. Voici quelques exemples :" -#: library/functions.rst:135 +#: library/functions.rst:132 #, fuzzy msgid "" "If the prefix \"0b\" is desired or not, you can use either of the following " @@ -494,11 +488,11 @@ msgstr "" "Pour contrôler l'affichage du préfixe ``0b``, vous pouvez utiliser les " "moyens suivants." -#: library/functions.rst:807 library/functions.rst:1102 +#: library/functions.rst:804 library/functions.rst:1099 msgid "See also :func:`format` for more information." msgstr "Voir aussi :func:`format` pour plus d'informations." -#: library/functions.rst:147 +#: library/functions.rst:144 #, fuzzy msgid "" "Return a Boolean value, i.e. one of ``True`` or ``False``. *x* is converted " @@ -516,11 +510,11 @@ msgstr "" "ses seules instances sont ``False`` et ``True`` (voir :ref:`bltin-boolean-" "values`)." -#: library/functions.rst:675 library/functions.rst:891 +#: library/functions.rst:672 library/functions.rst:888 msgid "*x* is now a positional-only parameter." msgstr "*x* est désormais un argument exclusivement optionnel." -#: library/functions.rst:161 +#: library/functions.rst:158 msgid "" "This function drops you into the debugger at the call site. Specifically, " "it calls :func:`sys.breakpointhook`, passing ``args`` and ``kws`` straight " @@ -541,7 +535,7 @@ msgstr "" "`sys.breakpointhook`, que :func:`breakpoint` appellera automatiquement, vous " "permettant ainsi de basculer dans le débogueur de votre choix." -#: library/functions.rst:171 +#: library/functions.rst:168 msgid "" "Raises an :ref:`auditing event ` ``builtins.breakpoint`` with " "argument ``breakpointhook``." @@ -549,7 +543,7 @@ msgstr "" "Lève un :ref:`auditing event ` ``builtins.breakpoint`` avec " "l'argument ``breakpointhook``." -#: library/functions.rst:179 +#: library/functions.rst:176 msgid "" "Return a new array of bytes. The :class:`bytearray` class is a mutable " "sequence of integers in the range 0 <= x < 256. It has most of the usual " @@ -562,7 +556,7 @@ msgstr "" "`typesseq-mutable`, ainsi que la plupart des méthodes de la classe :class:" "`bytes`, voir :ref:`bytes-methods`." -#: library/functions.rst:184 +#: library/functions.rst:181 msgid "" "The optional *source* parameter can be used to initialize the array in a few " "different ways:" @@ -570,7 +564,7 @@ msgstr "" "Le paramètre optionnel *source* peut être utilisé pour initialiser le " "tableau de plusieurs façons :" -#: library/functions.rst:187 +#: library/functions.rst:184 msgid "" "If it is a *string*, you must also give the *encoding* (and optionally, " "*errors*) parameters; :func:`bytearray` then converts the string to bytes " @@ -580,7 +574,7 @@ msgstr "" "l'encodage (et éventuellement *errors*). La fonction :func:`bytearray` " "convertit ensuite la chaîne en octets via la méthode :meth:`str.encode` ;" -#: library/functions.rst:191 +#: library/functions.rst:188 msgid "" "If it is an *integer*, the array will have that size and will be initialized " "with null bytes." @@ -588,7 +582,7 @@ msgstr "" "si c'est un *entier*, le tableau a cette taille et est initialisé d'octets " "*null* ;" -#: library/functions.rst:194 +#: library/functions.rst:191 #, fuzzy msgid "" "If it is an object conforming to the :ref:`buffer interface " @@ -598,7 +592,7 @@ msgstr "" "si c'est un objet conforme au protocole tampon, un tampon en lecture seule " "de l'objet est utilisé pour initialiser le tableau ;" -#: library/functions.rst:197 +#: library/functions.rst:194 msgid "" "If it is an *iterable*, it must be an iterable of integers in the range ``0 " "<= x < 256``, which are used as the initial contents of the array." @@ -607,15 +601,15 @@ msgstr "" "l'intervalle ``0 <= x < 256``, qui sont utilisés pour initialiser le contenu " "du tableau." -#: library/functions.rst:200 +#: library/functions.rst:197 msgid "Without an argument, an array of size 0 is created." msgstr "Sans argument, un tableau vide est créé." -#: library/functions.rst:202 +#: library/functions.rst:199 msgid "See also :ref:`binaryseq` and :ref:`typebytearray`." msgstr "Voir :ref:`binaryseq` et :ref:`typebytearray`." -#: library/functions.rst:209 +#: library/functions.rst:206 #, fuzzy msgid "" "Return a new \"bytes\" object which is an immutable sequence of integers in " @@ -628,25 +622,25 @@ msgstr "" "version immuable de :class:`bytearray` — avec les mêmes méthodes d'accès, et " "le même comportement lors de l'indexation ou la découpe." -#: library/functions.rst:214 +#: library/functions.rst:211 msgid "" "Accordingly, constructor arguments are interpreted as for :func:`bytearray`." msgstr "" "En conséquence, les arguments du constructeur sont les mêmes que pour :func:" "`bytearray`." -#: library/functions.rst:216 +#: library/functions.rst:213 msgid "Bytes objects can also be created with literals, see :ref:`strings`." msgstr "" "Les objets *bytes* peuvent aussi être créés à partir de littéraux, voir :ref:" "`strings`." -#: library/functions.rst:218 +#: library/functions.rst:215 msgid "See also :ref:`binaryseq`, :ref:`typebytes`, and :ref:`bytes-methods`." msgstr "" "Voir aussi :ref:`binaryseq`, :ref:`typebytes`, et :ref:`bytes-methods`." -#: library/functions.rst:223 +#: library/functions.rst:220 msgid "" "Return :const:`True` if the *object* argument appears callable, :const:" "`False` if not. If this returns ``True``, it is still possible that a call " @@ -661,7 +655,7 @@ msgstr "" "(appeler une classe donne une nouvelle instance) ; une instance n'est " "appelable que si sa classe définit une méthode :meth:`__call__`." -#: library/functions.rst:229 +#: library/functions.rst:226 msgid "" "This function was first removed in Python 3.0 and then brought back in " "Python 3.2." @@ -669,7 +663,7 @@ msgstr "" "cette fonction a d'abord été supprimée avec Python 3.0 puis elle a été " "remise dans Python 3.2." -#: library/functions.rst:236 +#: library/functions.rst:233 msgid "" "Return the string representing a character whose Unicode code point is the " "integer *i*. For example, ``chr(97)`` returns the string ``'a'``, while " @@ -680,7 +674,7 @@ msgstr "" "de caractères ``'a'``, tandis que ``chr(8364)`` renvoie ``'€'``. Il s'agit " "de l'inverse de :func:`ord`." -#: library/functions.rst:240 +#: library/functions.rst:237 msgid "" "The valid range for the argument is from 0 through 1,114,111 (0x10FFFF in " "base 16). :exc:`ValueError` will be raised if *i* is outside that range." @@ -689,11 +683,11 @@ msgstr "" "(``0x10FFFF`` en base 16). Une exception :exc:`ValueError` est levée si *i* " "est en dehors de l'intervalle." -#: library/functions.rst:246 +#: library/functions.rst:243 msgid "Transform a method into a class method." msgstr "Transforme une méthode en méthode de classe." -#: library/functions.rst:248 +#: library/functions.rst:245 #, fuzzy msgid "" "A class method receives the class as an implicit first argument, just like " @@ -704,7 +698,7 @@ msgstr "" "tout comme une méthode d'instance reçoit l'instance. Voici comment déclarer " "une méthode de classe ::" -#: library/functions.rst:256 +#: library/functions.rst:253 msgid "" "The ``@classmethod`` form is a function :term:`decorator` -- see :ref:" "`function` for details." @@ -712,7 +706,7 @@ msgstr "" "La forme ``@classmethod`` est un :term:`décorateur ` de fonction " "— consultez :ref:`function` pour plus de détails." -#: library/functions.rst:259 +#: library/functions.rst:256 msgid "" "A class method can be called either on the class (such as ``C.f()``) or on " "an instance (such as ``C().f()``). The instance is ignored except for its " @@ -724,7 +718,7 @@ msgstr "" "sa classe. Si la méthode est appelée sur une instance de classe fille, c'est " "la classe fille qui sera donnée en premier argument implicite." -#: library/functions.rst:264 +#: library/functions.rst:261 msgid "" "Class methods are different than C++ or Java static methods. If you want " "those, see :func:`staticmethod` in this section. For more information on " @@ -734,7 +728,7 @@ msgstr "" "Java. Si ce sont elles dont vous avez besoin, regardez du côté de :func:" "`staticmethod` dans cette section. Voir aussi :ref:`types`." -#: library/functions.rst:268 +#: library/functions.rst:265 msgid "" "Class methods can now wrap other :term:`descriptors ` such as :" "func:`property`." @@ -742,14 +736,14 @@ msgstr "" "les méthodes de classe peuvent encapsuler d'autres :term:`descripteurs " "` comme :func:`property`." -#: library/functions.rst:272 +#: library/functions.rst:269 msgid "" "Class methods now inherit the method attributes (``__module__``, " "``__name__``, ``__qualname__``, ``__doc__`` and ``__annotations__``) and " "have a new ``__wrapped__`` attribute." msgstr "" -#: library/functions.rst:279 +#: library/functions.rst:276 msgid "" "Compile the *source* into a code or AST object. Code objects can be " "executed by :func:`exec` or :func:`eval`. *source* can either be a normal " @@ -761,7 +755,7 @@ msgstr "" "une chaîne d'octets, ou un objet AST. Consultez la documentation du module :" "mod:`ast` pour des informations sur la manipulation d'objets AST." -#: library/functions.rst:284 +#: library/functions.rst:281 msgid "" "The *filename* argument should give the file from which the code was read; " "pass some recognizable value if it wasn't read from a file (``''`` " @@ -771,7 +765,7 @@ msgstr "" "lu. Donnez quelque chose de reconnaissable lorsqu'il n'a pas été lu depuis " "un fichier (typiquement ``\"\"``)." -#: library/functions.rst:288 +#: library/functions.rst:285 msgid "" "The *mode* argument specifies what kind of code must be compiled; it can be " "``'exec'`` if *source* consists of a sequence of statements, ``'eval'`` if " @@ -785,7 +779,7 @@ msgstr "" "(dans ce dernier cas, les résultats d'expressions donnant autre chose que " "``None`` sont affichés)." -#: library/functions.rst:294 +#: library/functions.rst:291 #, fuzzy msgid "" "The optional arguments *flags* and *dont_inherit* control which :ref:" @@ -809,7 +803,7 @@ msgstr "" "un entier différent de zéro, *flags* est utilisé seul — les instructions " "futures déclarées autour de l'appel à *compile* sont ignorées." -#: library/functions.rst:305 +#: library/functions.rst:302 #, fuzzy msgid "" "Compiler options and future statements are specified by bits which can be " @@ -825,7 +819,7 @@ msgstr "" "l'attribut :attr:`~__future__._Feature.compiler_flag` de la classe :class:" "`~__future__.Feature` du module :mod:`__future__`." -#: library/functions.rst:313 +#: library/functions.rst:310 msgid "" "The argument *optimize* specifies the optimization level of the compiler; " "the default value of ``-1`` selects the optimization level of the " @@ -840,7 +834,7 @@ msgstr "" "``1`` (les ``assert`` sont supprimés, ``__debug__`` est ``False``) ou ``2`` " "(les *docstrings* sont également supprimées)." -#: library/functions.rst:319 +#: library/functions.rst:316 msgid "" "This function raises :exc:`SyntaxError` if the compiled source is invalid, " "and :exc:`ValueError` if the source contains null bytes." @@ -848,7 +842,7 @@ msgstr "" "Cette fonction lève une :exc:`SyntaxError` si la source n'est pas valide, " "et :exc:`ValueError` si la source contient des octets *null*." -#: library/functions.rst:322 +#: library/functions.rst:319 msgid "" "If you want to parse Python code into its AST representation, see :func:`ast." "parse`." @@ -856,7 +850,7 @@ msgstr "" "Si vous voulez transformer du code Python en sa représentation AST, voyez :" "func:`ast.parse`." -#: library/functions.rst:325 +#: library/functions.rst:322 #, fuzzy msgid "" "Raises an :ref:`auditing event ` ``compile`` with arguments " @@ -865,7 +859,7 @@ msgstr "" "Lève un :ref:`auditing event ` ``open`` avec les arguments " "``file``, ``mode``, ``flags``." -#: library/functions.rst:327 +#: library/functions.rst:324 msgid "" "Raises an :ref:`auditing event ` ``compile`` with arguments " "``source`` and ``filename``. This event may also be raised by implicit " @@ -875,7 +869,7 @@ msgstr "" "``source`` et ``filename``. Cet événement peut également être levé par une " "compilation implicite." -#: library/functions.rst:333 +#: library/functions.rst:330 msgid "" "When compiling a string with multi-line code in ``'single'`` or ``'eval'`` " "mode, input must be terminated by at least one newline character. This is " @@ -887,7 +881,7 @@ msgstr "" "moins un retour à la ligne. Cela permet de faciliter la distinction entre " "les instructions complètes et incomplètes dans le module :mod:`code`." -#: library/functions.rst:340 +#: library/functions.rst:337 msgid "" "It is possible to crash the Python interpreter with a sufficiently large/" "complex string when compiling to an AST object due to stack depth " @@ -897,7 +891,7 @@ msgstr "" "suffisamment grandes ou complexes lors de la compilation d'un objet AST. " "Ceci est dû à limitation de la profondeur de la pile d'appels." -#: library/functions.rst:344 +#: library/functions.rst:341 #, fuzzy msgid "" "Allowed use of Windows and Mac newlines. Also, input in ``'exec'`` mode " @@ -907,7 +901,7 @@ msgstr "" "la chaîne donnée à ``'exec'`` n'a plus besoin de terminer par un retour à la " "ligne. Ajout du paramètre *optimize*." -#: library/functions.rst:348 +#: library/functions.rst:345 msgid "" "Previously, :exc:`TypeError` was raised when null bytes were encountered in " "*source*." @@ -915,7 +909,7 @@ msgstr "" "Précédemment, l'exception :exc:`TypeError` était levée quand un caractère " "nul était rencontré dans *source*." -#: library/functions.rst:352 +#: library/functions.rst:349 msgid "" "``ast.PyCF_ALLOW_TOP_LEVEL_AWAIT`` can now be passed in flags to enable " "support for top-level ``await``, ``async for``, and ``async with``." @@ -924,7 +918,7 @@ msgstr "" "pour permettre une gestion de ``await``, ``async for``, et ``async with`` de " "haut niveau." -#: library/functions.rst:359 +#: library/functions.rst:356 msgid "" "Return a complex number with the value *real* + *imag*\\*1j or convert a " "string or number to a complex number. If the first parameter is a string, " @@ -945,7 +939,7 @@ msgstr "" "class:`int` ou :class:`float`. Si aucun argument n'est fourni, renvoie " "``0j``." -#: library/functions.rst:368 +#: library/functions.rst:365 msgid "" "For a general Python object ``x``, ``complex(x)`` delegates to ``x." "__complex__()``. If ``__complex__()`` is not defined then it falls back to :" @@ -957,7 +951,7 @@ msgstr "" "meth:`__float__`. Si ``__float__()`` n'est pas défini, alors il délègue à :" "meth:`__index__`." -#: library/functions.rst:375 +#: library/functions.rst:372 msgid "" "When converting from a string, the string must not contain whitespace around " "the central ``+`` or ``-`` operator. For example, ``complex('1+2j')`` is " @@ -968,17 +962,17 @@ msgstr "" "``complex('1+2j')`` est correct, mais ``complex('1 + 2j')`` lève une :exc:" "`ValueError`." -#: library/functions.rst:380 +#: library/functions.rst:377 msgid "The complex type is described in :ref:`typesnumeric`." msgstr "Le type complexe est décrit dans :ref:`typesnumeric`." -#: library/functions.rst:672 library/functions.rst:888 +#: library/functions.rst:669 library/functions.rst:885 msgid "Grouping digits with underscores as in code literals is allowed." msgstr "" "les chiffres peuvent être groupés avec des tirets bas comme dans les " "expressions littérales." -#: library/functions.rst:385 +#: library/functions.rst:382 msgid "" "Falls back to :meth:`__index__` if :meth:`__complex__` and :meth:`__float__` " "are not defined." @@ -986,7 +980,7 @@ msgstr "" "revient à :meth:`__index__` si :meth:`__complex__` et :meth:`__float__` ne " "sont pas définis." -#: library/functions.rst:392 +#: library/functions.rst:389 msgid "" "This is a relative of :func:`setattr`. The arguments are an object and a " "string. The string must be the name of one of the object's attributes. The " @@ -998,7 +992,7 @@ msgstr "" "fonction supprime l'attribut nommé, si l'objet l'y autorise. Par exemple " "``delattr(x, 'foobar')`` est l'équivalent de ``del x.foobar``." -#: library/functions.rst:404 +#: library/functions.rst:401 msgid "" "Create a new dictionary. The :class:`dict` object is the dictionary class. " "See :class:`dict` and :ref:`typesmapping` for documentation about this class." @@ -1007,7 +1001,7 @@ msgstr "" "dictionnaire. Voir :class:`dict` et :ref:`typesmapping` pour vous documenter " "sur cette classe." -#: library/functions.rst:407 +#: library/functions.rst:404 msgid "" "For other containers see the built-in :class:`list`, :class:`set`, and :" "class:`tuple` classes, as well as the :mod:`collections` module." @@ -1015,7 +1009,7 @@ msgstr "" "Pour les autres conteneurs, voir les classes natives :class:`list`, :class:" "`set`, et :class:`tuple`, ainsi que le module :mod:`collections`." -#: library/functions.rst:413 +#: library/functions.rst:410 msgid "" "Without arguments, return the list of names in the current local scope. " "With an argument, attempt to return a list of valid attributes for that " @@ -1025,7 +1019,7 @@ msgstr "" "Avec un argument, elle essaye de donner une liste d'attributs valides pour " "cet objet." -#: library/functions.rst:416 +#: library/functions.rst:413 msgid "" "If the object has a method named :meth:`__dir__`, this method will be called " "and must return the list of attributes. This allows objects that implement a " @@ -1037,7 +1031,7 @@ msgstr "" "`__getattr__` ou :func:`__getattribute__` de personnaliser ce que donnera :" "func:`dir`." -#: library/functions.rst:421 +#: library/functions.rst:418 #, fuzzy msgid "" "If the object does not provide :meth:`__dir__`, the function tries its best " @@ -1052,7 +1046,7 @@ msgstr "" "n'est pas nécessairement complète, et peut être inadaptée quand l'objet a " "un :func:`__getattr__` personnalisé." -#: library/functions.rst:426 +#: library/functions.rst:423 msgid "" "The default :func:`dir` mechanism behaves differently with different types " "of objects, as it attempts to produce the most relevant, rather than " @@ -1062,7 +1056,7 @@ msgstr "" "différents types d'objets, car elle préfère donner une information " "pertinente plutôt qu'exhaustive :" -#: library/functions.rst:430 +#: library/functions.rst:427 msgid "" "If the object is a module object, the list contains the names of the " "module's attributes." @@ -1070,7 +1064,7 @@ msgstr "" "si l'objet est un module, la liste contiendra les noms des attributs du " "module ;" -#: library/functions.rst:433 +#: library/functions.rst:430 msgid "" "If the object is a type or class object, the list contains the names of its " "attributes, and recursively of the attributes of its bases." @@ -1078,7 +1072,7 @@ msgstr "" "si l'objet est un type ou une classe, la liste contiendra les noms de ses " "attributs et, récursivement, des attributs de ses parents ;" -#: library/functions.rst:436 +#: library/functions.rst:433 msgid "" "Otherwise, the list contains the object's attributes' names, the names of " "its class's attributes, and recursively of the attributes of its class's " @@ -1088,11 +1082,11 @@ msgstr "" "attributs de la classe, et récursivement des attributs des parents de la " "classe." -#: library/functions.rst:440 +#: library/functions.rst:437 msgid "The resulting list is sorted alphabetically. For example:" msgstr "La liste donnée est triée par ordre alphabétique, par exemple :" -#: library/functions.rst:459 +#: library/functions.rst:456 msgid "" "Because :func:`dir` is supplied primarily as a convenience for use at an " "interactive prompt, it tries to supply an interesting set of names more than " @@ -1106,7 +1100,7 @@ msgstr "" "peut aussi changer d'une version à l'autre. Par exemple, les attributs de " "méta-classes ne sont pas donnés lorsque l'argument est une classe." -#: library/functions.rst:469 +#: library/functions.rst:466 #, fuzzy msgid "" "Take two (non-complex) numbers as arguments and return a pair of numbers " @@ -1127,7 +1121,7 @@ msgstr "" "b + a % b`` est très proche de *a*. Si ``a % b`` est différent de zéro, il a " "le même signe que *b*, et ``0 <= abs(a % b) < abs(b)``." -#: library/functions.rst:481 +#: library/functions.rst:478 msgid "" "Return an enumerate object. *iterable* must be a sequence, an :term:" "`iterator`, or some other object which supports iteration. The :meth:" @@ -1141,11 +1135,11 @@ msgstr "" "`enumerate` renvoie un *n*-uplet contenant un compte (démarrant à *start*, 0 " "par défaut) et les valeurs obtenues de l'itération sur *iterable*." -#: library/functions.rst:493 +#: library/functions.rst:490 msgid "Equivalent to::" msgstr "Équivalent à ::" -#: library/functions.rst:504 +#: library/functions.rst:501 msgid "" "The arguments are a string and optional globals and locals. If provided, " "*globals* must be a dictionary. If provided, *locals* can be any mapping " @@ -1155,7 +1149,7 @@ msgstr "" "globales. S'il est fourni, *globals* doit être un dictionnaire. S'il est " "fourni, *locals* peut être n'importe quel objet *mapping*." -#: library/functions.rst:508 +#: library/functions.rst:505 #, fuzzy msgid "" "The *expression* argument is parsed and evaluated as a Python expression " @@ -1186,7 +1180,7 @@ msgstr "" "`eval` est appelée. Note, *eval()* n'a pas accès aux :term:`portées " "imbriquées ` (non locales) dans l'environnement englobant." -#: library/functions.rst:523 +#: library/functions.rst:520 msgid "" "The return value is the result of the evaluated expression. Syntax errors " "are reported as exceptions. Example:" @@ -1194,7 +1188,7 @@ msgstr "" "La valeur de retour est le résultat de l'expression évaluée. Les erreurs de " "syntaxe sont signalées comme des exceptions. Exemple :" -#: library/functions.rst:530 +#: library/functions.rst:527 #, fuzzy msgid "" "This function can also be used to execute arbitrary code objects (such as " @@ -1207,7 +1201,7 @@ msgstr "" "code plutôt qu'une chaîne. Si l'objet code a été compilé avec l'argument " "*mode* à ``'exec'``, :func:`eval` donnera ``None``." -#: library/functions.rst:535 +#: library/functions.rst:532 #, fuzzy msgid "" "Hints: dynamic execution of statements is supported by the :func:`exec` " @@ -1220,13 +1214,13 @@ msgstr "" "respectivement les dictionnaires globaux et locaux, qui peuvent être utiles " "lors de l'usage de :func:`eval` et :func:`exec`." -#: library/functions.rst:540 +#: library/functions.rst:537 msgid "" "If the given source is a string, then leading and trailing spaces and tabs " "are stripped." msgstr "" -#: library/functions.rst:543 +#: library/functions.rst:540 msgid "" "See :func:`ast.literal_eval` for a function that can safely evaluate strings " "with expressions containing only literals." @@ -1235,7 +1229,7 @@ msgstr "" "peut évaluer en toute sécurité des chaînes avec des expressions ne contenant " "que des valeurs littérales." -#: library/functions.rst:582 +#: library/functions.rst:579 #, fuzzy msgid "" "Raises an :ref:`auditing event ` ``exec`` with argument " @@ -1244,7 +1238,7 @@ msgstr "" "Lève un :ref:`auditing event ` ``open`` avec les arguments " "``file``, ``mode``, ``flags``." -#: library/functions.rst:584 +#: library/functions.rst:581 msgid "" "Raises an :ref:`auditing event ` ``exec`` with the code object as " "the argument. Code compilation events may also be raised." @@ -1253,7 +1247,7 @@ msgstr "" "comme argument. Les événements de compilation de code peuvent également être " "levés." -#: library/functions.rst:555 +#: library/functions.rst:552 #, fuzzy msgid "" "This function supports dynamic execution of Python code. *object* must be " @@ -1277,7 +1271,7 @@ msgstr "" "utilisés en dehors d'une fonction, même dans du code passé à :func:`exec`. " "La fonction renvoie ``None``." -#: library/functions.rst:566 +#: library/functions.rst:563 #, fuzzy msgid "" "In all cases, if the optional parts are omitted, the code is executed in the " @@ -1300,7 +1294,7 @@ msgstr "" "``exec`` reçoit deux objets distincts dans *globals* et *locals*, le code " "est exécuté comme s'il était inclus dans une définition de classe." -#: library/functions.rst:576 +#: library/functions.rst:573 msgid "" "If the *globals* dictionary does not contain a value for the key " "``__builtins__``, a reference to the dictionary of the built-in module :mod:" @@ -1314,7 +1308,7 @@ msgstr "" "exposées au code exécuté en insérant votre propre dictionnaire " "``__builtins__`` dans *globals* avant de le donner à :func:`exec`." -#: library/functions.rst:589 +#: library/functions.rst:586 msgid "" "The built-in functions :func:`globals` and :func:`locals` return the current " "global and local dictionary, respectively, which may be useful to pass " @@ -1324,7 +1318,7 @@ msgstr "" "respectivement les dictionnaires globaux et locaux, qui peuvent être utiles " "en deuxième et troisième argument de :func:`exec`." -#: library/functions.rst:595 +#: library/functions.rst:592 msgid "" "The default *locals* act as described for function :func:`locals` below: " "modifications to the default *locals* dictionary should not be attempted. " @@ -1337,7 +1331,7 @@ msgstr "" "observer l'effet du code sur les variables locales, après que :func:`exec` " "soit terminée." -#: library/functions.rst:603 +#: library/functions.rst:600 msgid "" "Construct an iterator from those elements of *iterable* for which *function* " "returns true. *iterable* may be either a sequence, a container which " @@ -1351,7 +1345,7 @@ msgstr "" "est ``None``, la fonction identité est prise, c'est-à-dire que tous les " "éléments faux d'*iterable* sont supprimés." -#: library/functions.rst:609 +#: library/functions.rst:606 msgid "" "Note that ``filter(function, iterable)`` is equivalent to the generator " "expression ``(item for item in iterable if function(item))`` if function is " @@ -1363,7 +1357,7 @@ msgstr "" "``None``, et de ``(item for item in iterable if item)`` si *function* est " "``None``." -#: library/functions.rst:614 +#: library/functions.rst:611 msgid "" "See :func:`itertools.filterfalse` for the complementary function that " "returns elements of *iterable* for which *function* returns false." @@ -1371,12 +1365,12 @@ msgstr "" "Voir :func:`itertools.filterfalse` pour la fonction complémentaire qui donne " "les éléments d'*iterable* pour lesquels *function* renvoie ``False``." -#: library/functions.rst:624 +#: library/functions.rst:621 msgid "Return a floating point number constructed from a number or string *x*." msgstr "" "Renvoie un nombre a virgule flottante depuis un nombre ou une chaîne *x*." -#: library/functions.rst:626 +#: library/functions.rst:623 #, fuzzy msgid "" "If the argument is a string, it should contain a decimal number, optionally " @@ -1396,7 +1390,7 @@ msgstr "" "conformer à la grammaire suivante, après que les espaces en début et fin de " "chaîne aient été retirées :" -#: library/functions.rst:641 +#: library/functions.rst:638 #, fuzzy msgid "" "Here ``floatnumber`` is the form of a Python floating-point literal, " @@ -1409,7 +1403,7 @@ msgstr "" "exemple, ``\"inf\"``, ``\" Inf\"``, ``\"INFINITY\"``, et ``\" iNfiNity\"`` " "sont tous des orthographes valides pour un infini positif." -#: library/functions.rst:646 +#: library/functions.rst:643 msgid "" "Otherwise, if the argument is an integer or a floating point number, a " "floating point number with the same value (within Python's floating point " @@ -1422,7 +1416,7 @@ msgstr "" "dehors de l'intervalle d'un nombre a virgule flottante pour Python, :exc:" "`OverflowError` est levée." -#: library/functions.rst:651 +#: library/functions.rst:648 msgid "" "For a general Python object ``x``, ``float(x)`` delegates to ``x." "__float__()``. If ``__float__()`` is not defined then it falls back to :" @@ -1432,23 +1426,23 @@ msgstr "" "__float__()``. Si ``__float__()`` n'est pas défini alors il est délégué à :" "meth:`__index__`." -#: library/functions.rst:655 +#: library/functions.rst:652 msgid "If no argument is given, ``0.0`` is returned." msgstr "Sans argument, ``0.0`` est renvoyé." -#: library/functions.rst:657 +#: library/functions.rst:654 msgid "Examples::" msgstr "Exemples ::" -#: library/functions.rst:670 +#: library/functions.rst:667 msgid "The float type is described in :ref:`typesnumeric`." msgstr "Le type *float* est décrit dans :ref:`typesnumeric`." -#: library/functions.rst:678 +#: library/functions.rst:675 msgid "Falls back to :meth:`__index__` if :meth:`__float__` is not defined." msgstr "revient à :meth:`__index__` si :meth:`__float__` n'est pas défini." -#: library/functions.rst:688 +#: library/functions.rst:685 #, fuzzy msgid "" "Convert a *value* to a \"formatted\" representation, as controlled by " @@ -1461,7 +1455,7 @@ msgstr "" "valeur, cependant il existe une syntaxe standard utilisée par la plupart des " "types natifs : :ref:`formatspec`." -#: library/functions.rst:693 +#: library/functions.rst:690 msgid "" "The default *format_spec* is an empty string which usually gives the same " "effect as calling :func:`str(value) `." @@ -1469,7 +1463,7 @@ msgstr "" "Par défaut, *format_spec* est une chaîne vide. Dans ce cas, appeler cette " "fonction a généralement le même effet qu'appeler :func:`str(value) `." -#: library/functions.rst:696 +#: library/functions.rst:693 msgid "" "A call to ``format(value, format_spec)`` is translated to ``type(value)." "__format__(value, format_spec)`` which bypasses the instance dictionary when " @@ -1485,7 +1479,7 @@ msgstr "" "mod:`object` et que *format_spec* n'est pas vide, ou si *format_spec* ou le " "résultat ne sont pas des chaînes de caractères." -#: library/functions.rst:703 +#: library/functions.rst:700 msgid "" "``object().__format__(format_spec)`` raises :exc:`TypeError` if " "*format_spec* is not an empty string." @@ -1493,7 +1487,7 @@ msgstr "" "``object().__format__(format_spec)`` lève :exc:`TypeError` si *format_spec* " "n'est pas une chaîne vide." -#: library/functions.rst:712 +#: library/functions.rst:709 msgid "" "Return a new :class:`frozenset` object, optionally with elements taken from " "*iterable*. ``frozenset`` is a built-in class. See :class:`frozenset` and :" @@ -1503,7 +1497,7 @@ msgstr "" "tirés d'*iterable*. ``frozenset`` est une classe native. Voir :class:" "`frozenset` et :ref:`types-set` pour la documentation sur cette classe." -#: library/functions.rst:716 +#: library/functions.rst:713 msgid "" "For other containers see the built-in :class:`set`, :class:`list`, :class:" "`tuple`, and :class:`dict` classes, as well as the :mod:`collections` module." @@ -1512,7 +1506,7 @@ msgstr "" "`list`, :class:`tuple`, et :class:`dict`, ainsi que le module :mod:" "`collections`." -#: library/functions.rst:723 +#: library/functions.rst:720 msgid "" "Return the value of the named attribute of *object*. *name* must be a " "string. If the string is the name of one of the object's attributes, the " @@ -1528,7 +1522,7 @@ msgstr "" "que *default* est fourni, celui-ci est renvoyé. Sinon l'exception :exc:" "`AttributeError` est levée." -#: library/functions.rst:731 +#: library/functions.rst:728 msgid "" "Since :ref:`private name mangling ` happens at " "compilation time, one must manually mangle a private attribute's (attributes " @@ -1536,7 +1530,7 @@ msgid "" "`getattr`." msgstr "" -#: library/functions.rst:739 +#: library/functions.rst:736 msgid "" "Return a dictionary representing the current global symbol table. This is " "always the dictionary of the current module (inside a function or method, " @@ -1548,7 +1542,7 @@ msgstr "" "fonction ou méthode, c'est le module où elle est définie, et non le module " "d'où elle est appelée)." -#: library/functions.rst:746 +#: library/functions.rst:743 msgid "" "The arguments are an object and a string. The result is ``True`` if the " "string is the name of one of the object's attributes, ``False`` if not. " @@ -1560,7 +1554,7 @@ msgstr "" "``False`` (l'implémentation appelle ``getattr(object, name)`` et regarde si " "une exception :exc:`AttributeError` a été levée)." -#: library/functions.rst:754 +#: library/functions.rst:751 msgid "" "Return the hash value of the object (if it has one). Hash values are " "integers. They are used to quickly compare dictionary keys during a " @@ -1573,7 +1567,7 @@ msgstr "" "ont la même valeur de hachage (même si leurs types sont différents, comme " "pour ``1`` et ``1.0``)." -#: library/functions.rst:761 +#: library/functions.rst:758 msgid "" "For objects with custom :meth:`__hash__` methods, note that :func:`hash` " "truncates the return value based on the bit width of the host machine. See :" @@ -1583,7 +1577,7 @@ msgstr "" "func:`hash` tronque la valeur donnée en fonction du nombre de bits de la " "machine hôte. Voir :meth:`__hash__` pour plus d'information." -#: library/functions.rst:767 +#: library/functions.rst:764 msgid "" "Invoke the built-in help system. (This function is intended for interactive " "use.) If no argument is given, the interactive help system starts on the " @@ -1600,7 +1594,7 @@ msgstr "" "la console. Si l'argument est d'un autre type, une page d'aide sur cet objet " "est générée." -#: library/functions.rst:774 +#: library/functions.rst:771 #, fuzzy msgid "" "Note that if a slash(/) appears in the parameter list of a function when " @@ -1614,14 +1608,14 @@ msgstr "" "plus d'informations, voir :ref:`La FAQ sur les arguments positionnels `." -#: library/functions.rst:779 +#: library/functions.rst:776 msgid "" "This function is added to the built-in namespace by the :mod:`site` module." msgstr "" "Cette fonction est ajoutée à l'espace de nommage natif par le module :mod:" "`site`." -#: library/functions.rst:781 +#: library/functions.rst:778 msgid "" "Changes to :mod:`pydoc` and :mod:`inspect` mean that the reported signatures " "for callables are now more comprehensive and consistent." @@ -1629,7 +1623,7 @@ msgstr "" "les changements aux modules :mod:`pydoc` et :mod:`inspect` rendent les " "signatures des appelables plus compréhensibles et cohérentes." -#: library/functions.rst:788 +#: library/functions.rst:785 msgid "" "Convert an integer number to a lowercase hexadecimal string prefixed with " "\"0x\". If *x* is not a Python :class:`int` object, it has to define an :" @@ -1639,7 +1633,7 @@ msgstr "" "pas un :class:`int`, il doit définir une méthode :meth:`__index__` qui " "renvoie un entier. Quelques exemples :" -#: library/functions.rst:797 +#: library/functions.rst:794 msgid "" "If you want to convert an integer number to an uppercase or lower " "hexadecimal string with prefix or not, you can use either of the following " @@ -1649,7 +1643,7 @@ msgstr "" "majuscule ou non, préfixée ou non, vous pouvez utiliser l'une des méthodes " "suivantes :" -#: library/functions.rst:809 +#: library/functions.rst:806 msgid "" "See also :func:`int` for converting a hexadecimal string to an integer using " "a base of 16." @@ -1657,7 +1651,7 @@ msgstr "" "Voir aussi :func:`int` pour convertir une chaîne hexadécimale en un entier " "(en affectant 16 à l'argument *base*)." -#: library/functions.rst:814 +#: library/functions.rst:811 msgid "" "To obtain a hexadecimal string representation for a float, use the :meth:" "`float.hex` method." @@ -1665,7 +1659,7 @@ msgstr "" "Pour obtenir une représentation hexadécimale sous forme de chaîne d'un " "nombre à virgule flottante, utilisez la méthode :meth:`float.hex`." -#: library/functions.rst:820 +#: library/functions.rst:817 msgid "" "Return the \"identity\" of an object. This is an integer which is " "guaranteed to be unique and constant for this object during its lifetime. " @@ -1676,7 +1670,7 @@ msgstr "" "constant pour cet objet durant sa durée de vie. Deux objets dont les durées " "de vie ne se chevauchent pas peuvent partager le même :func:`id`." -#: library/functions.rst:827 +#: library/functions.rst:824 #, fuzzy msgid "" "Raises an :ref:`auditing event ` ``builtins.id`` with argument " @@ -1685,7 +1679,7 @@ msgstr "" "Lève un :ref:`auditing event ` ``builtins.breakpoint`` avec " "l'argument ``breakpointhook``." -#: library/functions.rst:832 +#: library/functions.rst:829 msgid "" "If the *prompt* argument is present, it is written to standard output " "without a trailing newline. The function then reads a line from input, " @@ -1697,7 +1691,7 @@ msgstr "" "standard et la convertit en chaîne (supprimant le retour à la ligne final) " "quelle renvoie. Lorsque EOF est lu, :exc:`EOFError` est levée. Exemple ::" -#: library/functions.rst:842 +#: library/functions.rst:839 msgid "" "If the :mod:`readline` module was loaded, then :func:`input` will use it to " "provide elaborate line editing and history features." @@ -1705,7 +1699,7 @@ msgstr "" "Si le module :mod:`readline` est chargé, :func:`input` l'utilisera pour " "fournir des fonctionnalités d'édition et d'historique élaborées." -#: library/functions.rst:845 +#: library/functions.rst:842 #, fuzzy msgid "" "Raises an :ref:`auditing event ` ``builtins.input`` with argument " @@ -1714,7 +1708,7 @@ msgstr "" "Lève un :ref:`auditing event ` ``builtins.input`` avec l'argument " "``prompt`` avant de lire l'entrée." -#: library/functions.rst:847 +#: library/functions.rst:844 msgid "" "Raises an :ref:`auditing event ` ``builtins.input`` with argument " "``prompt`` before reading input" @@ -1722,7 +1716,7 @@ msgstr "" "Lève un :ref:`auditing event ` ``builtins.input`` avec l'argument " "``prompt`` avant de lire l'entrée." -#: library/functions.rst:850 +#: library/functions.rst:847 #, fuzzy msgid "" "Raises an :ref:`auditing event ` ``builtins.input/result`` with " @@ -1731,7 +1725,7 @@ msgstr "" "Lève un :ref:`auditing event ` ``builtins.breakpoint`` avec " "l'argument ``breakpointhook``." -#: library/functions.rst:852 +#: library/functions.rst:849 msgid "" "Raises an auditing event ``builtins.input/result`` with the result after " "successfully reading input." @@ -1739,7 +1733,7 @@ msgstr "" "Lève un événement d'audit ``builtins.input/result`` avec le résultat après " "avoir lu avec succès l'entrée." -#: library/functions.rst:859 +#: library/functions.rst:856 msgid "" "Return an integer object constructed from a number or string *x*, or return " "``0`` if no arguments are given. If *x* defines :meth:`__int__`, ``int(x)`` " @@ -1754,7 +1748,7 @@ msgstr "" "``int(x)`` renvoie ``x.__trunc__()``. Les nombres à virgule flottante sont " "tronqués vers zéro." -#: library/functions.rst:866 +#: library/functions.rst:863 msgid "" "If *x* is not a number or if *base* is given, then *x* must be a string, :" "class:`bytes`, or :class:`bytearray` instance representing an :ref:`integer " @@ -1783,11 +1777,11 @@ msgstr "" "0)`` n'est pas légal, alors que ``int('010')`` l'est tout comme ``int('010', " "8)``." -#: library/functions.rst:879 +#: library/functions.rst:876 msgid "The integer type is described in :ref:`typesnumeric`." msgstr "Le type des entiers est décrit dans :ref:`typesnumeric`." -#: library/functions.rst:881 +#: library/functions.rst:878 msgid "" "If *base* is not an instance of :class:`int` and the *base* object has a :" "meth:`base.__index__ ` method, that method is called to " @@ -1800,11 +1794,11 @@ msgstr "" "meth:`base.__int__ ` au lieu de :meth:`base.__index__ " "`." -#: library/functions.rst:894 +#: library/functions.rst:891 msgid "Falls back to :meth:`__index__` if :meth:`__int__` is not defined." msgstr "revient à :meth:`__index__` si :meth:`__int__` n'est pas défini." -#: library/functions.rst:900 +#: library/functions.rst:897 #, fuzzy msgid "" "Return ``True`` if the *object* argument is an instance of the *classinfo* " @@ -1825,11 +1819,11 @@ msgstr "" "un *n*-uplet de types (et récursivement), une exception :exc:`TypeError` est " "levée." -#: library/functions.rst:923 +#: library/functions.rst:920 msgid "*classinfo* can be a :ref:`types-union`." msgstr "" -#: library/functions.rst:916 +#: library/functions.rst:913 #, fuzzy msgid "" "Return ``True`` if *class* is a subclass (direct, indirect, or :term:" @@ -1845,13 +1839,14 @@ msgstr "" "classes, dans ce cas la vérification sera faite pour chaque classe de " "*classinfo*. Dans tous les autres cas, :exc:`TypeError` est levée." -#: library/functions.rst:929 +#: library/functions.rst:926 +#, fuzzy msgid "" "Return an :term:`iterator` object. The first argument is interpreted very " "differently depending on the presence of the second argument. Without a " -"second argument, *object* must be a collection object which supports the " -"iteration protocol (the :meth:`__iter__` method), or it must support the " -"sequence protocol (the :meth:`__getitem__` method with integer arguments " +"second argument, *object* must be a collection object which supports the :" +"term:`iterable` protocol (the :meth:`__iter__` method), or it must support " +"the sequence protocol (the :meth:`__getitem__` method with integer arguments " "starting at ``0``). If it does not support either of those protocols, :exc:" "`TypeError` is raised. If the second argument, *sentinel*, is given, then " "*object* must be a callable object. The iterator created in this case will " @@ -1870,11 +1865,11 @@ msgstr "" "de :meth:`~iterator.__next__`. Si la valeur reçue est égale à *sentinel* :" "exc:`StopIteration` est levée, sinon la valeur est renvoyée." -#: library/functions.rst:942 +#: library/functions.rst:939 msgid "See also :ref:`typeiter`." msgstr "Voir aussi :ref:`typeiter`." -#: library/functions.rst:944 +#: library/functions.rst:941 msgid "" "One useful application of the second form of :func:`iter` is to build a " "block-reader. For example, reading fixed-width blocks from a binary database " @@ -1884,7 +1879,7 @@ msgstr "" "construire un lecteur par blocs. Par exemple, lire des blocs de taille fixe " "d'une base de donnée binaire jusqu'à ce que la fin soit atteinte ::" -#: library/functions.rst:956 +#: library/functions.rst:953 msgid "" "Return the length (the number of items) of an object. The argument may be a " "sequence (such as a string, bytes, tuple, list, or range) or a collection " @@ -1895,13 +1890,13 @@ msgstr "" "liste ou un intervalle) ou une collection (telle qu'un dictionnaire, un " "ensemble ou un ensemble figé)." -#: library/functions.rst:962 +#: library/functions.rst:959 msgid "" "``len`` raises :exc:`OverflowError` on lengths larger than :data:`sys." "maxsize`, such as :class:`range(2 ** 100) `." msgstr "" -#: library/functions.rst:970 +#: library/functions.rst:967 msgid "" "Rather than being a function, :class:`list` is actually a mutable sequence " "type, as documented in :ref:`typesseq-list` and :ref:`typesseq`." @@ -1910,7 +1905,7 @@ msgstr "" "type séquentiel muable, comme décrit dans :ref:`typesseq-list` et :ref:" "`typesseq`." -#: library/functions.rst:976 +#: library/functions.rst:973 msgid "" "Update and return a dictionary representing the current local symbol table. " "Free variables are returned by :func:`locals` when it is called in function " @@ -1923,7 +1918,7 @@ msgstr "" "corps d'une classe. Notez qu’au niveau d’un module, :func:`locals` et :func:" "`globals` sont le même dictionnaire." -#: library/functions.rst:982 +#: library/functions.rst:979 msgid "" "The contents of this dictionary should not be modified; changes may not " "affect the values of local and free variables used by the interpreter." @@ -1932,7 +1927,7 @@ msgstr "" "n'affectent pas les valeurs des variables locales ou libres utilisées par " "l'interpréteur." -#: library/functions.rst:987 +#: library/functions.rst:984 msgid "" "Return an iterator that applies *function* to every item of *iterable*, " "yielding the results. If additional *iterable* arguments are passed, " @@ -1949,7 +1944,7 @@ msgstr "" "où les arguments sont déjà rangés sous forme de *n*-uplets, voir :func:" "`itertools.starmap`." -#: library/functions.rst:998 +#: library/functions.rst:995 msgid "" "Return the largest item in an iterable or the largest of two or more " "arguments." @@ -1957,7 +1952,7 @@ msgstr "" "Renvoie le plus grand élément d'un itérable, ou l'argument le plus grand " "parmi au moins deux arguments." -#: library/functions.rst:1001 +#: library/functions.rst:998 msgid "" "If one positional argument is provided, it should be an :term:`iterable`. " "The largest item in the iterable is returned. If two or more positional " @@ -1968,7 +1963,7 @@ msgstr "" "deux arguments positionnels sont fournis, l'argument le plus grand sera " "renvoyé." -#: library/functions.rst:1043 +#: library/functions.rst:1040 msgid "" "There are two optional keyword-only arguments. The *key* argument specifies " "a one-argument ordering function like that used for :meth:`list.sort`. The " @@ -1982,7 +1977,7 @@ msgstr "" "fourni est vide. Si l'itérable est vide et que *default* n'est pas fourni, :" "exc:`ValueError` est levée." -#: library/functions.rst:1012 +#: library/functions.rst:1009 msgid "" "If multiple items are maximal, the function returns the first one " "encountered. This is consistent with other sort-stability preserving tools " @@ -1994,15 +1989,15 @@ msgstr "" "stabilité lors du tri, tels que ``sorted(iterable, key=keyfunc, reverse=True)" "[0]`` et ``heapq.nlargest(1, iterable, key=keyfunc)``." -#: library/functions.rst:1054 +#: library/functions.rst:1051 msgid "The *default* keyword-only argument." msgstr "L'argument nommé (et seulement donné par son nom) *default*." -#: library/functions.rst:1057 +#: library/functions.rst:1054 msgid "The *key* can be ``None``." msgstr "l'argument *key* peut être ``None``." -#: library/functions.rst:1028 +#: library/functions.rst:1025 msgid "" "Return a \"memory view\" object created from the given argument. See :ref:" "`typememoryview` for more information." @@ -2010,7 +2005,7 @@ msgstr "" "Renvoie une « vue mémoire » (*memory view*) créée depuis l'argument. Voir :" "ref:`typememoryview` pour plus d'informations." -#: library/functions.rst:1035 +#: library/functions.rst:1032 msgid "" "Return the smallest item in an iterable or the smallest of two or more " "arguments." @@ -2018,7 +2013,7 @@ msgstr "" "Renvoie le plus petit élément d'un itérable ou le plus petit d'au moins deux " "arguments." -#: library/functions.rst:1038 +#: library/functions.rst:1035 msgid "" "If one positional argument is provided, it should be an :term:`iterable`. " "The smallest item in the iterable is returned. If two or more positional " @@ -2028,7 +2023,7 @@ msgstr "" "plus petit élément de l'itérable est renvoyé. Si au moins deux arguments " "positionnels sont fournis, le plus petit argument positionnel est renvoyé." -#: library/functions.rst:1049 +#: library/functions.rst:1046 msgid "" "If multiple items are minimal, the function returns the first one " "encountered. This is consistent with other sort-stability preserving tools " @@ -2040,17 +2035,18 @@ msgstr "" "du tri, tels que ``sorted(iterable, key=keyfunc)[0]`` et ``heapq." "nsmallest(1, iterable, key=keyfunc)``." -#: library/functions.rst:1063 +#: library/functions.rst:1060 +#, fuzzy msgid "" -"Retrieve the next item from the *iterator* by calling its :meth:`~iterator." -"__next__` method. If *default* is given, it is returned if the iterator is " -"exhausted, otherwise :exc:`StopIteration` is raised." +"Retrieve the next item from the :term:`iterator` by calling its :meth:" +"`~iterator.__next__` method. If *default* is given, it is returned if the " +"iterator is exhausted, otherwise :exc:`StopIteration` is raised." msgstr "" "Donne l'élément suivant d'*iterator* en appelant sa méthode :meth:`~iterator." "__next__`. Si *default* est fourni, il sera renvoyé si l'itérateur est " "épuisé, sinon :exc:`StopIteration` est levée." -#: library/functions.rst:1070 +#: library/functions.rst:1067 #, fuzzy msgid "" "Return a new featureless object. :class:`object` is a base for all classes. " @@ -2061,7 +2057,7 @@ msgstr "" "classes. C'est elle qui porte les méthodes communes à toutes les instances " "de classes en Python. Cette fonction n'accepte aucun argument." -#: library/functions.rst:1076 +#: library/functions.rst:1073 msgid "" ":class:`object` does *not* have a :attr:`~object.__dict__`, so you can't " "assign arbitrary attributes to an instance of the :class:`object` class." @@ -2070,7 +2066,7 @@ msgstr "" "pouvez donc pas assigner d'attributs arbitraires à une instance d':class:" "`object`." -#: library/functions.rst:1082 +#: library/functions.rst:1079 msgid "" "Convert an integer number to an octal string prefixed with \"0o\". The " "result is a valid Python expression. If *x* is not a Python :class:`int` " @@ -2082,7 +2078,7 @@ msgstr "" "objet :class:`int`, il doit définir une méthode :meth:`__index__` qui donne " "un entier, par exemple :" -#: library/functions.rst:1092 +#: library/functions.rst:1089 #, fuzzy msgid "" "If you want to convert an integer number to an octal string either with the " @@ -2091,7 +2087,7 @@ msgstr "" "Si vous voulez convertir un nombre entier en chaîne octale, avec ou sans le " "préfixe ``0o``, vous pouvez utiliser l'une des méthodes suivantes." -#: library/functions.rst:1109 +#: library/functions.rst:1106 msgid "" "Open *file* and return a corresponding :term:`file object`. If the file " "cannot be opened, an :exc:`OSError` is raised. See :ref:`tut-files` for more " @@ -2101,7 +2097,7 @@ msgstr "" "Si le fichier ne peut pas être ouvert, une :exc:`OSError` est levée. Voir :" "ref:`tut-files` pour plus d'exemple d'utilisation de cette fonction." -#: library/functions.rst:1113 +#: library/functions.rst:1110 #, fuzzy msgid "" "*file* is a :term:`path-like object` giving the pathname (absolute or " @@ -2116,7 +2112,7 @@ msgstr "" "descripteur de fichier est donné, il sera fermé en même temps que l'objet " "d'entrée-sortie renvoyé, sauf si *closefd* est mis à ``False``)." -#: library/functions.rst:1119 +#: library/functions.rst:1116 #, fuzzy msgid "" "*mode* is an optional string that specifies the mode in which the file is " @@ -2144,72 +2140,72 @@ msgstr "" "mode binaire sans préciser *encoding* non spécifié). Les modes disponibles " "sont :" -#: library/functions.rst:1136 +#: library/functions.rst:1133 msgid "Character" msgstr "Caractère" -#: library/functions.rst:1136 +#: library/functions.rst:1133 msgid "Meaning" msgstr "Signification" -#: library/functions.rst:1138 +#: library/functions.rst:1135 msgid "``'r'``" msgstr "``'r'``" -#: library/functions.rst:1138 +#: library/functions.rst:1135 msgid "open for reading (default)" msgstr "ouvre en lecture (par défaut)" -#: library/functions.rst:1139 +#: library/functions.rst:1136 msgid "``'w'``" msgstr "``'w'``" -#: library/functions.rst:1139 +#: library/functions.rst:1136 msgid "open for writing, truncating the file first" msgstr "ouvre en écriture, en effaçant le contenu du fichier" -#: library/functions.rst:1140 +#: library/functions.rst:1137 msgid "``'x'``" msgstr "``'x'``" -#: library/functions.rst:1140 +#: library/functions.rst:1137 msgid "open for exclusive creation, failing if the file already exists" msgstr "ouvre pour une création exclusive, échouant si le fichier existe déjà" -#: library/functions.rst:1141 +#: library/functions.rst:1138 msgid "``'a'``" msgstr "``'a'``" -#: library/functions.rst:1141 +#: library/functions.rst:1138 #, fuzzy msgid "open for writing, appending to the end of file if it exists" msgstr "ouvre en écriture, ajoutant à la fin du fichier s'il existe" -#: library/functions.rst:1142 +#: library/functions.rst:1139 msgid "``'b'``" msgstr "``'b'``" -#: library/functions.rst:1142 +#: library/functions.rst:1139 msgid "binary mode" msgstr "mode binaire" -#: library/functions.rst:1143 +#: library/functions.rst:1140 msgid "``'t'``" msgstr "``'t'``" -#: library/functions.rst:1143 +#: library/functions.rst:1140 msgid "text mode (default)" msgstr "mode texte (par défaut)" -#: library/functions.rst:1144 +#: library/functions.rst:1141 msgid "``'+'``" msgstr "``'+'``" -#: library/functions.rst:1144 +#: library/functions.rst:1141 msgid "open for updating (reading and writing)" msgstr "ouvre en modification (lecture et écriture)" -#: library/functions.rst:1147 +#: library/functions.rst:1144 #, fuzzy msgid "" "The default mode is ``'r'`` (open for reading text, a synonym of ``'rt'``). " @@ -2220,7 +2216,7 @@ msgstr "" "``'rt'``). Les modes ``'w+'`` et ``'w+b'`` ouvrent et vident le fichier. Les " "modes ``'r+'`` et ``'r+b'`` ouvrent le fichier sans le vider." -#: library/functions.rst:1151 +#: library/functions.rst:1148 msgid "" "As mentioned in the :ref:`io-overview`, Python distinguishes between binary " "and text I/O. Files opened in binary mode (including ``'b'`` in the *mode* " @@ -2238,7 +2234,7 @@ msgstr "" "octets ayant été décodés au préalable en utilisant un encodage déduit de " "l'environnement ou *encoding* s'il est donné." -#: library/functions.rst:1159 +#: library/functions.rst:1156 #, fuzzy msgid "" "There is an additional mode character permitted, ``'U'``, which no longer " @@ -2254,7 +2250,7 @@ msgstr "" "documentation du paramètre :ref:`newline ` pour plus " "de détails." -#: library/functions.rst:1167 +#: library/functions.rst:1164 msgid "" "Python doesn't depend on the underlying operating system's notion of text " "files; all the processing is done by Python itself, and is therefore " @@ -2264,7 +2260,7 @@ msgstr "" "jacent. Tout le traitement est effectué par Python lui-même, et est ainsi " "indépendant de la plate-forme." -#: library/functions.rst:1171 +#: library/functions.rst:1168 msgid "" "*buffering* is an optional integer used to set the buffering policy. Pass 0 " "to switch buffering off (only allowed in binary mode), 1 to select line " @@ -2279,7 +2275,7 @@ msgstr "" "en octets d'un tampon de taille fixe. Sans l'argument *buffering*, les " "comportements par défaut sont les suivants :" -#: library/functions.rst:1177 +#: library/functions.rst:1174 msgid "" "Binary files are buffered in fixed-size chunks; the size of the buffer is " "chosen using a heuristic trying to determine the underlying device's \"block " @@ -2292,7 +2288,7 @@ msgstr "" "DEFAULT_BUFFER_SIZE`. Sur de nombreux systèmes, le tampon sera de 4096 ou " "8192 octets." -#: library/functions.rst:1182 +#: library/functions.rst:1179 msgid "" "\"Interactive\" text files (files for which :meth:`~io.IOBase.isatty` " "returns ``True``) use line buffering. Other text files use the policy " @@ -2302,7 +2298,7 @@ msgstr "" "isatty` renvoie ``True``) utilisent un tampon par lignes. Les autres " "fichiers texte sont traités comme les fichiers binaires." -#: library/functions.rst:1186 +#: library/functions.rst:1183 msgid "" "*encoding* is the name of the encoding used to decode or encode the file. " "This should only be used in text mode. The default encoding is platform " @@ -2317,7 +2313,7 @@ msgstr "" "par Python peut être utilisé. Voir :mod:`codecs` pour une liste des " "encodages pris en charge." -#: library/functions.rst:1193 +#: library/functions.rst:1190 msgid "" "*errors* is an optional string that specifies how encoding and decoding " "errors are to be handled—this cannot be used in binary mode. A variety of " @@ -2332,7 +2328,7 @@ msgstr "" "d'erreur enregistré avec :func:`codecs.register_error` est aussi un argument " "valide. Les noms standards sont :" -#: library/functions.rst:1201 +#: library/functions.rst:1198 msgid "" "``'strict'`` to raise a :exc:`ValueError` exception if there is an encoding " "error. The default value of ``None`` has the same effect." @@ -2340,7 +2336,7 @@ msgstr "" "``'strict'`` pour lever une :exc:`ValueError` si une erreur d'encodage est " "rencontrée. La valeur par défaut, ``None``, a le même effet." -#: library/functions.rst:1205 +#: library/functions.rst:1202 msgid "" "``'ignore'`` ignores errors. Note that ignoring encoding errors can lead to " "data loss." @@ -2348,7 +2344,7 @@ msgstr "" "``'ignore'`` ignore les erreurs. Notez qu'ignorer les erreurs d'encodage " "peut mener à des pertes de données." -#: library/functions.rst:1208 +#: library/functions.rst:1205 msgid "" "``'replace'`` causes a replacement marker (such as ``'?'``) to be inserted " "where there is malformed data." @@ -2356,7 +2352,7 @@ msgstr "" "``'replace'`` insère un marqueur de substitution (tel que ``'?'``) en place " "des données mal formées." -#: library/functions.rst:1211 +#: library/functions.rst:1208 #, fuzzy msgid "" "``'surrogateescape'`` will represent any incorrect bytes as low surrogate " @@ -2372,7 +2368,7 @@ msgstr "" "l'écriture de la donnée. C'est utile pour traiter des fichiers d'un encodage " "inconnu." -#: library/functions.rst:1218 +#: library/functions.rst:1215 msgid "" "``'xmlcharrefreplace'`` is only supported when writing to a file. Characters " "not supported by the encoding are replaced with the appropriate XML " @@ -2382,7 +2378,7 @@ msgstr "" "fichier. Les caractères non gérés par l'encodage sont remplacés par une " "entité XML de la forme ``&#nnn;``." -#: library/functions.rst:1222 +#: library/functions.rst:1219 msgid "" "``'backslashreplace'`` replaces malformed data by Python's backslashed " "escape sequences." @@ -2390,7 +2386,7 @@ msgstr "" "``'backslashreplace'`` remplace les données mal formées par des séquences " "d'échappement Python (utilisant des barres obliques inverses)." -#: library/functions.rst:1225 +#: library/functions.rst:1222 msgid "" "``'namereplace'`` (also only supported when writing) replaces unsupported " "characters with ``\\N{...}`` escape sequences." @@ -2398,7 +2394,7 @@ msgstr "" "``'namereplace'`` (aussi supporté lors de l'écriture) remplace les " "caractères non gérés par des séquences d'échappement ``\\N{...}``." -#: library/functions.rst:1233 +#: library/functions.rst:1230 msgid "" "*newline* controls how :term:`universal newlines` mode works (it only " "applies to text mode). It can be ``None``, ``''``, ``'\\n'``, ``'\\r'``, " @@ -2409,7 +2405,7 @@ msgstr "" "``None``, ``''``, ``'\\n'``, ``'\\r'``, et ``'\\r\\n'``. Il fonctionne comme " "suit :" -#: library/functions.rst:1237 +#: library/functions.rst:1234 msgid "" "When reading input from the stream, if *newline* is ``None``, universal " "newlines mode is enabled. Lines in the input can end in ``'\\n'``, " @@ -2427,7 +2423,7 @@ msgstr "" "valeur autorisée, les lignes sont seulement terminées par la chaîne donnée, " "qui est rendue telle quelle." -#: library/functions.rst:1245 +#: library/functions.rst:1242 msgid "" "When writing output to the stream, if *newline* is ``None``, any ``'\\n'`` " "characters written are translated to the system default line separator, :" @@ -2441,7 +2437,7 @@ msgstr "" "*newline* est un autre caractère valide, chaque ``'\\n'`` sera remplacé par " "la chaîne donnée." -#: library/functions.rst:1251 +#: library/functions.rst:1248 #, fuzzy msgid "" "If *closefd* is ``False`` and a file descriptor rather than a filename was " @@ -2454,7 +2450,7 @@ msgstr "" "le fichier sera fermé. Si un nom de fichier est donné, *closefd* doit rester " "``True`` (la valeur par défaut) sans quoi une erreur est levée." -#: library/functions.rst:1256 +#: library/functions.rst:1253 msgid "" "A custom opener can be used by passing a callable as *opener*. The " "underlying file descriptor for the file object is then obtained by calling " @@ -2468,13 +2464,13 @@ msgstr "" "descripteur de fichier ouvert (fournir :mod:`os.open` en tant qu'*opener* " "aura le même effet que donner ``None``)." -#: library/functions.rst:1262 +#: library/functions.rst:1259 msgid "The newly created file is :ref:`non-inheritable `." msgstr "" "Il n'est :ref:`pas possible d'hériter du fichier ` " "nouvellement créé." -#: library/functions.rst:1264 +#: library/functions.rst:1261 msgid "" "The following example uses the :ref:`dir_fd ` parameter of the :func:" "`os.open` function to open a file relative to a given directory::" @@ -2482,7 +2478,7 @@ msgstr "" "L'exemple suivant utilise le paramètre :ref:`dir_fd ` de la " "fonction :func:`os.open` pour ouvrir un fichier relatif au dossier courant ::" -#: library/functions.rst:1277 +#: library/functions.rst:1274 msgid "" "The type of :term:`file object` returned by the :func:`open` function " "depends on the mode. When :func:`open` is used to open a file in a text " @@ -2508,7 +2504,7 @@ msgstr "" "BufferedRandom`. Lorsque le tampon est désactivé, le flux brut, une classe " "fille de :class:`io.RawIOBase`, :class:`io.FileIO` est renvoyée." -#: library/functions.rst:1298 +#: library/functions.rst:1295 #, fuzzy msgid "" "See also the file handling modules, such as :mod:`fileinput`, :mod:`io` " @@ -2519,7 +2515,7 @@ msgstr "" "`fileinput`, :mod:`io` (où :func:`open` est déclarée), :mod:`os`, :mod:`os." "path`, :mod:`tmpfile`, et :mod:`shutil`." -#: library/functions.rst:1302 +#: library/functions.rst:1299 msgid "" "Raises an :ref:`auditing event ` ``open`` with arguments ``file``, " "``mode``, ``flags``." @@ -2527,7 +2523,7 @@ msgstr "" "Lève un :ref:`auditing event ` ``open`` avec les arguments " "``file``, ``mode``, ``flags``." -#: library/functions.rst:1304 +#: library/functions.rst:1301 msgid "" "The ``mode`` and ``flags`` arguments may have been modified or inferred from " "the original call." @@ -2535,21 +2531,21 @@ msgstr "" "Les arguments ``mode`` et ``flags`` peuvent avoir été modifiés ou déduits de " "l'appel original." -#: library/functions.rst:1310 +#: library/functions.rst:1307 msgid "The *opener* parameter was added." msgstr "ajout du paramètre *opener*." -#: library/functions.rst:1311 +#: library/functions.rst:1308 msgid "The ``'x'`` mode was added." msgstr "ajout du mode ``'x'``." -#: library/functions.rst:1312 +#: library/functions.rst:1309 msgid ":exc:`IOError` used to be raised, it is now an alias of :exc:`OSError`." msgstr "" ":exc:`IOError` était normalement levée, elle est maintenant un alias de :exc:" "`OSError`." -#: library/functions.rst:1313 +#: library/functions.rst:1310 msgid "" ":exc:`FileExistsError` is now raised if the file opened in exclusive " "creation mode (``'x'``) already exists." @@ -2557,15 +2553,15 @@ msgstr "" ":exc:`FileExistsError` est maintenant levée si le fichier ouvert en mode " "création exclusive (``'x'``) existe déjà." -#: library/functions.rst:1319 +#: library/functions.rst:1316 msgid "The file is now non-inheritable." msgstr "Il n'est plus possible d'hériter de *file*." -#: library/functions.rst:1323 +#: library/functions.rst:1320 msgid "The ``'U'`` mode." msgstr "Le mode ``'U'``." -#: library/functions.rst:1328 +#: library/functions.rst:1325 msgid "" "If the system call is interrupted and the signal handler does not raise an " "exception, the function now retries the system call instead of raising an :" @@ -2575,15 +2571,15 @@ msgstr "" "aucune exception, la fonction réessaye l'appel système au lieu de lever une :" "exc:`InterruptedError` (voir la :pep:`475` pour la justification)." -#: library/functions.rst:1331 +#: library/functions.rst:1328 msgid "The ``'namereplace'`` error handler was added." msgstr "ajout du gestionnaire d'erreurs ``'namereplace'``." -#: library/functions.rst:1336 +#: library/functions.rst:1333 msgid "Support added to accept objects implementing :class:`os.PathLike`." msgstr "prise en charge des objets implémentant :class:`os.PathLike`." -#: library/functions.rst:1337 +#: library/functions.rst:1334 msgid "" "On Windows, opening a console buffer may return a subclass of :class:`io." "RawIOBase` other than :class:`io.FileIO`." @@ -2591,7 +2587,7 @@ msgstr "" "Sous Windows, ouvrir un *buffer* du terminal peut renvoyer une sous-classe " "de :class:`io.RawIOBase` autre que :class:`io.FileIO`." -#: library/functions.rst:1342 +#: library/functions.rst:1339 msgid "" "Given a string representing one Unicode character, return an integer " "representing the Unicode code point of that character. For example, " @@ -2603,7 +2599,7 @@ msgstr "" "entier ``97`` et ``ord('€')`` (symbole euro) renvoie ``8364``. Il s'agit de " "l'inverse de :func:`chr`." -#: library/functions.rst:1350 +#: library/functions.rst:1347 msgid "" "Return *base* to the power *exp*; if *mod* is present, return *base* to the " "power *exp*, modulo *mod* (computed more efficiently than ``pow(base, exp) % " @@ -2615,7 +2611,7 @@ msgstr "" "``pow(base, exp) % mod``). La forme à deux arguments ``pow(base, exp)`` est " "équivalente à l'opérateur puissance : ``base**exp``." -#: library/functions.rst:1355 +#: library/functions.rst:1352 #, fuzzy msgid "" "The arguments must have numeric types. With mixed operand types, the " @@ -2636,7 +2632,7 @@ msgstr "" "convertis en ``float``, et le résultat sera un ``float`` aussi. Par exemple, " "``10**2`` donne ``100``, alors que ``10**-2`` donne ``0.01``." -#: library/functions.rst:1365 +#: library/functions.rst:1362 msgid "" "For :class:`int` operands *base* and *exp*, if *mod* is present, *mod* must " "also be of integer type and *mod* must be nonzero. If *mod* is present and " @@ -2650,11 +2646,11 @@ msgstr "" "être premiers entre eux. Dans ce cas, ``pow(inv_base, -exp, mod)`` est " "renvoyé, où *inv_base* est un inverse de *base* modulo *mod*." -#: library/functions.rst:1371 +#: library/functions.rst:1368 msgid "Here's an example of computing an inverse for ``38`` modulo ``97``::" msgstr "Voici un exemple de calcul d'un inverse de ``38`` modulo ``97`` ::" -#: library/functions.rst:1378 +#: library/functions.rst:1375 msgid "" "For :class:`int` operands, the three-argument form of ``pow`` now allows the " "second argument to be negative, permitting computation of modular inverses." @@ -2663,14 +2659,14 @@ msgstr "" "permet maintenant au deuxième argument d'être négatif, permettant le calcul " "des inverses modulaires." -#: library/functions.rst:1383 +#: library/functions.rst:1380 msgid "" "Allow keyword arguments. Formerly, only positional arguments were supported." msgstr "" "Autorise les arguments par mots-clés. Auparavant, seuls les arguments " "positionnels étaient autorisés." -#: library/functions.rst:1390 +#: library/functions.rst:1387 #, fuzzy msgid "" "Print *objects* to the text stream *file*, separated by *sep* and followed " @@ -2681,7 +2677,7 @@ msgstr "" "*end*. Les arguments *sep*, *end*, *file*, et *flush*, s'ils sont présents, " "doivent être nommés." -#: library/functions.rst:1394 +#: library/functions.rst:1391 msgid "" "All non-keyword arguments are converted to strings like :func:`str` does and " "written to the stream, separated by *sep* and followed by *end*. Both *sep* " @@ -2695,7 +2691,7 @@ msgstr "" "les valeurs par défaut. Si aucun *objects* n'est donné :func:`print` écris " "seulement *end*." -#: library/functions.rst:1400 +#: library/functions.rst:1397 msgid "" "The *file* argument must be an object with a ``write(string)`` method; if it " "is not present or ``None``, :data:`sys.stdout` will be used. Since printed " @@ -2708,7 +2704,7 @@ msgstr "" "peut pas être utilisé avec des fichiers ouverts en mode binaire. Pour ceux-" "ci utilisez plutôt ``file.write(...)``." -#: library/functions.rst:1405 +#: library/functions.rst:1402 #, fuzzy msgid "" "Whether the output is buffered is usually determined by *file*, but if the " @@ -2717,15 +2713,15 @@ msgstr "" "Que la sortie utilise un *buffer* ou non est souvent décidé par *file*, mais " "si l'argument *flush* est vrai, le tampon du flux est vidé explicitement." -#: library/functions.rst:1408 +#: library/functions.rst:1405 msgid "Added the *flush* keyword argument." msgstr "ajout de l'argument nommé *flush*." -#: library/functions.rst:1414 +#: library/functions.rst:1411 msgid "Return a property attribute." msgstr "Renvoie un attribut propriété." -#: library/functions.rst:1416 +#: library/functions.rst:1413 msgid "" "*fget* is a function for getting an attribute value. *fset* is a function " "for setting an attribute value. *fdel* is a function for deleting an " @@ -2736,11 +2732,11 @@ msgstr "" "supprimer la valeur d'un attribut, et *doc* créé une *docstring* pour " "l'attribut." -#: library/functions.rst:1420 +#: library/functions.rst:1417 msgid "A typical use is to define a managed attribute ``x``::" msgstr "Une utilisation courante : définir un attribut managé ``x`` ::" -#: library/functions.rst:1437 +#: library/functions.rst:1434 #, fuzzy msgid "" "If *c* is an instance of *C*, ``c.x`` will invoke the getter, ``c.x = " @@ -2750,7 +2746,7 @@ msgstr "" "anglais), ``c.x = value`` invoque le mutateur (*setter*), et ``del x`` le " "destructeur (*deleter*)." -#: library/functions.rst:1440 +#: library/functions.rst:1437 msgid "" "If given, *doc* will be the docstring of the property attribute. Otherwise, " "the property will copy *fget*'s docstring (if it exists). This makes it " @@ -2762,7 +2758,7 @@ msgstr "" "création de propriétés en lecture seule en utilisant simplement :func:" "`property` comme un :term:`décorateur ` ::" -#: library/functions.rst:1453 +#: library/functions.rst:1450 msgid "" "The ``@property`` decorator turns the :meth:`voltage` method into a \"getter" "\" for a read-only attribute with the same name, and it sets the docstring " @@ -2772,7 +2768,7 @@ msgstr "" "*getter* d'un attribut du même nom, et donne *\"Get the current voltage\"* " "comme *docstring* de *voltage*." -#: library/functions.rst:1457 +#: library/functions.rst:1454 msgid "" "A property object has :attr:`~property.getter`, :attr:`~property.setter`, " "and :attr:`~property.deleter` methods usable as decorators that create a " @@ -2784,7 +2780,7 @@ msgstr "" "une copie de la propriété avec les accesseurs correspondants définis par la " "fonction de décoration. C'est plus clair avec un exemple ::" -#: library/functions.rst:1479 +#: library/functions.rst:1476 msgid "" "This code is exactly equivalent to the first example. Be sure to give the " "additional functions the same name as the original property (``x`` in this " @@ -2794,7 +2790,7 @@ msgstr "" "donner aux fonctions additionnelles le même nom que la propriété (``x`` dans " "ce cas)." -#: library/functions.rst:1483 +#: library/functions.rst:1480 msgid "" "The returned property object also has the attributes ``fget``, ``fset``, and " "``fdel`` corresponding to the constructor arguments." @@ -2802,11 +2798,11 @@ msgstr "" "L'objet propriété renvoyé à aussi les attributs ``fget``, ``fset`` et " "``fdel`` correspondants aux arguments du constructeur." -#: library/functions.rst:1486 +#: library/functions.rst:1483 msgid "The docstrings of property objects are now writeable." msgstr "Les *docstrings* des objets propriété peuvent maintenant être écrits." -#: library/functions.rst:1495 +#: library/functions.rst:1492 msgid "" "Rather than being a function, :class:`range` is actually an immutable " "sequence type, as documented in :ref:`typesseq-range` and :ref:`typesseq`." @@ -2815,7 +2811,7 @@ msgstr "" "type de séquence immuable, comme décrit dans :ref:`typesseq-range` et :ref:" "`typesseq`." -#: library/functions.rst:1501 +#: library/functions.rst:1498 #, fuzzy msgid "" "Return a string containing a printable representation of an object. For " @@ -2834,7 +2830,7 @@ msgstr "" "l'adresse de l'objet. Une classe peut contrôler ce que cette fonction " "renvoie pour ses instances en définissant une méthode :meth:`__repr__`." -#: library/functions.rst:1512 +#: library/functions.rst:1509 msgid "" "Return a reverse :term:`iterator`. *seq* must be an object which has a :" "meth:`__reversed__` method or supports the sequence protocol (the :meth:" @@ -2846,7 +2842,7 @@ msgstr "" "séquence (la méthode :meth:`__len__` et la méthode :meth:`__getitem__` avec " "des arguments entiers commençant à zéro)." -#: library/functions.rst:1520 +#: library/functions.rst:1517 msgid "" "Return *number* rounded to *ndigits* precision after the decimal point. If " "*ndigits* is omitted or is ``None``, it returns the nearest integer to its " @@ -2856,7 +2852,7 @@ msgstr "" "virgule. Si *ndigits* est omis (ou est ``None``), l'entier le plus proche " "est renvoyé." -#: library/functions.rst:1524 +#: library/functions.rst:1521 #, fuzzy msgid "" "For the built-in types supporting :func:`round`, values are rounded to the " @@ -2875,7 +2871,7 @@ msgstr "" "zéro, ou négatif). La valeur renvoyée est un entier si *ndigits* n'est pas " "donné, (ou est ``None``). Sinon elle est du même type que *number*." -#: library/functions.rst:1533 +#: library/functions.rst:1530 msgid "" "For a general Python object ``number``, ``round`` delegates to ``number." "__round__``." @@ -2883,7 +2879,7 @@ msgstr "" "Pour tout autre objet Python ``number``, ``round`` délègue à ``number." "__round__``." -#: library/functions.rst:1538 +#: library/functions.rst:1535 msgid "" "The behavior of :func:`round` for floats can be surprising: for example, " "``round(2.675, 2)`` gives ``2.67`` instead of the expected ``2.68``. This is " @@ -2897,7 +2893,7 @@ msgstr "" "fractions de décimaux ne peuvent pas être représentés exactement en nombre a " "virgule flottante. Voir :ref:`tut-fp-issues` pour plus d'information." -#: library/functions.rst:1549 +#: library/functions.rst:1546 msgid "" "Return a new :class:`set` object, optionally with elements taken from " "*iterable*. ``set`` is a built-in class. See :class:`set` and :ref:`types-" @@ -2907,7 +2903,7 @@ msgstr "" "d'*iterable*. ``set`` est une classe native. Voir :class:`set` et :ref:" "`types-set` pour la documentation de cette classe." -#: library/functions.rst:1553 +#: library/functions.rst:1550 msgid "" "For other containers see the built-in :class:`frozenset`, :class:`list`, :" "class:`tuple`, and :class:`dict` classes, as well as the :mod:`collections` " @@ -2916,7 +2912,7 @@ msgstr "" "D'autres conteneurs existent, comme : :class:`frozenset`, :class:`list`, :" "class:`tuple`, et :class:`dict`, ainsi que le module :mod:`collections`." -#: library/functions.rst:1560 +#: library/functions.rst:1557 #, fuzzy msgid "" "This is the counterpart of :func:`getattr`. The arguments are an object, a " @@ -2931,14 +2927,14 @@ msgstr "" "si l'objet l'autorise. Par exemple, ``setattr(x, 'foobar', 123)`` équivaut à " "``x.foobar = 123``." -#: library/functions.rst:1568 +#: library/functions.rst:1565 msgid "" "Since :ref:`private name mangling ` happens at " "compilation time, one must manually mangle a private attribute's (attributes " "with two leading underscores) name in order to set it with :func:`setattr`." msgstr "" -#: library/functions.rst:1577 +#: library/functions.rst:1574 #, fuzzy msgid "" "Return a :term:`slice` object representing the set of indices specified by " @@ -2963,16 +2959,16 @@ msgstr "" "Voir :func:`itertools.islice` pour une version alternative renvoyant un " "itérateur." -#: library/functions.rst:1590 +#: library/functions.rst:1587 msgid "Return a new sorted list from the items in *iterable*." msgstr "Renvoie une nouvelle liste triée depuis les éléments d'*iterable*." -#: library/functions.rst:1592 +#: library/functions.rst:1589 msgid "" "Has two optional arguments which must be specified as keyword arguments." msgstr "A deux arguments optionnels qui doivent être nommés." -#: library/functions.rst:1594 +#: library/functions.rst:1591 msgid "" "*key* specifies a function of one argument that is used to extract a " "comparison key from each element in *iterable* (for example, ``key=str." @@ -2983,7 +2979,7 @@ msgstr "" "lower``). La valeur par défaut est ``None`` (compare les éléments " "directement)." -#: library/functions.rst:1598 +#: library/functions.rst:1595 msgid "" "*reverse* is a boolean value. If set to ``True``, then the list elements " "are sorted as if each comparison were reversed." @@ -2991,7 +2987,7 @@ msgstr "" "*reverse*, une valeur booléenne. Si elle est ``True``, la liste d'éléments " "est triée comme si toutes les comparaisons étaient inversées." -#: library/functions.rst:1601 +#: library/functions.rst:1598 msgid "" "Use :func:`functools.cmp_to_key` to convert an old-style *cmp* function to a " "*key* function." @@ -2999,7 +2995,7 @@ msgstr "" "Utilisez :func:`functools.cmp_to_key` pour convertir l'ancienne notation " "*cmp* en une fonction *key*." -#: library/functions.rst:1604 +#: library/functions.rst:1601 msgid "" "The built-in :func:`sorted` function is guaranteed to be stable. A sort is " "stable if it guarantees not to change the relative order of elements that " @@ -3011,7 +3007,7 @@ msgstr "" "eux. C'est utile pour trier en plusieurs passes (par exemple par département " "puis par salaire)." -#: library/functions.rst:1609 +#: library/functions.rst:1606 msgid "" "The sort algorithm uses only ``<`` comparisons between items. While " "defining an :meth:`~object.__lt__` method will suffice for sorting, :PEP:`8` " @@ -3023,17 +3019,17 @@ msgid "" "method." msgstr "" -#: library/functions.rst:1618 +#: library/functions.rst:1615 msgid "" "For sorting examples and a brief sorting tutorial, see :ref:`sortinghowto`." msgstr "" "Pour des exemples de tris et un bref tutoriel, consultez :ref:`sortinghowto`." -#: library/functions.rst:1622 +#: library/functions.rst:1619 msgid "Transform a method into a static method." msgstr "Transforme une méthode en méthode statique." -#: library/functions.rst:1624 +#: library/functions.rst:1621 msgid "" "A static method does not receive an implicit first argument. To declare a " "static method, use this idiom::" @@ -3041,7 +3037,7 @@ msgstr "" "Une méthode statique ne reçoit pas de premier argument implicitement. Voilà " "comment déclarer une méthode statique ::" -#: library/functions.rst:1631 +#: library/functions.rst:1628 msgid "" "The ``@staticmethod`` form is a function :term:`decorator` -- see :ref:" "`function` for details." @@ -3049,7 +3045,7 @@ msgstr "" "La forme ``@staticmethod`` est un :term:`décorateur ` de " "fonction. Consultez :ref:`function` pour plus de détails." -#: library/functions.rst:1634 +#: library/functions.rst:1631 #, fuzzy msgid "" "A static method can be called either on the class (such as ``C.f()``) or on " @@ -3059,7 +3055,7 @@ msgstr "" "Une méthode statique peut être appelée sur une classe (par exemple, ``C." "f()``) comme sur une instance (par exemple, ``C().f()``)." -#: library/functions.rst:1638 +#: library/functions.rst:1635 #, fuzzy msgid "" "Static methods in Python are similar to those found in Java or C++. Also, " @@ -3070,7 +3066,7 @@ msgstr "" "ou en C++. Consultez :func:`classmethod` pour une variante utile pour créer " "des constructeurs alternatifs." -#: library/functions.rst:1642 +#: library/functions.rst:1639 msgid "" "Like all decorators, it is also possible to call ``staticmethod`` as a " "regular function and do something with its result. This is needed in some " @@ -3084,26 +3080,26 @@ msgstr "" "depuis le corps d'une classe, et souhaiteriez éviter sa transformation en " "méthode d'instance. Pour ces cas, faites comme suit ::" -#: library/functions.rst:1654 +#: library/functions.rst:1651 msgid "For more information on static methods, see :ref:`types`." msgstr "" "Pour plus d'informations sur les méthodes statiques, consultez :ref:`types`." -#: library/functions.rst:1656 +#: library/functions.rst:1653 msgid "" "Static methods now inherit the method attributes (``__module__``, " "``__name__``, ``__qualname__``, ``__doc__`` and ``__annotations__``), have a " "new ``__wrapped__`` attribute, and are now callable as regular functions." msgstr "" -#: library/functions.rst:1671 +#: library/functions.rst:1668 msgid "" "Return a :class:`str` version of *object*. See :func:`str` for details." msgstr "" "Renvoie une version d'*object* sous forme de :class:`str`. Voir :func:`str` " "pour plus de détails." -#: library/functions.rst:1673 +#: library/functions.rst:1670 msgid "" "``str`` is the built-in string :term:`class`. For general information about " "strings, see :ref:`textseq`." @@ -3111,7 +3107,7 @@ msgstr "" "``str`` est la :term:`classe ` native des chaînes de caractères. Pour " "des informations générales à propos des chaînes, consultez :ref:`textseq`." -#: library/functions.rst:1679 +#: library/functions.rst:1676 msgid "" "Sums *start* and the items of an *iterable* from left to right and returns " "the total. The *iterable*'s items are normally numbers, and the start value " @@ -3121,7 +3117,7 @@ msgstr "" "donne le total. Les éléments de l'*iterable* sont normalement des nombres, " "et la valeur de *start* ne peut pas être une chaîne de caractères." -#: library/functions.rst:1683 +#: library/functions.rst:1680 msgid "" "For some use cases, there are good alternatives to :func:`sum`. The " "preferred, fast way to concatenate a sequence of strings is by calling ``''." @@ -3135,11 +3131,11 @@ msgstr "" "meilleure précision, voir :func:`math.fsum`. Pour concaténer une série " "d'itérables, utilisez plutôt :func:`itertools.chain`." -#: library/functions.rst:1689 +#: library/functions.rst:1686 msgid "The *start* parameter can be specified as a keyword argument." msgstr "le paramètre *start* peut être passé comme un argument nommé." -#: library/functions.rst:1694 +#: library/functions.rst:1691 msgid "" "Return a proxy object that delegates method calls to a parent or sibling " "class of *type*. This is useful for accessing inherited methods that have " @@ -3149,7 +3145,7 @@ msgstr "" "de méthode à une classe parente ou sœur de *type*. C'est utile pour accéder " "aux méthodes héritées qui ont été remplacées dans une classe." -#: library/functions.rst:1698 +#: library/functions.rst:1695 msgid "" "The *object-or-type* determines the :term:`method resolution order` to be " "searched. The search starts from the class right after the *type*." @@ -3158,7 +3154,7 @@ msgstr "" "` est utilisé pour la recherche. La recherche " "commence à partir de la classe qui suit immédiatement le *type*." -#: library/functions.rst:1702 +#: library/functions.rst:1699 msgid "" "For example, if :attr:`~class.__mro__` of *object-or-type* is ``D -> B -> C -" "> A -> object`` and the value of *type* is ``B``, then :func:`super` " @@ -3168,7 +3164,7 @@ msgstr "" "-> A -> object`` et la valeur de *type* est ``B``, alors :func:`super` " "recherche ``C -> A -> object``." -#: library/functions.rst:1706 +#: library/functions.rst:1703 msgid "" "The :attr:`~class.__mro__` attribute of the *object-or-type* lists the " "method resolution search order used by both :func:`getattr` and :func:" @@ -3180,7 +3176,7 @@ msgstr "" "`super`. L'attribut est dynamique et peut changer lorsque la hiérarchie " "d'héritage est modifiée." -#: library/functions.rst:1711 +#: library/functions.rst:1708 msgid "" "If the second argument is omitted, the super object returned is unbound. If " "the second argument is an object, ``isinstance(obj, type)`` must be true. " @@ -3192,7 +3188,7 @@ msgstr "" "le second argument est un type, ``issubclass(type2, type)`` doit être vrai " "(c'est utile pour les méthodes de classe)." -#: library/functions.rst:1716 +#: library/functions.rst:1713 msgid "" "There are two typical use cases for *super*. In a class hierarchy with " "single inheritance, *super* can be used to refer to parent classes without " @@ -3205,7 +3201,7 @@ msgstr "" "maintenable. Cet usage se rapproche de l'usage de *super* dans d'autres " "langages de programmation." -#: library/functions.rst:1721 +#: library/functions.rst:1718 #, fuzzy msgid "" "The second use case is to support cooperative multiple inheritance in a " @@ -3229,12 +3225,12 @@ msgstr "" "dans la hiérarchie, et parce que l'ordre peut inclure des classes sœurs " "inconnues avant l'exécution)." -#: library/functions.rst:1731 +#: library/functions.rst:1728 msgid "For both use cases, a typical superclass call looks like this::" msgstr "" "Dans tous les cas, un appel typique à une classe parente ressemble à ::" -#: library/functions.rst:1738 +#: library/functions.rst:1735 msgid "" "In addition to method lookups, :func:`super` also works for attribute " "lookups. One possible use case for this is calling :term:`descriptors " @@ -3244,7 +3240,7 @@ msgstr "" "la recherche d'attributs. Un cas d'utilisation possible est l'appel d'un :" "term:`descripteur ` d'une classe parente ou sœur." -#: library/functions.rst:1742 +#: library/functions.rst:1739 msgid "" "Note that :func:`super` is implemented as part of the binding process for " "explicit dotted attribute lookups such as ``super().__getitem__(name)``. It " @@ -3261,7 +3257,7 @@ msgstr "" "n'est pas défini pour les recherches implicites via des instructions ou des " "opérateurs tels que ``super()[name]``." -#: library/functions.rst:1749 +#: library/functions.rst:1746 msgid "" "Also note that, aside from the zero argument form, :func:`super` is not " "limited to use inside methods. The two argument form specifies the " @@ -3278,7 +3274,7 @@ msgstr "" "propos de la classe en cours de définition, ainsi qu'accéder à l'instance " "courante pour les méthodes ordinaires." -#: library/functions.rst:1756 +#: library/functions.rst:1753 msgid "" "For practical suggestions on how to design cooperative classes using :func:" "`super`, see `guide to using super() `_." -#: library/functions.rst:1765 +#: library/functions.rst:1762 msgid "" "Rather than being a function, :class:`tuple` is actually an immutable " "sequence type, as documented in :ref:`typesseq-tuple` and :ref:`typesseq`." @@ -3296,7 +3292,7 @@ msgstr "" "Plutôt qu'être une fonction, :class:`tuple` est en fait un type de séquence " "immuable, comme documenté dans :ref:`typesseq-tuple` et :ref:`typesseq`." -#: library/functions.rst:1774 +#: library/functions.rst:1771 msgid "" "With one argument, return the type of an *object*. The return value is a " "type object and generally the same object as returned by :attr:`object." @@ -3306,7 +3302,7 @@ msgstr "" "objet type et généralement la même que la valeur de l'attribut :attr:`object." "__class__ `." -#: library/functions.rst:1778 +#: library/functions.rst:1775 msgid "" "The :func:`isinstance` built-in function is recommended for testing the type " "of an object, because it takes subclasses into account." @@ -3314,7 +3310,7 @@ msgstr "" "La fonction native :func:`isinstance` est recommandée pour tester le type " "d'un objet, car elle prend en compte l'héritage." -#: library/functions.rst:1782 +#: library/functions.rst:1779 #, fuzzy msgid "" "With three arguments, return a new type object. This is essentially a " @@ -3337,11 +3333,11 @@ msgstr "" "exemple, les deux instructions suivantes créent deux instances identiques " "de :class:`type` :" -#: library/functions.rst:1797 +#: library/functions.rst:1794 msgid "See also :ref:`bltin-type-objects`." msgstr "Voir aussi :ref:`bltin-type-objects`." -#: library/functions.rst:1799 +#: library/functions.rst:1796 msgid "" "Keyword arguments provided to the three argument form are passed to the " "appropriate metaclass machinery (usually :meth:`~object.__init_subclass__`) " @@ -3349,12 +3345,12 @@ msgid "" "would." msgstr "" -#: library/functions.rst:1804 +#: library/functions.rst:1801 #, fuzzy msgid "See also :ref:`class-customization`." msgstr "Voir aussi :ref:`typeiter`." -#: library/functions.rst:1806 +#: library/functions.rst:1803 msgid "" "Subclasses of :class:`type` which don't override ``type.__new__`` may no " "longer use the one-argument form to get the type of an object." @@ -3363,7 +3359,7 @@ msgstr "" "ne doivent plus utiliser la forme à un argument pour récupérer le type d'un " "objet." -#: library/functions.rst:1812 +#: library/functions.rst:1809 msgid "" "Return the :attr:`~object.__dict__` attribute for a module, class, instance, " "or any other object with a :attr:`~object.__dict__` attribute." @@ -3372,7 +3368,7 @@ msgstr "" "instance ou de n'importe quel objet avec un attribut :attr:`~object." "__dict__`." -#: library/functions.rst:1815 +#: library/functions.rst:1812 msgid "" "Objects such as modules and instances have an updateable :attr:`~object." "__dict__` attribute; however, other objects may have write restrictions on " @@ -3385,7 +3381,7 @@ msgstr "" "exemple, les classes utilisent un :class:`types.MappingProxyType` pour " "éviter les modifications directes du dictionnaire)." -#: library/functions.rst:1820 +#: library/functions.rst:1817 msgid "" "Without an argument, :func:`vars` acts like :func:`locals`. Note, the " "locals dictionary is only useful for reads since updates to the locals " @@ -3395,45 +3391,45 @@ msgstr "" "dictionnaire des variables locales n'est utile qu'en lecture, car ses " "écritures sont ignorées." -#: library/functions.rst:1824 +#: library/functions.rst:1821 msgid "" "A :exc:`TypeError` exception is raised if an object is specified but it " "doesn't have a :attr:`~object.__dict__` attribute (for example, if its class " "defines the :attr:`~object.__slots__` attribute)." msgstr "" -#: library/functions.rst:1830 +#: library/functions.rst:1827 msgid "" "Iterate over several iterables in parallel, producing tuples with an item " "from each one." msgstr "" -#: library/functions.rst:1833 +#: library/functions.rst:1830 #, fuzzy msgid "Example::" msgstr "Exemples ::" -#: library/functions.rst:1842 +#: library/functions.rst:1839 msgid "" "More formally: :func:`zip` returns an iterator of tuples, where the *i*-th " "tuple contains the *i*-th element from each of the argument iterables." msgstr "" -#: library/functions.rst:1845 +#: library/functions.rst:1842 msgid "" "Another way to think of :func:`zip` is that it turns rows into columns, and " "columns into rows. This is similar to `transposing a matrix `_." msgstr "" -#: library/functions.rst:1849 +#: library/functions.rst:1846 msgid "" ":func:`zip` is lazy: The elements won't be processed until the iterable is " "iterated on, e.g. by a :keyword:`!for` loop or by wrapping in a :class:" "`list`." msgstr "" -#: library/functions.rst:1853 +#: library/functions.rst:1850 msgid "" "One thing to consider is that the iterables passed to :func:`zip` could have " "different lengths; sometimes by design, and sometimes because of a bug in " @@ -3441,51 +3437,51 @@ msgid "" "approaches to dealing with this issue:" msgstr "" -#: library/functions.rst:1858 +#: library/functions.rst:1855 msgid "" "By default, :func:`zip` stops when the shortest iterable is exhausted. It " "will ignore the remaining items in the longer iterables, cutting off the " "result to the length of the shortest iterable::" msgstr "" -#: library/functions.rst:1865 +#: library/functions.rst:1862 msgid "" ":func:`zip` is often used in cases where the iterables are assumed to be of " "equal length. In such cases, it's recommended to use the ``strict=True`` " "option. Its output is the same as regular :func:`zip`::" msgstr "" -#: library/functions.rst:1872 +#: library/functions.rst:1869 msgid "" "Unlike the default behavior, it checks that the lengths of iterables are " "identical, raising a :exc:`ValueError` if they aren't:" msgstr "" -#: library/functions.rst:1880 +#: library/functions.rst:1877 msgid "" "Without the ``strict=True`` argument, any bug that results in iterables of " "different lengths will be silenced, possibly manifesting as a hard-to-find " "bug in another part of the program." msgstr "" -#: library/functions.rst:1884 +#: library/functions.rst:1881 msgid "" "Shorter iterables can be padded with a constant value to make all the " "iterables have the same length. This is done by :func:`itertools." "zip_longest`." msgstr "" -#: library/functions.rst:1888 +#: library/functions.rst:1885 msgid "" "Edge cases: With a single iterable argument, :func:`zip` returns an iterator " "of 1-tuples. With no arguments, it returns an empty iterator." msgstr "" -#: library/functions.rst:1891 +#: library/functions.rst:1888 msgid "Tips and tricks:" msgstr "" -#: library/functions.rst:1893 +#: library/functions.rst:1890 #, fuzzy msgid "" "The left-to-right evaluation order of the iterables is guaranteed. This " @@ -3501,7 +3497,7 @@ msgstr "" "l'itérateur. Cela a pour effet de diviser la séquence en morceaux de taille " "*n*." -#: library/functions.rst:1899 +#: library/functions.rst:1896 msgid "" ":func:`zip` in conjunction with the ``*`` operator can be used to unzip a " "list::" @@ -3509,12 +3505,12 @@ msgstr "" ":func:`zip` peut être utilisée conjointement avec l'opérateur ``*`` pour " "dézipper une liste ::" -#: library/functions.rst:1910 +#: library/functions.rst:1907 #, fuzzy msgid "Added the ``strict`` argument." msgstr "ajout de l'argument nommé *flush*." -#: library/functions.rst:1922 +#: library/functions.rst:1919 msgid "" "This is an advanced function that is not needed in everyday Python " "programming, unlike :func:`importlib.import_module`." @@ -3522,7 +3518,7 @@ msgstr "" "C'est une fonction avancée qui n'est pas fréquemment nécessaire, " "contrairement à :func:`importlib.import_module`." -#: library/functions.rst:1925 +#: library/functions.rst:1922 msgid "" "This function is invoked by the :keyword:`import` statement. It can be " "replaced (by importing the :mod:`builtins` module and assigning to " @@ -3542,7 +3538,7 @@ msgstr "" "à trouver l'implémentation par défaut. L'usage direct de :func:`__import__` " "est aussi déconseillé en faveur de :func:`importlib.import_module`." -#: library/functions.rst:1934 +#: library/functions.rst:1931 #, fuzzy msgid "" "The function imports the module *name*, potentially using the given " @@ -3559,7 +3555,7 @@ msgstr "" "l'argument *locals* et n'utilise *globals* que pour déterminer le contexte " "du paquet de l'instruction :keyword:`import`." -#: library/functions.rst:1941 +#: library/functions.rst:1938 msgid "" "*level* specifies whether to use absolute or relative imports. ``0`` (the " "default) means only perform absolute imports. Positive values for *level* " @@ -3572,7 +3568,7 @@ msgstr "" "positive indique le nombre de dossiers parents relativement au dossier du " "module appelant :func:`__import__` (voir la :pep:`328`)." -#: library/functions.rst:1947 +#: library/functions.rst:1944 msgid "" "When the *name* variable is of the form ``package.module``, normally, the " "top-level package (the name up till the first dot) is returned, *not* the " @@ -3584,7 +3580,7 @@ msgstr "" "et *pas* le module nommé par *name*. Cependant, lorsqu'un argument " "*fromlist* est fourni, le module nommé par *name* est renvoyé." -#: library/functions.rst:1952 +#: library/functions.rst:1949 msgid "" "For example, the statement ``import spam`` results in bytecode resembling " "the following code::" @@ -3592,11 +3588,11 @@ msgstr "" "Par exemple, l'instruction ``import spam`` renvoie un code intermédiaire " "(*bytecode* en anglais) ressemblant au code suivant ::" -#: library/functions.rst:1957 +#: library/functions.rst:1954 msgid "The statement ``import spam.ham`` results in this call::" msgstr "L'instruction ``import spam.ham`` appelle ::" -#: library/functions.rst:1961 +#: library/functions.rst:1958 msgid "" "Note how :func:`__import__` returns the toplevel module here because this is " "the object that is bound to a name by the :keyword:`import` statement." @@ -3604,7 +3600,7 @@ msgstr "" "Notez comment :func:`__import__` renvoie ici le module de plus haut niveau " "parce que c'est l'objet lié à un nom par l'instruction :keyword:`import`." -#: library/functions.rst:1964 +#: library/functions.rst:1961 msgid "" "On the other hand, the statement ``from spam.ham import eggs, sausage as " "saus`` results in ::" @@ -3612,7 +3608,7 @@ msgstr "" "En revanche, l'instruction ``from spam.ham import eggs, sausage as saus`` " "donne ::" -#: library/functions.rst:1971 +#: library/functions.rst:1968 msgid "" "Here, the ``spam.ham`` module is returned from :func:`__import__`. From " "this object, the names to import are retrieved and assigned to their " @@ -3621,7 +3617,7 @@ msgstr "" "Ici le module ``spam.ham`` est renvoyé par :func:`__import__`. De cet objet, " "les noms à importer sont récupérés et assignés à leurs noms respectifs." -#: library/functions.rst:1975 +#: library/functions.rst:1972 msgid "" "If you simply want to import a module (potentially within a package) by " "name, use :func:`importlib.import_module`." @@ -3629,7 +3625,7 @@ msgstr "" "Si vous voulez simplement importer un module (potentiellement dans un " "paquet) par son nom, utilisez :func:`importlib.import_module`." -#: library/functions.rst:1978 +#: library/functions.rst:1975 msgid "" "Negative values for *level* are no longer supported (which also changes the " "default value to 0)." @@ -3637,7 +3633,7 @@ msgstr "" "les valeurs négatives pour *level* ne sont plus prises en charge (et sa " "valeur par défaut est 0)." -#: library/functions.rst:1982 +#: library/functions.rst:1979 msgid "" "When the command line options :option:`-E` or :option:`-I` are being used, " "the environment variable :envvar:`PYTHONCASEOK` is now ignored." @@ -3645,11 +3641,11 @@ msgstr "" "quand les options :option:`-E` ou :option:`-I` sont précisées dans la ligne " "de commande, la variable d'environnement :envvar:`PYTHONCASEOK` est ignorée." -#: library/functions.rst:1987 +#: library/functions.rst:1984 msgid "Footnotes" msgstr "Notes" -#: library/functions.rst:1988 +#: library/functions.rst:1985 msgid "" "Note that the parser only accepts the Unix-style end of line convention. If " "you are reading the code from a file, make sure to use newline conversion " diff --git a/library/functools.po b/library/functools.po index 281210ea..d0b8fc6c 100644 --- a/library/functools.po +++ b/library/functools.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-02-06 18:15+0100\n" "Last-Translator: Antoine Wecxsteen\n" "Language-Team: FRENCH \n" @@ -63,7 +63,7 @@ msgstr "" "Comme elle ne nettoie jamais les anciennes entrées, elle est plus simple et " "plus rapide que :func:`lru_cache()` avec une limite." -#: library/functools.rst:258 +#: library/functools.rst:264 msgid "For example::" msgstr "Par exemple ::" @@ -75,7 +75,7 @@ msgid "" "computed properties of instances that are otherwise effectively immutable." msgstr "" -#: library/functools.rst:127 library/functools.rst:350 +#: library/functools.rst:127 library/functools.rst:356 msgid "Example::" msgstr "Exemple ::" @@ -212,10 +212,9 @@ msgstr "" #, fuzzy msgid "" "If *typed* is set to true, function arguments of different types will be " -"cached separately. For example, ``f(3)`` and ``f(3.0)`` will always be " -"treated as distinct calls with distinct results. If *typed* is false, the " -"implementation will usually but not always regard them as equivalent calls " -"and only cache a single result." +"cached separately. If *typed* is false, the implementation will usually " +"regard them as equivalent calls and only cache a single result. (Some types " +"such as *str* and *int* may be cached separately even when *typed* is false.)" msgstr "" "Si *typed* est vrai, les arguments de différents types seront mis en cache " "séparément. Par exemple, ``f(3)`` et ``f(3.0)`` seront considérés comme des " @@ -223,6 +222,15 @@ msgstr "" #: library/functools.rst:168 msgid "" +"Note, type specificity applies only to the function's immediate arguments " +"rather than their contents. The scalar arguments, ``Decimal(42)`` and " +"``Fraction(42)`` are be treated as distinct calls with distinct results. In " +"contrast, the tuple arguments ``('answer', Decimal(42))`` and ``('answer', " +"Fraction(42))`` are treated as equivalent." +msgstr "" + +#: library/functools.rst:174 +msgid "" "The wrapped function is instrumented with a :func:`cache_parameters` " "function that returns a new :class:`dict` showing the values for *maxsize* " "and *typed*. This is for information purposes only. Mutating the values " @@ -233,7 +241,7 @@ msgstr "" "*maxsize* et de *typed*. Cela ne sert qu'au débogage, changer ces valeurs " "n'a pas d'incidence." -#: library/functools.rst:173 +#: library/functools.rst:179 #, fuzzy msgid "" "To help measure the effectiveness of the cache and tune the *maxsize* " @@ -247,7 +255,7 @@ msgstr "" "*misses*, *maxsize* et *currsize*. Dans un environnement *multithread*, les " "succès et échecs d'appel du cache sont approximatifs." -#: library/functools.rst:178 +#: library/functools.rst:184 msgid "" "The decorator also provides a :func:`cache_clear` function for clearing or " "invalidating the cache." @@ -255,7 +263,7 @@ msgstr "" "Le décorateur fournit également une fonction :func:`cache_clear` pour vider " "ou invalider le cache." -#: library/functools.rst:181 +#: library/functools.rst:187 msgid "" "The original underlying function is accessible through the :attr:" "`__wrapped__` attribute. This is useful for introspection, for bypassing " @@ -265,13 +273,13 @@ msgstr "" "`__wrapped__`. Ceci est utile pour l'introspection, pour outrepasser le " "cache, ou pour ré-englober la fonction avec un cache différent." -#: library/functools.rst:185 +#: library/functools.rst:191 msgid "" "The cache keeps references to the arguments and return values until they age " "out of the cache or until the cache is cleared." msgstr "" -#: library/functools.rst:188 +#: library/functools.rst:194 msgid "" "An `LRU (least recently used) cache `_ works best when the " @@ -288,7 +296,7 @@ msgstr "" "taille limite du cache permet de s'assurer que le cache ne grossisse pas " "sans limite dans les processus à longue durée de vie comme les serveurs Web." -#: library/functools.rst:195 +#: library/functools.rst:201 msgid "" "In general, the LRU cache should only be used when you want to reuse " "previously computed values. Accordingly, it doesn't make sense to cache " @@ -301,11 +309,11 @@ msgstr "" "mutable distinct à chaque appel ou des fonctions *impures* telles que ``!" "time()`` ou ``!random()``." -#: library/functools.rst:200 +#: library/functools.rst:206 msgid "Example of an LRU cache for static web content::" msgstr "Exemple d'un cache LRU pour du contenu web statique ::" -#: library/functools.rst:219 +#: library/functools.rst:225 msgid "" "Example of efficiently computing `Fibonacci numbers `_ using a cache to implement a `dynamic " @@ -316,19 +324,19 @@ msgstr "" "technique de `programmation dynamique `_ ::" -#: library/functools.rst:239 +#: library/functools.rst:245 msgid "Added the *typed* option." msgstr "L'option *typed* a été ajoutée." -#: library/functools.rst:242 +#: library/functools.rst:248 msgid "Added the *user_function* option." msgstr "Ajout de l'option *user_function*." -#: library/functools.rst:245 +#: library/functools.rst:251 msgid "Added the function :func:`cache_parameters`" msgstr "Ajout de la fonction :func:`cache_parameters`" -#: library/functools.rst:250 +#: library/functools.rst:256 msgid "" "Given a class defining one or more rich comparison ordering methods, this " "class decorator supplies the rest. This simplifies the effort involved in " @@ -338,7 +346,7 @@ msgstr "" "riches, ce décorateur de classe fournit le reste. Ceci simplifie l'effort à " "fournir dans la spécification de toutes les opérations de comparaison riche :" -#: library/functools.rst:254 +#: library/functools.rst:260 msgid "" "The class must define one of :meth:`__lt__`, :meth:`__le__`, :meth:`__gt__`, " "or :meth:`__ge__`. In addition, the class should supply an :meth:`__eq__` " @@ -348,7 +356,7 @@ msgstr "" "`__le__`, :meth:`__gt__`, or :meth:`__ge__`. De plus, la classe doit fournir " "une méthode :meth:`__eq__`." -#: library/functools.rst:278 +#: library/functools.rst:284 msgid "" "While this decorator makes it easy to create well behaved totally ordered " "types, it *does* come at the cost of slower execution and more complex stack " @@ -363,7 +371,7 @@ msgstr "" "méthodes de comparaison riches résoudra normalement vos problèmes de " "rapidité." -#: library/functools.rst:287 +#: library/functools.rst:293 msgid "" "This decorator makes no attempt to override methods that have been declared " "in the class *or its superclasses*. Meaning that if a superclass defines a " @@ -371,7 +379,7 @@ msgid "" "the original method is abstract." msgstr "" -#: library/functools.rst:294 +#: library/functools.rst:300 msgid "" "Returning NotImplemented from the underlying comparison function for " "unrecognised types is now supported." @@ -379,7 +387,7 @@ msgstr "" "Retourner NotImplemented dans les fonction de comparaison sous-jacentes pour " "les types non reconnus est maintenant supporté." -#: library/functools.rst:300 +#: library/functools.rst:306 msgid "" "Return a new :ref:`partial object` which when called will " "behave like *func* called with the positional arguments *args* and keyword " @@ -393,7 +401,7 @@ msgstr "" "à l'appel, ils sont ajoutés à *args*. Si plus d'arguments nommés sont " "fournis, ils étendent et surchargent *keywords*. À peu près équivalent à ::" -#: library/functools.rst:316 +#: library/functools.rst:322 msgid "" "The :func:`partial` is used for partial function application which \"freezes" "\" some portion of a function's arguments and/or keywords resulting in a new " @@ -407,7 +415,7 @@ msgstr "" "peut être utilisé pour créer un appelable qui se comporte comme la fonction :" "func:`int` ou l'argument *base* est deux par défaut :" -#: library/functools.rst:331 +#: library/functools.rst:337 msgid "" "Return a new :class:`partialmethod` descriptor which behaves like :class:" "`partial` except that it is designed to be used as a method definition " @@ -417,7 +425,7 @@ msgstr "" "comme :class:`partial` sauf qu'il est fait pour être utilisé comme une " "définition de méthode plutôt que d'être appelé directement." -#: library/functools.rst:335 +#: library/functools.rst:341 msgid "" "*func* must be a :term:`descriptor` or a callable (objects which are both, " "like normal functions, are handled as descriptors)." @@ -425,7 +433,7 @@ msgstr "" "*func* doit être un :term:`descriptor` ou un appelable (les objets qui sont " "les deux, comme les fonction normales, sont gérés comme des descripteurs)." -#: library/functools.rst:338 +#: library/functools.rst:344 msgid "" "When *func* is a descriptor (such as a normal Python function, :func:" "`classmethod`, :func:`staticmethod`, :func:`abstractmethod` or another " @@ -439,7 +447,7 @@ msgstr "" "au descripteur sous-jacent, et un :ref:`objet partiel ` " "approprié est renvoyé comme résultat." -#: library/functools.rst:344 +#: library/functools.rst:350 msgid "" "When *func* is a non-descriptor callable, an appropriate bound method is " "created dynamically. This behaves like a normal Python function when used as " @@ -453,7 +461,7 @@ msgstr "" "premier argument positionnel, avant les *args* et *keywords* fournis au " "constructeur :class:`partialmethod`." -#: library/functools.rst:375 +#: library/functools.rst:381 msgid "" "Apply *function* of two arguments cumulatively to the items of *iterable*, " "from left to right, so as to reduce the iterable to a single value. For " @@ -475,11 +483,11 @@ msgstr "" "la séquence est vide. Si *initializer* n'est pas renseigné et que *iterable* " "ne contient qu'un élément, le premier élément est renvoyé." -#: library/functools.rst:384 +#: library/functools.rst:390 msgid "Roughly equivalent to::" msgstr "À peu près équivalent à ::" -#: library/functools.rst:396 +#: library/functools.rst:402 msgid "" "See :func:`itertools.accumulate` for an iterator that yields all " "intermediate values." @@ -487,7 +495,7 @@ msgstr "" "Voir :func:`itertools.accumulate` pour un itérateur qui génère toutes les " "valeurs intermédiaires." -#: library/functools.rst:401 +#: library/functools.rst:407 msgid "" "Transform a function into a :term:`single-dispatch ` :term:" "`generic function`." @@ -495,29 +503,31 @@ msgstr "" "Transforme une fonction en une :term:`fonction générique ` :term:`single-dispatch `." -#: library/functools.rst:404 +#: library/functools.rst:410 +#, fuzzy msgid "" "To define a generic function, decorate it with the ``@singledispatch`` " -"decorator. Note that the dispatch happens on the type of the first argument, " -"create your function accordingly::" +"decorator. When defining a function using ``@singledispatch``, note that the " +"dispatch happens on the type of the first argument::" msgstr "" "Pour définir une fonction générique, il faut la décorer avec le décorateur " "``@singledispatch``. Noter que la distribution est effectuée sur le type du " "premier argument, donc la fonction doit être créée en conséquence ::" -#: library/functools.rst:415 +#: library/functools.rst:421 +#, fuzzy msgid "" "To add overloaded implementations to the function, use the :func:`register` " -"attribute of the generic function. It is a decorator. For functions " -"annotated with types, the decorator will infer the type of the first " -"argument automatically::" +"attribute of the generic function, which can be used as a decorator. For " +"functions annotated with types, the decorator will infer the type of the " +"first argument automatically::" msgstr "" "Pour ajouter des surcharges d'implémentation à la fonction, utiliser " "l'attribut :func:`register` de la fonction générique. C'est un décorateur. " "Pour les fonctions annotées avec des types, le décorateur infère le type du " "premier argument automatiquement ::" -#: library/functools.rst:433 +#: library/functools.rst:439 msgid "" "For code which doesn't use type annotations, the appropriate type argument " "can be passed explicitly to the decorator itself::" @@ -525,25 +535,27 @@ msgstr "" "Pour le code qui n’utilise pas les indications de type, le type souhaité " "peut être passé explicitement en argument au décorateur ::" -#: library/functools.rst:444 +#: library/functools.rst:450 +#, fuzzy msgid "" -"To enable registering lambdas and pre-existing functions, the :func:" -"`register` attribute can be used in a functional form::" +"To enable registering :term:`lambdas` and pre-existing functions, " +"the :func:`register` attribute can also be used in a functional form::" msgstr "" "Pour permettre l'enregistrement de *lambdas* et de fonctions pré-existantes, " "l'attribut :func:`register` peut être utilisé sous forme fonctionnelle ::" -#: library/functools.rst:452 +#: library/functools.rst:458 +#, fuzzy msgid "" -"The :func:`register` attribute returns the undecorated function which " -"enables decorator stacking, pickling, as well as creating unit tests for " -"each variant independently::" +"The :func:`register` attribute returns the undecorated function. This " +"enables decorator stacking, :mod:`pickling`, and the creation of " +"unit tests for each variant independently::" msgstr "" "L'attribut :func:`register` renvoie la fonction non décorée ce qui permet " "d'empiler les décorateurs, la sérialisation, et la création de tests " "unitaires pour chaque variante indépendamment ::" -#: library/functools.rst:466 +#: library/functools.rst:472 msgid "" "When called, the generic function dispatches on the type of the first " "argument::" @@ -551,12 +563,14 @@ msgstr "" "Quand elle est appelée, la fonction générique distribue sur le type du " "premier argument ::" -#: library/functools.rst:486 +#: library/functools.rst:492 +#, fuzzy msgid "" "Where there is no registered implementation for a specific type, its method " "resolution order is used to find a more generic implementation. The original " -"function decorated with ``@singledispatch`` is registered for the base " -"``object`` type, which means it is used if no better implementation is found." +"function decorated with ``@singledispatch`` is registered for the base :" +"class:`object` type, which means it is used if no better implementation is " +"found." msgstr "" "Quand il n'y a pas d'implémentation enregistrée pour un type spécifique, son " "ordre de résolution de méthode est utilisé pour trouver une implémentation " @@ -564,21 +578,23 @@ msgstr "" "est enregistrée pour le type d'``object``, et elle sera utilisée si aucune " "implémentation n'est trouvée." -#: library/functools.rst:492 +#: library/functools.rst:498 msgid "" -"If an implementation registered to :term:`abstract base class`, virtual " -"subclasses will be dispatched to that implementation::" +"If an implementation is registered to an :term:`abstract base class`, " +"virtual subclasses of the base class will be dispatched to that " +"implementation::" msgstr "" -#: library/functools.rst:506 +#: library/functools.rst:513 +#, fuzzy msgid "" -"To check which implementation will the generic function choose for a given " +"To check which implementation the generic function will choose for a given " "type, use the ``dispatch()`` attribute::" msgstr "" "Pour vérifier quelle implémentation la fonction générique choisira pour un " "type donné, utiliser l'attribut ``dispatch()`` ::" -#: library/functools.rst:514 +#: library/functools.rst:521 msgid "" "To access all registered implementations, use the read-only ``registry`` " "attribute::" @@ -586,12 +602,13 @@ msgstr "" "Pour accéder à toutes les implémentations enregistrées, utiliser l'attribut " "en lecture seule ``registry`` ::" -#: library/functools.rst:528 -msgid "The :func:`register` attribute supports using type annotations." +#: library/functools.rst:535 +#, fuzzy +msgid "The :func:`register` attribute now supports using type annotations." msgstr "" "L’attribut :func:`register` gère l’utilisation des indications de type." -#: library/functools.rst:534 +#: library/functools.rst:541 msgid "" "Transform a method into a :term:`single-dispatch ` :term:" "`generic function`." @@ -599,32 +616,36 @@ msgstr "" "Transforme une méthode en une :term:`fonction générique ` :" "term:`single-dispatch `." -#: library/functools.rst:537 +#: library/functools.rst:544 +#, fuzzy msgid "" "To define a generic method, decorate it with the ``@singledispatchmethod`` " -"decorator. Note that the dispatch happens on the type of the first non-self " -"or non-cls argument, create your function accordingly::" +"decorator. When defining a function using ``@singledispatchmethod``, note " +"that the dispatch happens on the type of the first non-*self* or non-*cls* " +"argument::" msgstr "" "Pour définir une fonction générique, il faut la décorer avec le décorateur " "``@singledispatchmethod``. Notez que la distribution est effectuée sur le " "type du premier argument non *self* ni *cls*, donc la fonction doit être " "conçue en conséquence ::" -#: library/functools.rst:554 +#: library/functools.rst:562 msgid "" -"``@singledispatchmethod`` supports nesting with other decorators such as " -"``@classmethod``. Note that to allow for ``dispatcher.register``, " -"``singledispatchmethod`` must be the *outer most* decorator. Here is the " -"``Negator`` class with the ``neg`` methods being class bound::" +"``@singledispatchmethod`` supports nesting with other decorators such as :" +"func:`@classmethod`. Note that to allow for ``dispatcher." +"register``, ``singledispatchmethod`` must be the *outer most* decorator. " +"Here is the ``Negator`` class with the ``neg`` methods bound to the class, " +"rather than an instance of the class::" msgstr "" -#: library/functools.rst:575 +#: library/functools.rst:584 msgid "" -"The same pattern can be used for other similar decorators: ``staticmethod``, " -"``abstractmethod``, and others." +"The same pattern can be used for other similar decorators: :func:" +"`@staticmethod`, :func:`@abstractmethod`, " +"and others." msgstr "" -#: library/functools.rst:583 +#: library/functools.rst:593 msgid "" "Update a *wrapper* function to look like the *wrapped* function. The " "optional arguments are tuples to specify which attributes of the original " @@ -649,7 +670,7 @@ msgstr "" "met à jour le ``__dict__`` de la fonction englobante, c'est-à-dire le " "dictionnaire de l'instance)." -#: library/functools.rst:593 +#: library/functools.rst:603 msgid "" "To allow access to the original function for introspection and other " "purposes (e.g. bypassing a caching decorator such as :func:`lru_cache`), " @@ -661,7 +682,7 @@ msgstr "" "func:`lru_cache`), cette fonction ajoute automatiquement un attribut " "``__wrapped__`` qui référence la fonction englobée." -#: library/functools.rst:598 +#: library/functools.rst:608 msgid "" "The main intended use for this function is in :term:`decorator` functions " "which wrap the decorated function and return the wrapper. If the wrapper " @@ -675,7 +696,7 @@ msgstr "" "décorateur, au lieu de la définition originale, métadonnées souvent bien " "moins utiles." -#: library/functools.rst:604 +#: library/functools.rst:614 msgid "" ":func:`update_wrapper` may be used with callables other than functions. Any " "attributes named in *assigned* or *updated* that are missing from the object " @@ -689,20 +710,20 @@ msgstr "" "dans la fonction englobante). :exc:`AttributeError` est toujours levée si le " "fonction englobante elle même a des attributs non existants dans *updated*." -#: library/functools.rst:610 +#: library/functools.rst:620 msgid "Automatic addition of the ``__wrapped__`` attribute." msgstr "Ajout automatique de l'attribut ``__wrapped__``." -#: library/functools.rst:613 +#: library/functools.rst:623 msgid "Copying of the ``__annotations__`` attribute by default." msgstr "Copie de l'attribut ``__annotations__`` par défaut." -#: library/functools.rst:616 +#: library/functools.rst:626 msgid "Missing attributes no longer trigger an :exc:`AttributeError`." msgstr "" "Les attributs manquants ne lèvent plus d'exception :exc:`AttributeError`." -#: library/functools.rst:619 +#: library/functools.rst:629 msgid "" "The ``__wrapped__`` attribute now always refers to the wrapped function, " "even if that function defined a ``__wrapped__`` attribute. (see :issue:" @@ -711,7 +732,7 @@ msgstr "" "L'attribut ``__wrapped__`` renvoie toujours la fonction englobée, même si " "cette fonction définit un attribut ``__wrapped__``. (voir :issue:`17482`)" -#: library/functools.rst:627 +#: library/functools.rst:637 msgid "" "This is a convenience function for invoking :func:`update_wrapper` as a " "function decorator when defining a wrapper function. It is equivalent to " @@ -723,7 +744,7 @@ msgstr "" "C'est équivalent à ``partial(update_wrapper, wrapped=wrapped, " "assigned=assigned, updated=updated)``. Par exemple ::" -#: library/functools.rst:653 +#: library/functools.rst:663 msgid "" "Without the use of this decorator factory, the name of the example function " "would have been ``'wrapper'``, and the docstring of the original :func:" @@ -733,11 +754,11 @@ msgstr "" "d'exemple aurait été ``'wrapper'``, et la chaîne de documentation de la " "fonction :func:`example` originale aurait été perdue." -#: library/functools.rst:661 +#: library/functools.rst:671 msgid ":class:`partial` Objects" msgstr "Objets :class:`partial`" -#: library/functools.rst:663 +#: library/functools.rst:673 msgid "" ":class:`partial` objects are callable objects created by :func:`partial`. " "They have three read-only attributes:" @@ -745,7 +766,7 @@ msgstr "" "Les objets :class:`partial` sont des objets appelables créés par :func:" "`partial`. Ils ont trois attributs en lecture seule :" -#: library/functools.rst:669 +#: library/functools.rst:679 msgid "" "A callable object or function. Calls to the :class:`partial` object will be " "forwarded to :attr:`func` with new arguments and keywords." @@ -753,7 +774,7 @@ msgstr "" "Un objet ou une fonction appelable. Les appels à l'objet :class:`partial` " "seront transmis à :attr:`func` avec les nouveaux arguments et mots-clés." -#: library/functools.rst:675 +#: library/functools.rst:685 msgid "" "The leftmost positional arguments that will be prepended to the positional " "arguments provided to a :class:`partial` object call." @@ -761,7 +782,7 @@ msgstr "" "Les arguments positionnels qui seront ajoutés avant les arguments fournis " "lors de l'appel d'un objet :class:`partial`." -#: library/functools.rst:681 +#: library/functools.rst:691 msgid "" "The keyword arguments that will be supplied when the :class:`partial` object " "is called." @@ -769,7 +790,7 @@ msgstr "" "Les arguments nommés qui seront fournis quand l'objet :class:`partial` est " "appelé." -#: library/functools.rst:684 +#: library/functools.rst:694 msgid "" ":class:`partial` objects are like :class:`function` objects in that they are " "callable, weak referencable, and can have attributes. There are some " diff --git a/library/keyword.po b/library/keyword.po index f1af9c33..ff703a40 100644 --- a/library/keyword.po +++ b/library/keyword.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-11-27 10:27+0100\n" "PO-Revision-Date: 2021-10-22 02:12+0200\n" "Last-Translator: Jean Abou Samra \n" "Language-Team: FRENCH \n" @@ -24,9 +24,10 @@ msgid "**Source code:** :source:`Lib/keyword.py`" msgstr "**Code source :** :source:`Lib/keyword.py`" #: library/keyword.rst:11 +#, fuzzy msgid "" "This module allows a Python program to determine if a string is a :ref:" -"`keyword `." +"`keyword ` or :ref:`soft keyword `." msgstr "" "Ce module permet à un programme Python de déterminer si une chaîne " "représente un :ref:`mot-clé ` du langage." @@ -47,13 +48,15 @@ msgstr "" "effectives, ils seront tout de même inclus." #: library/keyword.rst:29 -msgid "Return ``True`` if *s* is a Python soft :ref:`keyword `." -msgstr "Renvoie vrai si *s* est un :ref:`mot-clé ad-hoc ` de Python." +#, fuzzy +msgid "Return ``True`` if *s* is a Python :ref:`soft keyword `." +msgstr "Renvoie vrai si *s* est un :ref:`mot-clé ` de Python." #: library/keyword.rst:36 +#, fuzzy msgid "" -"Sequence containing all the soft :ref:`keywords ` defined for the " -"interpreter. If any soft keywords are defined to only be active when " +"Sequence containing all the :ref:`soft keywords ` defined for " +"the interpreter. If any soft keywords are defined to only be active when " "particular :mod:`__future__` statements are in effect, these will be " "included as well." msgstr "" @@ -61,3 +64,7 @@ msgstr "" "l'interpréteur. Si certains mots-clés sont définis pour être actifs " "seulement si des instructions :mod:`__future__` particulières sont " "effectives, ils seront tout de même inclus." + +#~ msgid "Return ``True`` if *s* is a Python soft :ref:`keyword `." +#~ msgstr "" +#~ "Renvoie vrai si *s* est un :ref:`mot-clé ad-hoc ` de Python." diff --git a/library/sqlite3.po b/library/sqlite3.po index 1b36e119..554d8116 100644 --- a/library/sqlite3.po +++ b/library/sqlite3.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-11-04 18:14+0100\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2019-03-26 15:55+0100\n" "Last-Translator: Julien Palard \n" "Language-Team: FRENCH \n" @@ -51,8 +51,9 @@ msgstr "" "interface SQL conforme à la spécification DB-API 2.0 décrite par :pep:`249`." #: library/sqlite3.rst:24 +#, fuzzy msgid "" -"To use the module, you must first create a :class:`Connection` object that " +"To use the module, start by creating a :class:`Connection` object that " "represents the database. Here the data will be stored in the :file:`example." "db` file::" msgstr "" @@ -61,35 +62,37 @@ msgstr "" "stockées dans le fichier :file:`example.db` ::" #: library/sqlite3.rst:31 +#, fuzzy msgid "" -"You can also supply the special name ``:memory:`` to create a database in " -"RAM." +"The special path name ``:memory:`` can be provided to create a temporary " +"database in RAM." msgstr "" "Vous pouvez également fournir le nom spécial ``:memory:`` pour créer une " "base de données dans la mémoire vive." -#: library/sqlite3.rst:33 +#: library/sqlite3.rst:34 +#, fuzzy msgid "" -"Once you have a :class:`Connection`, you can create a :class:`Cursor` " +"Once a :class:`Connection` has been established, create a :class:`Cursor` " "object and call its :meth:`~Cursor.execute` method to perform SQL commands::" msgstr "" "Une fois que vous avez une instance de :class:`Connection`, vous pouvez " "créer un objet :class:`Cursor` et appeler sa méthode :meth:`~Cursor.execute` " "pour exécuter les commandes SQL ::" -#: library/sqlite3.rst:52 +#: library/sqlite3.rst:53 msgid "" -"The data you've saved is persistent and is available in subsequent sessions::" +"The saved data is persistent: it can be reloaded in a subsequent session " +"even after restarting the Python interpreter::" msgstr "" -"Les données que vous avez sauvegardées sont persistantes et disponibles dans " -"les sessions suivantes ::" -#: library/sqlite3.rst:58 +#: library/sqlite3.rst:60 +#, fuzzy msgid "" -"To retrieve data after executing a SELECT statement, you can either treat " -"the cursor as an :term:`iterator`, call the cursor's :meth:`~Cursor." -"fetchone` method to retrieve a single matching row, or call :meth:`~Cursor." -"fetchall` to get a list of the matching rows." +"To retrieve data after executing a SELECT statement, either treat the cursor " +"as an :term:`iterator`, call the cursor's :meth:`~Cursor.fetchone` method to " +"retrieve a single matching row, or call :meth:`~Cursor.fetchall` to get a " +"list of the matching rows." msgstr "" "Pour récupérer des données après avoir exécuté une instruction *SELECT*, " "vous pouvez considérer le curseur comme un :term:`itérateur `, " @@ -97,18 +100,17 @@ msgstr "" "seule ligne correspondante ou appeler :meth:`~Cursor.fetchall` pour obtenir " "une liste des lignes correspondantes." -#: library/sqlite3.rst:63 +#: library/sqlite3.rst:65 msgid "This example uses the iterator form::" msgstr "Cet exemple utilise la forme itérateur ::" -#: library/sqlite3.rst:76 +#: library/sqlite3.rst:78 #, fuzzy msgid "" -"Usually your SQL operations will need to use values from Python variables. " -"You shouldn't assemble your query using Python's string operations because " -"doing so is insecure; it makes your program vulnerable to an SQL injection " -"attack (see the `xkcd webcomic `_ for a humorous " -"example of what can go wrong)::" +"SQL operations usually need to use values from Python variables. However, " +"beware of using Python's string operations to assemble queries, as they are " +"vulnerable to SQL injection attacks (see the `xkcd webcomic `_ for a humorous example of what can go wrong)::" msgstr "" "Habituellement, vos opérations SQL utilisent les valeurs de variables " "Python. Vous ne devez pas assembler votre requête à l'aide des opérations " @@ -116,26 +118,27 @@ msgstr "" "votre programme vulnérable à une attaque par injection SQL (voir https://" "xkcd.com/327/ pour un exemple amusant de ce qui peut mal tourner)." -#: library/sqlite3.rst:86 +#: library/sqlite3.rst:87 msgid "" -"Instead, use the DB-API's parameter substitution. Put a placeholder wherever " -"you want to use a value, and then provide a tuple of values as the second " -"argument to the cursor's :meth:`~Cursor.execute` method. An SQL statement " -"may use one of two kinds of placeholders: question marks (qmark style) or " -"named placeholders (named style). For the qmark style, ``parameters`` must " -"be a :term:`sequence `. For the named style, it can be either a :" -"term:`sequence ` or :class:`dict` instance. The length of the :" -"term:`sequence ` must match the number of placeholders, or a :exc:" -"`ProgrammingError` is raised. If a :class:`dict` is given, it must contain " -"keys for all named parameters. Any extra items are ignored. Here's an " -"example of both styles:" +"Instead, use the DB-API's parameter substitution. To insert a variable into " +"a query string, use a placeholder in the string, and substitute the actual " +"values into the query by providing them as a :class:`tuple` of values to the " +"second argument of the cursor's :meth:`~Cursor.execute` method. An SQL " +"statement may use one of two kinds of placeholders: question marks (qmark " +"style) or named placeholders (named style). For the qmark style, " +"``parameters`` must be a :term:`sequence `. For the named style, " +"it can be either a :term:`sequence ` or :class:`dict` instance. " +"The length of the :term:`sequence ` must match the number of " +"placeholders, or a :exc:`ProgrammingError` is raised. If a :class:`dict` is " +"given, it must contain keys for all named parameters. Any extra items are " +"ignored. Here's an example of both styles:" msgstr "" -#: library/sqlite3.rst:105 +#: library/sqlite3.rst:107 msgid "https://www.sqlite.org" msgstr "https://www.sqlite.org" -#: library/sqlite3.rst:104 +#: library/sqlite3.rst:106 msgid "" "The SQLite web page; the documentation describes the syntax and the " "available data types for the supported SQL dialect." @@ -143,40 +146,40 @@ msgstr "" "Dans la page Web de SQLite, la documentation décrit la syntaxe et les types " "de données disponibles qui sont pris en charge par cette variante SQL." -#: library/sqlite3.rst:108 +#: library/sqlite3.rst:110 msgid "https://www.w3schools.com/sql/" msgstr "https://www.w3schools.com/sql/" -#: library/sqlite3.rst:108 +#: library/sqlite3.rst:110 msgid "Tutorial, reference and examples for learning SQL syntax." msgstr "Tutoriel, référence et exemples pour apprendre la syntaxe SQL." -#: library/sqlite3.rst:110 +#: library/sqlite3.rst:112 msgid ":pep:`249` - Database API Specification 2.0" msgstr ":pep:`249` — Spécifications de l'API 2.0 pour la base de données" -#: library/sqlite3.rst:111 +#: library/sqlite3.rst:113 msgid "PEP written by Marc-André Lemburg." msgstr "PEP écrite par Marc-André Lemburg." -#: library/sqlite3.rst:117 +#: library/sqlite3.rst:119 msgid "Module functions and constants" msgstr "Fonctions et constantes du module" -#: library/sqlite3.rst:122 +#: library/sqlite3.rst:124 msgid "" "String constant stating the supported DB-API level. Required by the DB-API. " "Hard-coded to ``\"2.0\"``." msgstr "" -#: library/sqlite3.rst:127 +#: library/sqlite3.rst:129 msgid "" "String constant stating the type of parameter marker formatting expected by " "the :mod:`sqlite3` module. Required by the DB-API. Hard-coded to ``\"qmark" "\"``." msgstr "" -#: library/sqlite3.rst:133 +#: library/sqlite3.rst:135 msgid "" "The :mod:`sqlite3` module supports both ``qmark`` and ``numeric`` DB-API " "parameter styles, because that is what the underlying SQLite library " @@ -184,7 +187,7 @@ msgid "" "``paramstyle`` attribute." msgstr "" -#: library/sqlite3.rst:140 +#: library/sqlite3.rst:142 msgid "" "The version number of this module, as a string. This is not the version of " "the SQLite library." @@ -192,7 +195,7 @@ msgstr "" "Le numéro de version de ce module, sous forme de chaîne. Ce n'est pas la " "version de la bibliothèque SQLite." -#: library/sqlite3.rst:146 +#: library/sqlite3.rst:148 msgid "" "The version number of this module, as a tuple of integers. This is not the " "version of the SQLite library." @@ -200,20 +203,20 @@ msgstr "" "Le numéro de version de ce module, sous forme d'un *n*-uplet d'entiers. Ce " "n'est pas la version de la bibliothèque SQLite." -#: library/sqlite3.rst:152 +#: library/sqlite3.rst:154 msgid "The version number of the run-time SQLite library, as a string." msgstr "" "Le numéro de version de la bibliothèque d'exécution SQLite, sous forme de " "chaîne." -#: library/sqlite3.rst:157 +#: library/sqlite3.rst:159 msgid "" "The version number of the run-time SQLite library, as a tuple of integers." msgstr "" "Le numéro de version de la bibliothèque d'exécution SQLite, sous forme " "d'entier." -#: library/sqlite3.rst:162 +#: library/sqlite3.rst:164 msgid "" "Integer constant required by the DB-API, stating the level of thread safety " "the :mod:`sqlite3` module supports. Currently hard-coded to ``1``, meaning *" @@ -222,13 +225,13 @@ msgid "" "time threaded mode using the following query::" msgstr "" -#: library/sqlite3.rst:175 +#: library/sqlite3.rst:177 msgid "" "Note that the `SQLITE_THREADSAFE levels `_ do not match the DB-API 2.0 ``threadsafety`` levels." msgstr "" -#: library/sqlite3.rst:195 +#: library/sqlite3.rst:197 msgid "" "This constant is meant to be used with the *detect_types* parameter of the :" "func:`connect` function." @@ -236,7 +239,7 @@ msgstr "" "Cette constante est destinée à être utilisée avec le paramètre " "*detect_types* de la fonction :func:`connect`." -#: library/sqlite3.rst:185 +#: library/sqlite3.rst:187 msgid "" "Setting it makes the :mod:`sqlite3` module parse the declared type for each " "column it returns. It will parse out the first word of the declared type, " @@ -251,7 +254,7 @@ msgstr "" "de *number(10)* il gardera *number*. Ensuite, pour cette colonne, il " "utilisera une fonction de conversion du dictionnaire des convertisseurs." -#: library/sqlite3.rst:198 +#: library/sqlite3.rst:200 #, fuzzy msgid "" "Setting this makes the SQLite interface parse the column name for each " @@ -273,7 +276,7 @@ msgstr "" "\\\"x [datetime]\\\"'`` dans votre code SQL, le nom de la colonne sera " "simplement *x*." -#: library/sqlite3.rst:211 +#: library/sqlite3.rst:213 msgid "" "Opens a connection to the SQLite database file *database*. By default " "returns a :class:`Connection` object, unless a custom *factory* is given." @@ -282,7 +285,7 @@ msgstr "" "cette commande renvoie un objet :class:`Connection`, sauf si *factory* est " "donné." -#: library/sqlite3.rst:214 +#: library/sqlite3.rst:216 msgid "" "*database* is a :term:`path-like object` giving the pathname (absolute or " "relative to the current working directory) of the database file to be " @@ -290,7 +293,7 @@ msgid "" "database that resides in RAM instead of on disk." msgstr "" -#: library/sqlite3.rst:219 +#: library/sqlite3.rst:221 msgid "" "When a database is accessed by multiple connections, and one of the " "processes modifies the database, the SQLite database is locked until that " @@ -299,13 +302,13 @@ msgid "" "The default for the timeout parameter is 5.0 (five seconds)." msgstr "" -#: library/sqlite3.rst:225 +#: library/sqlite3.rst:227 msgid "" "For the *isolation_level* parameter, please see the :attr:`~Connection." "isolation_level` property of :class:`Connection` objects." msgstr "" -#: library/sqlite3.rst:228 +#: library/sqlite3.rst:230 msgid "" "SQLite natively supports only the types TEXT, INTEGER, REAL, BLOB and NULL. " "If you want to use other types you must add support for them yourself. The " @@ -314,7 +317,7 @@ msgid "" "that." msgstr "" -#: library/sqlite3.rst:233 +#: library/sqlite3.rst:235 msgid "" "*detect_types* defaults to 0 (i. e. off, no type detection), you can set it " "to any combination of :const:`PARSE_DECLTYPES` and :const:`PARSE_COLNAMES` " @@ -323,7 +326,7 @@ msgid "" "parameter is set. In such case, the returned type is :class:`str`." msgstr "" -#: library/sqlite3.rst:239 +#: library/sqlite3.rst:241 msgid "" "By default, *check_same_thread* is :const:`True` and only the creating " "thread may use the connection. If set :const:`False`, the returned " @@ -332,7 +335,7 @@ msgid "" "the user to avoid data corruption." msgstr "" -#: library/sqlite3.rst:244 +#: library/sqlite3.rst:246 msgid "" "By default, the :mod:`sqlite3` module uses its :class:`Connection` class for " "the connect call. You can, however, subclass the :class:`Connection` class " @@ -340,11 +343,11 @@ msgid "" "the *factory* parameter." msgstr "" -#: library/sqlite3.rst:249 +#: library/sqlite3.rst:251 msgid "Consult the section :ref:`sqlite3-types` of this manual for details." msgstr "" -#: library/sqlite3.rst:251 +#: library/sqlite3.rst:253 msgid "" "The :mod:`sqlite3` module internally uses a statement cache to avoid SQL " "parsing overhead. If you want to explicitly set the number of statements " @@ -352,46 +355,46 @@ msgid "" "parameter. The currently implemented default is to cache 100 statements." msgstr "" -#: library/sqlite3.rst:256 +#: library/sqlite3.rst:258 msgid "" "If *uri* is true, *database* is interpreted as a URI. This allows you to " "specify options. For example, to open a database in read-only mode you can " "use::" msgstr "" -#: library/sqlite3.rst:262 +#: library/sqlite3.rst:264 msgid "" "More information about this feature, including a list of recognized options, " "can be found in the `SQLite URI documentation `_." msgstr "" -#: library/sqlite3.rst:265 +#: library/sqlite3.rst:267 msgid "" "Raises an :ref:`auditing event ` ``sqlite3.connect`` with argument " "``database``." msgstr "" -#: library/sqlite3.rst:266 +#: library/sqlite3.rst:268 msgid "" "Raises an :ref:`auditing event ` ``sqlite3.connect/handle`` with " "argument ``connection_handle``." msgstr "" -#: library/sqlite3.rst:268 +#: library/sqlite3.rst:270 msgid "Added the *uri* parameter." msgstr "" -#: library/sqlite3.rst:271 +#: library/sqlite3.rst:273 msgid "" "*database* can now also be a :term:`path-like object`, not only a string." msgstr "" -#: library/sqlite3.rst:274 +#: library/sqlite3.rst:276 msgid "Added the ``sqlite3.connect/handle`` auditing event." msgstr "" -#: library/sqlite3.rst:280 +#: library/sqlite3.rst:282 msgid "" "Registers a callable to convert a bytestring from the database into a custom " "Python type. The callable will be invoked for all database values that are " @@ -401,7 +404,7 @@ msgid "" "manner." msgstr "" -#: library/sqlite3.rst:289 +#: library/sqlite3.rst:291 msgid "" "Registers a callable to convert the custom Python type *type* into one of " "SQLite's supported types. The callable *callable* accepts as single " @@ -409,7 +412,7 @@ msgid "" "int, float, str or bytes." msgstr "" -#: library/sqlite3.rst:297 +#: library/sqlite3.rst:299 msgid "" "Returns :const:`True` if the string *sql* contains one or more complete SQL " "statements terminated by semicolons. It does not verify that the SQL is " @@ -417,12 +420,12 @@ msgid "" "the statement is terminated by a semicolon." msgstr "" -#: library/sqlite3.rst:302 +#: library/sqlite3.rst:304 msgid "" "This can be used to build a shell for SQLite, as in the following example:" msgstr "" -#: library/sqlite3.rst:310 +#: library/sqlite3.rst:312 msgid "" "By default you will not get any tracebacks in user-defined functions, " "aggregates, converters, authorizer callbacks etc. If you want to debug them, " @@ -431,35 +434,35 @@ msgid "" "disable the feature again." msgstr "" -#: library/sqlite3.rst:320 +#: library/sqlite3.rst:322 msgid "Connection Objects" msgstr "Objets de connexions" -#: library/sqlite3.rst:324 +#: library/sqlite3.rst:326 msgid "A SQLite database connection has the following attributes and methods:" msgstr "" -#: library/sqlite3.rst:328 +#: library/sqlite3.rst:330 msgid "" "Get or set the current default isolation level. :const:`None` for autocommit " "mode or one of \"DEFERRED\", \"IMMEDIATE\" or \"EXCLUSIVE\". See section :" "ref:`sqlite3-controlling-transactions` for a more detailed explanation." msgstr "" -#: library/sqlite3.rst:334 +#: library/sqlite3.rst:336 msgid "" ":const:`True` if a transaction is active (there are uncommitted changes), :" "const:`False` otherwise. Read-only attribute." msgstr "" -#: library/sqlite3.rst:341 +#: library/sqlite3.rst:343 msgid "" "The cursor method accepts a single optional parameter *factory*. If " "supplied, this must be a callable returning an instance of :class:`Cursor` " "or its subclasses." msgstr "" -#: library/sqlite3.rst:347 +#: library/sqlite3.rst:349 msgid "" "This method commits the current transaction. If you don't call this method, " "anything you did since the last call to ``commit()`` is not visible from " @@ -467,41 +470,41 @@ msgid "" "written to the database, please check you didn't forget to call this method." msgstr "" -#: library/sqlite3.rst:354 +#: library/sqlite3.rst:356 msgid "" "This method rolls back any changes to the database since the last call to :" "meth:`commit`." msgstr "" -#: library/sqlite3.rst:359 +#: library/sqlite3.rst:361 msgid "" "This closes the database connection. Note that this does not automatically " "call :meth:`commit`. If you just close your database connection without " "calling :meth:`commit` first, your changes will be lost!" msgstr "" -#: library/sqlite3.rst:365 +#: library/sqlite3.rst:367 msgid "" "This is a nonstandard shortcut that creates a cursor object by calling the :" "meth:`~Connection.cursor` method, calls the cursor's :meth:`~Cursor.execute` " "method with the *parameters* given, and returns the cursor." msgstr "" -#: library/sqlite3.rst:372 +#: library/sqlite3.rst:374 msgid "" "This is a nonstandard shortcut that creates a cursor object by calling the :" "meth:`~Connection.cursor` method, calls the cursor's :meth:`~Cursor." "executemany` method with the *parameters* given, and returns the cursor." msgstr "" -#: library/sqlite3.rst:379 +#: library/sqlite3.rst:381 msgid "" "This is a nonstandard shortcut that creates a cursor object by calling the :" "meth:`~Connection.cursor` method, calls the cursor's :meth:`~Cursor." "executescript` method with the given *sql_script*, and returns the cursor." msgstr "" -#: library/sqlite3.rst:386 +#: library/sqlite3.rst:388 msgid "" "Creates a user-defined function that you can later use from within SQL " "statements under the function name *name*. *num_params* is the number of " @@ -514,25 +517,25 @@ msgid "" "older versions." msgstr "" -#: library/sqlite3.rst:396 +#: library/sqlite3.rst:398 msgid "" "The function can return any of the types supported by SQLite: bytes, str, " "int, float and ``None``." msgstr "" -#: library/sqlite3.rst:399 +#: library/sqlite3.rst:401 msgid "The *deterministic* parameter was added." msgstr "" -#: library/sqlite3.rst:419 library/sqlite3.rst:702 +#: library/sqlite3.rst:421 library/sqlite3.rst:704 msgid "Example:" msgstr "Exemple :" -#: library/sqlite3.rst:409 +#: library/sqlite3.rst:411 msgid "Creates a user-defined aggregate function." msgstr "" -#: library/sqlite3.rst:411 +#: library/sqlite3.rst:413 msgid "" "The aggregate class must implement a ``step`` method, which accepts the " "number of parameters *num_params* (if *num_params* is -1, the function may " @@ -540,13 +543,13 @@ msgid "" "the final result of the aggregate." msgstr "" -#: library/sqlite3.rst:416 +#: library/sqlite3.rst:418 msgid "" "The ``finalize`` method can return any of the types supported by SQLite: " "bytes, str, int, float and ``None``." msgstr "" -#: library/sqlite3.rst:426 +#: library/sqlite3.rst:428 msgid "" "Creates a collation with the specified *name* and *callable*. The callable " "will be passed two string arguments. It should return -1 if the first is " @@ -555,30 +558,30 @@ msgid "" "(ORDER BY in SQL) so your comparisons don't affect other SQL operations." msgstr "" -#: library/sqlite3.rst:432 +#: library/sqlite3.rst:434 msgid "" "Note that the callable will get its parameters as Python bytestrings, which " "will normally be encoded in UTF-8." msgstr "" -#: library/sqlite3.rst:435 +#: library/sqlite3.rst:437 msgid "" "The following example shows a custom collation that sorts \"the wrong way\":" msgstr "" -#: library/sqlite3.rst:439 +#: library/sqlite3.rst:441 msgid "" "To remove a collation, call ``create_collation`` with ``None`` as callable::" msgstr "" -#: library/sqlite3.rst:446 +#: library/sqlite3.rst:448 msgid "" "You can call this method from a different thread to abort any queries that " "might be executing on the connection. The query will then abort and the " "caller will get an exception." msgstr "" -#: library/sqlite3.rst:453 +#: library/sqlite3.rst:455 msgid "" "This routine registers a callback. The callback is invoked for each attempt " "to access a column of a table in the database. The callback should return :" @@ -588,7 +591,7 @@ msgid "" "in the :mod:`sqlite3` module." msgstr "" -#: library/sqlite3.rst:460 +#: library/sqlite3.rst:462 msgid "" "The first argument to the callback signifies what kind of operation is to be " "authorized. The second and third argument will be arguments or :const:`None` " @@ -599,7 +602,7 @@ msgid "" "code." msgstr "" -#: library/sqlite3.rst:467 +#: library/sqlite3.rst:469 msgid "" "Please consult the SQLite documentation about the possible values for the " "first argument and the meaning of the second and third argument depending on " @@ -607,7 +610,7 @@ msgid "" "module." msgstr "" -#: library/sqlite3.rst:474 +#: library/sqlite3.rst:476 msgid "" "This routine registers a callback. The callback is invoked for every *n* " "instructions of the SQLite virtual machine. This is useful if you want to " @@ -615,26 +618,26 @@ msgid "" "a GUI." msgstr "" -#: library/sqlite3.rst:479 +#: library/sqlite3.rst:481 msgid "" "If you want to clear any previously installed progress handler, call the " "method with :const:`None` for *handler*." msgstr "" -#: library/sqlite3.rst:482 +#: library/sqlite3.rst:484 msgid "" "Returning a non-zero value from the handler function will terminate the " "currently executing query and cause it to raise an :exc:`OperationalError` " "exception." msgstr "" -#: library/sqlite3.rst:489 +#: library/sqlite3.rst:491 msgid "" "Registers *trace_callback* to be called for each SQL statement that is " "actually executed by the SQLite backend." msgstr "" -#: library/sqlite3.rst:492 +#: library/sqlite3.rst:494 msgid "" "The only argument passed to the callback is the statement (as :class:`str`) " "that is being executed. The return value of the callback is ignored. Note " @@ -644,19 +647,19 @@ msgid "" "of triggers defined in the current database." msgstr "" -#: library/sqlite3.rst:500 +#: library/sqlite3.rst:502 msgid "" "Passing :const:`None` as *trace_callback* will disable the trace callback." msgstr "" -#: library/sqlite3.rst:503 +#: library/sqlite3.rst:505 msgid "" "Exceptions raised in the trace callback are not propagated. As a development " "and debugging aid, use :meth:`~sqlite3.enable_callback_tracebacks` to enable " "printing tracebacks from exceptions raised in the trace callback." msgstr "" -#: library/sqlite3.rst:513 +#: library/sqlite3.rst:515 msgid "" "This routine allows/disallows the SQLite engine to load SQLite extensions " "from shared libraries. SQLite extensions can define new functions, " @@ -664,38 +667,38 @@ msgid "" "extension is the fulltext-search extension distributed with SQLite." msgstr "" -#: library/sqlite3.rst:535 +#: library/sqlite3.rst:537 msgid "Loadable extensions are disabled by default. See [#f1]_." msgstr "" -#: library/sqlite3.rst:520 +#: library/sqlite3.rst:522 msgid "" "Raises an :ref:`auditing event ` ``sqlite3.enable_load_extension`` " "with arguments ``connection``, ``enabled``." msgstr "" -#: library/sqlite3.rst:524 +#: library/sqlite3.rst:526 msgid "Added the ``sqlite3.enable_load_extension`` auditing event." msgstr "" -#: library/sqlite3.rst:531 +#: library/sqlite3.rst:533 msgid "" "This routine loads a SQLite extension from a shared library. You have to " "enable extension loading with :meth:`enable_load_extension` before you can " "use this routine." msgstr "" -#: library/sqlite3.rst:537 +#: library/sqlite3.rst:539 msgid "" "Raises an :ref:`auditing event ` ``sqlite3.load_extension`` with " "arguments ``connection``, ``path``." msgstr "" -#: library/sqlite3.rst:541 +#: library/sqlite3.rst:543 msgid "Added the ``sqlite3.load_extension`` auditing event." msgstr "" -#: library/sqlite3.rst:546 +#: library/sqlite3.rst:548 msgid "" "You can change this attribute to a callable that accepts the cursor and the " "original row as a tuple and will return the real result row. This way, you " @@ -703,7 +706,7 @@ msgid "" "object that can also access columns by name." msgstr "" -#: library/sqlite3.rst:555 +#: library/sqlite3.rst:557 msgid "" "If returning a tuple doesn't suffice and you want name-based access to " "columns, you should consider setting :attr:`row_factory` to the highly-" @@ -713,7 +716,7 @@ msgid "" "approach or even a db_row based solution." msgstr "" -#: library/sqlite3.rst:567 +#: library/sqlite3.rst:569 msgid "" "Using this attribute you can control what objects are returned for the " "``TEXT`` data type. By default, this attribute is set to :class:`str` and " @@ -721,23 +724,23 @@ msgid "" "you want to return :class:`bytes` instead, you can set it to :class:`bytes`." msgstr "" -#: library/sqlite3.rst:572 +#: library/sqlite3.rst:574 msgid "" "You can also set it to any other callable that accepts a single bytestring " "parameter and returns the resulting object." msgstr "" -#: library/sqlite3.rst:575 +#: library/sqlite3.rst:577 msgid "See the following example code for illustration:" msgstr "" -#: library/sqlite3.rst:582 +#: library/sqlite3.rst:584 msgid "" "Returns the total number of database rows that have been modified, inserted, " "or deleted since the database connection was opened." msgstr "" -#: library/sqlite3.rst:588 +#: library/sqlite3.rst:590 msgid "" "Returns an iterator to dump the database in an SQL text format. Useful when " "saving an in-memory database for later restoration. This function provides " @@ -745,11 +748,11 @@ msgid "" "shell." msgstr "" -#: library/sqlite3.rst:593 +#: library/sqlite3.rst:595 msgid "Example::" msgstr "Exemple ::" -#: library/sqlite3.rst:607 +#: library/sqlite3.rst:609 msgid "" "This method makes a backup of a SQLite database even while it's being " "accessed by other clients, or concurrently by the same connection. The copy " @@ -757,14 +760,14 @@ msgid "" "class:`Connection` instance." msgstr "" -#: library/sqlite3.rst:612 +#: library/sqlite3.rst:614 msgid "" "By default, or when *pages* is either ``0`` or a negative integer, the " "entire database is copied in a single step; otherwise the method performs a " "loop copying up to *pages* pages at a time." msgstr "" -#: library/sqlite3.rst:616 +#: library/sqlite3.rst:618 msgid "" "If *progress* is specified, it must either be ``None`` or a callable object " "that will be executed at each iteration with three integer arguments, " @@ -772,7 +775,7 @@ msgid "" "pages still to be copied and the *total* number of pages." msgstr "" -#: library/sqlite3.rst:621 +#: library/sqlite3.rst:623 msgid "" "The *name* argument specifies the database name that will be copied: it must " "be a string containing either ``\"main\"``, the default, to indicate the " @@ -781,36 +784,36 @@ msgid "" "an attached database." msgstr "" -#: library/sqlite3.rst:627 +#: library/sqlite3.rst:629 msgid "" "The *sleep* argument specifies the number of seconds to sleep by between " "successive attempts to backup remaining pages, can be specified either as an " "integer or a floating point value." msgstr "" -#: library/sqlite3.rst:631 +#: library/sqlite3.rst:633 msgid "Example 1, copy an existing database into another::" msgstr "" -#: library/sqlite3.rst:645 +#: library/sqlite3.rst:647 msgid "Example 2, copy an existing database into a transient copy::" msgstr "" -#: library/sqlite3.rst:659 +#: library/sqlite3.rst:661 msgid "Cursor Objects" msgstr "" -#: library/sqlite3.rst:663 +#: library/sqlite3.rst:665 msgid "A :class:`Cursor` instance has the following attributes and methods." msgstr "" -#: library/sqlite3.rst:670 +#: library/sqlite3.rst:672 msgid "" "Executes an SQL statement. Values may be bound to the statement using :ref:" "`placeholders `." msgstr "" -#: library/sqlite3.rst:673 +#: library/sqlite3.rst:675 msgid "" ":meth:`execute` will only execute a single SQL statement. If you try to " "execute more than one statement with it, it will raise a :exc:`.Warning`. " @@ -818,7 +821,7 @@ msgid "" "with one call." msgstr "" -#: library/sqlite3.rst:681 +#: library/sqlite3.rst:683 msgid "" "Executes a :ref:`parameterized ` SQL command against " "all parameter sequences or mappings found in the sequence " @@ -826,11 +829,11 @@ msgid "" "`iterator` yielding parameters instead of a sequence." msgstr "" -#: library/sqlite3.rst:688 +#: library/sqlite3.rst:690 msgid "Here's a shorter example using a :term:`generator`:" msgstr "" -#: library/sqlite3.rst:695 +#: library/sqlite3.rst:697 msgid "" "This is a nonstandard convenience method for executing multiple SQL " "statements at once. It issues a ``COMMIT`` statement first, then executes " @@ -838,23 +841,23 @@ msgid "" "`isolation_level`; any transaction control must be added to *sql_script*." msgstr "" -#: library/sqlite3.rst:700 +#: library/sqlite3.rst:702 msgid "*sql_script* can be an instance of :class:`str`." msgstr "" -#: library/sqlite3.rst:709 +#: library/sqlite3.rst:711 msgid "" "Fetches the next row of a query result set, returning a single sequence, or :" "const:`None` when no more data is available." msgstr "" -#: library/sqlite3.rst:715 +#: library/sqlite3.rst:717 msgid "" "Fetches the next set of rows of a query result, returning a list. An empty " "list is returned when no more rows are available." msgstr "" -#: library/sqlite3.rst:718 +#: library/sqlite3.rst:720 msgid "" "The number of rows to fetch per call is specified by the *size* parameter. " "If it is not given, the cursor's arraysize determines the number of rows to " @@ -863,7 +866,7 @@ msgid "" "not being available, fewer rows may be returned." msgstr "" -#: library/sqlite3.rst:724 +#: library/sqlite3.rst:726 msgid "" "Note there are performance considerations involved with the *size* " "parameter. For optimal performance, it is usually best to use the arraysize " @@ -871,42 +874,42 @@ msgid "" "the same value from one :meth:`fetchmany` call to the next." msgstr "" -#: library/sqlite3.rst:731 +#: library/sqlite3.rst:733 msgid "" "Fetches all (remaining) rows of a query result, returning a list. Note that " "the cursor's arraysize attribute can affect the performance of this " "operation. An empty list is returned when no rows are available." msgstr "" -#: library/sqlite3.rst:737 +#: library/sqlite3.rst:739 msgid "Close the cursor now (rather than whenever ``__del__`` is called)." msgstr "" -#: library/sqlite3.rst:739 +#: library/sqlite3.rst:741 msgid "" "The cursor will be unusable from this point forward; a :exc:" "`ProgrammingError` exception will be raised if any operation is attempted " "with the cursor." msgstr "" -#: library/sqlite3.rst:748 +#: library/sqlite3.rst:750 msgid "Required by the DB-API. Is a no-op in :mod:`sqlite3`." msgstr "" -#: library/sqlite3.rst:752 +#: library/sqlite3.rst:754 msgid "" "Although the :class:`Cursor` class of the :mod:`sqlite3` module implements " "this attribute, the database engine's own support for the determination of " "\"rows affected\"/\"rows selected\" is quirky." msgstr "" -#: library/sqlite3.rst:756 +#: library/sqlite3.rst:758 msgid "" "For :meth:`executemany` statements, the number of modifications are summed " "up into :attr:`rowcount`." msgstr "" -#: library/sqlite3.rst:759 +#: library/sqlite3.rst:761 msgid "" "As required by the Python DB API Spec, the :attr:`rowcount` attribute \"is " "-1 in case no ``executeXX()`` has been performed on the cursor or the " @@ -915,7 +918,7 @@ msgid "" "rows a query produced until all rows were fetched." msgstr "" -#: library/sqlite3.rst:767 +#: library/sqlite3.rst:769 msgid "" "This read-only attribute provides the rowid of the last modified row. It is " "only set if you issued an ``INSERT`` or a ``REPLACE`` statement using the :" @@ -924,35 +927,35 @@ msgid "" "`None`." msgstr "" -#: library/sqlite3.rst:773 +#: library/sqlite3.rst:775 msgid "" "If the ``INSERT`` or ``REPLACE`` statement failed to insert the previous " "successful rowid is returned." msgstr "" -#: library/sqlite3.rst:776 +#: library/sqlite3.rst:778 msgid "Added support for the ``REPLACE`` statement." msgstr "" -#: library/sqlite3.rst:781 +#: library/sqlite3.rst:783 msgid "" "Read/write attribute that controls the number of rows returned by :meth:" "`fetchmany`. The default value is 1 which means a single row would be " "fetched per call." msgstr "" -#: library/sqlite3.rst:786 +#: library/sqlite3.rst:788 msgid "" "This read-only attribute provides the column names of the last query. To " "remain compatible with the Python DB API, it returns a 7-tuple for each " "column where the last six items of each tuple are :const:`None`." msgstr "" -#: library/sqlite3.rst:790 +#: library/sqlite3.rst:792 msgid "It is set for ``SELECT`` statements without any matching rows as well." msgstr "" -#: library/sqlite3.rst:794 +#: library/sqlite3.rst:796 msgid "" "This read-only attribute provides the SQLite database :class:`Connection` " "used by the :class:`Cursor` object. A :class:`Cursor` object created by " @@ -960,79 +963,79 @@ msgid "" "`connection` attribute that refers to *con*::" msgstr "" -#: library/sqlite3.rst:807 +#: library/sqlite3.rst:809 msgid "Row Objects" msgstr "" -#: library/sqlite3.rst:811 +#: library/sqlite3.rst:813 msgid "" "A :class:`Row` instance serves as a highly optimized :attr:`~Connection." "row_factory` for :class:`Connection` objects. It tries to mimic a tuple in " "most of its features." msgstr "" -#: library/sqlite3.rst:815 +#: library/sqlite3.rst:817 msgid "" "It supports mapping access by column name and index, iteration, " "representation, equality testing and :func:`len`." msgstr "" -#: library/sqlite3.rst:818 +#: library/sqlite3.rst:820 msgid "" "If two :class:`Row` objects have exactly the same columns and their members " "are equal, they compare equal." msgstr "" -#: library/sqlite3.rst:823 +#: library/sqlite3.rst:825 msgid "" "This method returns a list of column names. Immediately after a query, it is " "the first member of each tuple in :attr:`Cursor.description`." msgstr "" -#: library/sqlite3.rst:826 +#: library/sqlite3.rst:828 msgid "Added support of slicing." msgstr "" -#: library/sqlite3.rst:829 +#: library/sqlite3.rst:831 msgid "Let's assume we initialize a table as in the example given above::" msgstr "" -#: library/sqlite3.rst:841 +#: library/sqlite3.rst:843 msgid "Now we plug :class:`Row` in::" msgstr "" -#: library/sqlite3.rst:873 +#: library/sqlite3.rst:875 msgid "Exceptions" msgstr "Exceptions" -#: library/sqlite3.rst:877 +#: library/sqlite3.rst:879 msgid "A subclass of :exc:`Exception`." msgstr "" -#: library/sqlite3.rst:881 +#: library/sqlite3.rst:883 msgid "" "The base class of the other exceptions in this module. It is a subclass of :" "exc:`Exception`." msgstr "" -#: library/sqlite3.rst:886 +#: library/sqlite3.rst:888 msgid "Exception raised for errors that are related to the database." msgstr "" -#: library/sqlite3.rst:890 +#: library/sqlite3.rst:892 msgid "" "Exception raised when the relational integrity of the database is affected, " "e.g. a foreign key check fails. It is a subclass of :exc:`DatabaseError`." msgstr "" -#: library/sqlite3.rst:895 +#: library/sqlite3.rst:897 msgid "" "Exception raised for programming errors, e.g. table not found or already " "exists, syntax error in the SQL statement, wrong number of parameters " "specified, etc. It is a subclass of :exc:`DatabaseError`." msgstr "" -#: library/sqlite3.rst:901 +#: library/sqlite3.rst:903 msgid "" "Exception raised for errors that are related to the database's operation and " "not necessarily under the control of the programmer, e.g. an unexpected " @@ -1040,7 +1043,7 @@ msgid "" "not be processed, etc. It is a subclass of :exc:`DatabaseError`." msgstr "" -#: library/sqlite3.rst:908 +#: library/sqlite3.rst:910 msgid "" "Exception raised in case a method or database API was used which is not " "supported by the database, e.g. calling the :meth:`~Connection.rollback` " @@ -1048,82 +1051,82 @@ msgid "" "turned off. It is a subclass of :exc:`DatabaseError`." msgstr "" -#: library/sqlite3.rst:917 +#: library/sqlite3.rst:919 msgid "SQLite and Python types" msgstr "" -#: library/sqlite3.rst:921 +#: library/sqlite3.rst:923 msgid "Introduction" msgstr "Introduction" -#: library/sqlite3.rst:923 +#: library/sqlite3.rst:925 msgid "" "SQLite natively supports the following types: ``NULL``, ``INTEGER``, " "``REAL``, ``TEXT``, ``BLOB``." msgstr "" -#: library/sqlite3.rst:926 +#: library/sqlite3.rst:928 msgid "" "The following Python types can thus be sent to SQLite without any problem:" msgstr "" -#: library/sqlite3.rst:946 +#: library/sqlite3.rst:948 msgid "Python type" msgstr "Type Python" -#: library/sqlite3.rst:946 +#: library/sqlite3.rst:948 msgid "SQLite type" msgstr "SQLite type" -#: library/sqlite3.rst:948 +#: library/sqlite3.rst:950 msgid ":const:`None`" msgstr ":const:`None`" -#: library/sqlite3.rst:948 +#: library/sqlite3.rst:950 msgid "``NULL``" msgstr "``NULL``" -#: library/sqlite3.rst:950 +#: library/sqlite3.rst:952 msgid ":class:`int`" msgstr ":class:`int`" -#: library/sqlite3.rst:950 +#: library/sqlite3.rst:952 msgid "``INTEGER``" msgstr "``INTEGER``" -#: library/sqlite3.rst:952 +#: library/sqlite3.rst:954 msgid ":class:`float`" msgstr ":class:`float`" -#: library/sqlite3.rst:952 +#: library/sqlite3.rst:954 msgid "``REAL``" msgstr "``REAL``" -#: library/sqlite3.rst:937 +#: library/sqlite3.rst:939 msgid ":class:`str`" msgstr ":class:`str`" -#: library/sqlite3.rst:954 +#: library/sqlite3.rst:956 msgid "``TEXT``" msgstr "``TEXT``" -#: library/sqlite3.rst:957 +#: library/sqlite3.rst:959 msgid ":class:`bytes`" msgstr ":class:`bytes`" -#: library/sqlite3.rst:957 +#: library/sqlite3.rst:959 msgid "``BLOB``" msgstr "``BLOB``" -#: library/sqlite3.rst:943 +#: library/sqlite3.rst:945 msgid "This is how SQLite types are converted to Python types by default:" msgstr "" -#: library/sqlite3.rst:954 +#: library/sqlite3.rst:956 msgid "depends on :attr:`~Connection.text_factory`, :class:`str` by default" msgstr "" -#: library/sqlite3.rst:960 +#: library/sqlite3.rst:962 msgid "" "The type system of the :mod:`sqlite3` module is extensible in two ways: you " "can store additional Python types in a SQLite database via object " @@ -1131,11 +1134,11 @@ msgid "" "to different Python types via converters." msgstr "" -#: library/sqlite3.rst:967 +#: library/sqlite3.rst:969 msgid "Using adapters to store additional Python types in SQLite databases" msgstr "" -#: library/sqlite3.rst:969 +#: library/sqlite3.rst:971 msgid "" "As described before, SQLite supports only a limited set of types natively. " "To use other Python types with SQLite, you must **adapt** them to one of the " @@ -1143,23 +1146,23 @@ msgid "" "str, bytes." msgstr "" -#: library/sqlite3.rst:974 +#: library/sqlite3.rst:976 msgid "" "There are two ways to enable the :mod:`sqlite3` module to adapt a custom " "Python type to one of the supported ones." msgstr "" -#: library/sqlite3.rst:979 +#: library/sqlite3.rst:981 msgid "Letting your object adapt itself" msgstr "" -#: library/sqlite3.rst:981 +#: library/sqlite3.rst:983 msgid "" "This is a good approach if you write the class yourself. Let's suppose you " "have a class like this::" msgstr "" -#: library/sqlite3.rst:988 +#: library/sqlite3.rst:990 msgid "" "Now you want to store the point in a single SQLite column. First you'll " "have to choose one of the supported types to be used for representing the " @@ -1169,18 +1172,18 @@ msgid "" "class:`PrepareProtocol`." msgstr "" -#: library/sqlite3.rst:998 +#: library/sqlite3.rst:1000 msgid "Registering an adapter callable" msgstr "" -#: library/sqlite3.rst:1000 +#: library/sqlite3.rst:1002 msgid "" "The other possibility is to create a function that converts the type to the " "string representation and register the function with :meth:" "`register_adapter`." msgstr "" -#: library/sqlite3.rst:1005 +#: library/sqlite3.rst:1007 msgid "" "The :mod:`sqlite3` module has two default adapters for Python's built-in :" "class:`datetime.date` and :class:`datetime.datetime` types. Now let's " @@ -1188,100 +1191,100 @@ msgid "" "representation, but as a Unix timestamp." msgstr "" -#: library/sqlite3.rst:1014 +#: library/sqlite3.rst:1016 msgid "Converting SQLite values to custom Python types" msgstr "" -#: library/sqlite3.rst:1016 +#: library/sqlite3.rst:1018 msgid "" "Writing an adapter lets you send custom Python types to SQLite. But to make " "it really useful we need to make the Python to SQLite to Python roundtrip " "work." msgstr "" -#: library/sqlite3.rst:1019 +#: library/sqlite3.rst:1021 msgid "Enter converters." msgstr "" -#: library/sqlite3.rst:1021 +#: library/sqlite3.rst:1023 msgid "" "Let's go back to the :class:`Point` class. We stored the x and y coordinates " "separated via semicolons as strings in SQLite." msgstr "" -#: library/sqlite3.rst:1024 +#: library/sqlite3.rst:1026 msgid "" "First, we'll define a converter function that accepts the string as a " "parameter and constructs a :class:`Point` object from it." msgstr "" -#: library/sqlite3.rst:1029 +#: library/sqlite3.rst:1031 msgid "" "Converter functions **always** get called with a :class:`bytes` object, no " "matter under which data type you sent the value to SQLite." msgstr "" -#: library/sqlite3.rst:1038 +#: library/sqlite3.rst:1040 msgid "" "Now you need to make the :mod:`sqlite3` module know that what you select " "from the database is actually a point. There are two ways of doing this:" msgstr "" -#: library/sqlite3.rst:1041 +#: library/sqlite3.rst:1043 msgid "Implicitly via the declared type" msgstr "" -#: library/sqlite3.rst:1043 +#: library/sqlite3.rst:1045 msgid "Explicitly via the column name" msgstr "" -#: library/sqlite3.rst:1045 +#: library/sqlite3.rst:1047 msgid "" "Both ways are described in section :ref:`sqlite3-module-contents`, in the " "entries for the constants :const:`PARSE_DECLTYPES` and :const:" "`PARSE_COLNAMES`." msgstr "" -#: library/sqlite3.rst:1048 +#: library/sqlite3.rst:1050 msgid "The following example illustrates both approaches." msgstr "" -#: library/sqlite3.rst:1054 +#: library/sqlite3.rst:1056 msgid "Default adapters and converters" msgstr "" -#: library/sqlite3.rst:1056 +#: library/sqlite3.rst:1058 msgid "" "There are default adapters for the date and datetime types in the datetime " "module. They will be sent as ISO dates/ISO timestamps to SQLite." msgstr "" -#: library/sqlite3.rst:1059 +#: library/sqlite3.rst:1061 msgid "" "The default converters are registered under the name \"date\" for :class:" "`datetime.date` and under the name \"timestamp\" for :class:`datetime." "datetime`." msgstr "" -#: library/sqlite3.rst:1063 +#: library/sqlite3.rst:1065 msgid "" "This way, you can use date/timestamps from Python without any additional " "fiddling in most cases. The format of the adapters is also compatible with " "the experimental SQLite date/time functions." msgstr "" -#: library/sqlite3.rst:1067 +#: library/sqlite3.rst:1069 msgid "The following example demonstrates this." msgstr "" -#: library/sqlite3.rst:1071 +#: library/sqlite3.rst:1073 msgid "" "If a timestamp stored in SQLite has a fractional part longer than 6 numbers, " "its value will be truncated to microsecond precision by the timestamp " "converter." msgstr "" -#: library/sqlite3.rst:1077 +#: library/sqlite3.rst:1079 msgid "" "The default \"timestamp\" converter ignores UTC offsets in the database and " "always returns a naive :class:`datetime.datetime` object. To preserve UTC " @@ -1289,17 +1292,17 @@ msgid "" "offset-aware converter with :func:`register_converter`." msgstr "" -#: library/sqlite3.rst:1085 +#: library/sqlite3.rst:1087 msgid "Controlling Transactions" msgstr "" -#: library/sqlite3.rst:1087 +#: library/sqlite3.rst:1089 msgid "" "The underlying ``sqlite3`` library operates in ``autocommit`` mode by " "default, but the Python :mod:`sqlite3` module by default does not." msgstr "" -#: library/sqlite3.rst:1090 +#: library/sqlite3.rst:1092 msgid "" "``autocommit`` mode means that statements that modify the database take " "effect immediately. A ``BEGIN`` or ``SAVEPOINT`` statement disables " @@ -1307,14 +1310,14 @@ msgid "" "ends the outermost transaction, turns ``autocommit`` mode back on." msgstr "" -#: library/sqlite3.rst:1095 +#: library/sqlite3.rst:1097 msgid "" "The Python :mod:`sqlite3` module by default issues a ``BEGIN`` statement " "implicitly before a Data Modification Language (DML) statement (i.e. " "``INSERT``/``UPDATE``/``DELETE``/``REPLACE``)." msgstr "" -#: library/sqlite3.rst:1099 +#: library/sqlite3.rst:1101 msgid "" "You can control which kind of ``BEGIN`` statements :mod:`sqlite3` implicitly " "executes via the *isolation_level* parameter to the :func:`connect` call, or " @@ -1324,7 +1327,7 @@ msgid "" "``EXCLUSIVE``." msgstr "" -#: library/sqlite3.rst:1106 +#: library/sqlite3.rst:1108 msgid "" "You can disable the :mod:`sqlite3` module's implicit transaction management " "by setting :attr:`isolation_level` to ``None``. This will leave the " @@ -1334,27 +1337,27 @@ msgid "" "code." msgstr "" -#: library/sqlite3.rst:1112 +#: library/sqlite3.rst:1114 msgid "" "Note that :meth:`~Cursor.executescript` disregards :attr:`isolation_level`; " "any transaction control must be added explicitly." msgstr "" -#: library/sqlite3.rst:1115 +#: library/sqlite3.rst:1117 msgid "" ":mod:`sqlite3` used to implicitly commit an open transaction before DDL " "statements. This is no longer the case." msgstr "" -#: library/sqlite3.rst:1121 +#: library/sqlite3.rst:1123 msgid "Using :mod:`sqlite3` efficiently" msgstr "" -#: library/sqlite3.rst:1125 +#: library/sqlite3.rst:1127 msgid "Using shortcut methods" msgstr "" -#: library/sqlite3.rst:1127 +#: library/sqlite3.rst:1129 msgid "" "Using the nonstandard :meth:`execute`, :meth:`executemany` and :meth:" "`executescript` methods of the :class:`Connection` object, your code can be " @@ -1366,38 +1369,38 @@ msgid "" "object." msgstr "" -#: library/sqlite3.rst:1139 +#: library/sqlite3.rst:1141 msgid "Accessing columns by name instead of by index" msgstr "" -#: library/sqlite3.rst:1141 +#: library/sqlite3.rst:1143 msgid "" "One useful feature of the :mod:`sqlite3` module is the built-in :class:" "`sqlite3.Row` class designed to be used as a row factory." msgstr "" -#: library/sqlite3.rst:1144 +#: library/sqlite3.rst:1146 msgid "" "Rows wrapped with this class can be accessed both by index (like tuples) and " "case-insensitively by name:" msgstr "" -#: library/sqlite3.rst:1151 +#: library/sqlite3.rst:1153 msgid "Using the connection as a context manager" msgstr "" -#: library/sqlite3.rst:1153 +#: library/sqlite3.rst:1155 msgid "" "Connection objects can be used as context managers that automatically commit " "or rollback transactions. In the event of an exception, the transaction is " "rolled back; otherwise, the transaction is committed:" msgstr "" -#: library/sqlite3.rst:1162 +#: library/sqlite3.rst:1164 msgid "Footnotes" msgstr "Notes" -#: library/sqlite3.rst:1163 +#: library/sqlite3.rst:1165 msgid "" "The sqlite3 module is not built with loadable extension support by default, " "because some platforms (notably macOS) have SQLite libraries which are " @@ -1405,6 +1408,13 @@ msgid "" "pass the :option:`--enable-loadable-sqlite-extensions` option to configure." msgstr "" +#~ msgid "" +#~ "The data you've saved is persistent and is available in subsequent " +#~ "sessions::" +#~ msgstr "" +#~ "Les données que vous avez sauvegardées sont persistantes et disponibles " +#~ "dans les sessions suivantes ::" + #~ msgid "" #~ "Instead, use the DB-API's parameter substitution. Put ``?`` as a " #~ "placeholder wherever you want to use a value, and then provide a tuple of " diff --git a/library/stdtypes.po b/library/stdtypes.po index 7838a515..cd7a2019 100644 --- a/library/stdtypes.po +++ b/library/stdtypes.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2020-08-09 15:32+0200\n" "Last-Translator: Mathieu Dupuy \n" "Language-Team: FRENCH \n" @@ -127,17 +127,17 @@ msgstr "" msgid "These are the Boolean operations, ordered by ascending priority:" msgstr "Ce sont les opérations booléennes, classées par priorité ascendante :" -#: library/stdtypes.rst:143 library/stdtypes.rst:363 library/stdtypes.rst:881 -#: library/stdtypes.rst:1076 +#: library/stdtypes.rst:143 library/stdtypes.rst:363 library/stdtypes.rst:882 +#: library/stdtypes.rst:1077 msgid "Operation" msgstr "Opération" -#: library/stdtypes.rst:274 library/stdtypes.rst:413 library/stdtypes.rst:1076 +#: library/stdtypes.rst:274 library/stdtypes.rst:413 library/stdtypes.rst:1077 msgid "Result" msgstr "Résultat" -#: library/stdtypes.rst:274 library/stdtypes.rst:881 library/stdtypes.rst:2308 -#: library/stdtypes.rst:3529 +#: library/stdtypes.rst:274 library/stdtypes.rst:882 library/stdtypes.rst:2309 +#: library/stdtypes.rst:3530 msgid "Notes" msgstr "Notes" @@ -149,8 +149,8 @@ msgstr "``x or y``" msgid "if *x* is false, then *y*, else *x*" msgstr "si *x* est faux, alors *y*, sinon *x*" -#: library/stdtypes.rst:284 library/stdtypes.rst:886 library/stdtypes.rst:2314 -#: library/stdtypes.rst:3535 +#: library/stdtypes.rst:284 library/stdtypes.rst:887 library/stdtypes.rst:2315 +#: library/stdtypes.rst:3536 msgid "\\(1)" msgstr "\\(1)" @@ -162,8 +162,8 @@ msgstr "``x and y``" msgid "if *x* is false, then *x*, else *y*" msgstr "si *x* est faux, alors *x*, sinon *y*" -#: library/stdtypes.rst:287 library/stdtypes.rst:1115 library/stdtypes.rst:2320 -#: library/stdtypes.rst:3541 +#: library/stdtypes.rst:287 library/stdtypes.rst:1116 library/stdtypes.rst:2321 +#: library/stdtypes.rst:3542 msgid "\\(2)" msgstr "\\(2)" @@ -175,14 +175,14 @@ msgstr "``not x``" msgid "if *x* is false, then ``True``, else ``False``" msgstr "si *x* est faux, alors ``True``, sinon ``False``" -#: library/stdtypes.rst:895 library/stdtypes.rst:2322 library/stdtypes.rst:2326 -#: library/stdtypes.rst:3543 library/stdtypes.rst:3547 -#: library/stdtypes.rst:3549 +#: library/stdtypes.rst:896 library/stdtypes.rst:2323 library/stdtypes.rst:2327 +#: library/stdtypes.rst:3544 library/stdtypes.rst:3548 +#: library/stdtypes.rst:3550 msgid "\\(3)" msgstr "\\(3)" -#: library/stdtypes.rst:318 library/stdtypes.rst:922 library/stdtypes.rst:2354 -#: library/stdtypes.rst:3579 +#: library/stdtypes.rst:318 library/stdtypes.rst:923 library/stdtypes.rst:2355 +#: library/stdtypes.rst:3580 msgid "Notes:" msgstr "Notes :" @@ -234,8 +234,8 @@ msgstr "" msgid "This table summarizes the comparison operations:" msgstr "Ce tableau résume les opérations de comparaison :" -#: library/stdtypes.rst:2285 library/stdtypes.rst:3506 -#: library/stdtypes.rst:3529 +#: library/stdtypes.rst:2286 library/stdtypes.rst:3507 +#: library/stdtypes.rst:3530 msgid "Meaning" msgstr "Signification" @@ -572,7 +572,7 @@ msgstr "" "un nombre complexe avec *re* pour partie réelle et *im* pour partie " "imaginaire. *im* vaut zéro par défaut." -#: library/stdtypes.rst:1108 library/stdtypes.rst:3566 +#: library/stdtypes.rst:1109 library/stdtypes.rst:3567 msgid "\\(6)" msgstr "\\(6)" @@ -608,8 +608,8 @@ msgstr "``pow(x, y)``" msgid "*x* to the power *y*" msgstr "*x* à la puissance *y*" -#: library/stdtypes.rst:311 library/stdtypes.rst:1100 library/stdtypes.rst:2344 -#: library/stdtypes.rst:3562 library/stdtypes.rst:3569 +#: library/stdtypes.rst:311 library/stdtypes.rst:1101 library/stdtypes.rst:2345 +#: library/stdtypes.rst:3563 library/stdtypes.rst:3570 msgid "\\(5)" msgstr "\\(5)" @@ -777,8 +777,8 @@ msgstr "``x | y``" msgid "bitwise :dfn:`or` of *x* and *y*" msgstr ":dfn:`ou ` binaire de *x* et *y*" -#: library/stdtypes.rst:418 library/stdtypes.rst:1121 library/stdtypes.rst:2334 -#: library/stdtypes.rst:3555 +#: library/stdtypes.rst:418 library/stdtypes.rst:1122 library/stdtypes.rst:2335 +#: library/stdtypes.rst:3556 msgid "\\(4)" msgstr "\\(4)" @@ -1236,18 +1236,20 @@ msgstr "" "détail, supportent toujours les méthodes d'itération." #: library/stdtypes.rst:775 +#, fuzzy msgid "" -"One method needs to be defined for container objects to provide iteration " -"support:" +"One method needs to be defined for container objects to provide :term:" +"`iterable` support:" msgstr "" "Une méthode doit être définie afin que les objets conteneurs supportent " "l'itération :" #: library/stdtypes.rst:782 +#, fuzzy msgid "" -"Return an iterator object. The object is required to support the iterator " -"protocol described below. If a container supports different types of " -"iteration, additional methods can be provided to specifically request " +"Return an :term:`iterator` object. The object is required to support the " +"iterator protocol described below. If a container supports different types " +"of iteration, additional methods can be provided to specifically request " "iterators for those iteration types. (An example of an object supporting " "multiple forms of iteration would be a tree structure which supports both " "breadth-first and depth-first traversal.) This method corresponds to the :c:" @@ -1272,10 +1274,11 @@ msgstr "" "qui forment ensemble le :dfn:`protocole d'itérateur ` :" #: library/stdtypes.rst:797 +#, fuzzy msgid "" -"Return the iterator object itself. This is required to allow both " +"Return the :term:`iterator` object itself. This is required to allow both " "containers and iterators to be used with the :keyword:`for` and :keyword:" -"`in` statements. This method corresponds to the :c:member:`~PyTypeObject." +"`in` statements. This method corresponds to the :c:member:`~PyTypeObject." "tp_iter` slot of the type structure for Python objects in the Python/C API." msgstr "" "Donne l'objet itérateur lui-même. Cela est nécessaire pour permettre à la " @@ -1284,19 +1287,20 @@ msgstr "" "l'attribut :c:member:`~PyTypeObject.tp_iter` de la structure des types des " "objets Python dans l'API Python/C." -#: library/stdtypes.rst:805 +#: library/stdtypes.rst:806 +#, fuzzy msgid "" -"Return the next item from the container. If there are no further items, " -"raise the :exc:`StopIteration` exception. This method corresponds to the :c:" -"member:`~PyTypeObject.tp_iternext` slot of the type structure for Python " -"objects in the Python/C API." +"Return the next item from the :term:`iterator`. If there are no further " +"items, raise the :exc:`StopIteration` exception. This method corresponds to " +"the :c:member:`~PyTypeObject.tp_iternext` slot of the type structure for " +"Python objects in the Python/C API." msgstr "" "Donne l'élément suivant du conteneur. S'il n'y a pas d'autres éléments, une " "exception :exc:`StopIteration` est levée. Cette méthode correspond à " "l'attribut :c:member:`PyTypeObject.tp_iternext` de la structure du type des " "objets Python dans l'API Python/C." -#: library/stdtypes.rst:810 +#: library/stdtypes.rst:811 msgid "" "Python defines several iterator objects to support iteration over general " "and specific sequence types, dictionaries, and other more specialized " @@ -1308,7 +1312,7 @@ msgstr "" "plus spécialisées. Les types spécifiques ne sont pas importants au-delà de " "leur implémentation du protocole d'itération." -#: library/stdtypes.rst:815 +#: library/stdtypes.rst:816 msgid "" "Once an iterator's :meth:`~iterator.__next__` method raises :exc:" "`StopIteration`, it must continue to do so on subsequent calls. " @@ -1319,11 +1323,11 @@ msgstr "" "Implémentations qui ne respectent pas cette propriété sont considérées " "cassées." -#: library/stdtypes.rst:823 +#: library/stdtypes.rst:824 msgid "Generator Types" msgstr "Types générateurs" -#: library/stdtypes.rst:825 +#: library/stdtypes.rst:826 msgid "" "Python's :term:`generator`\\s provide a convenient way to implement the " "iterator protocol. If a container object's :meth:`__iter__` method is " @@ -1340,11 +1344,11 @@ msgstr "" "générateurs peuvent être trouvés dans :ref:`la documentation de l'expression " "yield `." -#: library/stdtypes.rst:837 +#: library/stdtypes.rst:838 msgid "Sequence Types --- :class:`list`, :class:`tuple`, :class:`range`" msgstr "Types séquentiels — :class:`list`, :class:`tuple`, :class:`range`" -#: library/stdtypes.rst:839 +#: library/stdtypes.rst:840 msgid "" "There are three basic sequence types: lists, tuples, and range objects. " "Additional sequence types tailored for processing of :ref:`binary data " @@ -1357,11 +1361,11 @@ msgstr "" "` et :ref:`chaînes de caractères ` sont décrits dans des " "sections dédiées." -#: library/stdtypes.rst:848 +#: library/stdtypes.rst:849 msgid "Common Sequence Operations" msgstr "Opérations communes sur les séquences" -#: library/stdtypes.rst:852 +#: library/stdtypes.rst:853 msgid "" "The operations in the following table are supported by most sequence types, " "both mutable and immutable. The :class:`collections.abc.Sequence` ABC is " @@ -1373,7 +1377,7 @@ msgstr "" "class:`collections.abc.Sequence` est fournie pour aider à implémenter " "correctement ces opérations sur les types séquentiels personnalisés." -#: library/stdtypes.rst:857 +#: library/stdtypes.rst:858 msgid "" "This table lists the sequence operations sorted in ascending priority. In " "the table, *s* and *t* are sequences of the same type, *n*, *i*, *j* and *k* " @@ -1385,7 +1389,7 @@ msgstr "" "*n*, *i*, *j* et *k* sont des nombres entiers et *x* est un objet arbitraire " "qui répond à toutes les restrictions de type et de valeur imposée par *s*." -#: library/stdtypes.rst:862 +#: library/stdtypes.rst:863 msgid "" "The ``in`` and ``not in`` operations have the same priorities as the " "comparison operations. The ``+`` (concatenation) and ``*`` (repetition) " @@ -1397,107 +1401,107 @@ msgstr "" "(répétition) ont la même priorité que les opérations numériques " "correspondantes. [3]_" -#: library/stdtypes.rst:883 +#: library/stdtypes.rst:884 msgid "``x in s``" msgstr "``x in s``" -#: library/stdtypes.rst:883 +#: library/stdtypes.rst:884 msgid "``True`` if an item of *s* is equal to *x*, else ``False``" msgstr "``True`` si un élément de *s* est égal à *x*, sinon ``False``" -#: library/stdtypes.rst:886 +#: library/stdtypes.rst:887 msgid "``x not in s``" msgstr "``x not in s``" -#: library/stdtypes.rst:886 +#: library/stdtypes.rst:887 msgid "``False`` if an item of *s* is equal to *x*, else ``True``" msgstr "``False`` si un élément de *s* est égal à *x*, sinon ``True``" -#: library/stdtypes.rst:889 +#: library/stdtypes.rst:890 msgid "``s + t``" msgstr "``s + t``" -#: library/stdtypes.rst:889 +#: library/stdtypes.rst:890 msgid "the concatenation of *s* and *t*" msgstr "la concaténation de *s* et *t*" -#: library/stdtypes.rst:889 +#: library/stdtypes.rst:890 msgid "(6)(7)" msgstr "(6)(7)" -#: library/stdtypes.rst:892 +#: library/stdtypes.rst:893 msgid "``s * n`` or ``n * s``" msgstr "``s * n`` or ``n * s``" -#: library/stdtypes.rst:892 +#: library/stdtypes.rst:893 msgid "equivalent to adding *s* to itself *n* times" msgstr "équivalent à ajouter *s* *n* fois à lui même" -#: library/stdtypes.rst:892 +#: library/stdtypes.rst:893 msgid "(2)(7)" msgstr "(2)(7)" -#: library/stdtypes.rst:895 +#: library/stdtypes.rst:896 msgid "``s[i]``" msgstr "``s[i]``" -#: library/stdtypes.rst:895 +#: library/stdtypes.rst:896 msgid "*i*\\ th item of *s*, origin 0" msgstr "*i*\\ :sup:`e` élément de *s* en commençant par 0" -#: library/stdtypes.rst:897 +#: library/stdtypes.rst:898 msgid "``s[i:j]``" msgstr "``s[i:j]``" -#: library/stdtypes.rst:897 +#: library/stdtypes.rst:898 msgid "slice of *s* from *i* to *j*" msgstr "tranche (*slice*) de *s* de *i* à *j*" -#: library/stdtypes.rst:897 +#: library/stdtypes.rst:898 msgid "(3)(4)" msgstr "(3)(4)" -#: library/stdtypes.rst:899 +#: library/stdtypes.rst:900 msgid "``s[i:j:k]``" msgstr "``s[i:j:k]``" -#: library/stdtypes.rst:899 +#: library/stdtypes.rst:900 msgid "slice of *s* from *i* to *j* with step *k*" msgstr "tranche (*slice*) de *s* de *i* à *j* avec un pas de *k*" -#: library/stdtypes.rst:899 +#: library/stdtypes.rst:900 msgid "(3)(5)" msgstr "(3)(5)" -#: library/stdtypes.rst:902 +#: library/stdtypes.rst:903 msgid "``len(s)``" msgstr "``len(s)``" -#: library/stdtypes.rst:902 +#: library/stdtypes.rst:903 msgid "length of *s*" msgstr "longueur de *s*" -#: library/stdtypes.rst:904 +#: library/stdtypes.rst:905 msgid "``min(s)``" msgstr "``min(s)``" -#: library/stdtypes.rst:904 +#: library/stdtypes.rst:905 msgid "smallest item of *s*" msgstr "plus petit élément de *s*" -#: library/stdtypes.rst:906 +#: library/stdtypes.rst:907 msgid "``max(s)``" msgstr "``max(s)``" -#: library/stdtypes.rst:906 +#: library/stdtypes.rst:907 msgid "largest item of *s*" msgstr "plus grand élément de *s*" -#: library/stdtypes.rst:908 +#: library/stdtypes.rst:909 msgid "``s.index(x[, i[, j]])``" msgstr "``s.index(x[, i[, j]])``" -#: library/stdtypes.rst:908 +#: library/stdtypes.rst:909 msgid "" "index of the first occurrence of *x* in *s* (at or after index *i* and " "before index *j*)" @@ -1505,19 +1509,19 @@ msgstr "" "indice de la première occurrence de *x* dans *s* (à ou après l'indice *i* et " "avant indice *j*)" -#: library/stdtypes.rst:3537 +#: library/stdtypes.rst:3538 msgid "\\(8)" msgstr "\\(8)" -#: library/stdtypes.rst:912 +#: library/stdtypes.rst:913 msgid "``s.count(x)``" msgstr "``s.count(x)``" -#: library/stdtypes.rst:912 +#: library/stdtypes.rst:913 msgid "total number of occurrences of *x* in *s*" msgstr "nombre total d'occurrences de *x* dans *s*" -#: library/stdtypes.rst:916 +#: library/stdtypes.rst:917 msgid "" "Sequences of the same type also support comparisons. In particular, tuples " "and lists are compared lexicographically by comparing corresponding " @@ -1533,7 +1537,7 @@ msgstr "" "longueur. (Pour plus de détails voir :ref:`comparisons` dans la référence du " "langage.)" -#: library/stdtypes.rst:925 +#: library/stdtypes.rst:926 msgid "" "While the ``in`` and ``not in`` operations are used only for simple " "containment testing in the general case, some specialised sequences (such " @@ -1545,7 +1549,7 @@ msgstr "" "spécialisées (telles que :class:`str`, :class:`bytes` et :class:`bytearray`) " "les utilisent aussi pour tester l'existence de sous-séquences ::" -#: library/stdtypes.rst:934 +#: library/stdtypes.rst:935 msgid "" "Values of *n* less than ``0`` are treated as ``0`` (which yields an empty " "sequence of the same type as *s*). Note that items in the sequence *s* are " @@ -1557,7 +1561,7 @@ msgstr "" "ne sont pas copiés ; ils sont référencés plusieurs fois. Cela hante souvent " "de nouveaux développeurs Python, typiquement ::" -#: library/stdtypes.rst:946 +#: library/stdtypes.rst:947 msgid "" "What has happened is that ``[[]]`` is a one-element list containing an empty " "list, so all three elements of ``[[]] * 3`` are references to this single " @@ -1570,7 +1574,7 @@ msgstr "" "modifie cette liste unique. Vous pouvez créer une liste des différentes " "listes de cette façon ::" -#: library/stdtypes.rst:958 +#: library/stdtypes.rst:959 msgid "" "Further explanation is available in the FAQ entry :ref:`faq-multidimensional-" "list`." @@ -1578,7 +1582,7 @@ msgstr "" "De plus amples explications sont disponibles dans la FAQ à la question :ref:" "`faq-multidimensional-list`." -#: library/stdtypes.rst:962 +#: library/stdtypes.rst:963 msgid "" "If *i* or *j* is negative, the index is relative to the end of sequence *s*: " "``len(s) + i`` or ``len(s) + j`` is substituted. But note that ``-0`` is " @@ -1588,7 +1592,7 @@ msgstr "" "*s* : ``len(s) + i`` ou ``len(s) + j`` est substitué. Mais notez que ``-0`` " "est toujours ``0``." -#: library/stdtypes.rst:967 +#: library/stdtypes.rst:968 msgid "" "The slice of *s* from *i* to *j* is defined as the sequence of items with " "index *k* such that ``i <= k < j``. If *i* or *j* is greater than " @@ -1602,7 +1606,7 @@ msgstr "" "utilisé. Si *j* est omis ou ``None``, ``len(s)`` est utilisé. Si *i* est " "supérieure ou égale à *j*, la tranche est vide." -#: library/stdtypes.rst:974 +#: library/stdtypes.rst:975 msgid "" "The slice of *s* from *i* to *j* with step *k* is defined as the sequence of " "items with index ``x = i + n*k`` such that ``0 <= n < (j-i)/k``. In other " @@ -1625,7 +1629,7 @@ msgstr "" "Remarquez, *k* ne peut pas valoir zéro. Si *k* est ``None``, il est traité " "comme ``1``." -#: library/stdtypes.rst:985 +#: library/stdtypes.rst:986 msgid "" "Concatenating immutable sequences always results in a new object. This " "means that building up a sequence by repeated concatenation will have a " @@ -1638,7 +1642,7 @@ msgstr "" "totale. Pour obtenir un temps d'exécution linéaire, vous devez utiliser " "l'une des alternatives suivantes :" -#: library/stdtypes.rst:990 +#: library/stdtypes.rst:991 msgid "" "if concatenating :class:`str` objects, you can build a list and use :meth:" "`str.join` at the end or else write to an :class:`io.StringIO` instance and " @@ -1648,7 +1652,7 @@ msgstr "" "utiliser :meth:`str.join` à la fin, ou bien écrire dans une instance de :" "class:`io.StringIO` et récupérer sa valeur lorsque vous avez terminé" -#: library/stdtypes.rst:994 +#: library/stdtypes.rst:995 msgid "" "if concatenating :class:`bytes` objects, you can similarly use :meth:`bytes." "join` or :class:`io.BytesIO`, or you can do in-place concatenation with a :" @@ -1660,18 +1664,18 @@ msgstr "" "sur place avec un objet :class:`bytearray`. Les objets :class:`bytearray` " "sont muables et ont un mécanisme de sur-allocation efficace" -#: library/stdtypes.rst:999 +#: library/stdtypes.rst:1000 msgid "if concatenating :class:`tuple` objects, extend a :class:`list` instead" msgstr "" "si vous concaténez des :class:`tuple`, utilisez plutôt *extend* sur une :" "class:`list`" -#: library/stdtypes.rst:1001 +#: library/stdtypes.rst:1002 msgid "for other types, investigate the relevant class documentation" msgstr "" "pour d'autres types, cherchez dans la documentation de la classe concernée" -#: library/stdtypes.rst:1005 +#: library/stdtypes.rst:1006 msgid "" "Some sequence types (such as :class:`range`) only support item sequences " "that follow specific patterns, and hence don't support sequence " @@ -1681,7 +1685,7 @@ msgstr "" "séquences qui suivent des modèles spécifiques, et donc ne prennent pas en " "charge la concaténation ou la répétition." -#: library/stdtypes.rst:1010 +#: library/stdtypes.rst:1011 msgid "" "``index`` raises :exc:`ValueError` when *x* is not found in *s*. Not all " "implementations support passing the additional arguments *i* and *j*. These " @@ -1698,11 +1702,11 @@ msgstr "" "l'indice renvoyé alors relatif au début de la séquence plutôt qu'au début de " "la tranche." -#: library/stdtypes.rst:1021 +#: library/stdtypes.rst:1022 msgid "Immutable Sequence Types" msgstr "Types de séquences immuables" -#: library/stdtypes.rst:1028 +#: library/stdtypes.rst:1029 msgid "" "The only operation that immutable sequence types generally implement that is " "not also implemented by mutable sequence types is support for the :func:" @@ -1712,7 +1716,7 @@ msgstr "" "n'est pas implémentée par les types de séquences muables est le support de " "la fonction native :func:`hash`." -#: library/stdtypes.rst:1032 +#: library/stdtypes.rst:1033 msgid "" "This support allows immutable sequences, such as :class:`tuple` instances, " "to be used as :class:`dict` keys and stored in :class:`set` and :class:" @@ -1722,7 +1726,7 @@ msgstr "" "instances de :class:`tuple`, en tant que clés de :class:`dict` et stockées " "dans les instances de :class:`set` et :class:`frozenset`." -#: library/stdtypes.rst:1036 +#: library/stdtypes.rst:1037 msgid "" "Attempting to hash an immutable sequence that contains unhashable values " "will result in :exc:`TypeError`." @@ -1730,11 +1734,11 @@ msgstr "" "Essayer de hacher une séquence immuable qui contient des valeurs non-" "hachables lèvera une :exc:`TypeError`." -#: library/stdtypes.rst:1043 +#: library/stdtypes.rst:1044 msgid "Mutable Sequence Types" msgstr "Types de séquences muables" -#: library/stdtypes.rst:1050 +#: library/stdtypes.rst:1051 msgid "" "The operations in the following table are defined on mutable sequence types. " "The :class:`collections.abc.MutableSequence` ABC is provided to make it " @@ -1745,7 +1749,7 @@ msgstr "" "MutableSequence` est prévue pour faciliter l'implémentation correcte de ces " "opérations sur les types de séquence personnalisées." -#: library/stdtypes.rst:1054 +#: library/stdtypes.rst:1055 msgid "" "In the table *s* is an instance of a mutable sequence type, *t* is any " "iterable object and *x* is an arbitrary object that meets any type and value " @@ -1758,132 +1762,132 @@ msgstr "" "`bytearray` accepte uniquement des nombres entiers qui répondent à la " "restriction de la valeur ``0 <= x <= 255``)." -#: library/stdtypes.rst:1078 +#: library/stdtypes.rst:1079 msgid "``s[i] = x``" msgstr "``s[i] = x``" -#: library/stdtypes.rst:1078 +#: library/stdtypes.rst:1079 msgid "item *i* of *s* is replaced by *x*" msgstr "élément *i* de *s* est remplacé par *x*" -#: library/stdtypes.rst:1081 +#: library/stdtypes.rst:1082 msgid "``s[i:j] = t``" msgstr "``s[i:j] = t``" -#: library/stdtypes.rst:1081 +#: library/stdtypes.rst:1082 msgid "" "slice of *s* from *i* to *j* is replaced by the contents of the iterable *t*" msgstr "" "tranche de *s* de *i* à *j* est remplacée par le contenu de l'itérable *t*" -#: library/stdtypes.rst:1085 +#: library/stdtypes.rst:1086 msgid "``del s[i:j]``" msgstr "``del s[i:j]``" -#: library/stdtypes.rst:1085 +#: library/stdtypes.rst:1086 msgid "same as ``s[i:j] = []``" msgstr "identique à ``s[i:j] = []``" -#: library/stdtypes.rst:1087 +#: library/stdtypes.rst:1088 msgid "``s[i:j:k] = t``" msgstr "``s[i:j:k] = t``" -#: library/stdtypes.rst:1087 +#: library/stdtypes.rst:1088 msgid "the elements of ``s[i:j:k]`` are replaced by those of *t*" msgstr "les éléments de ``s[i:j:k]`` sont remplacés par ceux de *t*" -#: library/stdtypes.rst:1090 +#: library/stdtypes.rst:1091 msgid "``del s[i:j:k]``" msgstr "``del s[i:j:k]``" -#: library/stdtypes.rst:1090 +#: library/stdtypes.rst:1091 msgid "removes the elements of ``s[i:j:k]`` from the list" msgstr "supprime les éléments de ``s[i:j:k]`` de la liste" -#: library/stdtypes.rst:1093 +#: library/stdtypes.rst:1094 msgid "``s.append(x)``" msgstr "``s.append(x)``" -#: library/stdtypes.rst:1093 +#: library/stdtypes.rst:1094 msgid "" "appends *x* to the end of the sequence (same as ``s[len(s):len(s)] = [x]``)" msgstr "" "ajoute *x* à la fin de la séquence (identique à ``s[len(s):len(s)] = [x]``)" -#: library/stdtypes.rst:1097 +#: library/stdtypes.rst:1098 msgid "``s.clear()``" msgstr "``s.clear()``" -#: library/stdtypes.rst:1097 +#: library/stdtypes.rst:1098 msgid "removes all items from *s* (same as ``del s[:]``)" msgstr "supprime tous les éléments de *s* (identique à ``del s[:]``)" -#: library/stdtypes.rst:1100 +#: library/stdtypes.rst:1101 msgid "``s.copy()``" msgstr "``s.copy()``" -#: library/stdtypes.rst:1100 +#: library/stdtypes.rst:1101 msgid "creates a shallow copy of *s* (same as ``s[:]``)" msgstr "crée une copie superficielle de *s* (identique à ``s[:]``)" -#: library/stdtypes.rst:1103 +#: library/stdtypes.rst:1104 msgid "``s.extend(t)`` or ``s += t``" msgstr "``s.extend(t)`` or ``s += t``" -#: library/stdtypes.rst:1103 +#: library/stdtypes.rst:1104 msgid "" "extends *s* with the contents of *t* (for the most part the same as " "``s[len(s):len(s)] = t``)" msgstr "étend *s* avec le contenu de *t* (proche de ``s[len(s):len(s)] = t``)" -#: library/stdtypes.rst:1108 +#: library/stdtypes.rst:1109 msgid "``s *= n``" msgstr "``s *= n``" -#: library/stdtypes.rst:1108 +#: library/stdtypes.rst:1109 msgid "updates *s* with its contents repeated *n* times" msgstr "met à jour *s* avec son contenu répété *n* fois" -#: library/stdtypes.rst:1111 +#: library/stdtypes.rst:1112 msgid "``s.insert(i, x)``" msgstr "``s.insert(i, x)``" -#: library/stdtypes.rst:1111 +#: library/stdtypes.rst:1112 msgid "" "inserts *x* into *s* at the index given by *i* (same as ``s[i:i] = [x]``)" msgstr "" "insère *x* dans *s* à l'index donné par *i* (identique à ``s[i:i] = [x]``)" -#: library/stdtypes.rst:1115 +#: library/stdtypes.rst:1116 #, fuzzy msgid "``s.pop()`` or ``s.pop(i)``" msgstr "``s.extend(t)`` or ``s += t``" -#: library/stdtypes.rst:1115 +#: library/stdtypes.rst:1116 msgid "retrieves the item at *i* and also removes it from *s*" msgstr "récupère l'élément à *i* et le supprime de *s*" -#: library/stdtypes.rst:1118 +#: library/stdtypes.rst:1119 msgid "``s.remove(x)``" msgstr "``s.remove(x)``" -#: library/stdtypes.rst:1118 +#: library/stdtypes.rst:1119 msgid "remove the first item from *s* where ``s[i]`` is equal to *x*" msgstr "supprime le premier élément de *s* pour lequel ``s[i]`` est égal à *x*" -#: library/stdtypes.rst:1121 +#: library/stdtypes.rst:1122 msgid "``s.reverse()``" msgstr "``s.reverse()``" -#: library/stdtypes.rst:1121 +#: library/stdtypes.rst:1122 msgid "reverses the items of *s* in place" msgstr "inverse sur place les éléments de *s*" -#: library/stdtypes.rst:1129 +#: library/stdtypes.rst:1130 msgid "*t* must have the same length as the slice it is replacing." msgstr "*t* doit avoir la même longueur que la tranche qu'il remplace." -#: library/stdtypes.rst:1132 +#: library/stdtypes.rst:1133 msgid "" "The optional argument *i* defaults to ``-1``, so that by default the last " "item is removed and returned." @@ -1891,13 +1895,13 @@ msgstr "" "L'argument optionnel *i* vaut ``-1`` par défaut, afin que, par défaut, le " "dernier élément soit retiré et renvoyé." -#: library/stdtypes.rst:1136 +#: library/stdtypes.rst:1137 msgid ":meth:`remove` raises :exc:`ValueError` when *x* is not found in *s*." msgstr "" ":meth:`remove` lève une exception :exc:`ValueError` si *x* ne se trouve pas " "dans *s*." -#: library/stdtypes.rst:1139 +#: library/stdtypes.rst:1140 msgid "" "The :meth:`reverse` method modifies the sequence in place for economy of " "space when reversing a large sequence. To remind users that it operates by " @@ -1908,7 +1912,7 @@ msgstr "" "utilisateurs qu'elle a un effet de bord, elle ne renvoie pas la séquence " "inversée." -#: library/stdtypes.rst:1144 +#: library/stdtypes.rst:1145 msgid "" ":meth:`clear` and :meth:`!copy` are included for consistency with the " "interfaces of mutable containers that don't support slicing operations (such " @@ -1923,11 +1927,11 @@ msgstr "" "MutableSequence`, mais la plupart des classes implémentées gérant des " "séquences la proposent." -#: library/stdtypes.rst:1150 +#: library/stdtypes.rst:1151 msgid ":meth:`clear` and :meth:`!copy` methods." msgstr "méthodes :meth:`clear` et :meth:`!copy`." -#: library/stdtypes.rst:1154 +#: library/stdtypes.rst:1155 msgid "" "The value *n* is an integer, or an object implementing :meth:`~object." "__index__`. Zero and negative values of *n* clear the sequence. Items in " @@ -1940,11 +1944,11 @@ msgstr "" "référencés plusieurs fois, comme expliqué pour ``s * n`` dans :ref:`typesseq-" "common`." -#: library/stdtypes.rst:1163 +#: library/stdtypes.rst:1164 msgid "Lists" msgstr "Listes" -#: library/stdtypes.rst:1167 +#: library/stdtypes.rst:1168 msgid "" "Lists are mutable sequences, typically used to store collections of " "homogeneous items (where the precise degree of similarity will vary by " @@ -1954,32 +1958,32 @@ msgstr "" "des collections d'éléments homogènes (où le degré de similitude variera " "selon l'usage)." -#: library/stdtypes.rst:1173 +#: library/stdtypes.rst:1174 msgid "Lists may be constructed in several ways:" msgstr "Les listes peuvent être construites de différentes manières :" -#: library/stdtypes.rst:1175 +#: library/stdtypes.rst:1176 msgid "Using a pair of square brackets to denote the empty list: ``[]``" msgstr "" "En utilisant une paire de crochets pour indiquer une liste vide : ``[]``" -#: library/stdtypes.rst:1176 +#: library/stdtypes.rst:1177 msgid "" "Using square brackets, separating items with commas: ``[a]``, ``[a, b, c]``" msgstr "" "Au moyen de crochets, séparant les éléments par des virgules : ``[a]``, " "``[a, b, c]``" -#: library/stdtypes.rst:1177 +#: library/stdtypes.rst:1178 msgid "Using a list comprehension: ``[x for x in iterable]``" msgstr "En utilisant une liste en compréhension : ``[x for x in iterable]``" -#: library/stdtypes.rst:1178 +#: library/stdtypes.rst:1179 msgid "Using the type constructor: ``list()`` or ``list(iterable)``" msgstr "" "En utilisant le constructeur du type : ``list()`` ou ``list(iterable)``" -#: library/stdtypes.rst:1180 +#: library/stdtypes.rst:1181 msgid "" "The constructor builds a list whose items are the same and in the same order " "as *iterable*'s items. *iterable* may be either a sequence, a container " @@ -1997,7 +2001,7 @@ msgstr "" "``list( (1, 2, 3) )`` renvoie ``[1, 2, 3]``. Si aucun argument est donné, le " "constructeur crée une nouvelle liste vide, ``[]``." -#: library/stdtypes.rst:1189 +#: library/stdtypes.rst:1190 msgid "" "Many other operations also produce lists, including the :func:`sorted` built-" "in." @@ -2005,7 +2009,7 @@ msgstr "" "De nombreuses autres opérations produisent des listes, tel que la fonction " "native :func:`sorted`." -#: library/stdtypes.rst:1192 +#: library/stdtypes.rst:1193 msgid "" "Lists implement all of the :ref:`common ` and :ref:`mutable " "` sequence operations. Lists also provide the following " @@ -2015,7 +2019,7 @@ msgstr "" "` et :ref:`muables `. Les listes " "fournissent également la méthode supplémentaire suivante :" -#: library/stdtypes.rst:1198 +#: library/stdtypes.rst:1199 msgid "" "This method sorts the list in place, using only ``<`` comparisons between " "items. Exceptions are not suppressed - if any comparison operations fail, " @@ -2027,7 +2031,7 @@ msgstr "" "si n'importe quelle opération de comparaison échoue, le tri échouera (et la " "liste sera probablement laissée dans un état partiellement modifié)." -#: library/stdtypes.rst:1203 +#: library/stdtypes.rst:1204 msgid "" ":meth:`sort` accepts two arguments that can only be passed by keyword (:ref:" "`keyword-only arguments `):" @@ -2035,7 +2039,7 @@ msgstr "" ":meth:`sort` accepte deux arguments qui ne peuvent être fournis que par mot-" "clé (:ref:`keyword-only arguments `):" -#: library/stdtypes.rst:1206 +#: library/stdtypes.rst:1207 msgid "" "*key* specifies a function of one argument that is used to extract a " "comparison key from each list element (for example, ``key=str.lower``). The " @@ -2050,7 +2054,7 @@ msgstr "" "``None``, signifie que les éléments sont triés directement sans en calculer " "une valeur \"clé\" séparée." -#: library/stdtypes.rst:1213 +#: library/stdtypes.rst:1214 msgid "" "The :func:`functools.cmp_to_key` utility is available to convert a 2.x style " "*cmp* function to a *key* function." @@ -2058,7 +2062,7 @@ msgstr "" "La fonction utilitaire :func:`functools.cmp_to_key` est disponible pour " "convertir une fonction *cmp* du style 2.x à une fonction *key*." -#: library/stdtypes.rst:1216 +#: library/stdtypes.rst:1217 msgid "" "*reverse* is a boolean value. If set to ``True``, then the list elements " "are sorted as if each comparison were reversed." @@ -2066,7 +2070,7 @@ msgstr "" "*reverse*, une valeur booléenne. Si elle est ``True``, la liste d'éléments " "est triée comme si toutes les comparaisons étaient inversées." -#: library/stdtypes.rst:1219 +#: library/stdtypes.rst:1220 msgid "" "This method modifies the sequence in place for economy of space when sorting " "a large sequence. To remind users that it operates by side effect, it does " @@ -2078,7 +2082,7 @@ msgstr "" "bord, elle ne renvoie pas la séquence triée (utilisez :func:`sorted` pour " "demander explicitement une nouvelle instance de liste triée)." -#: library/stdtypes.rst:1224 +#: library/stdtypes.rst:1225 msgid "" "The :meth:`sort` method is guaranteed to be stable. A sort is stable if it " "guarantees not to change the relative order of elements that compare equal " @@ -2090,13 +2094,13 @@ msgstr "" "trier en plusieurs passes (par exemple, trier par département, puis par " "niveau de salaire)." -#: library/stdtypes.rst:1229 +#: library/stdtypes.rst:1230 msgid "" "For sorting examples and a brief sorting tutorial, see :ref:`sortinghowto`." msgstr "" "Pour des exemples de tris et un bref tutoriel, consultez :ref:`sortinghowto`." -#: library/stdtypes.rst:1233 +#: library/stdtypes.rst:1234 msgid "" "While a list is being sorted, the effect of attempting to mutate, or even " "inspect, the list is undefined. The C implementation of Python makes the " @@ -2108,11 +2112,11 @@ msgstr "" "liste comme vide pour la durée du traitement, et lève :exc:`ValueError` si " "elle détecte que la liste a été modifiée au cours du tri." -#: library/stdtypes.rst:1242 +#: library/stdtypes.rst:1243 msgid "Tuples" msgstr "Tuples" -#: library/stdtypes.rst:1246 +#: library/stdtypes.rst:1247 msgid "" "Tuples are immutable sequences, typically used to store collections of " "heterogeneous data (such as the 2-tuples produced by the :func:`enumerate` " @@ -2127,34 +2131,34 @@ msgstr "" "et immuable de données est nécessaire (pour, par exemple, les stocker dans " "un :class:`set` ou un :class:`dict`)." -#: library/stdtypes.rst:1254 +#: library/stdtypes.rst:1255 msgid "Tuples may be constructed in a number of ways:" msgstr "Les *n*-uplets peuvent être construits de différentes façons :" -#: library/stdtypes.rst:1256 +#: library/stdtypes.rst:1257 msgid "Using a pair of parentheses to denote the empty tuple: ``()``" msgstr "" "En utilisant une paire de parenthèses pour désigner le *n*-uplet vide : " "``()``" -#: library/stdtypes.rst:1257 +#: library/stdtypes.rst:1258 msgid "Using a trailing comma for a singleton tuple: ``a,`` or ``(a,)``" msgstr "" "En utilisant une virgule, pour créer un *n*-uplet d'un élément : ``a,`` ou " "``(a,)``" -#: library/stdtypes.rst:1258 +#: library/stdtypes.rst:1259 msgid "Separating items with commas: ``a, b, c`` or ``(a, b, c)``" msgstr "" "En séparant les éléments avec des virgules : ``a, b, c`` ou ``(a, b, c)``" -#: library/stdtypes.rst:1259 +#: library/stdtypes.rst:1260 msgid "Using the :func:`tuple` built-in: ``tuple()`` or ``tuple(iterable)``" msgstr "" "En utilisant la fonction native :func:`tuple` : ``tuple()`` ou " "``tuple(iterable)``" -#: library/stdtypes.rst:1261 +#: library/stdtypes.rst:1262 msgid "" "The constructor builds a tuple whose items are the same and in the same " "order as *iterable*'s items. *iterable* may be either a sequence, a " @@ -2172,7 +2176,7 @@ msgstr "" "3] )`` renvoie ``(1, 2, 3)``. Si aucun argument est donné, le constructeur " "crée un nouveau *n*-uplet vide, ``()``." -#: library/stdtypes.rst:1269 +#: library/stdtypes.rst:1270 msgid "" "Note that it is actually the comma which makes a tuple, not the parentheses. " "The parentheses are optional, except in the empty tuple case, or when they " @@ -2187,7 +2191,7 @@ msgstr "" "arguments, alors que ``f((a, b, c))`` est un appel de fonction avec un " "triplet comme unique argument." -#: library/stdtypes.rst:1275 +#: library/stdtypes.rst:1276 msgid "" "Tuples implement all of the :ref:`common ` sequence " "operations." @@ -2195,7 +2199,7 @@ msgstr "" "Les *n*-uplets implémentent toutes les opérations :ref:`communes ` des séquences." -#: library/stdtypes.rst:1278 +#: library/stdtypes.rst:1279 msgid "" "For heterogeneous collections of data where access by name is clearer than " "access by index, :func:`collections.namedtuple` may be a more appropriate " @@ -2205,11 +2209,11 @@ msgstr "" "clair que l'accès par index, :func:`collections.namedtuple` peut être un " "choix plus approprié qu'un simple *n*-uplet." -#: library/stdtypes.rst:1286 +#: library/stdtypes.rst:1287 msgid "Ranges" msgstr "*Ranges*" -#: library/stdtypes.rst:1290 +#: library/stdtypes.rst:1291 msgid "" "The :class:`range` type represents an immutable sequence of numbers and is " "commonly used for looping a specific number of times in :keyword:`for` loops." @@ -2218,7 +2222,7 @@ msgstr "" "couramment utilisé pour itérer un certain nombre de fois dans les boucles :" "keyword:`for`." -#: library/stdtypes.rst:1297 +#: library/stdtypes.rst:1298 msgid "" "The arguments to the range constructor must be integers (either built-in :" "class:`int` or any object that implements the ``__index__`` special " @@ -2232,7 +2236,7 @@ msgstr "" "valeur par défaut de l'argument *start* est ``0``. Si *step* est égal à " "zéro, une exception :exc:`ValueError` est levée." -#: library/stdtypes.rst:1303 +#: library/stdtypes.rst:1304 msgid "" "For a positive *step*, the contents of a range ``r`` are determined by the " "formula ``r[i] = start + step*i`` where ``i >= 0`` and ``r[i] < stop``." @@ -2240,7 +2244,7 @@ msgstr "" "Pour un *step* positif, le contenu d'un *range* ``r`` est déterminé par la " "formule ``r[i] = start + step*i`` où ``i >= 0`` et ``r[i] < stop``." -#: library/stdtypes.rst:1307 +#: library/stdtypes.rst:1308 msgid "" "For a negative *step*, the contents of the range are still determined by the " "formula ``r[i] = start + step*i``, but the constraints are ``i >= 0`` and " @@ -2250,7 +2254,7 @@ msgstr "" "formule ``r[i] = start + step*i``, mais les contraintes sont ``i >= 0`` et " "``r[i] > stop``." -#: library/stdtypes.rst:1311 +#: library/stdtypes.rst:1312 msgid "" "A range object will be empty if ``r[0]`` does not meet the value constraint. " "Ranges do support negative indices, but these are interpreted as indexing " @@ -2261,7 +2265,7 @@ msgstr "" "sont interprétées comme une indexation de la fin de la séquence déterminée " "par les indices positifs." -#: library/stdtypes.rst:1316 +#: library/stdtypes.rst:1317 msgid "" "Ranges containing absolute values larger than :data:`sys.maxsize` are " "permitted but some features (such as :func:`len`) may raise :exc:" @@ -2271,11 +2275,11 @@ msgstr "" "maxsize` sont permises, mais certaines fonctionnalités (comme :func:`len`) " "peuvent lever :exc:`OverflowError`." -#: library/stdtypes.rst:1320 +#: library/stdtypes.rst:1321 msgid "Range examples::" msgstr "Exemples avec *range* ::" -#: library/stdtypes.rst:1337 +#: library/stdtypes.rst:1338 msgid "" "Ranges implement all of the :ref:`common ` sequence " "operations except concatenation and repetition (due to the fact that range " @@ -2288,25 +2292,25 @@ msgstr "" "strict et que la répétition et la concaténation les feraient dévier de ce " "motif)." -#: library/stdtypes.rst:1344 +#: library/stdtypes.rst:1345 msgid "" "The value of the *start* parameter (or ``0`` if the parameter was not " "supplied)" msgstr "" "La valeur du paramètre *start* (ou ``0`` si le paramètre n'a pas été fourni)" -#: library/stdtypes.rst:1349 +#: library/stdtypes.rst:1350 msgid "The value of the *stop* parameter" msgstr "La valeur du paramètre *stop*" -#: library/stdtypes.rst:1353 +#: library/stdtypes.rst:1354 msgid "" "The value of the *step* parameter (or ``1`` if the parameter was not " "supplied)" msgstr "" "La valeur du paramètre *step* (ou ``1`` si le paramètre n'a pas été fourni)" -#: library/stdtypes.rst:1356 +#: library/stdtypes.rst:1357 msgid "" "The advantage of the :class:`range` type over a regular :class:`list` or :" "class:`tuple` is that a :class:`range` object will always take the same " @@ -2320,7 +2324,7 @@ msgstr "" "(car elle ne stocke que les valeurs ``start``, ``stop`` et ``step`` , le " "calcul des éléments individuels et les sous-intervalles au besoin)." -#: library/stdtypes.rst:1362 +#: library/stdtypes.rst:1363 msgid "" "Range objects implement the :class:`collections.abc.Sequence` ABC, and " "provide features such as containment tests, element index lookup, slicing " @@ -2331,7 +2335,7 @@ msgstr "" "(avec *in*), de recherche par index, le tranchage et ils gèrent les indices " "négatifs (voir :ref:`typesseq`):" -#: library/stdtypes.rst:1382 +#: library/stdtypes.rst:1383 msgid "" "Testing range objects for equality with ``==`` and ``!=`` compares them as " "sequences. That is, two range objects are considered equal if they " @@ -2347,7 +2351,7 @@ msgstr "" "et :attr:`~range.step` différents, par exemple ``range(0) == range(2, 1, " "3)`` ou ``range(0, 3, 2) == range(0, 4, 2)``.)" -#: library/stdtypes.rst:1389 +#: library/stdtypes.rst:1390 msgid "" "Implement the Sequence ABC. Support slicing and negative indices. Test :" "class:`int` objects for membership in constant time instead of iterating " @@ -2357,7 +2361,7 @@ msgstr "" "les indices négatifs. Tester l'appartenance d'un :class:`int` en temps " "constant au lieu d'itérer tous les éléments." -#: library/stdtypes.rst:1395 +#: library/stdtypes.rst:1396 msgid "" "Define '==' and '!=' to compare range objects based on the sequence of " "values they define (instead of comparing based on object identity)." @@ -2366,7 +2370,7 @@ msgstr "" "qu'ils définissent (au lieu d'une comparaison fondée sur l'identité de " "l'objet)." -#: library/stdtypes.rst:1400 +#: library/stdtypes.rst:1401 msgid "" "The :attr:`~range.start`, :attr:`~range.stop` and :attr:`~range.step` " "attributes." @@ -2374,7 +2378,7 @@ msgstr "" "Les attributs :attr:`~range.start`, :attr:`~range.stop` et :attr:`~range." "step`." -#: library/stdtypes.rst:1406 +#: library/stdtypes.rst:1407 msgid "" "The `linspace recipe `_ shows " "how to implement a lazy version of range suitable for floating point " @@ -2384,11 +2388,11 @@ msgstr "" "comment implémenter une version paresseuse de *range* adaptée aux nombres à " "virgule flottante." -#: library/stdtypes.rst:1418 +#: library/stdtypes.rst:1419 msgid "Text Sequence Type --- :class:`str`" msgstr "Type Séquence de Texte — :class:`str`" -#: library/stdtypes.rst:1420 +#: library/stdtypes.rst:1421 msgid "" "Textual data in Python is handled with :class:`str` objects, or :dfn:" "`strings`. Strings are immutable :ref:`sequences ` of Unicode code " @@ -2399,15 +2403,15 @@ msgstr "" "immuables de points de code Unicode. Les chaînes littérales peuvent être " "écrites de différentes manières :" -#: library/stdtypes.rst:1425 +#: library/stdtypes.rst:1426 msgid "Single quotes: ``'allows embedded \"double\" quotes'``" msgstr "Les guillemets simples : ``'autorisent les \"guillemets\"'``" -#: library/stdtypes.rst:1426 +#: library/stdtypes.rst:1427 msgid "Double quotes: ``\"allows embedded 'single' quotes\"``." msgstr "Les guillemets : ``\"autorisent les guillemets 'simples'\"``." -#: library/stdtypes.rst:1427 +#: library/stdtypes.rst:1428 msgid "" "Triple quoted: ``'''Three single quotes'''``, ``\"\"\"Three double quotes" "\"\"\"``" @@ -2415,7 +2419,7 @@ msgstr "" "Guillemets triples : ``'''Trois guillemets simples'''``, ``\"\"\"Trois " "guillemets\"\"\"``" -#: library/stdtypes.rst:1429 +#: library/stdtypes.rst:1430 msgid "" "Triple quoted strings may span multiple lines - all associated whitespace " "will be included in the string literal." @@ -2423,7 +2427,7 @@ msgstr "" "Les chaînes entre triple guillemets peuvent couvrir plusieurs lignes, tous " "les espaces associés seront inclus dans la chaîne littérale." -#: library/stdtypes.rst:1432 +#: library/stdtypes.rst:1433 msgid "" "String literals that are part of a single expression and have only " "whitespace between them will be implicitly converted to a single string " @@ -2433,7 +2437,7 @@ msgstr "" "seulement des espaces entre elles sont implicitement converties en une seule " "chaîne littérale. Autrement dit, ``(\"spam \" \"eggs\") == \"spam eggs\"``." -#: library/stdtypes.rst:1436 +#: library/stdtypes.rst:1437 msgid "" "See :ref:`strings` for more about the various forms of string literal, " "including supported escape sequences, and the ``r`` (\"raw\") prefix that " @@ -2444,7 +2448,7 @@ msgstr "" "et le préfixe ``r`` (*raw* (brut)) qui désactive la plupart des traitements " "de séquence d'échappement." -#: library/stdtypes.rst:1440 +#: library/stdtypes.rst:1441 msgid "" "Strings may also be created from other objects using the :class:`str` " "constructor." @@ -2452,7 +2456,7 @@ msgstr "" "Les chaînes peuvent également être créés à partir d'autres objets à l'aide " "du constructeur :class:`str`." -#: library/stdtypes.rst:1443 +#: library/stdtypes.rst:1444 msgid "" "Since there is no separate \"character\" type, indexing a string produces " "strings of length 1. That is, for a non-empty string *s*, ``s[0] == s[0:1]``." @@ -2461,7 +2465,7 @@ msgstr "" "produit des chaînes de longueur 1. Autrement dit, pour une chaîne non vide " "*s*, ``s[0] == s[0:1]``." -#: library/stdtypes.rst:1449 +#: library/stdtypes.rst:1450 msgid "" "There is also no mutable string type, but :meth:`str.join` or :class:`io." "StringIO` can be used to efficiently construct strings from multiple " @@ -2471,7 +2475,7 @@ msgstr "" "StringIO` peuvent être utilisées pour construire efficacement des chaînes à " "partir de plusieurs fragments." -#: library/stdtypes.rst:1453 +#: library/stdtypes.rst:1454 msgid "" "For backwards compatibility with the Python 2 series, the ``u`` prefix is " "once again permitted on string literals. It has no effect on the meaning of " @@ -2481,7 +2485,7 @@ msgstr "" "est à nouveau autorisé sur les chaînes littérales. Elle n'a aucun effet sur " "le sens des chaînes littérales et ne peut être combiné avec le préfixe ``r``." -#: library/stdtypes.rst:1465 +#: library/stdtypes.rst:1466 msgid "" "Return a :ref:`string ` version of *object*. If *object* is not " "provided, returns the empty string. Otherwise, the behavior of ``str()`` " @@ -2491,7 +2495,7 @@ msgstr "" "n'est pas fourni, renvoie une chaîne vide. Sinon, le comportement de " "``str()`` dépend de si *encoding* ou *errors* sont donnés, voir l'exemple." -#: library/stdtypes.rst:1469 +#: library/stdtypes.rst:1470 msgid "" "If neither *encoding* nor *errors* is given, ``str(object)`` returns :meth:" "`object.__str__() `, which is the \"informal\" or nicely " @@ -2505,7 +2509,7 @@ msgstr "" "chaîne elle-même. Si *object* n'a pas de méthode :meth:`~object.__str__`, :" "func:`str` utilise :meth:`repr(object) `." -#: library/stdtypes.rst:1480 +#: library/stdtypes.rst:1481 msgid "" "If at least one of *encoding* or *errors* is given, *object* should be a :" "term:`bytes-like object` (e.g. :class:`bytes` or :class:`bytearray`). In " @@ -2525,7 +2529,7 @@ msgstr "" "`binaryseq` et :ref:`bufferobjects` pour plus d'informations sur les " "*buffers*." -#: library/stdtypes.rst:1489 +#: library/stdtypes.rst:1490 msgid "" "Passing a :class:`bytes` object to :func:`str` without the *encoding* or " "*errors* arguments falls under the first case of returning the informal " @@ -2537,7 +2541,7 @@ msgstr "" "informelle de la chaîne est renvoyé (voir aussi l'option :option:`-b` de " "Python). Par exemple ::" -#: library/stdtypes.rst:1497 +#: library/stdtypes.rst:1498 msgid "" "For more information on the ``str`` class and its methods, see :ref:" "`textseq` and the :ref:`string-methods` section below. To output formatted " @@ -2549,11 +2553,11 @@ msgstr "" "de caractères, voir les sections :ref:`f-strings` et :ref:`formatstrings`. " "La section :ref:`stringservices` contient aussi des informations." -#: library/stdtypes.rst:1509 +#: library/stdtypes.rst:1510 msgid "String Methods" msgstr "Méthodes de chaînes de caractères" -#: library/stdtypes.rst:1514 +#: library/stdtypes.rst:1515 msgid "" "Strings implement all of the :ref:`common ` sequence " "operations, along with the additional methods described below." @@ -2561,7 +2565,7 @@ msgstr "" "Les chaînes implémentent toutes les opérations :ref:`communes des séquences " "`, ainsi que les autres méthodes décrites ci-dessous." -#: library/stdtypes.rst:1517 +#: library/stdtypes.rst:1518 msgid "" "Strings also support two styles of string formatting, one providing a large " "degree of flexibility and customization (see :meth:`str.format`, :ref:" @@ -2577,7 +2581,7 @@ msgstr "" "difficile à utiliser correctement, mais il est souvent plus rapide pour les " "cas, il peut gérer (:ref:`old-string-formatting`)." -#: library/stdtypes.rst:1524 +#: library/stdtypes.rst:1525 msgid "" "The :ref:`textservices` section of the standard library covers a number of " "other modules that provide various text related utilities (including regular " @@ -2587,7 +2591,7 @@ msgstr "" "nombre d'autres modules qui fournissent différents services relatifs au " "texte (y compris les expressions régulières dans le module :mod:`re`)." -#: library/stdtypes.rst:1530 +#: library/stdtypes.rst:1531 msgid "" "Return a copy of the string with its first character capitalized and the " "rest lowercased." @@ -2595,7 +2599,7 @@ msgstr "" "Renvoie une copie de la chaîne avec son premier caractère en majuscule et le " "reste en minuscule." -#: library/stdtypes.rst:1533 +#: library/stdtypes.rst:1534 msgid "" "The first character is now put into titlecase rather than uppercase. This " "means that characters like digraphs will only have their first letter " @@ -2605,7 +2609,7 @@ msgstr "" "majuscule. Cela veut dire que les caractères comme les digrammes auront " "seulement leur première lettre en majuscule, au lieu du caractère en entier." -#: library/stdtypes.rst:1540 +#: library/stdtypes.rst:1541 msgid "" "Return a casefolded copy of the string. Casefolded strings may be used for " "caseless matching." @@ -2613,7 +2617,7 @@ msgstr "" "Renvoie une copie *casefolded* de la chaîne. Les chaînes *casefolded* " "peuvent être utilisées dans des comparaison insensibles à la casse." -#: library/stdtypes.rst:1543 +#: library/stdtypes.rst:1544 msgid "" "Casefolding is similar to lowercasing but more aggressive because it is " "intended to remove all case distinctions in a string. For example, the " @@ -2627,7 +2631,7 @@ msgstr "" "Comme il est déjà minuscule, :meth:`lower` ferait rien à ``'ß'``; :meth:" "`casefold` le convertit en ``\"ss\"``." -#: library/stdtypes.rst:1549 +#: library/stdtypes.rst:1550 msgid "" "The casefolding algorithm is described in section 3.13 of the Unicode " "Standard." @@ -2635,7 +2639,7 @@ msgstr "" "L'algorithme de *casefolding* est décrit dans la section 3.13 de la norme " "Unicode." -#: library/stdtypes.rst:1557 +#: library/stdtypes.rst:1558 msgid "" "Return centered in a string of length *width*. Padding is done using the " "specified *fillchar* (default is an ASCII space). The original string is " @@ -2646,7 +2650,7 @@ msgstr "" "ASCII). La chaîne d'origine est renvoyée si *width* est inférieur ou égale à " "``len(s)``." -#: library/stdtypes.rst:1565 +#: library/stdtypes.rst:1566 msgid "" "Return the number of non-overlapping occurrences of substring *sub* in the " "range [*start*, *end*]. Optional arguments *start* and *end* are " @@ -2656,7 +2660,7 @@ msgstr "" "[*start*, *end*]. Les arguments facultatifs *start* et *end* sont " "interprétés comme pour des *slices*." -#: library/stdtypes.rst:1572 +#: library/stdtypes.rst:1573 msgid "" "Return an encoded version of the string as a bytes object. Default encoding " "is ``'utf-8'``. *errors* may be given to set a different error handling " @@ -2677,24 +2681,24 @@ msgstr "" "`error-handlers`. Pour une liste des encodages possibles, voir la section :" "ref:`standard-encodings`." -#: library/stdtypes.rst:1581 +#: library/stdtypes.rst:1582 msgid "" "By default, the *errors* argument is not checked for best performances, but " "only used at the first encoding error. Enable the :ref:`Python Development " "Mode `, or use a :ref:`debug build ` to check *errors*." msgstr "" -#: library/stdtypes.rst:1586 +#: library/stdtypes.rst:1587 msgid "Support for keyword arguments added." msgstr "Gestion des arguments par mot clef." -#: library/stdtypes.rst:2725 +#: library/stdtypes.rst:2726 msgid "" "The *errors* is now checked in development mode and in :ref:`debug mode " "`." msgstr "" -#: library/stdtypes.rst:1596 +#: library/stdtypes.rst:1597 msgid "" "Return ``True`` if the string ends with the specified *suffix*, otherwise " "return ``False``. *suffix* can also be a tuple of suffixes to look for. " @@ -2707,7 +2711,7 @@ msgstr "" "position. Si l'argument optionnel *end* est fourni, la comparaison s'arrête " "à cette position." -#: library/stdtypes.rst:1604 +#: library/stdtypes.rst:1605 msgid "" "Return a copy of the string where all tab characters are replaced by one or " "more spaces, depending on the current column and the given tab size. Tab " @@ -2737,7 +2741,7 @@ msgstr "" "et la colonne en cours est incrémentée de un indépendamment de la façon dont " "le caractère est représenté lors de l'affichage." -#: library/stdtypes.rst:1625 +#: library/stdtypes.rst:1626 msgid "" "Return the lowest index in the string where substring *sub* is found within " "the slice ``s[start:end]``. Optional arguments *start* and *end* are " @@ -2748,7 +2752,7 @@ msgstr "" "interprétés comme dans la notation des *slice*. Donne ``-1`` si *sub* n'est " "pas trouvé." -#: library/stdtypes.rst:1631 +#: library/stdtypes.rst:1632 msgid "" "The :meth:`~str.find` method should be used only if you need to know the " "position of *sub*. To check if *sub* is a substring or not, use the :" @@ -2758,7 +2762,7 @@ msgstr "" "de connaître la position de *sub*. Pour vérifier si *sub* est une sous " "chaine ou non, utilisez l'opérateur :keyword:`in` ::" -#: library/stdtypes.rst:1641 +#: library/stdtypes.rst:1642 msgid "" "Perform a string formatting operation. The string on which this method is " "called can contain literal text or replacement fields delimited by braces " @@ -2774,7 +2778,7 @@ msgstr "" "clé. Renvoie une copie de la chaîne où chaque champ de remplacement est " "remplacé par la valeur de chaîne de l'argument correspondant." -#: library/stdtypes.rst:1651 +#: library/stdtypes.rst:1652 msgid "" "See :ref:`formatstrings` for a description of the various formatting options " "that can be specified in format strings." @@ -2782,7 +2786,7 @@ msgstr "" "Voir :ref:`formatstrings` pour une description des options de formatage qui " "peuvent être spécifiées dans les chaînes de format." -#: library/stdtypes.rst:1655 +#: library/stdtypes.rst:1656 msgid "" "When formatting a number (:class:`int`, :class:`float`, :class:`complex`, :" "class:`decimal.Decimal` and subclasses) with the ``n`` type (ex: ``'{:n}'." @@ -2801,7 +2805,7 @@ msgstr "" "est différent de ``LC_CTYPE``. Ce changement temporaire affecte les autres " "fils d'exécution." -#: library/stdtypes.rst:1664 +#: library/stdtypes.rst:1665 msgid "" "When formatting a number with the ``n`` type, the function sets temporarily " "the ``LC_CTYPE`` locale to the ``LC_NUMERIC`` locale in some cases." @@ -2810,7 +2814,7 @@ msgstr "" "temporairement ``LC_CTYPE`` par la valeur de ``LC_NUMERIC`` dans certains " "cas." -#: library/stdtypes.rst:1672 +#: library/stdtypes.rst:1673 msgid "" "Similar to ``str.format(**mapping)``, except that ``mapping`` is used " "directly and not copied to a :class:`dict`. This is useful if for example " @@ -2820,7 +2824,7 @@ msgstr "" "directement et non copié dans un :class:`dict`. C'est utile si, par exemple " "``mapping`` est une sous-classe de ``dict`` :" -#: library/stdtypes.rst:1688 +#: library/stdtypes.rst:1689 msgid "" "Like :meth:`~str.find`, but raise :exc:`ValueError` when the substring is " "not found." @@ -2828,7 +2832,7 @@ msgstr "" "Comme :meth:`~str.find`, mais lève une :exc:`ValueError` lorsque la chaîne " "est introuvable." -#: library/stdtypes.rst:1694 +#: library/stdtypes.rst:1695 msgid "" "Return ``True`` if all characters in the string are alphanumeric and there " "is at least one character, ``False`` otherwise. A character ``c`` is " @@ -2840,7 +2844,7 @@ msgstr "" "alphanumérique si l'un des tests suivants renvoie ``True`` : ``c." "isalpha()``, ``c.isdecimal()``, ``c.isdigit()`` ou ``c.isnumeric()``." -#: library/stdtypes.rst:1702 +#: library/stdtypes.rst:1703 msgid "" "Return ``True`` if all characters in the string are alphabetic and there is " "at least one character, ``False`` otherwise. Alphabetic characters are " @@ -2856,7 +2860,7 @@ msgstr "" "\"Lu\", \"Ll\" ou \"Lo\" comme catégorie générale. Notez que ceci est " "différent de la propriété *Alphabetic* définie dans la norme Unicode." -#: library/stdtypes.rst:1711 +#: library/stdtypes.rst:1712 msgid "" "Return ``True`` if the string is empty or all characters in the string are " "ASCII, ``False`` otherwise. ASCII characters have code points in the range U" @@ -2866,7 +2870,7 @@ msgstr "" "ASCII, ``False`` sinon. Les caractères ASCII ont un code dans l'intervalle ``" "\"U+0000\"``\\ ---\\ ``\"U+007F\"``." -#: library/stdtypes.rst:1720 +#: library/stdtypes.rst:1721 msgid "" "Return ``True`` if all characters in the string are decimal characters and " "there is at least one character, ``False`` otherwise. Decimal characters are " @@ -2880,7 +2884,7 @@ msgstr "" "en base 10, tels que U+0660, ARABIC-INDIC DIGIT ZERO. Spécifiquement, un " "caractère décimal est un caractère dans la catégorie Unicode générale \"Nd\"." -#: library/stdtypes.rst:1730 +#: library/stdtypes.rst:1731 msgid "" "Return ``True`` if all characters in the string are digits and there is at " "least one character, ``False`` otherwise. Digits include decimal characters " @@ -2898,7 +2902,7 @@ msgstr "" "chiffre est un caractère dont la valeur de la propriété *Numeric_Type* est " "*Digit* ou *Decimal*." -#: library/stdtypes.rst:1740 +#: library/stdtypes.rst:1741 msgid "" "Return ``True`` if the string is a valid identifier according to the " "language definition, section :ref:`identifiers`." @@ -2906,7 +2910,7 @@ msgstr "" "Renvoie ``True`` si la chaîne est un identifiant valide selon la définition " "du langage, section :ref:`identifiers`." -#: library/stdtypes.rst:1743 +#: library/stdtypes.rst:1744 msgid "" "Call :func:`keyword.iskeyword` to test whether string ``s`` is a reserved " "identifier, such as :keyword:`def` and :keyword:`class`." @@ -2914,11 +2918,11 @@ msgstr "" "Utilisez :func:`keyword.iskeyword` pour savoir si la chaîne ``s`` est un " "identifiant réservé, tels que :keyword:`def` et :keyword:`class`." -#: library/stdtypes.rst:1746 +#: library/stdtypes.rst:1747 msgid "Example: ::" msgstr "Par exemple ::" -#: library/stdtypes.rst:1759 +#: library/stdtypes.rst:1760 msgid "" "Return ``True`` if all cased characters [4]_ in the string are lowercase and " "there is at least one cased character, ``False`` otherwise." @@ -2927,7 +2931,7 @@ msgstr "" "sont en minuscules et qu'elle contient au moins un caractère capitalisable. " "Renvoie ``False`` dans le cas contraire." -#: library/stdtypes.rst:1765 +#: library/stdtypes.rst:1766 msgid "" "Return ``True`` if all characters in the string are numeric characters, and " "there is at least one character, ``False`` otherwise. Numeric characters " @@ -2944,7 +2948,7 @@ msgstr "" "les priorités *Numeric_Type=Digit*, *Numeric_Type=Decimal*, ou " "*Numeric_Type=Numeric*." -#: library/stdtypes.rst:1775 +#: library/stdtypes.rst:1776 msgid "" "Return ``True`` if all characters in the string are printable or the string " "is empty, ``False`` otherwise. Nonprintable characters are those characters " @@ -2963,7 +2967,7 @@ msgstr "" "`repr` est invoquée sur une chaîne. Ça n'a aucune incidence sur le " "traitement des chaînes écrites sur :data:`sys.stdout` ou :data:`sys.stderr`.)" -#: library/stdtypes.rst:1786 +#: library/stdtypes.rst:1787 msgid "" "Return ``True`` if there are only whitespace characters in the string and " "there is at least one character, ``False`` otherwise." @@ -2972,7 +2976,7 @@ msgstr "" "et qu'il y a au moins un autre caractère. Renvoie ``False`` dans le cas " "contraire." -#: library/stdtypes.rst:1789 +#: library/stdtypes.rst:1790 msgid "" "A character is *whitespace* if in the Unicode character database (see :mod:" "`unicodedata`), either its general category is ``Zs`` (\"Separator, space" @@ -2983,7 +2987,7 @@ msgstr "" "`unicodedata`) sa catégorie générale est ``Zs`` (« séparateur, espace »), ou " "sa classe bidirectionnelle est une de ``WS``, ``B``, ou ``S``." -#: library/stdtypes.rst:1797 +#: library/stdtypes.rst:1798 msgid "" "Return ``True`` if the string is a titlecased string and there is at least " "one character, for example uppercase characters may only follow uncased " @@ -2996,7 +3000,7 @@ msgstr "" "minuscules ne peuvent suivre que des caractères capitalisables. Renvoie " "``False`` dans le cas contraire." -#: library/stdtypes.rst:1804 +#: library/stdtypes.rst:1805 msgid "" "Return ``True`` if all cased characters [4]_ in the string are uppercase and " "there is at least one cased character, ``False`` otherwise." @@ -3005,7 +3009,7 @@ msgstr "" "la chaîne sont en majuscules et il y a au moins un caractère différentiable " "sur la casse, sinon ``False``." -#: library/stdtypes.rst:1820 +#: library/stdtypes.rst:1821 msgid "" "Return a string which is the concatenation of the strings in *iterable*. A :" "exc:`TypeError` will be raised if there are any non-string values in " @@ -3017,7 +3021,7 @@ msgstr "" "pas une chaîne, y compris pour les objets :class:`bytes`. Le séparateur " "entre les éléments est la chaîne fournissant cette méthode." -#: library/stdtypes.rst:1828 +#: library/stdtypes.rst:1829 msgid "" "Return the string left justified in a string of length *width*. Padding is " "done using the specified *fillchar* (default is an ASCII space). The " @@ -3028,7 +3032,7 @@ msgstr "" "ASCII). La chaîne d'origine est renvoyée si *width* est inférieur ou égale à " "``len(s)``." -#: library/stdtypes.rst:1835 +#: library/stdtypes.rst:1836 msgid "" "Return a copy of the string with all the cased characters [4]_ converted to " "lowercase." @@ -3036,7 +3040,7 @@ msgstr "" "Renvoie une copie de la chaîne avec tous les caractères capitalisables [4]_ " "convertis en minuscules." -#: library/stdtypes.rst:1838 +#: library/stdtypes.rst:1839 msgid "" "The lowercasing algorithm used is described in section 3.13 of the Unicode " "Standard." @@ -3044,7 +3048,7 @@ msgstr "" "L'algorithme de mise en minuscules utilisé est décrit dans la section 3.13 " "de la norme Unicode." -#: library/stdtypes.rst:1844 +#: library/stdtypes.rst:1845 msgid "" "Return a copy of the string with leading characters removed. The *chars* " "argument is a string specifying the set of characters to be removed. If " @@ -3058,13 +3062,13 @@ msgstr "" "des espaces. L'argument *chars* n'est pas un préfixe, toutes les " "combinaisons de ses valeurs sont supprimées ::" -#: library/stdtypes.rst:1854 +#: library/stdtypes.rst:1855 msgid "" "See :meth:`str.removeprefix` for a method that will remove a single prefix " "string rather than all of a set of characters. For example::" msgstr "" -#: library/stdtypes.rst:1865 +#: library/stdtypes.rst:1866 msgid "" "This static method returns a translation table usable for :meth:`str." "translate`." @@ -3072,7 +3076,7 @@ msgstr "" "Cette méthode statique renvoie une table de traduction utilisable pour :meth:" "`str.translate`." -#: library/stdtypes.rst:1867 +#: library/stdtypes.rst:1868 msgid "" "If there is only one argument, it must be a dictionary mapping Unicode " "ordinals (integers) or characters (strings of length 1) to Unicode ordinals, " @@ -3083,7 +3087,7 @@ msgstr "" "correspondre des points de code Unicode (nombres entiers) ou des caractères " "(chaînes de longueur 1) à des points de code Unicode." -#: library/stdtypes.rst:1872 +#: library/stdtypes.rst:1873 msgid "" "If there are two arguments, they must be strings of equal length, and in the " "resulting dictionary, each character in x will be mapped to the character at " @@ -3096,7 +3100,7 @@ msgstr "" "argument est fourni, ce doit être une chaîne dont chaque caractère " "correspondra à ``None`` dans le résultat." -#: library/stdtypes.rst:1880 +#: library/stdtypes.rst:1881 msgid "" "Split the string at the first occurrence of *sep*, and return a 3-tuple " "containing the part before the separator, the separator itself, and the part " @@ -3108,7 +3112,7 @@ msgstr "" "partie après le séparateur. Si le séparateur n'est pas trouvé, le triplet " "contiendra la chaîne elle-même, suivie de deux chaînes vides." -#: library/stdtypes.rst:1888 +#: library/stdtypes.rst:1889 msgid "" "If the string starts with the *prefix* string, return " "``string[len(prefix):]``. Otherwise, return a copy of the original string::" @@ -3116,7 +3120,7 @@ msgstr "" "Si la chaîne de caractères commence par la chaîne *prefix*, renvoie " "``string[len(prefix):]``. Sinon, renvoie une copie de la chaîne originale ::" -#: library/stdtypes.rst:1902 +#: library/stdtypes.rst:1903 msgid "" "If the string ends with the *suffix* string and that *suffix* is not empty, " "return ``string[:-len(suffix)]``. Otherwise, return a copy of the original " @@ -3126,7 +3130,7 @@ msgstr "" "*suffix* n'est pas vide, renvoie ``string[:-len(suffix)]``. Sinon, renvoie " "une copie de la chaîne originale ::" -#: library/stdtypes.rst:1916 +#: library/stdtypes.rst:1917 msgid "" "Return a copy of the string with all occurrences of substring *old* replaced " "by *new*. If the optional argument *count* is given, only the first *count* " @@ -3136,7 +3140,7 @@ msgstr "" "chaîne *old* sont remplacés par *new*. Si l'argument optionnel *count* est " "donné, seules les *count* premières occurrences sont remplacées." -#: library/stdtypes.rst:1923 +#: library/stdtypes.rst:1924 msgid "" "Return the highest index in the string where substring *sub* is found, such " "that *sub* is contained within ``s[start:end]``. Optional arguments *start* " @@ -3147,7 +3151,7 @@ msgstr "" "arguments facultatifs *start* et *end* sont interprétés comme dans la " "notation des *slices*. Donne ``-1`` en cas d'échec." -#: library/stdtypes.rst:1930 +#: library/stdtypes.rst:1931 msgid "" "Like :meth:`rfind` but raises :exc:`ValueError` when the substring *sub* is " "not found." @@ -3155,7 +3159,7 @@ msgstr "" "Comme :meth:`rfind` mais lève une exception :exc:`ValueError` lorsque la " "sous-chaîne *sub* est introuvable." -#: library/stdtypes.rst:1936 +#: library/stdtypes.rst:1937 msgid "" "Return the string right justified in a string of length *width*. Padding is " "done using the specified *fillchar* (default is an ASCII space). The " @@ -3166,7 +3170,7 @@ msgstr "" "défaut est un espace ASCII). La chaîne d'origine est renvoyée si *width* est " "inférieure ou égale à ``len(s)``." -#: library/stdtypes.rst:1943 +#: library/stdtypes.rst:1944 msgid "" "Split the string at the last occurrence of *sep*, and return a 3-tuple " "containing the part before the separator, the separator itself, and the part " @@ -3178,7 +3182,7 @@ msgstr "" "partie après le séparateur. Si le séparateur n'est pas trouvé, le triplet " "contiendra deux chaînes vides, puis par la chaîne elle-même." -#: library/stdtypes.rst:1951 +#: library/stdtypes.rst:1952 msgid "" "Return a list of the words in the string, using *sep* as the delimiter " "string. If *maxsplit* is given, at most *maxsplit* splits are done, the " @@ -3193,7 +3197,7 @@ msgstr "" "par la droite, :meth:`rsplit` se comporte comme :meth:`split` qui est décrit " "en détail ci-dessous." -#: library/stdtypes.rst:1960 +#: library/stdtypes.rst:1961 msgid "" "Return a copy of the string with trailing characters removed. The *chars* " "argument is a string specifying the set of characters to be removed. If " @@ -3207,13 +3211,13 @@ msgstr "" "L'argument *chars* n'est pas un suffixe : toutes les combinaisons de ses " "valeurs sont retirées ::" -#: library/stdtypes.rst:1970 +#: library/stdtypes.rst:1971 msgid "" "See :meth:`str.removesuffix` for a method that will remove a single suffix " "string rather than all of a set of characters. For example::" msgstr "" -#: library/stdtypes.rst:1980 +#: library/stdtypes.rst:1981 msgid "" "Return a list of the words in the string, using *sep* as the delimiter " "string. If *maxsplit* is given, at most *maxsplit* splits are done (thus, " @@ -3227,7 +3231,7 @@ msgstr "" "+1``). Si *maxsplit* n'est pas fourni, ou vaut ``-1``, le nombre de découpes " "n'est pas limité (Toutes les découpes possibles sont faites)." -#: library/stdtypes.rst:1986 +#: library/stdtypes.rst:1987 msgid "" "If *sep* is given, consecutive delimiters are not grouped together and are " "deemed to delimit empty strings (for example, ``'1,,2'.split(',')`` returns " @@ -3241,15 +3245,15 @@ msgstr "" "(par exemple, ``'1<>2<>3'.split('<>')`` renvoie ``['1', '2', '3']``). " "Découper une chaîne vide en spécifiant *sep* donne ``['']``." -#: library/stdtypes.rst:2008 library/stdtypes.rst:2128 -#: library/stdtypes.rst:3041 library/stdtypes.rst:3148 -#: library/stdtypes.rst:3189 library/stdtypes.rst:3231 -#: library/stdtypes.rst:3263 library/stdtypes.rst:3313 -#: library/stdtypes.rst:3382 library/stdtypes.rst:3406 +#: library/stdtypes.rst:2009 library/stdtypes.rst:2129 +#: library/stdtypes.rst:3042 library/stdtypes.rst:3149 +#: library/stdtypes.rst:3190 library/stdtypes.rst:3232 +#: library/stdtypes.rst:3264 library/stdtypes.rst:3314 +#: library/stdtypes.rst:3383 library/stdtypes.rst:3407 msgid "For example::" msgstr "Par exemple ::" -#: library/stdtypes.rst:2001 +#: library/stdtypes.rst:2002 msgid "" "If *sep* is not specified or is ``None``, a different splitting algorithm is " "applied: runs of consecutive whitespace are regarded as a single separator, " @@ -3265,7 +3269,7 @@ msgstr "" "diviser une chaîne vide ou une chaîne composée d'espaces avec un séparateur " "``None`` renvoie ``[]``." -#: library/stdtypes.rst:2023 +#: library/stdtypes.rst:2024 msgid "" "Return a list of the lines in the string, breaking at line boundaries. Line " "breaks are not included in the resulting list unless *keepends* is given and " @@ -3275,7 +3279,7 @@ msgstr "" "niveau des limites des lignes. Les sauts de ligne ne sont pas inclus dans la " "liste des résultats, sauf si *keepends* est donné, et est vrai." -#: library/stdtypes.rst:2027 +#: library/stdtypes.rst:2028 msgid "" "This method splits on the following line boundaries. In particular, the " "boundaries are a superset of :term:`universal newlines`." @@ -3283,107 +3287,107 @@ msgstr "" "Cette méthode découpe sur les limites de ligne suivantes. Ces limites sont " "un sur ensemble de :term:`universal newlines`." -#: library/stdtypes.rst:2031 +#: library/stdtypes.rst:2032 msgid "Representation" msgstr "Représentation" -#: library/stdtypes.rst:2031 +#: library/stdtypes.rst:2032 msgid "Description" msgstr "Description" -#: library/stdtypes.rst:2033 +#: library/stdtypes.rst:2034 msgid "``\\n``" msgstr "``\\n``" -#: library/stdtypes.rst:2033 +#: library/stdtypes.rst:2034 msgid "Line Feed" msgstr "Saut de ligne" -#: library/stdtypes.rst:2035 +#: library/stdtypes.rst:2036 msgid "``\\r``" msgstr "``\\r``" -#: library/stdtypes.rst:2035 +#: library/stdtypes.rst:2036 msgid "Carriage Return" msgstr "Retour chariot" -#: library/stdtypes.rst:2037 +#: library/stdtypes.rst:2038 msgid "``\\r\\n``" msgstr "``\\r\\n``" -#: library/stdtypes.rst:2037 +#: library/stdtypes.rst:2038 msgid "Carriage Return + Line Feed" msgstr "Retour chariot + saut de ligne" -#: library/stdtypes.rst:2039 +#: library/stdtypes.rst:2040 msgid "``\\v`` or ``\\x0b``" msgstr "``\\v`` or ``\\x0b``" -#: library/stdtypes.rst:2039 +#: library/stdtypes.rst:2040 msgid "Line Tabulation" msgstr "Tabulation verticale" -#: library/stdtypes.rst:2041 +#: library/stdtypes.rst:2042 msgid "``\\f`` or ``\\x0c``" msgstr "``\\f`` or ``\\x0c``" -#: library/stdtypes.rst:2041 +#: library/stdtypes.rst:2042 msgid "Form Feed" msgstr "Saut de page" -#: library/stdtypes.rst:2043 +#: library/stdtypes.rst:2044 msgid "``\\x1c``" msgstr "``\\x1c``" -#: library/stdtypes.rst:2043 +#: library/stdtypes.rst:2044 msgid "File Separator" msgstr "Séparateur de fichiers" -#: library/stdtypes.rst:2045 +#: library/stdtypes.rst:2046 msgid "``\\x1d``" msgstr "``\\x1d``" -#: library/stdtypes.rst:2045 +#: library/stdtypes.rst:2046 msgid "Group Separator" msgstr "Séparateur de groupes" -#: library/stdtypes.rst:2047 +#: library/stdtypes.rst:2048 msgid "``\\x1e``" msgstr "``\\x1e``" -#: library/stdtypes.rst:2047 +#: library/stdtypes.rst:2048 msgid "Record Separator" msgstr "Séparateur d'enregistrements" -#: library/stdtypes.rst:2049 +#: library/stdtypes.rst:2050 msgid "``\\x85``" msgstr "``\\x85``" -#: library/stdtypes.rst:2049 +#: library/stdtypes.rst:2050 msgid "Next Line (C1 Control Code)" msgstr "Ligne suivante (code de contrôle *C1*)" -#: library/stdtypes.rst:2051 +#: library/stdtypes.rst:2052 msgid "``\\u2028``" msgstr "``\\u2028``" -#: library/stdtypes.rst:2051 +#: library/stdtypes.rst:2052 msgid "Line Separator" msgstr "Séparateur de ligne" -#: library/stdtypes.rst:2053 +#: library/stdtypes.rst:2054 msgid "``\\u2029``" msgstr "``\\u2029``" -#: library/stdtypes.rst:2053 +#: library/stdtypes.rst:2054 msgid "Paragraph Separator" msgstr "Séparateur de paragraphe" -#: library/stdtypes.rst:2058 +#: library/stdtypes.rst:2059 msgid "``\\v`` and ``\\f`` added to list of line boundaries." msgstr "``\\v`` et ``\\f`` ajoutés à la liste des limites de lignes." -#: library/stdtypes.rst:2067 +#: library/stdtypes.rst:2068 msgid "" "Unlike :meth:`~str.split` when a delimiter string *sep* is given, this " "method returns an empty list for the empty string, and a terminal line break " @@ -3393,11 +3397,11 @@ msgstr "" "renvoie une liste vide pour la chaîne vide, et un saut de ligne à la fin ne " "se traduit pas par une ligne supplémentaire ::" -#: library/stdtypes.rst:2076 +#: library/stdtypes.rst:2077 msgid "For comparison, ``split('\\n')`` gives::" msgstr "À titre de comparaison, ``split('\\n')`` donne ::" -#: library/stdtypes.rst:2086 +#: library/stdtypes.rst:2087 msgid "" "Return ``True`` if string starts with the *prefix*, otherwise return " "``False``. *prefix* can also be a tuple of prefixes to look for. With " @@ -3409,7 +3413,7 @@ msgstr "" "*start* est donné, la comparaison commence à cette position, et lorsque " "*end* est donné, la comparaison s'arrête à celle ci." -#: library/stdtypes.rst:2094 +#: library/stdtypes.rst:2095 msgid "" "Return a copy of the string with the leading and trailing characters " "removed. The *chars* argument is a string specifying the set of characters " @@ -3423,7 +3427,7 @@ msgstr "" "L'argument *chars* est pas un préfixe ni un suffixe, toutes les combinaisons " "de ses valeurs sont supprimées ::" -#: library/stdtypes.rst:2105 +#: library/stdtypes.rst:2106 msgid "" "The outermost leading and trailing *chars* argument values are stripped from " "the string. Characters are removed from the leading end until reaching a " @@ -3435,7 +3439,7 @@ msgstr "" "figurant pas dans le jeu de caractères dans *chars*. La même opération à " "lieu par la droite. Par exemple ::" -#: library/stdtypes.rst:2118 +#: library/stdtypes.rst:2119 msgid "" "Return a copy of the string with uppercase characters converted to lowercase " "and vice versa. Note that it is not necessarily true that ``s.swapcase()." @@ -3445,7 +3449,7 @@ msgstr "" "convertis en minuscules et vice versa. Notez qu'il est pas nécessairement " "vrai que ``s.swapcase().swapcase() == s``." -#: library/stdtypes.rst:2125 +#: library/stdtypes.rst:2126 msgid "" "Return a titlecased version of the string where words start with an " "uppercase character and the remaining characters are lowercase." @@ -3453,7 +3457,7 @@ msgstr "" "Renvoie une version en initiales majuscules de la chaîne où les mots " "commencent par une capitale et les caractères restants sont en minuscules." -#: library/stdtypes.rst:3350 +#: library/stdtypes.rst:3351 msgid "" "The algorithm uses a simple language-independent definition of a word as " "groups of consecutive letters. The definition works in many contexts but it " @@ -3466,14 +3470,14 @@ msgstr "" "apostrophes (typiquement de la forme possessive en Anglais) forment les " "limites de mot, ce qui n'est pas toujours le résultat souhaité ::" -#: library/stdtypes.rst:3358 +#: library/stdtypes.rst:3359 msgid "" "A workaround for apostrophes can be constructed using regular expressions::" msgstr "" "Une solution pour contourner le problème des apostrophes peut être obtenue " "en utilisant des expressions rationnelles ::" -#: library/stdtypes.rst:2155 +#: library/stdtypes.rst:2156 msgid "" "Return a copy of the string in which each character has been mapped through " "the given translation table. The table must be an object that implements " @@ -3493,7 +3497,7 @@ msgstr "" "pour supprimer le caractère de la chaîne de renvoyée soit lever une " "exception :exc:`LookupError` pour ne pas changer le caractère." -#: library/stdtypes.rst:2164 +#: library/stdtypes.rst:2165 msgid "" "You can use :meth:`str.maketrans` to create a translation map from character-" "to-character mappings in different formats." @@ -3501,7 +3505,7 @@ msgstr "" "Vous pouvez utiliser :meth:`str.maketrans` pour créer une table de " "correspondances de caractères dans différents formats." -#: library/stdtypes.rst:2167 +#: library/stdtypes.rst:2168 msgid "" "See also the :mod:`codecs` module for a more flexible approach to custom " "character mappings." @@ -3509,7 +3513,7 @@ msgstr "" "Voir aussi le module :mod:`codecs` pour une approche plus souple de " "changements de caractères par correspondance." -#: library/stdtypes.rst:2173 +#: library/stdtypes.rst:2174 msgid "" "Return a copy of the string with all the cased characters [4]_ converted to " "uppercase. Note that ``s.upper().isupper()`` might be ``False`` if ``s`` " @@ -3523,7 +3527,7 @@ msgstr "" "catégorie Unicode d'un caractère du résultat n'est pas \"Lu\" (*Letter*, " "*uppercase*), mais par exemple \"Lt\" (*Letter*, *titlecase*)." -#: library/stdtypes.rst:2179 +#: library/stdtypes.rst:2180 msgid "" "The uppercasing algorithm used is described in section 3.13 of the Unicode " "Standard." @@ -3531,7 +3535,7 @@ msgstr "" "L'algorithme de capitalisation utilisé est décrit dans la section 3.13 de la " "norme Unicode." -#: library/stdtypes.rst:2185 +#: library/stdtypes.rst:2186 msgid "" "Return a copy of the string left filled with ASCII ``'0'`` digits to make a " "string of length *width*. A leading sign prefix (``'+'``/``'-'``) is handled " @@ -3544,11 +3548,11 @@ msgstr "" "rembourrage *après* le caractère désigne plutôt qu'avant. La chaîne " "d'origine est renvoyée si *width* est inférieur ou égale à ``len(s)``." -#: library/stdtypes.rst:2203 +#: library/stdtypes.rst:2204 msgid "``printf``-style String Formatting" msgstr "Formatage de chaines à la ``printf``" -#: library/stdtypes.rst:2216 +#: library/stdtypes.rst:2217 msgid "" "The formatting operations described here exhibit a variety of quirks that " "lead to a number of common errors (such as failing to display tuples and " @@ -3566,7 +3570,7 @@ msgstr "" "ces alternatives apporte son lot d'avantages et inconvénients en matière de " "simplicité, de flexibilité et/ou de généralisation possible." -#: library/stdtypes.rst:2224 +#: library/stdtypes.rst:2225 msgid "" "String objects have one unique built-in operation: the ``%`` operator " "(modulo). This is also known as the string *formatting* or *interpolation* " @@ -3582,7 +3586,7 @@ msgstr "" "plusieurs éléments de *values*. L'effet est similaire à la fonction :c:func:" "`sprintf` du langage C." -#: library/stdtypes.rst:2230 +#: library/stdtypes.rst:2231 msgid "" "If *format* requires a single argument, *values* may be a single non-tuple " "object. [5]_ Otherwise, *values* must be a tuple with exactly the number of " @@ -3594,7 +3598,7 @@ msgstr "" "nombre d'éléments spécifiés par la chaîne de format, ou un seul objet de " "correspondances ( *mapping object*, par exemple, un dictionnaire)." -#: library/stdtypes.rst:3461 +#: library/stdtypes.rst:3462 msgid "" "A conversion specifier contains two or more characters and has the following " "components, which must occur in this order:" @@ -3602,11 +3606,11 @@ msgstr "" "Un indicateur de conversion contient deux ou plusieurs caractères et " "comporte les éléments suivants, qui doivent apparaître dans cet ordre :" -#: library/stdtypes.rst:3464 +#: library/stdtypes.rst:3465 msgid "The ``'%'`` character, which marks the start of the specifier." msgstr "Le caractère ``'%'``, qui marque le début du marqueur." -#: library/stdtypes.rst:3466 +#: library/stdtypes.rst:3467 msgid "" "Mapping key (optional), consisting of a parenthesised sequence of characters " "(for example, ``(somename)``)." @@ -3614,7 +3618,7 @@ msgstr "" "La clé de correspondance (facultative), composée d'une suite de caractères " "entre parenthèse (par exemple, ``(somename)``)." -#: library/stdtypes.rst:3469 +#: library/stdtypes.rst:3470 msgid "" "Conversion flags (optional), which affect the result of some conversion " "types." @@ -3622,7 +3626,7 @@ msgstr "" "Des options de conversion, facultatives, qui affectent le résultat de " "certains types de conversion." -#: library/stdtypes.rst:3472 +#: library/stdtypes.rst:3473 msgid "" "Minimum field width (optional). If specified as an ``'*'`` (asterisk), the " "actual width is read from the next element of the tuple in *values*, and the " @@ -3632,7 +3636,7 @@ msgstr "" "est lue de l'élément suivant du *n*-uplet *values*, et l'objet à convertir " "vient après la largeur de champ minimale et la précision facultative." -#: library/stdtypes.rst:3476 +#: library/stdtypes.rst:3477 msgid "" "Precision (optional), given as a ``'.'`` (dot) followed by the precision. " "If specified as ``'*'`` (an asterisk), the actual precision is read from the " @@ -3644,15 +3648,15 @@ msgstr "" "lue à partir de l'élément suivant du *n*-uplet *values* et la valeur à " "convertir vient ensuite." -#: library/stdtypes.rst:3481 +#: library/stdtypes.rst:3482 msgid "Length modifier (optional)." msgstr "Modificateur de longueur (facultatif)." -#: library/stdtypes.rst:3483 +#: library/stdtypes.rst:3484 msgid "Conversion type." msgstr "Type de conversion." -#: library/stdtypes.rst:2264 +#: library/stdtypes.rst:2265 msgid "" "When the right argument is a dictionary (or other mapping type), then the " "formats in the string *must* include a parenthesised mapping key into that " @@ -3665,7 +3669,7 @@ msgstr "" "caractère ``'%'``. La clé indique quelle valeur du dictionnaire doit être " "formatée. Par exemple :" -#: library/stdtypes.rst:3494 +#: library/stdtypes.rst:3495 msgid "" "In this case no ``*`` specifiers may occur in a format (since they require a " "sequential parameter list)." @@ -3673,36 +3677,36 @@ msgstr "" "Dans ce cas, aucune ``*`` ne peuvent se trouver dans le format (car ces " "``*`` nécessitent une liste (accès séquentiel) de paramètres)." -#: library/stdtypes.rst:3497 +#: library/stdtypes.rst:3498 msgid "The conversion flag characters are:" msgstr "Les caractères indicateurs de conversion sont :" -#: library/stdtypes.rst:3506 +#: library/stdtypes.rst:3507 msgid "Flag" msgstr "Option" -#: library/stdtypes.rst:3508 +#: library/stdtypes.rst:3509 msgid "``'#'``" msgstr "``'#'``" -#: library/stdtypes.rst:3508 +#: library/stdtypes.rst:3509 msgid "" "The value conversion will use the \"alternate form\" (where defined below)." msgstr "La conversion utilisera la \"forme alternative\" (définie ci-dessous)." -#: library/stdtypes.rst:3511 +#: library/stdtypes.rst:3512 msgid "``'0'``" msgstr "``'0'``" -#: library/stdtypes.rst:3511 +#: library/stdtypes.rst:3512 msgid "The conversion will be zero padded for numeric values." msgstr "Les valeurs numériques converties seront complétée de zéros." -#: library/stdtypes.rst:3513 +#: library/stdtypes.rst:3514 msgid "``'-'``" msgstr "``'-'``" -#: library/stdtypes.rst:3513 +#: library/stdtypes.rst:3514 msgid "" "The converted value is left adjusted (overrides the ``'0'`` conversion if " "both are given)." @@ -3710,11 +3714,11 @@ msgstr "" "La valeur convertie est ajustée à gauche (remplace la conversion ``'0'`` si " "les deux sont données)." -#: library/stdtypes.rst:3516 +#: library/stdtypes.rst:3517 msgid "``' '``" msgstr "``' '``" -#: library/stdtypes.rst:3516 +#: library/stdtypes.rst:3517 msgid "" "(a space) A blank should be left before a positive number (or empty string) " "produced by a signed conversion." @@ -3722,11 +3726,11 @@ msgstr "" "(un espace) Un espace doit être laissé avant un nombre positif (ou chaîne " "vide) produite par la conversion d'une valeur signée." -#: library/stdtypes.rst:3519 +#: library/stdtypes.rst:3520 msgid "``'+'``" msgstr "``'+'``" -#: library/stdtypes.rst:3519 +#: library/stdtypes.rst:3520 msgid "" "A sign character (``'+'`` or ``'-'``) will precede the conversion (overrides " "a \"space\" flag)." @@ -3734,7 +3738,7 @@ msgstr "" "Un caractère de signe (``'+'`` ou ``'-'``) précède la valeur convertie " "(remplace le marqueur \"espace\")." -#: library/stdtypes.rst:3523 +#: library/stdtypes.rst:3524 msgid "" "A length modifier (``h``, ``l``, or ``L``) may be present, but is ignored as " "it is not necessary for Python -- so e.g. ``%ld`` is identical to ``%d``." @@ -3743,91 +3747,91 @@ msgstr "" "est ignoré car il est pas nécessaire pour Python, donc par exemple ``%ld`` " "est identique à ``%d``." -#: library/stdtypes.rst:3526 +#: library/stdtypes.rst:3527 msgid "The conversion types are:" msgstr "Les types utilisables dans les conversion sont :" -#: library/stdtypes.rst:3529 +#: library/stdtypes.rst:3530 msgid "Conversion" msgstr "Conversion" -#: library/stdtypes.rst:3531 +#: library/stdtypes.rst:3532 msgid "``'d'``" msgstr "``'d'``" -#: library/stdtypes.rst:2312 library/stdtypes.rst:3533 +#: library/stdtypes.rst:2313 library/stdtypes.rst:3534 msgid "Signed integer decimal." msgstr "Entier décimal signé." -#: library/stdtypes.rst:3533 +#: library/stdtypes.rst:3534 msgid "``'i'``" msgstr "``'i'``" -#: library/stdtypes.rst:3535 +#: library/stdtypes.rst:3536 msgid "``'o'``" msgstr "``'o'``" -#: library/stdtypes.rst:3535 +#: library/stdtypes.rst:3536 msgid "Signed octal value." msgstr "Valeur octale signée." -#: library/stdtypes.rst:3537 +#: library/stdtypes.rst:3538 msgid "``'u'``" msgstr "``'u'``" -#: library/stdtypes.rst:3537 +#: library/stdtypes.rst:3538 msgid "Obsolete type -- it is identical to ``'d'``." msgstr "Type obsolète — identique à ``'d'``." -#: library/stdtypes.rst:3539 +#: library/stdtypes.rst:3540 msgid "``'x'``" msgstr "``'x'``" -#: library/stdtypes.rst:3539 +#: library/stdtypes.rst:3540 msgid "Signed hexadecimal (lowercase)." msgstr "Hexadécimal signé (en minuscules)." -#: library/stdtypes.rst:3541 +#: library/stdtypes.rst:3542 msgid "``'X'``" msgstr "``'X'``" -#: library/stdtypes.rst:3541 +#: library/stdtypes.rst:3542 msgid "Signed hexadecimal (uppercase)." msgstr "Hexadécimal signé (capitales)." -#: library/stdtypes.rst:3543 +#: library/stdtypes.rst:3544 msgid "``'e'``" msgstr "``'e'``" -#: library/stdtypes.rst:3543 +#: library/stdtypes.rst:3544 msgid "Floating point exponential format (lowercase)." msgstr "Format exponentiel pour un *float* (minuscule)." -#: library/stdtypes.rst:3545 +#: library/stdtypes.rst:3546 msgid "``'E'``" msgstr "``'E'``" -#: library/stdtypes.rst:3545 +#: library/stdtypes.rst:3546 msgid "Floating point exponential format (uppercase)." msgstr "Format exponentiel pour un *float* (en capitales)." -#: library/stdtypes.rst:3547 +#: library/stdtypes.rst:3548 msgid "``'f'``" msgstr "``'f'``" -#: library/stdtypes.rst:2328 library/stdtypes.rst:3549 +#: library/stdtypes.rst:2329 library/stdtypes.rst:3550 msgid "Floating point decimal format." msgstr "Format décimal pour un *float*." -#: library/stdtypes.rst:3549 +#: library/stdtypes.rst:3550 msgid "``'F'``" msgstr "``'F'``" -#: library/stdtypes.rst:3551 +#: library/stdtypes.rst:3552 msgid "``'g'``" msgstr "``'g'``" -#: library/stdtypes.rst:3551 +#: library/stdtypes.rst:3552 msgid "" "Floating point format. Uses lowercase exponential format if exponent is less " "than -4 or not less than precision, decimal format otherwise." @@ -3836,11 +3840,11 @@ msgstr "" "inférieur à ``-4`` ou pas plus petit que la précision, sinon le format " "décimal." -#: library/stdtypes.rst:3555 +#: library/stdtypes.rst:3556 msgid "``'G'``" msgstr "``'G'``" -#: library/stdtypes.rst:3555 +#: library/stdtypes.rst:3556 msgid "" "Floating point format. Uses uppercase exponential format if exponent is less " "than -4 or not less than precision, decimal format otherwise." @@ -3849,51 +3853,51 @@ msgstr "" "inférieur à ``-4`` ou pas plus petit que la précision, sinon le format " "décimal." -#: library/stdtypes.rst:3559 +#: library/stdtypes.rst:3560 msgid "``'c'``" msgstr "``'c'``" -#: library/stdtypes.rst:2338 +#: library/stdtypes.rst:2339 msgid "Single character (accepts integer or single character string)." msgstr "" "Un seul caractère (accepte des entiers ou une chaîne d'un seul caractère)." -#: library/stdtypes.rst:3572 +#: library/stdtypes.rst:3573 msgid "``'r'``" msgstr "``'r'``" -#: library/stdtypes.rst:2341 +#: library/stdtypes.rst:2342 msgid "String (converts any Python object using :func:`repr`)." msgstr "String (convertit n'importe quel objet Python avec :func:`repr`)." -#: library/stdtypes.rst:3566 +#: library/stdtypes.rst:3567 msgid "``'s'``" msgstr "``'s'``" -#: library/stdtypes.rst:2344 +#: library/stdtypes.rst:2345 msgid "String (converts any Python object using :func:`str`)." msgstr "String (convertit n'importe quel objet Python avec :func:`str`)." -#: library/stdtypes.rst:3569 +#: library/stdtypes.rst:3570 msgid "``'a'``" msgstr "``'a'``" -#: library/stdtypes.rst:2347 +#: library/stdtypes.rst:2348 msgid "String (converts any Python object using :func:`ascii`)." msgstr "" "String (convertit n'importe quel objet Python en utilisant :func:`ascii`)." -#: library/stdtypes.rst:3575 +#: library/stdtypes.rst:3576 msgid "``'%'``" msgstr "``'%'``" -#: library/stdtypes.rst:3575 +#: library/stdtypes.rst:3576 msgid "No argument is converted, results in a ``'%'`` character in the result." msgstr "" "Aucun argument n'est converti, donne un caractère de ``'%'`` dans le " "résultat." -#: library/stdtypes.rst:3582 +#: library/stdtypes.rst:3583 msgid "" "The alternate form causes a leading octal specifier (``'0o'``) to be " "inserted before the first digit." @@ -3901,7 +3905,7 @@ msgstr "" "La forme alternative entraîne l'insertion d'un préfixe octal (``'0o'``) " "avant le premier chiffre." -#: library/stdtypes.rst:3586 +#: library/stdtypes.rst:3587 msgid "" "The alternate form causes a leading ``'0x'`` or ``'0X'`` (depending on " "whether the ``'x'`` or ``'X'`` format was used) to be inserted before the " @@ -3911,7 +3915,7 @@ msgstr "" "(respectivement pour les formats ``'x'`` et ``'X'``) avant le premier " "chiffre." -#: library/stdtypes.rst:3590 +#: library/stdtypes.rst:3591 msgid "" "The alternate form causes the result to always contain a decimal point, even " "if no digits follow it." @@ -3919,14 +3923,14 @@ msgstr "" "La forme alternative implique la présence d'un point décimal, même si aucun " "chiffre ne le suit." -#: library/stdtypes.rst:3593 +#: library/stdtypes.rst:3594 msgid "" "The precision determines the number of digits after the decimal point and " "defaults to 6." msgstr "" "La précision détermine le nombre de chiffres après la virgule, 6 par défaut." -#: library/stdtypes.rst:3597 +#: library/stdtypes.rst:3598 msgid "" "The alternate form causes the result to always contain a decimal point, and " "trailing zeroes are not removed as they would otherwise be." @@ -3934,7 +3938,7 @@ msgstr "" "La forme alternative implique la présence d'un point décimal et les zéros " "non significatifs sont conservés (ils ne le seraient pas autrement)." -#: library/stdtypes.rst:3600 +#: library/stdtypes.rst:3601 msgid "" "The precision determines the number of significant digits before and after " "the decimal point and defaults to 6." @@ -3942,15 +3946,15 @@ msgstr "" "La précision détermine le nombre de chiffres significatifs avant et après la " "virgule. 6 par défaut." -#: library/stdtypes.rst:3604 +#: library/stdtypes.rst:3605 msgid "If precision is ``N``, the output is truncated to ``N`` characters." msgstr "Si la précision est ``N``, la sortie est tronquée à ``N`` caractères." -#: library/stdtypes.rst:3613 +#: library/stdtypes.rst:3614 msgid "See :pep:`237`." msgstr "Voir la :pep:`237`." -#: library/stdtypes.rst:2384 +#: library/stdtypes.rst:2385 msgid "" "Since Python strings have an explicit length, ``%s`` conversions do not " "assume that ``'\\0'`` is the end of the string." @@ -3958,7 +3962,7 @@ msgstr "" "Puisque les chaînes Python ont une longueur explicite, les conversions ``" "%s`` ne considèrent pas ``'\\0'`` comme la fin de la chaîne." -#: library/stdtypes.rst:2389 +#: library/stdtypes.rst:2390 msgid "" "``%f`` conversions for numbers whose absolute value is over 1e50 are no " "longer replaced by ``%g`` conversions." @@ -3966,7 +3970,7 @@ msgstr "" "Les conversions ``%f`` pour nombres dont la valeur absolue est supérieure à " "``1e50`` ne sont plus remplacés par des conversions ``%g``." -#: library/stdtypes.rst:2400 +#: library/stdtypes.rst:2401 msgid "" "Binary Sequence Types --- :class:`bytes`, :class:`bytearray`, :class:" "`memoryview`" @@ -3974,7 +3978,7 @@ msgstr "" "Séquences Binaires --- :class:`bytes`, :class:`bytearray`, :class:" "`memoryview`" -#: library/stdtypes.rst:2408 +#: library/stdtypes.rst:2409 msgid "" "The core built-in types for manipulating binary data are :class:`bytes` and :" "class:`bytearray`. They are supported by :class:`memoryview` which uses the :" @@ -3986,7 +3990,7 @@ msgstr "" "qui utilise le :ref:`buffer protocol ` pour accéder à la " "mémoire d'autres objets binaires sans avoir besoin d'en faire une copie." -#: library/stdtypes.rst:2413 +#: library/stdtypes.rst:2414 msgid "" "The :mod:`array` module supports efficient storage of basic data types like " "32-bit integers and IEEE754 double-precision floating values." @@ -3994,11 +3998,11 @@ msgstr "" "Le module :mod:`array` permet le stockage efficace de types basiques comme " "les entiers de 32 bits et les *float* double précision IEEE754." -#: library/stdtypes.rst:2419 +#: library/stdtypes.rst:2420 msgid "Bytes Objects" msgstr "Objets *bytes*" -#: library/stdtypes.rst:2423 +#: library/stdtypes.rst:2424 msgid "" "Bytes objects are immutable sequences of single bytes. Since many major " "binary protocols are based on the ASCII text encoding, bytes objects offer " @@ -4010,7 +4014,7 @@ msgstr "" "méthodes qui ne sont valables que lors de la manipulation de données ASCII " "et sont étroitement liés aux objets *str* dans bien d'autres aspects." -#: library/stdtypes.rst:2430 +#: library/stdtypes.rst:2431 msgid "" "Firstly, the syntax for bytes literals is largely the same as that for " "string literals, except that a ``b`` prefix is added:" @@ -4018,24 +4022,24 @@ msgstr "" "Tout d'abord, la syntaxe des *bytes* littéraux est en grande partie la même " "que pour les chaînes littérales, en dehors du préfixe ``b`` :" -#: library/stdtypes.rst:2433 +#: library/stdtypes.rst:2434 msgid "Single quotes: ``b'still allows embedded \"double\" quotes'``" msgstr "" "Les guillemets simples : ``b'autorisent aussi les guillemets \"doubles\"'``" -#: library/stdtypes.rst:2434 +#: library/stdtypes.rst:2435 msgid "Double quotes: ``b\"still allows embedded 'single' quotes\"``." msgstr "" "Les guillemets doubles : ``b\"permettent aussi les guillemets 'simples'\"``." -#: library/stdtypes.rst:2435 +#: library/stdtypes.rst:2436 msgid "" "Triple quoted: ``b'''3 single quotes'''``, ``b\"\"\"3 double quotes\"\"\"``" msgstr "" "Les guillemets triples : ``b'''3 single quotes'''``, ``b\"\"\"3 double quotes" "\"\"\"``" -#: library/stdtypes.rst:2437 +#: library/stdtypes.rst:2438 msgid "" "Only ASCII characters are permitted in bytes literals (regardless of the " "declared source code encoding). Any binary values over 127 must be entered " @@ -4046,7 +4050,7 @@ msgstr "" "delà de 127 doivent être entrées dans littéraux de *bytes* en utilisant une " "séquence d'échappement appropriée." -#: library/stdtypes.rst:2441 +#: library/stdtypes.rst:2442 msgid "" "As with string literals, bytes literals may also use a ``r`` prefix to " "disable processing of escape sequences. See :ref:`strings` for more about " @@ -4058,7 +4062,7 @@ msgstr "" "différentes formes littérales de *bytes*, y compris les séquences " "d'échappement supportées." -#: library/stdtypes.rst:2445 +#: library/stdtypes.rst:2446 msgid "" "While bytes literals and representations are based on ASCII text, bytes " "objects actually behave like immutable sequences of integers, with each " @@ -4081,7 +4085,7 @@ msgstr "" "sur des données binaires qui ne sont pas compatibles ASCII conduit " "généralement à leur corruption)." -#: library/stdtypes.rst:2455 +#: library/stdtypes.rst:2456 msgid "" "In addition to the literal forms, bytes objects can be created in a number " "of other ways:" @@ -4089,26 +4093,26 @@ msgstr "" "En plus des formes littérales, des objets *bytes* peuvent être créés par de " "nombreux moyens :" -#: library/stdtypes.rst:2458 +#: library/stdtypes.rst:2459 msgid "A zero-filled bytes object of a specified length: ``bytes(10)``" msgstr "" "Un objet *bytes* rempli de zéros d'une longueur spécifiée : ``bytes(10)``" -#: library/stdtypes.rst:2459 +#: library/stdtypes.rst:2460 msgid "From an iterable of integers: ``bytes(range(20))``" msgstr "D'un itérable d'entiers : ``bytes(range(20))``" -#: library/stdtypes.rst:2460 +#: library/stdtypes.rst:2461 msgid "Copying existing binary data via the buffer protocol: ``bytes(obj)``" msgstr "" "Copier des données binaires existantes via le *buffer protocol* : " "``bytes(obj)``" -#: library/stdtypes.rst:2462 +#: library/stdtypes.rst:2463 msgid "Also see the :ref:`bytes ` built-in." msgstr "Voir aussi la fonction native :ref:`bytes `." -#: library/stdtypes.rst:2464 +#: library/stdtypes.rst:2465 msgid "" "Since 2 hexadecimal digits correspond precisely to a single byte, " "hexadecimal numbers are a commonly used format for describing binary data. " @@ -4120,7 +4124,7 @@ msgstr "" "données binaires. Par conséquent, le type *bytes* a une méthode de classe " "pour lire des données dans ce format :" -#: library/stdtypes.rst:2470 +#: library/stdtypes.rst:2471 msgid "" "This :class:`bytes` class method returns a bytes object, decoding the given " "string object. The string must contain two hexadecimal digits per byte, " @@ -4130,7 +4134,7 @@ msgstr "" "la chaîne donnée. La chaîne doit contenir deux chiffres hexadécimaux par " "octet, les espaces ASCII sont ignorés." -#: library/stdtypes.rst:2477 +#: library/stdtypes.rst:2478 msgid "" ":meth:`bytes.fromhex` now skips all ASCII whitespace in the string, not just " "spaces." @@ -4138,7 +4142,7 @@ msgstr "" ":meth:`bytes.fromhex` saute maintenant dans la chaîne tous les caractères " "ASCII \"blancs\", pas seulement les espaces." -#: library/stdtypes.rst:2481 +#: library/stdtypes.rst:2482 msgid "" "A reverse conversion function exists to transform a bytes object into its " "hexadecimal representation." @@ -4146,7 +4150,7 @@ msgstr "" "Une fonction de conversion inverse existe pour transformer un objet *bytes* " "en sa représentation hexadécimale." -#: library/stdtypes.rst:2580 +#: library/stdtypes.rst:2581 msgid "" "Return a string object containing two hexadecimal digits for each byte in " "the instance." @@ -4154,7 +4158,7 @@ msgstr "" "Renvoie une chaîne contenant deux chiffres hexadécimaux pour chaque octet du " "*byte*." -#: library/stdtypes.rst:2492 +#: library/stdtypes.rst:2493 msgid "" "If you want to make the hex string easier to read, you can specify a single " "character separator *sep* parameter to include in the output. By default " @@ -4169,7 +4173,7 @@ msgstr "" "Les valeurs positives calculent la position du séparateur en partant de la " "droite, les valeurs négatives de la gauche." -#: library/stdtypes.rst:2508 +#: library/stdtypes.rst:2509 msgid "" ":meth:`bytes.hex` now supports optional *sep* and *bytes_per_sep* parameters " "to insert separators between bytes in the hex output." @@ -4178,7 +4182,7 @@ msgstr "" "et *bytes_per_sep* pour insérer des séparateurs entre les octets dans la " "sortie hexadécimale." -#: library/stdtypes.rst:2512 +#: library/stdtypes.rst:2513 msgid "" "Since bytes objects are sequences of integers (akin to a tuple), for a bytes " "object *b*, ``b[0]`` will be an integer, while ``b[0:1]`` will be a bytes " @@ -4190,7 +4194,7 @@ msgstr "" "que``b[0:1]`` sera un objet *bytes* de longueur 1. (Cela contraste avec les " "chaînes, où l'indexation et le *slicing* donne une chaîne de longueur 1)" -#: library/stdtypes.rst:2517 +#: library/stdtypes.rst:2518 msgid "" "The representation of bytes objects uses the literal format (``b'...'``) " "since it is often more useful than e.g. ``bytes([46, 46, 46])``. You can " @@ -4200,7 +4204,7 @@ msgstr "" "est souvent plus utile que par exemple ``bytes([46, 46, 46])``. Vous pouvez " "toujours convertir un *bytes* en liste d'entiers en utilisant ``list(b)``." -#: library/stdtypes.rst:2522 +#: library/stdtypes.rst:2523 msgid "" "For Python 2.x users: In the Python 2.x series, a variety of implicit " "conversions between 8-bit strings (the closest thing 2.x offers to a built-" @@ -4221,11 +4225,11 @@ msgstr "" "conversions entre les données binaires et texte Unicode doivent être " "explicites, et les *bytes* sont toujours différents des chaînes." -#: library/stdtypes.rst:2535 +#: library/stdtypes.rst:2536 msgid "Bytearray Objects" msgstr "Objets *bytearray*" -#: library/stdtypes.rst:2539 +#: library/stdtypes.rst:2540 msgid "" ":class:`bytearray` objects are a mutable counterpart to :class:`bytes` " "objects." @@ -4233,7 +4237,7 @@ msgstr "" "Les objets :class:`bytearray` sont l'équivalent muable des objets :class:" "`bytes`." -#: library/stdtypes.rst:2544 +#: library/stdtypes.rst:2545 msgid "" "There is no dedicated literal syntax for bytearray objects, instead they are " "always created by calling the constructor:" @@ -4241,27 +4245,27 @@ msgstr "" "Il n'y a pas de syntaxe littérale dédiée aux *bytearray*, ils sont toujours " "créés en appelant le constructeur :" -#: library/stdtypes.rst:2547 +#: library/stdtypes.rst:2548 msgid "Creating an empty instance: ``bytearray()``" msgstr "Créer une instance vide: ``bytearray()``" -#: library/stdtypes.rst:2548 +#: library/stdtypes.rst:2549 msgid "Creating a zero-filled instance with a given length: ``bytearray(10)``" msgstr "" "Créer une instance remplie de zéros d'une longueur donnée : ``bytearray(10)``" -#: library/stdtypes.rst:2549 +#: library/stdtypes.rst:2550 msgid "From an iterable of integers: ``bytearray(range(20))``" msgstr "À partir d'un itérable d'entiers : ``bytearray(range(20))``" -#: library/stdtypes.rst:2550 +#: library/stdtypes.rst:2551 msgid "" "Copying existing binary data via the buffer protocol: ``bytearray(b'Hi!')``" msgstr "" "Copie des données binaires existantes via le *buffer protocol* : " "``bytearray(b'Hi!')``" -#: library/stdtypes.rst:2552 +#: library/stdtypes.rst:2553 msgid "" "As bytearray objects are mutable, they support the :ref:`mutable ` sequence operations in addition to the common bytes and bytearray " @@ -4271,11 +4275,11 @@ msgstr "" "séquence :ref:`muables ` en plus des opérations communes " "de *bytes* et *bytearray* décrites dans :ref:`bytes-methods`." -#: library/stdtypes.rst:2556 +#: library/stdtypes.rst:2557 msgid "Also see the :ref:`bytearray ` built-in." msgstr "Voir aussi la fonction native :ref:`bytearray `." -#: library/stdtypes.rst:2558 +#: library/stdtypes.rst:2559 msgid "" "Since 2 hexadecimal digits correspond precisely to a single byte, " "hexadecimal numbers are a commonly used format for describing binary data. " @@ -4287,7 +4291,7 @@ msgstr "" "données binaires. Par conséquent, le type *bytearray* a une méthode de " "classe pour lire les données dans ce format :" -#: library/stdtypes.rst:2564 +#: library/stdtypes.rst:2565 msgid "" "This :class:`bytearray` class method returns bytearray object, decoding the " "given string object. The string must contain two hexadecimal digits per " @@ -4297,7 +4301,7 @@ msgstr "" "décodant la chaîne donnée. La chaîne doit contenir deux chiffres " "hexadécimaux par octet, les espaces ASCII sont ignorés." -#: library/stdtypes.rst:2571 +#: library/stdtypes.rst:2572 msgid "" ":meth:`bytearray.fromhex` now skips all ASCII whitespace in the string, not " "just spaces." @@ -4305,7 +4309,7 @@ msgstr "" ":meth:`bytearray.fromhex` saute maintenant tous les caractères \"blancs\" " "ASCII dans la chaîne, pas seulement les espaces." -#: library/stdtypes.rst:2575 +#: library/stdtypes.rst:2576 msgid "" "A reverse conversion function exists to transform a bytearray object into " "its hexadecimal representation." @@ -4313,7 +4317,7 @@ msgstr "" "Une fonction de conversion inverse existe pour transformer un objet " "*bytearray* en sa représentation hexadécimale." -#: library/stdtypes.rst:2588 +#: library/stdtypes.rst:2589 #, fuzzy msgid "" "Similar to :meth:`bytes.hex`, :meth:`bytearray.hex` now supports optional " @@ -4324,7 +4328,7 @@ msgstr "" "et *bytes_per_sep* pour insérer des séparateurs entre les octets dans la " "sortie hexadécimale." -#: library/stdtypes.rst:2593 +#: library/stdtypes.rst:2594 msgid "" "Since bytearray objects are sequences of integers (akin to a list), for a " "bytearray object *b*, ``b[0]`` will be an integer, while ``b[0:1]`` will be " @@ -4337,7 +4341,7 @@ msgstr "" "chaînes de texte, où l'indexation et le *slicing* produit une chaîne de " "longueur 1)" -#: library/stdtypes.rst:2598 +#: library/stdtypes.rst:2599 msgid "" "The representation of bytearray objects uses the bytes literal format " "(``bytearray(b'...')``) since it is often more useful than e.g. " @@ -4349,11 +4353,11 @@ msgstr "" "exemple ``bytearray([46, 46, 46])``. Vous pouvez toujours convertir un objet " "*bytearray* en une liste de nombres entiers en utilisant ``list(b)``." -#: library/stdtypes.rst:2607 +#: library/stdtypes.rst:2608 msgid "Bytes and Bytearray Operations" msgstr "Opérations sur les *bytes* et *bytearray*" -#: library/stdtypes.rst:2612 +#: library/stdtypes.rst:2613 msgid "" "Both bytes and bytearray objects support the :ref:`common ` " "sequence operations. They interoperate not just with operands of the same " @@ -4368,7 +4372,7 @@ msgstr "" "opérations sans provoquer d'erreurs. Cependant, le type du résultat peut " "dépendre de l'ordre des opérandes." -#: library/stdtypes.rst:2620 +#: library/stdtypes.rst:2621 msgid "" "The methods on bytes and bytearray objects don't accept strings as their " "arguments, just as the methods on strings don't accept bytes as their " @@ -4378,11 +4382,11 @@ msgstr "" "comme arguments, tout comme les méthodes sur les chaînes n'acceptent pas les " "*bytes* comme arguments. Par exemple, vous devez écrire ::" -#: library/stdtypes.rst:2627 +#: library/stdtypes.rst:2628 msgid "and::" msgstr "et ::" -#: library/stdtypes.rst:2632 +#: library/stdtypes.rst:2633 msgid "" "Some bytes and bytearray operations assume the use of ASCII compatible " "binary formats, and hence should be avoided when working with arbitrary " @@ -4393,7 +4397,7 @@ msgstr "" "travaillez avec des données binaires arbitraires. Ces restrictions sont " "couvertes ci-dessous." -#: library/stdtypes.rst:2637 +#: library/stdtypes.rst:2638 msgid "" "Using these ASCII based operations to manipulate binary data that is not " "stored in an ASCII based format may lead to data corruption." @@ -4401,7 +4405,7 @@ msgstr "" "Utiliser ces opérations basées sur l'ASCII pour manipuler des données " "binaires qui ne sont pas au format ASCII peut les corrompre." -#: library/stdtypes.rst:2640 +#: library/stdtypes.rst:2641 msgid "" "The following methods on bytes and bytearray objects can be used with " "arbitrary binary data." @@ -4409,7 +4413,7 @@ msgstr "" "Les méthodes suivantes sur les *bytes* et *bytearray* peuvent être utilisées " "avec des données binaires arbitraires." -#: library/stdtypes.rst:2646 +#: library/stdtypes.rst:2647 msgid "" "Return the number of non-overlapping occurrences of subsequence *sub* in the " "range [*start*, *end*]. Optional arguments *start* and *end* are " @@ -4419,8 +4423,8 @@ msgstr "" "séquence *sub* dans l'intervalle [*start*, *end*]. Les arguments facultatifs " "*start* et *end* sont interprétés comme pour un *slice*." -#: library/stdtypes.rst:2749 library/stdtypes.rst:2837 -#: library/stdtypes.rst:2850 +#: library/stdtypes.rst:2750 library/stdtypes.rst:2838 +#: library/stdtypes.rst:2851 msgid "" "The subsequence to search for may be any :term:`bytes-like object` or an " "integer in the range 0 to 255." @@ -4428,31 +4432,31 @@ msgstr "" "La sous-séquence à rechercher peut être un quelconque :term:`bytes-like " "object` ou un nombre entier compris entre 0 et 255." -#: library/stdtypes.rst:2761 library/stdtypes.rst:2840 -#: library/stdtypes.rst:2853 +#: library/stdtypes.rst:2762 library/stdtypes.rst:2841 +#: library/stdtypes.rst:2854 msgid "Also accept an integer in the range 0 to 255 as the subsequence." msgstr "" "Accepte aussi un nombre entier compris entre 0 et 255 comme sous-séquence." -#: library/stdtypes.rst:2660 +#: library/stdtypes.rst:2661 msgid "" "If the binary data starts with the *prefix* string, return " "``bytes[len(prefix):]``. Otherwise, return a copy of the original binary " "data::" msgstr "" -#: library/stdtypes.rst:2669 +#: library/stdtypes.rst:2670 #, fuzzy msgid "The *prefix* may be any :term:`bytes-like object`." msgstr "" "Le préfixe(s) à rechercher peuvent être n'importe quel :term:`bytes-like " "object`." -#: library/stdtypes.rst:2695 library/stdtypes.rst:2918 -#: library/stdtypes.rst:2963 library/stdtypes.rst:3019 -#: library/stdtypes.rst:3107 library/stdtypes.rst:3274 -#: library/stdtypes.rst:3372 library/stdtypes.rst:3415 -#: library/stdtypes.rst:3617 +#: library/stdtypes.rst:2696 library/stdtypes.rst:2919 +#: library/stdtypes.rst:2964 library/stdtypes.rst:3020 +#: library/stdtypes.rst:3108 library/stdtypes.rst:3275 +#: library/stdtypes.rst:3373 library/stdtypes.rst:3416 +#: library/stdtypes.rst:3618 msgid "" "The bytearray version of this method does *not* operate in place - it always " "produces a new object, even if no changes were made." @@ -4461,21 +4465,21 @@ msgstr "" "produit toujours un nouvel objet, même si aucune modification n'a été " "effectuée." -#: library/stdtypes.rst:2682 +#: library/stdtypes.rst:2683 msgid "" "If the binary data ends with the *suffix* string and that *suffix* is not " "empty, return ``bytes[:-len(suffix)]``. Otherwise, return a copy of the " "original binary data::" msgstr "" -#: library/stdtypes.rst:2691 +#: library/stdtypes.rst:2692 #, fuzzy msgid "The *suffix* may be any :term:`bytes-like object`." msgstr "" "Les suffixes à rechercher peuvent être n'importe quel :term:`bytes-like " "object`." -#: library/stdtypes.rst:2704 +#: library/stdtypes.rst:2705 msgid "" "Return a string decoded from the given bytes. Default encoding is " "``'utf-8'``. *errors* may be given to set a different error handling " @@ -4494,14 +4498,14 @@ msgstr "" "register_error`, voir la section :ref:`error-handlers`. Pour une liste des " "encodages possibles, voir la section :ref:`standard-encodings`." -#: library/stdtypes.rst:2712 +#: library/stdtypes.rst:2713 msgid "" "By default, the *errors* argument is not checked for best performances, but " "only used at the first decoding error. Enable the :ref:`Python Development " "Mode `, or use a :ref:`debug build ` to check *errors*." msgstr "" -#: library/stdtypes.rst:2718 +#: library/stdtypes.rst:2719 msgid "" "Passing the *encoding* argument to :class:`str` allows decoding any :term:" "`bytes-like object` directly, without needing to make a temporary bytes or " @@ -4511,11 +4515,11 @@ msgstr "" "`bytes-like object` directement, sans avoir besoin d'utiliser un *bytes* ou " "*bytearray* temporaire." -#: library/stdtypes.rst:2722 +#: library/stdtypes.rst:2723 msgid "Added support for keyword arguments." msgstr "Gère les arguments nommés." -#: library/stdtypes.rst:2733 +#: library/stdtypes.rst:2734 msgid "" "Return ``True`` if the binary data ends with the specified *suffix*, " "otherwise return ``False``. *suffix* can also be a tuple of suffixes to " @@ -4528,13 +4532,13 @@ msgstr "" "position. Avec l'argument optionnel *end*, la comparaison s'arrête à cette " "position." -#: library/stdtypes.rst:2738 +#: library/stdtypes.rst:2739 msgid "The suffix(es) to search for may be any :term:`bytes-like object`." msgstr "" "Les suffixes à rechercher peuvent être n'importe quel :term:`bytes-like " "object`." -#: library/stdtypes.rst:2744 +#: library/stdtypes.rst:2745 msgid "" "Return the lowest index in the data where the subsequence *sub* is found, " "such that *sub* is contained in the slice ``s[start:end]``. Optional " @@ -4546,7 +4550,7 @@ msgstr "" "facultatifs *start* et *end* sont interprétés comme dans la notation des " "*slices*. Donne ``-1`` si *sub* n'est pas trouvé." -#: library/stdtypes.rst:2754 +#: library/stdtypes.rst:2755 msgid "" "The :meth:`~bytes.find` method should be used only if you need to know the " "position of *sub*. To check if *sub* is a substring or not, use the :" @@ -4556,7 +4560,7 @@ msgstr "" "de connaître la position de *sub*. Pour vérifier si *sub* est présent ou " "non, utilisez l'opérateur :keyword:`in` ::" -#: library/stdtypes.rst:2768 +#: library/stdtypes.rst:2769 msgid "" "Like :meth:`~bytes.find`, but raise :exc:`ValueError` when the subsequence " "is not found." @@ -4564,7 +4568,7 @@ msgstr "" "Comme :meth:`~bytes.find`, mais lève une :exc:`ValueError` lorsque la " "séquence est introuvable." -#: library/stdtypes.rst:2781 +#: library/stdtypes.rst:2782 msgid "" "Return a bytes or bytearray object which is the concatenation of the binary " "data sequences in *iterable*. A :exc:`TypeError` will be raised if there " @@ -4580,7 +4584,7 @@ msgstr "" "éléments est le contenu du *bytes* ou du *bytearray* depuis lequel cette " "méthode est appelée." -#: library/stdtypes.rst:2792 +#: library/stdtypes.rst:2793 msgid "" "This static method returns a translation table usable for :meth:`bytes." "translate` that will map each character in *from* into the character at the " @@ -4593,7 +4597,7 @@ msgstr "" "être des :term:`bytes-like objects ` et avoir la même " "longueur." -#: library/stdtypes.rst:2803 +#: library/stdtypes.rst:2804 msgid "" "Split the sequence at the first occurrence of *sep*, and return a 3-tuple " "containing the part before the separator, the separator itself or its " @@ -4607,11 +4611,11 @@ msgstr "" "est pas trouvé, le triplet renvoyé contiendra une copie de la séquence " "d'origine, suivi de deux *bytes* ou *bytearray* vides." -#: library/stdtypes.rst:2867 +#: library/stdtypes.rst:2868 msgid "The separator to search for may be any :term:`bytes-like object`." msgstr "Le séparateur à rechercher peut être tout :term:`bytes-like object`." -#: library/stdtypes.rst:2816 +#: library/stdtypes.rst:2817 msgid "" "Return a copy of the sequence with all occurrences of subsequence *old* " "replaced by *new*. If the optional argument *count* is given, only the " @@ -4621,7 +4625,7 @@ msgstr "" "séquence *old* sont remplacées par *new*. Si l'argument optionnel *count* " "est donné, seules les *count* premières occurrences de sont remplacés." -#: library/stdtypes.rst:2820 +#: library/stdtypes.rst:2821 msgid "" "The subsequence to search for and its replacement may be any :term:`bytes-" "like object`." @@ -4629,7 +4633,7 @@ msgstr "" "La sous-séquence à rechercher et son remplacement peuvent être n'importe " "quel :term:`bytes-like object`." -#: library/stdtypes.rst:2832 +#: library/stdtypes.rst:2833 msgid "" "Return the highest index in the sequence where the subsequence *sub* is " "found, such that *sub* is contained within ``s[start:end]``. Optional " @@ -4641,7 +4645,7 @@ msgstr "" "sont interprétés comme dans la notation des *slices*. Donne ``-1`` si *sub* " "n'est pas trouvable." -#: library/stdtypes.rst:2847 +#: library/stdtypes.rst:2848 msgid "" "Like :meth:`~bytes.rfind` but raises :exc:`ValueError` when the subsequence " "*sub* is not found." @@ -4649,7 +4653,7 @@ msgstr "" "Semblable à :meth:`~bytes.rfind` mais lève une :exc:`ValueError` lorsque " "*sub* est introuvable." -#: library/stdtypes.rst:2860 +#: library/stdtypes.rst:2861 msgid "" "Split the sequence at the last occurrence of *sep*, and return a 3-tuple " "containing the part before the separator, the separator itself or its " @@ -4663,7 +4667,7 @@ msgstr "" "Si le séparateur n'est pas trouvé, le triplet contiendra deux *bytes* ou " "*bytesarray* vides suivi d’une copie de la séquence d'origine." -#: library/stdtypes.rst:2873 +#: library/stdtypes.rst:2874 msgid "" "Return ``True`` if the binary data starts with the specified *prefix*, " "otherwise return ``False``. *prefix* can also be a tuple of prefixes to " @@ -4675,13 +4679,13 @@ msgstr "" "rechercher. Avec l'argument *start* la recherche commence à cette position. " "Avec l'argument *end* option, la recherche s'arrête à cette position." -#: library/stdtypes.rst:2878 +#: library/stdtypes.rst:2879 msgid "The prefix(es) to search for may be any :term:`bytes-like object`." msgstr "" "Le préfixe(s) à rechercher peuvent être n'importe quel :term:`bytes-like " "object`." -#: library/stdtypes.rst:2884 +#: library/stdtypes.rst:2885 msgid "" "Return a copy of the bytes or bytearray object where all bytes occurring in " "the optional argument *delete* are removed, and the remaining bytes have " @@ -4692,25 +4696,25 @@ msgstr "" "*delete* sont supprimés, et les octets restants changés par la table de " "correspondance donnée, qui doit être un objet *bytes* d'une longueur de 256." -#: library/stdtypes.rst:2889 +#: library/stdtypes.rst:2890 msgid "" "You can use the :func:`bytes.maketrans` method to create a translation table." msgstr "" "Vous pouvez utiliser la méthode :func:`bytes.maketrans` pour créer une table " "de correspondance." -#: library/stdtypes.rst:2892 +#: library/stdtypes.rst:2893 msgid "" "Set the *table* argument to ``None`` for translations that only delete " "characters::" msgstr "" "Donnez ``None`` comme *table* pour seulement supprimer des caractères ::" -#: library/stdtypes.rst:2898 +#: library/stdtypes.rst:2899 msgid "*delete* is now supported as a keyword argument." msgstr "*delete* est maintenant accepté comme argument nommé." -#: library/stdtypes.rst:2902 +#: library/stdtypes.rst:2903 msgid "" "The following methods on bytes and bytearray objects have default behaviours " "that assume the use of ASCII compatible binary formats, but can still be " @@ -4724,7 +4728,7 @@ msgstr "" "appropriés. Notez que toutes les méthodes de *bytearray* de cette section " "ne travaillent jamais sur l'objet lui même, mais renvoient un nouvel objet." -#: library/stdtypes.rst:2911 +#: library/stdtypes.rst:2912 msgid "" "Return a copy of the object centered in a sequence of length *width*. " "Padding is done using the specified *fillbyte* (default is an ASCII space). " @@ -4736,7 +4740,7 @@ msgstr "" "espace ASCII). Pour les objets :class:`bytes`, la séquence initiale est " "renvoyée si *width* est inférieur ou égal à ``len(s)``." -#: library/stdtypes.rst:2925 +#: library/stdtypes.rst:2926 msgid "" "Return a copy of the object left justified in a sequence of length *width*. " "Padding is done using the specified *fillbyte* (default is an ASCII space). " @@ -4748,7 +4752,7 @@ msgstr "" "espace ASCII). Pour les objets :class:`bytes`, la séquence initiale est " "renvoyée si *width* est inférieure ou égale à ``len(s)``." -#: library/stdtypes.rst:2939 +#: library/stdtypes.rst:2940 msgid "" "Return a copy of the sequence with specified leading bytes removed. The " "*chars* argument is a binary sequence specifying the set of byte values to " @@ -4765,14 +4769,14 @@ msgstr "" "*chars* n’est pas un préfixe, toutes les combinaisons de ses valeurs sont " "supprimées ::" -#: library/stdtypes.rst:2951 +#: library/stdtypes.rst:2952 msgid "" "The binary sequence of byte values to remove may be any :term:`bytes-like " "object`. See :meth:`~bytes.removeprefix` for a method that will remove a " "single prefix string rather than all of a set of characters. For example::" msgstr "" -#: library/stdtypes.rst:2970 +#: library/stdtypes.rst:2971 msgid "" "Return a copy of the object right justified in a sequence of length *width*. " "Padding is done using the specified *fillbyte* (default is an ASCII space). " @@ -4784,7 +4788,7 @@ msgstr "" "défaut est un espace ASCII). Pour les objets :class:`bytes`, la séquence " "d'origine est renvoyée si *width* est inférieure ou égale à ``len(s)``." -#: library/stdtypes.rst:2984 +#: library/stdtypes.rst:2985 msgid "" "Split the binary sequence into subsequences of the same type, using *sep* as " "the delimiter string. If *maxsplit* is given, at most *maxsplit* splits are " @@ -4801,7 +4805,7 @@ msgstr "" "meth:`rsplit` se comporte comme :meth:`split` qui est décrit en détail ci-" "dessous." -#: library/stdtypes.rst:2995 +#: library/stdtypes.rst:2996 msgid "" "Return a copy of the sequence with specified trailing bytes removed. The " "*chars* argument is a binary sequence specifying the set of byte values to " @@ -4816,14 +4820,14 @@ msgstr "" "supprimés. L'argument *chars* n'est pas un suffixe : toutes les combinaisons " "de ses valeurs sont retirées ::" -#: library/stdtypes.rst:3007 +#: library/stdtypes.rst:3008 msgid "" "The binary sequence of byte values to remove may be any :term:`bytes-like " "object`. See :meth:`~bytes.removesuffix` for a method that will remove a " "single suffix string rather than all of a set of characters. For example::" msgstr "" -#: library/stdtypes.rst:3026 +#: library/stdtypes.rst:3027 msgid "" "Split the binary sequence into subsequences of the same type, using *sep* as " "the delimiter string. If *maxsplit* is given and non-negative, at most " @@ -4837,7 +4841,7 @@ msgstr "" "éléments), Si *maxsplit* n'est pas spécifié ou faut ``-1``, il n'y a aucune " "limite au nombre de découpes (elles sont toutes effectuées)." -#: library/stdtypes.rst:3032 +#: library/stdtypes.rst:3033 msgid "" "If *sep* is given, consecutive delimiters are not grouped together and are " "deemed to delimit empty subsequences (for example, ``b'1,,2'.split(b',')`` " @@ -4855,7 +4859,7 @@ msgstr "" "``[b'']`` ou ``[bytearray(b'')]`` en fonction du type de l'objet découpé. " "L'argument *sep* peut être n'importe quel :term:`bytes-like object`." -#: library/stdtypes.rst:3050 +#: library/stdtypes.rst:3051 msgid "" "If *sep* is not specified or is ``None``, a different splitting algorithm is " "applied: runs of consecutive ASCII whitespace are regarded as a single " @@ -4871,7 +4875,7 @@ msgstr "" "diviser une séquence vide ou une séquence composée d'espaces ASCII avec un " "séparateur ``None`` renvoie ``[]``." -#: library/stdtypes.rst:3071 +#: library/stdtypes.rst:3072 msgid "" "Return a copy of the sequence with specified leading and trailing bytes " "removed. The *chars* argument is a binary sequence specifying the set of " @@ -4887,14 +4891,14 @@ msgstr "" "espaces ASCII sont supprimés. L'argument *chars* n'est ni un préfixe ni un " "suffixe, toutes les combinaisons de ses valeurs sont supprimées ::" -#: library/stdtypes.rst:3084 +#: library/stdtypes.rst:3085 msgid "" "The binary sequence of byte values to remove may be any :term:`bytes-like " "object`." msgstr "" "La séquence de valeurs à supprimer peut être tout :term:`bytes-like object`." -#: library/stdtypes.rst:3093 +#: library/stdtypes.rst:3094 msgid "" "The following methods on bytes and bytearray objects assume the use of ASCII " "compatible binary formats and should not be applied to arbitrary binary " @@ -4907,7 +4911,7 @@ msgstr "" "que toutes les méthodes de *bytearray* de cette section *ne modifient pas* " "les octets, ils produisent de nouveaux objets." -#: library/stdtypes.rst:3101 +#: library/stdtypes.rst:3102 msgid "" "Return a copy of the sequence with each byte interpreted as an ASCII " "character, and the first byte capitalized and the rest lowercased. Non-ASCII " @@ -4917,7 +4921,7 @@ msgstr "" "caractère ASCII, le premier octet en capitale et le reste en minuscules. Les " "octets non ASCII ne sont pas modifiés." -#: library/stdtypes.rst:3114 +#: library/stdtypes.rst:3115 msgid "" "Return a copy of the sequence where all ASCII tab characters are replaced by " "one or more ASCII spaces, depending on the current column and the given tab " @@ -4948,7 +4952,7 @@ msgstr "" "cours est incrémentée de un indépendamment de la façon dont l'octet est " "représenté lors de l’affichage ::" -#: library/stdtypes.rst:3142 +#: library/stdtypes.rst:3143 msgid "" "Return ``True`` if all bytes in the sequence are alphabetical ASCII " "characters or ASCII decimal digits and the sequence is not empty, ``False`` " @@ -4963,7 +4967,7 @@ msgstr "" "``b'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ'`` et les " "chiffres : ``b'0123456789'``." -#: library/stdtypes.rst:3159 +#: library/stdtypes.rst:3160 msgid "" "Return ``True`` if all bytes in the sequence are alphabetic ASCII characters " "and the sequence is not empty, ``False`` otherwise. Alphabetic ASCII " @@ -4975,7 +4979,7 @@ msgstr "" "caractères ASCII alphabétiques sont : " "``b'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ'``." -#: library/stdtypes.rst:3175 +#: library/stdtypes.rst:3176 msgid "" "Return ``True`` if the sequence is empty or all bytes in the sequence are " "ASCII, ``False`` otherwise. ASCII bytes are in the range 0-0x7F." @@ -4984,7 +4988,7 @@ msgstr "" "octets ASCII, renvoie ``False`` dans le cas contraire. Les octets ASCII dans " "l'intervalle ``0``---``0x7F``." -#: library/stdtypes.rst:3185 +#: library/stdtypes.rst:3186 msgid "" "Return ``True`` if all bytes in the sequence are ASCII decimal digits and " "the sequence is not empty, ``False`` otherwise. ASCII decimal digits are " @@ -4994,7 +4998,7 @@ msgstr "" "et que la séquence n'est pas vide, sinon ``False``. Les chiffres ASCII sont " "ceux dans la séquence d'octets ``b'0123456789'``." -#: library/stdtypes.rst:3200 +#: library/stdtypes.rst:3201 msgid "" "Return ``True`` if there is at least one lowercase ASCII character in the " "sequence and no uppercase ASCII characters, ``False`` otherwise." @@ -5002,8 +5006,8 @@ msgstr "" "Renvoie ``True`` s'il y a au moins un caractère ASCII minuscule dans la " "séquence et aucune capitale, sinon ``False``." -#: library/stdtypes.rst:3252 library/stdtypes.rst:3318 -#: library/stdtypes.rst:3387 +#: library/stdtypes.rst:3253 library/stdtypes.rst:3319 +#: library/stdtypes.rst:3388 msgid "" "Lowercase ASCII characters are those byte values in the sequence " "``b'abcdefghijklmnopqrstuvwxyz'``. Uppercase ASCII characters are those byte " @@ -5012,7 +5016,7 @@ msgstr "" "Les caractères ASCII minuscules sont ``b'abcdefghijklmnopqrstuvwxyz'``. Les " "capitales ASCII sont ``b'ABCDEFGHIJKLMNOPQRSTUVWXYZ'``." -#: library/stdtypes.rst:3218 +#: library/stdtypes.rst:3219 msgid "" "Return ``True`` if all bytes in the sequence are ASCII whitespace and the " "sequence is not empty, ``False`` otherwise. ASCII whitespace characters are " @@ -5024,7 +5028,7 @@ msgstr "" "\\t\\n\\r\\x0b\\f'`` (espace, tabulation, saut de ligne, retour chariot, " "tabulation verticale, saut de page)." -#: library/stdtypes.rst:3227 +#: library/stdtypes.rst:3228 msgid "" "Return ``True`` if the sequence is ASCII titlecase and the sequence is not " "empty, ``False`` otherwise. See :meth:`bytes.title` for more details on the " @@ -5034,7 +5038,7 @@ msgstr "" "vide, sinon ``False``. Voir :meth:`bytes.title` pour plus de détails sur la " "définition de *titlecase*." -#: library/stdtypes.rst:3242 +#: library/stdtypes.rst:3243 msgid "" "Return ``True`` if there is at least one uppercase alphabetic ASCII " "character in the sequence and no lowercase ASCII characters, ``False`` " @@ -5043,7 +5047,7 @@ msgstr "" "Renvoie ``True`` s'il y a au moins un caractère alphabétique majuscule ASCII " "dans la séquence et aucun caractère ASCII minuscule, sinon ``False``." -#: library/stdtypes.rst:3260 +#: library/stdtypes.rst:3261 msgid "" "Return a copy of the sequence with all the uppercase ASCII characters " "converted to their corresponding lowercase counterpart." @@ -5051,7 +5055,7 @@ msgstr "" "Renvoie une copie de la séquence dont tous les caractères ASCII en " "majuscules sont convertis en leur équivalent en minuscules." -#: library/stdtypes.rst:3285 +#: library/stdtypes.rst:3286 msgid "" "Return a list of the lines in the binary sequence, breaking at ASCII line " "boundaries. This method uses the :term:`universal newlines` approach to " @@ -5063,7 +5067,7 @@ msgstr "" "newlines` pour découper les lignes. Les fins de ligne ne sont pas inclus " "dans la liste des résultats, sauf si *keepends* est donné et vrai." -#: library/stdtypes.rst:3297 +#: library/stdtypes.rst:3298 msgid "" "Unlike :meth:`~bytes.split` when a delimiter string *sep* is given, this " "method returns an empty list for the empty string, and a terminal line break " @@ -5073,7 +5077,7 @@ msgstr "" "cette méthode renvoie une liste vide pour la chaîne vide, et un saut de " "ligne à la fin ne se traduit pas par une ligne supplémentaire ::" -#: library/stdtypes.rst:3310 +#: library/stdtypes.rst:3311 msgid "" "Return a copy of the sequence with all the lowercase ASCII characters " "converted to their corresponding uppercase counterpart and vice-versa." @@ -5081,7 +5085,7 @@ msgstr "" "Renvoie une copie de la séquence dont tous les caractères ASCII minuscules " "sont convertis en majuscules et vice-versa." -#: library/stdtypes.rst:3322 +#: library/stdtypes.rst:3323 msgid "" "Unlike :func:`str.swapcase()`, it is always the case that ``bin.swapcase()." "swapcase() == bin`` for the binary versions. Case conversions are " @@ -5092,7 +5096,7 @@ msgstr "" "bin`` est toujours vrai. Les conversions majuscule/minuscule en ASCII étant " "toujours symétrique, ce qui n'est pas toujours vrai avec Unicode." -#: library/stdtypes.rst:3336 +#: library/stdtypes.rst:3337 msgid "" "Return a titlecased version of the binary sequence where words start with an " "uppercase ASCII character and the remaining characters are lowercase. " @@ -5102,7 +5106,7 @@ msgstr "" "commencent par un caractère ASCII majuscule et les caractères restants sont " "en minuscules. Les octets non capitalisables ne sont pas modifiés." -#: library/stdtypes.rst:3345 +#: library/stdtypes.rst:3346 msgid "" "Lowercase ASCII characters are those byte values in the sequence " "``b'abcdefghijklmnopqrstuvwxyz'``. Uppercase ASCII characters are those byte " @@ -5113,7 +5117,7 @@ msgstr "" "caractères ASCII majuscules sont ``b'ABCDEFGHIJKLMNOPQRSTUVWXYZ'``. Aucun " "autre octet n'est capitalisable." -#: library/stdtypes.rst:3379 +#: library/stdtypes.rst:3380 msgid "" "Return a copy of the sequence with all the lowercase ASCII characters " "converted to their corresponding uppercase counterpart." @@ -5121,7 +5125,7 @@ msgstr "" "Renvoie une copie de la séquence dont tous les caractères ASCII minuscules " "sont convertis en leur équivalent majuscule." -#: library/stdtypes.rst:3400 +#: library/stdtypes.rst:3401 msgid "" "Return a copy of the sequence left filled with ASCII ``b'0'`` digits to make " "a sequence of length *width*. A leading sign prefix (``b'+'``/ ``b'-'``) is " @@ -5136,11 +5140,11 @@ msgstr "" "séquence d'origine est renvoyée si *width* est inférieur ou égale à " "``len(seq)``." -#: library/stdtypes.rst:3422 +#: library/stdtypes.rst:3423 msgid "``printf``-style Bytes Formatting" msgstr "Formatage de *bytes* a la ``printf``" -#: library/stdtypes.rst:3439 +#: library/stdtypes.rst:3440 msgid "" "The formatting operations described here exhibit a variety of quirks that " "lead to a number of common errors (such as failing to display tuples and " @@ -5153,7 +5157,7 @@ msgstr "" "correctement). Si la valeur à afficher peut être un *n*-uplet ou un " "dictionnaire, mettez le a l'intérieur d'un autre *n*-uplet." -#: library/stdtypes.rst:3444 +#: library/stdtypes.rst:3445 msgid "" "Bytes objects (``bytes``/``bytearray``) have one unique built-in operation: " "the ``%`` operator (modulo). This is also known as the bytes *formatting* or " @@ -5169,7 +5173,7 @@ msgstr "" "plus de *values*. L'effet est similaire à la fonction :c:func:`sprintf` du " "langage C." -#: library/stdtypes.rst:3451 +#: library/stdtypes.rst:3452 msgid "" "If *format* requires a single argument, *values* may be a single non-tuple " "object. [5]_ Otherwise, *values* must be a tuple with exactly the number of " @@ -5181,7 +5185,7 @@ msgstr "" "nombre d'éléments spécifiés dans le format en *bytes*, ou un seul objet de " "correspondances ( *mapping object*, par exemple, un dictionnaire)." -#: library/stdtypes.rst:3485 +#: library/stdtypes.rst:3486 msgid "" "When the right argument is a dictionary (or other mapping type), then the " "formats in the bytes object *must* include a parenthesised mapping key into " @@ -5194,15 +5198,15 @@ msgstr "" "caractère ``'%'``. La clé indique quelle valeur du dictionnaire doit être " "formatée. Par exemple :" -#: library/stdtypes.rst:3559 +#: library/stdtypes.rst:3560 msgid "Single byte (accepts integer or single byte objects)." msgstr "Octet simple (Accepte un nombre entier ou un seul objet *byte*)." -#: library/stdtypes.rst:3562 +#: library/stdtypes.rst:3563 msgid "``'b'``" msgstr "``'b'``" -#: library/stdtypes.rst:3562 +#: library/stdtypes.rst:3563 msgid "" "Bytes (any object that follows the :ref:`buffer protocol ` or " "has :meth:`__bytes__`)." @@ -5210,7 +5214,7 @@ msgstr "" "*Bytes* (tout objet respectant le :ref:`buffer protocol ` ou " "ayant la méthode :meth:`__bytes__`)." -#: library/stdtypes.rst:3566 +#: library/stdtypes.rst:3567 msgid "" "``'s'`` is an alias for ``'b'`` and should only be used for Python2/3 code " "bases." @@ -5218,7 +5222,7 @@ msgstr "" "``'s'`` est un alias de ``'b'`` et ne devrait être utilisé que pour du code " "Python2/3." -#: library/stdtypes.rst:3569 +#: library/stdtypes.rst:3570 msgid "" "Bytes (converts any Python object using ``repr(obj)." "encode('ascii','backslashreplace)``)." @@ -5226,7 +5230,7 @@ msgstr "" "*Bytes* (convertis n'importe quel objet Python en utilisant ``repr(obj)." "encode('ascii', 'backslashreplace)``)." -#: library/stdtypes.rst:3572 +#: library/stdtypes.rst:3573 msgid "" "``'r'`` is an alias for ``'a'`` and should only be used for Python2/3 code " "bases." @@ -5234,27 +5238,27 @@ msgstr "" "``'r'`` est un alias de ``'a'`` et ne devrait être utilise que dans du code " "Python2/3." -#: library/stdtypes.rst:3572 +#: library/stdtypes.rst:3573 msgid "\\(7)" msgstr "\\(7)" -#: library/stdtypes.rst:3607 +#: library/stdtypes.rst:3608 msgid "``b'%s'`` is deprecated, but will not be removed during the 3.x series." msgstr "``b'%s'`` est obsolète, mais ne sera pas retiré des version 3.x." -#: library/stdtypes.rst:3610 +#: library/stdtypes.rst:3611 msgid "``b'%r'`` is deprecated, but will not be removed during the 3.x series." msgstr "``b'%r'`` est obsolète mais ne sera pas retiré dans Python 3.x." -#: library/stdtypes.rst:3622 +#: library/stdtypes.rst:3623 msgid ":pep:`461` - Adding % formatting to bytes and bytearray" msgstr ":pep:`461` -- Ajout du formatage via % aux *bytes* et *bytesarray*" -#: library/stdtypes.rst:3629 +#: library/stdtypes.rst:3630 msgid "Memory Views" msgstr "Vues de mémoires" -#: library/stdtypes.rst:3631 +#: library/stdtypes.rst:3632 msgid "" ":class:`memoryview` objects allow Python code to access the internal data of " "an object that supports the :ref:`buffer protocol ` without " @@ -5264,7 +5268,7 @@ msgstr "" "données internes d'un objet prenant en charge le :ref:`buffer protocol " "`." -#: library/stdtypes.rst:3637 +#: library/stdtypes.rst:3638 #, fuzzy msgid "" "Create a :class:`memoryview` that references *object*. *object* must " @@ -5275,7 +5279,7 @@ msgstr "" "le *buffer protocol*. Les objets natifs prenant en charge le *buffer " "protocol* sont :class:`bytes` et :class:`bytearray`." -#: library/stdtypes.rst:3641 +#: library/stdtypes.rst:3642 #, fuzzy msgid "" "A :class:`memoryview` has the notion of an *element*, which is the atomic " @@ -5289,7 +5293,7 @@ msgstr "" "d'autres types tels que :class:`array.array` les éléments peuvent être plus " "grands." -#: library/stdtypes.rst:3646 +#: library/stdtypes.rst:3647 msgid "" "``len(view)`` is equal to the length of :class:`~memoryview.tolist`. If " "``view.ndim = 0``, the length is 1. If ``view.ndim = 1``, the length is " @@ -5305,7 +5309,7 @@ msgstr "" "L'attribut :class:`~memoryview.itemsize` vous donnera la taille en octets " "d'un élément." -#: library/stdtypes.rst:3653 +#: library/stdtypes.rst:3654 msgid "" "A :class:`memoryview` supports slicing and indexing to expose its data. One-" "dimensional slicing will result in a subview::" @@ -5313,7 +5317,7 @@ msgstr "" "Une :class:`memoryview` autorise le découpage et l'indiçage de ses données. " "Découper sur une dimension donnera une sous-vue ::" -#: library/stdtypes.rst:3666 +#: library/stdtypes.rst:3667 msgid "" "If :class:`~memoryview.format` is one of the native format specifiers from " "the :mod:`struct` module, indexing with an integer or a tuple of integers is " @@ -5332,11 +5336,11 @@ msgstr "" "Les *memoryviews* à zéro dimension peuvent être indexées avec un *n*-uplet " "vide." -#: library/stdtypes.rst:3675 +#: library/stdtypes.rst:3676 msgid "Here is an example with a non-byte format::" msgstr "Voici un exemple avec un autre format que *byte* ::" -#: library/stdtypes.rst:3687 +#: library/stdtypes.rst:3688 msgid "" "If the underlying object is writable, the memoryview supports one-" "dimensional slice assignment. Resizing is not allowed::" @@ -5345,7 +5349,7 @@ msgstr "" "autorisera les assignations de tranches à une dimension. Redimensionner " "n'est cependant pas autorisé ::" -#: library/stdtypes.rst:3708 +#: library/stdtypes.rst:3709 msgid "" "One-dimensional memoryviews of hashable (read-only) types with formats 'B', " "'b' or 'c' are also hashable. The hash is defined as ``hash(m) == hash(m." @@ -5355,7 +5359,7 @@ msgstr "" "les formats 'B', 'b', ou 'c' sont aussi hachables. La fonction de hachage " "est définie tel que ``hash(m) == hash(m.tobytes())`` ::" -#: library/stdtypes.rst:3720 +#: library/stdtypes.rst:3721 msgid "" "One-dimensional memoryviews can now be sliced. One-dimensional memoryviews " "with formats 'B', 'b' or 'c' are now hashable." @@ -5364,7 +5368,7 @@ msgstr "" "*memoryviews* à une dimension avec les formats 'B', 'b', ou 'c' sont " "maintenant hachables." -#: library/stdtypes.rst:3724 +#: library/stdtypes.rst:3725 msgid "" "memoryview is now registered automatically with :class:`collections.abc." "Sequence`" @@ -5372,16 +5376,16 @@ msgstr "" "*memoryview* est maintenant enregistrée automatiquement avec :class:" "`collections.abc.Sequence`" -#: library/stdtypes.rst:3728 +#: library/stdtypes.rst:3729 msgid "memoryviews can now be indexed with tuple of integers." msgstr "" "les *memoryviews* peut maintenant être indexées par un *n*-uplet d'entiers." -#: library/stdtypes.rst:3731 +#: library/stdtypes.rst:3732 msgid ":class:`memoryview` has several methods:" msgstr "La :class:`memoryview` dispose de plusieurs méthodes :" -#: library/stdtypes.rst:3735 +#: library/stdtypes.rst:3736 msgid "" "A memoryview and a :pep:`3118` exporter are equal if their shapes are " "equivalent and if all corresponding values are equal when the operands' " @@ -5392,7 +5396,7 @@ msgstr "" "égales, le format respectifs des opérandes étant interprétés en utilisant la " "syntaxe de :mod:`struct`." -#: library/stdtypes.rst:3739 +#: library/stdtypes.rst:3740 msgid "" "For the subset of :mod:`struct` format strings currently supported by :meth:" "`tolist`, ``v`` and ``w`` are equal if ``v.tolist() == w.tolist()``::" @@ -5400,7 +5404,7 @@ msgstr "" "Pour le sous-ensemble des formats de :mod:`struct` supportés par :meth:" "`tolist`, ``v`` et ``w`` sont égaux si ``v.tolist() ==w.tolist()`` ::" -#: library/stdtypes.rst:3758 +#: library/stdtypes.rst:3759 msgid "" "If either format string is not supported by the :mod:`struct` module, then " "the objects will always compare as unequal (even if the format strings and " @@ -5410,7 +5414,7 @@ msgstr "" "objets seront toujours considérés différents (même si les formats et les " "valeurs contenues sont identiques) ::" -#: library/stdtypes.rst:3774 +#: library/stdtypes.rst:3775 msgid "" "Note that, as with floating point numbers, ``v is w`` does *not* imply ``v " "== w`` for memoryview objects." @@ -5418,7 +5422,7 @@ msgstr "" "Notez que pour les *memoryview*, comme pour les nombres à virgule flottante, " "``v is w`` *n'implique pas* ``v == w``." -#: library/stdtypes.rst:3777 +#: library/stdtypes.rst:3778 msgid "" "Previous versions compared the raw memory disregarding the item format and " "the logical array structure." @@ -5426,7 +5430,7 @@ msgstr "" "Les versions précédentes comparaient la mémoire brute sans tenir compte du " "format de l'objet ni de sa structure logique." -#: library/stdtypes.rst:3783 +#: library/stdtypes.rst:3784 msgid "" "Return the data in the buffer as a bytestring. This is equivalent to " "calling the :class:`bytes` constructor on the memoryview. ::" @@ -5434,7 +5438,7 @@ msgstr "" "Renvoie les données du *buffer* sous forme de *bytes*. Cela équivaut à " "appeler le constructeur :class:`bytes` sur le *memoryview*. ::" -#: library/stdtypes.rst:3792 +#: library/stdtypes.rst:3793 msgid "" "For non-contiguous arrays the result is equal to the flattened list " "representation with all elements converted to bytes. :meth:`tobytes` " @@ -5446,7 +5450,7 @@ msgstr "" "`tobytes` supporte toutes les chaînes de format, y compris celles qui ne " "sont pas connues du module :mod:`struct`." -#: library/stdtypes.rst:3797 +#: library/stdtypes.rst:3798 msgid "" "*order* can be {'C', 'F', 'A'}. When *order* is 'C' or 'F', the data of the " "original array is converted to C or Fortran order. For contiguous views, 'A' " @@ -5461,7 +5465,7 @@ msgstr "" "contiguës, les données sont d'abord converties en C. `order=None` est " "identique à `order='C'`." -#: library/stdtypes.rst:3806 +#: library/stdtypes.rst:3807 msgid "" "Return a string object containing two hexadecimal digits for each byte in " "the buffer. ::" @@ -5469,7 +5473,7 @@ msgstr "" "Renvoie une chaîne contenant deux chiffres hexadécimaux pour chaque octet de " "la mémoire. ::" -#: library/stdtypes.rst:3815 +#: library/stdtypes.rst:3816 #, fuzzy msgid "" "Similar to :meth:`bytes.hex`, :meth:`memoryview.hex` now supports optional " @@ -5480,12 +5484,12 @@ msgstr "" "et *bytes_per_sep* pour insérer des séparateurs entre les octets dans la " "sortie hexadécimale." -#: library/stdtypes.rst:3822 +#: library/stdtypes.rst:3823 msgid "Return the data in the buffer as a list of elements. ::" msgstr "" "Renvoie les données de la mémoire sous la forme d'une liste d'éléments. ::" -#: library/stdtypes.rst:3832 +#: library/stdtypes.rst:3833 msgid "" ":meth:`tolist` now supports all single character native formats in :mod:" "`struct` module syntax as well as multi-dimensional representations." @@ -5493,7 +5497,7 @@ msgstr "" ":meth:`tolist` prend désormais en charge tous les formats d'un caractère du " "module :mod:`struct` ainsi que des représentations multidimensionnelles." -#: library/stdtypes.rst:3839 +#: library/stdtypes.rst:3840 msgid "" "Return a readonly version of the memoryview object. The original memoryview " "object is unchanged. ::" @@ -5501,7 +5505,7 @@ msgstr "" "Renvoie une version en lecture seule de l'objet *memoryview*. Cet objet " "original *memoryview* est inchangé. ::" -#: library/stdtypes.rst:3858 +#: library/stdtypes.rst:3859 msgid "" "Release the underlying buffer exposed by the memoryview object. Many " "objects take special actions when a view is held on them (for example, a :" @@ -5516,7 +5520,7 @@ msgstr "" "lever ces restrictions (et en libérer les ressources liées) aussi tôt que " "possible." -#: library/stdtypes.rst:3864 +#: library/stdtypes.rst:3865 msgid "" "After this method has been called, any further operation on the view raises " "a :class:`ValueError` (except :meth:`release()` itself which can be called " @@ -5526,7 +5530,7 @@ msgstr "" "*view* lève une :class:`ValueError` (sauf :meth:`release()` elle-même qui " "peut être appelée plusieurs fois) ::" -#: library/stdtypes.rst:3875 +#: library/stdtypes.rst:3876 msgid "" "The context management protocol can be used for a similar effect, using the " "``with`` statement::" @@ -5534,7 +5538,7 @@ msgstr "" "Le protocole de gestion de contexte peut être utilisé pour obtenir un effet " "similaire, via l'instruction ``with`` ::" -#: library/stdtypes.rst:3891 +#: library/stdtypes.rst:3892 msgid "" "Cast a memoryview to a new format or shape. *shape* defaults to " "``[byte_length//new_itemsize]``, which means that the result view will be " @@ -5548,7 +5552,7 @@ msgstr "" "mais la mémoire elle-même n'est pas copiée. Les changements supportés sont " "une dimension vers C-:term:`contiguous` et *C-contiguous* vers une dimension." -#: library/stdtypes.rst:3897 +#: library/stdtypes.rst:3898 msgid "" "The destination format is restricted to a single element native format in :" "mod:`struct` syntax. One of the formats must be a byte format ('B', 'b' or " @@ -5559,37 +5563,37 @@ msgstr "" "'c'). La longueur du résultat en octets doit être la même que la longueur " "initiale." -#: library/stdtypes.rst:3902 +#: library/stdtypes.rst:3903 msgid "Cast 1D/long to 1D/unsigned bytes::" msgstr "Transforme *1D/long* en *1D/unsigned bytes* ::" -#: library/stdtypes.rst:3925 +#: library/stdtypes.rst:3926 msgid "Cast 1D/unsigned bytes to 1D/char::" msgstr "Transforme *1D/unsigned bytes* en *1D/char* ::" -#: library/stdtypes.rst:3938 +#: library/stdtypes.rst:3939 msgid "Cast 1D/bytes to 3D/ints to 1D/signed char::" msgstr "Transforme *1D/bytes* en *3D/ints* en *1D/signed char* ::" -#: library/stdtypes.rst:3964 +#: library/stdtypes.rst:3965 msgid "Cast 1D/unsigned long to 2D/unsigned long::" msgstr "Transforme *1D/unsigned char* en *2D/unsigned long* ::" -#: library/stdtypes.rst:3978 +#: library/stdtypes.rst:3979 msgid "The source format is no longer restricted when casting to a byte view." msgstr "" "Le format de la source n'est plus restreint lors de la transformation vers " "une vue d'octets." -#: library/stdtypes.rst:3981 +#: library/stdtypes.rst:3982 msgid "There are also several readonly attributes available:" msgstr "Plusieurs attributs en lecture seule sont également disponibles :" -#: library/stdtypes.rst:3985 +#: library/stdtypes.rst:3986 msgid "The underlying object of the memoryview::" msgstr "L'objet sous-jacent de la *memoryview* ::" -#: library/stdtypes.rst:3996 +#: library/stdtypes.rst:3997 msgid "" "``nbytes == product(shape) * itemsize == len(m.tobytes())``. This is the " "amount of space in bytes that the array would use in a contiguous " @@ -5599,15 +5603,15 @@ msgstr "" "l'espace que la liste utiliserait en octets, dans une représentation " "contiguë. Ce n'est pas nécessairement égale à ``len(m)`` ::" -#: library/stdtypes.rst:4015 +#: library/stdtypes.rst:4016 msgid "Multi-dimensional arrays::" msgstr "Tableaux multidimensionnels ::" -#: library/stdtypes.rst:4032 +#: library/stdtypes.rst:4033 msgid "A bool indicating whether the memory is read only." msgstr "Un booléen indiquant si la mémoire est en lecture seule." -#: library/stdtypes.rst:4036 +#: library/stdtypes.rst:4037 msgid "" "A string containing the format (in :mod:`struct` module style) for each " "element in the view. A memoryview can be created from exporters with " @@ -5619,7 +5623,7 @@ msgstr "" "de formats arbitraires, mais certaines méthodes (comme :meth:`tolist`) sont " "limitées aux formats natifs à un seul élément." -#: library/stdtypes.rst:4041 +#: library/stdtypes.rst:4042 msgid "" "format ``'B'`` is now handled according to the struct module syntax. This " "means that ``memoryview(b'abc')[0] == b'abc'[0] == 97``." @@ -5627,11 +5631,11 @@ msgstr "" "le format ``'B'`` est maintenant traité selon la syntaxe du module *struct*. " "Cela signifie que ``memoryview(b'abc')[0] == b'abc'[0] == 97``." -#: library/stdtypes.rst:4047 +#: library/stdtypes.rst:4048 msgid "The size in bytes of each element of the memoryview::" msgstr "La taille en octets de chaque élément d'une *memoryview* ::" -#: library/stdtypes.rst:4060 +#: library/stdtypes.rst:4061 msgid "" "An integer indicating how many dimensions of a multi-dimensional array the " "memory represents." @@ -5639,7 +5643,7 @@ msgstr "" "Un nombre entier indiquant le nombre de dimensions d'un tableau multi-" "dimensionnel représenté par la *memoryview*." -#: library/stdtypes.rst:4065 +#: library/stdtypes.rst:4066 msgid "" "A tuple of integers the length of :attr:`ndim` giving the shape of the " "memory as an N-dimensional array." @@ -5647,11 +5651,11 @@ msgstr "" "Un *n*-uplet d'entiers de longueur :attr:`ndim` donnant la forme de la " "*memoryview* sous forme d'un tableau à N dimensions." -#: library/stdtypes.rst:4076 +#: library/stdtypes.rst:4077 msgid "An empty tuple instead of ``None`` when ndim = 0." msgstr "Un *n*-uplet vide au lieu de ``None`` lorsque *ndim = 0*." -#: library/stdtypes.rst:4073 +#: library/stdtypes.rst:4074 msgid "" "A tuple of integers the length of :attr:`ndim` giving the size in bytes to " "access each element for each dimension of the array." @@ -5659,29 +5663,29 @@ msgstr "" "Un *n*-uplet d'entiers de longueur :attr:`ndim` donnant la taille en octets " "permettant d'accéder à chaque dimensions du tableau." -#: library/stdtypes.rst:4081 +#: library/stdtypes.rst:4082 msgid "Used internally for PIL-style arrays. The value is informational only." msgstr "" "Détail de l'implémentation des *PIL-style arrays*. La valeur n'est donné " "qu'a titre d'information." -#: library/stdtypes.rst:4085 +#: library/stdtypes.rst:4086 msgid "A bool indicating whether the memory is C-:term:`contiguous`." msgstr "Un booléen indiquant si la mémoire est C-:term:`contiguous`." -#: library/stdtypes.rst:4091 +#: library/stdtypes.rst:4092 msgid "A bool indicating whether the memory is Fortran :term:`contiguous`." msgstr "Un booléen indiquant si la mémoire est Fortran :term:`contiguous`." -#: library/stdtypes.rst:4097 +#: library/stdtypes.rst:4098 msgid "A bool indicating whether the memory is :term:`contiguous`." msgstr "Un booléen indiquant si la mémoire est :term:`contiguous`." -#: library/stdtypes.rst:4105 +#: library/stdtypes.rst:4106 msgid "Set Types --- :class:`set`, :class:`frozenset`" msgstr "Types d'ensembles — :class:`set`, :class:`frozenset`" -#: library/stdtypes.rst:4109 +#: library/stdtypes.rst:4110 msgid "" "A :dfn:`set` object is an unordered collection of distinct :term:`hashable` " "objects. Common uses include membership testing, removing duplicates from a " @@ -5697,7 +5701,7 @@ msgstr "" "(Pour les autres conteneurs, voir les classes natives :class:`dict`, :class:" "`list`, et :class:`tuple`, ainsi que le module :mod:`collections`.)" -#: library/stdtypes.rst:4116 +#: library/stdtypes.rst:4117 msgid "" "Like other collections, sets support ``x in set``, ``len(set)``, and ``for x " "in set``. Being an unordered collection, sets do not record element " @@ -5710,7 +5714,7 @@ msgstr "" "d'insertion. En conséquence, les *sets* n'autorisent ni l'indexation, ni le " "découpage, ou tout autre comportement de séquence." -#: library/stdtypes.rst:4121 +#: library/stdtypes.rst:4122 msgid "" "There are currently two built-in set types, :class:`set` and :class:" "`frozenset`. The :class:`set` type is mutable --- the contents can be " @@ -5730,7 +5734,7 @@ msgstr "" "--- son contenu ne peut être modifié après sa création, il peut ainsi être " "utilisé comme clef de dictionnaire ou élément d'un autre *set*." -#: library/stdtypes.rst:4129 +#: library/stdtypes.rst:4130 msgid "" "Non-empty sets (not frozensets) can be created by placing a comma-separated " "list of elements within braces, for example: ``{'jack', 'sjoerd'}``, in " @@ -5740,11 +5744,11 @@ msgstr "" "d'éléments séparés par des virgules et entre accolades, par exemple : " "``{'jack', 'sjoerd'}``, en plus du constructeur de la classe :class:`set`." -#: library/stdtypes.rst:4133 +#: library/stdtypes.rst:4134 msgid "The constructors for both classes work the same:" msgstr "Les constructeurs des deux classes fonctionnent pareil :" -#: library/stdtypes.rst:4138 +#: library/stdtypes.rst:4139 msgid "" "Return a new set or frozenset object whose elements are taken from " "*iterable*. The elements of a set must be :term:`hashable`. To represent " @@ -5757,23 +5761,23 @@ msgstr "" "class:`frozenset`. Si *iterable* n'est pas spécifié, un nouveau *set* vide " "est renvoyé." -#: library/stdtypes.rst:4144 +#: library/stdtypes.rst:4145 #, fuzzy msgid "Sets can be created by several means:" msgstr "Les listes peuvent être construites de différentes manières :" -#: library/stdtypes.rst:4146 +#: library/stdtypes.rst:4147 msgid "" "Use a comma-separated list of elements within braces: ``{'jack', 'sjoerd'}``" msgstr "" -#: library/stdtypes.rst:4147 +#: library/stdtypes.rst:4148 #, fuzzy msgid "" "Use a set comprehension: ``{c for c in 'abracadabra' if c not in 'abc'}``" msgstr "En utilisant une liste en compréhension : ``[x for x in iterable]``" -#: library/stdtypes.rst:4148 +#: library/stdtypes.rst:4149 #, fuzzy msgid "" "Use the type constructor: ``set()``, ``set('foobar')``, ``set(['a', 'b', " @@ -5781,7 +5785,7 @@ msgid "" msgstr "" "En utilisant le constructeur du type : ``list()`` ou ``list(iterable)``" -#: library/stdtypes.rst:4150 +#: library/stdtypes.rst:4151 msgid "" "Instances of :class:`set` and :class:`frozenset` provide the following " "operations:" @@ -5789,19 +5793,19 @@ msgstr "" "Les instances de :class:`set` et :class:`frozenset` fournissent les " "opérations suivantes :" -#: library/stdtypes.rst:4155 +#: library/stdtypes.rst:4156 msgid "Return the number of elements in set *s* (cardinality of *s*)." msgstr "Donne le nombre d'éléments dans le *set* *s* (cardinalité de *s*)." -#: library/stdtypes.rst:4159 +#: library/stdtypes.rst:4160 msgid "Test *x* for membership in *s*." msgstr "Test d'appartenance de *x* dans *s*." -#: library/stdtypes.rst:4163 +#: library/stdtypes.rst:4164 msgid "Test *x* for non-membership in *s*." msgstr "Test de non-appartenance de *x* dans *s*." -#: library/stdtypes.rst:4167 +#: library/stdtypes.rst:4168 msgid "" "Return ``True`` if the set has no elements in common with *other*. Sets are " "disjoint if and only if their intersection is the empty set." @@ -5810,11 +5814,11 @@ msgstr "" "Les ensembles sont disjoints si et seulement si leurs intersection est un " "ensemble vide." -#: library/stdtypes.rst:4173 +#: library/stdtypes.rst:4174 msgid "Test whether every element in the set is in *other*." msgstr "Teste si tous les éléments du set sont dans *other*." -#: library/stdtypes.rst:4177 +#: library/stdtypes.rst:4178 msgid "" "Test whether the set is a proper subset of *other*, that is, ``set <= other " "and set != other``." @@ -5822,11 +5826,11 @@ msgstr "" "Teste si l'ensemble est un sous-ensemble de *other*, c'est-à-dire, ``set <= " "other and set != other``." -#: library/stdtypes.rst:4183 +#: library/stdtypes.rst:4184 msgid "Test whether every element in *other* is in the set." msgstr "Teste si tous les éléments de *other* sont dans l'ensemble." -#: library/stdtypes.rst:4187 +#: library/stdtypes.rst:4188 msgid "" "Test whether the set is a proper superset of *other*, that is, ``set >= " "other and set != other``." @@ -5834,36 +5838,36 @@ msgstr "" "Teste si l'ensemble est un sur-ensemble de *other*, c'est-à-dire, ``set >= " "other and set != other``." -#: library/stdtypes.rst:4193 +#: library/stdtypes.rst:4194 msgid "Return a new set with elements from the set and all others." msgstr "" "Renvoie un nouvel ensemble dont les éléments viennent de l'ensemble et de " "tous les autres." -#: library/stdtypes.rst:4198 +#: library/stdtypes.rst:4199 msgid "Return a new set with elements common to the set and all others." msgstr "" "Renvoie un nouvel ensemble dont les éléments sont commun à l'ensemble et à " "tous les autres." -#: library/stdtypes.rst:4203 +#: library/stdtypes.rst:4204 msgid "Return a new set with elements in the set that are not in the others." msgstr "" "Renvoie un nouvel ensemble dont les éléments sont dans l'ensemble mais ne " "sont dans aucun des autres." -#: library/stdtypes.rst:4208 +#: library/stdtypes.rst:4209 msgid "" "Return a new set with elements in either the set or *other* but not both." msgstr "" "Renvoie un nouvel ensemble dont les éléments sont soit dans l'ensemble, soit " "dans les autres, mais pas dans les deux." -#: library/stdtypes.rst:4212 +#: library/stdtypes.rst:4213 msgid "Return a shallow copy of the set." msgstr "Renvoie une copie de surface du dictionnaire." -#: library/stdtypes.rst:4215 +#: library/stdtypes.rst:4216 #, fuzzy msgid "" "Note, the non-operator versions of :meth:`union`, :meth:`intersection`, :" @@ -5881,7 +5885,7 @@ msgstr "" "typiques d'erreurs, en faveur d'une construction plus lisible : ``set('abc')." "intersection('cbs')``." -#: library/stdtypes.rst:4222 +#: library/stdtypes.rst:4223 msgid "" "Both :class:`set` and :class:`frozenset` support set to set comparisons. Two " "sets are equal if and only if every element of each set is contained in the " @@ -5899,7 +5903,7 @@ msgstr "" "autre ensemble si et seulement si le premier est un sur-ensemble du second " "(est un sur-ensemble mais n'est pas égal)." -#: library/stdtypes.rst:4229 +#: library/stdtypes.rst:4230 msgid "" "Instances of :class:`set` are compared to instances of :class:`frozenset` " "based on their members. For example, ``set('abc') == frozenset('abc')`` " @@ -5910,7 +5914,7 @@ msgstr "" "frozenset('abc')`` envoie ``True``, ainsi que ``set('abc') in " "set([frozenset('abc')])``." -#: library/stdtypes.rst:4233 +#: library/stdtypes.rst:4234 msgid "" "The subset and equality comparisons do not generalize to a total ordering " "function. For example, any two nonempty disjoint sets are not equal and are " @@ -5922,7 +5926,7 @@ msgstr "" "vides ne sont ni égaux et ni des sous-ensembles l'un de l'autre, donc toutes " "ces comparaisons donnent ``False`` : ``ab``." -#: library/stdtypes.rst:4238 +#: library/stdtypes.rst:4239 msgid "" "Since sets only define partial ordering (subset relationships), the output " "of the :meth:`list.sort` method is undefined for lists of sets." @@ -5931,13 +5935,13 @@ msgstr "" "de sous-ensembles), la sortie de la méthode :meth:`list.sort` n'est pas " "définie pour des listes d'ensembles." -#: library/stdtypes.rst:4241 +#: library/stdtypes.rst:4242 msgid "Set elements, like dictionary keys, must be :term:`hashable`." msgstr "" "Les éléments des *sets*, comme les clefs de dictionnaires, doivent être :" "term:`hashable`." -#: library/stdtypes.rst:4243 +#: library/stdtypes.rst:4244 msgid "" "Binary operations that mix :class:`set` instances with :class:`frozenset` " "return the type of the first operand. For example: ``frozenset('ab') | " @@ -5947,7 +5951,7 @@ msgstr "" "`frozenset` renvoient le type de la première opérande. Par exemple : " "``frozenset('ab') | set('bc')`` renvoie une instance de :class:`frozenset`." -#: library/stdtypes.rst:4247 +#: library/stdtypes.rst:4248 msgid "" "The following table lists operations available for :class:`set` that do not " "apply to immutable instances of :class:`frozenset`:" @@ -5955,32 +5959,32 @@ msgstr "" "La table suivante liste les opérations disponibles pour les :class:`set` " "mais qui ne s'appliquent pas aux instances de :class:`frozenset` :" -#: library/stdtypes.rst:4253 +#: library/stdtypes.rst:4254 msgid "Update the set, adding elements from all others." msgstr "Met à jour l'ensemble, ajoutant les éléments de tous les autres." -#: library/stdtypes.rst:4258 +#: library/stdtypes.rst:4259 msgid "Update the set, keeping only elements found in it and all others." msgstr "" "Met à jour l'ensemble, ne gardant que les éléments trouvés dans tous les " "autres." -#: library/stdtypes.rst:4263 +#: library/stdtypes.rst:4264 msgid "Update the set, removing elements found in others." msgstr "Met à jour l'ensemble, retirant les éléments trouvés dans les autres." -#: library/stdtypes.rst:4268 +#: library/stdtypes.rst:4269 msgid "" "Update the set, keeping only elements found in either set, but not in both." msgstr "" "Met à jour le set, ne gardant que les éléments trouvés dans un des ensembles " "mais pas dans les deux." -#: library/stdtypes.rst:4272 +#: library/stdtypes.rst:4273 msgid "Add element *elem* to the set." msgstr "Ajoute l'élément *elem* au set." -#: library/stdtypes.rst:4276 +#: library/stdtypes.rst:4277 msgid "" "Remove element *elem* from the set. Raises :exc:`KeyError` if *elem* is not " "contained in the set." @@ -5988,11 +5992,11 @@ msgstr "" "Retire l'élément *elem* de l'ensemble. Lève une exception :exc:`KeyError` si " "*elem* n'est pas dans l'ensemble." -#: library/stdtypes.rst:4281 +#: library/stdtypes.rst:4282 msgid "Remove element *elem* from the set if it is present." msgstr "Retire l'élément *elem* de l'ensemble s'il y est." -#: library/stdtypes.rst:4285 +#: library/stdtypes.rst:4286 msgid "" "Remove and return an arbitrary element from the set. Raises :exc:`KeyError` " "if the set is empty." @@ -6000,11 +6004,11 @@ msgstr "" "Retire et renvoie un élément arbitraire de l'ensemble. Lève une exception :" "exc:`KeyError` si l'ensemble est vide." -#: library/stdtypes.rst:4290 +#: library/stdtypes.rst:4291 msgid "Remove all elements from the set." msgstr "Supprime tous les éléments du *set*." -#: library/stdtypes.rst:4293 +#: library/stdtypes.rst:4294 msgid "" "Note, the non-operator versions of the :meth:`update`, :meth:" "`intersection_update`, :meth:`difference_update`, and :meth:" @@ -6016,7 +6020,7 @@ msgstr "" "`symmetric_difference_update` acceptent n'importe quel itérable comme " "argument." -#: library/stdtypes.rst:4298 +#: library/stdtypes.rst:4299 msgid "" "Note, the *elem* argument to the :meth:`__contains__`, :meth:`remove`, and :" "meth:`discard` methods may be a set. To support searching for an equivalent " @@ -6027,11 +6031,11 @@ msgstr "" "recherche d'un *frozenset* équivalent, un *frozenset* temporaire est crée " "depuis *elem*." -#: library/stdtypes.rst:4306 +#: library/stdtypes.rst:4307 msgid "Mapping Types --- :class:`dict`" msgstr "Les types de correspondances — :class:`dict`" -#: library/stdtypes.rst:4316 +#: library/stdtypes.rst:4317 msgid "" "A :term:`mapping` object maps :term:`hashable` values to arbitrary objects. " "Mappings are mutable objects. There is currently only one standard mapping " @@ -6045,7 +6049,7 @@ msgstr "" "(Pour les autres conteneurs, voir les types natifs :class:`list`, :class:" "`set`, et :class:`tuple`, ainsi que le module :mod:`collections`.)" -#: library/stdtypes.rst:4322 +#: library/stdtypes.rst:4323 msgid "" "A dictionary's keys are *almost* arbitrary values. Values that are not :" "term:`hashable`, that is, values containing lists, dictionaries or other " @@ -6068,7 +6072,7 @@ msgstr "" "d'approximations, il est généralement imprudent de les utiliser comme clefs " "de dictionnaires.)" -#: library/stdtypes.rst:4331 +#: library/stdtypes.rst:4332 msgid "" "Dictionaries can be created by placing a comma-separated list of ``key: " "value`` pairs within braces, for example: ``{'jack': 4098, 'sjoerd': 4127}`` " @@ -6079,7 +6083,7 @@ msgstr "" "``{'jack': 4098, 'sjoerd': 4127}`` ou ``{4098: 'jack', 4127: 'sjoerd'}``, ou " "en utilisant le constructeur de :class:`dict`." -#: library/stdtypes.rst:4339 +#: library/stdtypes.rst:4340 msgid "" "Return a new dictionary initialized from an optional positional argument and " "a possibly empty set of keyword arguments." @@ -6087,12 +6091,12 @@ msgstr "" "Renvoie un nouveau dictionnaire initialisé depuis un argument positionnel " "optionnel, et un ensemble (vide ou non) d'arguments par mot clef." -#: library/stdtypes.rst:4342 +#: library/stdtypes.rst:4343 #, fuzzy msgid "Dictionaries can be created by several means:" msgstr "Les listes peuvent être construites de différentes manières :" -#: library/stdtypes.rst:4344 +#: library/stdtypes.rst:4345 #, fuzzy msgid "" "Use a comma-separated list of ``key: value`` pairs within braces: ``{'jack': " @@ -6103,18 +6107,18 @@ msgstr "" "``{'jack': 4098, 'sjoerd': 4127}`` ou ``{4098: 'jack', 4127: 'sjoerd'}``, ou " "en utilisant le constructeur de :class:`dict`." -#: library/stdtypes.rst:4346 +#: library/stdtypes.rst:4347 #, fuzzy msgid "Use a dict comprehension: ``{}``, ``{x: x ** 2 for x in range(10)}``" msgstr "En utilisant une liste en compréhension : ``[x for x in iterable]``" -#: library/stdtypes.rst:4347 +#: library/stdtypes.rst:4348 msgid "" "Use the type constructor: ``dict()``, ``dict([('foo', 100), ('bar', " "200)])``, ``dict(foo=100, bar=200)``" msgstr "" -#: library/stdtypes.rst:4350 +#: library/stdtypes.rst:4351 msgid "" "If no positional argument is given, an empty dictionary is created. If a " "positional argument is given and it is a mapping object, a dictionary is " @@ -6136,7 +6140,7 @@ msgstr "" "pour cette clef devient la valeur correspondante à cette clef dans le " "nouveau dictionnaire." -#: library/stdtypes.rst:4360 +#: library/stdtypes.rst:4361 msgid "" "If keyword arguments are given, the keyword arguments and their values are " "added to the dictionary created from the positional argument. If a key " @@ -6147,7 +6151,7 @@ msgstr "" "depuis l'argument positionnel. Si une clef est déjà présente, la valeur de " "l'argument nommé remplace la valeur reçue par l'argument positionnel." -#: library/stdtypes.rst:4365 +#: library/stdtypes.rst:4366 msgid "" "To illustrate, the following examples all return a dictionary equal to " "``{\"one\": 1, \"two\": 2, \"three\": 3}``::" @@ -6155,7 +6159,7 @@ msgstr "" "Typiquement, les exemples suivants renvoient tous un dictionnaire valant " "``{\"one\": 1, \"two\": 2, \"three\": 3}`` ::" -#: library/stdtypes.rst:4377 +#: library/stdtypes.rst:4378 msgid "" "Providing keyword arguments as in the first example only works for keys that " "are valid Python identifiers. Otherwise, any valid keys can be used." @@ -6164,7 +6168,7 @@ msgstr "" "pour des clefs qui sont des identifiants valide en Python. Dans les autres " "cas, toutes les clefs valides sont utilisables." -#: library/stdtypes.rst:4381 +#: library/stdtypes.rst:4382 msgid "" "These are the operations that dictionaries support (and therefore, custom " "mapping types should support too):" @@ -6172,16 +6176,16 @@ msgstr "" "Voici les opérations gérées par les dictionnaires, (par conséquent, d'autres " "types de *mapping* peuvent les gérer aussi) :" -#: library/stdtypes.rst:4386 +#: library/stdtypes.rst:4387 msgid "Return a list of all the keys used in the dictionary *d*." msgstr "" "Renvoie une liste de toutes les clés utilisées dans le dictionnaire *d*." -#: library/stdtypes.rst:4390 +#: library/stdtypes.rst:4391 msgid "Return the number of items in the dictionary *d*." msgstr "Renvoie le nombre d'éléments dans le dictionnaire *d*." -#: library/stdtypes.rst:4394 +#: library/stdtypes.rst:4395 msgid "" "Return the item of *d* with key *key*. Raises a :exc:`KeyError` if *key* is " "not in the map." @@ -6189,7 +6193,7 @@ msgstr "" "Donne l'élément de *d* dont la clef est *key*. Lève une exception :exc:" "`KeyError` si *key* n'est pas dans le dictionnaire." -#: library/stdtypes.rst:4399 +#: library/stdtypes.rst:4400 msgid "" "If a subclass of dict defines a method :meth:`__missing__` and *key* is not " "present, the ``d[key]`` operation calls that method with the key *key* as " @@ -6208,7 +6212,7 @@ msgstr "" "meth:`__missing__` doit être une méthode; ça ne peut être une variable " "d'instance ::" -#: library/stdtypes.rst:4417 +#: library/stdtypes.rst:4418 msgid "" "The example above shows part of the implementation of :class:`collections." "Counter`. A different ``__missing__`` method is used by :class:`collections." @@ -6218,11 +6222,11 @@ msgstr "" "`collections.Counter`. :class:`collections.defaultdict` implémente aussi " "``__missing__``." -#: library/stdtypes.rst:4423 +#: library/stdtypes.rst:4424 msgid "Set ``d[key]`` to *value*." msgstr "Assigne ``d[key]`` à *value*." -#: library/stdtypes.rst:4427 +#: library/stdtypes.rst:4428 msgid "" "Remove ``d[key]`` from *d*. Raises a :exc:`KeyError` if *key* is not in the " "map." @@ -6230,15 +6234,15 @@ msgstr "" "Supprime ``d[key]`` de *d*. Lève une exception :exc:`KeyError` si *key* " "n'est pas dans le dictionnaire." -#: library/stdtypes.rst:4432 +#: library/stdtypes.rst:4433 msgid "Return ``True`` if *d* has a key *key*, else ``False``." msgstr "Renvoie ``True`` si *d* a la clef *key*, sinon ``False``." -#: library/stdtypes.rst:4436 +#: library/stdtypes.rst:4437 msgid "Equivalent to ``not key in d``." msgstr "Équivalent à ``not key in d``." -#: library/stdtypes.rst:4440 +#: library/stdtypes.rst:4441 msgid "" "Return an iterator over the keys of the dictionary. This is a shortcut for " "``iter(d.keys())``." @@ -6246,22 +6250,22 @@ msgstr "" "Renvoie un itérateur sur les clefs du dictionnaire. C'est un raccourci pour " "``iter(d.keys())``." -#: library/stdtypes.rst:4445 +#: library/stdtypes.rst:4446 msgid "Remove all items from the dictionary." msgstr "Supprime tous les éléments du dictionnaire." -#: library/stdtypes.rst:4449 +#: library/stdtypes.rst:4450 msgid "Return a shallow copy of the dictionary." msgstr "Renvoie une copie de surface du dictionnaire." -#: library/stdtypes.rst:4453 +#: library/stdtypes.rst:4454 msgid "" "Create a new dictionary with keys from *iterable* and values set to *value*." msgstr "" "Crée un nouveau dictionnaire avec les clefs de *iterable* et les valeurs à " "*value*." -#: library/stdtypes.rst:4455 +#: library/stdtypes.rst:4456 msgid "" ":meth:`fromkeys` is a class method that returns a new dictionary. *value* " "defaults to ``None``. All of the values refer to just a single instance, so " @@ -6275,7 +6279,7 @@ msgstr "" "*value* soit un objet mutable comme une liste vide. Pour avoir des valeurs " "distinctes, utiliser plutôt une :ref:`compréhension de dictionnaire `." -#: library/stdtypes.rst:4463 +#: library/stdtypes.rst:4464 msgid "" "Return the value for *key* if *key* is in the dictionary, else *default*. If " "*default* is not given, it defaults to ``None``, so that this method never " @@ -6285,7 +6289,7 @@ msgstr "" "*default*. Si *default* n'est pas donné, il vaut ``None`` par défaut, de " "manière à ce que cette méthode ne lève jamais :exc:`KeyError`." -#: library/stdtypes.rst:4469 +#: library/stdtypes.rst:4470 msgid "" "Return a new view of the dictionary's items (``(key, value)`` pairs). See " "the :ref:`documentation of view objects `." @@ -6293,7 +6297,7 @@ msgstr "" "Renvoie une nouvelle vue des éléments du dictionnaire (paires de ``(key, " "value)``). Voir la :ref:`documentation des vues `." -#: library/stdtypes.rst:4474 +#: library/stdtypes.rst:4475 msgid "" "Return a new view of the dictionary's keys. See the :ref:`documentation of " "view objects `." @@ -6301,7 +6305,7 @@ msgstr "" "Renvoie une nouvelle vue des clefs du dictionnaire. Voir la :ref:" "`documentation des vues `." -#: library/stdtypes.rst:4479 +#: library/stdtypes.rst:4480 msgid "" "If *key* is in the dictionary, remove it and return its value, else return " "*default*. If *default* is not given and *key* is not in the dictionary, a :" @@ -6311,7 +6315,7 @@ msgstr "" "renvoyée, sinon renvoie *default*. Si *default* n'est pas donné et que " "*key* n'est pas dans le dictionnaire, une :exc:`KeyError` est levée." -#: library/stdtypes.rst:4485 +#: library/stdtypes.rst:4486 msgid "" "Remove and return a ``(key, value)`` pair from the dictionary. Pairs are " "returned in :abbr:`LIFO (last-in, first-out)` order." @@ -6319,7 +6323,7 @@ msgstr "" "Supprime et renvoie une paire ``(key, value)`` du dictionnaire. Les paires " "sont renvoyées dans un ordre :abbr:`LIFO (dernière entrée, prenière sortie)`." -#: library/stdtypes.rst:4488 +#: library/stdtypes.rst:4489 msgid "" ":meth:`popitem` is useful to destructively iterate over a dictionary, as " "often used in set algorithms. If the dictionary is empty, calling :meth:" @@ -6329,7 +6333,7 @@ msgstr "" "destructive, comme souvent dans les algorithmes sur les ensembles. Si le " "dictionnaire est vide, appeler :meth:`popitem` lève une :exc:`KeyError`." -#: library/stdtypes.rst:4492 +#: library/stdtypes.rst:4493 msgid "" "LIFO order is now guaranteed. In prior versions, :meth:`popitem` would " "return an arbitrary key/value pair." @@ -6338,7 +6342,7 @@ msgstr "" "les versions précédentes, :meth:`popitem` renvoyait une paire clé/valeur " "arbitraire." -#: library/stdtypes.rst:4498 +#: library/stdtypes.rst:4499 msgid "" "Return a reverse iterator over the keys of the dictionary. This is a " "shortcut for ``reversed(d.keys())``." @@ -6346,7 +6350,7 @@ msgstr "" "Renvoie un itérateur inversé sur les clés du dictionnaire. C'est un " "raccourci pour ``reversed(d.keys())``." -#: library/stdtypes.rst:4505 +#: library/stdtypes.rst:4506 msgid "" "If *key* is in the dictionary, return its value. If not, insert *key* with " "a value of *default* and return *default*. *default* defaults to ``None``." @@ -6355,7 +6359,7 @@ msgstr "" "*key* avec comme valeur *default* et renvoie *default*. *default* vaut " "``None`` par défaut." -#: library/stdtypes.rst:4511 +#: library/stdtypes.rst:4512 msgid "" "Update the dictionary with the key/value pairs from *other*, overwriting " "existing keys. Return ``None``." @@ -6363,7 +6367,7 @@ msgstr "" "Met à jour le dictionnaire avec les paires de clef/valeur d'*other*, " "écrasant les clefs existantes. Renvoie ``None``." -#: library/stdtypes.rst:4514 +#: library/stdtypes.rst:4515 msgid "" ":meth:`update` accepts either another dictionary object or an iterable of " "key/value pairs (as tuples or other iterables of length two). If keyword " @@ -6376,7 +6380,7 @@ msgstr "" "ensuite mis à jour avec ces pairs de clef/valeurs : ``d.update(red=1, " "blue=2)``." -#: library/stdtypes.rst:4521 +#: library/stdtypes.rst:4522 msgid "" "Return a new view of the dictionary's values. See the :ref:`documentation " "of view objects `." @@ -6384,7 +6388,7 @@ msgstr "" "Renvoie une nouvelle vue des valeurs du dictionnaire. Voir la :ref:" "`documentation des vues `." -#: library/stdtypes.rst:4524 +#: library/stdtypes.rst:4525 msgid "" "An equality comparison between one ``dict.values()`` view and another will " "always return ``False``. This also applies when comparing ``dict.values()`` " @@ -6394,21 +6398,21 @@ msgstr "" "renvoie toujours ``False``. Cela s'applique aussi lorsque l'on compare " "``dict.values()`` à lui-même ::" -#: library/stdtypes.rst:4534 +#: library/stdtypes.rst:4535 msgid "" "Create a new dictionary with the merged keys and values of *d* and *other*, " "which must both be dictionaries. The values of *other* take priority when " "*d* and *other* share keys." msgstr "" -#: library/stdtypes.rst:4542 +#: library/stdtypes.rst:4543 msgid "" "Update the dictionary *d* with keys and values from *other*, which may be " "either a :term:`mapping` or an :term:`iterable` of key/value pairs. The " "values of *other* take priority when *d* and *other* share keys." msgstr "" -#: library/stdtypes.rst:4548 +#: library/stdtypes.rst:4549 msgid "" "Dictionaries compare equal if and only if they have the same ``(key, " "value)`` pairs (regardless of ordering). Order comparisons ('<', '<=', '>=', " @@ -6418,7 +6422,7 @@ msgstr "" "clé-valeur (``(key, value)``, peu importe leur ordre). Les comparaisons " "d'ordre (``<``, ``<=``, ``>=``, ``>``) lèvent une :exc:`TypeError`." -#: library/stdtypes.rst:4552 +#: library/stdtypes.rst:4553 msgid "" "Dictionaries preserve insertion order. Note that updating a key does not " "affect the order. Keys added after deletion are inserted at the end. ::" @@ -6427,7 +6431,7 @@ msgstr "" "clé n'affecte pas l'ordre. Les clés ajoutées après un effacement sont " "insérées à la fin. ::" -#: library/stdtypes.rst:4570 +#: library/stdtypes.rst:4571 msgid "" "Dictionary order is guaranteed to be insertion order. This behavior was an " "implementation detail of CPython from 3.6." @@ -6436,16 +6440,16 @@ msgstr "" "comportement était un détail d'implémentation de CPython depuis la version " "3.6." -#: library/stdtypes.rst:4574 +#: library/stdtypes.rst:4575 msgid "Dictionaries and dictionary views are reversible. ::" msgstr "Les dictionnaires et les vues de dictionnaires sont réversibles. ::" # suit un ':' ("changed in version X.Y") -#: library/stdtypes.rst:4586 +#: library/stdtypes.rst:4587 msgid "Dictionaries are now reversible." msgstr "les dictionnaires sont maintenant réversibles." -#: library/stdtypes.rst:4591 +#: library/stdtypes.rst:4592 msgid "" ":class:`types.MappingProxyType` can be used to create a read-only view of a :" "class:`dict`." @@ -6453,11 +6457,11 @@ msgstr "" ":class:`types.MappingProxyType` peut être utilisé pour créer une vue en " "lecture seule d'un :class:`dict`." -#: library/stdtypes.rst:4598 +#: library/stdtypes.rst:4599 msgid "Dictionary view objects" msgstr "Les vues de dictionnaires" -#: library/stdtypes.rst:4600 +#: library/stdtypes.rst:4601 msgid "" "The objects returned by :meth:`dict.keys`, :meth:`dict.values` and :meth:" "`dict.items` are *view objects*. They provide a dynamic view on the " @@ -6469,7 +6473,7 @@ msgstr "" "éléments du dictionnaire, ce qui signifie que si le dictionnaire change, la " "vue reflète ces changements." -#: library/stdtypes.rst:4605 +#: library/stdtypes.rst:4606 msgid "" "Dictionary views can be iterated over to yield their respective data, and " "support membership tests:" @@ -6477,11 +6481,11 @@ msgstr "" "Les vues de dictionnaires peuvent être itérées et ainsi renvoyer les données " "du dictionnaire, elle gèrent aussi les tests de présence :" -#: library/stdtypes.rst:4610 +#: library/stdtypes.rst:4611 msgid "Return the number of entries in the dictionary." msgstr "Renvoie le nombre d'entrées du dictionnaire." -#: library/stdtypes.rst:4614 +#: library/stdtypes.rst:4615 msgid "" "Return an iterator over the keys, values or items (represented as tuples of " "``(key, value)``) in the dictionary." @@ -6489,7 +6493,7 @@ msgstr "" "Renvoie un itérateur sur les clefs, les valeurs, ou les éléments " "(représentés par des paires ``(key, value)`` du dictionnaire." -#: library/stdtypes.rst:4617 +#: library/stdtypes.rst:4618 msgid "" "Keys and values are iterated over in insertion order. This allows the " "creation of ``(value, key)`` pairs using :func:`zip`: ``pairs = zip(d." @@ -6501,7 +6505,7 @@ msgstr "" "``pairs = zip(d.values(), d.keys())``. Un autre moyen de construire la même " "liste est ``pairs = [(v, k) for (k, v) in d.items()]``." -#: library/stdtypes.rst:4622 +#: library/stdtypes.rst:4623 msgid "" "Iterating views while adding or deleting entries in the dictionary may raise " "a :exc:`RuntimeError` or fail to iterate over all entries." @@ -6510,11 +6514,11 @@ msgstr "" "dictionnaire peut lever une :exc:`RuntimeError` ou ne pas fournir toutes les " "entrées." -#: library/stdtypes.rst:4625 +#: library/stdtypes.rst:4626 msgid "Dictionary order is guaranteed to be insertion order." msgstr "L'ordre d'un dictionnaire est toujours l'ordre des insertions." -#: library/stdtypes.rst:4630 +#: library/stdtypes.rst:4631 msgid "" "Return ``True`` if *x* is in the underlying dictionary's keys, values or " "items (in the latter case, *x* should be a ``(key, value)`` tuple)." @@ -6523,7 +6527,7 @@ msgstr "" "dictionnaire sous-jacent (dans le dernier cas, *x* doit être une paire " "``(key, value)``)." -#: library/stdtypes.rst:4635 +#: library/stdtypes.rst:4636 msgid "" "Return a reverse iterator over the keys, values or items of the dictionary. " "The view will be iterated in reverse order of the insertion." @@ -6532,17 +6536,17 @@ msgstr "" "dictionnaire. La vue est itérée dans l'ordre inverse d'insertion." # suit un ':' ("changed in version X.Y") -#: library/stdtypes.rst:4638 +#: library/stdtypes.rst:4639 msgid "Dictionary views are now reversible." msgstr "les vues de dictionnaires sont dorénavant réversibles." -#: library/stdtypes.rst:4643 +#: library/stdtypes.rst:4644 msgid "" "Return a :class:`types.MappingProxyType` that wraps the original dictionary " "to which the view refers." msgstr "" -#: library/stdtypes.rst:4648 +#: library/stdtypes.rst:4649 msgid "" "Keys views are set-like since their entries are unique and hashable. If all " "values are hashable, so that ``(key, value)`` pairs are unique and hashable, " @@ -6561,15 +6565,15 @@ msgstr "" "abstraite :class:`collections.abc.Set` sont disponibles (comme ``==``, " "``<``, ou ``^``)." -#: library/stdtypes.rst:4655 +#: library/stdtypes.rst:4656 msgid "An example of dictionary view usage::" msgstr "Exemple d'utilisation de vue de dictionnaire ::" -#: library/stdtypes.rst:4696 +#: library/stdtypes.rst:4697 msgid "Context Manager Types" msgstr "Le type gestionnaire de contexte" -#: library/stdtypes.rst:4703 +#: library/stdtypes.rst:4704 msgid "" "Python's :keyword:`with` statement supports the concept of a runtime context " "defined by a context manager. This is implemented using a pair of methods " @@ -6582,7 +6586,7 @@ msgstr "" "entré avant l'exécution du corps de l'instruction, et qui est quitté lorsque " "l'instruction se termine :" -#: library/stdtypes.rst:4711 +#: library/stdtypes.rst:4712 msgid "" "Enter the runtime context and return either this object or another object " "related to the runtime context. The value returned by this method is bound " @@ -6594,7 +6598,7 @@ msgstr "" "cette méthode est liée à l'identifiant donné au :keyword:`!as` de " "l'instruction :keyword:`with` utilisant ce gestionnaire de contexte." -#: library/stdtypes.rst:4716 +#: library/stdtypes.rst:4717 msgid "" "An example of a context manager that returns itself is a :term:`file " "object`. File objects return themselves from __enter__() to allow :func:" @@ -6605,7 +6609,7 @@ msgstr "" "autorisent :func:`open` à être utilisé comme contexte à une instruction :" "keyword:`with`." -#: library/stdtypes.rst:4720 +#: library/stdtypes.rst:4721 msgid "" "An example of a context manager that returns a related object is the one " "returned by :func:`decimal.localcontext`. These managers set the active " @@ -6620,7 +6624,7 @@ msgstr "" "renvoyée. Ça permet de changer le contexte courant dans le corps du :keyword:" "`with` sans affecter le code en dehors de l'instruction :keyword:`!with`." -#: library/stdtypes.rst:4730 +#: library/stdtypes.rst:4731 msgid "" "Exit the runtime context and return a Boolean flag indicating if any " "exception that occurred should be suppressed. If an exception occurred while " @@ -6634,7 +6638,7 @@ msgstr "" "l'exception, sa valeur, et la trace de la pile (*traceback*). Sinon les " "trois arguments valent ``None``." -#: library/stdtypes.rst:4735 +#: library/stdtypes.rst:4736 msgid "" "Returning a true value from this method will cause the :keyword:`with` " "statement to suppress the exception and continue execution with the " @@ -6651,7 +6655,7 @@ msgstr "" "pendant l'exécution de cette méthode remplaceront toute exception qui s'est " "produite dans le corps du :keyword:`!with`." -#: library/stdtypes.rst:4742 +#: library/stdtypes.rst:4743 msgid "" "The exception passed in should never be reraised explicitly - instead, this " "method should return a false value to indicate that the method completed " @@ -6665,7 +6669,7 @@ msgstr "" "Ceci permet au code de gestion du contexte de comprendre si une méthode :" "meth:`__exit__` a échoué." -#: library/stdtypes.rst:4748 +#: library/stdtypes.rst:4749 msgid "" "Python defines several context managers to support easy thread " "synchronisation, prompt closure of files or other objects, and simpler " @@ -6680,7 +6684,7 @@ msgstr "" "protocole de gestion du contexte. Voir les exemples dans la documentation du " "module :mod:`contextlib`." -#: library/stdtypes.rst:4754 +#: library/stdtypes.rst:4755 msgid "" "Python's :term:`generator`\\s and the :class:`contextlib.contextmanager` " "decorator provide a convenient way to implement these protocols. If a " @@ -6696,7 +6700,7 @@ msgstr "" "`__enter__` et :meth:`__exit__`, plutôt que l'itérateur produit par un " "générateur non décoré." -#: library/stdtypes.rst:4761 +#: library/stdtypes.rst:4762 msgid "" "Note that there is no specific slot for any of these methods in the type " "structure for Python objects in the Python/C API. Extension types wanting to " @@ -6711,31 +6715,31 @@ msgstr "" "d'exécution, les le coût d'un accès au dictionnaire d'une classe unique est " "négligeable." -#: library/stdtypes.rst:4769 +#: library/stdtypes.rst:4770 msgid "" "Type Annotation Types --- :ref:`Generic Alias `, :ref:" "`Union `" msgstr "" -#: library/stdtypes.rst:4774 +#: library/stdtypes.rst:4775 msgid "" "The core built-in types for :term:`type annotations ` are :ref:" "`Generic Alias ` and :ref:`Union `." msgstr "" -#: library/stdtypes.rst:4781 +#: library/stdtypes.rst:4782 #, fuzzy msgid "Generic Alias Type" msgstr "Types générateurs" -#: library/stdtypes.rst:4787 +#: library/stdtypes.rst:4788 msgid "" "``GenericAlias`` objects are created by subscripting a class (usually a " "container), such as ``list[int]``. They are intended primarily for :term:" "`type annotations `." msgstr "" -#: library/stdtypes.rst:4791 +#: library/stdtypes.rst:4792 msgid "" "Usually, the :ref:`subscription ` of container objects calls " "the method :meth:`__getitem__` of the object. However, the subscription of " @@ -6744,35 +6748,35 @@ msgid "" "return a ``GenericAlias`` object." msgstr "" -#: library/stdtypes.rst:4798 +#: library/stdtypes.rst:4799 msgid "" "If the :meth:`__getitem__` of the class' metaclass is present, it will take " "precedence over the :meth:`__class_getitem__` defined in the class (see :pep:" "`560` for more details)." msgstr "" -#: library/stdtypes.rst:4802 +#: library/stdtypes.rst:4803 msgid "" "The ``GenericAlias`` object acts as a proxy for :term:`generic types " "`, implementing *parameterized generics* - a specific instance " "of a generic which provides the types for container elements." msgstr "" -#: library/stdtypes.rst:4806 +#: library/stdtypes.rst:4807 msgid "" "The user-exposed type for the ``GenericAlias`` object can be accessed from :" "class:`types.GenericAlias` and used for :func:`isinstance` checks. It can " "also be used to create ``GenericAlias`` objects directly." msgstr "" -#: library/stdtypes.rst:4812 +#: library/stdtypes.rst:4813 msgid "" "Creates a ``GenericAlias`` representing a type ``T`` containing elements of " "types *X*, *Y*, and more depending on the ``T`` used. For example, a " "function expecting a :class:`list` containing :class:`float` elements::" msgstr "" -#: library/stdtypes.rst:4820 +#: library/stdtypes.rst:4821 msgid "" "Another example for :term:`mapping` objects, using a :class:`dict`, which is " "a generic type expecting two type parameters representing the key type and " @@ -6780,13 +6784,13 @@ msgid "" "of type :class:`str` and values of type :class:`int`::" msgstr "" -#: library/stdtypes.rst:4828 +#: library/stdtypes.rst:4829 msgid "" "The builtin functions :func:`isinstance` and :func:`issubclass` do not " "accept ``GenericAlias`` types for their second argument::" msgstr "" -#: library/stdtypes.rst:4836 +#: library/stdtypes.rst:4837 msgid "" "The Python runtime does not enforce :term:`type annotations `. " "This extends to generic types and their type parameters. When creating an " @@ -6795,25 +6799,25 @@ msgid "" "without errors::" msgstr "" -#: library/stdtypes.rst:4846 +#: library/stdtypes.rst:4847 msgid "" "Furthermore, parameterized generics erase type parameters during object " "creation::" msgstr "" -#: library/stdtypes.rst:4857 +#: library/stdtypes.rst:4858 msgid "" "Calling :func:`repr` or :func:`str` on a generic shows the parameterized " "type::" msgstr "" -#: library/stdtypes.rst:4865 +#: library/stdtypes.rst:4866 msgid "" "The :meth:`__getitem__` method of generics will raise an exception to " "disallow mistakes like ``dict[str][str]``::" msgstr "" -#: library/stdtypes.rst:4873 +#: library/stdtypes.rst:4874 msgid "" "However, such expressions are valid when :ref:`type variables ` " "are used. The index must have as many elements as there are type variable " @@ -6821,216 +6825,216 @@ msgid "" "__args__>`. ::" msgstr "" -#: library/stdtypes.rst:4884 +#: library/stdtypes.rst:4885 msgid "Standard Generic Collections" msgstr "" -#: library/stdtypes.rst:4886 +#: library/stdtypes.rst:4887 msgid "These standard library collections support parameterized generics." msgstr "" -#: library/stdtypes.rst:4888 +#: library/stdtypes.rst:4889 msgid ":class:`tuple`" msgstr "" -#: library/stdtypes.rst:4889 +#: library/stdtypes.rst:4890 msgid ":class:`list`" msgstr "" -#: library/stdtypes.rst:4890 +#: library/stdtypes.rst:4891 msgid ":class:`dict`" msgstr "" -#: library/stdtypes.rst:4891 +#: library/stdtypes.rst:4892 msgid ":class:`set`" msgstr "" -#: library/stdtypes.rst:4892 +#: library/stdtypes.rst:4893 msgid ":class:`frozenset`" msgstr "" -#: library/stdtypes.rst:4893 +#: library/stdtypes.rst:4894 msgid ":class:`type`" msgstr "" -#: library/stdtypes.rst:4894 +#: library/stdtypes.rst:4895 msgid ":class:`collections.deque`" msgstr "" -#: library/stdtypes.rst:4895 +#: library/stdtypes.rst:4896 msgid ":class:`collections.defaultdict`" msgstr "" -#: library/stdtypes.rst:4896 +#: library/stdtypes.rst:4897 msgid ":class:`collections.OrderedDict`" msgstr "" -#: library/stdtypes.rst:4897 +#: library/stdtypes.rst:4898 msgid ":class:`collections.Counter`" msgstr "" -#: library/stdtypes.rst:4898 +#: library/stdtypes.rst:4899 msgid ":class:`collections.ChainMap`" msgstr "" -#: library/stdtypes.rst:4899 +#: library/stdtypes.rst:4900 msgid ":class:`collections.abc.Awaitable`" msgstr "" -#: library/stdtypes.rst:4900 +#: library/stdtypes.rst:4901 msgid ":class:`collections.abc.Coroutine`" msgstr "" -#: library/stdtypes.rst:4901 +#: library/stdtypes.rst:4902 msgid ":class:`collections.abc.AsyncIterable`" msgstr "" -#: library/stdtypes.rst:4902 +#: library/stdtypes.rst:4903 msgid ":class:`collections.abc.AsyncIterator`" msgstr "" -#: library/stdtypes.rst:4903 +#: library/stdtypes.rst:4904 msgid ":class:`collections.abc.AsyncGenerator`" msgstr "" -#: library/stdtypes.rst:4904 +#: library/stdtypes.rst:4905 msgid ":class:`collections.abc.Iterable`" msgstr "" -#: library/stdtypes.rst:4905 +#: library/stdtypes.rst:4906 msgid ":class:`collections.abc.Iterator`" msgstr "" -#: library/stdtypes.rst:4906 +#: library/stdtypes.rst:4907 msgid ":class:`collections.abc.Generator`" msgstr "" -#: library/stdtypes.rst:4907 +#: library/stdtypes.rst:4908 msgid ":class:`collections.abc.Reversible`" msgstr "" -#: library/stdtypes.rst:4908 +#: library/stdtypes.rst:4909 msgid ":class:`collections.abc.Container`" msgstr "" -#: library/stdtypes.rst:4909 +#: library/stdtypes.rst:4910 msgid ":class:`collections.abc.Collection`" msgstr "" -#: library/stdtypes.rst:4910 +#: library/stdtypes.rst:4911 msgid ":class:`collections.abc.Callable`" msgstr "" -#: library/stdtypes.rst:4911 +#: library/stdtypes.rst:4912 msgid ":class:`collections.abc.Set`" msgstr "" -#: library/stdtypes.rst:4912 +#: library/stdtypes.rst:4913 msgid ":class:`collections.abc.MutableSet`" msgstr "" -#: library/stdtypes.rst:4913 +#: library/stdtypes.rst:4914 msgid ":class:`collections.abc.Mapping`" msgstr "" -#: library/stdtypes.rst:4914 +#: library/stdtypes.rst:4915 msgid ":class:`collections.abc.MutableMapping`" msgstr "" -#: library/stdtypes.rst:4915 +#: library/stdtypes.rst:4916 msgid ":class:`collections.abc.Sequence`" msgstr "" -#: library/stdtypes.rst:4916 +#: library/stdtypes.rst:4917 msgid ":class:`collections.abc.MutableSequence`" msgstr "" -#: library/stdtypes.rst:4917 +#: library/stdtypes.rst:4918 msgid ":class:`collections.abc.ByteString`" msgstr "" -#: library/stdtypes.rst:4918 +#: library/stdtypes.rst:4919 msgid ":class:`collections.abc.MappingView`" msgstr "" -#: library/stdtypes.rst:4919 +#: library/stdtypes.rst:4920 msgid ":class:`collections.abc.KeysView`" msgstr "" -#: library/stdtypes.rst:4920 +#: library/stdtypes.rst:4921 msgid ":class:`collections.abc.ItemsView`" msgstr "" -#: library/stdtypes.rst:4921 +#: library/stdtypes.rst:4922 msgid ":class:`collections.abc.ValuesView`" msgstr "" -#: library/stdtypes.rst:4922 +#: library/stdtypes.rst:4923 msgid ":class:`contextlib.AbstractContextManager`" msgstr "" -#: library/stdtypes.rst:4923 +#: library/stdtypes.rst:4924 msgid ":class:`contextlib.AbstractAsyncContextManager`" msgstr "" -#: library/stdtypes.rst:4924 +#: library/stdtypes.rst:4925 msgid ":ref:`re.Pattern `" msgstr "" -#: library/stdtypes.rst:4925 +#: library/stdtypes.rst:4926 msgid ":ref:`re.Match `" msgstr "" -#: library/stdtypes.rst:4929 +#: library/stdtypes.rst:4930 #, fuzzy msgid "Special Attributes of Generic Alias" msgstr "Attributs spéciaux" -#: library/stdtypes.rst:4931 +#: library/stdtypes.rst:4932 msgid "All parameterized generics implement special read-only attributes." msgstr "" -#: library/stdtypes.rst:4935 +#: library/stdtypes.rst:4936 msgid "This attribute points at the non-parameterized generic class::" msgstr "" -#: library/stdtypes.rst:4943 +#: library/stdtypes.rst:4944 msgid "" "This attribute is a :class:`tuple` (possibly of length 1) of generic types " "passed to the original :meth:`__class_getitem__` of the generic container::" msgstr "" -#: library/stdtypes.rst:4953 +#: library/stdtypes.rst:4954 msgid "" "This attribute is a lazily computed tuple (possibly empty) of unique type " "variables found in ``__args__``::" msgstr "" -#: library/stdtypes.rst:4964 +#: library/stdtypes.rst:4965 msgid "" "A ``GenericAlias`` object with :class:`typing.ParamSpec` parameters may not " "have correct ``__parameters__`` after substitution because :class:`typing." "ParamSpec` is intended primarily for static type checking." msgstr "" -#: library/stdtypes.rst:4970 +#: library/stdtypes.rst:4971 msgid ":pep:`585` -- \"Type Hinting Generics In Standard Collections\"" msgstr "" -#: library/stdtypes.rst:4971 +#: library/stdtypes.rst:4972 msgid ":meth:`__class_getitem__` -- Used to implement parameterized generics." msgstr "" -#: library/stdtypes.rst:4972 +#: library/stdtypes.rst:4973 msgid ":ref:`generics` -- Generics in the :mod:`typing` module." msgstr "" -#: library/stdtypes.rst:4980 +#: library/stdtypes.rst:4981 #, fuzzy msgid "Union Type" msgstr "Type de conversion." -#: library/stdtypes.rst:4986 +#: library/stdtypes.rst:4987 msgid "" "A union object holds the value of the ``|`` (bitwise or) operation on " "multiple :ref:`type objects `. These types are intended " @@ -7039,7 +7043,7 @@ msgid "" "Union`." msgstr "" -#: library/stdtypes.rst:4993 +#: library/stdtypes.rst:4994 msgid "" "Defines a union object which holds types *X*, *Y*, and so forth. ``X | Y`` " "means either X or Y. It is equivalent to ``typing.Union[X, Y]``. For " @@ -7047,66 +7051,66 @@ msgid "" "class:`float`::" msgstr "" -#: library/stdtypes.rst:5003 +#: library/stdtypes.rst:5004 msgid "" "Union objects can be tested for equality with other union objects. Details:" msgstr "" -#: library/stdtypes.rst:5005 +#: library/stdtypes.rst:5006 msgid "Unions of unions are flattened::" msgstr "" -#: library/stdtypes.rst:5009 +#: library/stdtypes.rst:5010 msgid "Redundant types are removed::" msgstr "" -#: library/stdtypes.rst:5013 +#: library/stdtypes.rst:5014 msgid "When comparing unions, the order is ignored::" msgstr "" -#: library/stdtypes.rst:5017 +#: library/stdtypes.rst:5018 msgid "It is compatible with :data:`typing.Union`::" msgstr "" -#: library/stdtypes.rst:5021 +#: library/stdtypes.rst:5022 msgid "Optional types can be spelled as a union with ``None``::" msgstr "" -#: library/stdtypes.rst:5028 +#: library/stdtypes.rst:5029 msgid "" "Calls to :func:`isinstance` and :func:`issubclass` are also supported with a " "union object::" msgstr "" -#: library/stdtypes.rst:5034 +#: library/stdtypes.rst:5035 msgid "" "However, union objects containing :ref:`parameterized generics ` cannot be used::" msgstr "" -#: library/stdtypes.rst:5042 +#: library/stdtypes.rst:5043 msgid "" "The user-exposed type for the union object can be accessed from :data:`types." "UnionType` and used for :func:`isinstance` checks. An object cannot be " "instantiated from the type::" msgstr "" -#: library/stdtypes.rst:5055 +#: library/stdtypes.rst:5056 msgid "" "The :meth:`__or__` method for type objects was added to support the syntax " "``X | Y``. If a metaclass implements :meth:`__or__`, the Union may override " "it::" msgstr "" -#: library/stdtypes.rst:5073 +#: library/stdtypes.rst:5074 msgid ":pep:`604` -- PEP proposing the ``X | Y`` syntax and the Union type." msgstr "" -#: library/stdtypes.rst:5081 +#: library/stdtypes.rst:5082 msgid "Other Built-in Types" msgstr "Autres types natifs" -#: library/stdtypes.rst:5083 +#: library/stdtypes.rst:5084 msgid "" "The interpreter supports several other kinds of objects. Most of these " "support only one or two operations." @@ -7114,11 +7118,11 @@ msgstr "" "L'interpréteur gère aussi d'autres types d'objets, la plupart ne supportant " "cependant qu'une ou deux opérations." -#: library/stdtypes.rst:5090 +#: library/stdtypes.rst:5091 msgid "Modules" msgstr "Modules" -#: library/stdtypes.rst:5092 +#: library/stdtypes.rst:5093 msgid "" "The only special operation on a module is attribute access: ``m.name``, " "where *m* is a module and *name* accesses a name defined in *m*'s symbol " @@ -7136,7 +7140,7 @@ msgstr "" "objet module nommé *foo* existe, il nécessite cependant une *définition* " "(externe) d'un module nommé *foo* quelque part.)" -#: library/stdtypes.rst:5099 +#: library/stdtypes.rst:5100 msgid "" "A special attribute of every module is :attr:`~object.__dict__`. This is the " "dictionary containing the module's symbol table. Modifying this dictionary " @@ -7154,7 +7158,7 @@ msgstr "" "vous ne pouvez pas écrire ``m.__dict__ = {}``). Modifier :attr:`~object." "__dict__` directement n'est pas recommandé." -#: library/stdtypes.rst:5107 +#: library/stdtypes.rst:5108 msgid "" "Modules built into the interpreter are written like this: ````. If loaded from a file, they are written as ````. S'ils sont chargés depuis un fichier, ils sont représentés " "````." -#: library/stdtypes.rst:5115 +#: library/stdtypes.rst:5116 msgid "Classes and Class Instances" msgstr "Les classes et instances de classes" -#: library/stdtypes.rst:5117 +#: library/stdtypes.rst:5118 msgid "See :ref:`objects` and :ref:`class` for these." msgstr "Voir :ref:`objects` et :ref:`class`." -#: library/stdtypes.rst:5123 +#: library/stdtypes.rst:5124 msgid "Functions" msgstr "Fonctions" -#: library/stdtypes.rst:5125 +#: library/stdtypes.rst:5126 msgid "" "Function objects are created by function definitions. The only operation on " "a function object is to call it: ``func(argument-list)``." @@ -7185,7 +7189,7 @@ msgstr "" "opération applicable à un objet fonction est de l'appeler : ``func(argument-" "list)``." -#: library/stdtypes.rst:5128 +#: library/stdtypes.rst:5129 msgid "" "There are really two flavors of function objects: built-in functions and " "user-defined functions. Both support the same operation (to call the " @@ -7197,15 +7201,15 @@ msgstr "" "opérations (l'appel à la fonction), mais leur implémentation est différente, " "d'où les deux types distincts." -#: library/stdtypes.rst:5132 +#: library/stdtypes.rst:5133 msgid "See :ref:`function` for more information." msgstr "Voir :ref:`function` pour plus d'information." -#: library/stdtypes.rst:5138 +#: library/stdtypes.rst:5139 msgid "Methods" msgstr "Méthodes" -#: library/stdtypes.rst:5142 +#: library/stdtypes.rst:5143 msgid "" "Methods are functions that are called using the attribute notation. There " "are two flavors: built-in methods (such as :meth:`append` on lists) and " @@ -7217,7 +7221,7 @@ msgstr "" "listes), et les méthodes d'instances de classes. Les méthodes natives sont " "représentées avec le type qui les supporte." -#: library/stdtypes.rst:5147 +#: library/stdtypes.rst:5148 msgid "" "If you access a method (a function defined in a class namespace) through an " "instance, you get a special object: a :dfn:`bound method` (also called :dfn:" @@ -7238,7 +7242,7 @@ msgstr "" "n)`` est tout à fait équivalent à appeler ``m.__func__(m.__self__, arg-1, " "arg-2, …, arg-n)``." -#: library/stdtypes.rst:5156 +#: library/stdtypes.rst:5157 msgid "" "Like function objects, bound method objects support getting arbitrary " "attributes. However, since method attributes are actually stored on the " @@ -7255,15 +7259,15 @@ msgstr "" "`AttributeError`. Pour affecter l'attribut, vous devrez explicitement " "l'affecter à sa fonction sous-jacente ::" -#: library/stdtypes.rst:5207 +#: library/stdtypes.rst:5208 msgid "See :ref:`types` for more information." msgstr "Voir :ref:`types` pour plus d'information." -#: library/stdtypes.rst:5184 +#: library/stdtypes.rst:5185 msgid "Code Objects" msgstr "Objets code" -#: library/stdtypes.rst:5190 +#: library/stdtypes.rst:5191 msgid "" "Code objects are used by the implementation to represent \"pseudo-compiled\" " "executable Python code such as a function body. They differ from function " @@ -7279,13 +7283,13 @@ msgstr "" "fonction native :func:`compile` et peuvent être obtenus des objets fonction " "via leur attribut :attr:`__code__`. Voir aussi le module :mod:`code`." -#: library/stdtypes.rst:5197 +#: library/stdtypes.rst:5198 msgid "" "Accessing ``__code__`` raises an :ref:`auditing event ` ``object." "__getattr__`` with arguments ``obj`` and ``\"__code__\"``." msgstr "" -#: library/stdtypes.rst:5204 +#: library/stdtypes.rst:5205 msgid "" "A code object can be executed or evaluated by passing it (instead of a " "source string) to the :func:`exec` or :func:`eval` built-in functions." @@ -7294,11 +7298,11 @@ msgstr "" "d'une chaîne contenant du code) aux fonction natives :func:`exec` ou :func:" "`eval`." -#: library/stdtypes.rst:5213 +#: library/stdtypes.rst:5214 msgid "Type Objects" msgstr "Objets type" -#: library/stdtypes.rst:5219 +#: library/stdtypes.rst:5220 msgid "" "Type objects represent the various object types. An object's type is " "accessed by the built-in function :func:`type`. There are no special " @@ -7310,15 +7314,15 @@ msgstr "" "opération spéciale sur les types. Le module standard :mod:`types` définit " "les noms de tous les types natifs." -#: library/stdtypes.rst:5224 +#: library/stdtypes.rst:5225 msgid "Types are written like this: ````." msgstr "Les types sont représentés : ````." -#: library/stdtypes.rst:5230 +#: library/stdtypes.rst:5231 msgid "The Null Object" msgstr "L'objet Null" -#: library/stdtypes.rst:5232 +#: library/stdtypes.rst:5233 msgid "" "This object is returned by functions that don't explicitly return a value. " "It supports no special operations. There is exactly one null object, named " @@ -7328,15 +7332,15 @@ msgstr "" "valeur. Il ne supporte aucune opération spéciale. Il existe exactement un " "objet *null* nommé ``None`` (c'est un nom natif). ``type(None)()``." -#: library/stdtypes.rst:5236 +#: library/stdtypes.rst:5237 msgid "It is written as ``None``." msgstr "C'est écrit ``None``." -#: library/stdtypes.rst:5243 +#: library/stdtypes.rst:5244 msgid "The Ellipsis Object" msgstr "L'objet points de suspension" -#: library/stdtypes.rst:5245 +#: library/stdtypes.rst:5246 msgid "" "This object is commonly used by slicing (see :ref:`slicings`). It supports " "no special operations. There is exactly one ellipsis object, named :const:" @@ -7348,15 +7352,15 @@ msgstr "" "objet *ellipsis*, nommé :const:`Ellipsis` (un nom natif). ``type(Ellipsis)" "()`` produit le *singleton* :const:`Ellipsis`." -#: library/stdtypes.rst:5250 +#: library/stdtypes.rst:5251 msgid "It is written as ``Ellipsis`` or ``...``." msgstr "C'est écrit ``Ellipsis`` ou ``...``." -#: library/stdtypes.rst:5256 +#: library/stdtypes.rst:5257 msgid "The NotImplemented Object" msgstr "L'objet *NotImplemented*" -#: library/stdtypes.rst:5258 +#: library/stdtypes.rst:5259 msgid "" "This object is returned from comparisons and binary operations when they are " "asked to operate on types they don't support. See :ref:`comparisons` for " @@ -7368,15 +7372,15 @@ msgstr "" "pour plus d'informations. Il n'y a qu'un seul objet ``NotImplemented``. " "``type(NotImplemented)()`` renvoie un *singleton*." -#: library/stdtypes.rst:5263 +#: library/stdtypes.rst:5264 msgid "It is written as ``NotImplemented``." msgstr "C'est écrit ``NotImplemented``." -#: library/stdtypes.rst:5269 +#: library/stdtypes.rst:5270 msgid "Boolean Values" msgstr "Valeurs booléennes" -#: library/stdtypes.rst:5271 +#: library/stdtypes.rst:5272 msgid "" "Boolean values are the two constant objects ``False`` and ``True``. They " "are used to represent truth values (although other values can also be " @@ -7395,15 +7399,15 @@ msgstr "" "valeur en booléen tant que la valeur peut être interprétée en une valeur de " "vérité (voir :ref:`truth` au dessus)." -#: library/stdtypes.rst:5284 +#: library/stdtypes.rst:5285 msgid "They are written as ``False`` and ``True``, respectively." msgstr "Ils s'écrivent ``False`` et ``True``, respectivement." -#: library/stdtypes.rst:5290 +#: library/stdtypes.rst:5291 msgid "Internal Objects" msgstr "Objets internes" -#: library/stdtypes.rst:5292 +#: library/stdtypes.rst:5293 msgid "" "See :ref:`types` for this information. It describes stack frame objects, " "traceback objects, and slice objects." @@ -7411,11 +7415,11 @@ msgstr "" "Voir :ref:`types`. Ils décrivent les objets *stack frame*, *traceback*, et " "*slice*." -#: library/stdtypes.rst:5299 +#: library/stdtypes.rst:5300 msgid "Special Attributes" msgstr "Attributs spéciaux" -#: library/stdtypes.rst:5301 +#: library/stdtypes.rst:5302 msgid "" "The implementation adds a few special read-only attributes to several object " "types, where they are relevant. Some of these are not reported by the :func:" @@ -7425,7 +7429,7 @@ msgstr "" "certains types, lorsque ça a du sens. Certains ne sont *pas* listés par la " "fonction native :func:`dir`." -#: library/stdtypes.rst:5308 +#: library/stdtypes.rst:5309 msgid "" "A dictionary or other mapping object used to store an object's (writable) " "attributes." @@ -7433,20 +7437,20 @@ msgstr "" "Un dictionnaire ou un autre *mapping object* utilisé pour stocker les " "attributs (modifiables) de l'objet." -#: library/stdtypes.rst:5314 +#: library/stdtypes.rst:5315 msgid "The class to which a class instance belongs." msgstr "La classe de l'instance de classe." -#: library/stdtypes.rst:5319 +#: library/stdtypes.rst:5320 msgid "The tuple of base classes of a class object." msgstr "Le *n*-uplet des classes parentes d'un objet classe." -#: library/stdtypes.rst:5324 +#: library/stdtypes.rst:5325 msgid "" "The name of the class, function, method, descriptor, or generator instance." msgstr "Le nom de la classe, fonction, méthode, descripteur, ou générateur." -#: library/stdtypes.rst:5330 +#: library/stdtypes.rst:5331 msgid "" "The :term:`qualified name` of the class, function, method, descriptor, or " "generator instance." @@ -7454,7 +7458,7 @@ msgstr "" "Le :term:`qualified name` de la classe, fonction, méthode, descripteur, ou " "générateur." -#: library/stdtypes.rst:5338 +#: library/stdtypes.rst:5339 msgid "" "This attribute is a tuple of classes that are considered when looking for " "base classes during method resolution." @@ -7462,7 +7466,7 @@ msgstr "" "Cet attribut est un *n*-uplet contenant les classes parents prises en compte " "lors de la résolution de méthode." -#: library/stdtypes.rst:5344 +#: library/stdtypes.rst:5345 msgid "" "This method can be overridden by a metaclass to customize the method " "resolution order for its instances. It is called at class instantiation, " @@ -7473,7 +7477,7 @@ msgstr "" "la l'initialisation de la classe, et son résultat est stocké dans " "l'attribut :attr:`~class.__mro__`." -#: library/stdtypes.rst:5351 +#: library/stdtypes.rst:5352 #, fuzzy msgid "" "Each class keeps a list of weak references to its immediate subclasses. " @@ -7484,11 +7488,11 @@ msgstr "" "immédiates. Cette méthode renvoie la liste de toutes ces références encore " "valables. Exemple ::" -#: library/stdtypes.rst:5360 +#: library/stdtypes.rst:5361 msgid "Footnotes" msgstr "Notes" -#: library/stdtypes.rst:5361 +#: library/stdtypes.rst:5362 msgid "" "Additional information on these special methods may be found in the Python " "Reference Manual (:ref:`customization`)." @@ -7496,7 +7500,7 @@ msgstr "" "Plus d'informations sur ces méthodes spéciales peuvent être trouvées dans le " "*Python Reference Manual* (:ref:`customization`)." -#: library/stdtypes.rst:5364 +#: library/stdtypes.rst:5365 msgid "" "As a consequence, the list ``[1, 2]`` is considered equal to ``[1.0, 2.0]``, " "and similarly for tuples." @@ -7504,13 +7508,13 @@ msgstr "" "Par conséquent, la liste ``[1, 2]`` est considérée égale à ``[1.0, 2.0]``. " "Idem avec des *n*-uplets." -#: library/stdtypes.rst:5367 +#: library/stdtypes.rst:5368 msgid "They must have since the parser can't tell the type of the operands." msgstr "" "Nécessairement, puisque l'analyseur ne peut pas discerner le type des " "opérandes." -#: library/stdtypes.rst:5369 +#: library/stdtypes.rst:5370 msgid "" "Cased characters are those with general category property being one of \"Lu" "\" (Letter, uppercase), \"Ll\" (Letter, lowercase), or \"Lt\" (Letter, " @@ -7520,7 +7524,7 @@ msgstr "" "category* est soit \"Lu\" (pour *Letter*, *uppercase*), soit \"Ll\" (pour " "*Letter*, *lowercase*), soit \"Lt\" (pour *Letter*, *titlecase*)." -#: library/stdtypes.rst:5372 +#: library/stdtypes.rst:5373 msgid "" "To format only a tuple you should therefore provide a singleton tuple whose " "only element is the tuple to be formatted." diff --git a/library/sys.po b/library/sys.po index 987f0c5d..881b7115 100644 --- a/library/sys.po +++ b/library/sys.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-10-21 15:04+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-06-04 15:09+0200\n" "Last-Translator: louisMaury \n" "Language-Team: FRENCH \n" @@ -461,7 +461,7 @@ msgstr "" msgid "Integer specifying the handle of the Python DLL." msgstr "Nombre entier spécifiant le descripteur de la DLL Python." -#: library/sys.rst:810 library/sys.rst:1721 +#: library/sys.rst:810 library/sys.rst:1718 msgid ":ref:`Availability `: Windows." msgstr ":ref:`Disponibilité ` : Windows." @@ -1211,7 +1211,7 @@ msgstr "" "`dlopen`. Les noms symboliques valeurs peuvent être trouvées dans le module :" "mod:`os`. (Ce sont les constantes ``RTLD_xxx`` e.g. :data:`os.RTLD_LAZY`)." -#: library/sys.rst:1260 +#: library/sys.rst:1257 msgid ":ref:`Availability `: Unix." msgstr ":ref:`Disponibilité ` : Unix." @@ -1543,7 +1543,7 @@ msgstr "" msgid "See :pep:`525` for more details." msgstr "Voir la :pep:`525` pour plus d'informations." -#: library/sys.rst:1454 +#: library/sys.rst:1451 msgid "" "This function has been added on a provisional basis (see :pep:`411` for " "details.)" @@ -1560,7 +1560,7 @@ msgstr "" "le suivi de leur création, telle que défini par :func:" "`set_coroutine_origin_tracking_depth`." -#: library/sys.rst:1475 +#: library/sys.rst:1472 msgid "" "This function has been added on a provisional basis (see :pep:`411` for " "details.) Use it only for debugging purposes." @@ -1770,11 +1770,11 @@ msgstr "" "Un :term:`named tuple` qui contient des informations sur la représentation " "interne des entiers de Python. Les attributs sont en lecture seule." -#: library/sys.rst:1606 +#: library/sys.rst:1603 msgid "Attribute" msgstr "Attribut" -#: library/sys.rst:1606 +#: library/sys.rst:1603 msgid "Explanation" msgstr "Explication" @@ -2239,15 +2239,13 @@ msgid "" msgstr "" #: library/sys.rst:1218 +#, fuzzy msgid "" "A string giving the site-specific directory prefix where the platform " -"independent Python files are installed; by default, this is the string ``'/" -"usr/local'``. This can be set at build time with the ``--prefix`` argument " -"to the :program:`configure` script. The main collection of Python library " -"modules is installed in the directory :file:`{prefix}/lib/python{X.Y}` while " -"the platform independent header files (all except :file:`pyconfig.h`) are " -"stored in :file:`{prefix}/include/python{X.Y}`, where *X.Y* is the version " -"number of Python, for example ``3.2``." +"independent Python files are installed; on Unix, the default is ``'/usr/" +"local'``. This can be set at build time with the ``--prefix`` argument to " +"the :program:`configure` script. See :ref:`installation_paths` for derived " +"paths." msgstr "" "Une chaîne donnant le préfixe de répertoire spécifique au site dans lequel " "les fichiers Python indépendants de la plate-forme sont installés. Par " @@ -2259,7 +2257,7 @@ msgstr "" "stockées dans :file:`{prefix}/include/python{X.Y}`, où *X.Y* est le numéro " "de version de Python, par exemple ``3.2``." -#: library/sys.rst:1227 +#: library/sys.rst:1224 msgid "" "If a :ref:`virtual environment ` is in effect, this value will be " "changed in ``site.py`` to point to the virtual environment. The value for " @@ -2270,7 +2268,7 @@ msgstr "" "donnée au moment de la compilation de Python sera toujours disponible, dans :" "data:`base_prefix`." -#: library/sys.rst:1242 +#: library/sys.rst:1239 msgid "" "Strings specifying the primary and secondary prompt of the interpreter. " "These are only defined if the interpreter is in interactive mode. Their " @@ -2287,7 +2285,7 @@ msgstr "" "à lire une nouvelle commande interactive, c'est donc utilisable pour " "implémenter une invite dynamique." -#: library/sys.rst:1252 +#: library/sys.rst:1249 msgid "" "Set the flags used by the interpreter for :c:func:`dlopen` calls, such as " "when the interpreter loads extension modules. Among other things, this will " @@ -2306,7 +2304,7 @@ msgstr "" "trouvés dans le module :mod:`os` (ce sont les constantes ``RTLD_xxx``, " "comme :data:`os.RTLD_LAZY`)." -#: library/sys.rst:1268 +#: library/sys.rst:1265 msgid "" "Set the system's profile function, which allows you to implement a Python " "source code profiler in Python. See chapter :ref:`profile` for more " @@ -2334,7 +2332,7 @@ msgstr "" "*multithread*. Sa valeur de retour n'est pas utilisée, elle peut simplement " "renvoyer ``None``." -#: library/sys.rst:1279 +#: library/sys.rst:1276 msgid "" "Profile functions should have three arguments: *frame*, *event*, and *arg*. " "*frame* is the current stack frame. *event* is a string: ``'call'``, " @@ -2347,21 +2345,21 @@ msgstr "" "``'c_call'``, ``'c_return'`` ou ``'c_exception'``. *arg* dépend du type de " "l'évènement." -#: library/sys.rst:1284 +#: library/sys.rst:1281 msgid "" "Raises an :ref:`auditing event ` ``sys.setprofile`` with no " "arguments." msgstr "" -#: library/sys.rst:1367 +#: library/sys.rst:1364 msgid "The events have the following meaning:" msgstr "Les événements ont la signification suivante :" -#: library/sys.rst:1372 +#: library/sys.rst:1369 msgid "``'call'``" msgstr "``'call'``" -#: library/sys.rst:1289 +#: library/sys.rst:1286 msgid "" "A function is called (or some other code block entered). The profile " "function is called; *arg* is ``None``." @@ -2369,11 +2367,11 @@ msgstr "" "Une fonction est appelée (ou Python entre dans un autre bloc de code). La " "fonction de traçage est appelée, *arg* est ``None``." -#: library/sys.rst:1387 +#: library/sys.rst:1384 msgid "``'return'``" msgstr "``'return'``" -#: library/sys.rst:1293 +#: library/sys.rst:1290 msgid "" "A function (or other code block) is about to return. The profile function " "is called; *arg* is the value that will be returned, or ``None`` if the " @@ -2383,11 +2381,11 @@ msgstr "" "fonction de traçage est appelée, *arg* est la valeur qui sera renvoyée, ou " "``None`` si l'événement est causé par la levée d'une exception." -#: library/sys.rst:1299 +#: library/sys.rst:1296 msgid "``'c_call'``" msgstr "``'c_call'``" -#: library/sys.rst:1298 +#: library/sys.rst:1295 msgid "" "A C function is about to be called. This may be an extension function or a " "built-in. *arg* is the C function object." @@ -2395,23 +2393,23 @@ msgstr "" "Une fonction C est sur le point d'être appelée. C'est soit une fonction " "d'extension ou une fonction native. *arg* représente la fonction C." -#: library/sys.rst:1302 +#: library/sys.rst:1299 msgid "``'c_return'``" msgstr "``'c_return'``" -#: library/sys.rst:1302 +#: library/sys.rst:1299 msgid "A C function has returned. *arg* is the C function object." msgstr "Une fonction C a renvoyé une valeur. *arg* représente la fonction C." -#: library/sys.rst:1304 +#: library/sys.rst:1301 msgid "``'c_exception'``" msgstr "``'c_exception'``" -#: library/sys.rst:1305 +#: library/sys.rst:1302 msgid "A C function has raised an exception. *arg* is the C function object." msgstr "Une fonction C a levé une exception. *arg* représente la fonction C." -#: library/sys.rst:1309 +#: library/sys.rst:1306 msgid "" "Set the maximum depth of the Python interpreter stack to *limit*. This " "limit prevents infinite recursion from causing an overflow of the C stack " @@ -2421,7 +2419,7 @@ msgstr "" "*limit*. Cette limite empêche une récursion infinie de provoquer un " "débordement de la pile C et ainsi un crash de Python." -#: library/sys.rst:1313 +#: library/sys.rst:1310 msgid "" "The highest possible limit is platform-dependent. A user may need to set " "the limit higher when they have a program that requires deep recursion and a " @@ -2433,7 +2431,7 @@ msgstr "" "profonde, si sa plate-forme le permet. Cela doit être fait avec précaution, " "car une limite trop élevée peut conduire à un crash." -#: library/sys.rst:1318 +#: library/sys.rst:1315 msgid "" "If the new limit is too low at the current recursion depth, a :exc:" "`RecursionError` exception is raised." @@ -2441,7 +2439,7 @@ msgstr "" "Si la nouvelle limite est plus basse que la profondeur actuelle, une :exc:" "`RecursionError` est levée." -#: library/sys.rst:1321 +#: library/sys.rst:1318 msgid "" "A :exc:`RecursionError` exception is now raised if the new limit is too low " "at the current recursion depth." @@ -2449,7 +2447,7 @@ msgstr "" "Une :exc:`RecursionError` est maintenant levée si la nouvelle limite est " "plus basse que la profondeur de récursion actuelle." -#: library/sys.rst:1328 +#: library/sys.rst:1325 msgid "" "Set the interpreter's thread switch interval (in seconds). This floating-" "point value determines the ideal duration of the \"timeslices\" allocated to " @@ -2467,7 +2465,7 @@ msgstr "" "d'exécution prenant la main à la fin de l'intervalle revient au système " "d'exploitation. L'interpréteur n'a pas son propre ordonnanceur." -#: library/sys.rst:1345 +#: library/sys.rst:1342 msgid "" "Set the system's trace function, which allows you to implement a Python " "source code debugger in Python. The function is thread-specific; for a " @@ -2482,7 +2480,7 @@ msgstr "" "pour chaque fil d'exécution qu'il souhaite surveiller ou utilisez :func:" "`threading.settrace`." -#: library/sys.rst:1350 +#: library/sys.rst:1347 msgid "" "Trace functions should have three arguments: *frame*, *event*, and *arg*. " "*frame* is the current stack frame. *event* is a string: ``'call'``, " @@ -2494,7 +2492,7 @@ msgstr "" "chaîne de caractères pouvant valoir : ``'call'``, ``'line'``, ``'return'``, " "``'exception'`` ou ``'opcode'``. *arg* dépend du type de l'évènement." -#: library/sys.rst:1355 +#: library/sys.rst:1352 msgid "" "The trace function is invoked (with *event* set to ``'call'``) whenever a " "new local scope is entered; it should return a reference to a local trace " @@ -2506,7 +2504,7 @@ msgstr "" "référence à une fonction de traçage locale à utiliser pour ce *scope*, ou " "``None`` si le *Scope* ne doit pas être tracé." -#: library/sys.rst:1360 +#: library/sys.rst:1357 msgid "" "The local trace function should return a reference to itself (or to another " "function for further tracing in that scope), or ``None`` to turn off tracing " @@ -2516,7 +2514,7 @@ msgstr "" "autre fonction de traçage pour un traçage ultérieur dans cette portée), ou " "``None`` pour désactiver le traçage dans cette portée." -#: library/sys.rst:1364 +#: library/sys.rst:1361 msgid "" "If there is any error occurred in the trace function, it will be unset, just " "like ``settrace(None)`` is called." @@ -2524,7 +2522,7 @@ msgstr "" "Si une erreur se produit dans la fonction de trace, elle sera désactivée, " "tout comme si ``settrace(None)`` avait été appelée." -#: library/sys.rst:1370 +#: library/sys.rst:1367 msgid "" "A function is called (or some other code block entered). The global trace " "function is called; *arg* is ``None``; the return value specifies the local " @@ -2534,11 +2532,11 @@ msgstr "" "globale est appelée, *arg* est ``None``, la valeur renvoyée donne la " "fonction de traçage locale." -#: library/sys.rst:1381 +#: library/sys.rst:1378 msgid "``'line'``" msgstr "``'line'``" -#: library/sys.rst:1375 +#: library/sys.rst:1372 msgid "" "The interpreter is about to execute a new line of code or re-execute the " "condition of a loop. The local trace function is called; *arg* is ``None``; " @@ -2555,7 +2553,7 @@ msgstr "" "désactivés pour un cadre d'exécution en mettant :attr:`f_trace_lines` à :" "const:`False` pour ce cadre d'exécution." -#: library/sys.rst:1384 +#: library/sys.rst:1381 msgid "" "A function (or other code block) is about to return. The local trace " "function is called; *arg* is the value that will be returned, or ``None`` if " @@ -2567,11 +2565,11 @@ msgstr "" "renvoyée, ou ``None`` si l'événement est causé par la levée d'une exception. " "La valeur renvoyée par la fonction de traçage est ignorée." -#: library/sys.rst:1392 +#: library/sys.rst:1389 msgid "``'exception'``" msgstr "``'exception'``" -#: library/sys.rst:1390 +#: library/sys.rst:1387 msgid "" "An exception has occurred. The local trace function is called; *arg* is a " "tuple ``(exception, value, traceback)``; the return value specifies the new " @@ -2581,11 +2579,11 @@ msgstr "" "est le triplet ``(exception, valeur, traceback)``, la valeur renvoyée " "spécifie la nouvelle fonction de traçage locale." -#: library/sys.rst:1400 +#: library/sys.rst:1397 msgid "``'opcode'``" msgstr "``'opcode'``" -#: library/sys.rst:1395 +#: library/sys.rst:1392 msgid "" "The interpreter is about to execute a new opcode (see :mod:`dis` for opcode " "details). The local trace function is called; *arg* is ``None``; the return " @@ -2600,7 +2598,7 @@ msgstr "" "explicitement requis en mettant :attr:`f_trace_opcodes` à :const:`True` pour " "cette *frame*." -#: library/sys.rst:1402 +#: library/sys.rst:1399 msgid "" "Note that as an exception is propagated down the chain of callers, an " "``'exception'`` event is generated at each level." @@ -2608,7 +2606,7 @@ msgstr "" "Remarquez que, comme une exception se propage au travers de toute chaîne " "d'appelants, un événement ``'exception'`` est généré à chaque niveau." -#: library/sys.rst:1405 +#: library/sys.rst:1402 msgid "" "For more fine-grained usage, it's possible to set a trace function by " "assigning ``frame.f_trace = tracefunc`` explicitly, rather than relying on " @@ -2622,19 +2620,19 @@ msgid "" "on each frame)." msgstr "" -#: library/sys.rst:1416 +#: library/sys.rst:1413 msgid "For more information on code and frame objects, refer to :ref:`types`." msgstr "" "Pour plus d'informations sur les objets code et objets représentant une " "*frame* de la pile, consultez :ref:`types`." -#: library/sys.rst:1418 +#: library/sys.rst:1415 msgid "" "Raises an :ref:`auditing event ` ``sys.settrace`` with no " "arguments." msgstr "" -#: library/sys.rst:1422 +#: library/sys.rst:1419 msgid "" "The :func:`settrace` function is intended only for implementing debuggers, " "profilers, coverage tools and the like. Its behavior is part of the " @@ -2647,7 +2645,7 @@ msgstr "" "que de la définition du langage, et peut donc ne pas être disponible dans " "toutes les implémentations de Python." -#: library/sys.rst:1429 +#: library/sys.rst:1426 msgid "" "``'opcode'`` event type added; :attr:`f_trace_lines` and :attr:" "`f_trace_opcodes` attributes added to frames" @@ -2655,7 +2653,7 @@ msgstr "" "Ajout du type d’événement ``'opcode'`` ; les attributs :attr:`f_trace_lines` " "et :attr:`f_trace_opcodes` ont été ajoutés aux cadres d'exécution" -#: library/sys.rst:1434 +#: library/sys.rst:1431 msgid "" "Accepts two optional keyword arguments which are callables that accept an :" "term:`asynchronous generator iterator` as an argument. The *firstiter* " @@ -2669,25 +2667,25 @@ msgstr "" "première fois, et l'appelable *finalizer* sera appelé lorsqu'un générateur " "asynchrone est sur le point d'être détruit." -#: library/sys.rst:1440 +#: library/sys.rst:1437 msgid "" "Raises an :ref:`auditing event ` ``sys." "set_asyncgen_hooks_firstiter`` with no arguments." msgstr "" -#: library/sys.rst:1442 +#: library/sys.rst:1439 msgid "" "Raises an :ref:`auditing event ` ``sys." "set_asyncgen_hooks_finalizer`` with no arguments." msgstr "" -#: library/sys.rst:1444 +#: library/sys.rst:1441 msgid "" "Two auditing events are raised because the underlying API consists of two " "calls, each of which must raise its own event." msgstr "" -#: library/sys.rst:1447 +#: library/sys.rst:1444 msgid "" "See :pep:`525` for more details, and for a reference example of a " "*finalizer* method see the implementation of ``asyncio.Loop." @@ -2697,7 +2695,7 @@ msgstr "" "voir l'implémentation de ``asyncio.Loop.shutdown_asyncgens`` dans :source:" "`Lib/asyncio/base_events.py`" -#: library/sys.rst:1459 +#: library/sys.rst:1456 msgid "" "Allows enabling or disabling coroutine origin tracking. When enabled, the " "``cr_origin`` attribute on coroutine objects will contain a tuple of " @@ -2712,7 +2710,7 @@ msgstr "" "coroutine a été créé, avec l'appel le plus récent en premier. Lorsqu'il est " "désactivé, la valeur de ``cr_origin`` est ``None``." -#: library/sys.rst:1466 +#: library/sys.rst:1463 msgid "" "To enable, pass a *depth* value greater than zero; this sets the number of " "frames whose information will be captured. To disable, pass set *depth* to " @@ -2722,11 +2720,11 @@ msgstr "" "le nombre de cadres d'exécution dont les informations sont capturées. Pour " "le désactiver, mettez *depth* à zéro." -#: library/sys.rst:1470 +#: library/sys.rst:1467 msgid "This setting is thread-specific." msgstr "Ce paramètre est spécifique au fil d'exécution courant." -#: library/sys.rst:1480 +#: library/sys.rst:1477 #, fuzzy msgid "" "Changes the :term:`filesystem encoding and error handler` to 'mbcs' and " @@ -2736,7 +2734,7 @@ msgstr "" "fichiers à *mbcs* et *replace* respectivement, par cohérence avec les " "versions de Python antérieures à la 3.6." -#: library/sys.rst:1484 +#: library/sys.rst:1481 msgid "" "This is equivalent to defining the :envvar:`PYTHONLEGACYWINDOWSFSENCODING` " "environment variable before launching Python." @@ -2744,17 +2742,17 @@ msgstr "" "Équivaut à définir la variable d'environnement :envvar:" "`PYTHONLEGACYWINDOWSFSENCODING` avant de lancer Python." -#: library/sys.rst:1487 +#: library/sys.rst:1484 msgid "" "See also :func:`sys.getfilesystemencoding` and :func:`sys." "getfilesystemencodeerrors`." msgstr "" -#: library/sys.rst:1492 +#: library/sys.rst:1489 msgid "See :pep:`529` for more details." msgstr "Voir la :pep:`529` pour plus d'informations." -#: library/sys.rst:1499 +#: library/sys.rst:1496 msgid "" ":term:`File objects ` used by the interpreter for standard " "input, output and errors:" @@ -2762,7 +2760,7 @@ msgstr "" ":term:`objets fichiers ` utilisés par l'interpréteur pour " "l'entrée standard, la sortie standard et la sortie d'erreurs :" -#: library/sys.rst:1502 +#: library/sys.rst:1499 msgid "" "``stdin`` is used for all interactive input (including calls to :func:" "`input`);" @@ -2770,7 +2768,7 @@ msgstr "" "``stdin`` est utilisé pour toutes les entrées interactives (y compris les " "appels à :func:`input`)" -#: library/sys.rst:1504 +#: library/sys.rst:1501 msgid "" "``stdout`` is used for the output of :func:`print` and :term:`expression` " "statements and for the prompts of :func:`input`;" @@ -2778,13 +2776,13 @@ msgstr "" "``stdout`` est utilisé pour la sortie de :func:`print`, des :term:" "`expression` et pour les invites de :func:`input` ;" -#: library/sys.rst:1506 +#: library/sys.rst:1503 msgid "The interpreter's own prompts and its error messages go to ``stderr``." msgstr "" "Les invites de l'interpréteur et ses messages d'erreur sont écrits sur " "``stderr``." -#: library/sys.rst:1508 +#: library/sys.rst:1505 msgid "" "These streams are regular :term:`text files ` like those returned " "by the :func:`open` function. Their parameters are chosen as follows:" @@ -2793,13 +2791,13 @@ msgstr "" "renvoyés par la fonction :func:`open`. Leurs paramètres sont choisis comme " "suit :" -#: library/sys.rst:1512 +#: library/sys.rst:1509 msgid "" "The encoding and error handling are is initialized from :c:member:`PyConfig." "stdio_encoding` and :c:member:`PyConfig.stdio_errors`." msgstr "" -#: library/sys.rst:1515 +#: library/sys.rst:1512 #, fuzzy msgid "" "On Windows, UTF-8 is used for the console device. Non-character devices " @@ -2821,7 +2819,7 @@ msgstr "" "régionaux système si le processus n'est pas attaché initialement à une " "console." -#: library/sys.rst:1524 +#: library/sys.rst:1521 msgid "" "The special behaviour of the console can be overridden by setting the " "environment variable PYTHONLEGACYWINDOWSSTDIO before starting Python. In " @@ -2832,7 +2830,7 @@ msgstr "" "Python. Dans ce cas, les pages de code de la console sont utilisées comme " "pour tout autre périphérique de caractères." -#: library/sys.rst:1529 +#: library/sys.rst:1526 msgid "" "Under all platforms, you can override the character encoding by setting the :" "envvar:`PYTHONIOENCODING` environment variable before starting Python or by " @@ -2847,7 +2845,7 @@ msgstr "" "Toutefois, pour la console Windows, cela s'applique uniquement lorsque :" "envvar:`PYTHONLEGACYWINDOWSSTDIO` est également défini." -#: library/sys.rst:1536 +#: library/sys.rst:1533 #, fuzzy msgid "" "When interactive, the ``stdout`` stream is line-buffered. Otherwise, it is " @@ -2861,12 +2859,12 @@ msgstr "" "fichiers textes classiques. Vous pouvez remplacer cette valeur avec " "l'option :option:`-u` en ligne de commande." -#: library/sys.rst:1542 +#: library/sys.rst:1539 msgid "" "Non-interactive ``stderr`` is now line-buffered instead of fully buffered." msgstr "" -#: library/sys.rst:1548 +#: library/sys.rst:1545 msgid "" "To write or read binary data from/to the standard streams, use the " "underlying binary :data:`~io.TextIOBase.buffer` object. For example, to " @@ -2877,7 +2875,7 @@ msgstr "" "pour écrire des octets sur :data:`stdout`, utilisez ``sys.stdout.buffer." "write(b'abc')``." -#: library/sys.rst:1552 +#: library/sys.rst:1549 msgid "" "However, if you are writing a library (and do not control in which context " "its code will be executed), be aware that the standard streams may be " @@ -2889,7 +2887,7 @@ msgstr "" "remplacés par des objets de type fichier tel un :class:`io.StringIO` qui " "n'ont pas l'attribut :attr:`~io.BufferedIOBase.buffer`." -#: library/sys.rst:1562 +#: library/sys.rst:1559 msgid "" "These objects contain the original values of ``stdin``, ``stderr`` and " "``stdout`` at the start of the program. They are used during finalization, " @@ -2901,7 +2899,7 @@ msgstr "" "pendant la finalisation, et peuvent être utiles pour écrire dans le vrai " "flux standard, peu importe si l'objet ``sys.std*`` a été redirigé." -#: library/sys.rst:1567 +#: library/sys.rst:1564 msgid "" "It can also be used to restore the actual files to known working file " "objects in case they have been overwritten with a broken object. However, " @@ -2913,7 +2911,7 @@ msgstr "" "cependant la bonne façon de faire serait de sauvegarder explicitement les " "flux avant de les remplacer et ainsi pouvoir les restaurer." -#: library/sys.rst:1573 +#: library/sys.rst:1570 msgid "" "Under some conditions ``stdin``, ``stdout`` and ``stderr`` as well as the " "original values ``__stdin__``, ``__stdout__`` and ``__stderr__`` can be " @@ -2926,12 +2924,12 @@ msgstr "" "Windows qui ne sont pas connectées à une console, ou les applications Python " "démarrées avec :program:`pythonw`." -#: library/sys.rst:1581 +#: library/sys.rst:1578 msgid "" "A frozenset of strings containing the names of standard library modules." msgstr "" -#: library/sys.rst:1583 +#: library/sys.rst:1580 msgid "" "It is the same on all platforms. Modules which are not available on some " "platforms and modules disabled at Python build are also listed. All module " @@ -2939,7 +2937,7 @@ msgid "" "modules are excluded." msgstr "" -#: library/sys.rst:1588 +#: library/sys.rst:1585 msgid "" "For packages, only the main package is listed: sub-packages and sub-modules " "are not listed. For example, the ``email`` package is listed, but the " @@ -2947,63 +2945,63 @@ msgid "" "listed." msgstr "" -#: library/sys.rst:1593 +#: library/sys.rst:1590 msgid "See also the :attr:`sys.builtin_module_names` list." msgstr "" -#: library/sys.rst:1600 +#: library/sys.rst:1597 msgid "" "A :term:`named tuple` holding information about the thread implementation." msgstr "" "Un :term:`named tuple` contenant des informations sur l'implémentation des " "fils d'exécution." -#: library/sys.rst:1608 +#: library/sys.rst:1605 msgid ":const:`name`" msgstr ":const:`name`" -#: library/sys.rst:1608 +#: library/sys.rst:1605 msgid "Name of the thread implementation:" msgstr "Nom de l'implémentation des fils d'exécution :" -#: library/sys.rst:1610 +#: library/sys.rst:1607 msgid "``'nt'``: Windows threads" msgstr "``'nt'`` : Fils d'exécution Windows" -#: library/sys.rst:1611 +#: library/sys.rst:1608 msgid "``'pthread'``: POSIX threads" msgstr "``'pthread'`` : Fils d'exécution POSIX" -#: library/sys.rst:1612 +#: library/sys.rst:1609 msgid "``'solaris'``: Solaris threads" msgstr "``'solaris'`` : Fils d'exécution Solaris" -#: library/sys.rst:1614 +#: library/sys.rst:1611 msgid ":const:`lock`" msgstr ":const:`lock`" -#: library/sys.rst:1614 +#: library/sys.rst:1611 msgid "Name of the lock implementation:" msgstr "Nom de l'implémentation du système de verrou :" -#: library/sys.rst:1616 +#: library/sys.rst:1613 msgid "``'semaphore'``: a lock uses a semaphore" msgstr "``'semaphore'`` : Verrou utilisant une sémaphore" -#: library/sys.rst:1617 +#: library/sys.rst:1614 msgid "``'mutex+cond'``: a lock uses a mutex and a condition variable" msgstr "" "``'mutex+cond'`` : Un verrou utilisant un *mutex* et une *condition variable*" -#: library/sys.rst:1619 +#: library/sys.rst:1616 msgid "``None`` if this information is unknown" msgstr "``None`` si cette information n'est pas connue" -#: library/sys.rst:1621 +#: library/sys.rst:1618 msgid ":const:`version`" msgstr ":const:`version`" -#: library/sys.rst:1621 +#: library/sys.rst:1618 msgid "" "Name and version of the thread library. It is a string, or ``None`` if this " "information is unknown." @@ -3011,7 +3009,7 @@ msgstr "" "Nom et version de l'implémentation des fils d'exécution, c'est une chaîne, " "ou ``None`` si ces informations sont inconnues." -#: library/sys.rst:1630 +#: library/sys.rst:1627 msgid "" "When this variable is set to an integer value, it determines the maximum " "number of levels of traceback information printed when an unhandled " @@ -3025,55 +3023,55 @@ msgstr "" "est égale ou inférieure à ``0``, la pile d'appels n'est pas affichée, seul " "seuls le type et la valeur de l'exception sont le sont." -#: library/sys.rst:1638 +#: library/sys.rst:1635 msgid "Handle an unraisable exception." msgstr "" -#: library/sys.rst:1640 +#: library/sys.rst:1637 msgid "" "Called when an exception has occurred but there is no way for Python to " "handle it. For example, when a destructor raises an exception or during " "garbage collection (:func:`gc.collect`)." msgstr "" -#: library/sys.rst:1644 +#: library/sys.rst:1641 msgid "The *unraisable* argument has the following attributes:" msgstr "Les arguments *unraisable* ont la signification suivante :" -#: library/sys.rst:1646 +#: library/sys.rst:1643 msgid "*exc_type*: Exception type." msgstr "*exc_type* : le type de l'exception ;" -#: library/sys.rst:1647 +#: library/sys.rst:1644 msgid "*exc_value*: Exception value, can be ``None``." msgstr "*exc_value*: la valeur de l'exception, peut être ``None`` ;" -#: library/sys.rst:1648 +#: library/sys.rst:1645 msgid "*exc_traceback*: Exception traceback, can be ``None``." msgstr "" "*exc_traceback* : la pile d'appels pour cette exception, peut être ``None`` ;" -#: library/sys.rst:1649 +#: library/sys.rst:1646 msgid "*err_msg*: Error message, can be ``None``." msgstr "" -#: library/sys.rst:1650 +#: library/sys.rst:1647 msgid "*object*: Object causing the exception, can be ``None``." msgstr "" -#: library/sys.rst:1652 +#: library/sys.rst:1649 msgid "" "The default hook formats *err_msg* and *object* as: ``f'{err_msg}: {object!" "r}'``; use \"Exception ignored in\" error message if *err_msg* is ``None``." msgstr "" -#: library/sys.rst:1656 +#: library/sys.rst:1653 msgid "" ":func:`sys.unraisablehook` can be overridden to control how unraisable " "exceptions are handled." msgstr "" -#: library/sys.rst:1659 +#: library/sys.rst:1656 msgid "" "Storing *exc_value* using a custom hook can create a reference cycle. It " "should be cleared explicitly to break the reference cycle when the exception " @@ -3083,7 +3081,7 @@ msgstr "" "créer un cycle de références. *exc_value* doit être nettoyée explicitement " "pour casser ce cycle lorsque l'exception n'est plus nécessaire." -#: library/sys.rst:1663 +#: library/sys.rst:1660 #, fuzzy msgid "" "Storing *object* using a custom hook can resurrect it if it is set to an " @@ -3095,17 +3093,17 @@ msgstr "" "*thread* après la fin de la fonction de rappel, pour éviter de ressusciter " "des objets." -#: library/sys.rst:1667 +#: library/sys.rst:1664 msgid "See also :func:`excepthook` which handles uncaught exceptions." msgstr "" -#: library/sys.rst:1669 +#: library/sys.rst:1666 msgid "" "Raises an :ref:`auditing event ` ``sys.unraisablehook`` with " "arguments ``hook``, ``unraisable``." msgstr "" -#: library/sys.rst:1671 +#: library/sys.rst:1668 msgid "" "Raise an auditing event ``sys.unraisablehook`` with arguments ``hook``, " "``unraisable`` when an exception that cannot be handled occurs. The " @@ -3113,7 +3111,7 @@ msgid "" "hook has been set, ``hook`` may be ``None``." msgstr "" -#: library/sys.rst:1680 +#: library/sys.rst:1677 msgid "" "A string containing the version number of the Python interpreter plus " "additional information on the build number and compiler used. This string " @@ -3128,7 +3126,7 @@ msgstr "" "utilisez plutôt :data:`version_info` et les fonctions fournies par le " "module :mod:`platform`." -#: library/sys.rst:1689 +#: library/sys.rst:1686 msgid "" "The C API version for this interpreter. Programmers may find this useful " "when debugging version conflicts between Python and extension modules." @@ -3137,7 +3135,7 @@ msgstr "" "trouver cette information utile en déboguant des conflits de versions entre " "Python et des modules d'extension." -#: library/sys.rst:1695 +#: library/sys.rst:1692 msgid "" "A tuple containing the five components of the version number: *major*, " "*minor*, *micro*, *releaselevel*, and *serial*. All values except " @@ -3155,11 +3153,11 @@ msgstr "" "attributs sont aussi accessibles par leur nom, ainsi ``sys.version_info[0]`` " "est équivalent à ``sys.version_info.major``, et ainsi de suite." -#: library/sys.rst:1703 +#: library/sys.rst:1700 msgid "Added named component attributes." msgstr "Ajout des attributs nommés." -#: library/sys.rst:1708 +#: library/sys.rst:1705 msgid "" "This is an implementation detail of the warnings framework; do not modify " "this value. Refer to the :mod:`warnings` module for more information on the " @@ -3169,7 +3167,7 @@ msgstr "" "Ne modifiez pas cette valeur. Reportez-vous au module :mod:`warnings` pour " "plus d'informations sur le gestionnaire d'avertissements." -#: library/sys.rst:1715 +#: library/sys.rst:1712 msgid "" "The version number used to form registry keys on Windows platforms. This is " "stored as string resource 1000 in the Python DLL. The value is normally the " @@ -3184,7 +3182,7 @@ msgstr "" "d'information, et la modifier n'a aucun effet sur les clés de registre " "utilisées par Python." -#: library/sys.rst:1726 +#: library/sys.rst:1723 msgid "" "A dictionary of the various implementation-specific flags passed through " "the :option:`-X` command-line option. Option names are either mapped to " @@ -3195,7 +3193,7 @@ msgstr "" "correspondent soit leur valeur, si elle est donnée explicitement, soit à :" "const:`True`. Exemple :" -#: library/sys.rst:1742 +#: library/sys.rst:1739 msgid "" "This is a CPython-specific way of accessing options passed through :option:`-" "X`. Other implementations may export them through other means, or not at " @@ -3205,11 +3203,11 @@ msgstr "" "l'option :option:`-X`. D'autres implémentations pourraient les exposer par " "d'autres moyens, ou pas du tout." -#: library/sys.rst:1750 +#: library/sys.rst:1747 msgid "Citations" msgstr "Citations" -#: library/sys.rst:1751 +#: library/sys.rst:1748 msgid "" "ISO/IEC 9899:1999. \"Programming languages -- C.\" A public draft of this " "standard is available at http://www.open-std.org/jtc1/sc22/wg14/www/docs/" diff --git a/library/sysconfig.po b/library/sysconfig.po index 707b5cdc..4009684e 100644 --- a/library/sysconfig.po +++ b/library/sysconfig.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: FRENCH \n" @@ -85,11 +85,11 @@ msgstr "" msgid "Example of usage::" msgstr "Exemples d'utilisation ::" -#: library/sysconfig.rst:65 +#: library/sysconfig.rst:66 msgid "Installation paths" msgstr "" -#: library/sysconfig.rst:67 +#: library/sysconfig.rst:68 msgid "" "Python uses an installation scheme that differs depending on the platform " "and on the installation options. These schemes are stored in :mod:" @@ -97,124 +97,128 @@ msgid "" "`os.name`." msgstr "" -#: library/sysconfig.rst:71 +#: library/sysconfig.rst:72 msgid "" "Every new component that is installed using :mod:`distutils` or a Distutils-" "based system will follow the same scheme to copy its file in the right " "places." msgstr "" -#: library/sysconfig.rst:75 -msgid "Python currently supports seven schemes:" +#: library/sysconfig.rst:76 +msgid "Python currently supports six schemes:" msgstr "" -#: library/sysconfig.rst:77 +#: library/sysconfig.rst:78 msgid "" "*posix_prefix*: scheme for POSIX platforms like Linux or macOS. This is the " "default scheme used when Python or a component is installed." msgstr "" -#: library/sysconfig.rst:79 +#: library/sysconfig.rst:80 msgid "" "*posix_home*: scheme for POSIX platforms used when a *home* option is used " "upon installation. This scheme is used when a component is installed " "through Distutils with a specific home prefix." msgstr "" -#: library/sysconfig.rst:82 +#: library/sysconfig.rst:83 msgid "" "*posix_user*: scheme for POSIX platforms used when a component is installed " "through Distutils and the *user* option is used. This scheme defines paths " "located under the user home directory." msgstr "" -#: library/sysconfig.rst:85 +#: library/sysconfig.rst:86 msgid "*nt*: scheme for NT platforms like Windows." msgstr "" -#: library/sysconfig.rst:86 +#: library/sysconfig.rst:87 msgid "*nt_user*: scheme for NT platforms, when the *user* option is used." msgstr "" #: library/sysconfig.rst:88 +msgid "*osx_framework_user*: scheme for macOS, when the *user* option is used." +msgstr "" + +#: library/sysconfig.rst:90 msgid "" "Each scheme is itself composed of a series of paths and each path has a " "unique identifier. Python currently uses eight paths:" msgstr "" -#: library/sysconfig.rst:91 +#: library/sysconfig.rst:93 msgid "" "*stdlib*: directory containing the standard Python library files that are " "not platform-specific." msgstr "" -#: library/sysconfig.rst:93 +#: library/sysconfig.rst:95 msgid "" "*platstdlib*: directory containing the standard Python library files that " "are platform-specific." msgstr "" -#: library/sysconfig.rst:95 +#: library/sysconfig.rst:97 msgid "*platlib*: directory for site-specific, platform-specific files." msgstr "" -#: library/sysconfig.rst:96 +#: library/sysconfig.rst:98 msgid "*purelib*: directory for site-specific, non-platform-specific files." msgstr "" -#: library/sysconfig.rst:97 +#: library/sysconfig.rst:99 msgid "*include*: directory for non-platform-specific header files." msgstr "" -#: library/sysconfig.rst:98 +#: library/sysconfig.rst:100 msgid "*platinclude*: directory for platform-specific header files." msgstr "" -#: library/sysconfig.rst:99 +#: library/sysconfig.rst:101 msgid "*scripts*: directory for script files." msgstr "" -#: library/sysconfig.rst:100 +#: library/sysconfig.rst:102 msgid "*data*: directory for data files." msgstr "" -#: library/sysconfig.rst:102 +#: library/sysconfig.rst:104 msgid ":mod:`sysconfig` provides some functions to determine these paths." msgstr "" -#: library/sysconfig.rst:106 +#: library/sysconfig.rst:108 msgid "" "Return a tuple containing all schemes currently supported in :mod:" "`sysconfig`." msgstr "" -#: library/sysconfig.rst:112 +#: library/sysconfig.rst:114 msgid "Return the default scheme name for the current platform." msgstr "" -#: library/sysconfig.rst:114 +#: library/sysconfig.rst:116 msgid "" "This function was previously named ``_get_default_scheme()`` and considered " "an implementation detail." msgstr "" -#: library/sysconfig.rst:121 +#: library/sysconfig.rst:123 msgid "" "Return a preferred scheme name for an installation layout specified by *key*." msgstr "" -#: library/sysconfig.rst:123 +#: library/sysconfig.rst:125 msgid "*key* must be either ``\"prefix\"``, ``\"home\"``, or ``\"user\"``." msgstr "" -#: library/sysconfig.rst:125 +#: library/sysconfig.rst:127 msgid "" "The return value is a scheme name listed in :func:`get_scheme_names`. It can " "be passed to :mod:`sysconfig` functions that take a *scheme* argument, such " "as :func:`get_paths`." msgstr "" -#: library/sysconfig.rst:134 +#: library/sysconfig.rst:136 msgid "" "Return a dict containing preferred scheme names on the current platform. " "Python implementers and redistributors may add their preferred schemes to " @@ -224,109 +228,109 @@ msgid "" "mix with those by the other." msgstr "" -#: library/sysconfig.rst:141 +#: library/sysconfig.rst:143 msgid "" "End users should not use this function, but :func:`get_default_scheme` and :" "func:`get_preferred_scheme()` instead." msgstr "" -#: library/sysconfig.rst:149 +#: library/sysconfig.rst:151 msgid "" "Return a tuple containing all path names currently supported in :mod:" "`sysconfig`." msgstr "" -#: library/sysconfig.rst:155 +#: library/sysconfig.rst:157 msgid "" "Return an installation path corresponding to the path *name*, from the " "install scheme named *scheme*." msgstr "" -#: library/sysconfig.rst:158 +#: library/sysconfig.rst:160 msgid "" "*name* has to be a value from the list returned by :func:`get_path_names`." msgstr "" -#: library/sysconfig.rst:160 +#: library/sysconfig.rst:162 msgid "" ":mod:`sysconfig` stores installation paths corresponding to each path name, " "for each platform, with variables to be expanded. For instance the *stdlib* " "path for the *nt* scheme is: ``{base}/Lib``." msgstr "" -#: library/sysconfig.rst:164 +#: library/sysconfig.rst:166 msgid "" ":func:`get_path` will use the variables returned by :func:`get_config_vars` " "to expand the path. All variables have default values for each platform so " "one may call this function and get the default value." msgstr "" -#: library/sysconfig.rst:168 +#: library/sysconfig.rst:170 msgid "" "If *scheme* is provided, it must be a value from the list returned by :func:" "`get_scheme_names`. Otherwise, the default scheme for the current platform " "is used." msgstr "" -#: library/sysconfig.rst:172 +#: library/sysconfig.rst:174 msgid "" "If *vars* is provided, it must be a dictionary of variables that will update " "the dictionary return by :func:`get_config_vars`." msgstr "" -#: library/sysconfig.rst:175 +#: library/sysconfig.rst:177 msgid "" "If *expand* is set to ``False``, the path will not be expanded using the " "variables." msgstr "" -#: library/sysconfig.rst:178 +#: library/sysconfig.rst:180 msgid "If *name* is not found, raise a :exc:`KeyError`." msgstr "" -#: library/sysconfig.rst:183 +#: library/sysconfig.rst:185 msgid "" "Return a dictionary containing all installation paths corresponding to an " "installation scheme. See :func:`get_path` for more information." msgstr "" -#: library/sysconfig.rst:186 +#: library/sysconfig.rst:188 msgid "" "If *scheme* is not provided, will use the default scheme for the current " "platform." msgstr "" -#: library/sysconfig.rst:189 +#: library/sysconfig.rst:191 msgid "" "If *vars* is provided, it must be a dictionary of variables that will update " "the dictionary used to expand the paths." msgstr "" -#: library/sysconfig.rst:192 +#: library/sysconfig.rst:194 msgid "If *expand* is set to false, the paths will not be expanded." msgstr "" -#: library/sysconfig.rst:194 +#: library/sysconfig.rst:196 msgid "" "If *scheme* is not an existing scheme, :func:`get_paths` will raise a :exc:" "`KeyError`." msgstr "" -#: library/sysconfig.rst:199 +#: library/sysconfig.rst:201 msgid "Other functions" msgstr "Autres fonctions" -#: library/sysconfig.rst:203 +#: library/sysconfig.rst:205 msgid "" "Return the ``MAJOR.MINOR`` Python version number as a string. Similar to " "``'%d.%d' % sys.version_info[:2]``." msgstr "" -#: library/sysconfig.rst:209 +#: library/sysconfig.rst:211 msgid "Return a string that identifies the current platform." msgstr "" -#: library/sysconfig.rst:211 +#: library/sysconfig.rst:213 msgid "" "This is used mainly to distinguish platform-specific build directories and " "platform-specific built distributions. Typically includes the OS name and " @@ -335,99 +339,99 @@ msgid "" "version isn't particularly important." msgstr "" -#: library/sysconfig.rst:217 +#: library/sysconfig.rst:219 msgid "Examples of returned values:" msgstr "Exemples de valeurs renvoyées :" -#: library/sysconfig.rst:219 +#: library/sysconfig.rst:221 msgid "linux-i586" msgstr "linux-i586" -#: library/sysconfig.rst:220 +#: library/sysconfig.rst:222 msgid "linux-alpha (?)" msgstr "linux-alpha (?)" -#: library/sysconfig.rst:221 +#: library/sysconfig.rst:223 msgid "solaris-2.6-sun4u" msgstr "solaris-2.6-sun4u" -#: library/sysconfig.rst:223 +#: library/sysconfig.rst:225 msgid "Windows will return one of:" msgstr "" -#: library/sysconfig.rst:225 +#: library/sysconfig.rst:227 msgid "win-amd64 (64bit Windows on AMD64, aka x86_64, Intel64, and EM64T)" msgstr "" -#: library/sysconfig.rst:226 +#: library/sysconfig.rst:228 msgid "win32 (all others - specifically, sys.platform is returned)" msgstr "" -#: library/sysconfig.rst:228 +#: library/sysconfig.rst:230 msgid "macOS can return:" msgstr "" -#: library/sysconfig.rst:230 +#: library/sysconfig.rst:232 msgid "macosx-10.6-ppc" msgstr "macosx-10.6-ppc" -#: library/sysconfig.rst:231 +#: library/sysconfig.rst:233 msgid "macosx-10.4-ppc64" msgstr "macosx-10.4-ppc64" -#: library/sysconfig.rst:232 +#: library/sysconfig.rst:234 msgid "macosx-10.3-i386" msgstr "macosx-10.3-i386" -#: library/sysconfig.rst:233 +#: library/sysconfig.rst:235 msgid "macosx-10.4-fat" msgstr "macosx-10.4-fat" -#: library/sysconfig.rst:235 +#: library/sysconfig.rst:237 msgid "" "For other non-POSIX platforms, currently just returns :data:`sys.platform`." msgstr "" -#: library/sysconfig.rst:240 +#: library/sysconfig.rst:242 msgid "" "Return ``True`` if the running Python interpreter was built from source and " "is being run from its built location, and not from a location resulting from " "e.g. running ``make install`` or installing via a binary installer." msgstr "" -#: library/sysconfig.rst:247 +#: library/sysconfig.rst:249 msgid "Parse a :file:`config.h`\\-style file." msgstr "" -#: library/sysconfig.rst:249 +#: library/sysconfig.rst:251 msgid "" "*fp* is a file-like object pointing to the :file:`config.h`\\-like file." msgstr "" -#: library/sysconfig.rst:251 +#: library/sysconfig.rst:253 msgid "" "A dictionary containing name/value pairs is returned. If an optional " "dictionary is passed in as the second argument, it is used instead of a new " "dictionary, and updated with the values read in the file." msgstr "" -#: library/sysconfig.rst:258 +#: library/sysconfig.rst:260 msgid "Return the path of :file:`pyconfig.h`." msgstr "" -#: library/sysconfig.rst:262 +#: library/sysconfig.rst:264 msgid "Return the path of :file:`Makefile`." msgstr "" -#: library/sysconfig.rst:266 +#: library/sysconfig.rst:268 msgid "Using :mod:`sysconfig` as a script" msgstr "" -#: library/sysconfig.rst:268 +#: library/sysconfig.rst:270 msgid "You can use :mod:`sysconfig` as a script with Python's *-m* option:" msgstr "" -#: library/sysconfig.rst:294 +#: library/sysconfig.rst:296 msgid "" "This call will print in the standard output the information returned by :" "func:`get_platform`, :func:`get_python_version`, :func:`get_path` and :func:" diff --git a/library/typing.po b/library/typing.po index 5dc401e4..accb7830 100644 --- a/library/typing.po +++ b/library/typing.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-11-04 18:14+0100\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-05-18 11:06-0400\n" "Last-Translator: Jean-Michel Laprise \n" "Language-Team: FRENCH \n" @@ -332,7 +332,7 @@ msgstr "" "rappel ayant des signatures spécifiques peuvent être typés en utilisant " "``Callable[[Arg1Type, Arg2Type], ReturnType]``." -#: library/typing.rst:1010 library/typing.rst:2088 +#: library/typing.rst:1011 library/typing.rst:2089 msgid "For example::" msgstr "Par exemple ::" @@ -346,7 +346,7 @@ msgstr "" "la signature de l'appel en indiquant des points de suspension à la liste des " "arguments dans l'indice de type : ``Callable[..., ReturnType]``." -#: library/typing.rst:700 +#: library/typing.rst:701 msgid "" "Callables which take other callables as arguments may indicate that their " "parameter types are dependent on each other using :class:`ParamSpec`. " @@ -357,7 +357,7 @@ msgid "" "ReturnType]`` respectively." msgstr "" -#: library/typing.rst:712 +#: library/typing.rst:713 msgid "" "``Callable`` now supports :class:`ParamSpec` and :data:`Concatenate`. See :" "pep:`612` for more information." @@ -393,17 +393,17 @@ msgstr "" "Les génériques peuvent être paramétrés en utilisant une nouvelle fabrique " "(au sens des patrons de conception) disponible en tapant :class:`TypeVar`." -#: library/typing.rst:261 +#: library/typing.rst:262 msgid "User-defined generic types" msgstr "Types génériques définis par l'utilisateur" -#: library/typing.rst:263 +#: library/typing.rst:264 msgid "A user-defined class can be defined as a generic class." msgstr "" "Une classe définie par l'utilisateur peut être définie comme une classe " "générique." -#: library/typing.rst:289 +#: library/typing.rst:290 msgid "" "``Generic[T]`` as a base class defines that the class ``LoggedVar`` takes a " "single type parameter ``T`` . This also makes ``T`` valid as a type within " @@ -413,7 +413,7 @@ msgstr "" "``LoggedVar`` prend un paramètre de type unique ``T``. Ceci rend également " "``T`` valide en tant que type dans le corps de la classe." -#: library/typing.rst:293 +#: library/typing.rst:294 #, fuzzy msgid "" "The :class:`Generic` base class defines :meth:`~object.__class_getitem__` so " @@ -422,7 +422,7 @@ msgstr "" "La classe de base :class:`Generic` définit :meth:`__class_getitem__` de " "sorte que ``LoggedVar[t]`` est valide comme type ::" -#: library/typing.rst:302 +#: library/typing.rst:303 msgid "" "A generic type can have any number of type variables, and type variables may " "be constrained::" @@ -430,7 +430,7 @@ msgstr "" "Un type générique peut avoir un nombre quelconque de variables de type et " "vous pouvez fixer des contraintes sur les variables de type ::" -#: library/typing.rst:314 +#: library/typing.rst:315 msgid "" "Each type variable argument to :class:`Generic` must be distinct. This is " "thus invalid::" @@ -438,22 +438,22 @@ msgstr "" "Chaque argument de variable de type :class:`Generic` doit être distinct. " "Ceci n'est donc pas valable ::" -#: library/typing.rst:325 +#: library/typing.rst:326 msgid "You can use multiple inheritance with :class:`Generic`::" msgstr "Vous pouvez utiliser l'héritage multiple avec :class:`Generic` ::" -#: library/typing.rst:335 +#: library/typing.rst:336 msgid "" "When inheriting from generic classes, some type variables could be fixed::" msgstr "" "Lors de l'héritage de classes génériques, certaines variables de type " "peuvent être corrigées ::" -#: library/typing.rst:345 +#: library/typing.rst:346 msgid "In this case ``MyDict`` has a single parameter, ``T``." msgstr "Dans ce cas, ``MyDict`` a un seul paramètre, ``T``." -#: library/typing.rst:347 +#: library/typing.rst:348 msgid "" "Using a generic class without specifying type parameters assumes :data:`Any` " "for each position. In the following example, ``MyIterable`` is not generic " @@ -464,17 +464,17 @@ msgstr "" "``MyIterable`` n'est pas générique mais hérite implicitement de " "``Iterable[Any]`` ::" -#: library/typing.rst:355 +#: library/typing.rst:356 msgid "User defined generic type aliases are also supported. Examples::" msgstr "" "Les alias de type générique définis par l'utilisateur sont également pris en " "charge. Exemples ::" -#: library/typing.rst:372 +#: library/typing.rst:373 msgid ":class:`Generic` no longer has a custom metaclass." msgstr ":class:`Generic` n'a plus de métaclasse personnalisée." -#: library/typing.rst:375 +#: library/typing.rst:376 msgid "" "User-defined generics for parameter expressions are also supported via " "parameter specification variables in the form ``Generic[P]``. The behavior " @@ -484,7 +484,7 @@ msgid "" "used to substitute a :class:`ParamSpec`::" msgstr "" -#: library/typing.rst:392 +#: library/typing.rst:393 msgid "" "Furthermore, a generic with only one parameter specification variable will " "accept parameter lists in the forms ``X[[Type1, Type2, ...]]`` and also " @@ -492,20 +492,20 @@ msgid "" "converted to the former and are thus equivalent::" msgstr "" -#: library/typing.rst:404 +#: library/typing.rst:405 msgid "" "Do note that generics with :class:`ParamSpec` may not have correct " "``__parameters__`` after substitution in some cases because they are " "intended primarily for static type checking." msgstr "" -#: library/typing.rst:408 +#: library/typing.rst:409 msgid "" ":class:`Generic` can now be parameterized over parameter expressions. See :" "class:`ParamSpec` and :pep:`612` for more details." msgstr "" -#: library/typing.rst:412 +#: library/typing.rst:413 msgid "" "A user-defined generic class can have ABCs as base classes without a " "metaclass conflict. Generic metaclasses are not supported. The outcome of " @@ -518,11 +518,11 @@ msgstr "" "paramétrage des génériques est mis en cache et la plupart des types dans le " "module ``typing`` sont hachables et comparables pour l'égalité." -#: library/typing.rst:419 +#: library/typing.rst:420 msgid "The :data:`Any` type" msgstr "Le type :data:`Any`" -#: library/typing.rst:421 +#: library/typing.rst:422 msgid "" "A special kind of type is :data:`Any`. A static type checker will treat " "every type as being compatible with :data:`Any` and :data:`Any` as being " @@ -532,7 +532,7 @@ msgstr "" "chaque type comme étant compatible avec :data:`Any` et :data:`Any` comme " "étant compatible avec chaque type." -#: library/typing.rst:425 +#: library/typing.rst:426 #, fuzzy msgid "" "This means that it is possible to perform any operation or method call on a " @@ -542,7 +542,7 @@ msgstr "" "appel de méthode sur une valeur de type :data:`Any` et de l'affecter à " "n'importe quelle variable ::" -#: library/typing.rst:443 +#: library/typing.rst:444 msgid "" "Notice that no typechecking is performed when assigning a value of type :" "data:`Any` to a more precise type. For example, the static type checker did " @@ -556,7 +556,7 @@ msgstr "" "de ``a`` à ``s`` même si ``s`` était déclaré être de type :class:`str` et " "reçoit une valeur :class:`int` au moment de son exécution !" -#: library/typing.rst:449 +#: library/typing.rst:450 msgid "" "Furthermore, all functions without a return type or parameter types will " "implicitly default to using :data:`Any`::" @@ -564,7 +564,7 @@ msgstr "" "De plus, toutes les fonctions sans type de retour ni type de paramètre sont " "considérées comme utilisant :data:`Any` implicitement par défaut ::" -#: library/typing.rst:462 +#: library/typing.rst:463 msgid "" "This behavior allows :data:`Any` to be used as an *escape hatch* when you " "need to mix dynamically and statically typed code." @@ -572,7 +572,7 @@ msgstr "" "Ce comportement permet à :data:`Any` d'être utilisé comme succédané lorsque " "vous avez besoin de mélanger du code typé dynamiquement et statiquement." -#: library/typing.rst:465 +#: library/typing.rst:466 msgid "" "Contrast the behavior of :data:`Any` with the behavior of :class:`object`. " "Similar to :data:`Any`, every type is a subtype of :class:`object`. However, " @@ -584,7 +584,7 @@ msgstr "" "`object`. Cependant, contrairement à :data:`Any`, l'inverse n'est pas " "vrai : :class:`object` n'est *pas* un sous-type de chaque autre type." -#: library/typing.rst:470 +#: library/typing.rst:471 msgid "" "That means when the type of a value is :class:`object`, a type checker will " "reject almost all operations on it, and assigning it to a variable (or using " @@ -596,7 +596,7 @@ msgstr "" "l'affecter à une variable (ou l'utiliser comme une valeur de retour) d'un " "type plus spécialisé est une erreur de typage. Par exemple ::" -#: library/typing.rst:492 +#: library/typing.rst:493 msgid "" "Use :class:`object` to indicate that a value could be any type in a typesafe " "manner. Use :data:`Any` to indicate that a value is dynamically typed." @@ -605,11 +605,11 @@ msgstr "" "quel type de manière sûre. Utiliser :data:`Any` pour indiquer qu'une valeur " "est typée dynamiquement." -#: library/typing.rst:497 +#: library/typing.rst:498 msgid "Nominal vs structural subtyping" msgstr "Sous-typage nominal et sous-typage structurel" -#: library/typing.rst:499 +#: library/typing.rst:500 msgid "" "Initially :pep:`484` defined Python static type system as using *nominal " "subtyping*. This means that a class ``A`` is allowed where a class ``B`` is " @@ -620,7 +620,7 @@ msgstr "" "est permise lorsqu'une classe ``B`` est prévue si et seulement si ``A`` est " "une sous-classe de ``B``." -#: library/typing.rst:503 +#: library/typing.rst:504 #, fuzzy msgid "" "This requirement previously also applied to abstract base classes, such as :" @@ -636,7 +636,7 @@ msgstr "" "Python idiomatique typé dynamiquement. Par exemple, ceci est conforme à la :" "pep:`484` ::" -#: library/typing.rst:516 +#: library/typing.rst:517 msgid "" ":pep:`544` allows to solve this problem by allowing users to write the above " "code without explicit base classes in the class definition, allowing " @@ -651,7 +651,7 @@ msgstr "" "de type statique. C'est ce qu'on appelle le *sous-typage structurel* (ou " "typage canard) ::" -#: library/typing.rst:532 +#: library/typing.rst:533 msgid "" "Moreover, by subclassing a special class :class:`Protocol`, a user can " "define new custom protocols to fully enjoy structural subtyping (see " @@ -661,16 +661,16 @@ msgstr "" "utilisateur peut définir de nouveaux protocoles personnalisés pour profiter " "pleinement du sous-typage structurel (voir exemples ci-dessous)." -#: library/typing.rst:537 +#: library/typing.rst:538 msgid "Module contents" msgstr "" -#: library/typing.rst:539 +#: library/typing.rst:540 #, fuzzy msgid "The module defines the following classes, functions and decorators." msgstr "Ce module définit les classes, fonctions et décorateurs suivants :" -#: library/typing.rst:543 +#: library/typing.rst:544 msgid "" "This module defines several types that are subclasses of pre-existing " "standard library classes which also extend :class:`Generic` to support type " @@ -678,7 +678,7 @@ msgid "" "corresponding pre-existing classes were enhanced to support ``[]``." msgstr "" -#: library/typing.rst:549 +#: library/typing.rst:550 msgid "" "The redundant types are deprecated as of Python 3.9 but no deprecation " "warnings will be issued by the interpreter. It is expected that type " @@ -686,64 +686,64 @@ msgid "" "Python 3.9 or newer." msgstr "" -#: library/typing.rst:554 +#: library/typing.rst:555 msgid "" "The deprecated types will be removed from the :mod:`typing` module in the " "first Python version released 5 years after the release of Python 3.9.0. See " "details in :pep:`585`—*Type Hinting Generics In Standard Collections*." msgstr "" -#: library/typing.rst:560 +#: library/typing.rst:561 msgid "Special typing primitives" msgstr "" -#: library/typing.rst:563 +#: library/typing.rst:564 #, fuzzy msgid "Special types" msgstr "Type « optionnel »." -#: library/typing.rst:565 +#: library/typing.rst:566 msgid "These can be used as types in annotations and do not support ``[]``." msgstr "" -#: library/typing.rst:569 +#: library/typing.rst:570 msgid "Special type indicating an unconstrained type." msgstr "Type spécial indiquant un type non contraint." -#: library/typing.rst:571 +#: library/typing.rst:572 msgid "Every type is compatible with :data:`Any`." msgstr "Chaque type est compatible avec :data:`Any`." -#: library/typing.rst:572 +#: library/typing.rst:573 msgid ":data:`Any` is compatible with every type." msgstr ":data:`Any` est compatible avec tous les types." -#: library/typing.rst:576 +#: library/typing.rst:577 msgid "Special type indicating that a function never returns. For example::" msgstr "Type spécial indiquant qu'une fonction ne renvoie rien. Par exemple ::" -#: library/typing.rst:589 +#: library/typing.rst:590 msgid "" "Special annotation for explicitly declaring a :ref:`type alias `. For example::" msgstr "" -#: library/typing.rst:596 +#: library/typing.rst:597 #, fuzzy msgid "See :pep:`613` for more details about explicit type aliases." msgstr "Voir la :pep:`484` pour plus de détails." -#: library/typing.rst:601 +#: library/typing.rst:602 msgid "Special forms" msgstr "" -#: library/typing.rst:603 +#: library/typing.rst:604 msgid "" "These can be used as types in annotations using ``[]``, each having a unique " "syntax." msgstr "" -#: library/typing.rst:607 +#: library/typing.rst:608 msgid "" "Tuple type; ``Tuple[X, Y]`` is the type of a tuple of two items with the " "first item of type X and the second of type Y. The type of the empty tuple " @@ -753,7 +753,7 @@ msgstr "" "éléments avec le premier élément de type X et le second de type Y. Le type " "du *n*-uplet vide peut être écrit comme ``Tuple[()]``." -#: library/typing.rst:611 +#: library/typing.rst:612 msgid "" "Example: ``Tuple[T1, T2]`` is a tuple of two elements corresponding to type " "variables T1 and T2. ``Tuple[int, float, str]`` is a tuple of an int, a " @@ -763,7 +763,7 @@ msgstr "" "type ``T1`` et ``T2``. ``Tuple[int, float, str]`` est un triplet composé " "d'un entier, d'un flottant et d'une chaîne de caractères." -#: library/typing.rst:615 +#: library/typing.rst:616 msgid "" "To specify a variable-length tuple of homogeneous type, use literal " "ellipsis, e.g. ``Tuple[int, ...]``. A plain :data:`Tuple` is equivalent to " @@ -774,7 +774,7 @@ msgstr "" "`Tuple` est équivalent à ``Tuple[Any, ....]`` et, à son tour, à :class:" "`tuple`." -#: library/typing.rst:619 +#: library/typing.rst:620 msgid "" ":class:`builtins.tuple ` now supports ``[]``. See :pep:`585` and :ref:" "`types-genericalias`." @@ -782,14 +782,14 @@ msgstr "" ":class:`builtins.tuple ` prend désormais en charge ``[]``. Voir :pep:" "`585` et :ref:`types-genericalias`." -#: library/typing.rst:625 +#: library/typing.rst:626 #, fuzzy msgid "" "Union type; ``Union[X, Y]`` is equivalent to ``X | Y`` and means either X or " "Y." msgstr "Type « union » ; ``Union[X, Y]`` signifie X ou Y." -#: library/typing.rst:627 +#: library/typing.rst:628 #, fuzzy msgid "" "To define a union, use e.g. ``Union[int, str]`` or the shorthand ``int | " @@ -797,58 +797,58 @@ msgid "" msgstr "" "Pour définir une union, utilisez par exemple ``Union[int, str]``. Détail :" -#: library/typing.rst:629 +#: library/typing.rst:630 msgid "The arguments must be types and there must be at least one." msgstr "" "Les arguments doivent être des types et il doit y en avoir au moins un." -#: library/typing.rst:631 +#: library/typing.rst:632 msgid "Unions of unions are flattened, e.g.::" msgstr "Les unions d'unions sont aplanies, par exemple ::" -#: library/typing.rst:635 +#: library/typing.rst:636 msgid "Unions of a single argument vanish, e.g.::" msgstr "Les unions d'un seul argument disparaissent, par exemple ::" -#: library/typing.rst:639 +#: library/typing.rst:640 msgid "Redundant arguments are skipped, e.g.::" msgstr "Les arguments redondants sont ignorés, par exemple ::" -#: library/typing.rst:643 +#: library/typing.rst:644 msgid "When comparing unions, the argument order is ignored, e.g.::" msgstr "" "Lors de la comparaison d'unions, l'ordre des arguments est ignoré, par " "exemple ::" -#: library/typing.rst:647 +#: library/typing.rst:648 #, fuzzy msgid "You cannot subclass or instantiate a ``Union``." msgstr "Vous ne pouvez pas sous-classer ou instancier une union." -#: library/typing.rst:649 +#: library/typing.rst:650 msgid "You cannot write ``Union[X][Y]``." msgstr "Vous ne pouvez pas écrire ``Union[X][Y]``." -#: library/typing.rst:651 +#: library/typing.rst:652 msgid "Don't remove explicit subclasses from unions at runtime." msgstr "Ne supprime pas les sous-classes explicites des unions à l'exécution." -#: library/typing.rst:654 +#: library/typing.rst:655 msgid "" "Unions can now be written as ``X | Y``. See :ref:`union type " "expressions`." msgstr "" -#: library/typing.rst:660 +#: library/typing.rst:661 msgid "Optional type." msgstr "Type « optionnel »." -#: library/typing.rst:662 +#: library/typing.rst:663 #, fuzzy msgid "``Optional[X]`` is equivalent to ``X | None`` (or ``Union[X, None]``)." msgstr "``Optional[X]`` équivaut à ``Union[X, None]``." -#: library/typing.rst:664 +#: library/typing.rst:665 msgid "" "Note that this is not the same concept as an optional argument, which is one " "that has a default. An optional argument with a default does not require " @@ -860,7 +860,7 @@ msgstr "" "valeur par défaut) ne nécessite pas, à ce titre, le qualificatif " "``Optional`` sur son annotation de type. Par exemple ::" -#: library/typing.rst:672 +#: library/typing.rst:673 msgid "" "On the other hand, if an explicit value of ``None`` is allowed, the use of " "``Optional`` is appropriate, whether the argument is optional or not. For " @@ -870,19 +870,19 @@ msgstr "" "de ``Optional`` est appropriée, que l'argument soit facultatif ou non. Par " "exemple ::" -#: library/typing.rst:679 +#: library/typing.rst:680 msgid "" "Optional can now be written as ``X | None``. See :ref:`union type " "expressions`." msgstr "" -#: library/typing.rst:685 +#: library/typing.rst:686 msgid "Callable type; ``Callable[[int], str]`` is a function of (int) -> str." msgstr "" "Type Appelable. ``Callable[[int], str]`` est une fonction de type ``(int) -> " "str``." -#: library/typing.rst:687 +#: library/typing.rst:688 msgid "" "The subscription syntax must always be used with exactly two values: the " "argument list and the return type. The argument list must be a list of " @@ -893,7 +893,7 @@ msgstr "" "retour. La liste d'arguments doit être une liste de types ou une ellipse ; " "il doit y avoir un seul type de retour." -#: library/typing.rst:692 +#: library/typing.rst:693 msgid "" "There is no syntax to indicate optional or keyword arguments; such function " "types are rarely used as callback types. ``Callable[..., ReturnType]`` " @@ -910,7 +910,7 @@ msgstr "" "équivalent à ``Callable[..., Any]`` et, à son tour, à :class:`collections." "abc.Callable`." -#: library/typing.rst:708 +#: library/typing.rst:709 msgid "" ":class:`collections.abc.Callable` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -918,13 +918,13 @@ msgstr "" ":class:`collections.abc.Callable` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:717 +#: library/typing.rst:718 msgid "" "The documentation for :class:`ParamSpec` and :class:`Concatenate` provide " "examples of usage with ``Callable``." msgstr "" -#: library/typing.rst:722 +#: library/typing.rst:723 msgid "" "Used with :data:`Callable` and :class:`ParamSpec` to type annotate a higher " "order callable which adds, removes, or transforms parameters of another " @@ -934,7 +934,7 @@ msgid "" "``Concatenate`` must be a :class:`ParamSpec`." msgstr "" -#: library/typing.rst:729 +#: library/typing.rst:730 msgid "" "For example, to annotate a decorator ``with_lock`` which provides a :class:" "`threading.Lock` to the decorated function, ``Concatenate`` can be used to " @@ -945,17 +945,17 @@ msgid "" "passed in::" msgstr "" -#: library/typing.rst:1189 +#: library/typing.rst:1190 msgid "" ":pep:`612` -- Parameter Specification Variables (the PEP which introduced " "``ParamSpec`` and ``Concatenate``)." msgstr "" -#: library/typing.rst:771 +#: library/typing.rst:772 msgid ":class:`ParamSpec` and :class:`Callable`." msgstr "" -#: library/typing.rst:776 +#: library/typing.rst:777 msgid "" "A variable annotated with ``C`` may accept a value of type ``C``. In " "contrast, a variable annotated with ``Type[C]`` may accept values that are " @@ -967,11 +967,11 @@ msgstr "" "qui sont elles-mêmes des classes — plus précisément, elle accepte l'objet " "*class* de ``C``. Par exemple ::" -#: library/typing.rst:785 +#: library/typing.rst:786 msgid "Note that ``Type[C]`` is covariant::" msgstr "Notez que ``Type[C]`` est covariant ::" -#: library/typing.rst:797 +#: library/typing.rst:798 msgid "" "The fact that ``Type[C]`` is covariant implies that all subclasses of ``C`` " "should implement the same constructor signature and class method signatures " @@ -989,7 +989,7 @@ msgstr "" "de type est tenu de traiter ce cas particulier peut changer dans les futures " "révisions de :pep:`484`." -#: library/typing.rst:805 +#: library/typing.rst:806 msgid "" "The only legal parameters for :class:`Type` are classes, :data:`Any`, :ref:" "`type variables `, and unions of any of these types. For example::" @@ -998,7 +998,7 @@ msgstr "" "`Any`, :ref:`type variables `, et les unions de ces types. Par " "exemple ::" -#: library/typing.rst:811 +#: library/typing.rst:812 msgid "" "``Type[Any]`` is equivalent to ``Type`` which in turn is equivalent to " "``type``, which is the root of Python's metaclass hierarchy." @@ -1006,7 +1006,7 @@ msgstr "" "``Type[Any]`` est équivalent à ``Type`` qui à son tour est équivalent à " "``type``, qui est la racine de la hiérarchie des métaclasses de Python." -#: library/typing.rst:816 +#: library/typing.rst:817 msgid "" ":class:`builtins.type ` now supports ``[]``. See :pep:`585` and :ref:" "`types-genericalias`." @@ -1014,7 +1014,7 @@ msgstr "" ":class:`builtins.type ` prend désormais en charge ``[]``. Voir :pep:" "`585` et :ref:`types-genericalias`." -#: library/typing.rst:822 +#: library/typing.rst:823 msgid "" "A type that can be used to indicate to type checkers that the corresponding " "variable or function parameter has a value equivalent to the provided " @@ -1024,7 +1024,7 @@ msgstr "" "de fonction correspondant a une valeur équivalente au littéral fourni (ou un " "parmi plusieurs littéraux). Par exemple ::" -#: library/typing.rst:836 +#: library/typing.rst:837 msgid "" "``Literal[...]`` cannot be subclassed. At runtime, an arbitrary value is " "allowed as type argument to ``Literal[...]``, but type checkers may impose " @@ -1035,7 +1035,7 @@ msgstr "" "les vérificateurs de type peuvent imposer des restrictions. Voir la :pep:" "`586` pour plus de détails sur les types littéraux." -#: library/typing.rst:842 +#: library/typing.rst:843 msgid "" "``Literal`` now de-duplicates parameters. Equality comparisons of " "``Literal`` objects are no longer order dependent. ``Literal`` objects will " @@ -1043,12 +1043,12 @@ msgid "" "their parameters are not :term:`hashable`." msgstr "" -#: library/typing.rst:850 +#: library/typing.rst:851 msgid "Special type construct to mark class variables." msgstr "" "Construction de type particulière pour indiquer les variables de classe." -#: library/typing.rst:852 +#: library/typing.rst:853 msgid "" "As introduced in :pep:`526`, a variable annotation wrapped in ClassVar " "indicates that a given attribute is intended to be used as a class variable " @@ -1059,11 +1059,11 @@ msgstr "" "utilisé comme une variable de classe et ne doit pas être défini sur des " "instances de cette classe. Utilisation ::" -#: library/typing.rst:860 +#: library/typing.rst:861 msgid ":data:`ClassVar` accepts only types and cannot be further subscribed." msgstr ":data:`ClassVar` n'accepte que les types et ne peut plus être dérivé." -#: library/typing.rst:862 +#: library/typing.rst:863 msgid "" ":data:`ClassVar` is not a class itself, and should not be used with :func:" "`isinstance` or :func:`issubclass`. :data:`ClassVar` does not change Python " @@ -1076,7 +1076,7 @@ msgstr "" "par des vérificateurs tiers. Par exemple, un vérificateur de type peut " "marquer le code suivant comme une erreur ::" -#: library/typing.rst:876 +#: library/typing.rst:877 msgid "" "A special typing construct to indicate to type checkers that a name cannot " "be re-assigned or overridden in a subclass. For example::" @@ -1085,7 +1085,7 @@ msgstr "" "qu'un nom ne peut pas être réassigné ou remplacé dans une sous-classe. Par " "exemple ::" -#: library/typing.rst:1983 +#: library/typing.rst:1984 msgid "" "There is no runtime checking of these properties. See :pep:`591` for more " "details." @@ -1093,7 +1093,7 @@ msgstr "" "Ces propriétés ne sont pas vérifiées à l'exécution. Voir la :pep:`591` pour " "plus de détails." -#: library/typing.rst:895 +#: library/typing.rst:896 msgid "" "A type, introduced in :pep:`593` (``Flexible function and variable " "annotations``), to decorate existing types with context-specific metadata " @@ -1110,7 +1110,7 @@ msgid "" "``x`` within a specific application." msgstr "" -#: library/typing.rst:909 +#: library/typing.rst:910 msgid "" "Ultimately, the responsibility of how to interpret the annotations (if at " "all) is the responsibility of the tool or library encountering the " @@ -1119,21 +1119,21 @@ msgid "" "using ``isinstance()``)." msgstr "" -#: library/typing.rst:915 +#: library/typing.rst:916 msgid "" "When a tool or a library does not support annotations or encounters an " "unknown annotation it should just ignore it and treat annotated type as the " "underlying type." msgstr "" -#: library/typing.rst:919 +#: library/typing.rst:920 msgid "" "It's up to the tool consuming the annotations to decide whether the client " "is allowed to have several annotations on one type and how to merge those " "annotations." msgstr "" -#: library/typing.rst:923 +#: library/typing.rst:924 msgid "" "Since the ``Annotated`` type allows you to put several annotations of the " "same (or different) type(s) on any node, the tools or libraries consuming " @@ -1141,59 +1141,59 @@ msgid "" "example, if you are doing value range analysis you might allow this::" msgstr "" -#: library/typing.rst:932 +#: library/typing.rst:933 msgid "" "Passing ``include_extras=True`` to :func:`get_type_hints` lets one access " "the extra annotations at runtime." msgstr "" -#: library/typing.rst:935 +#: library/typing.rst:936 msgid "The details of the syntax:" msgstr "" -#: library/typing.rst:937 +#: library/typing.rst:938 msgid "The first argument to ``Annotated`` must be a valid type" msgstr "" -#: library/typing.rst:939 +#: library/typing.rst:940 msgid "" "Multiple type annotations are supported (``Annotated`` supports variadic " "arguments)::" msgstr "" -#: library/typing.rst:944 +#: library/typing.rst:945 msgid "" "``Annotated`` must be called with at least two arguments " "( ``Annotated[int]`` is not valid)" msgstr "" -#: library/typing.rst:947 +#: library/typing.rst:948 msgid "" "The order of the annotations is preserved and matters for equality checks::" msgstr "" -#: library/typing.rst:954 +#: library/typing.rst:955 msgid "" "Nested ``Annotated`` types are flattened, with metadata ordered starting " "with the innermost annotation::" msgstr "" -#: library/typing.rst:961 +#: library/typing.rst:962 msgid "Duplicated annotations are not removed::" msgstr "" -#: library/typing.rst:967 +#: library/typing.rst:968 msgid "``Annotated`` can be used with nested and generic aliases::" msgstr "" -#: library/typing.rst:980 +#: library/typing.rst:981 msgid "" "Special typing form used to annotate the return type of a user-defined type " "guard function. ``TypeGuard`` only accepts a single type argument. At " "runtime, functions marked this way should return a boolean." msgstr "" -#: library/typing.rst:984 +#: library/typing.rst:985 msgid "" "``TypeGuard`` aims to benefit *type narrowing* -- a technique used by static " "type checkers to determine a more precise type of an expression within a " @@ -1202,44 +1202,44 @@ msgid "" "conditional expression here is sometimes referred to as a \"type guard\"::" msgstr "" -#: library/typing.rst:999 +#: library/typing.rst:1000 msgid "" "Sometimes it would be convenient to use a user-defined boolean function as a " "type guard. Such a function should use ``TypeGuard[...]`` as its return " "type to alert static type checkers to this intention." msgstr "" -#: library/typing.rst:1003 +#: library/typing.rst:1004 msgid "" "Using ``-> TypeGuard`` tells the static type checker that for a given " "function:" msgstr "" -#: library/typing.rst:1006 +#: library/typing.rst:1007 msgid "The return value is a boolean." msgstr "" -#: library/typing.rst:1007 +#: library/typing.rst:1008 msgid "" "If the return value is ``True``, the type of its argument is the type inside " "``TypeGuard``." msgstr "" -#: library/typing.rst:1024 +#: library/typing.rst:1025 msgid "" "If ``is_str_list`` is a class or instance method, then the type in " "``TypeGuard`` maps to the type of the second parameter after ``cls`` or " "``self``." msgstr "" -#: library/typing.rst:1028 +#: library/typing.rst:1029 msgid "" "In short, the form ``def foo(arg: TypeA) -> TypeGuard[TypeB]: ...``, means " "that if ``foo(arg)`` returns ``True``, then ``arg`` narrows from ``TypeA`` " "to ``TypeB``." msgstr "" -#: library/typing.rst:1034 +#: library/typing.rst:1035 msgid "" "``TypeB`` need not be a narrower form of ``TypeA`` -- it can even be a wider " "form. The main reason is to allow for things like narrowing ``List[object]`` " @@ -1248,28 +1248,28 @@ msgid "" "guards is left to the user." msgstr "" -#: library/typing.rst:1040 +#: library/typing.rst:1041 msgid "" "``TypeGuard`` also works with type variables. For more information, see :" "pep:`647` (User-Defined Type Guards)." msgstr "" -#: library/typing.rst:1047 +#: library/typing.rst:1048 #, fuzzy msgid "Building generic types" msgstr "Types génériques définis par l'utilisateur" -#: library/typing.rst:1049 +#: library/typing.rst:1050 msgid "" "These are not used in annotations. They are building blocks for creating " "generic types." msgstr "" -#: library/typing.rst:1053 +#: library/typing.rst:1054 msgid "Abstract base class for generic types." msgstr "Classe de base abstraite pour les types génériques." -#: library/typing.rst:1055 +#: library/typing.rst:1056 msgid "" "A generic type is typically declared by inheriting from an instantiation of " "this class with one or more type variables. For example, a generic mapping " @@ -1279,19 +1279,19 @@ msgstr "" "de cette classe avec une ou plusieurs variables de type. Par exemple, un " "type de correspondance générique peut être défini comme suit ::" -#: library/typing.rst:1064 +#: library/typing.rst:1065 msgid "This class can then be used as follows::" msgstr "Cette classe peut alors être utilisée comme suit ::" -#: library/typing.rst:1077 +#: library/typing.rst:1078 msgid "Type variable." msgstr "Variables de type." -#: library/typing.rst:1118 library/typing.rst:1295 +#: library/typing.rst:1119 library/typing.rst:1296 msgid "Usage::" msgstr "Utilisation ::" -#: library/typing.rst:1084 +#: library/typing.rst:1085 #, fuzzy msgid "" "Type variables exist primarily for the benefit of static type checkers. " @@ -1305,7 +1305,7 @@ msgstr "" "``Generic`` pour plus d'informations sur les types génériques. Les fonctions " "génériques fonctionnent comme suit ::" -#: library/typing.rst:1097 +#: library/typing.rst:1098 msgid "" "The latter example's signature is essentially the overloading of ``(str, " "str) -> str`` and ``(bytes, bytes) -> bytes``. Also note that if the " @@ -1317,7 +1317,7 @@ msgstr "" "les arguments sont des instances d'une sous-classe de la classe :class:" "`str`, le type de retour est toujours la classe :class:`str`." -#: library/typing.rst:1102 +#: library/typing.rst:1103 msgid "" "At runtime, ``isinstance(x, T)`` will raise :exc:`TypeError`. In general, :" "func:`isinstance` and :func:`issubclass` should not be used with types." @@ -1326,7 +1326,7 @@ msgstr "" "général, :func:`isinstance` et :func:`issubclass` ne devraient pas être " "utilisés avec les types." -#: library/typing.rst:1105 +#: library/typing.rst:1106 msgid "" "Type variables may be marked covariant or contravariant by passing " "``covariant=True`` or ``contravariant=True``. See :pep:`484` for more " @@ -1343,13 +1343,13 @@ msgstr "" "(explicitement ou implicitement) à la variable type doit être une sous-" "classe du type frontière (*boundary* en anglais), voir la :pep:`484`." -#: library/typing.rst:1115 +#: library/typing.rst:1116 msgid "" "Parameter specification variable. A specialized version of :class:`type " "variables `." msgstr "" -#: library/typing.rst:1122 +#: library/typing.rst:1123 msgid "" "Parameter specification variables exist primarily for the benefit of static " "type checkers. They are used to forward the parameter types of one callable " @@ -1359,7 +1359,7 @@ msgid "" "See :class:`Generic` for more information on generic types." msgstr "" -#: library/typing.rst:1129 +#: library/typing.rst:1130 msgid "" "For example, to add basic logging to a function, one can create a decorator " "``add_logging`` to log function calls. The parameter specification variable " @@ -1367,27 +1367,27 @@ msgid "" "new callable returned by it have inter-dependent type parameters::" msgstr "" -#: library/typing.rst:1153 +#: library/typing.rst:1154 msgid "" "Without ``ParamSpec``, the simplest way to annotate this previously was to " "use a :class:`TypeVar` with bound ``Callable[..., Any]``. However this " "causes two problems:" msgstr "" -#: library/typing.rst:1157 +#: library/typing.rst:1158 msgid "" "The type checker can't type check the ``inner`` function because ``*args`` " "and ``**kwargs`` have to be typed :data:`Any`." msgstr "" -#: library/typing.rst:1159 +#: library/typing.rst:1160 msgid "" ":func:`~cast` may be required in the body of the ``add_logging`` decorator " "when returning the ``inner`` function, or the static type checker must be " "told to ignore the ``return inner``." msgstr "" -#: library/typing.rst:1166 +#: library/typing.rst:1167 msgid "" "Since ``ParamSpec`` captures both positional and keyword parameters, ``P." "args`` and ``P.kwargs`` can be used to split a ``ParamSpec`` into its " @@ -1400,7 +1400,7 @@ msgid "" "`ParamSpecKwargs`." msgstr "" -#: library/typing.rst:1176 +#: library/typing.rst:1177 msgid "" "Parameter specification variables created with ``covariant=True`` or " "``contravariant=True`` can be used to declare covariant or contravariant " @@ -1409,17 +1409,17 @@ msgid "" "decided." msgstr "" -#: library/typing.rst:1185 +#: library/typing.rst:1186 msgid "" "Only parameter specification variables defined in global scope can be " "pickled." msgstr "" -#: library/typing.rst:1191 +#: library/typing.rst:1192 msgid ":class:`Callable` and :class:`Concatenate`." msgstr "" -#: library/typing.rst:1196 +#: library/typing.rst:1197 msgid "" "Arguments and keyword arguments attributes of a :class:`ParamSpec`. The ``P." "args`` attribute of a ``ParamSpec`` is an instance of ``ParamSpecArgs``, and " @@ -1427,13 +1427,13 @@ msgid "" "runtime introspection and have no special meaning to static type checkers." msgstr "" -#: library/typing.rst:1201 +#: library/typing.rst:1202 msgid "" "Calling :func:`get_origin` on either of these objects will return the " "original ``ParamSpec``::" msgstr "" -#: library/typing.rst:1213 +#: library/typing.rst:1214 msgid "" "``AnyStr`` is a type variable defined as ``AnyStr = TypeVar('AnyStr', str, " "bytes)``." @@ -1441,7 +1441,7 @@ msgstr "" "``AnyStr`` est une variable de type définie comme ``AnyStr = " "TypeVar('AnyStr', str, bytes)``." -#: library/typing.rst:1216 +#: library/typing.rst:1217 msgid "" "It is meant to be used for functions that may accept any kind of string " "without allowing different kinds of strings to mix. For example::" @@ -1450,14 +1450,14 @@ msgstr "" "n'importe quel type de chaîne de caractères sans permettre à différents " "types de chaînes de caractères de se mélanger. Par exemple ::" -#: library/typing.rst:1228 +#: library/typing.rst:1229 msgid "" "Base class for protocol classes. Protocol classes are defined like this::" msgstr "" "Classe de base pour les classes de protocole. Les classes de protocole sont " "définies comme suit ::" -#: library/typing.rst:1234 +#: library/typing.rst:1235 msgid "" "Such classes are primarily used with static type checkers that recognize " "structural subtyping (static duck-typing), for example::" @@ -1466,7 +1466,7 @@ msgstr "" "de type qui reconnaissent les sous-types structurels (typage canard " "statique), par exemple ::" -#: library/typing.rst:1246 +#: library/typing.rst:1247 msgid "" "See :pep:`544` for details. Protocol classes decorated with :func:" "`runtime_checkable` (described later) act as simple-minded runtime protocols " @@ -1478,15 +1478,15 @@ msgstr "" "protocoles d'exécution simples qui ne vérifient que la présence d'attributs " "donnés, ignorant leurs signatures de type." -#: library/typing.rst:1251 +#: library/typing.rst:1252 msgid "Protocol classes can be generic, for example::" msgstr "Les classes de protocole peuvent être génériques, par exemple ::" -#: library/typing.rst:1261 +#: library/typing.rst:1262 msgid "Mark a protocol class as a runtime protocol." msgstr "Marquez une classe de protocole comme protocole d'exécution." -#: library/typing.rst:1263 +#: library/typing.rst:1264 #, fuzzy msgid "" "Such a protocol can be used with :func:`isinstance` and :func:`issubclass`. " @@ -1501,7 +1501,7 @@ msgstr "" "similaire aux « classes qui ne savent faire qu'une chose » présentes dans :" "mod:`collections.abc` tel que :class:`Iterable`. Par exemple ::" -#: library/typing.rst:1276 +#: library/typing.rst:1277 msgid "" ":func:`runtime_checkable` will check only the presence of the required " "methods, not their type signatures. For example, :class:`ssl.SSLObject` is a " @@ -1511,39 +1511,39 @@ msgid "" "making it impossible to call (instantiate) :class:`ssl.SSLObject`." msgstr "" -#: library/typing.rst:1287 +#: library/typing.rst:1288 msgid "Other special directives" msgstr "" -#: library/typing.rst:1289 +#: library/typing.rst:1290 msgid "" "These are not used in annotations. They are building blocks for declaring " "types." msgstr "" -#: library/typing.rst:1293 +#: library/typing.rst:1294 msgid "Typed version of :func:`collections.namedtuple`." msgstr "Version typée de :func:`collections.namedtuple`." -#: library/typing.rst:1301 +#: library/typing.rst:1302 msgid "This is equivalent to::" msgstr "Ce qui est équivalent à ::" -#: library/typing.rst:1305 +#: library/typing.rst:1306 msgid "" "To give a field a default value, you can assign to it in the class body::" msgstr "" "Pour assigner une valeur par défaut à un champ, vous pouvez lui donner dans " "le corps de classe ::" -#: library/typing.rst:1314 +#: library/typing.rst:1315 msgid "" "Fields with a default value must come after any fields without a default." msgstr "" "Les champs avec une valeur par défaut doivent venir après tous les champs " "sans valeur par défaut." -#: library/typing.rst:1316 +#: library/typing.rst:1317 msgid "" "The resulting class has an extra attribute ``__annotations__`` giving a dict " "that maps the field names to the field types. (The field names are in the " @@ -1556,28 +1556,28 @@ msgstr "" "défaut sont dans l'attribut ``_field_defaults`` qui font partie de l'API " "*namedtuple*.)" -#: library/typing.rst:1322 +#: library/typing.rst:1323 msgid "``NamedTuple`` subclasses can also have docstrings and methods::" msgstr "" "Les sous-classes de ``NamedTuple`` peuvent aussi avoir des *docstrings* et " "des méthodes ::" -#: library/typing.rst:1332 +#: library/typing.rst:1333 msgid "Backward-compatible usage::" msgstr "Utilisation rétrocompatible ::" -#: library/typing.rst:1336 +#: library/typing.rst:1337 msgid "Added support for :pep:`526` variable annotation syntax." msgstr "" "Ajout de la gestion de la syntaxe d'annotation variable de la :pep:`526`." -#: library/typing.rst:1339 +#: library/typing.rst:1340 msgid "Added support for default values, methods, and docstrings." msgstr "" "Ajout de la prise en charge des valeurs par défaut, des méthodes et des " "chaînes de caractères *docstrings*." -#: library/typing.rst:1342 +#: library/typing.rst:1343 msgid "" "The ``_field_types`` and ``__annotations__`` attributes are now regular " "dictionaries instead of instances of ``OrderedDict``." @@ -1585,7 +1585,7 @@ msgstr "" "Les attributs ``_field_types`` et ``__annotations__`` sont maintenant des " "dictionnaires standards au lieu d'instances de ``OrderedDict``." -#: library/typing.rst:1346 +#: library/typing.rst:1347 msgid "" "Removed the ``_field_types`` attribute in favor of the more standard " "``__annotations__`` attribute which has the same information." @@ -1593,7 +1593,7 @@ msgstr "" "rend l'attribut ``_field_types`` obsolète en faveur de l'attribut plus " "standard ``__annotations__`` qui a la même information." -#: library/typing.rst:1352 +#: library/typing.rst:1353 #, fuzzy msgid "" "A helper class to indicate a distinct type to a typechecker, see :ref:" @@ -1604,11 +1604,11 @@ msgstr "" "vérificateur de type, voir :ref:`distinct`. Lors de l'exécution, elle " "renvoie une fonction qui renvoie son argument. Utilisation ::" -#: library/typing.rst:1362 +#: library/typing.rst:1363 msgid "``NewType`` is now a class rather than a function." msgstr "" -#: library/typing.rst:1367 +#: library/typing.rst:1368 #, fuzzy msgid "" "Special construct to add type hints to a dictionary. At runtime it is a " @@ -1617,7 +1617,7 @@ msgstr "" "Un simple espace de nommage typé. À l'exécution, c'est l'équivalent d'un " "simple :class:`dict`." -#: library/typing.rst:1370 +#: library/typing.rst:1371 #, fuzzy msgid "" "``TypedDict`` declares a dictionary type that expects all of its instances " @@ -1631,7 +1631,7 @@ msgstr "" "l'exécution mais n'est appliquée que par les vérificateurs de type. " "Utilisation ::" -#: library/typing.rst:1386 +#: library/typing.rst:1387 #, fuzzy msgid "" "The type info for introspection can be accessed via ``Point2D." @@ -1646,13 +1646,13 @@ msgstr "" "pas en compte la :pep:`526`, ``TypedDict`` gère deux formes syntaxiques " "équivalentes supplémentaires ::" -#: library/typing.rst:1396 +#: library/typing.rst:1397 msgid "" "By default, all keys must be present in a ``TypedDict``. It is possible to " "override this by specifying totality. Usage::" msgstr "" -#: library/typing.rst:1404 +#: library/typing.rst:1405 msgid "" "This means that a ``Point2D`` ``TypedDict`` can have any of the keys " "omitted. A type checker is only expected to support a literal ``False`` or " @@ -1660,7 +1660,7 @@ msgid "" "and makes all items defined in the class body required." msgstr "" -#: library/typing.rst:1409 +#: library/typing.rst:1410 #, fuzzy msgid "" "See :pep:`589` for more examples and detailed rules of using ``TypedDict``." @@ -1668,15 +1668,15 @@ msgstr "" "Voir la :pep:`589` pour plus d'exemples et de règles détaillées " "d'utilisation de ``TypedDict`` avec les vérificateurs de type." -#: library/typing.rst:1414 +#: library/typing.rst:1415 msgid "Generic concrete collections" msgstr "" -#: library/typing.rst:1417 +#: library/typing.rst:1418 msgid "Corresponding to built-in types" msgstr "" -#: library/typing.rst:1421 +#: library/typing.rst:1422 msgid "" "A generic version of :class:`dict`. Useful for annotating return types. To " "annotate arguments it is preferred to use an abstract collection type such " @@ -1686,11 +1686,11 @@ msgstr "" "retour. Pour annoter les arguments, il est préférable d'utiliser un type de " "collection abstraite tel que :class:`Mapping`." -#: library/typing.rst:1425 +#: library/typing.rst:1426 msgid "This type can be used as follows::" msgstr "Ce type peut être utilisé comme suit ::" -#: library/typing.rst:1430 +#: library/typing.rst:1431 msgid "" ":class:`builtins.dict ` now supports ``[]``. See :pep:`585` and :ref:" "`types-genericalias`." @@ -1698,7 +1698,7 @@ msgstr "" ":class:`builtins.dict ` prend désormais en charge ``[]``. Voir :pep:" "`585` et :ref:`types-genericalias`." -#: library/typing.rst:1436 +#: library/typing.rst:1437 msgid "" "Generic version of :class:`list`. Useful for annotating return types. To " "annotate arguments it is preferred to use an abstract collection type such " @@ -1708,11 +1708,11 @@ msgstr "" "Pour annoter les arguments, il est préférable d'utiliser un type de " "collection abstraite tel que :class:`Sequence` ou :class:`Iterable`." -#: library/typing.rst:1441 +#: library/typing.rst:1442 msgid "This type may be used as follows::" msgstr "Ce type peut être utilisé comme suit ::" -#: library/typing.rst:1451 +#: library/typing.rst:1452 msgid "" ":class:`builtins.list ` now supports ``[]``. See :pep:`585` and :ref:" "`types-genericalias`." @@ -1720,7 +1720,7 @@ msgstr "" ":class:`builtins.list ` prend désormais en charge ``[]``. Voir :pep:" "`585` et :ref:`types-genericalias`." -#: library/typing.rst:1457 +#: library/typing.rst:1458 msgid "" "A generic version of :class:`builtins.set `. Useful for annotating " "return types. To annotate arguments it is preferred to use an abstract " @@ -1730,7 +1730,7 @@ msgstr "" "types de retour. Pour annoter les arguments, il est préférable d'utiliser un " "type de collection abstraite tel que :class:`AbstractSet`." -#: library/typing.rst:1461 +#: library/typing.rst:1462 msgid "" ":class:`builtins.set ` now supports ``[]``. See :pep:`585` and :ref:" "`types-genericalias`." @@ -1738,11 +1738,11 @@ msgstr "" ":class:`builtins.set ` prend désormais en charge ``[]``. Voir :pep:" "`585` et :ref:`types-genericalias`." -#: library/typing.rst:1467 +#: library/typing.rst:1468 msgid "A generic version of :class:`builtins.frozenset `." msgstr "Une version générique de :class:`builtins.frozenset `." -#: library/typing.rst:1469 +#: library/typing.rst:1470 msgid "" ":class:`builtins.frozenset ` now supports ``[]``. See :pep:`585` " "and :ref:`types-genericalias`." @@ -1750,19 +1750,19 @@ msgstr "" ":class:`builtins.frozenset ` prend désormais en charge ``[]``. " "Voir :pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1473 +#: library/typing.rst:1474 msgid ":data:`Tuple` is a special form." msgstr "" -#: library/typing.rst:1476 +#: library/typing.rst:1477 msgid "Corresponding to types in :mod:`collections`" msgstr "" -#: library/typing.rst:1480 +#: library/typing.rst:1481 msgid "A generic version of :class:`collections.defaultdict`." msgstr "Une version générique de :class:`collections.defaultdict`." -#: library/typing.rst:1484 +#: library/typing.rst:1485 msgid "" ":class:`collections.defaultdict` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -1770,11 +1770,11 @@ msgstr "" ":class:`collections.defaultdict` prend désormais en charge ``[]``. Voir :pep:" "`585` et :ref:`types-genericalias`." -#: library/typing.rst:1490 +#: library/typing.rst:1491 msgid "A generic version of :class:`collections.OrderedDict`." msgstr "Une version générique de :class:`collections.OrderedDict`." -#: library/typing.rst:1494 +#: library/typing.rst:1495 msgid "" ":class:`collections.OrderedDict` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -1782,11 +1782,11 @@ msgstr "" ":class:`collections.OrderedDict` prend désormais en charge ``[]``. Voir :pep:" "`585` et :ref:`types-genericalias`." -#: library/typing.rst:1500 +#: library/typing.rst:1501 msgid "A generic version of :class:`collections.ChainMap`." msgstr "Une version générique de :class:`collections.ChainMap`." -#: library/typing.rst:1505 +#: library/typing.rst:1506 msgid "" ":class:`collections.ChainMap` now supports ``[]``. See :pep:`585` and :ref:" "`types-genericalias`." @@ -1794,11 +1794,11 @@ msgstr "" ":class:`collections.ChainMap` prend désormais en charge ``[]``. Voir :pep:" "`585` et :ref:`types-genericalias`." -#: library/typing.rst:1511 +#: library/typing.rst:1512 msgid "A generic version of :class:`collections.Counter`." msgstr "Une version générique de :class:`collections.Counter`." -#: library/typing.rst:1516 +#: library/typing.rst:1517 msgid "" ":class:`collections.Counter` now supports ``[]``. See :pep:`585` and :ref:" "`types-genericalias`." @@ -1806,11 +1806,11 @@ msgstr "" ":class:`collections.Counter` prend désormais en charge ``[]``. Voir :pep:" "`585` et :ref:`types-genericalias`." -#: library/typing.rst:1522 +#: library/typing.rst:1523 msgid "A generic version of :class:`collections.deque`." msgstr "Une version générique de :class:`collections.deque`." -#: library/typing.rst:1527 +#: library/typing.rst:1528 msgid "" ":class:`collections.deque` now supports ``[]``. See :pep:`585` and :ref:" "`types-genericalias`." @@ -1818,11 +1818,11 @@ msgstr "" ":class:`collections.deque` prend désormais en charge ``[]``. Voir :pep:`585` " "et :ref:`types-genericalias`." -#: library/typing.rst:1532 +#: library/typing.rst:1533 msgid "Other concrete types" msgstr "" -#: library/typing.rst:1538 +#: library/typing.rst:1539 #, fuzzy msgid "" "Generic type ``IO[AnyStr]`` and its subclasses ``TextIO(IO[str])`` and " @@ -1833,13 +1833,13 @@ msgstr "" "``BinaryIO(IO[bytes])`` représentent les types de flux d'entrées-sorties " "tels que renvoyés par :func:`open`." -#: library/typing.rst:1545 +#: library/typing.rst:1546 msgid "" "The ``typing.io`` namespace is deprecated and will be removed. These types " "should be directly imported from ``typing`` instead." msgstr "" -#: library/typing.rst:1550 +#: library/typing.rst:1551 #, fuzzy msgid "" "These type aliases correspond to the return types from :func:`re.compile` " @@ -1852,19 +1852,19 @@ msgstr "" "génériques dans ``AnyStr`` et peuvent être rendus spécifiques en écrivant " "``Pattern[str]``, ``Pattern[bytes]``, ``Match[str]`` ou ``Match[bytes]``." -#: library/typing.rst:1560 +#: library/typing.rst:1561 msgid "" "The ``typing.re`` namespace is deprecated and will be removed. These types " "should be directly imported from ``typing`` instead." msgstr "" -#: library/typing.rst:1561 +#: library/typing.rst:1562 msgid "" "Classes ``Pattern`` and ``Match`` from :mod:`re` now support ``[]``. See :" "pep:`585` and :ref:`types-genericalias`." msgstr "" -#: library/typing.rst:1567 +#: library/typing.rst:1568 msgid "" "``Text`` is an alias for ``str``. It is provided to supply a forward " "compatible path for Python 2 code: in Python 2, ``Text`` is an alias for " @@ -1874,7 +1874,7 @@ msgstr "" "compatibilité ascendante du code Python 2 : en Python 2, ``Text`` est un " "alias pour ``unicode``." -#: library/typing.rst:1571 +#: library/typing.rst:1572 msgid "" "Use ``Text`` to indicate that a value must contain a unicode string in a " "manner that is compatible with both Python 2 and Python 3::" @@ -1882,20 +1882,20 @@ msgstr "" "Utilisez ``Text`` pour indiquer qu'une valeur doit contenir une chaîne " "Unicode d'une manière compatible avec Python 2 et Python 3 ::" -#: library/typing.rst:1580 +#: library/typing.rst:1581 #, fuzzy msgid "Abstract Base Classes" msgstr "Classe de base abstraite pour les types génériques." -#: library/typing.rst:1583 +#: library/typing.rst:1584 msgid "Corresponding to collections in :mod:`collections.abc`" msgstr "" -#: library/typing.rst:1587 +#: library/typing.rst:1588 msgid "A generic version of :class:`collections.abc.Set`." msgstr "Une version générique de :class:`collections.abc.Set`." -#: library/typing.rst:1589 +#: library/typing.rst:1590 msgid "" ":class:`collections.abc.Set` now supports ``[]``. See :pep:`585` and :ref:" "`types-genericalias`." @@ -1903,11 +1903,11 @@ msgstr "" ":class:`collections.abc.Set` prend désormais en charge ``[]``. Voir :pep:" "`585` et :ref:`types-genericalias`." -#: library/typing.rst:1595 +#: library/typing.rst:1596 msgid "A generic version of :class:`collections.abc.ByteString`." msgstr "Une version générique de :class:`collections.abc.ByteString`." -#: library/typing.rst:1597 +#: library/typing.rst:1598 #, fuzzy msgid "" "This type represents the types :class:`bytes`, :class:`bytearray`, and :" @@ -1916,7 +1916,7 @@ msgstr "" "Ce type représente les types :class:`bytes`, :class:`bytearray` et :class:" "`memoryview`." -#: library/typing.rst:1600 +#: library/typing.rst:1601 msgid "" "As a shorthand for this type, :class:`bytes` can be used to annotate " "arguments of any of the types mentioned above." @@ -1924,7 +1924,7 @@ msgstr "" "Comme abréviation pour ce type, :class:`bytes` peut être utilisé pour " "annoter des arguments de n'importe quel type mentionné ci-dessus." -#: library/typing.rst:1603 +#: library/typing.rst:1604 msgid "" ":class:`collections.abc.ByteString` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -1932,11 +1932,11 @@ msgstr "" ":class:`collections.abc.ByteString` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1609 +#: library/typing.rst:1610 msgid "A generic version of :class:`collections.abc.Collection`" msgstr "Une version générique de :class:`collections.abc.Collection`" -#: library/typing.rst:1613 +#: library/typing.rst:1614 msgid "" ":class:`collections.abc.Collection` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -1944,11 +1944,11 @@ msgstr "" ":class:`collections.abc.Collection` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1619 +#: library/typing.rst:1620 msgid "A generic version of :class:`collections.abc.Container`." msgstr "Une version générique de :class:`collections.abc.Container`." -#: library/typing.rst:1621 +#: library/typing.rst:1622 msgid "" ":class:`collections.abc.Container` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -1956,11 +1956,11 @@ msgstr "" ":class:`collections.abc.Container` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1627 +#: library/typing.rst:1628 msgid "A generic version of :class:`collections.abc.ItemsView`." msgstr "Une version générique de :class:`collections.abc.ItemsView`." -#: library/typing.rst:1629 +#: library/typing.rst:1630 msgid "" ":class:`collections.abc.ItemsView` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -1968,11 +1968,11 @@ msgstr "" ":class:`collections.abc.ItemsView` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1635 +#: library/typing.rst:1636 msgid "A generic version of :class:`collections.abc.KeysView`." msgstr "Une version générique de :class:`collections.abc.KeysView`." -#: library/typing.rst:1637 +#: library/typing.rst:1638 msgid "" ":class:`collections.abc.KeysView` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -1980,7 +1980,7 @@ msgstr "" ":class:`collections.abc.KeysView` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1643 +#: library/typing.rst:1644 msgid "" "A generic version of :class:`collections.abc.Mapping`. This type can be used " "as follows::" @@ -1988,7 +1988,7 @@ msgstr "" "Une version générique de :class:`collections.abc.Mapping`. Ce type peut être " "utilisé comme suit ::" -#: library/typing.rst:1649 +#: library/typing.rst:1650 msgid "" ":class:`collections.abc.Mapping` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -1996,11 +1996,11 @@ msgstr "" ":class:`collections.abc.Mapping` prend désormais en charge ``[]``. Voir :pep:" "`585` et :ref:`types-genericalias`." -#: library/typing.rst:1655 +#: library/typing.rst:1656 msgid "A generic version of :class:`collections.abc.MappingView`." msgstr "Une version générique de :class:`collections.abc.MappingView`." -#: library/typing.rst:1657 +#: library/typing.rst:1658 msgid "" ":class:`collections.abc.MappingView` now supports ``[]``. See :pep:`585` " "and :ref:`types-genericalias`." @@ -2008,11 +2008,11 @@ msgstr "" ":class:`collections.abc.MappingView` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1663 +#: library/typing.rst:1664 msgid "A generic version of :class:`collections.abc.MutableMapping`." msgstr "Une version générique de :class:`collections.abc.MutableMapping`." -#: library/typing.rst:1665 +#: library/typing.rst:1666 msgid "" ":class:`collections.abc.MutableMapping` now supports ``[]``. See :pep:`585` " "and :ref:`types-genericalias`." @@ -2020,11 +2020,11 @@ msgstr "" ":class:`collections.abc.MutableMapping` prend désormais en charge ``[]``. " "Voir :pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1671 +#: library/typing.rst:1672 msgid "A generic version of :class:`collections.abc.MutableSequence`." msgstr "Une version générique de :class:`collections.abc.MutableSequence`." -#: library/typing.rst:1673 +#: library/typing.rst:1674 msgid "" ":class:`collections.abc.MutableSequence` now supports ``[]``. See :pep:`585` " "and :ref:`types-genericalias`." @@ -2032,11 +2032,11 @@ msgstr "" ":class:`collections.abc.MutableSequence` prend désormais en charge ``[]``. " "Voir :pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1679 +#: library/typing.rst:1680 msgid "A generic version of :class:`collections.abc.MutableSet`." msgstr "Une version générique de :class:`collections.abc.MutableSet`." -#: library/typing.rst:1681 +#: library/typing.rst:1682 msgid "" ":class:`collections.abc.MutableSet` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -2044,11 +2044,11 @@ msgstr "" ":class:`collections.abc.MutableSet` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1687 +#: library/typing.rst:1688 msgid "A generic version of :class:`collections.abc.Sequence`." msgstr "Une version générique de :class:`collections.abc.Sequence`." -#: library/typing.rst:1689 +#: library/typing.rst:1690 msgid "" ":class:`collections.abc.Sequence` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -2056,11 +2056,11 @@ msgstr "" ":class:`collections.abc.Sequence` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1695 +#: library/typing.rst:1696 msgid "A generic version of :class:`collections.abc.ValuesView`." msgstr "Une version générique de :class:`collections.abc.ValuesView`." -#: library/typing.rst:1697 +#: library/typing.rst:1698 msgid "" ":class:`collections.abc.ValuesView` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -2068,15 +2068,15 @@ msgstr "" ":class:`collections.abc.ValuesView` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1702 +#: library/typing.rst:1703 msgid "Corresponding to other types in :mod:`collections.abc`" msgstr "" -#: library/typing.rst:1706 +#: library/typing.rst:1707 msgid "A generic version of :class:`collections.abc.Iterable`." msgstr "Une version générique de :class:`collections.abc.Iterable`." -#: library/typing.rst:1708 +#: library/typing.rst:1709 msgid "" ":class:`collections.abc.Iterable` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -2084,11 +2084,11 @@ msgstr "" ":class:`collections.abc.Iterable` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1714 +#: library/typing.rst:1715 msgid "A generic version of :class:`collections.abc.Iterator`." msgstr "Une version générique de :class:`collections.abc.Iterator`." -#: library/typing.rst:1716 +#: library/typing.rst:1717 msgid "" ":class:`collections.abc.Iterator` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -2096,7 +2096,7 @@ msgstr "" ":class:`collections.abc.Iterator` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1722 +#: library/typing.rst:1723 msgid "" "A generator can be annotated by the generic type ``Generator[YieldType, " "SendType, ReturnType]``. For example::" @@ -2104,7 +2104,7 @@ msgstr "" "Un générateur peut être annoté par le type générique ``Generator[YieldType, " "SendType, ReturnType]``. Par exemple ::" -#: library/typing.rst:1731 +#: library/typing.rst:1732 msgid "" "Note that unlike many other generics in the typing module, the ``SendType`` " "of :class:`Generator` behaves contravariantly, not covariantly or " @@ -2114,7 +2114,7 @@ msgstr "" "*typing*, le ``SendType`` de :class:`Generator` se comporte de manière " "contravariante, pas de manière covariante ou invariante." -#: library/typing.rst:1735 +#: library/typing.rst:1736 msgid "" "If your generator will only yield values, set the ``SendType`` and " "``ReturnType`` to ``None``::" @@ -2122,7 +2122,7 @@ msgstr "" "Si votre générateur ne donne que des valeurs, réglez les paramètres " "``SendType`` et ``ReturnType`` sur ``None`` ::" -#: library/typing.rst:1743 +#: library/typing.rst:1744 msgid "" "Alternatively, annotate your generator as having a return type of either " "``Iterable[YieldType]`` or ``Iterator[YieldType]``::" @@ -2130,7 +2130,7 @@ msgstr "" "Alternativement, annotez votre générateur comme ayant un type de retour soit " "``Iterable[YieldType]`` ou ``Iterator[YieldType]`` ::" -#: library/typing.rst:1751 +#: library/typing.rst:1752 msgid "" ":class:`collections.abc.Generator` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -2138,15 +2138,15 @@ msgstr "" ":class:`collections.abc.Generator` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1757 +#: library/typing.rst:1758 msgid "An alias to :class:`collections.abc.Hashable`" msgstr "Un alias pour :class:`collections.abc.Hashable`" -#: library/typing.rst:1761 +#: library/typing.rst:1762 msgid "A generic version of :class:`collections.abc.Reversible`." msgstr "Une version générique de :class:`collections.abc.Reversible`." -#: library/typing.rst:1763 +#: library/typing.rst:1764 msgid "" ":class:`collections.abc.Reversible` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -2154,15 +2154,15 @@ msgstr "" ":class:`collections.abc.Reversible` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1769 +#: library/typing.rst:1770 msgid "An alias to :class:`collections.abc.Sized`" msgstr "Un alias pour :class:`collections.abc.Sized`" -#: library/typing.rst:1772 +#: library/typing.rst:1773 msgid "Asynchronous programming" msgstr "" -#: library/typing.rst:1776 +#: library/typing.rst:1777 msgid "" "A generic version of :class:`collections.abc.Coroutine`. The variance and " "order of type variables correspond to those of :class:`Generator`, for " @@ -2172,7 +2172,7 @@ msgstr "" "l'ordre des variables de type correspondent à ceux de la classe :class:" "`Generator`, par exemple ::" -#: library/typing.rst:1789 +#: library/typing.rst:1790 msgid "" ":class:`collections.abc.Coroutine` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -2180,7 +2180,7 @@ msgstr "" ":class:`collections.abc.Coroutine` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1795 +#: library/typing.rst:1796 msgid "" "An async generator can be annotated by the generic type " "``AsyncGenerator[YieldType, SendType]``. For example::" @@ -2188,7 +2188,7 @@ msgstr "" "Un générateur asynchrone peut être annoté par le type générique " "``AsyncGenerator[YieldType, SendType]``. Par exemple ::" -#: library/typing.rst:1804 +#: library/typing.rst:1805 msgid "" "Unlike normal generators, async generators cannot return a value, so there " "is no ``ReturnType`` type parameter. As with :class:`Generator`, the " @@ -2199,14 +2199,14 @@ msgstr "" "``ReturnType``. Comme avec :class:`Generator`, le ``SendType`` se comporte " "de manière contravariante." -#: library/typing.rst:1808 +#: library/typing.rst:1809 msgid "" "If your generator will only yield values, set the ``SendType`` to ``None``::" msgstr "" "Si votre générateur ne donne que des valeurs, réglez le paramètre " "``SendType`` sur ``None`` ::" -#: library/typing.rst:1816 +#: library/typing.rst:1817 msgid "" "Alternatively, annotate your generator as having a return type of either " "``AsyncIterable[YieldType]`` or ``AsyncIterator[YieldType]``::" @@ -2214,7 +2214,7 @@ msgstr "" "Alternativement, annotez votre générateur comme ayant un type de retour soit " "``AsyncIterable[YieldType]`` ou ``AsyncIterator[YieldType]`` ::" -#: library/typing.rst:1826 +#: library/typing.rst:1827 msgid "" ":class:`collections.abc.AsyncGenerator` now supports ``[]``. See :pep:`585` " "and :ref:`types-genericalias`." @@ -2222,11 +2222,11 @@ msgstr "" ":class:`collections.abc.AsyncGenerator` prend désormais en charge ``[]``. " "Voir :pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1832 +#: library/typing.rst:1833 msgid "A generic version of :class:`collections.abc.AsyncIterable`." msgstr "Une version générique de :class:`collections.abc.AsyncIterable`." -#: library/typing.rst:1836 +#: library/typing.rst:1837 msgid "" ":class:`collections.abc.AsyncIterable` now supports ``[]``. See :pep:`585` " "and :ref:`types-genericalias`." @@ -2234,11 +2234,11 @@ msgstr "" ":class:`collections.abc.AsyncIterable` prend désormais en charge ``[]``. " "Voir :pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1842 +#: library/typing.rst:1843 msgid "A generic version of :class:`collections.abc.AsyncIterator`." msgstr "Une version générique de :class:`collections.abc.AsyncIterator`." -#: library/typing.rst:1846 +#: library/typing.rst:1847 msgid "" ":class:`collections.abc.AsyncIterator` now supports ``[]``. See :pep:`585` " "and :ref:`types-genericalias`." @@ -2246,11 +2246,11 @@ msgstr "" ":class:`collections.abc.AsyncIterator` prend désormais en charge ``[]``. " "Voir :pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1852 +#: library/typing.rst:1853 msgid "A generic version of :class:`collections.abc.Awaitable`." msgstr "Une version générique de :class:`collections.abc.Awaitable`." -#: library/typing.rst:1856 +#: library/typing.rst:1857 msgid "" ":class:`collections.abc.Awaitable` now supports ``[]``. See :pep:`585` and :" "ref:`types-genericalias`." @@ -2258,15 +2258,15 @@ msgstr "" ":class:`collections.abc.Awaitable` prend désormais en charge ``[]``. Voir :" "pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1862 +#: library/typing.rst:1863 msgid "Context manager types" msgstr "" -#: library/typing.rst:1866 +#: library/typing.rst:1867 msgid "A generic version of :class:`contextlib.AbstractContextManager`." msgstr "Une version générique de :class:`contextlib.AbstractContextManager`." -#: library/typing.rst:1871 +#: library/typing.rst:1872 msgid "" ":class:`contextlib.AbstractContextManager` now supports ``[]``. See :pep:" "`585` and :ref:`types-genericalias`." @@ -2274,12 +2274,12 @@ msgstr "" ":class:`contextlib.AbstractContextManager` prend désormais en charge ``[]``. " "Voir :pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1877 +#: library/typing.rst:1878 msgid "A generic version of :class:`contextlib.AbstractAsyncContextManager`." msgstr "" "Une version générique de :class:`contextlib.AbstractAsyncContextManager`." -#: library/typing.rst:1882 +#: library/typing.rst:1883 msgid "" ":class:`contextlib.AbstractAsyncContextManager` now supports ``[]``. See :" "pep:`585` and :ref:`types-genericalias`." @@ -2287,15 +2287,15 @@ msgstr "" ":class:`contextlib.AbstractAsyncContextManager` prend désormais en charge " "``[]``. Voir :pep:`585` et :ref:`types-genericalias`." -#: library/typing.rst:1887 +#: library/typing.rst:1888 msgid "Protocols" msgstr "" -#: library/typing.rst:1889 +#: library/typing.rst:1890 msgid "These protocols are decorated with :func:`runtime_checkable`." msgstr "" -#: library/typing.rst:1893 +#: library/typing.rst:1894 msgid "" "An ABC with one abstract method ``__abs__`` that is covariant in its return " "type." @@ -2303,27 +2303,27 @@ msgstr "" "Une ABC avec une méthode abstraite ``__abs__`` qui est covariante dans son " "type de retour." -#: library/typing.rst:1898 +#: library/typing.rst:1899 msgid "An ABC with one abstract method ``__bytes__``." msgstr "Une ABC avec une méthode abstraite ``__bytes__``." -#: library/typing.rst:1902 +#: library/typing.rst:1903 msgid "An ABC with one abstract method ``__complex__``." msgstr "Une ABC avec une méthode abstraite ``__complex__``." -#: library/typing.rst:1906 +#: library/typing.rst:1907 msgid "An ABC with one abstract method ``__float__``." msgstr "Une ABC avec une méthode abstraite ``__float__``." -#: library/typing.rst:1910 +#: library/typing.rst:1911 msgid "An ABC with one abstract method ``__index__``." msgstr "Une ABC avec une méthode abstraite ``__index__``." -#: library/typing.rst:1916 +#: library/typing.rst:1917 msgid "An ABC with one abstract method ``__int__``." msgstr "Une ABC avec une méthode abstraite ``__int__``." -#: library/typing.rst:1920 +#: library/typing.rst:1921 msgid "" "An ABC with one abstract method ``__round__`` that is covariant in its " "return type." @@ -2331,16 +2331,16 @@ msgstr "" "Une ABC avec une méthode abstraite ``__round__`` qui est covariante dans son " "type de retour." -#: library/typing.rst:1924 +#: library/typing.rst:1925 #, fuzzy msgid "Functions and decorators" msgstr "Classes, fonctions et décorateurs" -#: library/typing.rst:1928 +#: library/typing.rst:1929 msgid "Cast a value to a type." msgstr "Convertit une valeur en un type." -#: library/typing.rst:1930 +#: library/typing.rst:1931 msgid "" "This returns the value unchanged. To the type checker this signals that the " "return value has the designated type, but at runtime we intentionally don't " @@ -2351,7 +2351,7 @@ msgstr "" "intentionnellement, rien n'est vérifié (afin que cela soit aussi rapide que " "possible)." -#: library/typing.rst:1937 +#: library/typing.rst:1938 msgid "" "The ``@overload`` decorator allows describing functions and methods that " "support multiple different combinations of argument types. A series of " @@ -2377,13 +2377,13 @@ msgstr "" "`NotImplementedError`. Un exemple de surcharge qui donne un type plus précis " "que celui qui peut être exprimé à l'aide d'une variable union ou type ::" -#: library/typing.rst:1961 +#: library/typing.rst:1962 msgid "See :pep:`484` for details and comparison with other typing semantics." msgstr "" "Voir la :pep:`484` pour plus de détails et la comparaison avec d'autres " "sémantiques de typage." -#: library/typing.rst:1965 +#: library/typing.rst:1966 msgid "" "A decorator to indicate to type checkers that the decorated method cannot be " "overridden, and the decorated class cannot be subclassed. For example::" @@ -2392,13 +2392,13 @@ msgstr "" "décorée ne peut pas être remplacée et que la classe décorée ne peut pas être " "sous-classée. Par exemple ::" -#: library/typing.rst:1990 +#: library/typing.rst:1991 msgid "Decorator to indicate that annotations are not type hints." msgstr "" "Décorateur pour indiquer que les annotations ne sont pas des indications de " "type." -#: library/typing.rst:1992 +#: library/typing.rst:1993 msgid "" "This works as class or function :term:`decorator`. With a class, it applies " "recursively to all methods defined in that class (but not to methods defined " @@ -2409,16 +2409,16 @@ msgstr "" "méthodes définies dans cette classe (mais pas aux méthodes définies dans ses " "superclasses ou sous-classes)." -#: library/typing.rst:1996 +#: library/typing.rst:1997 msgid "This mutates the function(s) in place." msgstr "Cela fait muter la ou les fonctions en place." -#: library/typing.rst:2000 +#: library/typing.rst:2001 msgid "Decorator to give another decorator the :func:`no_type_check` effect." msgstr "" "Décorateur pour donner à un autre décorateur l'effet :func:`no_type_check`." -#: library/typing.rst:2002 +#: library/typing.rst:2003 msgid "" "This wraps the decorator with something that wraps the decorated function " "in :func:`no_type_check`." @@ -2426,13 +2426,13 @@ msgstr "" "Ceci enveloppe le décorateur avec quelque chose qui enveloppe la fonction " "décorée dans :func:`no_type_check`." -#: library/typing.rst:2007 +#: library/typing.rst:2008 msgid "Decorator to mark a class or function to be unavailable at runtime." msgstr "" "Décorateur pour marquer une classe ou une fonction comme étant indisponible " "au moment de l'exécution." -#: library/typing.rst:2009 +#: library/typing.rst:2010 msgid "" "This decorator is itself not available at runtime. It is mainly intended to " "mark classes that are defined in type stub files if an implementation " @@ -2443,7 +2443,7 @@ msgstr "" "d'annotations de type (*type stub file*, en anglais) si une implémentation " "renvoie une instance d'une classe privée ::" -#: library/typing.rst:2020 +#: library/typing.rst:2021 msgid "" "Note that returning instances of private classes is not recommended. It is " "usually preferable to make such classes public." @@ -2451,11 +2451,11 @@ msgstr "" "Notez qu'il n'est pas recommandé de renvoyer les instances des classes " "privées. Il est généralement préférable de rendre ces classes publiques." -#: library/typing.rst:2024 +#: library/typing.rst:2025 msgid "Introspection helpers" msgstr "" -#: library/typing.rst:2028 +#: library/typing.rst:2029 msgid "" "Return a dictionary containing type hints for a function, method, module or " "class object." @@ -2463,7 +2463,7 @@ msgstr "" "renvoie un dictionnaire contenant des indications de type pour une fonction, " "une méthode, un module ou un objet de classe." -#: library/typing.rst:2031 +#: library/typing.rst:2032 msgid "" "This is often the same as ``obj.__annotations__``. In addition, forward " "references encoded as string literals are handled by evaluating them in " @@ -2480,31 +2480,31 @@ msgstr "" "classe ``C``, renvoie un dictionnaire construit en fusionnant toutes les " "``__annotations__`` en parcourant ``C.__mro__`` en ordre inverse." -#: library/typing.rst:2039 +#: library/typing.rst:2040 msgid "" "The function recursively replaces all ``Annotated[T, ...]`` with ``T``, " "unless ``include_extras`` is set to ``True`` (see :class:`Annotated` for " "more information). For example::" msgstr "" -#: library/typing.rst:2054 +#: library/typing.rst:2055 msgid "" ":func:`get_type_hints` does not work with imported :ref:`type aliases ` that include forward references. Enabling postponed evaluation of " "annotations (:pep:`563`) may remove the need for most forward references." msgstr "" -#: library/typing.rst:2059 +#: library/typing.rst:2060 msgid "Added ``include_extras`` parameter as part of :pep:`593`." msgstr "" -#: library/typing.rst:2065 +#: library/typing.rst:2066 msgid "Provide basic introspection for generic types and special typing forms." msgstr "" "Fournit une introspection de base pour les types génériques et les formes " "spéciales de typage." -#: library/typing.rst:2067 +#: library/typing.rst:2068 #, fuzzy msgid "" "For a typing object of the form ``X[Y, Z, ...]`` these functions return " @@ -2520,11 +2520,11 @@ msgstr "" "native ou de :mod:`collections`, il est normalisé en la classe originale. " "Pour les objets non gérés, renvoie la paire ``None`` , ``()``. Exemples ::" -#: library/typing.rst:2086 +#: library/typing.rst:2087 msgid "Check if a type is a :class:`TypedDict`." msgstr "" -#: library/typing.rst:2101 +#: library/typing.rst:2102 #, fuzzy msgid "" "A class used for internal typing representation of string forward " @@ -2539,18 +2539,18 @@ msgstr "" "instanciée par un utilisateur, mais peut être utilisée par des outils " "d'introspection." -#: library/typing.rst:2107 +#: library/typing.rst:2108 msgid "" ":pep:`585` generic types such as ``list[\"SomeClass\"]`` will not be " "implicitly transformed into ``list[ForwardRef(\"SomeClass\")]`` and thus " "will not automatically resolve to ``list[SomeClass]``." msgstr "" -#: library/typing.rst:2114 +#: library/typing.rst:2115 msgid "Constant" msgstr "Constante" -#: library/typing.rst:2118 +#: library/typing.rst:2119 msgid "" "A special constant that is assumed to be ``True`` by 3rd party static type " "checkers. It is ``False`` at runtime. Usage::" @@ -2558,7 +2558,7 @@ msgstr "" "Constante spéciale qui vaut ``True`` pour les vérificateurs de type " "statiques tiers et ``False`` à l'exécution. Utilisation ::" -#: library/typing.rst:2127 +#: library/typing.rst:2128 #, fuzzy msgid "" "The first type annotation must be enclosed in quotes, making it a \"forward " @@ -2573,7 +2573,7 @@ msgstr "" "sorte que la deuxième annotation n'a pas besoin d'être placée entre " "guillemets." -#: library/typing.rst:2134 +#: library/typing.rst:2135 msgid "" "If ``from __future__ import annotations`` is used in Python 3.7 or later, " "annotations are not evaluated at function definition time. Instead, they are " diff --git a/library/unittest.po b/library/unittest.po index 6f682105..550467d5 100644 --- a/library/unittest.po +++ b/library/unittest.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-04-27 15:01+0200\n" "Last-Translator: Julien Palard \n" "Language-Team: FRENCH \n" @@ -403,10 +403,11 @@ msgid "Stop the test run on the first error or failure." msgstr "Arrête l'exécution des tests lors du premier cas d'erreur ou d'échec." #: library/unittest.rst:224 +#, fuzzy msgid "" "Only run test methods and classes that match the pattern or substring. This " "option may be used multiple times, in which case all test cases that match " -"of the given patterns are included." +"any of the given patterns are included." msgstr "" "Exécute uniquement les méthodes de test et les classes qui correspondent au " "motif ou à la chaîne de caractères. Cette option peut être utilisée " diff --git a/reference/compound_stmts.po b/reference/compound_stmts.po index 259fa61e..35cab55c 100644 --- a/reference/compound_stmts.po +++ b/reference/compound_stmts.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-10-27 21:17+0200\n" "Last-Translator: Jean Abou Samra \n" "Language-Team: FRENCH \n" @@ -528,9 +528,10 @@ msgstr "" "« élément » (*item* dans la grammaire) se déroule comme suit :" #: reference/compound_stmts.rst:421 +#, fuzzy msgid "" -"The context expression (the expression given in the :token:`with_item`) is " -"evaluated to obtain a context manager." +"The context expression (the expression given in the :token:`~python-grammar:" +"with_item`) is evaluated to obtain a context manager." msgstr "" "L'expression de contexte (l'expression donnée dans le :token:`with_item`) " "est évaluée pour obtenir un gestionnaire de contexte." @@ -613,13 +614,13 @@ msgstr "" "valeur de retour de :meth:`__exit__` est ignorée et l'exécution se poursuit " "à l'endroit normal pour le type de sortie prise." -#: reference/compound_stmts.rst:457 reference/compound_stmts.rst:1446 -#: reference/compound_stmts.rst:1487 +#: reference/compound_stmts.rst:457 reference/compound_stmts.rst:1447 +#: reference/compound_stmts.rst:1488 msgid "The following code::" msgstr "Le code suivant ::" #: reference/compound_stmts.rst:462 reference/compound_stmts.rst:487 -#: reference/compound_stmts.rst:1492 +#: reference/compound_stmts.rst:1493 msgid "is semantically equivalent to::" msgstr "est sémantiquement équivalent à ::" @@ -718,11 +719,11 @@ msgstr "" "Les mots-clés ``match`` et ``case`` sont des :ref:`mots-clés ad-hoc `." -#: reference/compound_stmts.rst:555 reference/compound_stmts.rst:1109 +#: reference/compound_stmts.rst:555 reference/compound_stmts.rst:1110 msgid ":pep:`634` -- Structural Pattern Matching: Specification" msgstr ":pep:`634` — Spécifications pour le filtrage par motif" -#: reference/compound_stmts.rst:556 reference/compound_stmts.rst:1110 +#: reference/compound_stmts.rst:556 reference/compound_stmts.rst:1111 msgid ":pep:`636` -- Structural Pattern Matching: Tutorial" msgstr ":pep:`636` — Tutoriel pour le filtrage par motif" @@ -1105,15 +1106,17 @@ msgstr "" "syntaxe est la suivante :" #: reference/compound_stmts.rst:799 +#, fuzzy msgid "" "A single underscore ``_`` is not a capture pattern (this is what ``!'_'`` " -"expresses). It is instead treated as a :token:`wildcard_pattern`." +"expresses). It is instead treated as a :token:`~python-grammar:" +"wildcard_pattern`." msgstr "" "Un simple caractère souligné ``_`` n'est pas un filtre de capture (c'est ce " "que ``!'_'`` veut dire). C'est le motif pour désigner un filtre attrape-tout " "(lexème :token:`wilcard_pattern`, voir plus bas)." -#: reference/compound_stmts.rst:802 +#: reference/compound_stmts.rst:803 msgid "" "In a given pattern, a given name can only be bound once. E.g. ``case x, " "x: ...`` is invalid while ``case [x] | x: ...`` is allowed." @@ -1122,7 +1125,7 @@ msgstr "" "exemple, ``case x, x: ...`` est invalide mais ``case [x] | x: ...`` est " "autorisé." -#: reference/compound_stmts.rst:805 +#: reference/compound_stmts.rst:806 msgid "" "Capture patterns always succeed. The binding follows scoping rules " "established by the assignment expression operator in :pep:`572`; the name " @@ -1135,18 +1138,18 @@ msgstr "" "intérieure à moins qu'il n'y ait une instruction :keyword:`global` ou :" "keyword:`nonlocal` qui s'applique." -#: reference/compound_stmts.rst:810 +#: reference/compound_stmts.rst:811 msgid "" "In simple terms ``NAME`` will always succeed and it will set ``NAME = " "``." msgstr "" "En termes simples, ``NAME`` réussit toujours et définit ``NAME = ``." -#: reference/compound_stmts.rst:815 +#: reference/compound_stmts.rst:816 msgid "Wildcard Patterns" msgstr "Filtres attrape-tout" -#: reference/compound_stmts.rst:817 +#: reference/compound_stmts.rst:818 msgid "" "A wildcard pattern always succeeds (matches anything) and binds no name. " "Syntax:" @@ -1154,7 +1157,7 @@ msgstr "" "Un filtre attrape-tout réussit toujours (quel que soit le champ de " "recherche) et ne lie aucun nom. La syntaxe est la suivante :" -#: reference/compound_stmts.rst:823 +#: reference/compound_stmts.rst:824 msgid "" "``_`` is a :ref:`soft keyword ` within any pattern, but only " "within patterns. It is an identifier, as usual, even within ``match`` " @@ -1165,21 +1168,21 @@ msgstr "" "d'habitude, même à l'intérieur d'une expression champ de recherche de " "``match``, d'une garde ou d'un bloc ``case``." -#: reference/compound_stmts.rst:827 +#: reference/compound_stmts.rst:828 msgid "In simple terms, ``_`` will always succeed." msgstr "En termes simples, ``_`` réussit toujours." -#: reference/compound_stmts.rst:832 +#: reference/compound_stmts.rst:833 msgid "Value Patterns" msgstr "Filtres par valeurs" -#: reference/compound_stmts.rst:834 +#: reference/compound_stmts.rst:835 msgid "A value pattern represents a named value in Python. Syntax:" msgstr "" "Un filtre par valeur représente une valeur nommée de Python. Sa syntaxe est " "la suivante :" -#: reference/compound_stmts.rst:842 +#: reference/compound_stmts.rst:843 msgid "" "The dotted name in the pattern is looked up using standard Python :ref:`name " "resolution rules `. The pattern succeeds if the value found " @@ -1190,7 +1193,7 @@ msgstr "" "réussit si la valeur trouvée vérifie l'égalité avec la valeur du champ de " "recherche (en utilisant l'opérateur d'égalité ``==``)." -#: reference/compound_stmts.rst:847 +#: reference/compound_stmts.rst:848 msgid "" "In simple terms ``NAME1.NAME2`` will succeed only if `` == NAME1." "NAME2``" @@ -1199,7 +1202,7 @@ msgstr "" "NOM1.NOM2``" # Pas de majuscule car suit : -#: reference/compound_stmts.rst:851 +#: reference/compound_stmts.rst:852 msgid "" "If the same value occurs multiple times in the same match statement, the " "interpreter may cache the first value found and reuse it rather than repeat " @@ -1211,11 +1214,11 @@ msgstr "" "la réutiliser plutôt que de refaire une recherche. Ce cache est strictement " "limité à l'exécution de l'instruction ``match`` donnée." -#: reference/compound_stmts.rst:859 +#: reference/compound_stmts.rst:860 msgid "Group Patterns" msgstr "Filtres de groupes" -#: reference/compound_stmts.rst:861 +#: reference/compound_stmts.rst:862 msgid "" "A group pattern allows users to add parentheses around patterns to emphasize " "the intended grouping. Otherwise, it has no additional syntax. Syntax:" @@ -1224,15 +1227,15 @@ msgstr "" "regrouper des motifs en plaçant ceux-ci entre parenthèses. À part ça, il " "n’introduit aucune syntaxe supplémentaire. Sa syntaxe est la suivante :" -#: reference/compound_stmts.rst:868 +#: reference/compound_stmts.rst:869 msgid "In simple terms ``(P)`` has the same effect as ``P``." msgstr "En termes plus simples, ``(P)`` équivaut à ``P``." -#: reference/compound_stmts.rst:873 +#: reference/compound_stmts.rst:874 msgid "Sequence Patterns" msgstr "Filtres de séquences" -#: reference/compound_stmts.rst:875 +#: reference/compound_stmts.rst:876 msgid "" "A sequence pattern contains several subpatterns to be matched against " "sequence elements. The syntax is similar to the unpacking of a list or tuple." @@ -1241,7 +1244,7 @@ msgstr "" "correspondre à un élément d’une séquence. La syntaxe est similaire au " "déballage d’une liste ou d’un *n*-uplet." -#: reference/compound_stmts.rst:886 +#: reference/compound_stmts.rst:887 msgid "" "There is no difference if parentheses or square brackets are used for " "sequence patterns (i.e. ``(...)`` vs ``[...]`` )." @@ -1250,7 +1253,7 @@ msgstr "" "crochets ``[...]`` pour encadrer les filtres à regrouper." # Pas de majuscule car suit : -#: reference/compound_stmts.rst:890 +#: reference/compound_stmts.rst:891 msgid "" "A single pattern enclosed in parentheses without a trailing comma (e.g. ``(3 " "| 4)``) is a :ref:`group pattern `. While a single pattern " @@ -1261,7 +1264,7 @@ msgstr "" "revanche, un filtre seul entre crochets (par exemple ``[3 | 4]``) reste un " "filtre de séquence." -#: reference/compound_stmts.rst:895 +#: reference/compound_stmts.rst:896 msgid "" "At most one star subpattern may be in a sequence pattern. The star " "subpattern may occur in any position. If no star subpattern is present, the " @@ -1273,7 +1276,7 @@ msgstr "" "position. S’il n’y en a pas, le filtre de séquence est un filtre de séquence " "à longueur fixe, sinon c’est un filtre de séquence à longueur variable." -#: reference/compound_stmts.rst:900 +#: reference/compound_stmts.rst:901 msgid "" "The following is the logical flow for matching a sequence pattern against a " "subject value:" @@ -1281,14 +1284,14 @@ msgstr "" "Voici le déroulement logique d’un filtrage par motif de séquence sur une " "valeur du champ de recherche :" -#: reference/compound_stmts.rst:903 +#: reference/compound_stmts.rst:904 msgid "" "If the subject value is not a sequence [#]_, the sequence pattern fails." msgstr "" "Si la valeur du champ de recherche n’est pas une séquence [#]_, le filtre de " "séquence échoue." -#: reference/compound_stmts.rst:906 +#: reference/compound_stmts.rst:907 msgid "" "If the subject value is an instance of ``str``, ``bytes`` or ``bytearray`` " "the sequence pattern fails." @@ -1296,7 +1299,7 @@ msgstr "" "Si la valeur du champ de recherche est une instance de ``str``, ``bytes`` ou " "``bytearray``, le filtre de séquence échoue." -#: reference/compound_stmts.rst:909 +#: reference/compound_stmts.rst:910 msgid "" "The subsequent steps depend on whether the sequence pattern is fixed or " "variable-length." @@ -1304,12 +1307,12 @@ msgstr "" "Les étapes suivantes dépendent de la longueur fixe ou non du filtre de " "séquence." -#: reference/compound_stmts.rst:912 +#: reference/compound_stmts.rst:913 msgid "If the sequence pattern is fixed-length:" msgstr "Si le filtre de séquence est de longueur fixe :" # Fin de la phrase donc se termine par un point. -#: reference/compound_stmts.rst:914 +#: reference/compound_stmts.rst:915 msgid "" "If the length of the subject sequence is not equal to the number of " "subpatterns, the sequence pattern fails" @@ -1317,7 +1320,7 @@ msgstr "" "Si la longueur de la séquence champ de recherche n’est pas égale au nombre " "de sous-filtres, le filtre de séquence échoue." -#: reference/compound_stmts.rst:917 +#: reference/compound_stmts.rst:918 msgid "" "Subpatterns in the sequence pattern are matched to their corresponding items " "in the subject sequence from left to right. Matching stops as soon as a " @@ -1330,11 +1333,11 @@ msgstr "" "les sous-filtres réussissent la confrontation à l’élément du champ de " "recherche correspondant, le filtre de séquence réussit." -#: reference/compound_stmts.rst:922 +#: reference/compound_stmts.rst:923 msgid "Otherwise, if the sequence pattern is variable-length:" msgstr "Sinon, si le filtre de séquence est de longueur variable :" -#: reference/compound_stmts.rst:924 +#: reference/compound_stmts.rst:925 msgid "" "If the length of the subject sequence is less than the number of non-star " "subpatterns, the sequence pattern fails." @@ -1342,7 +1345,7 @@ msgstr "" "Si la longueur de la séquence champ de recherche est plus petite que le " "nombre de sous-filtres sans étoile, le filtre de séquence échoue." -#: reference/compound_stmts.rst:927 +#: reference/compound_stmts.rst:928 msgid "" "The leading non-star subpatterns are matched to their corresponding items as " "for fixed-length sequences." @@ -1350,7 +1353,7 @@ msgstr "" "Les sous-filtres sans étoile du début sont confrontés aux éléments " "correspondants comme pour un filtre de séquences de longueur fixe." -#: reference/compound_stmts.rst:930 +#: reference/compound_stmts.rst:931 msgid "" "If the previous step succeeds, the star subpattern matches a list formed of " "the remaining subject items, excluding the remaining items corresponding to " @@ -1361,7 +1364,7 @@ msgstr "" "éléments restants qui correspondent à des sous-filtres sans étoile qui " "suivent le sous-filtre étoilé." -#: reference/compound_stmts.rst:934 +#: reference/compound_stmts.rst:935 msgid "" "Remaining non-star subpatterns are matched to their corresponding subject " "items, as for a fixed-length sequence." @@ -1371,7 +1374,7 @@ msgstr "" "longueur fixe." # Pas de majuscule car suit : -#: reference/compound_stmts.rst:937 +#: reference/compound_stmts.rst:938 msgid "" "The length of the subject sequence is obtained via :func:`len` (i.e. via " "the :meth:`__len__` protocol). This length may be cached by the interpreter " @@ -1382,7 +1385,7 @@ msgstr "" "en cache par l’interpréteur de la même manière que pour les :ref:`filtres " "par valeur `." -#: reference/compound_stmts.rst:943 +#: reference/compound_stmts.rst:944 msgid "" "In simple terms ``[P1, P2, P3,`` ... ``, P]`` matches only if all the " "following happens:" @@ -1390,37 +1393,37 @@ msgstr "" "En termes plus simples, ``[M1, M2, M3,`` … ``, M]`` réussit seulement si " "tout ce qui suit a lieu :" -#: reference/compound_stmts.rst:946 +#: reference/compound_stmts.rst:947 msgid "check ```` is a sequence" msgstr "vérification que ```` est une séquence," -#: reference/compound_stmts.rst:947 +#: reference/compound_stmts.rst:948 msgid "``len(subject) == ``" msgstr "``len(subject) == ``," -#: reference/compound_stmts.rst:948 +#: reference/compound_stmts.rst:949 msgid "" "``P1`` matches ``[0]`` (note that this match can also bind names)" msgstr "" "``M1`` correspond à ``[0]`` (notez que cette correspondance peut " "lier des noms)," -#: reference/compound_stmts.rst:949 +#: reference/compound_stmts.rst:950 msgid "" "``P2`` matches ``[1]`` (note that this match can also bind names)" msgstr "" "``M2`` correspond à ``[1]`` (notez que cette correspondance peut " "lier des noms)," -#: reference/compound_stmts.rst:950 +#: reference/compound_stmts.rst:951 msgid "... and so on for the corresponding pattern/element." msgstr "et ainsi de suite pour chaque filtre par motif / élément." -#: reference/compound_stmts.rst:955 +#: reference/compound_stmts.rst:956 msgid "Mapping Patterns" msgstr "Filtres associatifs" -#: reference/compound_stmts.rst:957 +#: reference/compound_stmts.rst:958 msgid "" "A mapping pattern contains one or more key-value patterns. The syntax is " "similar to the construction of a dictionary. Syntax:" @@ -1428,7 +1431,7 @@ msgstr "" "Un filtre associatif contient un ou plusieurs motifs clé-valeur. La syntaxe " "est similaire à la construction d’un dictionnaire :" -#: reference/compound_stmts.rst:968 +#: reference/compound_stmts.rst:969 msgid "" "At most one double star pattern may be in a mapping pattern. The double " "star pattern must be the last subpattern in the mapping pattern." @@ -1437,7 +1440,7 @@ msgstr "" "associatif. Le filtre doublement étoilé doit être le dernier sous-filtre du " "filtre associatif." -#: reference/compound_stmts.rst:971 +#: reference/compound_stmts.rst:972 msgid "" "Duplicate keys in mapping patterns are disallowed. Duplicate literal keys " "will raise a :exc:`SyntaxError`. Two keys that otherwise have the same value " @@ -1447,7 +1450,7 @@ msgstr "" "clé en double sous forme littérale lève une :exc:`Syntax Error`. Deux clés " "qui ont la même valeur lèvent une :exc:`ValueError` à l’exécution." -#: reference/compound_stmts.rst:975 +#: reference/compound_stmts.rst:976 msgid "" "The following is the logical flow for matching a mapping pattern against a " "subject value:" @@ -1455,13 +1458,13 @@ msgstr "" "Voici le déroulement d’un filtrage associatif sur la valeur du champ de " "recherche :" -#: reference/compound_stmts.rst:978 +#: reference/compound_stmts.rst:979 msgid "If the subject value is not a mapping [#]_,the mapping pattern fails." msgstr "" "Si la valeur du champ de recherche n'est pas un tableau associatif [#]_, le " "filtre associatif échoue." -#: reference/compound_stmts.rst:980 +#: reference/compound_stmts.rst:981 msgid "" "If every key given in the mapping pattern is present in the subject mapping, " "and the pattern for each key matches the corresponding item of the subject " @@ -1472,7 +1475,7 @@ msgstr "" "correspond aux éléments du tableau associatif champ de recherche, le filtre " "associatif réussit." -#: reference/compound_stmts.rst:984 +#: reference/compound_stmts.rst:985 msgid "" "If duplicate keys are detected in the mapping pattern, the pattern is " "considered invalid. A :exc:`SyntaxError` is raised for duplicate literal " @@ -1484,7 +1487,7 @@ msgstr "" "même valeur." # Pas de majuscule car suit : -#: reference/compound_stmts.rst:988 +#: reference/compound_stmts.rst:989 msgid "" "Key-value pairs are matched using the two-argument form of the mapping " "subject's ``get()`` method. Matched key-value pairs must already be present " @@ -1496,7 +1499,7 @@ msgstr "" "associées doivent déjà être présentes dans le tableau associatif et ne sont " "pas créées à la volée *via* :meth:`__missing__` ou :meth:`__getitem__`." -#: reference/compound_stmts.rst:993 +#: reference/compound_stmts.rst:994 msgid "" "In simple terms ``{KEY1: P1, KEY2: P2, ... }`` matches only if all the " "following happens:" @@ -1504,27 +1507,27 @@ msgstr "" "En termes simples, ``{CLÉ1: M1, CLÉ2: M2, ... }`` réussit seulement si tout " "ce qui suit a lieu :" -#: reference/compound_stmts.rst:996 +#: reference/compound_stmts.rst:997 msgid "check ```` is a mapping" msgstr "vérification que ```` est un tableau associatif," -#: reference/compound_stmts.rst:997 +#: reference/compound_stmts.rst:998 msgid "``KEY1 in ``" msgstr "``CLÉ1 in ``," -#: reference/compound_stmts.rst:998 +#: reference/compound_stmts.rst:999 msgid "``P1`` matches ``[KEY1]``" msgstr "``M1`` correspond à ``[CLÉ1]``," -#: reference/compound_stmts.rst:999 +#: reference/compound_stmts.rst:1000 msgid "... and so on for the corresponding KEY/pattern pair." msgstr "et ainsi de suite pour chaque paire CLÉ/Motif." -#: reference/compound_stmts.rst:1005 +#: reference/compound_stmts.rst:1006 msgid "Class Patterns" msgstr "Filtres de classes" -#: reference/compound_stmts.rst:1007 +#: reference/compound_stmts.rst:1008 msgid "" "A class pattern represents a class and its positional and keyword arguments " "(if any). Syntax:" @@ -1532,11 +1535,11 @@ msgstr "" "Un filtre de classe représente une classe et ses arguments positionnels et " "par mots-clés (s'il y en a). La syntaxe est la suivante :" -#: reference/compound_stmts.rst:1018 +#: reference/compound_stmts.rst:1019 msgid "The same keyword should not be repeated in class patterns." msgstr "Le même mot-clé ne doit pas être répété dans les filtres de classes." -#: reference/compound_stmts.rst:1020 +#: reference/compound_stmts.rst:1021 msgid "" "The following is the logical flow for matching a class pattern against a " "subject value:" @@ -1544,7 +1547,7 @@ msgstr "" "Voici le déroulement d’un filtrage de classe sur la valeur du champ de " "recherche :" -#: reference/compound_stmts.rst:1023 +#: reference/compound_stmts.rst:1024 msgid "" "If ``name_or_attr`` is not an instance of the builtin :class:`type` , raise :" "exc:`TypeError`." @@ -1552,7 +1555,7 @@ msgstr "" "Si ``name_or_attr`` n'est pas une instance de la classe native :class:" "`type` , lève une :exc:`TypeError`." -#: reference/compound_stmts.rst:1026 +#: reference/compound_stmts.rst:1027 msgid "" "If the subject value is not an instance of ``name_or_attr`` (tested via :" "func:`isinstance`), the class pattern fails." @@ -1561,7 +1564,7 @@ msgstr "" "``name_or_attr`` (testé *via* :func:`isinstance`), le filtre de classe " "échoue." -#: reference/compound_stmts.rst:1029 +#: reference/compound_stmts.rst:1030 msgid "" "If no pattern arguments are present, the pattern succeeds. Otherwise, the " "subsequent steps depend on whether keyword or positional argument patterns " @@ -1571,7 +1574,7 @@ msgstr "" "suivantes dépendent de la présence ou non de motifs pour les arguments " "positionnels ou par mot-clé." -#: reference/compound_stmts.rst:1033 +#: reference/compound_stmts.rst:1034 msgid "" "For a number of built-in types (specified below), a single positional " "subpattern is accepted which will match the entire subject; for these types " @@ -1582,7 +1585,7 @@ msgstr "" "entier ; pour ces types, les motifs par mots-clés fonctionnent comme les " "autres types." -#: reference/compound_stmts.rst:1037 +#: reference/compound_stmts.rst:1038 msgid "" "If only keyword patterns are present, they are processed as follows, one by " "one:" @@ -1590,11 +1593,11 @@ msgstr "" "S'il n'y a que des motifs par mot-clé (NdT : dans le sens « argument par " "mot-clé »), ils sont évalués comme ceci, un par un :" -#: reference/compound_stmts.rst:1040 +#: reference/compound_stmts.rst:1041 msgid "I. The keyword is looked up as an attribute on the subject." msgstr "I. Le mot-clé est recherché en tant qu'attribut du champ de recherche." -#: reference/compound_stmts.rst:1042 +#: reference/compound_stmts.rst:1043 msgid "" "If this raises an exception other than :exc:`AttributeError`, the exception " "bubbles up." @@ -1602,11 +1605,11 @@ msgstr "" "Si cela lève une exception autre que :exc:`AttributeError`, l'exception est " "propagée vers le haut." -#: reference/compound_stmts.rst:1045 +#: reference/compound_stmts.rst:1046 msgid "If this raises :exc:`AttributeError`, the class pattern has failed." msgstr "Si cela lève l'exception :exc:`AttributeError`, le filtre échoue." -#: reference/compound_stmts.rst:1047 +#: reference/compound_stmts.rst:1048 msgid "" "Else, the subpattern associated with the keyword pattern is matched against " "the subject's attribute value. If this fails, the class pattern fails; if " @@ -1616,12 +1619,12 @@ msgstr "" "du champ de recherche. Si cela échoue, le filtre de classe échoue ; si cela " "réussit, le filtre passe au mot-clé suivant." -#: reference/compound_stmts.rst:1052 +#: reference/compound_stmts.rst:1053 msgid "II. If all keyword patterns succeed, the class pattern succeeds." msgstr "" "II. Si tous les motifs par mot-clé ont réussi, le filtre de classe réussit." -#: reference/compound_stmts.rst:1054 +#: reference/compound_stmts.rst:1055 msgid "" "If any positional patterns are present, they are converted to keyword " "patterns using the :data:`~object.__match_args__` attribute on the class " @@ -1631,17 +1634,17 @@ msgstr "" "mot-clé en utilisant l'attribut :data:`~object.__match_args__` de la classe " "``name_or_attr`` avant le filtrage :" -#: reference/compound_stmts.rst:1058 +#: reference/compound_stmts.rst:1059 msgid "" "I. The equivalent of ``getattr(cls, \"__match_args__\", ())`` is called." msgstr "" "I. L'équivalent de ``getattr(cls, \"__match_args__\", ())`` est appelé." -#: reference/compound_stmts.rst:1060 +#: reference/compound_stmts.rst:1061 msgid "If this raises an exception, the exception bubbles up." msgstr "Si cela lève une exception, elle est propagée vers le haut." -#: reference/compound_stmts.rst:1062 +#: reference/compound_stmts.rst:1063 msgid "" "If the returned value is not a tuple, the conversion fails and :exc:" "`TypeError` is raised." @@ -1649,7 +1652,7 @@ msgstr "" "Si la valeur de retour n'est pas un *n*-uplet, la conversion échoue et une :" "exc:`TypeError` est levée." -#: reference/compound_stmts.rst:1065 +#: reference/compound_stmts.rst:1066 msgid "" "If there are more positional patterns than ``len(cls.__match_args__)``, :exc:" "`TypeError` is raised." @@ -1657,7 +1660,7 @@ msgstr "" "S'il y a plus de motifs positionnels que ``len(cls.__match_args__)``, une :" "exc:`TypeError` est levée." -#: reference/compound_stmts.rst:1068 +#: reference/compound_stmts.rst:1069 msgid "" "Otherwise, positional pattern ``i`` is converted to a keyword pattern using " "``__match_args__[i]`` as the keyword. ``__match_args__[i]`` must be a " @@ -1667,28 +1670,28 @@ msgstr "" "clé sera ``__match_args__[i]``). ``__match_args__[i]`` doit être une chaîne, " "sinon une :exc:`TypeError` est levée." -#: reference/compound_stmts.rst:1072 +#: reference/compound_stmts.rst:1073 msgid "If there are duplicate keywords, :exc:`TypeError` is raised." msgstr "Si un mot-clé est dupliqué, une :exc:`TypeError` est levée." -#: reference/compound_stmts.rst:1074 +#: reference/compound_stmts.rst:1075 msgid ":ref:`class-pattern-matching`" msgstr ":ref:`class-pattern-matching`" -#: reference/compound_stmts.rst:1077 +#: reference/compound_stmts.rst:1078 msgid "" "II. Once all positional patterns have been converted to keyword patterns," msgstr "" "II. Une fois que tous les motifs positionnels ont été convertis en motifs " "par mot-clé," -#: reference/compound_stmts.rst:1077 +#: reference/compound_stmts.rst:1078 msgid "the match proceeds as if there were only keyword patterns." msgstr "" "le filtre se déroule comme si tous les motifs étaient des motifs par mots-" "clés." -#: reference/compound_stmts.rst:1079 +#: reference/compound_stmts.rst:1080 msgid "" "For the following built-in types the handling of positional subpatterns is " "different:" @@ -1696,51 +1699,51 @@ msgstr "" "Pour les types natifs suivants, le traitement des motifs positionnels est " "différent :" -#: reference/compound_stmts.rst:1082 +#: reference/compound_stmts.rst:1083 msgid ":class:`bool`" msgstr ":class:`bool`" -#: reference/compound_stmts.rst:1083 +#: reference/compound_stmts.rst:1084 msgid ":class:`bytearray`" msgstr ":class:`bytearray`" -#: reference/compound_stmts.rst:1084 +#: reference/compound_stmts.rst:1085 msgid ":class:`bytes`" msgstr ":class:`bytes`" -#: reference/compound_stmts.rst:1085 +#: reference/compound_stmts.rst:1086 msgid ":class:`dict`" msgstr ":class:`dict`" -#: reference/compound_stmts.rst:1086 +#: reference/compound_stmts.rst:1087 msgid ":class:`float`" msgstr ":class:`float`" -#: reference/compound_stmts.rst:1087 +#: reference/compound_stmts.rst:1088 msgid ":class:`frozenset`" msgstr ":class:`frozenset`" -#: reference/compound_stmts.rst:1088 +#: reference/compound_stmts.rst:1089 msgid ":class:`int`" msgstr ":class:`int`" -#: reference/compound_stmts.rst:1089 reference/compound_stmts.rst:1540 +#: reference/compound_stmts.rst:1090 reference/compound_stmts.rst:1541 msgid ":class:`list`" msgstr ":class:`list`" -#: reference/compound_stmts.rst:1090 +#: reference/compound_stmts.rst:1091 msgid ":class:`set`" msgstr ":class:`set`" -#: reference/compound_stmts.rst:1091 +#: reference/compound_stmts.rst:1092 msgid ":class:`str`" msgstr ":class:`str`" -#: reference/compound_stmts.rst:1092 reference/compound_stmts.rst:1543 +#: reference/compound_stmts.rst:1093 reference/compound_stmts.rst:1544 msgid ":class:`tuple`" msgstr ":class:`tuple`" -#: reference/compound_stmts.rst:1094 +#: reference/compound_stmts.rst:1095 msgid "" "These classes accept a single positional argument, and the pattern there is " "matched against the whole object rather than an attribute. For example " @@ -1752,44 +1755,44 @@ msgstr "" "exemple, ``int(0|1)`` réussit lorsqu'il est confronté à la valeur ``0``, " "mais pas aux valeurs ``0.0`` ou ``False``." -#: reference/compound_stmts.rst:1098 +#: reference/compound_stmts.rst:1099 msgid "" "In simple terms ``CLS(P1, attr=P2)`` matches only if the following happens:" msgstr "" "En termes simples, ``CLS(P1, attr=P2)`` réussit seulement si la séquence " "suivante est déroulée :" -#: reference/compound_stmts.rst:1100 +#: reference/compound_stmts.rst:1101 msgid "``isinstance(, CLS)``" msgstr "``isinstance(, CLS)``" -#: reference/compound_stmts.rst:1101 +#: reference/compound_stmts.rst:1102 msgid "convert ``P1`` to a keyword pattern using ``CLS.__match_args__``" msgstr "" "convertit ``P1`` vers un motif par mot-clé en utilisant ``CLS." "__match_args__``" -#: reference/compound_stmts.rst:1103 +#: reference/compound_stmts.rst:1104 msgid "For each keyword argument ``attr=P2``:" msgstr "Pour chaque argument par mot-clé ``attr=P2`` :" -#: reference/compound_stmts.rst:1103 +#: reference/compound_stmts.rst:1104 msgid "``hasattr(, \"attr\")``" msgstr "``hasattr(, \"attr\")``" -#: reference/compound_stmts.rst:1104 +#: reference/compound_stmts.rst:1105 msgid "``P2`` matches ``.attr``" msgstr "``P2`` correspond à ``.attr``" -#: reference/compound_stmts.rst:1105 +#: reference/compound_stmts.rst:1106 msgid "... and so on for the corresponding keyword argument/pattern pair." msgstr "… et ainsi de suite pour les paires motif/argument par mot-clé." -#: reference/compound_stmts.rst:1120 +#: reference/compound_stmts.rst:1121 msgid "Function definitions" msgstr "Définition de fonctions" -#: reference/compound_stmts.rst:1135 +#: reference/compound_stmts.rst:1136 msgid "" "A function definition defines a user-defined function object (see section :" "ref:`types`):" @@ -1797,7 +1800,7 @@ msgstr "" "Une définition de fonction définit un objet fonction allogène (voir la " "section :ref:`types`) :" -#: reference/compound_stmts.rst:1154 +#: reference/compound_stmts.rst:1155 msgid "" "A function definition is an executable statement. Its execution binds the " "function name in the current local namespace to a function object (a wrapper " @@ -1812,7 +1815,7 @@ msgstr "" "globaux courant comme espace des noms globaux à utiliser lorsque la fonction " "est appelée." -#: reference/compound_stmts.rst:1160 +#: reference/compound_stmts.rst:1161 msgid "" "The function definition does not execute the function body; this gets " "executed only when the function is called. [#]_" @@ -1820,7 +1823,7 @@ msgstr "" "La définition de la fonction n'exécute pas le corps de la fonction ; elle " "n'est exécutée que lorsque la fonction est appelée. [#]_" -#: reference/compound_stmts.rst:1166 +#: reference/compound_stmts.rst:1167 msgid "" "A function definition may be wrapped by one or more :term:`decorator` " "expressions. Decorator expressions are evaluated when the function is " @@ -1839,11 +1842,11 @@ msgstr "" "décorateurs, ils sont appliqués par imbrication ; par exemple, le code " "suivant ::" -#: reference/compound_stmts.rst:1177 reference/compound_stmts.rst:1354 +#: reference/compound_stmts.rst:1178 reference/compound_stmts.rst:1355 msgid "is roughly equivalent to ::" msgstr "est à peu près équivalent à ::" -#: reference/compound_stmts.rst:1182 +#: reference/compound_stmts.rst:1183 msgid "" "except that the original function is not temporarily bound to the name " "``func``." @@ -1851,18 +1854,19 @@ msgstr "" "sauf que la fonction originale n'est pas temporairement liée au nom ``func``." # Pas de majuscule : ok. -#: reference/compound_stmts.rst:1184 +#: reference/compound_stmts.rst:1185 +#, fuzzy msgid "" -"Functions may be decorated with any valid :token:`assignment_expression`. " -"Previously, the grammar was much more restrictive; see :pep:`614` for " -"details." +"Functions may be decorated with any valid :token:`~python-grammar:" +"assignment_expression`. Previously, the grammar was much more restrictive; " +"see :pep:`614` for details." msgstr "" "les fonctions peuvent être décorées par toute :token:`expression " "d'affectation ` valide. Auparavant, la grammaire " "était beaucoup plus restrictive ; voir la :pep:`614` pour obtenir les " "détails." -#: reference/compound_stmts.rst:1194 +#: reference/compound_stmts.rst:1195 msgid "" "When one or more :term:`parameters ` have the form *parameter* " "``=`` *expression*, the function is said to have \"default parameter values." @@ -1881,7 +1885,7 @@ msgstr "" "une valeur par défaut — ceci est une restriction syntaxique qui n'est pas " "exprimée dans la grammaire." -#: reference/compound_stmts.rst:1202 +#: reference/compound_stmts.rst:1203 msgid "" "**Default parameter values are evaluated from left to right when the " "function definition is executed.** This means that the expression is " @@ -1905,7 +1909,7 @@ msgstr "" "``None`` par défaut et de tester explicitement la valeur dans le corps de la " "fonction. Par exemple ::" -#: reference/compound_stmts.rst:1223 +#: reference/compound_stmts.rst:1224 msgid "" "Function call semantics are described in more detail in section :ref:" "`calls`. A function call always assigns values to all parameters mentioned " @@ -1935,7 +1939,7 @@ msgstr "" "``/`` ne peuvent être passés qu'avec des arguments positionnels." # pas de majuscule car suit un : -#: reference/compound_stmts.rst:1235 +#: reference/compound_stmts.rst:1236 msgid "" "The ``/`` function parameter syntax may be used to indicate positional-only " "parameters. See :pep:`570` for details." @@ -1943,7 +1947,7 @@ msgstr "" "ajout de la syntaxe avec ``/`` pour indiquer les paramètre exclusivement " "positionnels (voir la :pep:`570`)." -#: reference/compound_stmts.rst:1244 +#: reference/compound_stmts.rst:1245 msgid "" "Parameters may have an :term:`annotation ` of the form " "\"``: expression``\" following the parameter name. Any parameter may have " @@ -1975,7 +1979,7 @@ msgstr "" "cas, les annotations peuvent être interprétées dans un ordre différent de " "l'ordre dans lequel elles apparaissent dans le fichier." -#: reference/compound_stmts.rst:1259 +#: reference/compound_stmts.rst:1260 msgid "" "It is also possible to create anonymous functions (functions not bound to a " "name), for immediate use in expressions. This uses lambda expressions, " @@ -1996,7 +2000,7 @@ msgstr "" "en fait plus puissante puisqu'elle permet l'exécution de plusieurs " "instructions et les annotations." -#: reference/compound_stmts.rst:1267 +#: reference/compound_stmts.rst:1268 msgid "" "**Programmer's note:** Functions are first-class objects. A \"``def``\" " "statement executed inside a function definition defines a local function " @@ -2011,29 +2015,29 @@ msgstr "" "ont accès aux variables locales de la fonction contenant le \"``def``\". " "Voir la section :ref:`naming` pour plus de détails." -#: reference/compound_stmts.rst:1276 +#: reference/compound_stmts.rst:1277 msgid ":pep:`3107` - Function Annotations" msgstr ":pep:`3107` — Annotations de fonctions" -#: reference/compound_stmts.rst:1276 +#: reference/compound_stmts.rst:1277 msgid "The original specification for function annotations." msgstr "La spécification originale pour les annotations de fonctions." -#: reference/compound_stmts.rst:1279 +#: reference/compound_stmts.rst:1280 msgid ":pep:`484` - Type Hints" msgstr ":pep:`484` — Indications de types" -#: reference/compound_stmts.rst:1279 +#: reference/compound_stmts.rst:1280 msgid "Definition of a standard meaning for annotations: type hints." msgstr "" "Définition de la signification standard pour les annotations : indications " "de types." -#: reference/compound_stmts.rst:1283 +#: reference/compound_stmts.rst:1284 msgid ":pep:`526` - Syntax for Variable Annotations" msgstr ":pep:`526` — Syntaxe pour les annotations de variables" -#: reference/compound_stmts.rst:1282 +#: reference/compound_stmts.rst:1283 msgid "" "Ability to type hint variable declarations, including class variables and " "instance variables" @@ -2041,11 +2045,11 @@ msgstr "" "Capacité d'indiquer des types pour les déclarations de variables, y compris " "les variables de classes et les variables d'instances" -#: reference/compound_stmts.rst:1286 +#: reference/compound_stmts.rst:1287 msgid ":pep:`563` - Postponed Evaluation of Annotations" msgstr ":pep:`563` — Évaluation différée des annotations" -#: reference/compound_stmts.rst:1286 +#: reference/compound_stmts.rst:1287 msgid "" "Support for forward references within annotations by preserving annotations " "in a string form at runtime instead of eager evaluation." @@ -2054,17 +2058,17 @@ msgstr "" "préservant les annotations sous forme de chaînes à l'exécution au lieu d'une " "évaluation directe." -#: reference/compound_stmts.rst:1293 +#: reference/compound_stmts.rst:1294 msgid "Class definitions" msgstr "Définition de classes" -#: reference/compound_stmts.rst:1308 +#: reference/compound_stmts.rst:1309 msgid "A class definition defines a class object (see section :ref:`types`):" msgstr "" "Une définition de classe définit un objet classe (voir la section :ref:" "`types`) :" -#: reference/compound_stmts.rst:1315 +#: reference/compound_stmts.rst:1316 msgid "" "A class definition is an executable statement. The inheritance list usually " "gives a list of base classes (see :ref:`metaclasses` for more advanced " @@ -2080,11 +2084,11 @@ msgstr "" "classes sans liste d'héritage héritent, par défaut, de la classe de base :" "class:`object` ; d'où ::" -#: reference/compound_stmts.rst:1324 +#: reference/compound_stmts.rst:1325 msgid "is equivalent to ::" msgstr "est équivalente à ::" -#: reference/compound_stmts.rst:1329 +#: reference/compound_stmts.rst:1330 msgid "" "The class's suite is then executed in a new execution frame (see :ref:" "`naming`), using a newly created local namespace and the original global " @@ -2105,7 +2109,7 @@ msgstr "" "de nommage sauvegardé comme dictionnaire des attributs. Le nom de classe est " "lié à l'objet classe dans l'espace de nommage local original." -#: reference/compound_stmts.rst:1338 +#: reference/compound_stmts.rst:1339 msgid "" "The order in which attributes are defined in the class body is preserved in " "the new class's ``__dict__``. Note that this is reliable only right after " @@ -2117,7 +2121,7 @@ msgstr "" "n'est fiable que juste après la création de la classe et seulement pour les " "classes qui ont été définies en utilisant la syntaxe de définition." -#: reference/compound_stmts.rst:1343 +#: reference/compound_stmts.rst:1344 msgid "" "Class creation can be customized heavily using :ref:`metaclasses " "`." @@ -2125,13 +2129,13 @@ msgstr "" "La création de classes peut être fortement personnalisée en utilisant les :" "ref:`métaclasses `." -#: reference/compound_stmts.rst:1348 +#: reference/compound_stmts.rst:1349 msgid "Classes can also be decorated: just like when decorating functions, ::" msgstr "" "Les classes peuvent aussi être décorées. Comme pour les décorateurs de " "fonctions ::" -#: reference/compound_stmts.rst:1359 +#: reference/compound_stmts.rst:1360 msgid "" "The evaluation rules for the decorator expressions are the same as for " "function decorators. The result is then bound to the class name." @@ -2140,17 +2144,18 @@ msgstr "" "que pour les décorateurs de fonctions. Le résultat est alors lié au nom de " "la classe." -#: reference/compound_stmts.rst:1362 +#: reference/compound_stmts.rst:1363 +#, fuzzy msgid "" -"Classes may be decorated with any valid :token:`assignment_expression`. " -"Previously, the grammar was much more restrictive; see :pep:`614` for " -"details." +"Classes may be decorated with any valid :token:`~python-grammar:" +"assignment_expression`. Previously, the grammar was much more restrictive; " +"see :pep:`614` for details." msgstr "" "les classes peuvent être décorées par toute :token:`expression d'affectation " "` valide. Auparavant, la grammaire était beaucoup " "plus restrictive ; voir la :pep:`614` pour obtenir les détails." -#: reference/compound_stmts.rst:1367 +#: reference/compound_stmts.rst:1368 msgid "" "**Programmer's note:** Variables defined in the class definition are class " "attributes; they are shared by instances. Instance attributes can be set in " @@ -2174,11 +2179,11 @@ msgstr "" "peuvent être utilisés pour créer des variables d'instances avec des détails " "d'implémentation différents." -#: reference/compound_stmts.rst:1382 +#: reference/compound_stmts.rst:1383 msgid ":pep:`3115` - Metaclasses in Python 3000" msgstr ":pep:`3115` — Métaclasses dans Python 3000" -#: reference/compound_stmts.rst:1380 +#: reference/compound_stmts.rst:1381 msgid "" "The proposal that changed the declaration of metaclasses to the current " "syntax, and the semantics for how classes with metaclasses are constructed." @@ -2187,11 +2192,11 @@ msgstr "" "actuelle, et la sémantique pour la façon dont les classes avec métaclasses " "sont construites." -#: reference/compound_stmts.rst:1385 +#: reference/compound_stmts.rst:1386 msgid ":pep:`3129` - Class Decorators" msgstr ":pep:`3129` — Décorateurs de classes" -#: reference/compound_stmts.rst:1385 +#: reference/compound_stmts.rst:1386 msgid "" "The proposal that added class decorators. Function and method decorators " "were introduced in :pep:`318`." @@ -2199,15 +2204,15 @@ msgstr "" "La proposition qui a ajouté des décorateurs de classe. Les décorateurs de " "fonction et de méthode ont été introduits dans :pep:`318`." -#: reference/compound_stmts.rst:1392 +#: reference/compound_stmts.rst:1393 msgid "Coroutines" msgstr "Coroutines" -#: reference/compound_stmts.rst:1400 +#: reference/compound_stmts.rst:1401 msgid "Coroutine function definition" msgstr "Définition de fonctions coroutines" -#: reference/compound_stmts.rst:1410 +#: reference/compound_stmts.rst:1411 msgid "" "Execution of Python coroutines can be suspended and resumed at many points " "(see :term:`coroutine`). :keyword:`await` expressions, :keyword:`async for` " @@ -2219,7 +2224,7 @@ msgstr "" "keyword:`async for` et :keyword:`async with` ne peuvent être utilisées que " "dans les corps de coroutines." -#: reference/compound_stmts.rst:1414 +#: reference/compound_stmts.rst:1415 msgid "" "Functions defined with ``async def`` syntax are always coroutine functions, " "even if they do not contain ``await`` or ``async`` keywords." @@ -2228,7 +2233,7 @@ msgstr "" "fonctions coroutines, même si elles ne contiennent aucun mot-clé ``await`` " "ou ``async``." -#: reference/compound_stmts.rst:1417 +#: reference/compound_stmts.rst:1418 msgid "" "It is a :exc:`SyntaxError` to use a ``yield from`` expression inside the " "body of a coroutine function." @@ -2236,11 +2241,11 @@ msgstr "" "C'est une :exc:`SyntaxError` d'utiliser une expression ``yield from`` dans " "une coroutine." -#: reference/compound_stmts.rst:1420 +#: reference/compound_stmts.rst:1421 msgid "An example of a coroutine function::" msgstr "Un exemple de fonction coroutine ::" -#: reference/compound_stmts.rst:1426 +#: reference/compound_stmts.rst:1427 msgid "" "``await`` and ``async`` are now keywords; previously they were only treated " "as such inside the body of a coroutine function." @@ -2248,11 +2253,11 @@ msgstr "" "``await`` et ``async`` sont dorénavant des mots-clés ; auparavant, ils " "n'étaient traités comme tels que dans le corps d'une fonction coroutine." -#: reference/compound_stmts.rst:1434 +#: reference/compound_stmts.rst:1435 msgid "The :keyword:`!async for` statement" msgstr "L'instruction :keyword:`!async for`" -#: reference/compound_stmts.rst:1439 +#: reference/compound_stmts.rst:1440 msgid "" "An :term:`asynchronous iterable` provides an ``__aiter__`` method that " "directly returns an :term:`asynchronous iterator`, which can call " @@ -2263,7 +2268,7 @@ msgstr "" "`, celui-ci pouvant appeler du code asynchrone dans " "sa méthode ``__anext__``." -#: reference/compound_stmts.rst:1443 +#: reference/compound_stmts.rst:1444 msgid "" "The ``async for`` statement allows convenient iteration over asynchronous " "iterables." @@ -2271,16 +2276,16 @@ msgstr "" "L'instruction ``async for`` permet d'itérer facilement sur des itérables " "asynchrones." -#: reference/compound_stmts.rst:1453 +#: reference/compound_stmts.rst:1454 msgid "Is semantically equivalent to::" msgstr "est sémantiquement équivalent à ::" -#: reference/compound_stmts.rst:1469 +#: reference/compound_stmts.rst:1470 msgid "See also :meth:`__aiter__` and :meth:`__anext__` for details." msgstr "" "Voir aussi :meth:`__aiter__` et :meth:`__anext__` pour plus de détails." -#: reference/compound_stmts.rst:1471 +#: reference/compound_stmts.rst:1472 msgid "" "It is a :exc:`SyntaxError` to use an ``async for`` statement outside the " "body of a coroutine function." @@ -2288,11 +2293,11 @@ msgstr "" "C'est une :exc:`SyntaxError` d'utiliser une instruction ``async for`` en " "dehors d'une fonction coroutine." -#: reference/compound_stmts.rst:1479 +#: reference/compound_stmts.rst:1480 msgid "The :keyword:`!async with` statement" msgstr "L'instruction :keyword:`!async with`" -#: reference/compound_stmts.rst:1484 +#: reference/compound_stmts.rst:1485 msgid "" "An :term:`asynchronous context manager` is a :term:`context manager` that is " "able to suspend execution in its *enter* and *exit* methods." @@ -2301,12 +2306,12 @@ msgstr "" "manager>` est un :term:`gestionnaire de contexte ` qui est " "capable de suspendre l'exécution dans ses méthodes *enter* et *exit*." -#: reference/compound_stmts.rst:1511 +#: reference/compound_stmts.rst:1512 msgid "See also :meth:`__aenter__` and :meth:`__aexit__` for details." msgstr "" "Voir aussi :meth:`__aenter__` et :meth:`__aexit__` pour plus de détails." -#: reference/compound_stmts.rst:1513 +#: reference/compound_stmts.rst:1514 msgid "" "It is a :exc:`SyntaxError` to use an ``async with`` statement outside the " "body of a coroutine function." @@ -2314,11 +2319,11 @@ msgstr "" "C'est une :exc:`SyntaxError` d'utiliser l'instruction ``async with`` en " "dehors d'une fonction coroutine." -#: reference/compound_stmts.rst:1519 +#: reference/compound_stmts.rst:1520 msgid ":pep:`492` - Coroutines with async and await syntax" msgstr ":pep:`492` — Coroutines avec les syntaxes *async* et *await*" -#: reference/compound_stmts.rst:1519 +#: reference/compound_stmts.rst:1520 msgid "" "The proposal that made coroutines a proper standalone concept in Python, and " "added supporting syntax." @@ -2326,11 +2331,11 @@ msgstr "" "La proposition qui a fait que les coroutines soient un concept propre en " "Python, et a ajouté la syntaxe de prise en charge de celles-ci." -#: reference/compound_stmts.rst:1524 +#: reference/compound_stmts.rst:1525 msgid "Footnotes" msgstr "Notes" -#: reference/compound_stmts.rst:1525 +#: reference/compound_stmts.rst:1526 msgid "" "The exception is propagated to the invocation stack unless there is a :" "keyword:`finally` clause which happens to raise another exception. That new " @@ -2341,52 +2346,52 @@ msgstr "" "perte de l'ancienne exception. Cette nouvelle exception entraîne la perte " "pure et simple de l'ancienne." -#: reference/compound_stmts.rst:1529 +#: reference/compound_stmts.rst:1530 msgid "In pattern matching, a sequence is defined as one of the following:" msgstr "Dans le filtrage par motif, une séquence est définie comme suit :" -#: reference/compound_stmts.rst:1531 +#: reference/compound_stmts.rst:1532 msgid "a class that inherits from :class:`collections.abc.Sequence`" msgstr "une classe qui hérite de :class:`collections.abc.Sequence`" -#: reference/compound_stmts.rst:1532 +#: reference/compound_stmts.rst:1533 msgid "" "a Python class that has been registered as :class:`collections.abc.Sequence`" msgstr "" "une classe Python qui a été enregistrée en tant que :class:`collections.abc." "Sequence`" -#: reference/compound_stmts.rst:1533 +#: reference/compound_stmts.rst:1534 msgid "" "a builtin class that has its (CPython) :data:`Py_TPFLAGS_SEQUENCE` bit set" msgstr "" "une classe native dont le bit (CPython) :data:`Py_TPFLAGS_SEQUENCE` est à 1" -#: reference/compound_stmts.rst:1534 reference/compound_stmts.rst:1553 +#: reference/compound_stmts.rst:1535 reference/compound_stmts.rst:1554 msgid "a class that inherits from any of the above" msgstr "une classe qui hérite d'une classe citée ci-dessus" -#: reference/compound_stmts.rst:1536 +#: reference/compound_stmts.rst:1537 msgid "The following standard library classes are sequences:" msgstr "Les classes suivantes de la bibliothèque standard sont des séquences :" -#: reference/compound_stmts.rst:1538 +#: reference/compound_stmts.rst:1539 msgid ":class:`array.array`" msgstr ":class:`array.array`" -#: reference/compound_stmts.rst:1539 +#: reference/compound_stmts.rst:1540 msgid ":class:`collections.deque`" msgstr ":class:`collections.deque`" -#: reference/compound_stmts.rst:1541 +#: reference/compound_stmts.rst:1542 msgid ":class:`memoryview`" msgstr ":class:`memoryview`" -#: reference/compound_stmts.rst:1542 +#: reference/compound_stmts.rst:1543 msgid ":class:`range`" msgstr ":class:`range`" -#: reference/compound_stmts.rst:1545 +#: reference/compound_stmts.rst:1546 msgid "" "Subject values of type ``str``, ``bytes``, and ``bytearray`` do not match " "sequence patterns." @@ -2394,29 +2399,29 @@ msgstr "" "Les champs de recherche du type ``str``, ``bytes`` et ``bytearray`` ne " "correspondent pas avec des filtres de séquence." -#: reference/compound_stmts.rst:1548 +#: reference/compound_stmts.rst:1549 msgid "In pattern matching, a mapping is defined as one of the following:" msgstr "" "Dans le filtrage par motif, un tableau associatif est défini comme suit :" -#: reference/compound_stmts.rst:1550 +#: reference/compound_stmts.rst:1551 msgid "a class that inherits from :class:`collections.abc.Mapping`" msgstr "une classe qui hérite de :class:`collections.abc.Mapping`" -#: reference/compound_stmts.rst:1551 +#: reference/compound_stmts.rst:1552 msgid "" "a Python class that has been registered as :class:`collections.abc.Mapping`" msgstr "" "une classe Python qui a été enregistrée en tant que :class:`collections.abc." "Mapping`" -#: reference/compound_stmts.rst:1552 +#: reference/compound_stmts.rst:1553 msgid "" "a builtin class that has its (CPython) :data:`Py_TPFLAGS_MAPPING` bit set" msgstr "" "une classe native dont le bit (CPython) :data:`Py_TPFLAGS_MAPPING` est à 1" -#: reference/compound_stmts.rst:1555 +#: reference/compound_stmts.rst:1556 msgid "" "The standard library classes :class:`dict` and :class:`types." "MappingProxyType` are mappings." @@ -2424,7 +2429,7 @@ msgstr "" "Les classes :class:`dict` et :class:`types.MappingProxyType` de la " "bibliothèque standard sont des tableaux associatifs." -#: reference/compound_stmts.rst:1558 +#: reference/compound_stmts.rst:1559 msgid "" "A string literal appearing as the first statement in the function body is " "transformed into the function's ``__doc__`` attribute and therefore the " @@ -2434,7 +2439,7 @@ msgstr "" "de la fonction est transformée en attribut ``__doc__`` de la fonction et " "donc en :term:`docstring` de la fonction." -#: reference/compound_stmts.rst:1562 +#: reference/compound_stmts.rst:1563 msgid "" "A string literal appearing as the first statement in the class body is " "transformed into the namespace's ``__doc__`` item and therefore the class's :" diff --git a/reference/datamodel.po b/reference/datamodel.po index 1395fc5e..bf5e6b53 100644 --- a/reference/datamodel.po +++ b/reference/datamodel.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-11-04 18:14+0100\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-10-21 23:42+0200\n" "Last-Translator: Jean Abou Samra \n" "Language-Team: FRENCH \n" @@ -1180,16 +1180,17 @@ msgid "Generator functions" msgstr "Fonctions générateurs" #: reference/datamodel.rst:649 +#, fuzzy msgid "" "A function or method which uses the :keyword:`yield` statement (see section :" "ref:`yield`) is called a :dfn:`generator function`. Such a function, when " -"called, always returns an iterator object which can be used to execute the " -"body of the function: calling the iterator's :meth:`iterator.__next__` " -"method will cause the function to execute until it provides a value using " -"the :keyword:`!yield` statement. When the function executes a :keyword:" -"`return` statement or falls off the end, a :exc:`StopIteration` exception is " -"raised and the iterator will have reached the end of the set of values to be " -"returned." +"called, always returns an :term:`iterator` object which can be used to " +"execute the body of the function: calling the iterator's :meth:`iterator." +"__next__` method will cause the function to execute until it provides a " +"value using the :keyword:`!yield` statement. When the function executes a :" +"keyword:`return` statement or falls off the end, a :exc:`StopIteration` " +"exception is raised and the iterator will have reached the end of the set of " +"values to be returned." msgstr "" "Une fonction ou une méthode qui utilise l'instruction :keyword:`yield` (voir " "la section :ref:`yield`) est appelée :dfn:`fonction générateur`. Une telle " @@ -1224,12 +1225,13 @@ msgid "Asynchronous generator functions" msgstr "Fonctions générateurs asynchrones" #: reference/datamodel.rst:674 +#, fuzzy msgid "" "A function or method which is defined using :keyword:`async def` and which " "uses the :keyword:`yield` statement is called a :dfn:`asynchronous generator " -"function`. Such a function, when called, returns an asynchronous iterator " -"object which can be used in an :keyword:`async for` statement to execute the " -"body of the function." +"function`. Such a function, when called, returns an :term:`asynchronous " +"iterator` object which can be used in an :keyword:`async for` statement to " +"execute the body of the function." msgstr "" "Une fonction ou une méthode définie avec :keyword:`async def` et qui utilise " "l'instruction :keyword:`yield` est appelée :dfn:`fonction générateur " @@ -3533,7 +3535,7 @@ msgstr "" "qui est utilisé à la place de la classe de base. Le *n*-uplet peut être " "vide, dans ce cas la classe de base originale est ignorée." -#: reference/datamodel.rst:2198 +#: reference/datamodel.rst:2008 msgid ":pep:`560` - Core support for typing module and generic types" msgstr "" ":pep:`560` — Gestion de base pour les types modules et les types génériques" @@ -3882,14 +3884,48 @@ msgstr "Émulation de types génériques" #: reference/datamodel.rst:2183 msgid "" -"One can implement the generic class syntax as specified by :pep:`484` (for " -"example ``List[int]``) by defining a special method:" +"When using :term:`type annotations`, it is often useful to " +"*parameterize* a :term:`generic type` using Python's square-brackets " +"notation. For example, the annotation ``list[int]`` might be used to signify " +"a :class:`list` in which all the elements are of type :class:`int`." msgstr "" -"Vous pouvez implémenter la syntaxe générique des classes comme spécifié par " -"la :pep:`484` (par exemple ``List[int]``) en définissant une méthode " -"spéciale :" -#: reference/datamodel.rst:2188 +#: reference/datamodel.rst:2191 +#, fuzzy +msgid ":pep:`484` - Type Hints" +msgstr ":pep:`343` — L'instruction ``with``" + +#: reference/datamodel.rst:2191 +msgid "Introducing Python's framework for type annotations" +msgstr "" + +#: reference/datamodel.rst:2194 +msgid ":ref:`Generic Alias Types`" +msgstr "" + +#: reference/datamodel.rst:2194 +msgid "Documentation for objects representing parameterized generic classes" +msgstr "" + +#: reference/datamodel.rst:2197 +msgid "" +":ref:`Generics`, :ref:`user-defined generics` and :" +"class:`typing.Generic`" +msgstr "" + +#: reference/datamodel.rst:2197 +msgid "" +"Documentation on how to implement generic classes that can be parameterized " +"at runtime and understood by static type-checkers." +msgstr "" + +#: reference/datamodel.rst:2200 +msgid "" +"A class can *generally* only be parameterized if it defines the special " +"class method ``__class_getitem__()``." +msgstr "" + +#: reference/datamodel.rst:2205 msgid "" "Return an object representing the specialization of a generic class by type " "arguments found in *key*." @@ -3897,24 +3933,97 @@ msgstr "" "Renvoie un objet représentant la spécialisation d'une classe générique en " "fonction des arguments types trouvés dans *key*." -#: reference/datamodel.rst:2191 +#: reference/datamodel.rst:2208 msgid "" -"This method is looked up on the class object itself, and when defined in the " -"class body, this method is implicitly a class method. Note, this mechanism " -"is primarily reserved for use with static type hints, other usage is " -"discouraged." +"When defined on a class, ``__class_getitem__()`` is automatically a class " +"method. As such, there is no need for it to be decorated with :func:" +"`@classmethod` when it is defined." msgstr "" -"Python recherche cette méthode dans l'objet de classe lui-même et, " -"lorsqu'elle est définie dans le corps de la classe, cette méthode est " -"implicitement une méthode de classe. Notez que ce mécanisme est " -"principalement réservé à une utilisation avec des indications de type " -"statiques, d'autres utilisations sont déconseillées." -#: reference/datamodel.rst:2204 +#: reference/datamodel.rst:2214 +msgid "The purpose of *__class_getitem__*" +msgstr "" + +#: reference/datamodel.rst:2216 +msgid "" +"The purpose of :meth:`~object.__class_getitem__` is to allow runtime " +"parameterization of standard-library generic classes in order to more easily " +"apply :term:`type hints` to these classes." +msgstr "" + +#: reference/datamodel.rst:2220 +msgid "" +"To implement custom generic classes that can be parameterized at runtime and " +"understood by static type-checkers, users should either inherit from a " +"standard library class that already implements :meth:`~object." +"__class_getitem__`, or inherit from :class:`typing.Generic`, which has its " +"own implementation of ``__class_getitem__()``." +msgstr "" + +#: reference/datamodel.rst:2226 +msgid "" +"Custom implementations of :meth:`~object.__class_getitem__` on classes " +"defined outside of the standard library may not be understood by third-party " +"type-checkers such as mypy. Using ``__class_getitem__()`` on any class for " +"purposes other than type hinting is discouraged." +msgstr "" + +#: reference/datamodel.rst:2236 +msgid "*__class_getitem__* versus *__getitem__*" +msgstr "" + +#: reference/datamodel.rst:2238 +msgid "" +"Usually, the :ref:`subscription` of an object using square " +"brackets will call the :meth:`~object.__getitem__` instance method defined " +"on the object's class. However, if the object being subscribed is itself a " +"class, the class method :meth:`~object.__class_getitem__` may be called " +"instead. ``__class_getitem__()`` should return a :ref:`GenericAlias` object if it is properly defined." +msgstr "" + +#: reference/datamodel.rst:2245 +msgid "" +"Presented with the :term:`expression` ``obj[x]``, the Python interpreter " +"follows something like the following process to decide whether :meth:" +"`~object.__getitem__` or :meth:`~object.__class_getitem__` should be called::" +msgstr "" + +#: reference/datamodel.rst:2273 +msgid "" +"In Python, all classes are themselves instances of other classes. The class " +"of a class is known as that class's :term:`metaclass`, and most classes have " +"the :class:`type` class as their metaclass. :class:`type` does not define :" +"meth:`~object.__getitem__`, meaning that expressions such as ``list[int]``, " +"``dict[str, float]`` and ``tuple[str, bytes]`` all result in :meth:`~object." +"__class_getitem__` being called::" +msgstr "" + +#: reference/datamodel.rst:2292 +msgid "" +"However, if a class has a custom metaclass that defines :meth:`~object." +"__getitem__`, subscribing the class may result in different behaviour. An " +"example of this can be found in the :mod:`enum` module::" +msgstr "" + +#: reference/datamodel.rst:2317 +#, fuzzy +msgid ":pep:`560` - Core Support for typing module and generic types" +msgstr "" +":pep:`560` — Gestion de base pour les types modules et les types génériques" + +#: reference/datamodel.rst:2316 +msgid "" +"Introducing :meth:`~object.__class_getitem__`, and outlining when a :ref:" +"`subscription` results in ``__class_getitem__()`` being " +"called instead of :meth:`~object.__getitem__`" +msgstr "" + +#: reference/datamodel.rst:2324 msgid "Emulating callable objects" msgstr "Émulation d'objets appelables" -#: reference/datamodel.rst:2211 +#: reference/datamodel.rst:2331 msgid "" "Called when the instance is \"called\" as a function; if this method is " "defined, ``x(arg1, arg2, ...)`` roughly translates to ``type(x).__call__(x, " @@ -3924,11 +4033,11 @@ msgstr "" "méthode est définie, ``x(arg1, arg2, …)`` est un raccourci pour ``type(x)." "__call__(x, arg1, …)``." -#: reference/datamodel.rst:2218 +#: reference/datamodel.rst:2338 msgid "Emulating container types" msgstr "Émulation de types conteneurs" -#: reference/datamodel.rst:2220 +#: reference/datamodel.rst:2340 msgid "" "The following methods can be defined to implement container objects. " "Containers usually are sequences (such as lists or tuples) or mappings (like " @@ -3995,7 +4104,7 @@ msgstr "" "de correspondances, :meth:`__iter__` doit itérer sur les clés de l'objet ; " "pour les séquences, elle doit itérer sur les valeurs." -#: reference/datamodel.rst:2255 +#: reference/datamodel.rst:2375 msgid "" "Called to implement the built-in function :func:`len`. Should return the " "length of the object, an integer ``>=`` 0. Also, an object that doesn't " @@ -4007,7 +4116,7 @@ msgstr "" "définit pas de méthode :meth:`__bool__` et dont la méthode :meth:`__len__` " "renvoie zéro est considéré comme valant ``False`` dans un contexte booléen." -#: reference/datamodel.rst:2262 +#: reference/datamodel.rst:2382 msgid "" "In CPython, the length is required to be at most :attr:`sys.maxsize`. If the " "length is larger than :attr:`!sys.maxsize` some features (such as :func:" @@ -4021,7 +4130,7 @@ msgstr "" "exc:`!OverflowError` lors de tests booléens, un objet doit définir la " "méthode :meth:`__bool__`." -#: reference/datamodel.rst:2271 +#: reference/datamodel.rst:2391 msgid "" "Called to implement :func:`operator.length_hint`. Should return an estimated " "length for the object (which may be greater or less than the actual length). " @@ -4038,31 +4147,33 @@ msgstr "" "méthode est utilisée uniquement pour optimiser les traitements et n'est " "jamais tenue de renvoyer un résultat exact." -#: reference/datamodel.rst:2285 +#: reference/datamodel.rst:2405 msgid "" "Slicing is done exclusively with the following three methods. A call like ::" msgstr "" "Le découpage est effectué uniquement à l'aide des trois méthodes suivantes. " "Un appel comme ::" -#: reference/datamodel.rst:2289 +#: reference/datamodel.rst:2409 msgid "is translated to ::" msgstr "est traduit en ::" -#: reference/datamodel.rst:2293 +#: reference/datamodel.rst:2413 msgid "and so forth. Missing slice items are always filled in with ``None``." msgstr "et ainsi de suite. Les éléments manquants sont remplacés par ``None``." -#: reference/datamodel.rst:2298 +#: reference/datamodel.rst:2418 +#, fuzzy msgid "" -"Called to implement evaluation of ``self[key]``. For sequence types, the " -"accepted keys should be integers and slice objects. Note that the special " -"interpretation of negative indexes (if the class wishes to emulate a " -"sequence type) is up to the :meth:`__getitem__` method. If *key* is of an " -"inappropriate type, :exc:`TypeError` may be raised; if of a value outside " -"the set of indexes for the sequence (after any special interpretation of " -"negative values), :exc:`IndexError` should be raised. For mapping types, if " -"*key* is missing (not in the container), :exc:`KeyError` should be raised." +"Called to implement evaluation of ``self[key]``. For :term:`sequence` types, " +"the accepted keys should be integers and slice objects. Note that the " +"special interpretation of negative indexes (if the class wishes to emulate " +"a :term:`sequence` type) is up to the :meth:`__getitem__` method. If *key* " +"is of an inappropriate type, :exc:`TypeError` may be raised; if of a value " +"outside the set of indexes for the sequence (after any special " +"interpretation of negative values), :exc:`IndexError` should be raised. For :" +"term:`mapping` types, if *key* is missing (not in the container), :exc:" +"`KeyError` should be raised." msgstr "" "Appelée pour implémenter l'évaluation de ``self[key]``. Pour les types " "séquences, les clés autorisées sont les entiers et les objets tranches " @@ -4074,7 +4185,7 @@ msgstr "" "`IndexError` doit être levée. Pour les tableaux de correspondances, si *key* " "n'existe pas dans le conteneur, une :exc:`KeyError` doit être levée." -#: reference/datamodel.rst:2309 +#: reference/datamodel.rst:2430 msgid "" ":keyword:`for` loops expect that an :exc:`IndexError` will be raised for " "illegal indexes to allow proper detection of the end of the sequence." @@ -4082,7 +4193,14 @@ msgstr "" ":keyword:`for` s'attend à ce qu'une :exc:`IndexError` soit levée en cas " "d'indice illégal afin de détecter correctement la fin de la séquence." -#: reference/datamodel.rst:2315 +#: reference/datamodel.rst:2435 +msgid "" +"When :ref:`subscripting` a *class*, the special class method :" +"meth:`~object.__class_getitem__` may be called instead of ``__getitem__()``. " +"See :ref:`classgetitem-versus-getitem` for more details." +msgstr "" + +#: reference/datamodel.rst:2443 msgid "" "Called to implement assignment to ``self[key]``. Same note as for :meth:" "`__getitem__`. This should only be implemented for mappings if the objects " @@ -4098,7 +4216,7 @@ msgstr "" "exceptions que pour la méthode :meth:`__getitem__` doivent être levées en " "cas de mauvaises valeurs de clés." -#: reference/datamodel.rst:2324 +#: reference/datamodel.rst:2452 msgid "" "Called to implement deletion of ``self[key]``. Same note as for :meth:" "`__getitem__`. This should only be implemented for mappings if the objects " @@ -4113,7 +4231,7 @@ msgstr "" "Les mêmes exceptions que pour la méthode :meth:`__getitem__` doivent être " "levées en cas de mauvaises valeurs de clés." -#: reference/datamodel.rst:2333 +#: reference/datamodel.rst:2461 msgid "" "Called by :class:`dict`\\ .\\ :meth:`__getitem__` to implement ``self[key]`` " "for dict subclasses when key is not in the dictionary." @@ -4122,29 +4240,20 @@ msgstr "" "``self[key]`` dans les sous-classes de dictionnaires lorsque la clé n'est " "pas dans le dictionnaire." -#: reference/datamodel.rst:2339 +#: reference/datamodel.rst:2467 +#, fuzzy msgid "" -"This method is called when an iterator is required for a container. This " -"method should return a new iterator object that can iterate over all the " -"objects in the container. For mappings, it should iterate over the keys of " -"the container." +"This method is called when an :term:`iterator` is required for a container. " +"This method should return a new iterator object that can iterate over all " +"the objects in the container. For mappings, it should iterate over the keys " +"of the container." msgstr "" "Cette méthode est appelée quand un itérateur est requis pour un conteneur. " "Cette méthode doit renvoyer un nouvel objet itérateur qui peut itérer sur " "tous les objets du conteneur. Pour les tableaux de correspondances, elle " "doit itérer sur les clés du conteneur." -#: reference/datamodel.rst:2343 -msgid "" -"Iterator objects also need to implement this method; they are required to " -"return themselves. For more information on iterator objects, see :ref:" -"`typeiter`." -msgstr "" -"Les objets itérateurs doivent aussi implémenter cette méthode ; ils doivent " -"alors se renvoyer eux-mêmes. Pour plus d'information sur les objets " -"itérateurs, lisez :ref:`typeiter`." - -#: reference/datamodel.rst:2349 +#: reference/datamodel.rst:2475 msgid "" "Called (if present) by the :func:`reversed` built-in to implement reverse " "iteration. It should return a new iterator object that iterates over all " @@ -4154,7 +4263,7 @@ msgstr "" "implémenter l'itération en sens inverse. Elle doit renvoyer un nouvel objet " "itérateur qui itère sur tous les objets du conteneur en sens inverse." -#: reference/datamodel.rst:2353 +#: reference/datamodel.rst:2479 msgid "" "If the :meth:`__reversed__` method is not provided, the :func:`reversed` " "built-in will fall back to using the sequence protocol (:meth:`__len__` and :" @@ -4168,7 +4277,7 @@ msgstr "" "doivent fournir :meth:`__reversed__` que si l'implémentation qu'ils " "proposent est plus efficace que celle de :func:`reversed`." -#: reference/datamodel.rst:2360 +#: reference/datamodel.rst:2486 msgid "" "The membership test operators (:keyword:`in` and :keyword:`not in`) are " "normally implemented as an iteration through a container. However, container " @@ -4181,7 +4290,7 @@ msgstr "" "suivantes avec une implémentation plus efficace, qui ne requièrent " "d'ailleurs pas que l'objet soit itérable." -#: reference/datamodel.rst:2367 +#: reference/datamodel.rst:2493 msgid "" "Called to implement membership test operators. Should return true if *item* " "is in *self*, false otherwise. For mapping objects, this should consider " @@ -4192,7 +4301,7 @@ msgstr "" "tableaux de correspondances, seules les clés sont considérées (pas les " "valeurs des paires clés-valeurs)." -#: reference/datamodel.rst:2371 +#: reference/datamodel.rst:2497 msgid "" "For objects that don't define :meth:`__contains__`, the membership test " "first tries iteration via :meth:`__iter__`, then the old sequence iteration " @@ -4205,11 +4314,11 @@ msgstr "" "reportez-vous à :ref:`cette section dans la référence du langage `." -#: reference/datamodel.rst:2380 +#: reference/datamodel.rst:2506 msgid "Emulating numeric types" msgstr "Émulation de types numériques" -#: reference/datamodel.rst:2382 +#: reference/datamodel.rst:2508 msgid "" "The following methods can be defined to emulate numeric objects. Methods " "corresponding to operations that are not supported by the particular kind of " @@ -4222,7 +4331,7 @@ msgstr "" "opérations bit à bit pour les nombres qui ne sont pas entiers) doivent être " "laissées indéfinies." -#: reference/datamodel.rst:2408 +#: reference/datamodel.rst:2534 msgid "" "These methods are called to implement the binary arithmetic operations (``" "+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :func:`pow`, " @@ -4245,7 +4354,7 @@ msgstr "" "accepter un troisième argument optionnel si la version ternaire de la " "fonction native :func:`pow` est autorisée." -#: reference/datamodel.rst:2419 +#: reference/datamodel.rst:2545 msgid "" "If one of those methods does not support the operation with the supplied " "arguments, it should return ``NotImplemented``." @@ -4253,7 +4362,7 @@ msgstr "" "Si l'une de ces méthodes n'autorise pas l'opération avec les arguments " "donnés, elle doit renvoyer ``NotImplemented``." -#: reference/datamodel.rst:2442 +#: reference/datamodel.rst:2568 msgid "" "These methods are called to implement the binary arithmetic operations (``" "+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :func:`pow`, " @@ -4274,7 +4383,7 @@ msgstr "" "`__rsub__`, ``y.__rsub__(x)`` est appelée si ``x.__sub__(y)`` renvoie " "*NotImplemented*." -#: reference/datamodel.rst:2453 +#: reference/datamodel.rst:2579 msgid "" "Note that ternary :func:`pow` will not try calling :meth:`__rpow__` (the " "coercion rules would become too complicated)." @@ -4282,7 +4391,7 @@ msgstr "" "Notez que la fonction ternaire :func:`pow` n'essaie pas d'appeler :meth:" "`__rpow__` (les règles de coercition seraient trop compliquées)." -#: reference/datamodel.rst:2458 +#: reference/datamodel.rst:2584 msgid "" "If the right operand's type is a subclass of the left operand's type and " "that subclass provides a different implementation of the reflected method " @@ -4296,7 +4405,7 @@ msgstr "" "méthode originelle de l'opérande gauche. Ce comportement permet à des sous-" "classes de surcharger les opérations de leurs ancêtres." -#: reference/datamodel.rst:2479 +#: reference/datamodel.rst:2605 msgid "" "These methods are called to implement the augmented arithmetic assignments " "(``+=``, ``-=``, ``*=``, ``@=``, ``/=``, ``//=``, ``%=``, ``**=``, ``<<=``, " @@ -4325,7 +4434,7 @@ msgstr "" "erreurs inattendues (voir :ref:`faq-augmented-assignment-tuple-error`), mais " "ce comportement est en fait partie intégrante du modèle de données." -#: reference/datamodel.rst:2500 +#: reference/datamodel.rst:2626 msgid "" "Called to implement the unary arithmetic operations (``-``, ``+``, :func:" "`abs` and ``~``)." @@ -4333,7 +4442,7 @@ msgstr "" "Appelée pour implémenter les opérations arithmétiques unaires (``-``, ``" "+``, :func:`abs` et ``~``)." -#: reference/datamodel.rst:2513 +#: reference/datamodel.rst:2639 msgid "" "Called to implement the built-in functions :func:`complex`, :func:`int` and :" "func:`float`. Should return a value of the appropriate type." @@ -4341,7 +4450,7 @@ msgstr "" "Appelées pour implémenter les fonctions natives :func:`complex`, :func:`int` " "et :func:`float`. Elles doivent renvoyer une valeur du type approprié." -#: reference/datamodel.rst:2520 +#: reference/datamodel.rst:2646 msgid "" "Called to implement :func:`operator.index`, and whenever Python needs to " "losslessly convert the numeric object to an integer object (such as in " @@ -4355,7 +4464,7 @@ msgstr "" "`oct`). La présence de cette méthode indique que l'objet numérique est un " "type entier. Elle doit renvoyer un entier." -#: reference/datamodel.rst:2526 +#: reference/datamodel.rst:2652 msgid "" "If :meth:`__int__`, :meth:`__float__` and :meth:`__complex__` are not " "defined then corresponding built-in functions :func:`int`, :func:`float` " @@ -4365,7 +4474,7 @@ msgstr "" "définies, alors les fonctions natives :func:`int`, :func:`float` et :func:" "`complex` redirigent par défaut vers :meth:`__index__`." -#: reference/datamodel.rst:2538 +#: reference/datamodel.rst:2664 msgid "" "Called to implement the built-in function :func:`round` and :mod:`math` " "functions :func:`~math.trunc`, :func:`~math.floor` and :func:`~math.ceil`. " @@ -4379,17 +4488,17 @@ msgstr "" "toutes ces méthodes doivent renvoyer la valeur de l'objet tronquée pour " "donner un :class:`~numbers.Integral` (typiquement un :class:`int`)." -#: reference/datamodel.rst:2544 +#: reference/datamodel.rst:2670 msgid "" "The built-in function :func:`int` falls back to :meth:`__trunc__` if " "neither :meth:`__int__` nor :meth:`__index__` is defined." msgstr "" -#: reference/datamodel.rst:2551 +#: reference/datamodel.rst:2677 msgid "With Statement Context Managers" msgstr "Gestionnaire de contexte With" -#: reference/datamodel.rst:2553 +#: reference/datamodel.rst:2679 msgid "" "A :dfn:`context manager` is an object that defines the runtime context to be " "established when executing a :keyword:`with` statement. The context manager " @@ -4406,7 +4515,7 @@ msgstr "" "dans la section :ref:`with`), mais ils peuvent aussi être directement " "invoqués par leurs méthodes." -#: reference/datamodel.rst:2564 +#: reference/datamodel.rst:2690 msgid "" "Typical uses of context managers include saving and restoring various kinds " "of global state, locking and unlocking resources, closing opened files, etc." @@ -4415,14 +4524,14 @@ msgstr "" "et la restauration d'états divers, le verrouillage et le déverrouillage de " "ressources, la fermeture de fichiers ouverts, etc." -#: reference/datamodel.rst:2567 +#: reference/datamodel.rst:2693 msgid "" "For more information on context managers, see :ref:`typecontextmanager`." msgstr "" "Pour plus d'informations sur les gestionnaires de contexte, lisez :ref:" "`typecontextmanager`." -#: reference/datamodel.rst:2572 +#: reference/datamodel.rst:2698 msgid "" "Enter the runtime context related to this object. The :keyword:`with` " "statement will bind this method's return value to the target(s) specified in " @@ -4433,7 +4542,7 @@ msgstr "" "cible spécifiée par la clause :keyword:`!as` de l'instruction, si elle est " "spécifiée." -#: reference/datamodel.rst:2579 +#: reference/datamodel.rst:2705 msgid "" "Exit the runtime context related to this object. The parameters describe the " "exception that caused the context to be exited. If the context was exited " @@ -4443,7 +4552,7 @@ msgstr "" "l'exception qui a causé la sortie du contexte. Si l'on sort du contexte sans " "exception, les trois arguments sont à :const:`None`." -#: reference/datamodel.rst:2583 +#: reference/datamodel.rst:2709 msgid "" "If an exception is supplied, and the method wishes to suppress the exception " "(i.e., prevent it from being propagated), it should return a true value. " @@ -4455,7 +4564,7 @@ msgstr "" "propagée), elle doit renvoyer ``True``. Sinon, l'exception est traitée " "normalement à la sortie de cette méthode." -#: reference/datamodel.rst:2587 +#: reference/datamodel.rst:2713 msgid "" "Note that :meth:`__exit__` methods should not reraise the passed-in " "exception; this is the caller's responsibility." @@ -4463,11 +4572,11 @@ msgstr "" "Notez qu'une méthode :meth:`__exit__` ne doit pas lever à nouveau " "l'exception qu'elle reçoit ; c'est du ressort de l'appelant." -#: reference/datamodel.rst:2594 +#: reference/datamodel.rst:2720 msgid ":pep:`343` - The \"with\" statement" msgstr ":pep:`343` — L'instruction ``with``" -#: reference/datamodel.rst:2594 +#: reference/datamodel.rst:2720 msgid "" "The specification, background, and examples for the Python :keyword:`with` " "statement." @@ -4475,11 +4584,11 @@ msgstr "" "La spécification, les motivations et des exemples de l'instruction :keyword:" "`with` en Python." -#: reference/datamodel.rst:2601 +#: reference/datamodel.rst:2727 msgid "Customizing positional arguments in class pattern matching" msgstr "Arguments positionnels dans le filtrage par motif sur les classes" -#: reference/datamodel.rst:2603 +#: reference/datamodel.rst:2729 msgid "" "When using a class name in a pattern, positional arguments in the pattern " "are not allowed by default, i.e. ``case MyClass(x, y)`` is typically invalid " @@ -4491,7 +4600,7 @@ msgstr "" "fait rien pour cela. Afin de prendre en charge le filtrage par arguments " "positionnels, une classe doit définir ``__match_args__``." -#: reference/datamodel.rst:2610 +#: reference/datamodel.rst:2736 msgid "" "This class variable can be assigned a tuple of strings. When this class is " "used in a class pattern with positional arguments, each positional argument " @@ -4505,7 +4614,7 @@ msgstr "" "n'est pas défini, tout se passe comme si sa valeur était le *n*-uplet vide " "``()``." -#: reference/datamodel.rst:2616 +#: reference/datamodel.rst:2742 msgid "" "For example, if ``MyClass.__match_args__`` is ``(\"left\", \"center\", " "\"right\")`` that means that ``case MyClass(x, y)`` is equivalent to ``case " @@ -4520,19 +4629,19 @@ msgstr "" "d'arguments positionnels que la longueur ``__match_args__``. Dans le cas " "contraire, le filtrage lève l'exception :exc:`TypeError`." -#: reference/datamodel.rst:2626 +#: reference/datamodel.rst:2752 msgid ":pep:`634` - Structural Pattern Matching" msgstr ":pep:`634` — Filtrage par motif structurel" -#: reference/datamodel.rst:2627 +#: reference/datamodel.rst:2753 msgid "The specification for the Python ``match`` statement." msgstr "Spécification de l'instruction ``match``." -#: reference/datamodel.rst:2633 +#: reference/datamodel.rst:2759 msgid "Special method lookup" msgstr "Recherche des méthodes spéciales" -#: reference/datamodel.rst:2635 +#: reference/datamodel.rst:2761 msgid "" "For custom classes, implicit invocations of special methods are only " "guaranteed to work correctly if defined on an object's type, not in the " @@ -4544,7 +4653,7 @@ msgstr "" "type d'objet, pas dans le dictionnaire de l'objet instance. Ce comportement " "explique pourquoi le code suivant lève une exception ::" -#: reference/datamodel.rst:2650 +#: reference/datamodel.rst:2776 msgid "" "The rationale behind this behaviour lies with a number of special methods " "such as :meth:`__hash__` and :meth:`__repr__` that are implemented by all " @@ -4558,7 +4667,7 @@ msgstr "" "méthodes utilisait le processus normal de recherche, elles ne " "fonctionneraient pas si on les appelait sur l'objet type lui-même ::" -#: reference/datamodel.rst:2663 +#: reference/datamodel.rst:2789 msgid "" "Incorrectly attempting to invoke an unbound method of a class in this way is " "sometimes referred to as 'metaclass confusion', and is avoided by bypassing " @@ -4568,7 +4677,7 @@ msgstr "" "parfois appelé « confusion de métaclasse » et se contourne en shuntant " "l'instance lors de la recherche des méthodes spéciales ::" -#: reference/datamodel.rst:2672 +#: reference/datamodel.rst:2798 msgid "" "In addition to bypassing any instance attributes in the interest of " "correctness, implicit special method lookup generally also bypasses the :" @@ -4578,7 +4687,7 @@ msgstr "" "correctement, la recherche des méthodes spéciales implicites shunte aussi la " "méthode :meth:`__getattribute__` même dans la métaclasse de l'objet ::" -#: reference/datamodel.rst:2698 +#: reference/datamodel.rst:2824 msgid "" "Bypassing the :meth:`__getattribute__` machinery in this fashion provides " "significant scope for speed optimisations within the interpreter, at the " @@ -4592,15 +4701,15 @@ msgstr "" "être définie sur l'objet classe lui-même afin d'être invoquée de manière " "cohérente par l'interpréteur)." -#: reference/datamodel.rst:2709 +#: reference/datamodel.rst:2835 msgid "Coroutines" msgstr "Coroutines" -#: reference/datamodel.rst:2713 +#: reference/datamodel.rst:2839 msgid "Awaitable Objects" msgstr "Objets *attendables* (*awaitable*)" -#: reference/datamodel.rst:2715 +#: reference/datamodel.rst:2841 msgid "" "An :term:`awaitable` object generally implements an :meth:`__await__` " "method. :term:`Coroutine objects ` returned from :keyword:`async " @@ -4610,7 +4719,7 @@ msgstr "" "`__await__`. Les objets :term:`coroutine` renvoyés par les fonctions :" "keyword:`async def` sont des *attendables* (*awaitable*)." -#: reference/datamodel.rst:2721 +#: reference/datamodel.rst:2847 msgid "" "The :term:`generator iterator` objects returned from generators decorated " "with :func:`types.coroutine` or :func:`asyncio.coroutine` are also " @@ -4621,7 +4730,7 @@ msgstr "" "des *attendables* (*awaitable*), mais ils n'implémentent pas :meth:" "`__await__`." -#: reference/datamodel.rst:2727 +#: reference/datamodel.rst:2853 msgid "" "Must return an :term:`iterator`. Should be used to implement :term:" "`awaitable` objects. For instance, :class:`asyncio.Future` implements this " @@ -4631,17 +4740,17 @@ msgstr "" "objets :term:`awaitable`. Par exemple, :class:`asyncio.Future` implémente " "cette méthode pour être compatible avec les expressions :keyword:`await`." -#: reference/datamodel.rst:2733 +#: reference/datamodel.rst:2859 msgid ":pep:`492` for additional information about awaitable objects." msgstr "" ":pep:`492` pour les informations relatives aux objets *attendables* " "(*awaitable*)." -#: reference/datamodel.rst:2739 +#: reference/datamodel.rst:2865 msgid "Coroutine Objects" msgstr "Objets coroutines" -#: reference/datamodel.rst:2741 +#: reference/datamodel.rst:2867 msgid "" ":term:`Coroutine objects ` are :term:`awaitable` objects. A " "coroutine's execution can be controlled by calling :meth:`__await__` and " @@ -4659,7 +4768,7 @@ msgstr "" "exception, elle est propagée par l'itérateur. Les coroutines ne doivent pas " "lever directement des exceptions :exc:`StopIteration` non gérées." -#: reference/datamodel.rst:2749 +#: reference/datamodel.rst:2875 msgid "" "Coroutines also have the methods listed below, which are analogous to those " "of generators (see :ref:`generator-methods`). However, unlike generators, " @@ -4670,13 +4779,13 @@ msgstr "" "contraire des générateurs, vous ne pouvez pas itérer directement sur des " "coroutines." -#: reference/datamodel.rst:2753 +#: reference/datamodel.rst:2879 msgid "It is a :exc:`RuntimeError` to await on a coroutine more than once." msgstr "" "Utiliser *await* plus d'une fois sur une coroutine lève une :exc:" "`RuntimeError`." -#: reference/datamodel.rst:2759 +#: reference/datamodel.rst:2885 msgid "" "Starts or resumes execution of the coroutine. If *value* is ``None``, this " "is equivalent to advancing the iterator returned by :meth:`__await__`. If " @@ -4693,7 +4802,7 @@ msgstr "" "est le même que lorsque vous itérez sur la valeur de retour de :meth:" "`__await__`, décrite ci-dessus." -#: reference/datamodel.rst:2769 +#: reference/datamodel.rst:2895 msgid "" "Raises the specified exception in the coroutine. This method delegates to " "the :meth:`~generator.throw` method of the iterator that caused the " @@ -4711,7 +4820,7 @@ msgstr "" "retour de :meth:`__await__`, décrite ci-dessus. Si l'exception n'est pas " "gérée par la coroutine, elle est propagée à l'appelant." -#: reference/datamodel.rst:2780 +#: reference/datamodel.rst:2906 msgid "" "Causes the coroutine to clean itself up and exit. If the coroutine is " "suspended, this method first delegates to the :meth:`~generator.close` " @@ -4728,7 +4837,7 @@ msgstr "" "la coroutine est marquée comme ayant terminé son exécution, même si elle n'a " "jamais démarré." -#: reference/datamodel.rst:2788 +#: reference/datamodel.rst:2914 msgid "" "Coroutine objects are automatically closed using the above process when they " "are about to be destroyed." @@ -4736,11 +4845,11 @@ msgstr "" "Les objets coroutines sont automatiquement fermés en utilisant le processus " "décrit au-dessus au moment où ils sont détruits." -#: reference/datamodel.rst:2794 +#: reference/datamodel.rst:2920 msgid "Asynchronous Iterators" msgstr "Itérateurs asynchrones" -#: reference/datamodel.rst:2796 +#: reference/datamodel.rst:2922 msgid "" "An *asynchronous iterator* can call asynchronous code in its ``__anext__`` " "method." @@ -4748,18 +4857,18 @@ msgstr "" "Un *itérateur asynchrone* peut appeler du code asynchrone dans sa méthode " "``__anext__``." -#: reference/datamodel.rst:2799 +#: reference/datamodel.rst:2925 msgid "" "Asynchronous iterators can be used in an :keyword:`async for` statement." msgstr "" "Les itérateurs asynchrones peuvent être utilisés dans des instructions :" "keyword:`async for`." -#: reference/datamodel.rst:2803 +#: reference/datamodel.rst:2929 msgid "Must return an *asynchronous iterator* object." msgstr "Doit renvoyer un objet *itérateur asynchrone*." -#: reference/datamodel.rst:2807 +#: reference/datamodel.rst:2933 msgid "" "Must return an *awaitable* resulting in a next value of the iterator. " "Should raise a :exc:`StopAsyncIteration` error when the iteration is over." @@ -4768,11 +4877,11 @@ msgstr "" "suivante de l'itérateur. Doit lever une :exc:`StopAsyncIteration` quand " "l'itération est terminée." -#: reference/datamodel.rst:2810 +#: reference/datamodel.rst:2936 msgid "An example of an asynchronous iterable object::" msgstr "Un exemple d'objet itérateur asynchrone ::" -#: reference/datamodel.rst:2827 +#: reference/datamodel.rst:2953 msgid "" "Prior to Python 3.7, ``__aiter__`` could return an *awaitable* that would " "resolve to an :term:`asynchronous iterator `." @@ -4781,7 +4890,7 @@ msgstr "" "(*awaitable*) qui se résolvait potentiellement en un :term:`itérateur " "asynchrone `." -#: reference/datamodel.rst:2832 +#: reference/datamodel.rst:2958 msgid "" "Starting with Python 3.7, ``__aiter__`` must return an asynchronous iterator " "object. Returning anything else will result in a :exc:`TypeError` error." @@ -4789,11 +4898,11 @@ msgstr "" "À partir de Python 3.7, ``__aiter__`` doit renvoyer un objet itérateur " "asynchrone. Renvoyer autre chose entraine une erreur :exc:`TypeError`." -#: reference/datamodel.rst:2840 +#: reference/datamodel.rst:2966 msgid "Asynchronous Context Managers" msgstr "Gestionnaires de contexte asynchrones" -#: reference/datamodel.rst:2842 +#: reference/datamodel.rst:2968 msgid "" "An *asynchronous context manager* is a *context manager* that is able to " "suspend execution in its ``__aenter__`` and ``__aexit__`` methods." @@ -4802,7 +4911,7 @@ msgstr "" "qui est capable de suspendre son exécution dans ses méthodes ``__aenter__`` " "et ``__aexit__``." -#: reference/datamodel.rst:2845 +#: reference/datamodel.rst:2971 msgid "" "Asynchronous context managers can be used in an :keyword:`async with` " "statement." @@ -4810,7 +4919,7 @@ msgstr "" "Les gestionnaires de contexte asynchrones peuvent être utilisés dans des " "instructions :keyword:`async with`." -#: reference/datamodel.rst:2849 +#: reference/datamodel.rst:2975 msgid "" "Semantically similar to :meth:`__enter__`, the only difference being that it " "must return an *awaitable*." @@ -4818,7 +4927,7 @@ msgstr "" "Sémantiquement équivalente à :meth:`__enter__`, à la seule différence près " "qu'elle doit renvoyer un *attendable* (*awaitable*)." -#: reference/datamodel.rst:2854 +#: reference/datamodel.rst:2980 msgid "" "Semantically similar to :meth:`__exit__`, the only difference being that it " "must return an *awaitable*." @@ -4826,15 +4935,15 @@ msgstr "" "Sémantiquement équivalente à :meth:`__exit__`, à la seule différence près " "qu'elle doit renvoyer un *attendable* (*awaitable*)." -#: reference/datamodel.rst:2857 +#: reference/datamodel.rst:2983 msgid "An example of an asynchronous context manager class::" msgstr "Un exemple de classe de gestionnaire de contexte asynchrone ::" -#: reference/datamodel.rst:2870 +#: reference/datamodel.rst:2996 msgid "Footnotes" msgstr "Notes de bas de page" -#: reference/datamodel.rst:2871 +#: reference/datamodel.rst:2997 msgid "" "It *is* possible in some cases to change an object's type, under certain " "controlled conditions. It generally isn't a good idea though, since it can " @@ -4845,7 +4954,7 @@ msgstr "" "car cela peut conduire à un comportement très étrange si ce n'est pas géré " "correctement." -#: reference/datamodel.rst:2875 +#: reference/datamodel.rst:3001 msgid "" "The :meth:`__hash__`, :meth:`__iter__`, :meth:`__reversed__`, and :meth:" "`__contains__` methods have special handling for this; others will still " @@ -4857,7 +4966,7 @@ msgstr "" "lèvent toujours :exc:`TypeError`, mais le font en considérant que ``None`` " "n'est pas un appelable." -#: reference/datamodel.rst:2880 +#: reference/datamodel.rst:3006 msgid "" "\"Does not support\" here means that the class has no such method, or the " "method returns ``NotImplemented``. Do not set the method to ``None`` if you " @@ -4869,7 +4978,7 @@ msgstr "" "``None`` à la méthode si vous voulez un repli vers la méthode symétrique de " "l'opérande de droite — cela aurait pour effet de *bloquer* un tel repli." -#: reference/datamodel.rst:2886 +#: reference/datamodel.rst:3012 msgid "" "For operands of the same type, it is assumed that if the non-reflected " "method -- such as :meth:`__add__` -- fails then the overall operation is not " @@ -4879,6 +4988,35 @@ msgstr "" "(telle que :meth:`__add__`) échoue, alors l'opération en tant que telle " "n'est pas autorisée et donc la méthode symétrique n'est pas appelée." +#~ msgid "" +#~ "One can implement the generic class syntax as specified by :pep:`484` " +#~ "(for example ``List[int]``) by defining a special method:" +#~ msgstr "" +#~ "Vous pouvez implémenter la syntaxe générique des classes comme spécifié " +#~ "par la :pep:`484` (par exemple ``List[int]``) en définissant une méthode " +#~ "spéciale :" + +#~ msgid "" +#~ "This method is looked up on the class object itself, and when defined in " +#~ "the class body, this method is implicitly a class method. Note, this " +#~ "mechanism is primarily reserved for use with static type hints, other " +#~ "usage is discouraged." +#~ msgstr "" +#~ "Python recherche cette méthode dans l'objet de classe lui-même et, " +#~ "lorsqu'elle est définie dans le corps de la classe, cette méthode est " +#~ "implicitement une méthode de classe. Notez que ce mécanisme est " +#~ "principalement réservé à une utilisation avec des indications de type " +#~ "statiques, d'autres utilisations sont déconseillées." + +#~ msgid "" +#~ "Iterator objects also need to implement this method; they are required to " +#~ "return themselves. For more information on iterator objects, see :ref:" +#~ "`typeiter`." +#~ msgstr "" +#~ "Les objets itérateurs doivent aussi implémenter cette méthode ; ils " +#~ "doivent alors se renvoyer eux-mêmes. Pour plus d'information sur les " +#~ "objets itérateurs, lisez :ref:`typeiter`." + #~ msgid "" #~ "If :meth:`__int__` is not defined then the built-in function :func:`int` " #~ "falls back to :meth:`__trunc__`." diff --git a/reference/executionmodel.po b/reference/executionmodel.po index 30a85538..0cf26c9c 100644 --- a/reference/executionmodel.po +++ b/reference/executionmodel.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-10-21 15:04+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-04-09 23:45+0200\n" "Last-Translator: Jules Lasne \n" "Language-Team: FRENCH \n" @@ -78,29 +78,58 @@ msgstr "" "opérations de liaisons de noms (*name binding* en anglais)." #: reference/executionmodel.rst:59 -msgid "" -"The following constructs bind names: formal parameters to functions, :" -"keyword:`import` statements, class and function definitions (these bind the " -"class or function name in the defining block), and targets that are " -"identifiers if occurring in an assignment, :keyword:`for` loop header, or " -"after :keyword:`!as` in a :keyword:`with` statement or :keyword:`except` " -"clause. The :keyword:`!import` statement of the form ``from ... import *`` " -"binds all names defined in the imported module, except those beginning with " -"an underscore. This form may only be used at the module level." +msgid "The following constructs bind names:" +msgstr "" + +#: reference/executionmodel.rst:61 +msgid "formal parameters to functions," +msgstr "" + +#: reference/executionmodel.rst:62 +msgid "class definitions," +msgstr "" + +#: reference/executionmodel.rst:63 +msgid "function definitions," +msgstr "" + +#: reference/executionmodel.rst:64 +msgid "assignment expressions," +msgstr "" + +#: reference/executionmodel.rst:65 +msgid "" +":ref:`targets ` that are identifiers if occurring in an " +"assignment:" +msgstr "" + +#: reference/executionmodel.rst:68 +msgid ":keyword:`for` loop header," msgstr "" -"Les constructions suivantes conduisent à des opérations de liaison à des " -"noms : les paramètres formels d'une fonction, les instructions :keyword:" -"`import`, les définitions de fonctions et de classes (le nom de la classe ou " -"de la fonction est lié au bloc qui la définit) et les cibles qui sont des " -"identifiants dans les assignations, les entêtes de boucles :keyword:`for` ou " -"après :keyword:`!as` dans une instruction :keyword:`with` ou une clause :" -"keyword:`except`. L'instruction :keyword:`!import` sous la forme ``from ... " -"import *`` lie tous les noms définis dans le module importé, sauf ceux qui " -"commencent par un tiret bas (`'_'`). Cette forme ne doit être utilisée qu'au " -"niveau du module." #: reference/executionmodel.rst:69 msgid "" +"after :keyword:`!as` in a :keyword:`with` statement, :keyword:`except` " +"clause or in the as-pattern in structural pattern matching," +msgstr "" + +#: reference/executionmodel.rst:71 +msgid "in a capture pattern in structural pattern matching" +msgstr "" + +#: reference/executionmodel.rst:73 +msgid ":keyword:`import` statements." +msgstr "" + +#: reference/executionmodel.rst:75 +msgid "" +"The :keyword:`!import` statement of the form ``from ... import *`` binds all " +"names defined in the imported module, except those beginning with an " +"underscore. This form may only be used at the module level." +msgstr "" + +#: reference/executionmodel.rst:79 +msgid "" "A target occurring in a :keyword:`del` statement is also considered bound " "for this purpose (though the actual semantics are to unbind the name)." msgstr "" @@ -108,7 +137,7 @@ msgstr "" "considérée comme une liaison à un nom dans ce cadre (bien que la sémantique " "véritable soit de délier le nom)." -#: reference/executionmodel.rst:72 +#: reference/executionmodel.rst:82 msgid "" "Each assignment or import statement occurs within a block defined by a class " "or function definition or at the module level (the top-level code block)." @@ -117,7 +146,7 @@ msgstr "" "une définition de classe ou de fonction ou au niveau du module (le bloc de " "code de plus haut niveau)." -#: reference/executionmodel.rst:77 +#: reference/executionmodel.rst:87 msgid "" "If a name is bound in a block, it is a local variable of that block, unless " "declared as :keyword:`nonlocal` or :keyword:`global`. If a name is bound at " @@ -132,7 +161,7 @@ msgstr "" "est utilisée dans un bloc de code alors qu'elle n'y est pas définie, c'est " "une :dfn:`variable libre`." -#: reference/executionmodel.rst:83 +#: reference/executionmodel.rst:93 msgid "" "Each occurrence of a name in the program text refers to the :dfn:`binding` " "of that name established by the following name resolution rules." @@ -140,11 +169,11 @@ msgstr "" "Chaque occurrence d'un nom dans un programme fait référence à la :dfn:" "`liaison` de ce nom établie par les règles de résolution des noms suivantes." -#: reference/executionmodel.rst:89 +#: reference/executionmodel.rst:99 msgid "Resolution of names" msgstr "Résolution des noms" -#: reference/executionmodel.rst:93 +#: reference/executionmodel.rst:103 msgid "" "A :dfn:`scope` defines the visibility of a name within a block. If a local " "variable is defined in a block, its scope includes that block. If the " @@ -158,7 +187,7 @@ msgstr "" "les blocs contenus dans celui qui comprend la définition, à moins qu'un bloc " "intérieur ne définisse une autre liaison pour ce nom." -#: reference/executionmodel.rst:101 +#: reference/executionmodel.rst:111 msgid "" "When a name is used in a code block, it is resolved using the nearest " "enclosing scope. The set of all such scopes visible to a code block is " @@ -168,7 +197,7 @@ msgstr "" "portée la plus petite. L'ensemble de toutes les portées visibles dans un " "bloc de code s'appelle :dfn:`l'environnement` du bloc." -#: reference/executionmodel.rst:109 +#: reference/executionmodel.rst:119 msgid "" "When a name is not found at all, a :exc:`NameError` exception is raised. If " "the current scope is a function scope, and the name refers to a local " @@ -182,7 +211,7 @@ msgstr "" "nom est utilisé, une exception :exc:`UnboundLocalError` est levée. :exc:" "`UnboundLocalError` est une sous-classe de :exc:`NameError`." -#: reference/executionmodel.rst:115 +#: reference/executionmodel.rst:125 msgid "" "If a name binding operation occurs anywhere within a code block, all uses of " "the name within the block are treated as references to the current block. " @@ -201,7 +230,7 @@ msgstr "" "de code peuvent être déterminées en parcourant tout le texte du bloc à la " "recherche des opérations de liaisons." -#: reference/executionmodel.rst:122 +#: reference/executionmodel.rst:132 #, fuzzy msgid "" "If the :keyword:`global` statement occurs within a block, all uses of the " @@ -224,7 +253,7 @@ msgstr "" "l'espace de nommage natif. L'instruction :keyword:`!global` doit précéder " "toute utilisation du nom considéré." -#: reference/executionmodel.rst:131 +#: reference/executionmodel.rst:141 msgid "" "The :keyword:`global` statement has the same scope as a name binding " "operation in the same block. If the nearest enclosing scope for a free " @@ -235,7 +264,7 @@ msgstr "" "du même bloc. Si la portée englobante la plus petite pour une variable libre " "contient une instruction *global*, la variable libre est considérée globale." -#: reference/executionmodel.rst:137 +#: reference/executionmodel.rst:147 msgid "" "The :keyword:`nonlocal` statement causes corresponding names to refer to " "previously bound variables in the nearest enclosing function scope. :exc:" @@ -248,7 +277,7 @@ msgstr "" "compilation si le nom donné n'existe dans aucune portée de fonction " "englobante." -#: reference/executionmodel.rst:144 +#: reference/executionmodel.rst:154 msgid "" "The namespace for a module is automatically created the first time a module " "is imported. The main module for a script is always called :mod:`__main__`." @@ -257,7 +286,7 @@ msgstr "" "que le module est importé. Le module principal d'un script s'appelle " "toujours :mod:`__main__`." -#: reference/executionmodel.rst:147 +#: reference/executionmodel.rst:157 msgid "" "Class definition blocks and arguments to :func:`exec` and :func:`eval` are " "special in the context of name resolution. A class definition is an " @@ -283,11 +312,11 @@ msgstr "" "puisque celles-ci sont implémentées en utilisant une portée de fonction. " "Ainsi, les instructions suivantes échouent ::" -#: reference/executionmodel.rst:165 +#: reference/executionmodel.rst:175 msgid "Builtins and restricted execution" msgstr "Noms natifs et restrictions d'exécution" -#: reference/executionmodel.rst:171 +#: reference/executionmodel.rst:181 msgid "" "Users should not touch ``__builtins__``; it is strictly an implementation " "detail. Users wanting to override values in the builtins namespace should :" @@ -300,7 +329,7 @@ msgstr "" "keyword:`importer ` le module :mod:`builtins` et modifier ses " "attributs judicieusement." -#: reference/executionmodel.rst:176 +#: reference/executionmodel.rst:186 msgid "" "The builtins namespace associated with the execution of a code block is " "actually found by looking up the name ``__builtins__`` in its global " @@ -319,11 +348,11 @@ msgstr "" "``__builtins__`` est un pseudonyme du dictionnaire du module :mod:`builtins` " "lui-même." -#: reference/executionmodel.rst:188 +#: reference/executionmodel.rst:198 msgid "Interaction with dynamic features" msgstr "Interaction avec les fonctionnalités dynamiques" -#: reference/executionmodel.rst:190 +#: reference/executionmodel.rst:200 msgid "" "Name resolution of free variables occurs at runtime, not at compile time. " "This means that the following code will print 42::" @@ -331,7 +360,7 @@ msgstr "" "La résolution des noms de variables libres intervient à l'exécution, pas à " "la compilation. Cela signifie que le code suivant affiche 42 ::" -#: reference/executionmodel.rst:201 +#: reference/executionmodel.rst:211 msgid "" "The :func:`eval` and :func:`exec` functions do not have access to the full " "environment for resolving names. Names may be resolved in the local and " @@ -350,11 +379,11 @@ msgstr "" "nommage globaux et locaux. Si seulement un espace de nommage est spécifié, " "il est utilisé pour les deux." -#: reference/executionmodel.rst:212 +#: reference/executionmodel.rst:222 msgid "Exceptions" msgstr "Exceptions" -#: reference/executionmodel.rst:223 +#: reference/executionmodel.rst:233 msgid "" "Exceptions are a means of breaking out of the normal flow of control of a " "code block in order to handle errors or other exceptional conditions. An " @@ -369,7 +398,7 @@ msgstr "" "a, directement ou indirectement, invoqué le bloc de code où l'erreur s'est " "produite." -#: reference/executionmodel.rst:229 +#: reference/executionmodel.rst:239 msgid "" "The Python interpreter raises an exception when it detects a run-time error " "(such as division by zero). A Python program can also explicitly raise an " @@ -387,7 +416,7 @@ msgstr "" "peut être utilisée pour spécifier un code de nettoyage qui ne gère pas " "l'exception mais qui est exécuté quoi qu'il arrive (exception ou pas)." -#: reference/executionmodel.rst:239 +#: reference/executionmodel.rst:249 msgid "" "Python uses the \"termination\" model of error handling: an exception " "handler can find out what happened and continue execution at an outer level, " @@ -400,7 +429,7 @@ msgstr "" "l'erreur et ré-essayer l'opération qui a échoué (sauf à entrer à nouveau " "dans le code en question par le haut)." -#: reference/executionmodel.rst:246 +#: reference/executionmodel.rst:256 msgid "" "When an exception is not handled at all, the interpreter terminates " "execution of the program, or returns to its interactive main loop. In " @@ -412,7 +441,7 @@ msgstr "" "il affiche une trace de la pile d'appels, sauf si l'exception est :exc:" "`SystemExit`." -#: reference/executionmodel.rst:250 +#: reference/executionmodel.rst:260 msgid "" "Exceptions are identified by class instances. The :keyword:`except` clause " "is selected depending on the class of the instance: it must reference the " @@ -426,7 +455,7 @@ msgstr "" "L'instance peut être transmise au gestionnaire et peut apporter des " "informations complémentaires sur les conditions de l'exception." -#: reference/executionmodel.rst:257 +#: reference/executionmodel.rst:267 msgid "" "Exception messages are not part of the Python API. Their contents may " "change from one version of Python to the next without warning and should not " @@ -438,7 +467,7 @@ msgstr "" "code ne doit pas reposer sur ceux-ci s'il doit fonctionner sur plusieurs " "versions de l'interpréteur." -#: reference/executionmodel.rst:261 +#: reference/executionmodel.rst:271 msgid "" "See also the description of the :keyword:`try` statement in section :ref:" "`try` and :keyword:`raise` statement in section :ref:`raise`." @@ -447,14 +476,36 @@ msgstr "" "section :ref:`try` et de l'instruction :keyword:`raise` dans la section :ref:" "`raise`." -#: reference/executionmodel.rst:266 +#: reference/executionmodel.rst:276 msgid "Footnotes" msgstr "Notes" -#: reference/executionmodel.rst:267 +#: reference/executionmodel.rst:277 msgid "" "This limitation occurs because the code that is executed by these operations " "is not available at the time the module is compiled." msgstr "" "En effet, le code qui est exécuté par ces opérations n'est pas connu au " "moment où le module est compilé." + +#~ msgid "" +#~ "The following constructs bind names: formal parameters to functions, :" +#~ "keyword:`import` statements, class and function definitions (these bind " +#~ "the class or function name in the defining block), and targets that are " +#~ "identifiers if occurring in an assignment, :keyword:`for` loop header, or " +#~ "after :keyword:`!as` in a :keyword:`with` statement or :keyword:`except` " +#~ "clause. The :keyword:`!import` statement of the form ``from ... import " +#~ "*`` binds all names defined in the imported module, except those " +#~ "beginning with an underscore. This form may only be used at the module " +#~ "level." +#~ msgstr "" +#~ "Les constructions suivantes conduisent à des opérations de liaison à des " +#~ "noms : les paramètres formels d'une fonction, les instructions :keyword:" +#~ "`import`, les définitions de fonctions et de classes (le nom de la classe " +#~ "ou de la fonction est lié au bloc qui la définit) et les cibles qui sont " +#~ "des identifiants dans les assignations, les entêtes de boucles :keyword:" +#~ "`for` ou après :keyword:`!as` dans une instruction :keyword:`with` ou une " +#~ "clause :keyword:`except`. L'instruction :keyword:`!import` sous la forme " +#~ "``from ... import *`` lie tous les noms définis dans le module importé, " +#~ "sauf ceux qui commencent par un tiret bas (`'_'`). Cette forme ne doit " +#~ "être utilisée qu'au niveau du module." diff --git a/reference/expressions.po b/reference/expressions.po index fd1c3809..f26c2333 100644 --- a/reference/expressions.po +++ b/reference/expressions.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-10-17 16:54+0200\n" "Last-Translator: Jean Abou Samra \n" "Language-Team: FRENCH \n" @@ -666,23 +666,24 @@ msgstr "" "`asynchronous-generator-functions`." #: reference/expressions.rst:447 +#, fuzzy msgid "" "When a generator function is called, it returns an iterator known as a " "generator. That generator then controls the execution of the generator " -"function. The execution starts when one of the generator's methods is " -"called. At that time, the execution proceeds to the first yield expression, " -"where it is suspended again, returning the value of :token:`expression_list` " -"to the generator's caller. By suspended, we mean that all local state is " -"retained, including the current bindings of local variables, the instruction " -"pointer, the internal evaluation stack, and the state of any exception " -"handling. When the execution is resumed by calling one of the generator's " -"methods, the function can proceed exactly as if the yield expression were " -"just another external call. The value of the yield expression after " -"resuming depends on the method which resumed the execution. If :meth:" -"`~generator.__next__` is used (typically via either a :keyword:`for` or the :" -"func:`next` builtin) then the result is :const:`None`. Otherwise, if :meth:" -"`~generator.send` is used, then the result will be the value passed in to " -"that method." +"function. The execution starts when one of the generator's methods is " +"called. At that time, the execution proceeds to the first yield expression, " +"where it is suspended again, returning the value of :token:`~python-grammar:" +"expression_list` to the generator's caller. By suspended, we mean that all " +"local state is retained, including the current bindings of local variables, " +"the instruction pointer, the internal evaluation stack, and the state of any " +"exception handling. When the execution is resumed by calling one of the " +"generator's methods, the function can proceed exactly as if the yield " +"expression were just another external call. The value of the yield " +"expression after resuming depends on the method which resumed the " +"execution. If :meth:`~generator.__next__` is used (typically via either a :" +"keyword:`for` or the :func:`next` builtin) then the result is :const:" +"`None`. Otherwise, if :meth:`~generator.send` is used, then the result will " +"be the value passed in to that method." msgstr "" "Lorsqu'une fonction génératrice est appelée, elle renvoie un itérateur que " "l'on appelle générateur. Ce générateur contrôle l'exécution de la fonction " @@ -702,7 +703,7 @@ msgstr "" "`~generator.send` qui a été utilisée, alors le résultat est la valeur " "transmise à cette méthode." -#: reference/expressions.rst:466 +#: reference/expressions.rst:465 msgid "" "All of this makes generator functions quite similar to coroutines; they " "yield multiple times, they have more than one entry point and their " @@ -717,7 +718,7 @@ msgstr "" "contrôler où l'exécution doit se poursuivre après une instruction " "``yield`` ; ce contrôle est toujours du ressort de l'appelant au générateur." -#: reference/expressions.rst:472 +#: reference/expressions.rst:471 msgid "" "Yield expressions are allowed anywhere in a :keyword:`try` construct. If " "the generator is not resumed before it is finalized (by reaching a zero " @@ -732,7 +733,7 @@ msgstr "" "close` du générateur-itérateur est appelée, ce qui permet l'exécution de " "toutes les clauses :keyword:`finally` en attente." -#: reference/expressions.rst:481 +#: reference/expressions.rst:480 msgid "" "When ``yield from `` is used, the supplied expression must be an " "iterable. The values produced by iterating that iterable are passed directly " @@ -752,7 +753,7 @@ msgstr "" "`AttributeError` ou une :exc:`TypeError`, alors que :meth:`~generator.throw` " "ne fait que propager l'exception immédiatement." -#: reference/expressions.rst:490 +#: reference/expressions.rst:489 msgid "" "When the underlying iterator is complete, the :attr:`~StopIteration.value` " "attribute of the raised :exc:`StopIteration` instance becomes the value of " @@ -766,13 +767,13 @@ msgstr "" "quand vous levez :exc:`StopIteration` ou automatiquement que le sous-" "itérateur est un générateur (en renvoyant une valeur par le sous-générateur)." -#: reference/expressions.rst:496 +#: reference/expressions.rst:495 msgid "Added ``yield from `` to delegate control flow to a subiterator." msgstr "" "``yield from `` a été ajoutée pour déléguer le contrôle du flot " "d'exécution à un sous-itérateur." -#: reference/expressions.rst:499 +#: reference/expressions.rst:498 msgid "" "The parentheses may be omitted when the yield expression is the sole " "expression on the right hand side of an assignment statement." @@ -780,11 +781,11 @@ msgstr "" "Les parenthèses peuvent être omises quand l'expression ``yield`` est la " "seule expression à droite de l'instruction de l'instruction d'assignation." -#: reference/expressions.rst:505 +#: reference/expressions.rst:504 msgid ":pep:`255` - Simple Generators" msgstr ":pep:`255` : générateurs simples" -#: reference/expressions.rst:505 +#: reference/expressions.rst:504 msgid "" "The proposal for adding generators and the :keyword:`yield` statement to " "Python." @@ -792,11 +793,11 @@ msgstr "" "La proposition d'ajouter à Python des générateurs et l'instruction :keyword:" "`yield`." -#: reference/expressions.rst:509 +#: reference/expressions.rst:508 msgid ":pep:`342` - Coroutines via Enhanced Generators" msgstr ":pep:`342` -- Coroutines *via* des générateurs améliorés" -#: reference/expressions.rst:508 +#: reference/expressions.rst:507 msgid "" "The proposal to enhance the API and syntax of generators, making them usable " "as simple coroutines." @@ -804,23 +805,24 @@ msgstr "" "Proposition d'améliorer l'API et la syntaxe des générateurs, de manière à " "pouvoir les utiliser comme de simples coroutines." -#: reference/expressions.rst:513 +#: reference/expressions.rst:512 msgid ":pep:`380` - Syntax for Delegating to a Subgenerator" msgstr ":pep:`380` -- Syntaxe pour déléguer à un sous-générateur" -#: reference/expressions.rst:512 +#: reference/expressions.rst:511 +#, fuzzy msgid "" -"The proposal to introduce the :token:`yield_from` syntax, making delegation " -"to subgenerators easy." +"The proposal to introduce the :token:`~python-grammar:yield_from` syntax, " +"making delegation to subgenerators easy." msgstr "" "Proposition d'introduire la syntaxe :token:`yield_from`, de manière à " "déléguer facilement l'exécution à un sous-générateur." -#: reference/expressions.rst:516 +#: reference/expressions.rst:515 msgid ":pep:`525` - Asynchronous Generators" msgstr ":pep:`525` : Générateurs asynchrones" -#: reference/expressions.rst:516 +#: reference/expressions.rst:515 msgid "" "The proposal that expanded on :pep:`492` by adding generator capabilities to " "coroutine functions." @@ -828,11 +830,11 @@ msgstr "" "La proposition qui a amélioré la :pep:`492` en ajoutant des capacités de " "générateur pour les coroutines." -#: reference/expressions.rst:523 +#: reference/expressions.rst:522 msgid "Generator-iterator methods" msgstr "Méthodes des générateurs-itérateurs" -#: reference/expressions.rst:525 +#: reference/expressions.rst:524 msgid "" "This subsection describes the methods of a generator iterator. They can be " "used to control the execution of a generator function." @@ -840,7 +842,7 @@ msgstr "" "Cette sous-section décrit les méthodes des générateurs-itérateurs. Elles " "peuvent être utilisées pour contrôler l'exécution des fonctions générateurs." -#: reference/expressions.rst:528 +#: reference/expressions.rst:527 msgid "" "Note that calling any of the generator methods below when the generator is " "already executing raises a :exc:`ValueError` exception." @@ -849,16 +851,17 @@ msgstr "" "générateur est déjà en cours d'exécution lève une exception :exc:" "`ValueError`." -#: reference/expressions.rst:536 +#: reference/expressions.rst:535 +#, fuzzy msgid "" "Starts the execution of a generator function or resumes it at the last " "executed yield expression. When a generator function is resumed with a :" "meth:`~generator.__next__` method, the current yield expression always " "evaluates to :const:`None`. The execution then continues to the next yield " "expression, where the generator is suspended again, and the value of the :" -"token:`expression_list` is returned to :meth:`__next__`'s caller. If the " -"generator exits without yielding another value, a :exc:`StopIteration` " -"exception is raised." +"token:`~python-grammar:expression_list` is returned to :meth:`__next__`'s " +"caller. If the generator exits without yielding another value, a :exc:" +"`StopIteration` exception is raised." msgstr "" "Démarre l'exécution d'une fonction générateur ou la reprend à la dernière " "expression ``yield`` exécutée. Quand une fonction générateur est reprise par " @@ -869,7 +872,7 @@ msgstr "" "`__next__` de l'appelant. Si le générateur termine sans donner une autre " "valeur, une exception :exc:`StopIteration` est levée." -#: reference/expressions.rst:545 +#: reference/expressions.rst:544 msgid "" "This method is normally called implicitly, e.g. by a :keyword:`for` loop, or " "by the built-in :func:`next` function." @@ -877,7 +880,7 @@ msgstr "" "Cette méthode est normalement appelée implicitement, par exemple par une " "boucle :keyword:`for` ou par la fonction native :func:`next`." -#: reference/expressions.rst:551 +#: reference/expressions.rst:550 msgid "" "Resumes the execution and \"sends\" a value into the generator function. " "The *value* argument becomes the result of the current yield expression. " @@ -895,7 +898,7 @@ msgstr "" "le générateur, elle doit avoir :const:`None` comme argument, car il n'y a " "aucune expression ``yield`` qui peut recevoir la valeur." -#: reference/expressions.rst:562 +#: reference/expressions.rst:561 msgid "" "Raises an exception of type ``type`` at the point where the generator was " "paused, and returns the next value yielded by the generator function. If " @@ -911,7 +914,7 @@ msgstr "" "l'exception passée ou lève une autre exception, alors cette exception est " "propagée vers l'appelant." -#: reference/expressions.rst:573 +#: reference/expressions.rst:572 msgid "" "Raises a :exc:`GeneratorExit` at the point where the generator function was " "paused. If the generator function then exits gracefully, is already closed, " @@ -929,11 +932,11 @@ msgstr "" "est propagée à l'appelant. La méthode :meth:`close` ne fait rien si le " "générateur a déjà terminé en raison d'une exception ou d'une fin normale." -#: reference/expressions.rst:584 +#: reference/expressions.rst:583 msgid "Examples" msgstr "Exemples" -#: reference/expressions.rst:586 +#: reference/expressions.rst:585 msgid "" "Here is a simple example that demonstrates the behavior of generators and " "generator functions::" @@ -941,7 +944,7 @@ msgstr "" "Voici un exemple simple qui montre le comportement des générateurs et des " "fonctions génératrices ::" -#: reference/expressions.rst:613 +#: reference/expressions.rst:612 msgid "" "For examples using ``yield from``, see :ref:`pep-380` in \"What's New in " "Python.\"" @@ -949,11 +952,11 @@ msgstr "" "Pour des exemples d'utilisation de ``yield from``, lisez la :ref:`pep-380` " "dans « Les nouveautés de Python »." -#: reference/expressions.rst:619 +#: reference/expressions.rst:618 msgid "Asynchronous generator functions" msgstr "Fonctions génératrices asynchrones" -#: reference/expressions.rst:621 +#: reference/expressions.rst:620 msgid "" "The presence of a yield expression in a function or method defined using :" "keyword:`async def` further defines the function as an :term:`asynchronous " @@ -963,7 +966,7 @@ msgstr "" "définie en utilisant :keyword:`async def` transforme cette fonction en " "fonction :term:`générateur asynchrone `." -#: reference/expressions.rst:625 +#: reference/expressions.rst:624 msgid "" "When an asynchronous generator function is called, it returns an " "asynchronous iterator known as an asynchronous generator object. That object " @@ -979,22 +982,24 @@ msgstr "" "à l'intérieur d'une fonction coroutine de la même manière qu'un objet " "générateur serait utilisé dans une instruction :keyword:`for`." -#: reference/expressions.rst:632 +#: reference/expressions.rst:631 +#, fuzzy msgid "" "Calling one of the asynchronous generator's methods returns an :term:" "`awaitable` object, and the execution starts when this object is awaited on. " "At that time, the execution proceeds to the first yield expression, where it " -"is suspended again, returning the value of :token:`expression_list` to the " -"awaiting coroutine. As with a generator, suspension means that all local " -"state is retained, including the current bindings of local variables, the " -"instruction pointer, the internal evaluation stack, and the state of any " -"exception handling. When the execution is resumed by awaiting on the next " -"object returned by the asynchronous generator's methods, the function can " -"proceed exactly as if the yield expression were just another external call. " -"The value of the yield expression after resuming depends on the method which " -"resumed the execution. If :meth:`~agen.__anext__` is used then the result " -"is :const:`None`. Otherwise, if :meth:`~agen.asend` is used, then the result " -"will be the value passed in to that method." +"is suspended again, returning the value of :token:`~python-grammar:" +"expression_list` to the awaiting coroutine. As with a generator, suspension " +"means that all local state is retained, including the current bindings of " +"local variables, the instruction pointer, the internal evaluation stack, and " +"the state of any exception handling. When the execution is resumed by " +"awaiting on the next object returned by the asynchronous generator's " +"methods, the function can proceed exactly as if the yield expression were " +"just another external call. The value of the yield expression after resuming " +"depends on the method which resumed the execution. If :meth:`~agen." +"__anext__` is used then the result is :const:`None`. Otherwise, if :meth:" +"`~agen.asend` is used, then the result will be the value passed in to that " +"method." msgstr "" "L'appel d'une méthode du générateur asynchrone renvoie un objet :term:" "`awaitable` et l'exécution commence au moment où l'on atteint une " @@ -1013,7 +1018,7 @@ msgstr "" "alors le résultat est :const:`None`. Sinon, si c'est :meth:`~agen.asend` qui " "a été utilisée, alors le résultat est la valeur transmise à cette méthode." -#: reference/expressions.rst:648 +#: reference/expressions.rst:646 msgid "" "If an asynchronous generator happens to exit early by :keyword:`break`, the " "caller task being cancelled, or other exceptions, the generator's async " @@ -1025,7 +1030,7 @@ msgid "" "generator and ultimately detach it from the event loop." msgstr "" -#: reference/expressions.rst:658 +#: reference/expressions.rst:656 msgid "" "In an asynchronous generator function, yield expressions are allowed " "anywhere in a :keyword:`try` construct. However, if an asynchronous " @@ -1050,7 +1055,7 @@ msgstr "" "générateur asynchrone et d'exécuter l'objet coroutine résultant, permettant " "ainsi à toute clause :keyword:`!finally` en attente d'être exécutée." -#: reference/expressions.rst:669 +#: reference/expressions.rst:667 #, fuzzy msgid "" "To take care of finalization upon event loop termination, an event loop " @@ -1073,7 +1078,7 @@ msgstr "" "*finalizer*, regardez l'implémentation de ``asyncio.Loop." "shutdown_asyncgens`` dans :source:`Lib/asyncio/base_events.py`." -#: reference/expressions.rst:678 +#: reference/expressions.rst:676 msgid "" "The expression ``yield from `` is a syntax error when used in an " "asynchronous generator function." @@ -1081,11 +1086,11 @@ msgstr "" "L'expression ``yield from `` produit une erreur de syntaxe quand elle " "est utilisée dans une fonction génératrice asynchrone." -#: reference/expressions.rst:685 +#: reference/expressions.rst:683 msgid "Asynchronous generator-iterator methods" msgstr "Méthodes des générateurs-itérateurs asynchrones" -#: reference/expressions.rst:687 +#: reference/expressions.rst:685 msgid "" "This subsection describes the methods of an asynchronous generator iterator, " "which are used to control the execution of a generator function." @@ -1094,18 +1099,20 @@ msgstr "" "asynchrones. Elles sont utilisées pour contrôler l’exécution des fonctions " "génératrices." -#: reference/expressions.rst:695 +#: reference/expressions.rst:693 +#, fuzzy msgid "" "Returns an awaitable which when run starts to execute the asynchronous " "generator or resumes it at the last executed yield expression. When an " "asynchronous generator function is resumed with an :meth:`~agen.__anext__` " "method, the current yield expression always evaluates to :const:`None` in " "the returned awaitable, which when run will continue to the next yield " -"expression. The value of the :token:`expression_list` of the yield " -"expression is the value of the :exc:`StopIteration` exception raised by the " -"completing coroutine. If the asynchronous generator exits without yielding " -"another value, the awaitable instead raises a :exc:`StopAsyncIteration` " -"exception, signalling that the asynchronous iteration has completed." +"expression. The value of the :token:`~python-grammar:expression_list` of the " +"yield expression is the value of the :exc:`StopIteration` exception raised " +"by the completing coroutine. If the asynchronous generator exits without " +"yielding another value, the awaitable instead raises a :exc:" +"`StopAsyncIteration` exception, signalling that the asynchronous iteration " +"has completed." msgstr "" "Renvoie un *awaitable* qui, quand il a la main, démarre l'exécution du " "générateur asynchrone ou reprend son exécution à l'endroit de la dernière " @@ -1119,14 +1126,14 @@ msgstr "" "lève une exception :exc:`StopAsyncIteration` qui signale que l'itération " "asynchrone est terminée." -#: reference/expressions.rst:707 +#: reference/expressions.rst:705 msgid "" "This method is normally called implicitly by a :keyword:`async for` loop." msgstr "" "Cette méthode est normalement appelée implicitement par une boucle :keyword:" "`async for`." -#: reference/expressions.rst:712 +#: reference/expressions.rst:710 msgid "" "Returns an awaitable which when run resumes the execution of the " "asynchronous generator. As with the :meth:`~generator.send()` method for a " @@ -1151,7 +1158,7 @@ msgstr "" "appelée pour démarrer le générateur asynchrone, l'argument doit être :const:" "`None` car il n'y a pas d'expression ``yield`` pour recevoir la valeur." -#: reference/expressions.rst:727 +#: reference/expressions.rst:725 msgid "" "Returns an awaitable that raises an exception of type ``type`` at the point " "where the asynchronous generator was paused, and returns the next value " @@ -1171,7 +1178,7 @@ msgstr "" "l'exception reçue ou lève une autre exception alors, quand le *awaitable* " "est lancé, cette exception est propagée vers l'appelant du *awaitable*." -#: reference/expressions.rst:742 +#: reference/expressions.rst:740 msgid "" "Returns an awaitable that when run will throw a :exc:`GeneratorExit` into " "the asynchronous generator function at the point where it was paused. If the " @@ -1199,11 +1206,11 @@ msgstr "" "déjà terminé (soit par une exception, soit normalement), alors tout nouvel " "appel à :meth:`aclose` renvoie un *awaitable* qui ne fait rien." -#: reference/expressions.rst:758 +#: reference/expressions.rst:756 msgid "Primaries" msgstr "Primaires" -#: reference/expressions.rst:762 +#: reference/expressions.rst:760 msgid "" "Primaries represent the most tightly bound operations of the language. Their " "syntax is:" @@ -1212,17 +1219,17 @@ msgstr "" "les opérations qui se lient au plus proche dans le langage. Leur syntaxe " "est :" -#: reference/expressions.rst:772 +#: reference/expressions.rst:770 msgid "Attribute references" msgstr "Références à des attributs" -#: reference/expressions.rst:778 +#: reference/expressions.rst:776 msgid "An attribute reference is a primary followed by a period and a name:" msgstr "" "Une référence à un attribut (*attributeref* dans la grammaire formelle ci-" "dessous) est une primaire suivie par un point et un nom :" -#: reference/expressions.rst:788 +#: reference/expressions.rst:786 msgid "" "The primary must evaluate to an object of a type that supports attribute " "references, which most objects do. This object is then asked to produce the " @@ -1241,11 +1248,11 @@ msgstr "" "l'objet. Plusieurs évaluations successives d'une référence à un même " "attribut peuvent produire différents objets." -#: reference/expressions.rst:800 +#: reference/expressions.rst:798 msgid "Subscriptions" msgstr "Sélections" -#: reference/expressions.rst:815 +#: reference/expressions.rst:813 msgid "" "Subscription of a sequence (string, tuple or list) or mapping (dictionary) " "object usually selects an item from the collection:" @@ -1254,7 +1261,7 @@ msgstr "" "objet séquence (chaîne, *n*-uplet ou liste) ou tableau associatif " "(dictionnaire) désigne un élément dans cette séquence :" -#: reference/expressions.rst:821 +#: reference/expressions.rst:819 msgid "" "The primary must evaluate to an object that supports subscription (lists or " "dictionaries for example). User-defined objects can support subscription by " @@ -1264,13 +1271,13 @@ msgstr "" "ou un dictionnaire par exemple). Les objets définis par l'utilisateur " "peuvent gérer les sélections en définissant une méthode :meth:`__getitem__`." -#: reference/expressions.rst:825 +#: reference/expressions.rst:823 msgid "" "For built-in objects, there are two types of objects that support " "subscription:" msgstr "Pour les objets natifs, deux types d'objets gèrent la sélection :" -#: reference/expressions.rst:827 +#: reference/expressions.rst:825 msgid "" "If the primary is a mapping, the expression list must evaluate to an object " "whose value is one of the keys of the mapping, and the subscription selects " @@ -1284,7 +1291,7 @@ msgstr "" "(la liste d'expressions est un *n*-uplet sauf si elle comporte exactement un " "élément)." -#: reference/expressions.rst:832 +#: reference/expressions.rst:830 msgid "" "If the primary is a sequence, the expression list must evaluate to an " "integer or a slice (as discussed in the following section)." @@ -1293,7 +1300,7 @@ msgstr "" "dans la grammaire) doit pouvoir être évaluée comme un entier ou une tranche " "(comme expliqué dans la section suivante)." -#: reference/expressions.rst:835 +#: reference/expressions.rst:833 msgid "" "The formal syntax makes no special provision for negative indices in " "sequences; however, built-in sequences all provide a :meth:`__getitem__` " @@ -1317,7 +1324,7 @@ msgstr "" "surchargent cette méthode doivent aussi savoir les gérer, de manière " "explicite." -#: reference/expressions.rst:849 +#: reference/expressions.rst:847 msgid "" "A string's items are characters. A character is not a separate data type " "but a string of exactly one character." @@ -1325,7 +1332,7 @@ msgstr "" "Les éléments des chaînes sont des caractères. Un caractère n'est pas un type " "en tant que tel, c'est une chaîne de longueur un." -#: reference/expressions.rst:852 +#: reference/expressions.rst:850 msgid "" "Subscription of certain :term:`classes ` or :term:`types ` " "creates a :ref:`generic alias `. In this case, user-" @@ -1337,11 +1344,11 @@ msgstr "" "classes définies par l'utilisateur peuvent gérer la sélection en fournissant " "une méthode de classe :meth:`__class_getitem__`." -#: reference/expressions.rst:861 +#: reference/expressions.rst:859 msgid "Slicings" msgstr "Tranches" -#: reference/expressions.rst:875 +#: reference/expressions.rst:873 msgid "" "A slicing selects a range of items in a sequence object (e.g., a string, " "tuple or list). Slicings may be used as expressions or as targets in " @@ -1354,7 +1361,7 @@ msgstr "" "les assignations ou les instructions :keyword:`del`. La syntaxe est la " "suivante :" -#: reference/expressions.rst:888 +#: reference/expressions.rst:886 msgid "" "There is ambiguity in the formal syntax here: anything that looks like an " "expression list also looks like a slice list, so any subscription can be " @@ -1373,7 +1380,7 @@ msgstr "" "que tranche (c'est le cas si la liste de tranches (*slice_list*) ne contient " "aucune tranche en tant que telle)." -#: reference/expressions.rst:900 +#: reference/expressions.rst:898 msgid "" "The semantics for a slicing are as follows. The primary is indexed (using " "the same :meth:`__getitem__` method as normal subscription) with a key that " @@ -1402,11 +1409,11 @@ msgstr "" "la grammaire) et le pas (*stride* dans la grammaire), respectivement. En cas " "d'expression manquante, la valeur par défaut est ``None``." -#: reference/expressions.rst:924 +#: reference/expressions.rst:922 msgid "Calls" msgstr "Appels" -#: reference/expressions.rst:926 +#: reference/expressions.rst:924 msgid "" "A call calls a callable object (e.g., a :term:`function`) with a possibly " "empty series of :term:`arguments `:" @@ -1415,7 +1422,7 @@ msgstr "" "(par exemple, une :term:`fonction `) avec, possiblement, une liste " "d'\\ :term:`arguments ` :" -#: reference/expressions.rst:943 +#: reference/expressions.rst:941 msgid "" "An optional trailing comma may be present after the positional and keyword " "arguments but does not affect the semantics." @@ -1423,7 +1430,7 @@ msgstr "" "Une virgule finale (optionnelle) peut être présente, après les arguments " "positionnels et nommés, mais elle n'affecte pas la sémantique." -#: reference/expressions.rst:949 +#: reference/expressions.rst:947 msgid "" "The primary must evaluate to a callable object (user-defined functions, " "built-in functions, methods of built-in objects, class objects, methods of " @@ -1440,7 +1447,7 @@ msgstr "" "section :ref:`function` pour la syntaxe des listes de :term:`paramètres " "` formels." -#: reference/expressions.rst:957 +#: reference/expressions.rst:955 msgid "" "If keyword arguments are present, they are first converted to positional " "arguments, as follows. First, a list of unfilled slots is created for the " @@ -1481,7 +1488,7 @@ msgstr "" "n'est définie, une exception :exc:`TypeError` est levée. Sinon, la liste des " "*slots* remplie est utilisée en tant que liste des arguments pour l'appel." -#: reference/expressions.rst:977 +#: reference/expressions.rst:975 msgid "" "An implementation may provide built-in functions whose positional parameters " "do not have names, even if they are 'named' for the purpose of " @@ -1495,7 +1502,7 @@ msgstr "" "CPython, les fonctions implémentées en C qui utilisent :c:func:" "`PyArg_ParseTuple` pour analyser leurs arguments en font partie." -#: reference/expressions.rst:983 +#: reference/expressions.rst:981 msgid "" "If there are more positional arguments than there are formal parameter " "slots, a :exc:`TypeError` exception is raised, unless a formal parameter " @@ -1509,7 +1516,7 @@ msgstr "" "reçoit un *n*-uplet contenant les arguments positionnels en supplément (ou " "un *n*-uplet vide s'il n'y avait pas d'argument positionnel en trop)." -#: reference/expressions.rst:989 +#: reference/expressions.rst:987 msgid "" "If any keyword argument does not correspond to a formal parameter name, a :" "exc:`TypeError` exception is raised, unless a formal parameter using the " @@ -1526,7 +1533,7 @@ msgstr "" "dictionnaire), ou un (nouveau) dictionnaire vide s'il n'y a pas d'argument " "par mot-clé en trop." -#: reference/expressions.rst:1000 +#: reference/expressions.rst:998 msgid "" "If the syntax ``*expression`` appears in the function call, ``expression`` " "must evaluate to an :term:`iterable`. Elements from these iterables are " @@ -1542,7 +1549,7 @@ msgstr "" "s'évalue comme une séquence *y1* … *yM*, c'est équivalent à un appel avec M" "+4 arguments positionnels *x1*, *x2*, *y1* … *yM*, *x3*, *x4*." -#: reference/expressions.rst:1007 +#: reference/expressions.rst:1005 msgid "" "A consequence of this is that although the ``*expression`` syntax may appear " "*after* explicit keyword arguments, it is processed *before* the keyword " @@ -1553,7 +1560,7 @@ msgstr "" "*avant* les arguments nommés (et avant tout argument ``**expression`` -- " "voir ci-dessous). Ainsi ::" -#: reference/expressions.rst:1023 +#: reference/expressions.rst:1021 msgid "" "It is unusual for both keyword arguments and the ``*expression`` syntax to " "be used in the same call, so in practice this confusion does not arise." @@ -1562,7 +1569,7 @@ msgstr "" "``*expression`` soient utilisés simultanément dans un même appel, ce qui " "fait que la confusion reste hypothétique." -#: reference/expressions.rst:1029 +#: reference/expressions.rst:1027 msgid "" "If the syntax ``**expression`` appears in the function call, ``expression`` " "must evaluate to a :term:`mapping`, the contents of which are treated as " @@ -1577,7 +1584,7 @@ msgstr "" "qu'argument par mot-clé explicite, ou venant d'un autre dépaquetage), une " "exception :exc:`TypeError` est levée." -#: reference/expressions.rst:1035 +#: reference/expressions.rst:1033 msgid "" "Formal parameters using the syntax ``*identifier`` or ``**identifier`` " "cannot be used as positional argument slots or as keyword argument names." @@ -1586,7 +1593,7 @@ msgstr "" "``**identifier`` ne peuvent pas être utilisés comme arguments positionnels " "ou comme noms d'arguments par mots-clés." -#: reference/expressions.rst:1038 +#: reference/expressions.rst:1036 msgid "" "Function calls accept any number of ``*`` and ``**`` unpackings, positional " "arguments may follow iterable unpackings (``*``), and keyword arguments may " @@ -1598,7 +1605,7 @@ msgstr "" "dépaquetages de dictionnaires (``**``). Proposé pour la première fois par " "la :pep:`448`." -#: reference/expressions.rst:1044 +#: reference/expressions.rst:1042 msgid "" "A call always returns some value, possibly ``None``, unless it raises an " "exception. How this value is computed depends on the type of the callable " @@ -1608,15 +1615,15 @@ msgstr "" "ne lève une exception. La façon dont celle valeur est calculée dépend du " "type de l'objet appelable." -#: reference/expressions.rst:1048 +#: reference/expressions.rst:1046 msgid "If it is---" msgstr "Si c'est ---" -#: reference/expressions.rst:1061 +#: reference/expressions.rst:1059 msgid "a user-defined function:" msgstr "une fonction définie par l'utilisateur :" -#: reference/expressions.rst:1057 +#: reference/expressions.rst:1055 msgid "" "The code block for the function is executed, passing it the argument list. " "The first thing the code block will do is bind the formal parameters to the " @@ -1630,11 +1637,11 @@ msgstr "" "`function`. Quand le bloc de code exécute l'instruction :keyword:`return`, " "cela spécifie la valeur de retour de l'appel de la fonction." -#: reference/expressions.rst:1075 +#: reference/expressions.rst:1073 msgid "a built-in function or method:" msgstr "une fonction ou une méthode native :" -#: reference/expressions.rst:1074 +#: reference/expressions.rst:1072 msgid "" "The result is up to the interpreter; see :ref:`built-in-funcs` for the " "descriptions of built-in functions and methods." @@ -1642,19 +1649,19 @@ msgstr "" "le résultat dépend de l'interpréteur ; lisez :ref:`built-in-funcs` pour une " "description des fonctions et méthodes natives." -#: reference/expressions.rst:1082 +#: reference/expressions.rst:1080 msgid "a class object:" msgstr "un objet classe :" -#: reference/expressions.rst:1082 +#: reference/expressions.rst:1080 msgid "A new instance of that class is returned." msgstr "une nouvelle instance de cette classe est renvoyée." -#: reference/expressions.rst:1092 +#: reference/expressions.rst:1090 msgid "a class instance method:" msgstr "une méthode d'instance de classe :" -#: reference/expressions.rst:1090 +#: reference/expressions.rst:1088 msgid "" "The corresponding user-defined function is called, with an argument list " "that is one longer than the argument list of the call: the instance becomes " @@ -1664,11 +1671,11 @@ msgstr "" "liste d'arguments qui est plus grande d'un élément que la liste des " "arguments de l'appel : l'instance est placée en tête des arguments." -#: reference/expressions.rst:1101 +#: reference/expressions.rst:1099 msgid "a class instance:" msgstr "une instance de classe :" -#: reference/expressions.rst:1099 +#: reference/expressions.rst:1097 msgid "" "The class must define a :meth:`__call__` method; the effect is then the same " "as if that method was called." @@ -1676,11 +1683,11 @@ msgstr "" "la classe doit définir une méthode :meth:`__call__` ; l'effet est le même " "que si cette méthode était appelée." -#: reference/expressions.rst:1872 +#: reference/expressions.rst:1871 msgid "Await expression" msgstr "Expression ``await``" -#: reference/expressions.rst:1109 +#: reference/expressions.rst:1107 msgid "" "Suspend the execution of :term:`coroutine` on an :term:`awaitable` object. " "Can only be used inside a :term:`coroutine function`." @@ -1688,11 +1695,11 @@ msgstr "" "Suspend l'exécution de la :term:`coroutine` sur un objet :term:`awaitable`. " "Ne peut être utilisée qu'à l'intérieur d'une :term:`coroutine function`." -#: reference/expressions.rst:1121 +#: reference/expressions.rst:1119 msgid "The power operator" msgstr "L'opérateur puissance" -#: reference/expressions.rst:1127 +#: reference/expressions.rst:1125 msgid "" "The power operator binds more tightly than unary operators on its left; it " "binds less tightly than unary operators on its right. The syntax is:" @@ -1701,7 +1708,7 @@ msgstr "" "gauche ; il est moins prioritaire que les opérateurs unaires sur sa droite. " "La syntaxe est :" -#: reference/expressions.rst:1133 +#: reference/expressions.rst:1131 msgid "" "Thus, in an unparenthesized sequence of power and unary operators, the " "operators are evaluated from right to left (this does not constrain the " @@ -1711,7 +1718,7 @@ msgstr "" "unaires, les opérateurs sont évalués de droite à gauche (ceci ne contraint " "pas l'ordre d'évaluation des opérandes) : ``-1**2`` donne ``-1``." -#: reference/expressions.rst:1137 +#: reference/expressions.rst:1135 msgid "" "The power operator has the same semantics as the built-in :func:`pow` " "function, when called with two arguments: it yields its left argument raised " @@ -1724,7 +1731,7 @@ msgstr "" "arguments numériques sont d'abord convertis vers un type commun et le " "résultat est de ce type." -#: reference/expressions.rst:1142 +#: reference/expressions.rst:1140 msgid "" "For int operands, the result has the same type as the operands unless the " "second argument is negative; in that case, all arguments are converted to " @@ -1737,7 +1744,7 @@ msgstr "" "virgule flottante. Par exemple, ``10**2`` renvoie ``100`` mais ``10**-2`` " "renvoie ``0.01``." -#: reference/expressions.rst:1147 +#: reference/expressions.rst:1145 msgid "" "Raising ``0.0`` to a negative power results in a :exc:`ZeroDivisionError`. " "Raising a negative number to a fractional power results in a :class:" @@ -1748,24 +1755,24 @@ msgstr "" "renvoie un nombre :class:`complexe ` (dans les versions " "antérieures, cela levait une :exc:`ValueError`)." -#: reference/expressions.rst:1151 +#: reference/expressions.rst:1149 msgid "" "This operation can be customized using the special :meth:`__pow__` method." msgstr "" "La méthode spéciale qui permet de surcharger cet opérateur est :meth:" "`__pow__`." -#: reference/expressions.rst:1156 +#: reference/expressions.rst:1154 msgid "Unary arithmetic and bitwise operations" msgstr "Arithmétique unaire et opérations sur les bits" -#: reference/expressions.rst:1162 +#: reference/expressions.rst:1160 msgid "All unary arithmetic and bitwise operations have the same priority:" msgstr "" "Toute l'arithmétique unaire et les opérations sur les bits ont la même " "priorité :" -#: reference/expressions.rst:1173 +#: reference/expressions.rst:1171 msgid "" "The unary ``-`` (minus) operator yields the negation of its numeric " "argument; the operation can be overridden with the :meth:`__neg__` special " @@ -1774,7 +1781,7 @@ msgstr "" "L'opérateur unaire ``-`` (moins) produit l'opposé de son argument numérique " "(la méthode spéciale qui le surcharge est :meth:`__neg__`) ;" -#: reference/expressions.rst:1181 +#: reference/expressions.rst:1179 msgid "" "The unary ``+`` (plus) operator yields its numeric argument unchanged; the " "operation can be overridden with the :meth:`__pos__` special method." @@ -1782,7 +1789,7 @@ msgstr "" "L'opérateur unaire ``+`` (plus) produit son argument numérique inchangé " "(surcharge par la méthode :meth:`__pos__`) ;" -#: reference/expressions.rst:1188 +#: reference/expressions.rst:1186 msgid "" "The unary ``~`` (invert) operator yields the bitwise inversion of its " "integer argument. The bitwise inversion of ``x`` is defined as ``-(x+1)``. " @@ -1794,7 +1801,7 @@ msgstr "" "+1)``. Elle ne s'applique qu'aux nombres entiers et aux objets allogènes qui " "surchargent la méthode spéciale :meth:`__invert__`." -#: reference/expressions.rst:1197 +#: reference/expressions.rst:1195 msgid "" "In all three cases, if the argument does not have the proper type, a :exc:" "`TypeError` exception is raised." @@ -1802,11 +1809,11 @@ msgstr "" "Dans ces trois cas, si l'argument n'est pas du bon type, une exception :exc:" "`TypeError` est levée." -#: reference/expressions.rst:1204 +#: reference/expressions.rst:1202 msgid "Binary arithmetic operations" msgstr "Opérations arithmétiques binaires" -#: reference/expressions.rst:1208 +#: reference/expressions.rst:1206 msgid "" "The binary arithmetic operations have the conventional priority levels. " "Note that some of these operations also apply to certain non-numeric types. " @@ -1819,7 +1826,7 @@ msgstr "" "niveaux, le premier pour les opérateurs multiplicatifs et le second pour les " "opérateurs additifs :" -#: reference/expressions.rst:1223 +#: reference/expressions.rst:1221 msgid "" "The ``*`` (multiplication) operator yields the product of its arguments. " "The arguments must either both be numbers, or one argument must be an " @@ -1835,7 +1842,7 @@ msgstr "" "Dans le dernier cas, la séquence est répétée ; une répétition négative " "produit une séquence vide." -#: reference/expressions.rst:1229 +#: reference/expressions.rst:1227 msgid "" "This operation can be customized using the special :meth:`__mul__` and :meth:" "`__rmul__` methods." @@ -1843,7 +1850,7 @@ msgstr "" "Les méthodes spéciales qui permettent de surcharger cet opérateur sont :meth:" "`__mul__` et :meth:`__rmul__`." -#: reference/expressions.rst:1236 +#: reference/expressions.rst:1234 msgid "" "The ``@`` (at) operator is intended to be used for matrix multiplication. " "No builtin Python types implement this operator." @@ -1851,7 +1858,7 @@ msgstr "" "L'opérateur ``@`` (prononcé *at* en anglais) a vocation à multiplier des " "matrices. Aucun type Python natif n'implémente cet opérateur." -#: reference/expressions.rst:1247 +#: reference/expressions.rst:1245 msgid "" "The ``/`` (division) and ``//`` (floor division) operators yield the " "quotient of their arguments. The numeric arguments are first converted to a " @@ -1868,7 +1875,7 @@ msgstr "" "mathématique suivie de la fonction ``floor`` appliquée au résultat. Une " "division par zéro lève une exception :exc:`ZeroDivisionError`." -#: reference/expressions.rst:1254 +#: reference/expressions.rst:1252 msgid "" "This operation can be customized using the special :meth:`__truediv__` and :" "meth:`__floordiv__` methods." @@ -1876,7 +1883,7 @@ msgstr "" "Les méthodes spéciales qui permettent de surcharger ces opérations sont :" "meth:`__truediv__` et :meth:`__floordiv__`." -#: reference/expressions.rst:1261 +#: reference/expressions.rst:1259 msgid "" "The ``%`` (modulo) operator yields the remainder from the division of the " "first argument by the second. The numeric arguments are first converted to " @@ -1896,7 +1903,7 @@ msgstr "" "même signe que le second opérande (ou zéro) ; la valeur absolue du résultat " "est strictement inférieure à la valeur absolue du second opérande [#]_." -#: reference/expressions.rst:1270 +#: reference/expressions.rst:1268 msgid "" "The floor division and modulo operators are connected by the following " "identity: ``x == (x//y)*y + (x%y)``. Floor division and modulo are also " @@ -1908,7 +1915,7 @@ msgstr "" "aussi liés à la fonction native :func:`divmod` : ``divmod(x, y) == (x//y, x" "%y)`` [#]_." -#: reference/expressions.rst:1275 +#: reference/expressions.rst:1273 msgid "" "In addition to performing the modulo operation on numbers, the ``%`` " "operator is also overloaded by string objects to perform old-style string " @@ -1922,7 +1929,7 @@ msgstr "" "décrit dans la référence de la bibliothèque Python, dans la section :ref:" "`old-string-formatting`." -#: reference/expressions.rst:1280 +#: reference/expressions.rst:1278 msgid "" "The *modulo* operation can be customized using the special :meth:`__mod__` " "method." @@ -1930,7 +1937,7 @@ msgstr "" "La méthode spéciale qui permet de surcharger cette opération est :meth:" "`__mod__`." -#: reference/expressions.rst:1282 +#: reference/expressions.rst:1280 msgid "" "The floor division operator, the modulo operator, and the :func:`divmod` " "function are not defined for complex numbers. Instead, convert to a " @@ -1941,7 +1948,7 @@ msgstr "" "pouvez, si cela a du sens pour ce que vous voulez faire, les convertir vers " "des nombres à virgule flottante en utilisant la fonction :func:`abs`." -#: reference/expressions.rst:1291 +#: reference/expressions.rst:1289 msgid "" "The ``+`` (addition) operator yields the sum of its arguments. The " "arguments must either both be numbers or both be sequences of the same " @@ -1954,7 +1961,7 @@ msgstr "" "puis sont additionnés entre eux. Dans le dernier cas, les séquences sont " "concaténées." -#: reference/expressions.rst:1296 +#: reference/expressions.rst:1294 msgid "" "This operation can be customized using the special :meth:`__add__` and :meth:" "`__radd__` methods." @@ -1962,7 +1969,7 @@ msgstr "" "Les méthodes spéciales qui permettent de surcharger cette opération sont :" "meth:`__add__` et :meth:`__radd__`." -#: reference/expressions.rst:1304 +#: reference/expressions.rst:1302 msgid "" "The ``-`` (subtraction) operator yields the difference of its arguments. " "The numeric arguments are first converted to a common type." @@ -1970,25 +1977,25 @@ msgstr "" "L'opérateur ``-`` (soustraction) produit la différence entre ses arguments. " "Les arguments numériques sont d'abord convertis vers un type commun." -#: reference/expressions.rst:1307 +#: reference/expressions.rst:1305 msgid "" "This operation can be customized using the special :meth:`__sub__` method." msgstr "" "La méthode spéciale qui permet de surcharger cette opération est :meth:" "`__sub__`." -#: reference/expressions.rst:1313 +#: reference/expressions.rst:1311 msgid "Shifting operations" msgstr "Opérations de décalage" -#: reference/expressions.rst:1320 +#: reference/expressions.rst:1318 msgid "" "The shifting operations have lower priority than the arithmetic operations:" msgstr "" "Les opérations de décalage sont moins prioritaires que les opérations " "arithmétiques :" -#: reference/expressions.rst:1325 +#: reference/expressions.rst:1323 msgid "" "These operators accept integers as arguments. They shift the first argument " "to the left or right by the number of bits given by the second argument." @@ -1997,7 +2004,7 @@ msgstr "" "argument vers la gauche ou vers la droite du nombre de bits donné par le " "deuxième argument." -#: reference/expressions.rst:1328 +#: reference/expressions.rst:1326 msgid "" "This operation can be customized using the special :meth:`__lshift__` and :" "meth:`__rshift__` methods." @@ -2005,7 +2012,7 @@ msgstr "" "Les méthodes spéciales qui permettent de surcharger ces opérations sont :" "meth:`__lshift__` et :meth:`__rshift__`." -#: reference/expressions.rst:1333 +#: reference/expressions.rst:1331 msgid "" "A right shift by *n* bits is defined as floor division by ``pow(2,n)``. A " "left shift by *n* bits is defined as multiplication with ``pow(2,n)``." @@ -2014,17 +2021,17 @@ msgstr "" "``pow(2,n)``. Un décalage à gauche de *n* bits est défini comme la " "multiplication par ``pow(2,n)``." -#: reference/expressions.rst:1340 +#: reference/expressions.rst:1338 msgid "Binary bitwise operations" msgstr "Opérations binaires bit à bit" -#: reference/expressions.rst:1344 +#: reference/expressions.rst:1342 msgid "Each of the three bitwise operations has a different priority level:" msgstr "" "Chacune des trois opérations binaires bit à bit possède une priorité " "différente :" -#: reference/expressions.rst:1355 +#: reference/expressions.rst:1353 msgid "" "The ``&`` operator yields the bitwise AND of its arguments, which must be " "integers or one of them must be a custom object overriding :meth:`__and__` " @@ -2034,7 +2041,7 @@ msgstr "" "des entiers, sauf si celui de gauche surcharge la méthode spéciale :meth:" "`__and__`, ou celui de droite la méthode :meth:`__rand__`." -#: reference/expressions.rst:1364 +#: reference/expressions.rst:1362 msgid "" "The ``^`` operator yields the bitwise XOR (exclusive OR) of its arguments, " "which must be integers or one of them must be a custom object overriding :" @@ -2044,7 +2051,7 @@ msgstr "" "doivent être des entiers, sauf à surcharger :meth:`__xor__` ou :meth:" "`__rxor__`." -#: reference/expressions.rst:1373 +#: reference/expressions.rst:1371 msgid "" "The ``|`` operator yields the bitwise (inclusive) OR of its arguments, which " "must be integers or one of them must be a custom object overriding :meth:" @@ -2053,11 +2060,11 @@ msgstr "" "L'opérateur ``|`` produit le OU logique de ses arguments. Ils doivent être " "des entiers, sauf à surcharger :meth:`__or__` ou :meth:`__ror__`." -#: reference/expressions.rst:1381 +#: reference/expressions.rst:1379 msgid "Comparisons" msgstr "Comparaisons" -#: reference/expressions.rst:1393 +#: reference/expressions.rst:1391 msgid "" "Unlike C, all comparison operations in Python have the same priority, which " "is lower than that of any arithmetic, shifting or bitwise operation. Also " @@ -2070,7 +2077,7 @@ msgstr "" "les expressions telles que ``a < b < c`` sont interprétées comme elles le " "seraient conventionnellement en mathématiques :" -#: reference/expressions.rst:1403 +#: reference/expressions.rst:1401 msgid "" "Comparisons yield boolean values: ``True`` or ``False``. Custom :dfn:`rich " "comparison methods` may return non-boolean values. In this case Python will " @@ -2082,7 +2089,7 @@ msgstr "" "la comparaison est converti en booléen avec :func:`bool` dans les contextes " "qui attendent un booléen." -#: reference/expressions.rst:1409 +#: reference/expressions.rst:1407 msgid "" "Comparisons can be chained arbitrarily, e.g., ``x < y <= z`` is equivalent " "to ``x < y and y <= z``, except that ``y`` is evaluated only once (but in " @@ -2094,7 +2101,7 @@ msgstr "" "seulement une fois (mais dans les deux cas, ``z`` n'est pas évalué du tout " "si ``x < y`` s'avère être faux)." -#: reference/expressions.rst:1413 +#: reference/expressions.rst:1411 msgid "" "Formally, if *a*, *b*, *c*, ..., *y*, *z* are expressions and *op1*, " "*op2*, ..., *opN* are comparison operators, then ``a op1 b op2 c ... y opN " @@ -2106,7 +2113,7 @@ msgstr "" "opN z`` est équivalent à ``a op1 b and b op2 c and … y opN z``, sauf que " "chaque expression est évaluée au maximum une fois." -#: reference/expressions.rst:1418 +#: reference/expressions.rst:1416 msgid "" "Note that ``a op1 b op2 c`` doesn't imply any kind of comparison between *a* " "and *c*, so that, e.g., ``x < y > z`` is perfectly legal (though perhaps not " @@ -2116,11 +2123,11 @@ msgstr "" "Ainsi, par exemple, ``x < y > z`` est parfaitement légal (mais peut-être pas " "très élégant)." -#: reference/expressions.rst:1423 +#: reference/expressions.rst:1421 msgid "Value comparisons" msgstr "Comparaisons de valeurs" -#: reference/expressions.rst:1425 +#: reference/expressions.rst:1423 msgid "" "The operators ``<``, ``>``, ``==``, ``>=``, ``<=``, and ``!=`` compare the " "values of two objects. The objects do not need to have the same type." @@ -2128,7 +2135,7 @@ msgstr "" "Les opérateurs ``<``, ``>``, ``==``, ``>=``, ``<=`` et ``!=`` comparent les " "valeurs de deux objets. Les objets n'ont pas besoin d'être du même type." -#: reference/expressions.rst:1428 +#: reference/expressions.rst:1426 msgid "" "Chapter :ref:`objects` states that objects have a value (in addition to type " "and identity). The value of an object is a rather abstract notion in " @@ -2149,7 +2156,7 @@ msgstr "" "d'un objet. Vous pouvez vous le représenter comme une définition indirecte " "de la valeur d'un objet, *via* l'implémentation de leur comparaison." -#: reference/expressions.rst:1437 +#: reference/expressions.rst:1435 msgid "" "Because all types are (direct or indirect) subtypes of :class:`object`, they " "inherit the default comparison behavior from :class:`object`. Types can " @@ -2162,7 +2169,7 @@ msgstr "" "des comparaisons en implémentant des :dfn:`méthodes de comparaisons riches`, " "comme :meth:`__lt__`, décrites dans :ref:`customization`." -#: reference/expressions.rst:1443 +#: reference/expressions.rst:1441 msgid "" "The default behavior for equality comparison (``==`` and ``!=``) is based on " "the identity of the objects. Hence, equality comparison of instances with " @@ -2178,7 +2185,7 @@ msgstr "" "choix est que Python souhaite que tous les objets soient réflexifs, c'est-à-" "dire que ``x is y`` implique ``x == y``." -#: reference/expressions.rst:1450 +#: reference/expressions.rst:1448 msgid "" "A default order comparison (``<``, ``>``, ``<=``, and ``>=``) is not " "provided; an attempt raises :exc:`TypeError`. A motivation for this default " @@ -2188,7 +2195,7 @@ msgstr "" "défaut ; une tentative se solde par une :exc:`TypeError`. La raison de ce " "choix est qu'il n'existe pas d'invariant similaire à celui de l'égalité." -#: reference/expressions.rst:1454 +#: reference/expressions.rst:1452 msgid "" "The behavior of the default equality comparison, that instances with " "different identities are always unequal, may be in contrast to what types " @@ -2203,7 +2210,7 @@ msgstr "" "personnaliser leurs tests de comparaison et, en fait, c'est ce qu'ont fait " "un certain nombre de types natifs." -#: reference/expressions.rst:1460 +#: reference/expressions.rst:1458 msgid "" "The following list describes the comparison behavior of the most important " "built-in types." @@ -2211,7 +2218,7 @@ msgstr "" "La liste suivante décrit le comportement des tests d'égalité pour les types " "natifs les plus importants." -#: reference/expressions.rst:1463 +#: reference/expressions.rst:1461 msgid "" "Numbers of built-in numeric types (:ref:`typesnumeric`) and of the standard " "library types :class:`fractions.Fraction` and :class:`decimal.Decimal` can " @@ -2228,7 +2235,7 @@ msgstr "" "des types concernés, la comparaison mathématique équivaut à la comparaison " "algorithmique, sans perte de précision." -#: reference/expressions.rst:1470 +#: reference/expressions.rst:1468 msgid "" "The not-a-number values ``float('NaN')`` and ``decimal.Decimal('NaN')`` are " "special. Any ordered comparison of a number to a not-a-number value is " @@ -2245,7 +2252,7 @@ msgstr "" "sont toutes fausses, mais l’expression ``x != x`` est vraie. Ce comportement " "est en accord avec IEEE 754." -#: reference/expressions.rst:1477 +#: reference/expressions.rst:1475 msgid "" "``None`` and ``NotImplemented`` are singletons. :PEP:`8` advises that " "comparisons for singletons should always be done with ``is`` or ``is not``, " @@ -2255,7 +2262,7 @@ msgstr "" "toujours comparer les singletons en utilisant soit ``is`` soit ``is not``, " "jamais les autres opérateurs." -#: reference/expressions.rst:1481 +#: reference/expressions.rst:1479 msgid "" "Binary sequences (instances of :class:`bytes` or :class:`bytearray`) can be " "compared within and across their types. They compare lexicographically " @@ -2266,7 +2273,7 @@ msgstr "" "La comparaison est lexicographique, en utilisant la valeur numérique des " "éléments." -#: reference/expressions.rst:1485 +#: reference/expressions.rst:1483 msgid "" "Strings (instances of :class:`str`) compare lexicographically using the " "numerical Unicode code points (the result of the built-in function :func:" @@ -2276,13 +2283,13 @@ msgstr "" "lexicographique en utilisant la valeur Unicode (le résultat de la fonction " "native :func:`ord`) des caractères [#]_." -#: reference/expressions.rst:1489 +#: reference/expressions.rst:1487 msgid "Strings and binary sequences cannot be directly compared." msgstr "" "Les chaînes de caractères et les séquences binaires ne peuvent pas être " "comparées directement." -#: reference/expressions.rst:1491 +#: reference/expressions.rst:1489 msgid "" "Sequences (instances of :class:`tuple`, :class:`list`, or :class:`range`) " "can be compared only within each of their types, with the restriction that " @@ -2296,7 +2303,7 @@ msgstr "" "d'égalité entre ces types renvoie faux et une comparaison entre instances de " "types différents lève une :exc:`TypeError`." -#: reference/expressions.rst:1497 +#: reference/expressions.rst:1495 msgid "" "Sequences compare lexicographically using comparison of corresponding " "elements. The built-in containers typically assume identical objects are " @@ -2309,13 +2316,13 @@ msgstr "" "d’égalité pour des objets identiques afin d’améliorer les performances et de " "conserver leurs invariants internes." -#: reference/expressions.rst:1502 +#: reference/expressions.rst:1500 msgid "" "Lexicographical comparison between built-in collections works as follows:" msgstr "" "L'ordre lexicographique pour les collections natives fonctionne comme suit :" -#: reference/expressions.rst:1504 +#: reference/expressions.rst:1502 msgid "" "For two collections to compare equal, they must be of the same type, have " "the same length, and each pair of corresponding elements must compare equal " @@ -2325,7 +2332,7 @@ msgstr "" "longueur et si les éléments correspondants de chaque paire sont égaux. Par " "exemple, ``[1,2] == (1,2)`` est faux car les types sont différents." -#: reference/expressions.rst:1509 +#: reference/expressions.rst:1507 msgid "" "Collections that support order comparison are ordered the same as their " "first unequal elements (for example, ``[1,2,x] <= [1,2,y]`` has the same " @@ -2339,7 +2346,7 @@ msgstr "" "collection la plus courte est la plus petite (par exemple, ``[1,2] < " "[1,2,3]`` est vrai)." -#: reference/expressions.rst:1515 +#: reference/expressions.rst:1513 msgid "" "Mappings (instances of :class:`dict`) compare equal if and only if they have " "equal `(key, value)` pairs. Equality comparison of the keys and values " @@ -2349,13 +2356,13 @@ msgstr "" "et seulement si toutes leurs paires `(clé, valeur)` sont égales. L'égalité " "des clés et des valeurs met en œuvre la réflexivité." -#: reference/expressions.rst:1519 +#: reference/expressions.rst:1517 msgid "" "Order comparisons (``<``, ``>``, ``<=``, and ``>=``) raise :exc:`TypeError`." msgstr "" "Les comparaisons (``<``, ``>``, ``<=`` et ``>=``) lèvent :exc:`TypeError`." -#: reference/expressions.rst:1521 +#: reference/expressions.rst:1519 msgid "" "Sets (instances of :class:`set` or :class:`frozenset`) can be compared " "within and across their types." @@ -2363,7 +2370,7 @@ msgstr "" "Les ensembles (instances de :class:`set` ou :class:`frozenset`) peuvent être " "comparés au sein de leur propre type et entre types différents." -#: reference/expressions.rst:1524 +#: reference/expressions.rst:1522 msgid "" "They define order comparison operators to mean subset and superset tests. " "Those relations do not define total orderings (for example, the two sets " @@ -2381,11 +2388,11 @@ msgstr "" "exemple, les fonctions :func:`min`, :func:`max` et :func:`sorted` produisent " "des résultats indéfinis si on leur donne des listes d'ensembles en entrée)." -#: reference/expressions.rst:1532 +#: reference/expressions.rst:1530 msgid "Comparison of sets enforces reflexivity of its elements." msgstr "La comparaison des ensembles met en œuvre la réflexivité des éléments." -#: reference/expressions.rst:1534 +#: reference/expressions.rst:1532 msgid "" "Most other built-in types have no comparison methods implemented, so they " "inherit the default comparison behavior." @@ -2393,7 +2400,7 @@ msgstr "" "La plupart des autres types natifs n'implémentent pas de méthodes de " "comparaisons, ils héritent donc du comportement par défaut." -#: reference/expressions.rst:1537 +#: reference/expressions.rst:1535 msgid "" "User-defined classes that customize their comparison behavior should follow " "some consistency rules, if possible:" @@ -2401,7 +2408,7 @@ msgstr "" "Les classes allogènes qui particularisent les opérations de comparaison " "doivent, si possible, respecter quelques règles pour la cohérence :" -#: reference/expressions.rst:1540 +#: reference/expressions.rst:1538 msgid "" "Equality comparison should be reflexive. In other words, identical objects " "should compare equal:" @@ -2409,11 +2416,11 @@ msgstr "" "Le test d'égalité doit être réflexif. En d'autres termes, des objets " "identiques doivent être égaux :" -#: reference/expressions.rst:1543 +#: reference/expressions.rst:1541 msgid "``x is y`` implies ``x == y``" msgstr "``x is y`` implique ``x == y``" -#: reference/expressions.rst:1545 +#: reference/expressions.rst:1543 msgid "" "Comparison should be symmetric. In other words, the following expressions " "should have the same result:" @@ -2421,23 +2428,23 @@ msgstr "" "La comparaison doit être symétrique. En d'autres termes, les expressions " "suivantes doivent donner le même résultat :" -#: reference/expressions.rst:1548 +#: reference/expressions.rst:1546 msgid "``x == y`` and ``y == x``" msgstr "``x == y`` et ``y == x``" -#: reference/expressions.rst:1550 +#: reference/expressions.rst:1548 msgid "``x != y`` and ``y != x``" msgstr "``x != y`` et ``y != x``" -#: reference/expressions.rst:1552 +#: reference/expressions.rst:1550 msgid "``x < y`` and ``y > x``" msgstr "``x < y`` et ``y > x``" -#: reference/expressions.rst:1554 +#: reference/expressions.rst:1552 msgid "``x <= y`` and ``y >= x``" msgstr "``x <= y`` et ``y >= x``" -#: reference/expressions.rst:1556 +#: reference/expressions.rst:1554 msgid "" "Comparison should be transitive. The following (non-exhaustive) examples " "illustrate that:" @@ -2445,15 +2452,15 @@ msgstr "" "La comparaison doit être transitive. Les exemples suivants (liste non " "exhaustive) illustrent ce concept :" -#: reference/expressions.rst:1559 +#: reference/expressions.rst:1557 msgid "``x > y and y > z`` implies ``x > z``" msgstr "``x > y and y > z`` implique ``x > z``" -#: reference/expressions.rst:1561 +#: reference/expressions.rst:1559 msgid "``x < y and y <= z`` implies ``x < z``" msgstr "``x < y and y <= z`` implique ``x < z``" -#: reference/expressions.rst:1563 +#: reference/expressions.rst:1561 msgid "" "Inverse comparison should result in the boolean negation. In other words, " "the following expressions should have the same result:" @@ -2462,19 +2469,19 @@ msgstr "" "booléenne. En d'autres termes, les expressions suivantes doivent produire le " "même résultat :" -#: reference/expressions.rst:1566 +#: reference/expressions.rst:1564 msgid "``x == y`` and ``not x != y``" msgstr "``x == y`` et ``not x != y``" -#: reference/expressions.rst:1568 +#: reference/expressions.rst:1566 msgid "``x < y`` and ``not x >= y`` (for total ordering)" msgstr "``x < y`` et ``not x >= y`` (pour une relation d'ordre total)" -#: reference/expressions.rst:1570 +#: reference/expressions.rst:1568 msgid "``x > y`` and ``not x <= y`` (for total ordering)" msgstr "``x > y`` et ``not x <= y`` (pour une relation d'ordre total)" -#: reference/expressions.rst:1572 +#: reference/expressions.rst:1570 msgid "" "The last two expressions apply to totally ordered collections (e.g. to " "sequences, but not to sets or mappings). See also the :func:`~functools." @@ -2485,7 +2492,7 @@ msgstr "" "de correspondances). Regardez aussi le décorateur :func:`~functools." "total_ordering`." -#: reference/expressions.rst:1576 +#: reference/expressions.rst:1574 msgid "" "The :func:`hash` result should be consistent with equality. Objects that are " "equal should either have the same hash value, or be marked as unhashable." @@ -2494,7 +2501,7 @@ msgstr "" "qui sont égaux doivent avoir la même empreinte ou être marqués comme non-" "hachables." -#: reference/expressions.rst:1580 +#: reference/expressions.rst:1578 msgid "" "Python does not enforce these consistency rules. In fact, the not-a-number " "values are an example for not following these rules." @@ -2502,11 +2509,11 @@ msgstr "" "Python ne vérifie pas ces règles de cohérence. En fait, l'utilisation de " "valeurs non numériques est un exemple de non-respect de ces règles." -#: reference/expressions.rst:1589 +#: reference/expressions.rst:1587 msgid "Membership test operations" msgstr "Opérations de tests d’appartenance à un ensemble" -#: reference/expressions.rst:1591 +#: reference/expressions.rst:1589 msgid "" "The operators :keyword:`in` and :keyword:`not in` test for membership. ``x " "in s`` evaluates to ``True`` if *x* is a member of *s*, and ``False`` " @@ -2526,7 +2533,7 @@ msgstr "" "*collections.deque*, l’expression ``x in y`` est équivalente à ``any(x is e " "or x == e for e in y)``." -#: reference/expressions.rst:1599 +#: reference/expressions.rst:1597 msgid "" "For the string and bytes types, ``x in y`` is ``True`` if and only if *x* is " "a substring of *y*. An equivalent test is ``y.find(x) != -1``. Empty " @@ -2538,7 +2545,7 @@ msgstr "" "``y.find(x) != -1``. Une chaîne vide est considérée comme une sous-chaîne de " "toute autre chaîne, ainsi ``\"\" in \"abc\"`` renvoie ``True``." -#: reference/expressions.rst:1604 +#: reference/expressions.rst:1602 msgid "" "For user-defined classes which define the :meth:`__contains__` method, ``x " "in y`` returns ``True`` if ``y.__contains__(x)`` returns a true value, and " @@ -2548,7 +2555,7 @@ msgstr "" "``x in y`` renvoie ``True`` si ``y.__contains__(x)`` renvoie vrai, et " "``False`` sinon." -#: reference/expressions.rst:1608 +#: reference/expressions.rst:1606 msgid "" "For user-defined classes which do not define :meth:`__contains__` but do " "define :meth:`__iter__`, ``x in y`` is ``True`` if some value ``z``, for " @@ -2562,7 +2569,7 @@ msgstr "" "de l'itération sur ``y``. Si une exception est levée pendant l'itération, " "c'est comme si :keyword:`in` avait levé cette exception." -#: reference/expressions.rst:1614 +#: reference/expressions.rst:1612 msgid "" "Lastly, the old-style iteration protocol is tried: if a class defines :meth:" "`__getitem__`, ``x in y`` is ``True`` if and only if there is a non-negative " @@ -2577,7 +2584,7 @@ msgstr "" "`IndexError` (si toute autre exception est levée, c'est comme si :keyword:" "`in` avait levé cette exception)." -#: reference/expressions.rst:1626 +#: reference/expressions.rst:1624 msgid "" "The operator :keyword:`not in` is defined to have the inverse truth value " "of :keyword:`in`." @@ -2585,11 +2592,11 @@ msgstr "" "L'opérateur :keyword:`not in` est défini comme produisant le contraire de :" "keyword:`in`." -#: reference/expressions.rst:1639 +#: reference/expressions.rst:1637 msgid "Identity comparisons" msgstr "Comparaisons d'identifiants" -#: reference/expressions.rst:1641 +#: reference/expressions.rst:1639 msgid "" "The operators :keyword:`is` and :keyword:`is not` test for an object's " "identity: ``x is y`` is true if and only if *x* and *y* are the same " @@ -2602,11 +2609,11 @@ msgstr "" "fonction :meth:`id`. ``x is not y`` renvoie le résultat contraire de " "l'égalité des identifiants [#]_." -#: reference/expressions.rst:1653 +#: reference/expressions.rst:1651 msgid "Boolean operations" msgstr "Opérations booléennes" -#: reference/expressions.rst:1664 +#: reference/expressions.rst:1662 msgid "" "In the context of Boolean operations, and also when expressions are used by " "control flow statements, the following values are interpreted as false: " @@ -2625,7 +2632,7 @@ msgstr "" "allogènes peuvent personnaliser leur table de vérité en implémentant une " "méthode :meth:`__bool__`." -#: reference/expressions.rst:1673 +#: reference/expressions.rst:1671 msgid "" "The operator :keyword:`not` yields ``True`` if its argument is false, " "``False`` otherwise." @@ -2633,7 +2640,7 @@ msgstr "" "L'opérateur :keyword:`not` produit ``True`` si son argument est faux, " "``False`` sinon." -#: reference/expressions.rst:1678 +#: reference/expressions.rst:1676 msgid "" "The expression ``x and y`` first evaluates *x*; if *x* is false, its value " "is returned; otherwise, *y* is evaluated and the resulting value is returned." @@ -2642,7 +2649,7 @@ msgstr "" "valeur est renvoyée ; sinon, *y* est évalué et la valeur résultante est " "renvoyée." -#: reference/expressions.rst:1683 +#: reference/expressions.rst:1681 msgid "" "The expression ``x or y`` first evaluates *x*; if *x* is true, its value is " "returned; otherwise, *y* is evaluated and the resulting value is returned." @@ -2651,7 +2658,7 @@ msgstr "" "valeur est renvoyée ; sinon, *y* est évalué et la valeur résultante est " "renvoyée." -#: reference/expressions.rst:1686 +#: reference/expressions.rst:1684 msgid "" "Note that neither :keyword:`and` nor :keyword:`or` restrict the value and " "type they return to ``False`` and ``True``, but rather return the last " @@ -2670,40 +2677,42 @@ msgstr "" "de son argument (par exemple, ``not 'truc'`` produit ``False`` plutôt que " "``''``." -#: reference/expressions.rst:1696 +#: reference/expressions.rst:1694 msgid "Assignment expressions" msgstr "Expressions d'affectation" -#: reference/expressions.rst:1701 +#: reference/expressions.rst:1699 +#, fuzzy msgid "" "An assignment expression (sometimes also called a \"named expression\" or " -"\"walrus\") assigns an :token:`expression` to an :token:`identifier`, while " -"also returning the value of the :token:`expression`." +"\"walrus\") assigns an :token:`~python-grammar:expression` to an :token:" +"`~python-grammar:identifier`, while also returning the value of the :token:" +"`~python-grammar:expression`." msgstr "" "Une expression d'affectation (parfois aussi appelée « expression nommée » ou " "« expression morse ») affecte l':token:`expression` à un :token:" "`identifiant` et renvoie la valeur de l':token:`expression`." -#: reference/expressions.rst:1705 +#: reference/expressions.rst:1704 msgid "One common use case is when handling matched regular expressions:" msgstr "" "Une utilisation classique concerne les correspondances d'expressions " "rationnelles :" -#: reference/expressions.rst:1712 +#: reference/expressions.rst:1711 msgid "Or, when processing a file stream in chunks:" msgstr "Ou lorsqu'on traite le contenu d'un fichier par morceaux :" -#: reference/expressions.rst:1719 +#: reference/expressions.rst:1718 msgid "See :pep:`572` for more details about assignment expressions." msgstr "" "Voir la :pep:`572` pour plus de détails sur les expressions d’affectation." -#: reference/expressions.rst:1726 +#: reference/expressions.rst:1725 msgid "Conditional expressions" msgstr "Expressions conditionnelles" -#: reference/expressions.rst:1738 +#: reference/expressions.rst:1737 msgid "" "Conditional expressions (sometimes called a \"ternary operator\") have the " "lowest priority of all Python operations." @@ -2711,7 +2720,7 @@ msgstr "" "Les expressions conditionnelles (parfois appelées « opérateur ternaire ») " "sont les moins prioritaires de toutes les opérations Python." -#: reference/expressions.rst:1741 +#: reference/expressions.rst:1740 msgid "" "The expression ``x if C else y`` first evaluates the condition, *C* rather " "than *x*. If *C* is true, *x* is evaluated and its value is returned; " @@ -2721,16 +2730,16 @@ msgstr "" "est vrai, alors *x* est évalué et sa valeur est renvoyée ; sinon, *y* est " "évalué et sa valeur est renvoyée." -#: reference/expressions.rst:1745 +#: reference/expressions.rst:1744 msgid "See :pep:`308` for more details about conditional expressions." msgstr "" "Voir la :pep:`308` pour plus de détails sur les expressions conditionnelles." -#: reference/expressions.rst:1752 +#: reference/expressions.rst:1751 msgid "Lambdas" msgstr "Expressions lambda" -#: reference/expressions.rst:1763 +#: reference/expressions.rst:1762 msgid "" "Lambda expressions (sometimes called lambda forms) are used to create " "anonymous functions. The expression ``lambda parameters: expression`` yields " @@ -2741,7 +2750,7 @@ msgstr "" "L'expression ``lambda parameters: expression`` produit un objet fonction. " "Cet objet anonyme se comporte comme un objet fonction défini par :" -#: reference/expressions.rst:1772 +#: reference/expressions.rst:1771 msgid "" "See section :ref:`function` for the syntax of parameter lists. Note that " "functions created with lambda expressions cannot contain statements or " @@ -2751,11 +2760,11 @@ msgstr "" "Notez que les fonctions créées par des expressions lambda ne peuvent pas " "contenir d'instructions ou d'annotations." -#: reference/expressions.rst:1780 +#: reference/expressions.rst:1779 msgid "Expression lists" msgstr "Listes d'expressions" -#: reference/expressions.rst:1794 +#: reference/expressions.rst:1793 msgid "" "Except when part of a list or set display, an expression list containing at " "least one comma yields a tuple. The length of the tuple is the number of " @@ -2766,7 +2775,7 @@ msgstr "" "La longueur du *n*-uplet est le nombre d'expressions dans la liste. Les " "expressions sont évaluées de la gauche vers la droite." -#: reference/expressions.rst:1803 +#: reference/expressions.rst:1802 msgid "" "An asterisk ``*`` denotes :dfn:`iterable unpacking`. Its operand must be " "an :term:`iterable`. The iterable is expanded into a sequence of items, " @@ -2778,14 +2787,14 @@ msgstr "" "L'itérable est développé en une séquence d'éléments qui sont inclus dans un " "nouvel objet *n*-uplet, liste ou ensemble à l'emplacement du dépaquetage." -#: reference/expressions.rst:1808 +#: reference/expressions.rst:1807 msgid "" "Iterable unpacking in expression lists, originally proposed by :pep:`448`." msgstr "" "dépaquetage d'itérables dans les listes d'expressions, proposé à l'origine " "par la :pep:`448`." -#: reference/expressions.rst:1813 +#: reference/expressions.rst:1812 msgid "" "The trailing comma is required only to create a single tuple (a.k.a. a " "*singleton*); it is optional in all other cases. A single expression " @@ -2799,11 +2808,11 @@ msgstr "" "produit la valeur de cette expression (pour créer un *n*-uplet vide, " "utilisez une paire de parenthèses vide : ``()``)." -#: reference/expressions.rst:1823 +#: reference/expressions.rst:1822 msgid "Evaluation order" msgstr "Ordre d'évaluation" -#: reference/expressions.rst:1827 +#: reference/expressions.rst:1826 msgid "" "Python evaluates expressions from left to right. Notice that while " "evaluating an assignment, the right-hand side is evaluated before the left-" @@ -2813,7 +2822,7 @@ msgstr "" "lors de l'évaluation d'une assignation, la partie droite de l'assignation " "est évaluée avant la partie gauche." -#: reference/expressions.rst:1830 +#: reference/expressions.rst:1829 msgid "" "In the following lines, expressions will be evaluated in the arithmetic " "order of their suffixes::" @@ -2821,11 +2830,11 @@ msgstr "" "Dans les lignes qui suivent, les expressions sont évaluées suivant l'ordre " "arithmétique de leurs suffixes ::" -#: reference/expressions.rst:1844 +#: reference/expressions.rst:1843 msgid "Operator precedence" msgstr "Priorités des opérateurs" -#: reference/expressions.rst:1849 +#: reference/expressions.rst:1848 msgid "" "The following table summarizes the operator precedence in Python, from " "highest precedence (most binding) to lowest precedence (least binding). " @@ -2840,7 +2849,7 @@ msgstr "" "binaires. Les opérateurs dans la même case regroupent de la gauche vers la " "droite (sauf pour la puissance qui regroupe de la droite vers la gauche)." -#: reference/expressions.rst:1855 +#: reference/expressions.rst:1854 msgid "" "Note that comparisons, membership tests, and identity tests, all have the " "same precedence and have a left-to-right chaining feature as described in " @@ -2850,23 +2859,23 @@ msgstr "" "d'identifiants possèdent tous la même priorité et s'enchaînent de la gauche " "vers la droite comme décrit dans la section :ref:`comparisons`." -#: reference/expressions.rst:1861 +#: reference/expressions.rst:1860 msgid "Operator" msgstr "Opérateur" -#: reference/expressions.rst:1861 +#: reference/expressions.rst:1860 msgid "Description" msgstr "Description" -#: reference/expressions.rst:1863 +#: reference/expressions.rst:1862 msgid "``(expressions...)``," msgstr "``(expressions…)``," -#: reference/expressions.rst:1865 +#: reference/expressions.rst:1864 msgid "``[expressions...]``, ``{key: value...}``, ``{expressions...}``" msgstr "``[expressions…]``, ``{key: value…}``, ``{expressions…}``" -#: reference/expressions.rst:1863 +#: reference/expressions.rst:1862 msgid "" "Binding or parenthesized expression, list display, dictionary display, set " "display" @@ -2874,39 +2883,39 @@ msgstr "" "Expression de liaison ou parenthèse, affichage de liste, affichage de " "dictionnaire, affichage de *set*" -#: reference/expressions.rst:1869 +#: reference/expressions.rst:1868 msgid "``x[index]``, ``x[index:index]``, ``x(arguments...)``, ``x.attribute``" msgstr "``x[indice]``, ``x[indice:indice]``, ``x(arguments…)``, ``x.attribut``" -#: reference/expressions.rst:1869 +#: reference/expressions.rst:1868 msgid "Subscription, slicing, call, attribute reference" msgstr "indiçage, tranches, appel, référence à un attribut" -#: reference/expressions.rst:1872 +#: reference/expressions.rst:1871 msgid ":keyword:`await` ``x``" msgstr ":keyword:`await` ``x``" -#: reference/expressions.rst:1874 +#: reference/expressions.rst:1873 msgid "``**``" msgstr "``**``" -#: reference/expressions.rst:1874 +#: reference/expressions.rst:1873 msgid "Exponentiation [#]_" msgstr "Puissance [#]_" -#: reference/expressions.rst:1876 +#: reference/expressions.rst:1875 msgid "``+x``, ``-x``, ``~x``" msgstr "``+x``, ``-x``, ``~x``" -#: reference/expressions.rst:1876 +#: reference/expressions.rst:1875 msgid "Positive, negative, bitwise NOT" msgstr "NOT (positif, négatif, bit à bit)" -#: reference/expressions.rst:1878 +#: reference/expressions.rst:1877 msgid "``*``, ``@``, ``/``, ``//``, ``%``" msgstr "``*``, ``@``, ``/``, ``//``, ``%``" -#: reference/expressions.rst:1878 +#: reference/expressions.rst:1877 msgid "" "Multiplication, matrix multiplication, division, floor division, remainder " "[#]_" @@ -2914,47 +2923,47 @@ msgstr "" "Multiplication, multiplication de matrices, division, division entière, " "reste [#]_" -#: reference/expressions.rst:1882 +#: reference/expressions.rst:1881 msgid "``+``, ``-``" msgstr "``+``, ``-``" -#: reference/expressions.rst:1882 +#: reference/expressions.rst:1881 msgid "Addition and subtraction" msgstr "Addition et soustraction" -#: reference/expressions.rst:1884 +#: reference/expressions.rst:1883 msgid "``<<``, ``>>``" msgstr "``<<``, ``>>``" -#: reference/expressions.rst:1884 +#: reference/expressions.rst:1883 msgid "Shifts" msgstr "décalages" -#: reference/expressions.rst:1886 +#: reference/expressions.rst:1885 msgid "``&``" msgstr "``&``" -#: reference/expressions.rst:1886 +#: reference/expressions.rst:1885 msgid "Bitwise AND" msgstr "AND (bit à bit)" -#: reference/expressions.rst:1888 +#: reference/expressions.rst:1887 msgid "``^``" msgstr "``^``" -#: reference/expressions.rst:1888 +#: reference/expressions.rst:1887 msgid "Bitwise XOR" msgstr "XOR (bit à bit)" -#: reference/expressions.rst:1890 +#: reference/expressions.rst:1889 msgid "``|``" msgstr "``|``" -#: reference/expressions.rst:1890 +#: reference/expressions.rst:1889 msgid "Bitwise OR" msgstr "OR (bit à bit)" -#: reference/expressions.rst:1892 +#: reference/expressions.rst:1891 msgid "" ":keyword:`in`, :keyword:`not in`, :keyword:`is`, :keyword:`is not`, ``<``, " "``<=``, ``>``, ``>=``, ``!=``, ``==``" @@ -2962,64 +2971,64 @@ msgstr "" ":keyword:`in`, :keyword:`not in`, :keyword:`is`, :keyword:`is not`, ``<``, " "``<=``, ``>``, ``>=``, ``!=``, ``==``" -#: reference/expressions.rst:1892 +#: reference/expressions.rst:1891 msgid "Comparisons, including membership tests and identity tests" msgstr "" "Comparaisons, y compris les tests d'appartenance et les tests d'identifiants" -#: reference/expressions.rst:1896 +#: reference/expressions.rst:1895 msgid ":keyword:`not` ``x``" msgstr ":keyword:`not` ``x``" -#: reference/expressions.rst:1896 +#: reference/expressions.rst:1895 msgid "Boolean NOT" msgstr "NOT (booléen)" -#: reference/expressions.rst:1898 +#: reference/expressions.rst:1897 msgid ":keyword:`and`" msgstr ":keyword:`and`" -#: reference/expressions.rst:1898 +#: reference/expressions.rst:1897 msgid "Boolean AND" msgstr "AND (booléen)" -#: reference/expressions.rst:1900 +#: reference/expressions.rst:1899 msgid ":keyword:`or`" msgstr ":keyword:`or`" -#: reference/expressions.rst:1900 +#: reference/expressions.rst:1899 msgid "Boolean OR" msgstr "OR (booléen)" -#: reference/expressions.rst:1902 +#: reference/expressions.rst:1901 msgid ":keyword:`if ` -- :keyword:`!else`" msgstr ":keyword:`if ` -- :keyword:`!else`" -#: reference/expressions.rst:1902 +#: reference/expressions.rst:1901 msgid "Conditional expression" msgstr "Expressions conditionnelles" -#: reference/expressions.rst:1904 +#: reference/expressions.rst:1903 msgid ":keyword:`lambda`" msgstr ":keyword:`lambda`" -#: reference/expressions.rst:1904 +#: reference/expressions.rst:1903 msgid "Lambda expression" msgstr "Expression lambda" -#: reference/expressions.rst:1906 +#: reference/expressions.rst:1905 msgid "``:=``" msgstr "``:=``" -#: reference/expressions.rst:1906 +#: reference/expressions.rst:1905 msgid "Assignment expression" msgstr "Expression d'affectation" -#: reference/expressions.rst:1911 +#: reference/expressions.rst:1910 msgid "Footnotes" msgstr "Notes" -#: reference/expressions.rst:1912 +#: reference/expressions.rst:1911 msgid "" "While ``abs(x%y) < abs(y)`` is true mathematically, for floats it may not be " "true numerically due to roundoff. For example, and assuming a platform on " @@ -3040,7 +3049,7 @@ msgstr "" "argument, c'est-à-dire ``-1e-100`` dans ce cas. La meilleure approche dépend " "de l'application." -#: reference/expressions.rst:1921 +#: reference/expressions.rst:1920 msgid "" "If x is very close to an exact integer multiple of y, it's possible for ``x//" "y`` to be one larger than ``(x-x%y)//y`` due to rounding. In such cases, " @@ -3052,7 +3061,7 @@ msgstr "" "Dans de tels cas, Python renvoie le second résultat afin d'avoir ``divmod(x," "y)[0] * y + x % y`` le plus proche de ``x``." -#: reference/expressions.rst:1926 +#: reference/expressions.rst:1925 msgid "" "The Unicode standard distinguishes between :dfn:`code points` (e.g. U+0041) " "and :dfn:`abstract characters` (e.g. \"LATIN CAPITAL LETTER A\"). While most " @@ -3077,7 +3086,7 @@ msgstr "" "*U+0043* (LATIN CAPITAL LETTER C) du code, suivi par un :dfn:`caractère " "combiné` à la position *U+0327* (*COMBINING CEDILLA*) du code." -#: reference/expressions.rst:1937 +#: reference/expressions.rst:1936 msgid "" "The comparison operators on strings compare at the level of Unicode code " "points. This may be counter-intuitive to humans. For example, ``\"\\u00C7\" " @@ -3090,7 +3099,7 @@ msgstr "" "chaînes représentent le même caractère abstrait \"LATIN CAPITAL LETTER C " "WITH CEDILLA\"." -#: reference/expressions.rst:1942 +#: reference/expressions.rst:1941 msgid "" "To compare strings at the level of abstract characters (that is, in a way " "intuitive to humans), use :func:`unicodedata.normalize`." @@ -3099,7 +3108,7 @@ msgstr "" "quelque chose d'intuitif pour les humains), utilisez :func:`unicodedata." "normalize`." -#: reference/expressions.rst:1945 +#: reference/expressions.rst:1944 msgid "" "Due to automatic garbage-collection, free lists, and the dynamic nature of " "descriptors, you may notice seemingly unusual behaviour in certain uses of " @@ -3112,7 +3121,7 @@ msgstr "" "cela implique des comparaisons entre des méthodes d'instances ou des " "constantes. Allez vérifier dans la documentation pour plus d'informations." -#: reference/expressions.rst:1950 +#: reference/expressions.rst:1949 msgid "" "The power operator ``**`` binds less tightly than an arithmetic or bitwise " "unary operator on its right, that is, ``2**-1`` is ``0.5``." @@ -3120,7 +3129,7 @@ msgstr "" "L'opérateur puissance ``**`` est moins prioritaire qu'un opérateur unaire " "arithmétique ou bit à bit sur sa droite. Ainsi, ``2**-1`` vaut ``0.5``." -#: reference/expressions.rst:1953 +#: reference/expressions.rst:1952 msgid "" "The ``%`` operator is also used for string formatting; the same precedence " "applies." diff --git a/reference/lexical_analysis.po b/reference/lexical_analysis.po index 840a435a..0f9bcdcc 100644 --- a/reference/lexical_analysis.po +++ b/reference/lexical_analysis.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-10-21 15:04+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-04-10 17:40+0200\n" "Last-Translator: Samuel Giffard \n" "Language-Team: FRENCH \n" @@ -715,12 +715,14 @@ msgstr "" "lexicales suivantes :" #: reference/lexical_analysis.rst:471 +#, fuzzy msgid "" "One syntactic restriction not indicated by these productions is that " -"whitespace is not allowed between the :token:`stringprefix` or :token:" -"`bytesprefix` and the rest of the literal. The source character set is " -"defined by the encoding declaration; it is UTF-8 if no encoding declaration " -"is given in the source file; see section :ref:`encodings`." +"whitespace is not allowed between the :token:`~python-grammar:stringprefix` " +"or :token:`~python-grammar:bytesprefix` and the rest of the literal. The " +"source character set is defined by the encoding declaration; it is UTF-8 if " +"no encoding declaration is given in the source file; see section :ref:" +"`encodings`." msgstr "" "Une restriction syntaxique non indiquée par ces règles est qu'aucun blanc " "n'est autorisé entre le :token:`stringprefix` ou :token:`bytesprefix` et le " diff --git a/tutorial/controlflow.po b/tutorial/controlflow.po index 3a2a49bc..f67dfdfa 100644 --- a/tutorial/controlflow.po +++ b/tutorial/controlflow.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-10-16 23:16+0200\n" "Last-Translator: Jean Abou Samra \n" "Language-Team: FRENCH \n" @@ -442,11 +442,12 @@ msgstr "" "ignorant le reste." #: tutorial/controlflow.rst:378 +#, fuzzy msgid "" "Mapping patterns: ``{\"bandwidth\": b, \"latency\": l}`` captures the ``" "\"bandwidth\"`` and ``\"latency\"`` values from a dictionary. Unlike " "sequence patterns, extra keys are ignored. An unpacking like ``**rest`` is " -"also supported. (But ``**_`` would be redundant, so it not allowed.)" +"also supported. (But ``**_`` would be redundant, so it is not allowed.)" msgstr "" "Il existe les filtres d'association, qui ressemblent syntaxiquement aux " "dictionnaires. Par exemple, le filtre ``{\"bande_passante\": b, \"latence\": " diff --git a/whatsnew/3.10.po b/whatsnew/3.10.po index 82a50a07..bb76f92b 100644 --- a/whatsnew/3.10.po +++ b/whatsnew/3.10.po @@ -12,7 +12,6 @@ msgstr "" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"Last-Translator: Yannick Gingras \n" "X-Generator: Poedit 2.4.2\n" #: whatsnew/3.10.rst:3 @@ -1828,7 +1827,7 @@ msgstr "" #: whatsnew/3.10.rst:1173 msgid "" -":ref:`importlib.metadata entry points ` now provides a nicer " +":ref:`importlib.metadata entry points ` now provide a nicer " "experience for selecting entry points by group and name through a new :class:" "`importlib.metadata.EntryPoints` class. See the Compatibility Note in the " "docs for more info on the deprecation and usage." diff --git a/whatsnew/3.9.po b/whatsnew/3.9.po index 054b25ac..e6449653 100644 --- a/whatsnew/3.9.po +++ b/whatsnew/3.9.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-09-23 16:16+0200\n" +"POT-Creation-Date: 2021-11-27 10:27+0100\n" "PO-Revision-Date: 2021-10-27 20:52+0200\n" "Last-Translator: Yannick Gingras \n" "Language-Team: FRENCH \n" @@ -1371,7 +1371,7 @@ msgstr "" "pour mesurer la taille d'apogée de parties de code spécifiques (contribution " "de *Huon Wilson* dans :issue:`40630`)." -#: whatsnew/3.9.rst:1485 +#: whatsnew/3.9.rst:1481 msgid "typing" msgstr "*typing*" @@ -1817,7 +1817,7 @@ msgstr "" "Le paramètre *random* de :func:`random.shuffle` est maintenant obsolète " "(contribution de *Raymond Hettinger* dans :issue:`40465`)." -#: whatsnew/3.9.rst:1399 +#: whatsnew/3.9.rst:1395 msgid "Removed" msgstr "Retraits" @@ -2510,7 +2510,7 @@ msgstr "" "la plus efficace d'appeler un objet Python appelable sans aucun argument " "(contribution de *Victor Stinner* dans :issue:`37194`)." -#: whatsnew/3.9.rst:1410 +#: whatsnew/3.9.rst:1406 msgid "Changes in the limited C API (if ``Py_LIMITED_API`` macro is defined):" msgstr "" "Changements dans l'API C limité (si la macro ``Py_LIMITED_API`` est " @@ -2538,7 +2538,7 @@ msgstr "" "``PyObject_INIT()`` et ``PyObject_INIT_VAR()`` deviennent des fonctions " "\"opaques\" régulières pour cacher les détails d'implémentation" -#: whatsnew/3.9.rst:1437 +#: whatsnew/3.9.rst:1433 msgid "(Contributed by Victor Stinner in :issue:`38644` and :issue:`39542`.)" msgstr "" "(contribution de *Victor Stinner* dans :issue:`38644` et :issue:`39542`)." @@ -2726,16 +2726,6 @@ msgstr "" #: whatsnew/3.9.rst:1381 msgid "" -":c:func:`PyType_HasFeature` now always calls :c:func:`PyType_GetFlags`. " -"Previously, it accessed directly the :c:member:`PyTypeObject.tp_flags` " -"member when the limited C API was not used." -msgstr "" -"Maintenant, :c:func:`PyType_HasFeature` appelle toujours :c:func:" -"`PyType_GetFlags`. Précédemment, elle accédait directement au membre :c:" -"member:`PyTypeObject.tp_flags` quand l'API limité C n'était pas utilisé ;" - -#: whatsnew/3.9.rst:1385 -msgid "" ":c:func:`PyObject_GET_WEAKREFS_LISTPTR` macro was converted to a function: " "the macro accessed directly the :c:member:`PyTypeObject.tp_weaklistoffset` " "member." @@ -2744,7 +2734,7 @@ msgstr "" "fonction : la macro accédait directement au membre :c:member:`PyTypeObject." "tp_weaklistoffset` ;" -#: whatsnew/3.9.rst:1389 +#: whatsnew/3.9.rst:1385 msgid "" ":c:func:`PyObject_CheckBuffer` macro was converted to a function: the macro " "accessed directly the :c:member:`PyTypeObject.tp_as_buffer` member." @@ -2752,7 +2742,7 @@ msgstr "" "La macro :c:func:`PyObject_CheckBuffer` a été convertie en fonction : la " "macro accédait directement au membre :c:member:`PyTypeObject.tp_as_buffer` ;" -#: whatsnew/3.9.rst:1392 +#: whatsnew/3.9.rst:1388 msgid "" ":c:func:`PyIndex_Check` is now always declared as an opaque function to hide " "implementation details: removed the ``PyIndex_Check()`` macro. The macro " @@ -2763,11 +2753,11 @@ msgstr "" "``PyIndex_Check()``. La macro accédait directement au membre :c:member:" "`PyTypeObject.tp_as_number`." -#: whatsnew/3.9.rst:1396 +#: whatsnew/3.9.rst:1392 msgid "(See :issue:`40170` for more details.)" msgstr "(Voir :issue:`40170` pour plus de détails.)" -#: whatsnew/3.9.rst:1401 +#: whatsnew/3.9.rst:1397 msgid "" "Excluded ``PyFPE_START_PROTECT()`` and ``PyFPE_END_PROTECT()`` macros of " "``pyfpe.h`` from the limited C API. (Contributed by Victor Stinner in :issue:" @@ -2776,7 +2766,7 @@ msgstr "" "Exclusion des macros ``PyFPE_START_PROTECT()`` et ``PyFPE_END_PROTECT()`` de " "l'API C limité (contribution de *Victor Stinner* dans :issue:`38835`)." -#: whatsnew/3.9.rst:1405 +#: whatsnew/3.9.rst:1401 msgid "" "The ``tp_print`` slot of :ref:`PyTypeObject ` has been " "removed. It was used for printing objects to files in Python 2.7 and before. " @@ -2788,11 +2778,11 @@ msgstr "" "dans les versions précédentes. Depuis Python 3.0, il était ignoré et " "inutilisé (contribution de *Jeroen Demeyer* dans :issue:`36974`)." -#: whatsnew/3.9.rst:1412 +#: whatsnew/3.9.rst:1408 msgid "Excluded the following functions from the limited C API:" msgstr "Exclusion des fonctions suivantes de l'API C limité :" -#: whatsnew/3.9.rst:1414 +#: whatsnew/3.9.rst:1410 msgid "" "``PyThreadState_DeleteCurrent()`` (Contributed by Joannah Nanjekye in :issue:" "`37878`.)" @@ -2800,82 +2790,82 @@ msgstr "" "``PyThreadState_DeleteCurrent()`` (contribution de *Joannah Nanjekye* dans :" "issue:`37878`) ;" -#: whatsnew/3.9.rst:1416 +#: whatsnew/3.9.rst:1412 msgid "``_Py_CheckRecursionLimit``" msgstr "``_Py_CheckRecursionLimit`` ;" -#: whatsnew/3.9.rst:1417 +#: whatsnew/3.9.rst:1413 msgid "``_Py_NewReference()``" msgstr "``_Py_NewReference()`` ;" -#: whatsnew/3.9.rst:1418 +#: whatsnew/3.9.rst:1414 msgid "``_Py_ForgetReference()``" msgstr "``_Py_ForgetReference()`` ;" -#: whatsnew/3.9.rst:1419 +#: whatsnew/3.9.rst:1415 msgid "``_PyTraceMalloc_NewReference()``" msgstr "``_PyTraceMalloc_NewReference()`` ;" -#: whatsnew/3.9.rst:1420 +#: whatsnew/3.9.rst:1416 msgid "``_Py_GetRefTotal()``" msgstr "``_Py_GetRefTotal()`` ;" -#: whatsnew/3.9.rst:1421 +#: whatsnew/3.9.rst:1417 msgid "The trashcan mechanism which never worked in the limited C API." msgstr "" "Le mécanisme *trashcan* qui n'a jamais fonctionné dans l'API C limité ;" -#: whatsnew/3.9.rst:1422 +#: whatsnew/3.9.rst:1418 msgid "``PyTrash_UNWIND_LEVEL``" msgstr "``PyTrash_UNWIND_LEVEL`` ;" -#: whatsnew/3.9.rst:1423 +#: whatsnew/3.9.rst:1419 msgid "``Py_TRASHCAN_BEGIN_CONDITION``" msgstr "``Py_TRASHCAN_BEGIN_CONDITION`` ;" -#: whatsnew/3.9.rst:1424 +#: whatsnew/3.9.rst:1420 msgid "``Py_TRASHCAN_BEGIN``" msgstr "``Py_TRASHCAN_BEGIN`` ;" -#: whatsnew/3.9.rst:1425 +#: whatsnew/3.9.rst:1421 msgid "``Py_TRASHCAN_END``" msgstr "``Py_TRASHCAN_END`` ;" -#: whatsnew/3.9.rst:1426 +#: whatsnew/3.9.rst:1422 msgid "``Py_TRASHCAN_SAFE_BEGIN``" msgstr "``Py_TRASHCAN_SAFE_BEGIN`` ;" -#: whatsnew/3.9.rst:1427 +#: whatsnew/3.9.rst:1423 msgid "``Py_TRASHCAN_SAFE_END``" msgstr "``Py_TRASHCAN_SAFE_END``." -#: whatsnew/3.9.rst:1429 +#: whatsnew/3.9.rst:1425 msgid "Moved following functions and definitions to the internal C API:" msgstr "" "Migration des fonctions et définitions suivantes vers l'API C interne :" -#: whatsnew/3.9.rst:1431 +#: whatsnew/3.9.rst:1427 msgid "``_PyDebug_PrintTotalRefs()``" msgstr "``_PyDebug_PrintTotalRefs()`` ;" -#: whatsnew/3.9.rst:1432 +#: whatsnew/3.9.rst:1428 msgid "``_Py_PrintReferences()``" msgstr "``_Py_PrintReferences()`` ;" -#: whatsnew/3.9.rst:1433 +#: whatsnew/3.9.rst:1429 msgid "``_Py_PrintReferenceAddresses()``" msgstr "``_Py_PrintReferenceAddresses()`` ;" -#: whatsnew/3.9.rst:1434 +#: whatsnew/3.9.rst:1430 msgid "``_Py_tracemalloc_config``" msgstr "``_Py_tracemalloc_config`` ;" -#: whatsnew/3.9.rst:1435 +#: whatsnew/3.9.rst:1431 msgid "``_Py_AddToAllObjects()`` (specific to ``Py_TRACE_REFS`` build)" msgstr "" "``_Py_AddToAllObjects()`` (spécifique aux compilations ``Py_TRACE_REFS``)." -#: whatsnew/3.9.rst:1439 +#: whatsnew/3.9.rst:1435 msgid "" "Removed ``_PyRuntime.getframe`` hook and removed ``_PyThreadState_GetFrame`` " "macro which was an alias to ``_PyRuntime.getframe``. They were only exposed " @@ -2888,7 +2878,7 @@ msgstr "" "type ``PyThreadFrameGetter`` (contribution de *Victor Stinner* dans :issue:" "`39946`)." -#: whatsnew/3.9.rst:1444 +#: whatsnew/3.9.rst:1440 msgid "" "Removed the following functions from the C API. Call :c:func:`PyGC_Collect` " "explicitly to clear all free lists. (Contributed by Inada Naoki and Victor " @@ -2899,31 +2889,31 @@ msgstr "" "Naoki* et *Victor Stinner* dans :issue:`37340`, :issue:`38896` et :issue:" "`40428`) :" -#: whatsnew/3.9.rst:1449 +#: whatsnew/3.9.rst:1445 msgid "``PyAsyncGen_ClearFreeLists()``" msgstr "``PyAsyncGen_ClearFreeLists()`` ;" -#: whatsnew/3.9.rst:1450 +#: whatsnew/3.9.rst:1446 msgid "``PyContext_ClearFreeList()``" msgstr "``PyContext_ClearFreeList()`` ;" -#: whatsnew/3.9.rst:1451 +#: whatsnew/3.9.rst:1447 msgid "``PyDict_ClearFreeList()``" msgstr "``PyDict_ClearFreeList()`` ;" -#: whatsnew/3.9.rst:1452 +#: whatsnew/3.9.rst:1448 msgid "``PyFloat_ClearFreeList()``" msgstr "``PyFloat_ClearFreeList()`` ;" -#: whatsnew/3.9.rst:1453 +#: whatsnew/3.9.rst:1449 msgid "``PyFrame_ClearFreeList()``" msgstr "``PyFrame_ClearFreeList()`` ;" -#: whatsnew/3.9.rst:1454 +#: whatsnew/3.9.rst:1450 msgid "``PyList_ClearFreeList()``" msgstr "``PyList_ClearFreeList()`` ;" -#: whatsnew/3.9.rst:1455 +#: whatsnew/3.9.rst:1451 msgid "" "``PyMethod_ClearFreeList()`` and ``PyCFunction_ClearFreeList()``: the free " "lists of bound method objects have been removed." @@ -2931,18 +2921,18 @@ msgstr "" "``PyMethod_ClearFreeList()`` et ``PyCFunction_ClearFreeList()`` : les *free " "lists* des objets méthode liées ont été retirées ;" -#: whatsnew/3.9.rst:1457 +#: whatsnew/3.9.rst:1453 msgid "" "``PySet_ClearFreeList()``: the set free list has been removed in Python 3.4." msgstr "" "``PySet_ClearFreeList()`` : la *free list* des objets *sets* a été retirée " "dans Python 3.4 ;" -#: whatsnew/3.9.rst:1459 +#: whatsnew/3.9.rst:1455 msgid "``PyTuple_ClearFreeList()``" msgstr "``PyTuple_ClearFreeList()`` ;" -#: whatsnew/3.9.rst:1460 +#: whatsnew/3.9.rst:1456 msgid "" "``PyUnicode_ClearFreeList()``: the Unicode free list has been removed in " "Python 3.3." @@ -2950,7 +2940,7 @@ msgstr "" "``PyUnicode_ClearFreeList()`` : la *free list* des objets Unicode a été " "retirée dans Python 3.3." -#: whatsnew/3.9.rst:1463 +#: whatsnew/3.9.rst:1459 msgid "" "Removed ``_PyUnicode_ClearStaticStrings()`` function. (Contributed by Victor " "Stinner in :issue:`39465`.)" @@ -2959,7 +2949,7 @@ msgstr "" "*Victor Stinner* dans :issue:`39465`)." # Féminin puisque Py_UNICODE_MATCH est une macro. -#: whatsnew/3.9.rst:1466 +#: whatsnew/3.9.rst:1462 msgid "" "Removed ``Py_UNICODE_MATCH``. It has been deprecated by :pep:`393`, and " "broken since Python 3.3. The :c:func:`PyUnicode_Tailmatch` function can be " @@ -2970,7 +2960,7 @@ msgstr "" "`PyUnicode_Tailmatch` peut être utilisée à sa place (contribution de *Inada " "Naoki* dans :issue:`36346`)." -#: whatsnew/3.9.rst:1471 +#: whatsnew/3.9.rst:1467 msgid "" "Cleaned header files of interfaces defined but with no implementation. The " "public API symbols being removed are: " @@ -2992,11 +2982,11 @@ msgstr "" "``PyNoArgsFunction`` (contribution de *Pablo Galindo Salgado* dans :issue:" "`39372`)." -#: whatsnew/3.9.rst:1482 +#: whatsnew/3.9.rst:1478 msgid "Notable changes in Python 3.9.1" msgstr "Changements importants dans Python 3.9.1" -#: whatsnew/3.9.rst:1487 +#: whatsnew/3.9.rst:1483 msgid "" "The behavior of :class:`typing.Literal` was changed to conform with :pep:" "`586` and to match the behavior of static type checkers specified in the PEP." @@ -3005,18 +2995,18 @@ msgstr "" "avec :pep:`586` et pour avoir le comportement des vérificateurs de types " "statique spécifiés dans le PEP :" -#: whatsnew/3.9.rst:1490 +#: whatsnew/3.9.rst:1486 msgid "``Literal`` now de-duplicates parameters." msgstr "``Literal`` de-duplique maintenant les paramètres ;" -#: whatsnew/3.9.rst:1491 +#: whatsnew/3.9.rst:1487 msgid "" "Equality comparisons between ``Literal`` objects are now order independent." msgstr "" "Les comparaisons d'égalité entre les objets ``Literal`` sont maintenant " "indépendantes de l'ordre ;" -#: whatsnew/3.9.rst:1492 +#: whatsnew/3.9.rst:1488 msgid "" "``Literal`` comparisons now respect types. For example, ``Literal[0] == " "Literal[False]`` previously evaluated to ``True``. It is now ``False``. To " @@ -3028,7 +3018,7 @@ msgstr "" "C'est maintenant ``False``. Pour gérer ce changement, le cache interne des " "types utilisés peut maintenant différentier les types ;" -#: whatsnew/3.9.rst:1496 +#: whatsnew/3.9.rst:1492 msgid "" "``Literal`` objects will now raise a :exc:`TypeError` exception during " "equality comparisons if any of their parameters are not :term:`hashable`. " @@ -3040,16 +3030,16 @@ msgstr "" "term:`immuable `. Prenez-note que déclarer un ``Literal`` avec un " "paramètre muable ne lève pas une erreur ::" -#: whatsnew/3.9.rst:1508 +#: whatsnew/3.9.rst:1504 msgid "(Contributed by Yurii Karabas in :issue:`42345`.)" msgstr "(Contribution de *Yurii Karabas* dans :issue:`42345`.)" -#: whatsnew/3.9.rst:1511 +#: whatsnew/3.9.rst:1507 msgid "macOS 11.0 (Big Sur) and Apple Silicon Mac support" msgstr "" "Prise en charge de *macOS* 11.0 (Big Sur) et de Mac sur processeur Apple" -#: whatsnew/3.9.rst:1513 +#: whatsnew/3.9.rst:1509 msgid "" "As of 3.9.1, Python now fully supports building and running on macOS 11.0 " "(Big Sur) and on Apple Silicon Macs (based on the ``ARM64`` architecture). A " @@ -3061,20 +3051,20 @@ msgid "" "version in use at runtime (\"weaklinking\")." msgstr "" -#: whatsnew/3.9.rst:1522 +#: whatsnew/3.9.rst:1518 msgid "(Contributed by Ronald Oussoren and Lawrence D'Anna in :issue:`41100`.)" msgstr "" "(contribution de *Ronald Oussoren* et *Lawrence D'Anna* dans :issue:`41100`)." -#: whatsnew/3.9.rst:1525 +#: whatsnew/3.9.rst:1521 msgid "Notable changes in Python 3.9.2" msgstr "Changements importants dans Python 3.9.2" -#: whatsnew/3.9.rst:1528 +#: whatsnew/3.9.rst:1524 msgid "collections.abc" msgstr "*collections.abc*" -#: whatsnew/3.9.rst:1530 +#: whatsnew/3.9.rst:1526 msgid "" ":class:`collections.abc.Callable` generic now flattens type parameters, " "similar to what :data:`typing.Callable` currently does. This means that " @@ -3090,11 +3080,11 @@ msgid "" "Python 3.10. (Contributed by Ken Jin in :issue:`42195`.)" msgstr "" -#: whatsnew/3.9.rst:1544 +#: whatsnew/3.9.rst:1540 msgid "urllib.parse" msgstr "*urllib.parse*" -#: whatsnew/3.9.rst:1546 +#: whatsnew/3.9.rst:1542 msgid "" "Earlier Python versions allowed using both ``;`` and ``&`` as query " "parameter separators in :func:`urllib.parse.parse_qs` and :func:`urllib." @@ -3115,6 +3105,15 @@ msgstr "" "Pour plus de détails, voir leur documentation respective (contribution de " "*Adam Goldschmidt*, *Senthil Kumaran* et *Ken Jin* dans :issue:`42967`)." +#~ msgid "" +#~ ":c:func:`PyType_HasFeature` now always calls :c:func:`PyType_GetFlags`. " +#~ "Previously, it accessed directly the :c:member:`PyTypeObject.tp_flags` " +#~ "member when the limited C API was not used." +#~ msgstr "" +#~ "Maintenant, :c:func:`PyType_HasFeature` appelle toujours :c:func:" +#~ "`PyType_GetFlags`. Précédemment, elle accédait directement au membre :c:" +#~ "member:`PyTypeObject.tp_flags` quand l'API limité C n'était pas utilisé ;" + #~ msgid "" #~ "This article explains the new features in Python 3.9, compared to 3.8." #~ msgstr ""