From a623a8d3bee13104cab19053607a122c9c90166b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cristi=C3=A1n=20Maureira-Fredes?= Date: Sat, 14 Jan 2023 17:52:21 +0100 Subject: [PATCH 1/5] Traducido reference/datamodel Closes #1901 --- dictionaries/reference_datamodel.txt | 3 +- reference/datamodel.po | 3175 +++++++++++++------------- 2 files changed, 1600 insertions(+), 1578 deletions(-) diff --git a/dictionaries/reference_datamodel.txt b/dictionaries/reference_datamodel.txt index 7c3677fd9b..1aefc2b7b2 100644 --- a/dictionaries/reference_datamodel.txt +++ b/dictionaries/reference_datamodel.txt @@ -1,3 +1,4 @@ +awaitable +empaquetándolos objects zero -awaitable diff --git a/reference/datamodel.po b/reference/datamodel.po index 64c12cf1b1..a5a9e873bc 100644 --- a/reference/datamodel.po +++ b/reference/datamodel.po @@ -13,12 +13,12 @@ msgstr "" "POT-Creation-Date: 2022-10-25 19:47+0200\n" "PO-Revision-Date: 2021-12-09 23:44-0300\n" "Last-Translator: Cristián Maureira-Fredes \n" -"Language: es\n" "Language-Team: python-doc-es\n" -"Plural-Forms: nplurals=2; plural=(n != 1);\n" +"Language: es\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=utf-8\n" "Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" "Generated-By: Babel 2.10.3\n" #: ../Doc/reference/datamodel.rst:6 @@ -37,9 +37,9 @@ msgid "" "computer\", code is also represented by objects.)" msgstr "" ":dfn:`Objects` son la abstracción de Python para los datos. Todos los datos " -"en un programa Python están representados por objetos o por relaciones entre " -"objetos. (En cierto sentido y de conformidad con el modelo de Von Neumann de " -"una \"programa almacenado de computadora\", el código también está " +"en un programa Python están representados por objetos o por relaciones entre" +" objetos. (En cierto sentido y de conformidad con el modelo de Von Neumann " +"de una \"programa almacenado de computadora\", el código también está " "representado por objetos.)" #: ../Doc/reference/datamodel.rst:35 @@ -51,10 +51,10 @@ msgid "" "identity." msgstr "" "Cada objeto tiene una identidad, un tipo y un valor. La *identidad* de un " -"objeto nunca cambia una vez que ha sido creado; puede pensar en ello como la " -"dirección del objeto en la memoria. El operador ':keyword:`is`' compara la " -"identidad de dos objetos; la función :func:`id` retorna un número entero que " -"representa su identidad." +"objeto nunca cambia una vez que ha sido creado; puede pensar en ello como la" +" dirección del objeto en la memoria. El operador ':keyword:`is`' compara la " +"identidad de dos objetos; la función :func:`id` retorna un número entero que" +" representa su identidad." #: ../Doc/reference/datamodel.rst:42 msgid "For CPython, ``id(x)`` is the memory address where ``x`` is stored." @@ -64,16 +64,16 @@ msgstr "" #: ../Doc/reference/datamodel.rst:44 msgid "" "An object's type determines the operations that the object supports (e.g., " -"\"does it have a length?\") and also defines the possible values for objects " -"of that type. The :func:`type` function returns an object's type (which is " -"an object itself). Like its identity, an object's :dfn:`type` is also " +"\"does it have a length?\") and also defines the possible values for objects" +" of that type. The :func:`type` function returns an object's type (which is" +" an object itself). Like its identity, an object's :dfn:`type` is also " "unchangeable. [#]_" msgstr "" "El tipo de un objeto determina las operaciones que admite el objeto (por " "ejemplo, \"¿tiene una longitud?\") y también define los posibles valores " "para los objetos de ese tipo. La función :func:`type` retorna el tipo de un " -"objeto (que es un objeto en sí mismo). Al igual que su identidad, también " -"el :dfn:`type` de un objeto es inmutable. [#]_" +"objeto (que es un objeto en sí mismo). Al igual que su identidad, también el" +" :dfn:`type` de un objeto es inmutable. [#]_" #: ../Doc/reference/datamodel.rst:50 msgid "" @@ -83,8 +83,8 @@ msgid "" "that contains a reference to a mutable object can change when the latter's " "value is changed; however the container is still considered immutable, " "because the collection of objects it contains cannot be changed. So, " -"immutability is not strictly the same as having an unchangeable value, it is " -"more subtle.) An object's mutability is determined by its type; for " +"immutability is not strictly the same as having an unchangeable value, it is" +" more subtle.) An object's mutability is determined by its type; for " "instance, numbers, strings and tuples are immutable, while dictionaries and " "lists are mutable." msgstr "" @@ -97,8 +97,8 @@ msgstr "" "que contiene no se puede cambiar. Por lo tanto, la inmutabilidad no es " "estrictamente lo mismo que tener un valor inmutable, es más sutil). La " "mutabilidad de un objeto está determinada por su tipo; por ejemplo, los " -"números, las cadenas de caracteres y las tuplas son inmutables, mientras que " -"los diccionarios y las listas son mutables." +"números, las cadenas de caracteres y las tuplas son inmutables, mientras que" +" los diccionarios y las listas son mutables." #: ../Doc/reference/datamodel.rst:65 msgid "" @@ -110,10 +110,10 @@ msgid "" msgstr "" "Los objetos nunca se destruyen explícitamente; sin embargo, cuando se " "vuelven inalcanzables, se pueden recolectar basura. Se permite a una " -"implementación posponer la recolección de basura u omitirla por completo; es " -"una cuestión de calidad de la implementación cómo se implementa la " -"recolección de basura, siempre que no se recolecten objetos que todavía sean " -"accesibles." +"implementación posponer la recolección de basura u omitirla por completo; es" +" una cuestión de calidad de la implementación cómo se implementa la " +"recolección de basura, siempre que no se recolecten objetos que todavía sean" +" accesibles." #: ../Doc/reference/datamodel.rst:73 msgid "" @@ -146,35 +146,36 @@ msgstr "" "Tenga en cuenta que el uso de las funciones de rastreo o depuración de la " "implementación puede mantener activos los objetos que normalmente serían " "coleccionables. También tenga en cuenta que la captura de una excepción con " -"una sentencia ':keyword:`try`...\\ :keyword:`except`' puede mantener objetos " -"activos." +"una sentencia ':keyword:`try`...\\ :keyword:`except`' puede mantener objetos" +" activos." #: ../Doc/reference/datamodel.rst:87 msgid "" -"Some objects contain references to \"external\" resources such as open files " -"or windows. It is understood that these resources are freed when the object " -"is garbage-collected, but since garbage collection is not guaranteed to " -"happen, such objects also provide an explicit way to release the external " -"resource, usually a :meth:`close` method. Programs are strongly recommended " -"to explicitly close such objects. The ':keyword:`try`...\\ :keyword:" -"`finally`' statement and the ':keyword:`with`' statement provide convenient " -"ways to do this." +"Some objects contain references to \"external\" resources such as open files" +" or windows. It is understood that these resources are freed when the " +"object is garbage-collected, but since garbage collection is not guaranteed " +"to happen, such objects also provide an explicit way to release the external" +" resource, usually a :meth:`close` method. Programs are strongly recommended" +" to explicitly close such objects. The ':keyword:`try`...\\ " +":keyword:`finally`' statement and the ':keyword:`with`' statement provide " +"convenient ways to do this." msgstr "" "Algunos objetos contienen referencias a recursos \"externos\" como archivos " "abiertos o ventanas. Se entiende que estos recursos se liberan cuando el " "objeto es eliminado por el recolector de basura, pero como no se garantiza " -"que la recolección de basura suceda, dichos objetos también proporcionan una " -"forma explícita de liberar el recurso externo, generalmente un método :meth:" -"`close`. Se recomienda encarecidamente a los programas cerrar explícitamente " -"dichos objetos. La declaración ':keyword:`try`...\\ :keyword:`finally`' y la " -"declaración ':keyword:`with`' proporcionan formas convenientes de hacer esto." +"que la recolección de basura suceda, dichos objetos también proporcionan una" +" forma explícita de liberar el recurso externo, generalmente un método " +":meth:`close`. Se recomienda encarecidamente a los programas cerrar " +"explícitamente dichos objetos. La declaración ':keyword:`try`...\\ " +":keyword:`finally`' y la declaración ':keyword:`with`' proporcionan formas " +"convenientes de hacer esto." #: ../Doc/reference/datamodel.rst:97 msgid "" "Some objects contain references to other objects; these are called " "*containers*. Examples of containers are tuples, lists and dictionaries. " -"The references are part of a container's value. In most cases, when we talk " -"about the value of a container, we imply the values, not the identities of " +"The references are part of a container's value. In most cases, when we talk" +" about the value of a container, we imply the values, not the identities of " "the contained objects; however, when we talk about the mutability of a " "container, only the identities of the immediately contained objects are " "implied. So, if an immutable container (like a tuple) contains a reference " @@ -196,9 +197,9 @@ msgid "" "object identity is affected in some sense: for immutable types, operations " "that compute new values may actually return a reference to any existing " "object with the same type and value, while for mutable objects this is not " -"allowed. E.g., after ``a = 1; b = 1``, ``a`` and ``b`` may or may not refer " -"to the same object with the value one, depending on the implementation, but " -"after ``c = []; d = []``, ``c`` and ``d`` are guaranteed to refer to two " +"allowed. E.g., after ``a = 1; b = 1``, ``a`` and ``b`` may or may not refer" +" to the same object with the value one, depending on the implementation, but" +" after ``c = []; d = []``, ``c`` and ``d`` are guaranteed to refer to two " "different, unique, newly created empty lists. (Note that ``c = d = []`` " "assigns the same object to both ``c`` and ``d``.)" msgstr "" @@ -208,11 +209,11 @@ msgstr "" "valores en realidad pueden retornar una referencia a cualquier objeto " "existente con el mismo tipo y valor, mientras que para los objetos mutables " "esto no está permitido. Por ejemplo, al hacer ``a = 1; b = 1``, ``a`` y " -"``b`` puede o no referirse al mismo objeto con el valor 1, dependiendo de la " -"implementación, pero al hacer ``c = []; d = []``, ``c`` y ``d`` se garantiza " -"que se refieren a dos listas vacías diferentes, únicas y recién creadas. " -"(Tenga en cuenta que ``c = d = []`` asigna el mismo objeto a ambos ``c`` y " -"``d``.)" +"``b`` puede o no referirse al mismo objeto con el valor 1, dependiendo de la" +" implementación, pero al hacer ``c = []; d = []``, ``c`` y ``d`` se " +"garantiza que se refieren a dos listas vacías diferentes, únicas y recién " +"creadas. (Tenga en cuenta que ``c = d = []`` asigna el mismo objeto a ambos " +"``c`` y ``d``.)" #: ../Doc/reference/datamodel.rst:120 msgid "The standard type hierarchy" @@ -222,24 +223,24 @@ msgstr "Jerarquía de tipos estándar" msgid "" "Below is a list of the types that are built into Python. Extension modules " "(written in C, Java, or other languages, depending on the implementation) " -"can define additional types. Future versions of Python may add types to the " -"type hierarchy (e.g., rational numbers, efficiently stored arrays of " +"can define additional types. Future versions of Python may add types to the" +" type hierarchy (e.g., rational numbers, efficiently stored arrays of " "integers, etc.), although such additions will often be provided via the " "standard library instead." msgstr "" "A continuación se muestra una lista de los tipos integrados en Python. Los " "módulos de extensión (escritos en C, Java u otros lenguajes, dependiendo de " "la implementación) pueden definir tipos adicionales. Las versiones futuras " -"de Python pueden agregar tipos a la jerarquía de tipos (por ejemplo, números " -"racionales, matrices de enteros almacenados de manera eficiente, etc.), " +"de Python pueden agregar tipos a la jerarquía de tipos (por ejemplo, números" +" racionales, matrices de enteros almacenados de manera eficiente, etc.), " "aunque tales adiciones a menudo se proporcionarán a través de la biblioteca " "estándar." #: ../Doc/reference/datamodel.rst:140 msgid "" "Some of the type descriptions below contain a paragraph listing 'special " -"attributes.' These are attributes that provide access to the implementation " -"and are not intended for general use. Their definition may change in the " +"attributes.' These are attributes that provide access to the implementation" +" and are not intended for general use. Their definition may change in the " "future." msgstr "" "Algunas de las descripciones de tipos a continuación contienen un párrafo " @@ -255,8 +256,8 @@ msgstr "None" msgid "" "This type has a single value. There is a single object with this value. " "This object is accessed through the built-in name ``None``. It is used to " -"signify the absence of a value in many situations, e.g., it is returned from " -"functions that don't explicitly return anything. Its truth value is false." +"signify the absence of a value in many situations, e.g., it is returned from" +" functions that don't explicitly return anything. Its truth value is false." msgstr "" "Este tipo tiene un solo valor. Hay un solo objeto con este valor. Se accede " "a este objeto a través del nombre incorporado ``None``. Se utiliza para " @@ -272,10 +273,10 @@ msgstr "NotImplemented" msgid "" "This type has a single value. There is a single object with this value. " "This object is accessed through the built-in name ``NotImplemented``. " -"Numeric methods and rich comparison methods should return this value if they " -"do not implement the operation for the operands provided. (The interpreter " -"will then try the reflected operation, or some other fallback, depending on " -"the operator.) It should not be evaluated in a boolean context." +"Numeric methods and rich comparison methods should return this value if they" +" do not implement the operation for the operands provided. (The interpreter" +" will then try the reflected operation, or some other fallback, depending on" +" the operator.) It should not be evaluated in a boolean context." msgstr "" "Este tipo tiene un solo valor. Hay un solo objeto con este valor. Se accede " "a este objeto a través del nombre integrado ``NotImplemented``. Los métodos " @@ -296,9 +297,9 @@ msgid "" "will raise a :exc:`TypeError` in a future version of Python." msgstr "" "La evaluación de ``NotImplemented`` en un contexto booleano está en desuso. " -"Si bien actualmente se evalúa como verdadero, lanzará un :exc:" -"`DeprecationWarning`. Lanzará un :exc:`TypeError` en una versión futura de " -"Python." +"Si bien actualmente se evalúa como verdadero, lanzará un " +":exc:`DeprecationWarning`. Lanzará un :exc:`TypeError` en una versión futura" +" de Python." #: ../Doc/reference/datamodel.rst:179 msgid "Ellipsis" @@ -321,8 +322,8 @@ msgstr ":class:`numbers.Number`" #: ../Doc/reference/datamodel.rst:184 msgid "" "These are created by numeric literals and returned as results by arithmetic " -"operators and arithmetic built-in functions. Numeric objects are immutable; " -"once created their value never changes. Python numbers are of course " +"operators and arithmetic built-in functions. Numeric objects are immutable;" +" once created their value never changes. Python numbers are of course " "strongly related to mathematical numbers, but subject to the limitations of " "numerical representation in computers." msgstr "" @@ -334,14 +335,14 @@ msgstr "" "numérica en las computadoras." #: ../Doc/reference/datamodel.rst:190 -#, fuzzy msgid "" -"The string representations of the numeric classes, computed by :meth:" -"`~object.__repr__` and :meth:`~object.__str__`, have the following " +"The string representations of the numeric classes, computed by " +":meth:`~object.__repr__` and :meth:`~object.__str__`, have the following " "properties:" msgstr "" -"Las representaciones de cadena de las clases numéricas, calculadas por :meth:" -"`__repr__` y :meth:`__str__`, tienen las siguientes propiedades:" +"Las representaciones de cadena de las clases numéricas, calculadas por " +":meth:`~object.__repr__` y :meth:`~object.__str__`, tienen las siguientes " +"propiedades:" #: ../Doc/reference/datamodel.rst:194 msgid "" @@ -389,8 +390,8 @@ msgstr ":class:`numbers.Integral`" #: ../Doc/reference/datamodel.rst:214 msgid "" -"These represent elements from the mathematical set of integers (positive and " -"negative)." +"These represent elements from the mathematical set of integers (positive and" +" negative)." msgstr "" "Estos representan elementos del conjunto matemático de números enteros " "(positivo y negativo)." @@ -424,18 +425,18 @@ msgstr "Booleanos (:class:`bool`)" #: ../Doc/reference/datamodel.rst:232 msgid "" "These represent the truth values False and True. The two objects " -"representing the values ``False`` and ``True`` are the only Boolean objects. " -"The Boolean type is a subtype of the integer type, and Boolean values behave " -"like the values 0 and 1, respectively, in almost all contexts, the exception " -"being that when converted to a string, the strings ``\"False\"`` or " -"``\"True\"`` are returned, respectively." +"representing the values ``False`` and ``True`` are the only Boolean objects." +" The Boolean type is a subtype of the integer type, and Boolean values " +"behave like the values 0 and 1, respectively, in almost all contexts, the " +"exception being that when converted to a string, the strings ``\"False\"`` " +"or ``\"True\"`` are returned, respectively." msgstr "" "Estos representan los valores de verdad Falso y Verdadero. Los dos objetos " "que representan los valores ``False`` y ``True`` son los únicos objetos " "booleanos. El tipo booleano es un subtipo del tipo entero y los valores " -"booleanos se comportan como los valores 0 y 1 respectivamente, en casi todos " -"los contextos, con la excepción de que cuando se convierten en una cadena de " -"caracteres, las cadenas de caracteres ``\"False\"`` o ``\"True\"`` son " +"booleanos se comportan como los valores 0 y 1 respectivamente, en casi todos" +" los contextos, con la excepción de que cuando se convierten en una cadena " +"de caracteres, las cadenas de caracteres ``\"False\"`` o ``\"True\"`` son " "retornadas respectivamente." #: ../Doc/reference/datamodel.rst:240 @@ -456,11 +457,11 @@ msgstr ":class:`numbers.Real` (:class:`float`)" msgid "" "These represent machine-level double precision floating point numbers. You " "are at the mercy of the underlying machine architecture (and C or Java " -"implementation) for the accepted range and handling of overflow. Python does " -"not support single-precision floating point numbers; the savings in " +"implementation) for the accepted range and handling of overflow. Python does" +" not support single-precision floating point numbers; the savings in " "processor and memory usage that are usually the reason for using these are " -"dwarfed by the overhead of using objects in Python, so there is no reason to " -"complicate the language with two kinds of floating point numbers." +"dwarfed by the overhead of using objects in Python, so there is no reason to" +" complicate the language with two kinds of floating point numbers." msgstr "" "Estos representan números de punto flotante de precisión doble a nivel de " "máquina. Está a merced de la arquitectura de la máquina subyacente (y la " @@ -484,8 +485,8 @@ msgid "" msgstr "" "Estos representan números complejos como un par de números de coma flotante " "de precisión doble a nivel de máquina. Se aplican las mismas advertencias " -"que para los números de coma flotante. Las partes reales e imaginarias de un " -"número complejo ``z`` se pueden obtener a través de los atributos de solo " +"que para los números de coma flotante. Las partes reales e imaginarias de un" +" número complejo ``z`` se pueden obtener a través de los atributos de solo " "lectura ``z.real`` y ``z.imag``." #: ../Doc/reference/datamodel.rst:383 @@ -500,9 +501,9 @@ msgid "" "1, ..., *n*-1. Item *i* of sequence *a* is selected by ``a[i]``." msgstr "" "Estos representan conjuntos ordenados finitos indexados por números no " -"negativos. La función incorporada :func:`len` retorna el número de elementos " -"de una secuencia. Cuando la longitud de una secuencia es *n*, el conjunto de " -"índices contiene los números 0, 1, ..., *n*-1. El elemento *i* de la " +"negativos. La función incorporada :func:`len` retorna el número de elementos" +" de una secuencia. Cuando la longitud de una secuencia es *n*, el conjunto " +"de índices contiene los números 0, 1, ..., *n*-1. El elemento *i* de la " "secuencia *a* se selecciona mediante ``a[i]``." #: ../Doc/reference/datamodel.rst:283 @@ -512,11 +513,11 @@ msgid "" "a sequence of the same type. This implies that the index set is renumbered " "so that it starts at 0." msgstr "" -"Las secuencias también admiten segmentación: ``a[i:j]`` selecciona todos los " -"elementos con índice *k* de modo que *i* ``<=`` *k* ``<`` *j*. Cuando se " +"Las secuencias también admiten segmentación: ``a[i:j]`` selecciona todos los" +" elementos con índice *k* de modo que *i* ``<=`` *k* ``<`` *j*. Cuando se " "usa como una expresión, un segmento es una secuencia del mismo tipo. Esto " -"implica que el conjunto de índices se vuelve a enumerar para que comience en " -"0." +"implica que el conjunto de índices se vuelve a enumerar para que comience en" +" 0." #: ../Doc/reference/datamodel.rst:288 msgid "" @@ -540,15 +541,15 @@ msgstr "Secuencias inmutables" #: ../Doc/reference/datamodel.rst:299 msgid "" "An object of an immutable sequence type cannot change once it is created. " -"(If the object contains references to other objects, these other objects may " -"be mutable and may be changed; however, the collection of objects directly " +"(If the object contains references to other objects, these other objects may" +" be mutable and may be changed; however, the collection of objects directly " "referenced by an immutable object cannot change.)" msgstr "" "Un objeto de un tipo de secuencia inmutable no puede cambiar una vez que se " "crea. (Si el objeto contiene referencias a otros objetos, estos otros " -"objetos pueden ser mutables y pueden cambiarse; sin embargo, la colección de " -"objetos a los que hace referencia directamente un objeto inmutable no puede " -"cambiar)." +"objetos pueden ser mutables y pueden cambiarse; sin embargo, la colección de" +" objetos a los que hace referencia directamente un objeto inmutable no puede" +" cambiar)." #: ../Doc/reference/datamodel.rst:304 msgid "The following types are immutable sequences:" @@ -560,17 +561,28 @@ msgstr "Cadenas de caracteres" #: ../Doc/reference/datamodel.rst:317 msgid "" -"A string is a sequence of values that represent Unicode code points. All the " -"code points in the range ``U+0000 - U+10FFFF`` can be represented in a " +"A string is a sequence of values that represent Unicode code points. All the" +" code points in the range ``U+0000 - U+10FFFF`` can be represented in a " "string. Python doesn't have a :c:expr:`char` type; instead, every code " "point in the string is represented as a string object with length ``1``. " -"The built-in function :func:`ord` converts a code point from its string form " -"to an integer in the range ``0 - 10FFFF``; :func:`chr` converts an integer " -"in the range ``0 - 10FFFF`` to the corresponding length ``1`` string " -"object. :meth:`str.encode` can be used to convert a :class:`str` to :class:" -"`bytes` using the given text encoding, and :meth:`bytes.decode` can be used " -"to achieve the opposite." -msgstr "" +"The built-in function :func:`ord` converts a code point from its string form" +" to an integer in the range ``0 - 10FFFF``; :func:`chr` converts an integer " +"in the range ``0 - 10FFFF`` to the corresponding length ``1`` string object." +" :meth:`str.encode` can be used to convert a :class:`str` to :class:`bytes` " +"using the given text encoding, and :meth:`bytes.decode` can be used to " +"achieve the opposite." +msgstr "" +"Una cadena es una secuencia de valores que representan puntos de código " +"Unicode. Todos los puntos de código en el rango ``U+0000 - U+10FFFF`` se " +"pueden representar en una cadena. Python no tiene un tipo :c:expr:`char`; en" +" su lugar, cada punto de código de la cadena se representa como un objeto de" +" cadena con una longitud ``1``. La función integrada :func:`ord` convierte " +"un punto de código de su forma de cadena a un entero en el rango ``0 - " +"10FFFF``; :func:`chr` convierte un entero en el rango ``0 - 10FFFF`` al " +"objeto de cadena ``1`` de longitud correspondiente. :meth:`str.encode` se " +"puede usar para convertir un :class:`str` a :class:`bytes` usando la " +"codificación de texto dada, y :meth:`bytes.decode` se puede usar para lograr" +" lo contrario." #: ../Doc/reference/datamodel.rst:340 msgid "Tuples" @@ -601,15 +613,15 @@ msgid "" "A bytes object is an immutable array. The items are 8-bit bytes, " "represented by integers in the range 0 <= x < 256. Bytes literals (like " "``b'abc'``) and the built-in :func:`bytes()` constructor can be used to " -"create bytes objects. Also, bytes objects can be decoded to strings via " -"the :meth:`~bytes.decode` method." +"create bytes objects. Also, bytes objects can be decoded to strings via the" +" :meth:`~bytes.decode` method." msgstr "" "Un objeto de bytes es una colección inmutable. Los elementos son bytes de 8 " "bits, representados por enteros en el rango 0 <= x <256. Literales de bytes " "(como ``b'abc'``) y el constructor incorporado :func:`bytes()` se puede " -"utilizar para crear objetos de bytes. Además, los objetos de bytes se pueden " -"decodificar en cadenas de caracteres a través del método :meth:`~bytes." -"decode`." +"utilizar para crear objetos de bytes. Además, los objetos de bytes se pueden" +" decodificar en cadenas de caracteres a través del método " +":meth:`~bytes.decode`." #: ../Doc/reference/datamodel.rst:383 msgid "Mutable sequences" @@ -618,8 +630,8 @@ msgstr "Secuencias mutables" #: ../Doc/reference/datamodel.rst:359 msgid "" "Mutable sequences can be changed after they are created. The subscription " -"and slicing notations can be used as the target of assignment and :keyword:" -"`del` (delete) statements." +"and slicing notations can be used as the target of assignment and " +":keyword:`del` (delete) statements." msgstr "" "Las secuencias mutables se pueden cambiar después de su creación. Las " "anotaciones de suscripción y segmentación se pueden utilizar como el " @@ -636,11 +648,11 @@ msgstr "Listas" #: ../Doc/reference/datamodel.rst:368 msgid "" "The items of a list are arbitrary Python objects. Lists are formed by " -"placing a comma-separated list of expressions in square brackets. (Note that " -"there are no special cases needed to form lists of length 0 or 1.)" +"placing a comma-separated list of expressions in square brackets. (Note that" +" there are no special cases needed to form lists of length 0 or 1.)" msgstr "" -"Los elementos de una lista son objetos de Python arbitrarios. Las listas se " -"forman colocando una lista de expresiones separadas por comas entre " +"Los elementos de una lista son objetos de Python arbitrarios. Las listas se" +" forman colocando una lista de expresiones separadas por comas entre " "corchetes. (Tome en cuenta que no hay casos especiales necesarios para " "formar listas de longitud 0 o 1.)" @@ -650,13 +662,13 @@ msgstr "Colecciones de bytes" #: ../Doc/reference/datamodel.rst:375 msgid "" -"A bytearray object is a mutable array. They are created by the built-in :" -"func:`bytearray` constructor. Aside from being mutable (and hence " +"A bytearray object is a mutable array. They are created by the built-in " +":func:`bytearray` constructor. Aside from being mutable (and hence " "unhashable), byte arrays otherwise provide the same interface and " "functionality as immutable :class:`bytes` objects." msgstr "" -"Un objeto bytearray es una colección mutable. Son creados por el constructor " -"incorporado :func:`bytearray`. Además de ser mutables (y, por lo tanto, " +"Un objeto bytearray es una colección mutable. Son creados por el constructor" +" incorporado :func:`bytearray`. Además de ser mutables (y, por lo tanto, " "inquebrantable), las colecciones de bytes proporcionan la misma interfaz y " "funcionalidad que los objetos inmutables :class:`bytes`." @@ -675,11 +687,11 @@ msgstr "Tipos de conjuntos" #: ../Doc/reference/datamodel.rst:390 msgid "" "These represent unordered, finite sets of unique, immutable objects. As " -"such, they cannot be indexed by any subscript. However, they can be iterated " -"over, and the built-in function :func:`len` returns the number of items in a " -"set. Common uses for sets are fast membership testing, removing duplicates " -"from a sequence, and computing mathematical operations such as intersection, " -"union, difference, and symmetric difference." +"such, they cannot be indexed by any subscript. However, they can be iterated" +" over, and the built-in function :func:`len` returns the number of items in " +"a set. Common uses for sets are fast membership testing, removing duplicates" +" from a sequence, and computing mathematical operations such as " +"intersection, union, difference, and symmetric difference." msgstr "" "Estos representan conjuntos finitos no ordenados de objetos únicos e " "inmutables. Como tal, no pueden ser indexados por ningún *subscript*. Sin " @@ -692,15 +704,15 @@ msgstr "" #: ../Doc/reference/datamodel.rst:397 msgid "" "For set elements, the same immutability rules apply as for dictionary keys. " -"Note that numeric types obey the normal rules for numeric comparison: if two " -"numbers compare equal (e.g., ``1`` and ``1.0``), only one of them can be " +"Note that numeric types obey the normal rules for numeric comparison: if two" +" numbers compare equal (e.g., ``1`` and ``1.0``), only one of them can be " "contained in a set." msgstr "" "Para elementos del conjunto, se aplican las mismas reglas de inmutabilidad " "que para las claves de diccionario. Tenga en cuenta que los tipos numéricos " -"obedecen las reglas normales para la comparación numérica: si dos números se " -"comparan igual (por ejemplo, ``1`` y ``1.0``), solo uno de ellos puede estar " -"contenido en un conjunto." +"obedecen las reglas normales para la comparación numérica: si dos números se" +" comparan igual (por ejemplo, ``1`` y ``1.0``), solo uno de ellos puede " +"estar contenido en un conjunto." #: ../Doc/reference/datamodel.rst:402 msgid "There are currently two intrinsic set types:" @@ -713,8 +725,8 @@ msgstr "Conjuntos" #: ../Doc/reference/datamodel.rst:407 msgid "" "These represent a mutable set. They are created by the built-in :func:`set` " -"constructor and can be modified afterwards by several methods, such as :meth:" -"`~set.add`." +"constructor and can be modified afterwards by several methods, such as " +":meth:`~set.add`." msgstr "" "Estos representan un conjunto mutable. Son creados por el constructor " "incorporado :func:`set` y puede ser modificado posteriormente por varios " @@ -726,14 +738,15 @@ msgstr "Conjuntos congelados" #: ../Doc/reference/datamodel.rst:414 msgid "" -"These represent an immutable set. They are created by the built-in :func:" -"`frozenset` constructor. As a frozenset is immutable and :term:`hashable`, " -"it can be used again as an element of another set, or as a dictionary key." +"These represent an immutable set. They are created by the built-in " +":func:`frozenset` constructor. As a frozenset is immutable and " +":term:`hashable`, it can be used again as an element of another set, or as a" +" dictionary key." msgstr "" "Estos representan un conjunto inmutable. Son creados por el constructor " -"incorporado :func:`frozenset`. Como un conjunto congelado es inmutable y :" -"term:`hashable`, se puede usar nuevamente como un elemento de otro conjunto " -"o como una clave de un diccionario." +"incorporado :func:`frozenset`. Como un conjunto congelado es inmutable y " +":term:`hashable`, se puede usar nuevamente como un elemento de otro conjunto" +" o como una clave de un diccionario." #: ../Doc/reference/datamodel.rst:464 msgid "Mappings" @@ -750,9 +763,9 @@ msgstr "" "Estos representan conjuntos finitos de objetos indexados por conjuntos de " "índices arbitrarios. La notación de subíndice ``a[k]`` selecciona el " "elemento indexado por ``k`` del mapeo ``a``; esto se puede usar en " -"expresiones y como el objetivo de asignaciones o declaraciones :keyword:" -"`del`. La función incorporada :func:`len` retorna el número de elementos en " -"un mapeo." +"expresiones y como el objetivo de asignaciones o declaraciones " +":keyword:`del`. La función incorporada :func:`len` retorna el número de " +"elementos en un mapeo." #: ../Doc/reference/datamodel.rst:431 msgid "There is currently a single intrinsic mapping type:" @@ -777,29 +790,29 @@ msgstr "" "arbitrarios. Los únicos tipos de valores no aceptables como claves son " "valores que contienen listas o diccionarios u otros tipos mutables que se " "comparan por valor en lugar de por identidad de objeto, la razón es que la " -"implementación eficiente de los diccionarios requiere que el valor *hash* de " -"una clave permanezca constante. Los tipos numéricos utilizados para las " +"implementación eficiente de los diccionarios requiere que el valor *hash* de" +" una clave permanezca constante. Los tipos numéricos utilizados para las " "claves obedecen las reglas normales para la comparación numérica: si dos " "números se comparan igual (por ejemplo, ``1`` y ``1.0``) entonces se pueden " "usar indistintamente para indexar la misma entrada del diccionario." #: ../Doc/reference/datamodel.rst:445 msgid "" -"Dictionaries preserve insertion order, meaning that keys will be produced in " -"the same order they were added sequentially over the dictionary. Replacing " +"Dictionaries preserve insertion order, meaning that keys will be produced in" +" the same order they were added sequentially over the dictionary. Replacing " "an existing key does not change the order, however removing a key and re-" "inserting it will add it to the end instead of keeping its old place." msgstr "" "Los diccionarios conservan el orden de inserción, lo que significa que las " "claves se mantendrán en el mismo orden en que se agregaron secuencialmente " -"sobre el diccionario. Reemplazar una clave existente no cambia el orden, sin " -"embargo, eliminar una clave y volver a insertarla la agregará al final en " +"sobre el diccionario. Reemplazar una clave existente no cambia el orden, sin" +" embargo, eliminar una clave y volver a insertarla la agregará al final en " "lugar de mantener su lugar anterior." #: ../Doc/reference/datamodel.rst:450 msgid "" -"Dictionaries are mutable; they can be created by the ``{...}`` notation (see " -"section :ref:`dict`)." +"Dictionaries are mutable; they can be created by the ``{...}`` notation (see" +" section :ref:`dict`)." msgstr "" "Los diccionarios son mutables; pueden ser creados por la notación ``{...}`` " "(vea la sección :ref:`dict`)." @@ -810,14 +823,14 @@ msgid "" "examples of mapping types, as does the :mod:`collections` module." msgstr "" "Los módulos de extensión :mod:`dbm.ndbm` y :mod:`dbm.gnu` proporcionan " -"ejemplos adicionales de tipos de mapeo, al igual que el módulo :mod:" -"`collections`." +"ejemplos adicionales de tipos de mapeo, al igual que el módulo " +":mod:`collections`." #: ../Doc/reference/datamodel.rst:461 msgid "" "Dictionaries did not preserve insertion order in versions of Python before " -"3.6. In CPython 3.6, insertion order was preserved, but it was considered an " -"implementation detail at that time rather than a language guarantee." +"3.6. In CPython 3.6, insertion order was preserved, but it was considered an" +" implementation detail at that time rather than a language guarantee." msgstr "" "Los diccionarios no conservaban el orden de inserción en las versiones de " "Python anteriores a 3.6. En CPython 3.6, el orden de inserción se conserva, " @@ -830,8 +843,8 @@ msgstr "Tipos invocables" #: ../Doc/reference/datamodel.rst:473 msgid "" -"These are the types to which the function call operation (see section :ref:" -"`calls`) can be applied:" +"These are the types to which the function call operation (see section " +":ref:`calls`) can be applied:" msgstr "" "Estos son los tipos a los que la operación de llamada de función (vea la " "sección :ref:`calls`) puede ser aplicado:" @@ -939,8 +952,8 @@ msgstr ":attr:`__globals__`" #: ../Doc/reference/datamodel.rst:533 msgid "" -"A reference to the dictionary that holds the function's global variables --- " -"the global namespace of the module in which the function was defined." +"A reference to the dictionary that holds the function's global variables ---" +" the global namespace of the module in which the function was defined." msgstr "" "Una referencia al diccionario que contiene las variables globales de la " "función --- el espacio de nombres global del módulo en el que se definió la " @@ -1003,17 +1016,17 @@ msgid "" "Most of the attributes labelled \"Writable\" check the type of the assigned " "value." msgstr "" -"La mayoría de los atributos etiquetados \"Escribible\" verifican el tipo del " -"valor asignado." +"La mayoría de los atributos etiquetados \"Escribible\" verifican el tipo del" +" valor asignado." #: ../Doc/reference/datamodel.rst:567 msgid "" "Function objects also support getting and setting arbitrary attributes, " "which can be used, for example, to attach metadata to functions. Regular " "attribute dot-notation is used to get and set such attributes. *Note that " -"the current implementation only supports function attributes on user-defined " -"functions. Function attributes on built-in functions may be supported in the " -"future.*" +"the current implementation only supports function attributes on user-defined" +" functions. Function attributes on built-in functions may be supported in " +"the future.*" msgstr "" "Los objetos de función también admiten la obtención y configuración de " "atributos arbitrarios, que se pueden usar, por ejemplo, para adjuntar " @@ -1034,13 +1047,14 @@ msgstr "" #: ../Doc/reference/datamodel.rst:576 msgid "" "Additional information about a function's definition can be retrieved from " -"its code object; see the description of internal types below. The :data:" -"`cell ` type can be accessed in the :mod:`types` module." +"its code object; see the description of internal types below. The " +":data:`cell ` type can be accessed in the :mod:`types` " +"module." msgstr "" "Se puede recuperar información adicional sobre la definición de una función " "desde su objeto de código; Vea la descripción de los tipos internos a " -"continuación. El tipo :data:`cell ` puede ser accedido en el " -"módulo :mod:`types`." +"continuación. El tipo :data:`cell ` puede ser accedido en el" +" módulo :mod:`types`." #: ../Doc/reference/datamodel.rst:642 msgid "Instance methods" @@ -1051,24 +1065,26 @@ msgid "" "An instance method object combines a class, a class instance and any " "callable object (normally a user-defined function)." msgstr "" -"Un objeto de método de instancia combina una clase, una instancia de clase y " -"cualquier objeto invocable (normalmente una función definida por el usuario)." +"Un objeto de método de instancia combina una clase, una instancia de clase y" +" cualquier objeto invocable (normalmente una función definida por el " +"usuario)." #: ../Doc/reference/datamodel.rst:597 msgid "" -"Special read-only attributes: :attr:`__self__` is the class instance " -"object, :attr:`__func__` is the function object; :attr:`__doc__` is the " -"method's documentation (same as ``__func__.__doc__``); :attr:`~definition." -"__name__` is the method name (same as ``__func__.__name__``); :attr:" -"`__module__` is the name of the module the method was defined in, or " -"``None`` if unavailable." +"Special read-only attributes: :attr:`__self__` is the class instance object," +" :attr:`__func__` is the function object; :attr:`__doc__` is the method's " +"documentation (same as ``__func__.__doc__``); :attr:`~definition.__name__` " +"is the method name (same as ``__func__.__name__``); :attr:`__module__` is " +"the name of the module the method was defined in, or ``None`` if " +"unavailable." msgstr "" "Atributos especiales de solo lectura: :attr:`__self__` es el objeto de " -"instancia de clase, :attr:`__func__` es el objeto de función; :attr:" -"`__doc__` es la documentación del método (al igual que ``__func__." -"__doc__``); :attr:`~definition.__name__` es el nombre del método (al igual " -"que ``__func__.__name__``); :attr:`__module__` es el nombre del módulo en el " -"que el método fue definido, o ``None`` si no se encuentra disponible." +"instancia de clase, :attr:`__func__` es el objeto de función; " +":attr:`__doc__` es la documentación del método (al igual que " +"``__func__.__doc__``); :attr:`~definition.__name__` es el nombre del método " +"(al igual que ``__func__.__name__``); :attr:`__module__` es el nombre del " +"módulo en el que el método fue definido, o ``None`` si no se encuentra " +"disponible." #: ../Doc/reference/datamodel.rst:603 msgid "" @@ -1099,35 +1115,36 @@ msgstr "" "Cuando un objeto de instancia de método es creado al obtener un objeto de " "función definida por el usuario desde una clase a través de una de sus " "instancias, su atributo :attr:`__self__` es la instancia, y el objeto de " -"método se dice que está enlazado. El nuevo atributo de método :attr:" -"`__func__` es el objeto de función original." +"método se dice que está enlazado. El nuevo atributo de método " +":attr:`__func__` es el objeto de función original." #: ../Doc/reference/datamodel.rst:616 msgid "" "When an instance method object is created by retrieving a class method " -"object from a class or instance, its :attr:`__self__` attribute is the class " -"itself, and its :attr:`__func__` attribute is the function object underlying " -"the class method." +"object from a class or instance, its :attr:`__self__` attribute is the class" +" itself, and its :attr:`__func__` attribute is the function object " +"underlying the class method." msgstr "" "Cuando un objeto de instancia de método es creado al obtener un objeto de " -"método de clase a partir de una clase o instancia, su atributo :attr:" -"`__self__` es la clase misma, y su atributo :attr:`__func__` es el objeto de " -"función subyacente al método de la clase." +"método de clase a partir de una clase o instancia, su atributo " +":attr:`__self__` es la clase misma, y su atributo :attr:`__func__` es el " +"objeto de función subyacente al método de la clase." #: ../Doc/reference/datamodel.rst:621 msgid "" -"When an instance method object is called, the underlying function (:attr:" -"`__func__`) is called, inserting the class instance (:attr:`__self__`) in " -"front of the argument list. For instance, when :class:`C` is a class which " -"contains a definition for a function :meth:`f`, and ``x`` is an instance of :" -"class:`C`, calling ``x.f(1)`` is equivalent to calling ``C.f(x, 1)``." +"When an instance method object is called, the underlying function " +"(:attr:`__func__`) is called, inserting the class instance " +"(:attr:`__self__`) in front of the argument list. For instance, when " +":class:`C` is a class which contains a definition for a function :meth:`f`, " +"and ``x`` is an instance of :class:`C`, calling ``x.f(1)`` is equivalent to " +"calling ``C.f(x, 1)``." msgstr "" "Cuando el objeto de la instancia de método es invocado, la función " -"subyacente (:attr:`__func__`) es llamada, insertando la instancia de clase (:" -"attr:`__self__`) delante de la lista de argumentos. Por ejemplo, cuando :" -"class:`C` es una clase que contiene la definición de una función :meth:`f`, " -"y ``x`` es una instancia de :class:`C`, invocar ``x.f(1)`` es equivalente a " -"invocar ``C.f(x, 1)``." +"subyacente (:attr:`__func__`) es llamada, insertando la instancia de clase " +"(:attr:`__self__`) delante de la lista de argumentos. Por ejemplo, cuando " +":class:`C` es una clase que contiene la definición de una función :meth:`f`," +" y ``x`` es una instancia de :class:`C`, invocar ``x.f(1)`` es equivalente a" +" invocar ``C.f(x, 1)``." #: ../Doc/reference/datamodel.rst:628 msgid "" @@ -1136,10 +1153,10 @@ msgid "" "itself, so that calling either ``x.f(1)`` or ``C.f(1)`` is equivalent to " "calling ``f(C,1)`` where ``f`` is the underlying function." msgstr "" -"Cuando el objeto de instancia de método es derivado del objeto del método de " -"clase, la “instancia de clase” almacenada en :attr:`__self__` en realidad " -"será la clase misma, de manera que invocar ya sea ``x.f(1)`` o ``C.f(1)`` es " -"equivalente a invocar ``f(C,1)`` donde ``f`` es la función subyacente." +"Cuando el objeto de instancia de método es derivado del objeto del método de" +" clase, la “instancia de clase” almacenada en :attr:`__self__` en realidad " +"será la clase misma, de manera que invocar ya sea ``x.f(1)`` o ``C.f(1)`` es" +" equivalente a invocar ``f(C,1)`` donde ``f`` es la función subyacente." #: ../Doc/reference/datamodel.rst:633 msgid "" @@ -1147,14 +1164,14 @@ msgid "" "happens each time the attribute is retrieved from the instance. In some " "cases, a fruitful optimization is to assign the attribute to a local " "variable and call that local variable. Also notice that this transformation " -"only happens for user-defined functions; other callable objects (and all non-" -"callable objects) are retrieved without transformation. It is also " +"only happens for user-defined functions; other callable objects (and all " +"non-callable objects) are retrieved without transformation. It is also " "important to note that user-defined functions which are attributes of a " "class instance are not converted to bound methods; this *only* happens when " "the function is an attribute of the class." msgstr "" -"Tome en cuenta que la transformación de objeto de función a objeto de método " -"de instancia ocurre cada vez que el atributo es obtenido de la instancia. " +"Tome en cuenta que la transformación de objeto de función a objeto de método" +" de instancia ocurre cada vez que el atributo es obtenido de la instancia. " "En algunos casos, una optimización fructífera es asignar el atributo a una " "variable local e invocarla. Note también que esta transformación únicamente " "ocurre con funciones definidas por usuario; otros objetos invocables (y " @@ -1169,27 +1186,26 @@ msgid "Generator functions" msgstr "Funciones generadoras" #: ../Doc/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 " +"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 :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 "" -"Una función o método que utiliza la declaración :keyword:`yield` (ver " -"sección :ref:`yield`) se llama :dfn:`generator function`. Dicha función, " -"cuando es invocada, siempre retorna un objeto iterador que puede ser " -"utilizado para ejecutar el cuerpo de la función: invocando el método " -"iterador :meth:`iterator.__next__` hará que la función se ejecute hasta " -"proporcionar un valor utilizando la declaración :keyword:`!yield`. Cuando " -"la función ejecuta una declaración :keyword:`return` o llega hasta el final, " -"una excepción :exc:`StopIteration` es lanzada y el iterador habrá llegado al " -"final del conjunto de valores a ser retornados." +"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 "" +"Una función o método que utiliza la instrucción :keyword:`yield` (consulte " +"la sección :ref:`yield`) se denomina :dfn:`función generadora`. Una función " +"de este tipo, cuando se llama, siempre devuelve un objeto :term:`iterator` " +"que se puede usar para ejecutar el cuerpo de la función: llamar al método " +":meth:`iterator.__next__` del iterador hará que la función se ejecute hasta " +"que proporcione un valor usando la declaración :keyword:`!yield`. Cuando la " +"función ejecuta una declaración :keyword:`return` o se cae del final, se " +"genera una excepción :exc:`StopIteration` y el iterador habrá llegado al " +"final del conjunto de valores que se devolverán." #: ../Doc/reference/datamodel.rst:667 msgid "Coroutine functions" @@ -1197,54 +1213,53 @@ msgstr "Funciones de corrutina" #: ../Doc/reference/datamodel.rst:663 msgid "" -"A function or method which is defined using :keyword:`async def` is called " -"a :dfn:`coroutine function`. Such a function, when called, returns a :term:" -"`coroutine` object. It may contain :keyword:`await` expressions, as well " -"as :keyword:`async with` and :keyword:`async for` statements. See also the :" -"ref:`coroutine-objects` section." +"A function or method which is defined using :keyword:`async def` is called a" +" :dfn:`coroutine function`. Such a function, when called, returns a " +":term:`coroutine` object. It may contain :keyword:`await` expressions, as " +"well as :keyword:`async with` and :keyword:`async for` statements. See also " +"the :ref:`coroutine-objects` section." msgstr "" "Una función o método que es definido utilizando :keyword:`async def` se " -"llama :dfn:`coroutine function`. Dicha función, cuando es invocada, retorna " -"un objeto :term:`coroutine`. Éste puede contener expresiones :keyword:" -"`await`, así como declaraciones :keyword:`async with` y :keyword:`async " -"for`. Ver también la sección :ref:`coroutine-objects`." +"llama :dfn:`coroutine function`. Dicha función, cuando es invocada, retorna" +" un objeto :term:`coroutine`. Éste puede contener expresiones " +":keyword:`await`, así como declaraciones :keyword:`async with` y " +":keyword:`async for`. Ver también la sección :ref:`coroutine-objects`." #: ../Doc/reference/datamodel.rst:687 msgid "Asynchronous generator functions" msgstr "Funciones generadoras asincrónicas" #: ../Doc/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 :term:`asynchronous " +"uses the :keyword:`yield` statement is called a :dfn:`asynchronous generator" +" 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 "" -"Una función o método que es definido usando :keyword:`async def` y que " -"utiliza la declaración :keyword:`yield` se llama :dfn:`asynchronous " -"generator function`. Dicha función, al ser invocada, retorna un objeto " -"iterador asincrónico que puede ser utilizado en una declaración :keyword:" -"`async for` para ejecutar el cuerpo de la función." +"Una función o método que se define utilizando :keyword:`async def` y que " +"utiliza la instrucción :keyword:`yield` se denomina :dfn:`función de " +"generador asíncrono`. Cuando se llama a una función de este tipo, devuelve " +"un objeto :term:`asynchronous iterator` que se puede utilizar en una " +"instrucción :keyword:`async for` para ejecutar el cuerpo de la función." #: ../Doc/reference/datamodel.rst:680 -#, fuzzy -msgid "" -"Calling the asynchronous iterator's :meth:`aiterator.__anext__ ` method will return an :term:`awaitable` which when awaited will " -"execute until it provides a value using the :keyword:`yield` expression. " -"When the function executes an empty :keyword:`return` statement or falls off " -"the end, a :exc:`StopAsyncIteration` exception is raised and the " -"asynchronous iterator will have reached the end of the set of values to be " -"yielded." -msgstr "" -"Invocando el método del iterador asincrónico :meth:`aiterator.__anext__` " -"retornará un :term:`awaitable` que al ser esperado se ejecutará hasta " -"proporcionar un valor utilizando la expresión :keyword:`yield`. Cuando la " -"función ejecuta una declaración :keyword:`return` vacía o llega a su final, " -"una excepción :exc:`StopAsyncIteration` es lanzada y el iterador asincrónico " -"habrá llegado al final del conjunto de valores a ser producidos." +msgid "" +"Calling the asynchronous iterator's :meth:`aiterator.__anext__ " +"` method will return an :term:`awaitable` which when " +"awaited will execute until it provides a value using the :keyword:`yield` " +"expression. When the function executes an empty :keyword:`return` statement" +" or falls off the end, a :exc:`StopAsyncIteration` exception is raised and " +"the asynchronous iterator will have reached the end of the set of values to " +"be yielded." +msgstr "" +"Llamar al método :meth:`aiterator.__anext__ ` del iterador" +" asíncrono devolverá un :term:`awaitable` que, cuando se espera, se " +"ejecutará hasta que proporcione un valor mediante la expresión " +":keyword:`yield`. Cuando la función ejecuta una declaración " +":keyword:`return` vacía o se cae del final, se genera una excepción " +":exc:`StopAsyncIteration` y el iterador asíncrono habrá llegado al final del" +" conjunto de valores que se generarán." #: ../Doc/reference/datamodel.rst:702 msgid "Built-in functions" @@ -1256,21 +1271,21 @@ msgid "" "built-in functions are :func:`len` and :func:`math.sin` (:mod:`math` is a " "standard built-in module). The number and type of the arguments are " "determined by the C function. Special read-only attributes: :attr:`__doc__` " -"is the function's documentation string, or ``None`` if unavailable; :attr:" -"`~definition.__name__` is the function's name; :attr:`__self__` is set to " -"``None`` (but see the next item); :attr:`__module__` is the name of the " +"is the function's documentation string, or ``None`` if unavailable; " +":attr:`~definition.__name__` is the function's name; :attr:`__self__` is set" +" to ``None`` (but see the next item); :attr:`__module__` is the name of the " "module the function was defined in or ``None`` if unavailable." msgstr "" -"Un objeto de función incorporada es un envoltorio (wrapper) alrededor de una " -"función C. Ejemplos de funciones incorporadas son :func:`len` y :func:`math." -"sin` (:mod:`math` es un módulo estándar incorporado). El número y tipo de " -"argumentos son determinados por la función C. Atributos especiales de solo " -"lectura: :attr:`__doc__` es la cadena de documentación de la función, o " -"``None`` si no se encuentra disponible; :attr:`~definition.__name__` es el " -"nombre de la función; :attr:`__init__` es establecido como ``None`` (sin " -"embargo ver el siguiente elemento); :attr:`__module__` es el nombre del " -"módulo en el que la función fue definida o ``None`` si no se encuentra " -"disponible." +"Un objeto de función incorporada es un envoltorio (wrapper) alrededor de una" +" función C. Ejemplos de funciones incorporadas son :func:`len` y " +":func:`math.sin` (:mod:`math` es un módulo estándar incorporado). El número " +"y tipo de argumentos son determinados por la función C. Atributos especiales" +" de solo lectura: :attr:`__doc__` es la cadena de documentación de la " +"función, o ``None`` si no se encuentra disponible; " +":attr:`~definition.__name__` es el nombre de la función; :attr:`__init__` es" +" establecido como ``None`` (sin embargo ver el siguiente elemento); " +":attr:`__module__` es el nombre del módulo en el que la función fue definida" +" o ``None`` si no se encuentra disponible." #: ../Doc/reference/datamodel.rst:714 msgid "Built-in methods" @@ -1279,10 +1294,10 @@ msgstr "Métodos incorporados" #: ../Doc/reference/datamodel.rst:710 msgid "" "This is really a different disguise of a built-in function, this time " -"containing an object passed to the C function as an implicit extra " -"argument. An example of a built-in method is ``alist.append()``, assuming " -"*alist* is a list object. In this case, the special read-only attribute :" -"attr:`__self__` is set to the object denoted by *alist*." +"containing an object passed to the C function as an implicit extra argument." +" An example of a built-in method is ``alist.append()``, assuming *alist* is" +" a list object. In this case, the special read-only attribute " +":attr:`__self__` is set to the object denoted by *alist*." msgstr "" "Éste es realmente un disfraz distinto de una función incorporada, esta vez " "teniendo un objeto que se pasa a la función C como un argumento extra " @@ -1296,32 +1311,30 @@ msgid "Classes" msgstr "Clases" #: ../Doc/reference/datamodel.rst:717 -#, fuzzy msgid "" "Classes are callable. These objects normally act as factories for new " "instances of themselves, but variations are possible for class types that " -"override :meth:`~object.__new__`. The arguments of the call are passed to :" -"meth:`__new__` and, in the typical case, to :meth:`~object.__init__` to " +"override :meth:`~object.__new__`. The arguments of the call are passed to " +":meth:`__new__` and, in the typical case, to :meth:`~object.__init__` to " "initialize the new instance." msgstr "" -"Las clases son invocables. Estos objetos normalmente actúan como fábricas " -"de nuevas instancias de ellos mismos, pero las variaciones son posibles para " -"los tipos de clases que anulan :meth:`__new__`. Los argumentos de la " -"invocación son pasados a :meth:`__new__` y, en el caso típico, a :meth:" -"`__init__` para iniciar la nueva instancia." +"Las clases son llamables. Estos objetos normalmente actúan como fábricas " +"para nuevas instancias de sí mismos, pero es posible que haya variaciones " +"para los tipos de clase que anulan :meth:`~object.__new__`. Los argumentos " +"de la llamada se pasan a :meth:`__new__` y, en el caso típico, a " +":meth:`~object.__init__` para inicializar la nueva instancia." #: ../Doc/reference/datamodel.rst:726 msgid "Class Instances" msgstr "Instancias de clases" #: ../Doc/reference/datamodel.rst:724 -#, fuzzy msgid "" -"Instances of arbitrary classes can be made callable by defining a :meth:" -"`~object.__call__` method in their class." +"Instances of arbitrary classes can be made callable by defining a " +":meth:`~object.__call__` method in their class." msgstr "" "Las instancias de clases arbitrarias se pueden hacer invocables definiendo " -"el método :meth:`__call__` en su clase." +"un método :meth:`~object.__call__` en su clase." #: ../Doc/reference/datamodel.rst:789 msgid "Modules" @@ -1330,27 +1343,27 @@ msgstr "Módulos" #: ../Doc/reference/datamodel.rst:733 msgid "" "Modules are a basic organizational unit of Python code, and are created by " -"the :ref:`import system ` as invoked either by the :keyword:" -"`import` statement, or by calling functions such as :func:`importlib." -"import_module` and built-in :func:`__import__`. A module object has a " -"namespace implemented by a dictionary object (this is the dictionary " -"referenced by the ``__globals__`` attribute of functions defined in the " -"module). Attribute references are translated to lookups in this dictionary, " -"e.g., ``m.x`` is equivalent to ``m.__dict__[\"x\"]``. A module object does " -"not contain the code object used to initialize the module (since it isn't " -"needed once the initialization is done)." +"the :ref:`import system ` as invoked either by the " +":keyword:`import` statement, or by calling functions such as " +":func:`importlib.import_module` and built-in :func:`__import__`. A module " +"object has a namespace implemented by a dictionary object (this is the " +"dictionary referenced by the ``__globals__`` attribute of functions defined " +"in the module). Attribute references are translated to lookups in this " +"dictionary, e.g., ``m.x`` is equivalent to ``m.__dict__[\"x\"]``. A module " +"object does not contain the code object used to initialize the module (since" +" it isn't needed once the initialization is done)." msgstr "" "Los módulos son una unidad básica organizacional en código Python, y son " "creados por el :ref:`import system ` al ser invocados ya sea " -"por la declaración :keyword:`import`, o invocando funciones como :func:" -"`importlib.import_module` y la incorporada :func:`__import__`. Un objeto de " -"módulo tiene un espacio de nombres implementado por un objeto de diccionario " -"(éste es el diccionario al que hace referencia el atributo de funciones " -"``__globals__`` definido en el módulo). Las referencias de atributos son " -"traducidas a búsquedas en este diccionario, p. ej., ``m.x`` es equivalente a " -"``m.__dict__[“x”]``. Un objeto de módulo no contiene el objeto de código " -"utilizado para iniciar el módulo (ya que no es necesario una vez que la " -"inicialización es realizada)." +"por la declaración :keyword:`import`, o invocando funciones como " +":func:`importlib.import_module` y la incorporada :func:`__import__`. Un " +"objeto de módulo tiene un espacio de nombres implementado por un objeto de " +"diccionario (éste es el diccionario al que hace referencia el atributo de " +"funciones ``__globals__`` definido en el módulo). Las referencias de " +"atributos son traducidas a búsquedas en este diccionario, p. ej., ``m.x`` es" +" equivalente a ``m.__dict__[“x”]``. Un objeto de módulo no contiene el " +"objeto de código utilizado para iniciar el módulo (ya que no es necesario " +"una vez que la inicialización es realizada)." #: ../Doc/reference/datamodel.rst:745 msgid "" @@ -1384,8 +1397,8 @@ msgstr ":attr:`__file__`" #: ../Doc/reference/datamodel.rst:765 msgid "" "The pathname of the file from which the module was loaded, if it was loaded " -"from a file. The :attr:`__file__` attribute may be missing for certain types " -"of modules, such as C modules that are statically linked into the " +"from a file. The :attr:`__file__` attribute may be missing for certain types" +" of modules, such as C modules that are statically linked into the " "interpreter. For extension modules loaded dynamically from a shared " "library, it's the pathname of the shared library file." msgstr "" @@ -1399,13 +1412,13 @@ msgstr "" #: ../Doc/reference/datamodel.rst:774 msgid "" "A dictionary containing :term:`variable annotations ` " -"collected during module body execution. For best practices on working with :" -"attr:`__annotations__`, please see :ref:`annotations-howto`." +"collected during module body execution. For best practices on working with " +":attr:`__annotations__`, please see :ref:`annotations-howto`." msgstr "" "Un diccionario que contiene el :term:`variable annotations ` recopilados durante la ejecución del cuerpo del módulo. Para " -"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve :" -"ref:`annotations-howto`." +"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve " +":ref:`annotations-howto`." #: ../Doc/reference/datamodel.rst:781 msgid "" @@ -1417,16 +1430,16 @@ msgstr "" #: ../Doc/reference/datamodel.rst:786 msgid "" -"Because of the way CPython clears module dictionaries, the module dictionary " -"will be cleared when the module falls out of scope even if the dictionary " +"Because of the way CPython clears module dictionaries, the module dictionary" +" will be cleared when the module falls out of scope even if the dictionary " "still has live references. To avoid this, copy the dictionary or keep the " "module around while using its dictionary directly." msgstr "" "Debido a la manera en la que CPython limpia los diccionarios de módulo, el " "diccionario de módulo será limpiado cuando el módulo se encuentra fuera de " "alcance, incluso si el diccionario aún tiene referencias existentes. Para " -"evitar esto, copie el diccionario o mantenga el módulo cerca mientras usa el " -"diccionario directamente." +"evitar esto, copie el diccionario o mantenga el módulo cerca mientras usa el" +" diccionario directamente." #: ../Doc/reference/datamodel.rst:864 msgid "Custom classes" @@ -1434,18 +1447,18 @@ msgstr "Clases personalizadas" #: ../Doc/reference/datamodel.rst:792 msgid "" -"Custom class types are typically created by class definitions (see section :" -"ref:`class`). A class has a namespace implemented by a dictionary object. " -"Class attribute references are translated to lookups in this dictionary, e." -"g., ``C.x`` is translated to ``C.__dict__[\"x\"]`` (although there are a " +"Custom class types are typically created by class definitions (see section " +":ref:`class`). A class has a namespace implemented by a dictionary object. " +"Class attribute references are translated to lookups in this dictionary, " +"e.g., ``C.x`` is translated to ``C.__dict__[\"x\"]`` (although there are a " "number of hooks which allow for other means of locating attributes). When " -"the attribute name is not found there, the attribute search continues in the " -"base classes. This search of the base classes uses the C3 method resolution " -"order which behaves correctly even in the presence of 'diamond' inheritance " -"structures where there are multiple inheritance paths leading back to a " +"the attribute name is not found there, the attribute search continues in the" +" base classes. This search of the base classes uses the C3 method resolution" +" order which behaves correctly even in the presence of 'diamond' inheritance" +" structures where there are multiple inheritance paths leading back to a " "common ancestor. Additional details on the C3 MRO used by Python can be " -"found in the documentation accompanying the 2.3 release at https://www." -"python.org/download/releases/2.3/mro/." +"found in the documentation accompanying the 2.3 release at " +"https://www.python.org/download/releases/2.3/mro/." msgstr "" "Los tipos de clases personalizadas son normalmente creadas por definiciones " "de clases (ver sección :ref:`class`). Una clase tiene implementado un " @@ -1454,31 +1467,32 @@ msgstr "" "``C.x`` es traducido a ``C.__dict__[“x”]`` (aunque hay una serie de enlaces " "que permiten la ubicación de atributos por otros medios). Cuando el nombre " "de atributo no es encontrado ahí, la búsqueda de atributo continúa en las " -"clases base. Esta búsqueda de las clases base utiliza la orden de resolución " -"de métodos C3 que se comporta correctamente aún en la presencia de " -"estructuras de herencia ‘diamante’ donde existen múltiples rutas de herencia " -"que llevan a un ancestro común. Detalles adicionales en el MRO C3 utilizados " -"por Python pueden ser encontrados en la documentación correspondiente a la " -"versión 2.3 en https://www.python.org/download/releases/2.3/mro/." +"clases base. Esta búsqueda de las clases base utiliza la orden de resolución" +" de métodos C3 que se comporta correctamente aún en la presencia de " +"estructuras de herencia ‘diamante’ donde existen múltiples rutas de herencia" +" que llevan a un ancestro común. Detalles adicionales en el MRO C3 " +"utilizados por Python pueden ser encontrados en la documentación " +"correspondiente a la versión 2.3 en " +"https://www.python.org/download/releases/2.3/mro/." #: ../Doc/reference/datamodel.rst:816 msgid "" "When a class attribute reference (for class :class:`C`, say) would yield a " -"class method object, it is transformed into an instance method object whose :" -"attr:`__self__` attribute is :class:`C`. When it would yield a static " +"class method object, it is transformed into an instance method object whose " +":attr:`__self__` attribute is :class:`C`. When it would yield a static " "method object, it is transformed into the object wrapped by the static " "method object. See section :ref:`descriptors` for another way in which " "attributes retrieved from a class may differ from those actually contained " "in its :attr:`~object.__dict__`." msgstr "" -"Cuando la referencia de un atributo de clase (digamos, para la clase :class:" -"`C`) produce un objeto de método de clase, éste es transformado a un objeto " -"de método de instancia cuyo atributo :attr:`__self__` es :class:`C`. Cuando " -"produce un objeto de un método estático, éste es transformado al objeto " -"envuelto por el objeto de método estático. Ver sección :ref:`descriptors` " -"para otra manera en la que los atributos obtenidos de una clase pueden " -"diferir de los que en realidad están contenidos en su :attr:`~object." -"__dict__`." +"Cuando la referencia de un atributo de clase (digamos, para la clase " +":class:`C`) produce un objeto de método de clase, éste es transformado a un " +"objeto de método de instancia cuyo atributo :attr:`__self__` es :class:`C`." +" Cuando produce un objeto de un método estático, éste es transformado al " +"objeto envuelto por el objeto de método estático. Ver sección " +":ref:`descriptors` para otra manera en la que los atributos obtenidos de una" +" clase pueden diferir de los que en realidad están contenidos en su " +":attr:`~object.__dict__`." #: ../Doc/reference/datamodel.rst:826 msgid "" @@ -1518,11 +1532,11 @@ msgstr ":attr:`~class.__bases__`" #: ../Doc/reference/datamodel.rst:853 msgid "" -"A tuple containing the base classes, in the order of their occurrence in the " -"base class list." +"A tuple containing the base classes, in the order of their occurrence in the" +" base class list." msgstr "" -"Una tupla conteniendo las clases de base, en orden de ocurrencia en la lista " -"de clase base." +"Una tupla conteniendo las clases de base, en orden de ocurrencia en la lista" +" de clase base." #: ../Doc/reference/datamodel.rst:857 msgid "The class's documentation string, or ``None`` if undefined." @@ -1532,20 +1546,19 @@ msgstr "" #: ../Doc/reference/datamodel.rst:860 msgid "" "A dictionary containing :term:`variable annotations ` " -"collected during class body execution. For best practices on working with :" -"attr:`__annotations__`, please see :ref:`annotations-howto`." +"collected during class body execution. For best practices on working with " +":attr:`__annotations__`, please see :ref:`annotations-howto`." msgstr "" "Un diccionario conteniendo el :term:`variable annotations ` recopilados durante la ejecución del cuerpo de la clase. Para " -"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve :" -"ref:`annotations-howto`." +"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve " +":ref:`annotations-howto`." #: ../Doc/reference/datamodel.rst:907 msgid "Class instances" msgstr "Instancias de clase" #: ../Doc/reference/datamodel.rst:873 -#, fuzzy msgid "" "A class instance is created by calling a class object (see above). A class " "instance has a namespace implemented as a dictionary which is the first " @@ -1558,37 +1571,36 @@ msgid "" "\"Classes\". See section :ref:`descriptors` for another way in which " "attributes of a class retrieved via its instances may differ from the " "objects actually stored in the class's :attr:`~object.__dict__`. If no " -"class attribute is found, and the object's class has a :meth:`~object." -"__getattr__` method, that is called to satisfy the lookup." -msgstr "" -"Una instancia de clase es creado al invocar un objeto de clase (ver " -"arriba). Una instancia de clase tiene implementado un espacio de nombres " -"como diccionario que es el primer lugar en el que se buscan referencias de " -"atributos. Cuando un atributo no es encontrado ahí, y la clase de instancia " -"tiene un atributo con ese nombre, la búsqueda continúa con los atributos de " -"clase. Si se encuentra que un atributo de clase es un objeto de función " -"definido por el usuario, es transformado en un objeto de método de instancia " -"cuyo atributo :attr:`__self__` es la instancia. Los objetos de método y " -"método de clase estáticos también son transformados; ver más adelante debajo " -"de “Clases”. Ver sección :ref:`descriptors` para otra forma en la que los " -"atributos de una clase obtenida a través de sus instancias puede diferir de " -"los objetos realmente almacenados en el :attr:`~object.__dict__` de la " -"clase. Si no se encuentra ningún atributo de clase, y la clase del objeto " -"tiene un método :meth:`__getattr__`, éste es llamado para satisfacer la " -"búsqueda." +"class attribute is found, and the object's class has a " +":meth:`~object.__getattr__` method, that is called to satisfy the lookup." +msgstr "" +"Una instancia de clase se crea llamando a un objeto de clase (ver arriba). " +"Una instancia de clase tiene un espacio de nombres implementado como un " +"diccionario que es el primer lugar en el que se buscan las referencias de " +"atributos. Cuando no se encuentra un atributo allí, y la clase de la " +"instancia tiene un atributo con ese nombre, la búsqueda continúa con los " +"atributos de la clase. Si se encuentra un atributo de clase que es un objeto" +" de función definido por el usuario, se transforma en un objeto de método de" +" instancia cuyo atributo :attr:`__self__` es la instancia. Los objetos de " +"método estático y método de clase también se transforman; ver arriba en " +"\"Clases\". Consulte la sección :ref:`descriptors` para conocer otra forma " +"en la que los atributos de una clase recuperados a través de sus instancias " +"pueden diferir de los objetos realmente almacenados en el " +":attr:`~object.__dict__` de la clase. Si no se encuentra ningún atributo de " +"clase y la clase del objeto tiene un método :meth:`~object.__getattr__`, se " +"llama para satisfacer la búsqueda." #: ../Doc/reference/datamodel.rst:889 -#, fuzzy msgid "" "Attribute assignments and deletions update the instance's dictionary, never " -"a class's dictionary. If the class has a :meth:`~object.__setattr__` or :" -"meth:`~object.__delattr__` method, this is called instead of updating the " +"a class's dictionary. If the class has a :meth:`~object.__setattr__` or " +":meth:`~object.__delattr__` method, this is called instead of updating the " "instance dictionary directly." msgstr "" -"Asignación y eliminación de atributos actualizan el diccionario de la " -"instancia, nunca el diccionario de la clase. Si la clase tiene un método :" -"meth:`__setattr__` o :meth:`__delattr__`, éste es invocado en lugar de " -"actualizar el diccionario de la instancia directamente." +"Las asignaciones y eliminaciones de atributos actualizan el diccionario de " +"la instancia, nunca el diccionario de una clase. Si la clase tiene un método" +" :meth:`~object.__setattr__` o :meth:`~object.__delattr__`, se llama a este " +"en lugar de actualizar el diccionario de instancias directamente." #: ../Doc/reference/datamodel.rst:899 msgid "" @@ -1596,13 +1608,13 @@ msgid "" "have methods with certain special names. See section :ref:`specialnames`." msgstr "" "Instancias de clases pueden pretender ser números, secuencias o mapeos si " -"tienen métodos con ciertos nombres especiales. Ver sección :ref:" -"`specialnames`." +"tienen métodos con ciertos nombres especiales. Ver sección " +":ref:`specialnames`." #: ../Doc/reference/datamodel.rst:906 msgid "" -"Special attributes: :attr:`~object.__dict__` is the attribute dictionary; :" -"attr:`~instance.__class__` is the instance's class." +"Special attributes: :attr:`~object.__dict__` is the attribute dictionary; " +":attr:`~instance.__class__` is the instance's class." msgstr "" "Atributos especiales: :attr:`~object.__dict__` es el diccionario de " "atributos; :attr:`~instance.__class__` es la clase de la instancia." @@ -1615,28 +1627,28 @@ msgstr "Objetos E/S (también conocidos como objetos de archivo)" msgid "" "A :term:`file object` represents an open file. Various shortcuts are " "available to create file objects: the :func:`open` built-in function, and " -"also :func:`os.popen`, :func:`os.fdopen`, and the :meth:`~socket.socket." -"makefile` method of socket objects (and perhaps by other functions or " -"methods provided by extension modules)." +"also :func:`os.popen`, :func:`os.fdopen`, and the " +":meth:`~socket.socket.makefile` method of socket objects (and perhaps by " +"other functions or methods provided by extension modules)." msgstr "" "Un :term:`file object` representa un archivo abierto. Diversos accesos " -"directos se encuentran disponibles para crear objetos de archivo: la función " -"incorporada :func:`open`, así como :func:`os.popen`, :func:`os.fdopen`, y el " -"método de objetos socket :meth:`~socket.makefile` (y quizás por otras " +"directos se encuentran disponibles para crear objetos de archivo: la función" +" incorporada :func:`open`, así como :func:`os.popen`, :func:`os.fdopen`, y " +"el método de objetos socket :meth:`~socket.makefile` (y quizás por otras " "funciones y métodos proporcionados por módulos de extensión)." #: ../Doc/reference/datamodel.rst:929 msgid "" -"The objects ``sys.stdin``, ``sys.stdout`` and ``sys.stderr`` are initialized " -"to file objects corresponding to the interpreter's standard input, output " +"The objects ``sys.stdin``, ``sys.stdout`` and ``sys.stderr`` are initialized" +" to file objects corresponding to the interpreter's standard input, output " "and error streams; they are all open in text mode and therefore follow the " "interface defined by the :class:`io.TextIOBase` abstract class." msgstr "" "Los objetos ``sys.stdin``, ``sys.stdout`` y ``sys.stderr`` son iniciados a " "objetos de archivos correspondientes a la entrada y salida estándar del " "intérprete, así como flujos de error; todos ellos están abiertos en el modo " -"de texto y por lo tanto siguen la interface definida por la clase abstracta :" -"class:`io.TextIOBase`." +"de texto y por lo tanto siguen la interface definida por la clase abstracta " +":class:`io.TextIOBase`." #: ../Doc/reference/datamodel.rst:1219 msgid "Internal types" @@ -1658,103 +1670,107 @@ msgstr "Objetos de código" #: ../Doc/reference/datamodel.rst:947 msgid "" -"Code objects represent *byte-compiled* executable Python code, or :term:" -"`bytecode`. The difference between a code object and a function object is " -"that the function object contains an explicit reference to the function's " -"globals (the module in which it was defined), while a code object contains " -"no context; also the default argument values are stored in the function " -"object, not in the code object (because they represent values calculated at " -"run-time). Unlike function objects, code objects are immutable and contain " -"no references (directly or indirectly) to mutable objects." -msgstr "" -"Los objetos de código representan código de Python ejecutable *compilado por " -"bytes*, o :term:`bytecode`. La diferencia entre un objeto de código y un " +"Code objects represent *byte-compiled* executable Python code, or " +":term:`bytecode`. The difference between a code object and a function object" +" is that the function object contains an explicit reference to the " +"function's globals (the module in which it was defined), while a code object" +" contains no context; also the default argument values are stored in the " +"function object, not in the code object (because they represent values " +"calculated at run-time). Unlike function objects, code objects are " +"immutable and contain no references (directly or indirectly) to mutable " +"objects." +msgstr "" +"Los objetos de código representan código de Python ejecutable *compilado por" +" bytes*, o :term:`bytecode`. La diferencia entre un objeto de código y un " "objeto de función es que el objeto de función contiene una referencia " "explícita a los globales de la función (el módulo en el que fue definido), " "mientras el objeto de código no contiene contexto; de igual manera los " "valores por defecto de los argumentos son almacenados en el objeto de " -"función, no en el objeto de código (porque representan valores calculados en " -"tiempo de ejecución). A diferencia de objetos de función, los objetos de " +"función, no en el objeto de código (porque representan valores calculados en" +" tiempo de ejecución). A diferencia de objetos de función, los objetos de " "código son inmutables y no contienen referencias (directas o indirectas) a " "objetos mutables." #: ../Doc/reference/datamodel.rst:975 -#, fuzzy -msgid "" -"Special read-only attributes: :attr:`co_name` gives the function name; :attr:" -"`co_qualname` gives the fully qualified function name; :attr:`co_argcount` " -"is the total number of positional arguments (including positional-only " -"arguments and arguments with default values); :attr:`co_posonlyargcount` is " -"the number of positional-only arguments (including arguments with default " -"values); :attr:`co_kwonlyargcount` is the number of keyword-only arguments " -"(including arguments with default values); :attr:`co_nlocals` is the number " -"of local variables used by the function (including arguments); :attr:" -"`co_varnames` is a tuple containing the names of the local variables " -"(starting with the argument names); :attr:`co_cellvars` is a tuple " -"containing the names of local variables that are referenced by nested " -"functions; :attr:`co_freevars` is a tuple containing the names of free " -"variables; :attr:`co_code` is a string representing the sequence of bytecode " -"instructions; :attr:`co_consts` is a tuple containing the literals used by " -"the bytecode; :attr:`co_names` is a tuple containing the names used by the " -"bytecode; :attr:`co_filename` is the filename from which the code was " -"compiled; :attr:`co_firstlineno` is the first line number of the function; :" -"attr:`co_lnotab` is a string encoding the mapping from bytecode offsets to " -"line numbers (for details see the source code of the interpreter); :attr:" -"`co_stacksize` is the required stack size; :attr:`co_flags` is an integer " -"encoding a number of flags for the interpreter." -msgstr "" -"Atributos especiales de solo lectura: :attr:`co_name` da el nombre de la " -"función; :attr:`co_argcount` es el número total de argumentos posicionales " -"(incluyendo argumentos únicamente posicionales y argumentos con valores por " -"default); :attr:`co_posonlyargcount` es el número de argumentos únicamente " -"posicionales (incluyendo argumentos con valores por default); :attr:" -"`co_kwonlyargcountp` es el número de argumentos solo de palabra clave " -"(incluyendo argumentos con valores por default); :attr:`co_nlocals` es el " -"número de variables usadas por la función (incluyendo argumentos); :attr:" -"`co_varnames` es una tupla que contiene los nombres con las variables " -"locales (empezando con los nombres de argumento); :attr:`co_cellvars` es una " -"tupla que contiene los nombres de variables locales que son referenciadas " -"por funciones anidadas; :attr:`co_freevars` es una tupla que contiene los " -"nombres de variables libres; :attr:`co_code` es una cadena que representa la " -"secuencia de instrucciones de bytecode; :attr:`co_consts` es una tupla que " -"contiene las literales usadas por el bytecode; :attr:`co_names` es una tupla " -"que contiene los nombres usados por el bytecode; :attr:`co_filename` es el " -"nombre de archivo de donde el código fue compilado; :attr:`co_firstlineno` " -"es el primer número de línea de la función; :attr:`co_lnotab` es una cadena " -"codificando el mapeo desde el desplazamiento de bytecode al número de líneas " -"(ver el código fuente del intérprete para más detalles); :attr:" -"`co_stacksize` es el tamaño de pila requerido; :attr:`co_flags` es un entero " -"codificando el número de banderas para el intérprete." +msgid "" +"Special read-only attributes: :attr:`co_name` gives the function name; " +":attr:`co_qualname` gives the fully qualified function name; " +":attr:`co_argcount` is the total number of positional arguments (including " +"positional-only arguments and arguments with default values); " +":attr:`co_posonlyargcount` is the number of positional-only arguments " +"(including arguments with default values); :attr:`co_kwonlyargcount` is the " +"number of keyword-only arguments (including arguments with default values); " +":attr:`co_nlocals` is the number of local variables used by the function " +"(including arguments); :attr:`co_varnames` is a tuple containing the names " +"of the local variables (starting with the argument names); " +":attr:`co_cellvars` is a tuple containing the names of local variables that " +"are referenced by nested functions; :attr:`co_freevars` is a tuple " +"containing the names of free variables; :attr:`co_code` is a string " +"representing the sequence of bytecode instructions; :attr:`co_consts` is a " +"tuple containing the literals used by the bytecode; :attr:`co_names` is a " +"tuple containing the names used by the bytecode; :attr:`co_filename` is the " +"filename from which the code was compiled; :attr:`co_firstlineno` is the " +"first line number of the function; :attr:`co_lnotab` is a string encoding " +"the mapping from bytecode offsets to line numbers (for details see the " +"source code of the interpreter); :attr:`co_stacksize` is the required stack " +"size; :attr:`co_flags` is an integer encoding a number of flags for the " +"interpreter." +msgstr "" +"Atributos especiales de solo lectura: :attr:`co_name` proporciona el nombre " +"de la función; :attr:`co_qualname` proporciona el nombre de función " +"completo; :attr:`co_argcount` es el número total de argumentos posicionales " +"(incluidos los argumentos solo posicionales y los argumentos con valores " +"predeterminados); :attr:`co_posonlyargcount` es el número de argumentos solo" +" posicionales (incluidos los argumentos con valores predeterminados); " +":attr:`co_kwonlyargcount` es el número de argumentos de solo palabras clave " +"(incluidos los argumentos con valores predeterminados); :attr:`co_nlocals` " +"es el número de variables locales utilizadas por la función (incluidos los " +"argumentos); :attr:`co_varnames` es una tupla que contiene los nombres de " +"las variables locales (comenzando con los nombres de los argumentos); " +":attr:`co_cellvars` es una tupla que contiene los nombres de las variables " +"locales a las que hacen referencia las funciones anidadas; " +":attr:`co_freevars` es una tupla que contiene los nombres de las variables " +"libres; :attr:`co_code` es una cadena que representa la secuencia de " +"instrucciones de código de bytes; :attr:`co_consts` es una tupla que " +"contiene los literales utilizados por el código de bytes; :attr:`co_names` " +"es una tupla que contiene los nombres utilizados por el código de bytes; " +":attr:`co_filename` es el nombre de archivo a partir del cual se compiló el " +"código; :attr:`co_firstlineno` es el primer número de línea de la función; " +":attr:`co_lnotab` es una cadena que codifica la asignación de compensaciones" +" de bytecode a números de línea (para obtener más información, consulte el " +"código fuente del intérprete); :attr:`co_stacksize` es el tamaño de pila " +"requerido; :attr:`co_flags` es un número entero que codifica varios " +"indicadores para el intérprete." #: ../Doc/reference/datamodel.rst:1000 msgid "" "The following flag bits are defined for :attr:`co_flags`: bit ``0x04`` is " "set if the function uses the ``*arguments`` syntax to accept an arbitrary " -"number of positional arguments; bit ``0x08`` is set if the function uses the " -"``**keywords`` syntax to accept arbitrary keyword arguments; bit ``0x20`` is " -"set if the function is a generator." +"number of positional arguments; bit ``0x08`` is set if the function uses the" +" ``**keywords`` syntax to accept arbitrary keyword arguments; bit ``0x20`` " +"is set if the function is a generator." msgstr "" "Los siguientes bits de bandera son definidos por :attr:`co_flags` : bit " "``0x04`` es establecido si la función utiliza la sintaxis ``*arguments`` " "para aceptar un número arbitrario de argumentos posicionales; bit ``0x08`` " -"es establecido si la función utiliza la sintaxis ``**keywords`` para aceptar " -"argumentos de palabras clave arbitrarios; bit ``0x20`` es establecido si la " -"función es un generador." +"es establecido si la función utiliza la sintaxis ``**keywords`` para aceptar" +" argumentos de palabras clave arbitrarios; bit ``0x20`` es establecido si la" +" función es un generador." #: ../Doc/reference/datamodel.rst:1006 msgid "" "Future feature declarations (``from __future__ import division``) also use " -"bits in :attr:`co_flags` to indicate whether a code object was compiled with " -"a particular feature enabled: bit ``0x2000`` is set if the function was " +"bits in :attr:`co_flags` to indicate whether a code object was compiled with" +" a particular feature enabled: bit ``0x2000`` is set if the function was " "compiled with future division enabled; bits ``0x10`` and ``0x1000`` were " "used in earlier versions of Python." msgstr "" "Declaraciones de características futuras (``from __future__ import " "division``) también utiliza bits en :attr:`co_flags` para indicar si el " "objeto de código fue compilado con alguna característica particular " -"habilitada: el bit ``0x2000`` es establecido si la función fue compilada con " -"división futura habilitada; los bits ``0x10`` y ``0x1000`` fueron utilizados " -"en versiones previas de Python." +"habilitada: el bit ``0x2000`` es establecido si la función fue compilada con" +" división futura habilitada; los bits ``0x10`` y ``0x1000`` fueron " +"utilizados en versiones previas de Python." #: ../Doc/reference/datamodel.rst:1012 msgid "Other bits in :attr:`co_flags` are reserved for internal use." @@ -1765,53 +1781,67 @@ msgid "" "If a code object represents a function, the first item in :attr:`co_consts` " "is the documentation string of the function, or ``None`` if undefined." msgstr "" -"Si un objeto de código representa una función, el primer elemento en :attr:" -"`co_consts` es la cadena de documentación de la función, o ``None`` si no " -"está definido." +"Si un objeto de código representa una función, el primer elemento en " +":attr:`co_consts` es la cadena de documentación de la función, o ``None`` si" +" no está definido." #: ../Doc/reference/datamodel.rst:1021 msgid "" "Returns an iterable over the source code positions of each bytecode " "instruction in the code object." msgstr "" +"Devuelve un iterable sobre las posiciones del código fuente de cada " +"instrucción de código de bytes en el objeto de código." #: ../Doc/reference/datamodel.rst:1024 msgid "" "The iterator returns tuples containing the ``(start_line, end_line, " -"start_column, end_column)``. The *i-th* tuple corresponds to the position of " -"the source code that compiled to the *i-th* instruction. Column information " -"is 0-indexed utf-8 byte offsets on the given source line." +"start_column, end_column)``. The *i-th* tuple corresponds to the position of" +" the source code that compiled to the *i-th* instruction. Column information" +" is 0-indexed utf-8 byte offsets on the given source line." msgstr "" +"El iterador devuelve tuplas que contienen ``(start_line, end_line, " +"start_column, end_column)``. La tupla *i-th* corresponde a la posición del " +"código fuente que se compiló en la instrucción *i-th*. La información de la " +"columna son compensaciones de utf-8 bytes indexadas en 0 en la línea de " +"origen dada." #: ../Doc/reference/datamodel.rst:1030 msgid "" "This positional information can be missing. A non-exhaustive lists of cases " "where this may happen:" msgstr "" +"Esta información posicional puede faltar. Una lista no exhaustiva de casos " +"en los que esto puede suceder:" #: ../Doc/reference/datamodel.rst:1033 msgid "Running the interpreter with :option:`-X` ``no_debug_ranges``." -msgstr "" +msgstr "Ejecutando el intérprete con :option:`-X` ``no_debug_ranges``." #: ../Doc/reference/datamodel.rst:1034 msgid "" "Loading a pyc file compiled while using :option:`-X` ``no_debug_ranges``." msgstr "" +"Cargando un archivo pyc compilado usando :option:`-X` ``no_debug_ranges``." #: ../Doc/reference/datamodel.rst:1035 msgid "Position tuples corresponding to artificial instructions." -msgstr "" +msgstr "Tuplas de posición correspondientes a instrucciones artificiales." #: ../Doc/reference/datamodel.rst:1036 msgid "" "Line and column numbers that can't be represented due to implementation " "specific limitations." msgstr "" +"Números de línea y columna que no se pueden representar debido a " +"limitaciones específicas de la implementación." #: ../Doc/reference/datamodel.rst:1039 msgid "" "When this occurs, some or all of the tuple elements can be :const:`None`." msgstr "" +"Cuando esto ocurre, algunos o todos los elementos de la tupla pueden ser " +":const:`None`." #: ../Doc/reference/datamodel.rst:1045 msgid "" @@ -1822,6 +1852,13 @@ msgid "" "``no_debug_ranges`` command line flag or the :envvar:`PYTHONNODEBUGRANGES` " "environment variable can be used." msgstr "" +"Esta función requiere el almacenamiento de posiciones de columna en objetos " +"de código, lo que puede resultar en un pequeño aumento del uso del disco de " +"archivos de Python compilados o del uso de la memoria del intérprete. Para " +"evitar almacenar la información extra y/o desactivar la impresión de la " +"información extra de seguimiento, se puede usar el indicador de línea de " +"comando :option:`-X` ``no_debug_ranges`` o la variable de entorno " +":envvar:`PYTHONNODEBUGRANGES`." #: ../Doc/reference/datamodel.rst:1112 msgid "Frame objects" @@ -1839,66 +1876,66 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1068 msgid "" "Special read-only attributes: :attr:`f_back` is to the previous stack frame " -"(towards the caller), or ``None`` if this is the bottom stack frame; :attr:" -"`f_code` is the code object being executed in this frame; :attr:`f_locals` " -"is the dictionary used to look up local variables; :attr:`f_globals` is used " -"for global variables; :attr:`f_builtins` is used for built-in (intrinsic) " -"names; :attr:`f_lasti` gives the precise instruction (this is an index into " -"the bytecode string of the code object)." +"(towards the caller), or ``None`` if this is the bottom stack frame; " +":attr:`f_code` is the code object being executed in this frame; " +":attr:`f_locals` is the dictionary used to look up local variables; " +":attr:`f_globals` is used for global variables; :attr:`f_builtins` is used " +"for built-in (intrinsic) names; :attr:`f_lasti` gives the precise " +"instruction (this is an index into the bytecode string of the code object)." msgstr "" "Atributos especiales de solo lectura: :attr:`f_back` es para el marco de " "pila anterior (hacia quien produce el llamado), o ``None`` si éste es el " "marco de pila inferior; :attr:`f_code` es el objeto de código ejecutado en " "este marco; :attr:`f_locals` es el diccionario utilizado para buscar " -"variables locales; :attr:`f_globals` es usado por las variables globales; :" -"attr:`f_builtins` es utilizado por nombres incorporados (intrínsecos); :attr:" -"`f_lasti` da la instrucción precisa (éste es un índice dentro de la cadena " -"de bytecode del objeto de código)." +"variables locales; :attr:`f_globals` es usado por las variables globales; " +":attr:`f_builtins` es utilizado por nombres incorporados (intrínsecos); " +":attr:`f_lasti` da la instrucción precisa (éste es un índice dentro de la " +"cadena de bytecode del objeto de código)." #: ../Doc/reference/datamodel.rst:1076 msgid "" -"Accessing ``f_code`` raises an :ref:`auditing event ` ``object." -"__getattr__`` with arguments ``obj`` and ``\"f_code\"``." +"Accessing ``f_code`` raises an :ref:`auditing event ` " +"``object.__getattr__`` with arguments ``obj`` and ``\"f_code\"``." msgstr "" "Acceder a ``f_code`` lanza un objeto :ref:`evento de auditoría ` " "``.__getattr__`` con argumentos ``obj`` y ``\"f_code\"`` ." #: ../Doc/reference/datamodel.rst:1085 msgid "" -"Special writable attributes: :attr:`f_trace`, if not ``None``, is a function " -"called for various events during code execution (this is used by the " +"Special writable attributes: :attr:`f_trace`, if not ``None``, is a function" +" called for various events during code execution (this is used by the " "debugger). Normally an event is triggered for each new source line - this " "can be disabled by setting :attr:`f_trace_lines` to :const:`False`." msgstr "" -"Atributos especiales escribibles: :attr:`f_trace`, de lo contrario ``None``, " -"es una función llamada por distintos eventos durante la ejecución del código " -"(éste es utilizado por el depurador). Normalmente un evento es desencadenado " -"por cada una de las líneas fuente - esto puede ser deshabilitado " -"estableciendo :attr:`f_trace_lines` a :const:`False`." +"Atributos especiales escribibles: :attr:`f_trace`, de lo contrario ``None``," +" es una función llamada por distintos eventos durante la ejecución del " +"código (éste es utilizado por el depurador). Normalmente un evento es " +"desencadenado por cada una de las líneas fuente - esto puede ser " +"deshabilitado estableciendo :attr:`f_trace_lines` a :const:`False`." #: ../Doc/reference/datamodel.rst:1090 msgid "" -"Implementations *may* allow per-opcode events to be requested by setting :" -"attr:`f_trace_opcodes` to :const:`True`. Note that this may lead to " +"Implementations *may* allow per-opcode events to be requested by setting " +":attr:`f_trace_opcodes` to :const:`True`. Note that this may lead to " "undefined interpreter behaviour if exceptions raised by the trace function " "escape to the function being traced." msgstr "" "Las implementaciones *pueden* permitir que eventos por código de operación " "sean solicitados estableciendo :attr:`f_trace_opcodes` a :const:`True`. " "Tenga en cuenta que esto puede llevar a un comportamiento indefinido del " -"intérprete si se levantan excepciones por la función de rastreo escape hacia " -"la función que está siendo rastreada." +"intérprete si se levantan excepciones por la función de rastreo escape hacia" +" la función que está siendo rastreada." #: ../Doc/reference/datamodel.rst:1095 msgid "" -":attr:`f_lineno` is the current line number of the frame --- writing to this " -"from within a trace function jumps to the given line (only for the bottom-" +":attr:`f_lineno` is the current line number of the frame --- writing to this" +" from within a trace function jumps to the given line (only for the bottom-" "most frame). A debugger can implement a Jump command (aka Set Next " "Statement) by writing to f_lineno." msgstr "" ":attr:`f_lineno` es el número de línea actual del marco --- escribiendo a " -"esta forma dentro de una función de rastreo salta a la línea dada (solo para " -"el último marco). Un depurador puede implementar un comando de salto " +"esta forma dentro de una función de rastreo salta a la línea dada (solo para" +" el último marco). Un depurador puede implementar un comando de salto " "(*Jump*) (también conocido como *Set Next Statement*) al escribir en " "f_lineno." @@ -1915,8 +1952,8 @@ msgid "" msgstr "" "Este método limpia todas las referencias a variables locales mantenidas por " "el marco. También, si el marco pertenecía a un generador, éste es " -"finalizado. Esto ayuda a interrumpir los ciclos de referencia que involucran " -"objetos de marco (por ejemplo al detectar una excepción y almacenando su " +"finalizado. Esto ayuda a interrumpir los ciclos de referencia que involucran" +" objetos de marco (por ejemplo al detectar una excepción y almacenando su " "rastro para uso posterior)." #: ../Doc/reference/datamodel.rst:1110 @@ -1934,8 +1971,8 @@ msgid "" "explicitly created by calling :class:`types.TracebackType`." msgstr "" "Los objetos de seguimiento de pila representan el trazo de pila (*stack " -"trace*) de una excepción. Un objeto de rastreo es creado de manera implícita " -"cuando se da una excepción, y puede ser creada de manera explícita al " +"trace*) de una excepción. Un objeto de rastreo es creado de manera implícita" +" cuando se da una excepción, y puede ser creada de manera explícita al " "llamar :class:`types.TracebackType`." #: ../Doc/reference/datamodel.rst:1131 @@ -1943,23 +1980,26 @@ msgid "" "For implicitly created tracebacks, when the search for an exception handler " "unwinds the execution stack, at each unwound level a traceback object is " "inserted in front of the current traceback. When an exception handler is " -"entered, the stack trace is made available to the program. (See section :ref:" -"`try`.) It is accessible as the third item of the tuple returned by ``sys." -"exc_info()``, and as the ``__traceback__`` attribute of the caught exception." +"entered, the stack trace is made available to the program. (See section " +":ref:`try`.) It is accessible as the third item of the tuple returned by " +"``sys.exc_info()``, and as the ``__traceback__`` attribute of the caught " +"exception." msgstr "" "Para seguimientos de pila (tracebacks) creados de manera implícita, cuando " "la búsqueda por un manejo de excepciones desenvuelve la pila de ejecución, " "en cada nivel de desenvolvimiento se inserta un objeto de rastreo al frente " "del rastreo actual. Cuando se entra a un manejo de excepción, la pila de " "rastreo se vuelve disponible para el programa. (Ver sección :ref:`try`.) Es " -"accesible como el tercer elemento de la tupla retornada por ``sys." -"exc_info()``, y como el atributo ``__traceback__`` de la excepción capturada." +"accesible como el tercer elemento de la tupla retornada por " +"``sys.exc_info()``, y como el atributo ``__traceback__`` de la excepción " +"capturada." #: ../Doc/reference/datamodel.rst:1139 msgid "" "When the program contains no suitable handler, the stack trace is written " "(nicely formatted) to the standard error stream; if the interpreter is " -"interactive, it is also made available to the user as ``sys.last_traceback``." +"interactive, it is also made available to the user as " +"``sys.last_traceback``." msgstr "" "Cuando el programa no contiene un gestor apropiado, el trazo de pila es " "escrito (muy bien formateado) a la secuencia de error estándar; si el " @@ -1978,8 +2018,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1154 msgid "" -"Special read-only attributes: :attr:`tb_frame` points to the execution frame " -"of the current level; :attr:`tb_lineno` gives the line number where the " +"Special read-only attributes: :attr:`tb_frame` points to the execution frame" +" of the current level; :attr:`tb_lineno` gives the line number where the " "exception occurred; :attr:`tb_lasti` indicates the precise instruction. The " "line number and last instruction in the traceback may differ from the line " "number of its frame object if the exception occurred in a :keyword:`try` " @@ -1989,23 +2029,23 @@ msgstr "" "ejecución del nivel actual; :attr:`tb_lineno` da el número de línea donde " "ocurrió la excepción; :attr:`tb_lasti` indica la instrucción precisa. El " "número de línea y la última instrucción en el seguimiento de pila puede " -"diferir del número de línea de su objeto de marco si la excepción ocurrió en " -"una declaración :keyword:`try` sin una cláusula de excepción (except) " +"diferir del número de línea de su objeto de marco si la excepción ocurrió en" +" una declaración :keyword:`try` sin una cláusula de excepción (except) " "correspondiente o con una cláusula *finally*." #: ../Doc/reference/datamodel.rst:1163 msgid "" -"Accessing ``tb_frame`` raises an :ref:`auditing event ` ``object." -"__getattr__`` with arguments ``obj`` and ``\"tb_frame\"``." +"Accessing ``tb_frame`` raises an :ref:`auditing event ` " +"``object.__getattr__`` with arguments ``obj`` and ``\"tb_frame\"``." msgstr "" -"Acceder a ``tb_frame`` lanza un objeto :ref:`evento de auditoría ` " -"``.__getattr__`` con argumentos ``obj`` y ``tb_frame``." +"Acceder a ``tb_frame`` lanza un objeto :ref:`evento de auditoría `" +" ``.__getattr__`` con argumentos ``obj`` y ``tb_frame``." #: ../Doc/reference/datamodel.rst:1169 msgid "" "Special writable attribute: :attr:`tb_next` is the next level in the stack " -"trace (towards the frame where the exception occurred), or ``None`` if there " -"is no next level." +"trace (towards the frame where the exception occurred), or ``None`` if there" +" is no next level." msgstr "" "Atributo especial escribible: :attr:`tb_next` es el siguiente nivel en el " "trazo de pila (hacia el marco en donde ocurrió la excepción), o ``None`` si " @@ -2025,25 +2065,24 @@ msgid "Slice objects" msgstr "Objetos de segmento (Slice objects)" #: ../Doc/reference/datamodel.rst:1180 -#, fuzzy msgid "" "Slice objects are used to represent slices for :meth:`~object.__getitem__` " "methods. They are also created by the built-in :func:`slice` function." msgstr "" -"Los objetos de segmento son utilizados para representar segmentos para " -"métodos :meth:`__getitem__`. También son creados por la función incorporada :" -"func:`slice`." +"Los objetos de sector se utilizan para representar sectores para métodos " +":meth:`~object.__getitem__`. También son creados por la función integrada " +":func:`slice`." #: ../Doc/reference/datamodel.rst:1189 msgid "" -"Special read-only attributes: :attr:`~slice.start` is the lower bound; :attr:" -"`~slice.stop` is the upper bound; :attr:`~slice.step` is the step value; " -"each is ``None`` if omitted. These attributes can have any type." +"Special read-only attributes: :attr:`~slice.start` is the lower bound; " +":attr:`~slice.stop` is the upper bound; :attr:`~slice.step` is the step " +"value; each is ``None`` if omitted. These attributes can have any type." msgstr "" "Atributos especiales de solo lectura: :attr:`~slice.start` es el límite " "inferior; :attr:`~slice.stop` es el límite superior; :attr:`~slice.step` es " -"el valor de paso; cada uno es ``None`` si es omitido. Estos atributos pueden " -"ser de cualquier tipo." +"el valor de paso; cada uno es ``None`` si es omitido. Estos atributos pueden" +" ser de cualquier tipo." #: ../Doc/reference/datamodel.rst:1193 msgid "Slice objects support one method:" @@ -2079,15 +2118,15 @@ msgid "" "any further transformation. Static method objects are also callable. Static " "method objects are created by the built-in :func:`staticmethod` constructor." msgstr "" -"Los objetos de método estático proveen una forma de anular la transformación " -"de objetos de función a objetos de método descritos anteriormente. Un objeto " -"de método estático es una envoltura (*wrapper*) alrededor de cualquier otro " -"objeto, usualmente un objeto de método definido por usuario. Cuando un " -"objeto de método estático es obtenido desde una clase o una instancia de " -"clase, usualmente el objeto retornado es el objeto envuelto, el cual no está " -"objeto a ninguna transformación adicional. Los objetos de método estático " -"también pueden ser llamados. Los objetos de método estático son creados por " -"el constructor incorporado :func:`staticmethod`." +"Los objetos de método estático proveen una forma de anular la transformación" +" de objetos de función a objetos de método descritos anteriormente. Un " +"objeto de método estático es una envoltura (*wrapper*) alrededor de " +"cualquier otro objeto, usualmente un objeto de método definido por usuario. " +"Cuando un objeto de método estático es obtenido desde una clase o una " +"instancia de clase, usualmente el objeto retornado es el objeto envuelto, el" +" cual no está objeto a ninguna transformación adicional. Los objetos de " +"método estático también pueden ser llamados. Los objetos de método estático " +"son creados por el constructor incorporado :func:`staticmethod`." #: ../Doc/reference/datamodel.rst:1219 msgid "Class method objects" @@ -2097,8 +2136,8 @@ msgstr "Objetos de método de clase" msgid "" "A class method object, like a static method object, is a wrapper around " "another object that alters the way in which that object is retrieved from " -"classes and class instances. The behaviour of class method objects upon such " -"retrieval is described above, under \"User-defined methods\". Class method " +"classes and class instances. The behaviour of class method objects upon such" +" retrieval is described above, under \"User-defined methods\". Class method " "objects are created by the built-in :func:`classmethod` constructor." msgstr "" "Un objeto de método de clase, igual que un objeto de método estático, es un " @@ -2106,62 +2145,59 @@ msgstr "" "el objeto es obtenido desde las clases y las instancias de clase. El " "comportamiento de los objetos de método de clase sobre tal obtención es " "descrita más arriba, debajo de “Métodos definidos por usuario”. Objetos de " -"clase de método son creados por el constructor incorporado :func:" -"`classmethod`." +"clase de método son creados por el constructor incorporado " +":func:`classmethod`." #: ../Doc/reference/datamodel.rst:1224 msgid "Special method names" msgstr "Nombres especiales de método" #: ../Doc/reference/datamodel.rst:1230 -#, fuzzy msgid "" "A class can implement certain operations that are invoked by special syntax " "(such as arithmetic operations or subscripting and slicing) by defining " "methods with special names. This is Python's approach to :dfn:`operator " "overloading`, allowing classes to define their own behavior with respect to " -"language operators. For instance, if a class defines a method named :meth:" -"`~object.__getitem__`, and ``x`` is an instance of this class, then ``x[i]`` " -"is roughly equivalent to ``type(x).__getitem__(x, i)``. Except where " -"mentioned, attempts to execute an operation raise an exception when no " -"appropriate method is defined (typically :exc:`AttributeError` or :exc:" -"`TypeError`)." -msgstr "" -"Una clase puede implementar ciertas operaciones que son invocadas por " -"sintaxis especiales (como operaciones aritméticas o de sub-índice y " -"segmentación) definiendo métodos con nombres especiales. Este es el enfoque " -"de Python hacia :dfn:`operator overloading`, permitiendo a las clases " -"definir su propio comportamiento con respecto a los operadores del lenguaje. " -"Por ejemplo, si una clase define un método llamado :meth:`__getitem__`, y " -"``x`` es una instancia de esta clase, entonces ``x[i]`` es aproximadamente " -"equivalente a ``type(x).__getitem__(x, i)``. A excepción de donde se " -"menciona, los intentos por ejecutar una operación lanzan una excepción " -"cuando no es definido un método apropiado (normalmente :exc:`AttributeError` " -"o :exc:`TypeError`)." +"language operators. For instance, if a class defines a method named " +":meth:`~object.__getitem__`, and ``x`` is an instance of this class, then " +"``x[i]`` is roughly equivalent to ``type(x).__getitem__(x, i)``. Except " +"where mentioned, attempts to execute an operation raise an exception when no" +" appropriate method is defined (typically :exc:`AttributeError` or " +":exc:`TypeError`)." +msgstr "" +"Una clase puede implementar ciertas operaciones que son invocadas por una " +"sintaxis especial (como operaciones aritméticas o subíndices y cortes) " +"definiendo métodos con nombres especiales. Este es el enfoque de Python para" +" :dfn:`sobrecarga de operadores`, que permite que las clases definan su " +"propio comportamiento con respecto a los operadores de lenguaje. Por " +"ejemplo, si una clase define un método llamado :meth:`~object.__getitem__` y" +" ``x`` es una instancia de esta clase, entonces ``x[i]`` es aproximadamente " +"equivalente a ``type(x).__getitem__(x, i)``. Excepto donde se mencione, los " +"intentos de ejecutar una operación generan una excepción cuando no se define" +" un método apropiado (normalmente :exc:`AttributeError` o :exc:`TypeError`)." #: ../Doc/reference/datamodel.rst:1241 -#, fuzzy msgid "" "Setting a special method to ``None`` indicates that the corresponding " -"operation is not available. For example, if a class sets :meth:`~object." -"__iter__` to ``None``, the class is not iterable, so calling :func:`iter` on " -"its instances will raise a :exc:`TypeError` (without falling back to :meth:" -"`~object.__getitem__`). [#]_" +"operation is not available. For example, if a class sets " +":meth:`~object.__iter__` to ``None``, the class is not iterable, so calling " +":func:`iter` on its instances will raise a :exc:`TypeError` (without falling" +" back to :meth:`~object.__getitem__`). [#]_" msgstr "" -"Estableciendo un método especial a ``None`` indica que la operación " -"correspondiente no se encuentra disponible. Por ejemplo, si una clase " -"establece :meth:`__iter__` a ``None``, la clase no es iterable, así que " -"llamando :func:`iter` en sus instancias lanzará un :exc:`TypeError` (sin " -"volver a :meth:`__getitem__`). [#]_" +"Establecer un método especial en ``None`` indica que la operación " +"correspondiente no está disponible. Por ejemplo, si una clase establece " +":meth:`~object.__iter__` en ``None``, la clase no es iterable, por lo que " +"llamar a :func:`iter` en sus instancias generará un :exc:`TypeError` (sin " +"retroceder a :meth:`~object.__getitem__`). [#]_" #: ../Doc/reference/datamodel.rst:1247 msgid "" "When implementing a class that emulates any built-in type, it is important " -"that the emulation only be implemented to the degree that it makes sense for " -"the object being modelled. For example, some sequences may work well with " -"retrieval of individual elements, but extracting a slice may not make " -"sense. (One example of this is the :class:`~xml.dom.NodeList` interface in " -"the W3C's Document Object Model.)" +"that the emulation only be implemented to the degree that it makes sense for" +" the object being modelled. For example, some sequences may work well with " +"retrieval of individual elements, but extracting a slice may not make sense." +" (One example of this is the :class:`~xml.dom.NodeList` interface in the " +"W3C's Document Object Model.)" msgstr "" "Cuando se implementa una clase que emula cualquier tipo incorporado, es " "importante que la emulación solo sea implementado al grado que hace sentido " @@ -2177,15 +2213,15 @@ msgstr "Personalización básica" #: ../Doc/reference/datamodel.rst:1264 msgid "" -"Called to create a new instance of class *cls*. :meth:`__new__` is a static " -"method (special-cased so you need not declare it as such) that takes the " +"Called to create a new instance of class *cls*. :meth:`__new__` is a static" +" method (special-cased so you need not declare it as such) that takes the " "class of which an instance was requested as its first argument. The " "remaining arguments are those passed to the object constructor expression " "(the call to the class). The return value of :meth:`__new__` should be the " "new object instance (usually an instance of *cls*)." msgstr "" -"Es llamado para crear una nueva instancia de clase *cls*. :meth:`__new__` es " -"un método estático (como un caso especial, así que no se necesita declarar " +"Es llamado para crear una nueva instancia de clase *cls*. :meth:`__new__` es" +" un método estático (como un caso especial, así que no se necesita declarar " "como tal) que toma la clase de donde fue solicitada una instancia como su " "primer argumento. Los argumentos restantes son aquellos que se pasan a la " "expresión del constructor de objetos (para llamar a la clase). El valor " @@ -2193,31 +2229,30 @@ msgstr "" "(normalmente una instancia de *cls*)." #: ../Doc/reference/datamodel.rst:1271 -#, fuzzy msgid "" "Typical implementations create a new instance of the class by invoking the " "superclass's :meth:`__new__` method using ``super().__new__(cls[, ...])`` " "with appropriate arguments and then modifying the newly created instance as " "necessary before returning it." msgstr "" -"Implementaciones típicas crean una nueva instancia de la clase invocando el " -"método :meth:`__new__` de la súper clase utilizando ``super().__new__(cls[, " -"…])`` con argumentos apropiados y después modificando la recién creada " -"instancia como necesaria antes de retornarla." +"Las implementaciones típicas crean una nueva instancia de la clase invocando" +" el método :meth:`__new__` de la superclase usando ``super().__new__(cls[, " +"...])`` con los argumentos apropiados y luego modificando la instancia " +"recién creada según sea necesario antes de devolverla." #: ../Doc/reference/datamodel.rst:1276 msgid "" "If :meth:`__new__` is invoked during object construction and it returns an " "instance of *cls*, then the new instance’s :meth:`__init__` method will be " -"invoked like ``__init__(self[, ...])``, where *self* is the new instance and " -"the remaining arguments are the same as were passed to the object " +"invoked like ``__init__(self[, ...])``, where *self* is the new instance and" +" the remaining arguments are the same as were passed to the object " "constructor." msgstr "" "Si :meth:`__new__` es invocado durante la construcción del objeto y éste " -"retorna una instancia de *cls*, entonces el nuevo método :meth:`__init__` de " -"la instancia será invocado como ``__init__(self[, …])``, donde *self* es la " -"nueva instancia y los argumentos restantes son iguales a como fueron pasados " -"hacia el constructor de objetos." +"retorna una instancia de *cls*, entonces el nuevo método :meth:`__init__` de" +" la instancia será invocado como ``__init__(self[, …])``, donde *self* es la" +" nueva instancia y los argumentos restantes son iguales a como fueron " +"pasados hacia el constructor de objetos." #: ../Doc/reference/datamodel.rst:1281 msgid "" @@ -2243,9 +2278,9 @@ msgstr "" msgid "" "Called after the instance has been created (by :meth:`__new__`), but before " "it is returned to the caller. The arguments are those passed to the class " -"constructor expression. If a base class has an :meth:`__init__` method, the " -"derived class's :meth:`__init__` method, if any, must explicitly call it to " -"ensure proper initialization of the base class part of the instance; for " +"constructor expression. If a base class has an :meth:`__init__` method, the" +" derived class's :meth:`__init__` method, if any, must explicitly call it to" +" ensure proper initialization of the base class part of the instance; for " "example: ``super().__init__([args...])``." msgstr "" "Llamado después de que la instancia ha sido creada (por :meth:`__new__`), " @@ -2263,23 +2298,23 @@ msgid "" "it), no non-``None`` value may be returned by :meth:`__init__`; doing so " "will cause a :exc:`TypeError` to be raised at runtime." msgstr "" -"Debido a que :meth:`__new__` y :meth:`__init__` trabajan juntos construyendo " -"objetos (:meth:`__new__` para crearlo y :meth:`__init__` para " -"personalizarlo), ningún valor distinto a ``None`` puede ser retornado por :" -"meth:`__init__`; hacer esto puede causar que se lance una excepción :exc:" -"`TypeError` en tiempo de ejecución." +"Debido a que :meth:`__new__` y :meth:`__init__` trabajan juntos construyendo" +" objetos (:meth:`__new__` para crearlo y :meth:`__init__` para " +"personalizarlo), ningún valor distinto a ``None`` puede ser retornado por " +":meth:`__init__`; hacer esto puede causar que se lance una excepción " +":exc:`TypeError` en tiempo de ejecución." #: ../Doc/reference/datamodel.rst:1313 msgid "" "Called when the instance is about to be destroyed. This is also called a " -"finalizer or (improperly) a destructor. If a base class has a :meth:" -"`__del__` method, the derived class's :meth:`__del__` method, if any, must " -"explicitly call it to ensure proper deletion of the base class part of the " -"instance." +"finalizer or (improperly) a destructor. If a base class has a " +":meth:`__del__` method, the derived class's :meth:`__del__` method, if any, " +"must explicitly call it to ensure proper deletion of the base class part of " +"the instance." msgstr "" "Llamado cuando la instancia es a punto de ser destruida. Esto también es " -"llamado finalizador o (indebidamente) destructor. Si una clase base tiene un " -"método :meth:`__del__` el método :meth:`__del__` de la clase derivada, de " +"llamado finalizador o (indebidamente) destructor. Si una clase base tiene un" +" método :meth:`__del__` el método :meth:`__del__` de la clase derivada, de " "existir, debe llamarlo explícitamente para asegurar la eliminación adecuada " "de la parte de la clase base de la instancia." @@ -2288,9 +2323,9 @@ msgid "" "It is possible (though not recommended!) for the :meth:`__del__` method to " "postpone destruction of the instance by creating a new reference to it. " "This is called object *resurrection*. It is implementation-dependent " -"whether :meth:`__del__` is called a second time when a resurrected object is " -"about to be destroyed; the current :term:`CPython` implementation only calls " -"it once." +"whether :meth:`__del__` is called a second time when a resurrected object is" +" about to be destroyed; the current :term:`CPython` implementation only " +"calls it once." msgstr "" "Es posible (¡aunque no recomendable!) para el método :meth:`__del__` " "posponer la destrucción de la instancia al crear una nueva referencia hacia " @@ -2321,12 +2356,20 @@ msgstr "" msgid "" "It is possible for a reference cycle to prevent the reference count of an " "object from going to zero. In this case, the cycle will be later detected " -"and deleted by the :term:`cyclic garbage collector `. A " -"common cause of reference cycles is when an exception has been caught in a " +"and deleted by the :term:`cyclic garbage collector `. A" +" common cause of reference cycles is when an exception has been caught in a " "local variable. The frame's locals then reference the exception, which " "references its own traceback, which references the locals of all frames " "caught in the traceback." msgstr "" +"Es posible que un ciclo de referencia evite que el recuento de referencia de" +" un objeto llegue a cero. En este caso, el ciclo será posteriormente " +"detectado y eliminado por el :term:`cyclic garbage collector `. Una causa común de los ciclos de referencia es cuando se " +"detecta una excepción en una variable local. Luego, los locales del marco " +"hacen referencia a la excepción, que hace referencia a su propio rastreo, " +"que hace referencia a los locales de todos los marcos capturados en el " +"rastreo." #: ../Doc/reference/datamodel.rst:1346 msgid "Documentation for the :mod:`gc` module." @@ -2338,40 +2381,40 @@ msgid "" "invoked, exceptions that occur during their execution are ignored, and a " "warning is printed to ``sys.stderr`` instead. In particular:" msgstr "" -"Debido a las circunstancias inciertas bajo las que los métodos :meth:" -"`__del__` son invocados, las excepciones que ocurren durante su ejecución " -"son ignoradas, y una advertencia es mostrada hacia ``sys.stderr``. En " -"particular:" +"Debido a las circunstancias inciertas bajo las que los métodos " +":meth:`__del__` son invocados, las excepciones que ocurren durante su " +"ejecución son ignoradas, y una advertencia es mostrada hacia ``sys.stderr``." +" En particular:" #: ../Doc/reference/datamodel.rst:1354 msgid "" ":meth:`__del__` can be invoked when arbitrary code is being executed, " "including from any arbitrary thread. If :meth:`__del__` needs to take a " "lock or invoke any other blocking resource, it may deadlock as the resource " -"may already be taken by the code that gets interrupted to execute :meth:" -"`__del__`." +"may already be taken by the code that gets interrupted to execute " +":meth:`__del__`." msgstr "" ":meth:`__del__` puede ser invocado cuando código arbitrario es ejecutado, " "incluyendo el de cualquier hilo arbitrario. Si :meth:`__del__` necesita " "realizar un cierre de exclusión mutua (*lock*) o invocar cualquier otro " -"recurso que lo esté bloqueando, podría provocar un bloqueo muto (*deadlock*) " -"ya que el recurso podría estar siendo utilizado por el código que se " +"recurso que lo esté bloqueando, podría provocar un bloqueo muto (*deadlock*)" +" ya que el recurso podría estar siendo utilizado por el código que se " "interrumpe al ejecutar :meth:`__del__`." #: ../Doc/reference/datamodel.rst:1360 msgid "" ":meth:`__del__` can be executed during interpreter shutdown. As a " "consequence, the global variables it needs to access (including other " -"modules) may already have been deleted or set to ``None``. Python guarantees " -"that globals whose name begins with a single underscore are deleted from " +"modules) may already have been deleted or set to ``None``. Python guarantees" +" that globals whose name begins with a single underscore are deleted from " "their module before other globals are deleted; if no other references to " "such globals exist, this may help in assuring that imported modules are " "still available at the time when the :meth:`__del__` method is called." msgstr "" ":meth:`__del__` puede ser ejecutado durante el cierre del intérprete. Como " "consecuencia, las variables globales que necesita para acceder (incluyendo " -"otros módulos) podrían haber sido borradas o establecidas a ``None``. Python " -"garantiza que los globales cuyo nombre comienza con un guión bajo simple " +"otros módulos) podrían haber sido borradas o establecidas a ``None``. Python" +" garantiza que los globales cuyo nombre comienza con un guión bajo simple " "sean borrados de su módulo antes que los globales sean borrados; si no " "existen otras referencias a dichas globales, esto puede ayudar asegurando " "que los módulos importados aún se encuentren disponibles al momento de " @@ -2381,18 +2424,19 @@ msgstr "" msgid "" "Called by the :func:`repr` built-in function to compute the \"official\" " "string representation of an object. If at all possible, this should look " -"like a valid Python expression that could be used to recreate an object with " -"the same value (given an appropriate environment). If this is not possible, " -"a string of the form ``<...some useful description...>`` should be returned. " -"The return value must be a string object. If a class defines :meth:" -"`__repr__` but not :meth:`__str__`, then :meth:`__repr__` is also used when " -"an \"informal\" string representation of instances of that class is required." +"like a valid Python expression that could be used to recreate an object with" +" the same value (given an appropriate environment). If this is not " +"possible, a string of the form ``<...some useful description...>`` should be" +" returned. The return value must be a string object. If a class defines " +":meth:`__repr__` but not :meth:`__str__`, then :meth:`__repr__` is also used" +" when an \"informal\" string representation of instances of that class is " +"required." msgstr "" "Llamado por la función incorporada :func:`repr` para calcular la cadena " "“oficial” de representación de un objeto. Si es posible, esto debería verse " "como una expresión de Python válida que puede ser utilizada para recrear un " -"objeto con el mismo valor (bajo el ambiente adecuado). Si no es posible, una " -"cadena con la forma ``<…some useful description…>`` debe ser retornada. El " +"objeto con el mismo valor (bajo el ambiente adecuado). Si no es posible, una" +" cadena con la forma ``<…some useful description…>`` debe ser retornada. El " "valor de retorno debe ser un objeto de cadena (*string*). Si una clase " "define :meth:`__repr__` pero no :meth:`__str__`, entonces :meth:`__repr__` " "también es utilizado cuando una cadena “informal” de representación de " @@ -2408,15 +2452,15 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1395 msgid "" -"Called by :func:`str(object) ` and the built-in functions :func:" -"`format` and :func:`print` to compute the \"informal\" or nicely printable " -"string representation of an object. The return value must be a :ref:`string " -"` object." +"Called by :func:`str(object) ` and the built-in functions " +":func:`format` and :func:`print` to compute the \"informal\" or nicely " +"printable string representation of an object. The return value must be a " +":ref:`string ` object." msgstr "" -"Llamado por :func:`str(object) ` y las funciones incorporadas :func:" -"`format` y :func:`print` para calcular la “informal” o bien mostrada cadena " -"de representación de un objeto. El valor de retorno debe ser un objeto :ref:" -"`string `." +"Llamado por :func:`str(object) ` y las funciones incorporadas " +":func:`format` y :func:`print` para calcular la “informal” o bien mostrada " +"cadena de representación de un objeto. El valor de retorno debe ser un " +"objeto :ref:`string `." #: ../Doc/reference/datamodel.rst:1400 msgid "" @@ -2424,8 +2468,8 @@ msgid "" "expectation that :meth:`__str__` return a valid Python expression: a more " "convenient or concise representation can be used." msgstr "" -"Este método difiere de :meth:`object.__repr__` en que no hay expectativas de " -"que :meth:`__str__` retorne una expresión de Python válida: una " +"Este método difiere de :meth:`object.__repr__` en que no hay expectativas de" +" que :meth:`__str__` retorne una expresión de Python válida: una " "representación más conveniente o concisa pueda ser utilizada." #: ../Doc/reference/datamodel.rst:1404 @@ -2433,8 +2477,8 @@ msgid "" "The default implementation defined by the built-in type :class:`object` " "calls :meth:`object.__repr__`." msgstr "" -"La implementación por defecto definida por el tipo incorporado :class:" -"`object` llama a :meth:`object.__repr__`." +"La implementación por defecto definida por el tipo incorporado " +":class:`object` llama a :meth:`object.__repr__`." #: ../Doc/reference/datamodel.rst:1414 msgid "" @@ -2446,23 +2490,24 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1425 msgid "" -"Called by the :func:`format` built-in function, and by extension, evaluation " -"of :ref:`formatted string literals ` and the :meth:`str.format` " +"Called by the :func:`format` built-in function, and by extension, evaluation" +" of :ref:`formatted string literals ` and the :meth:`str.format` " "method, to produce a \"formatted\" string representation of an object. The " "*format_spec* argument is a string that contains a description of the " -"formatting options desired. The interpretation of the *format_spec* argument " -"is up to the type implementing :meth:`__format__`, however most classes will " -"either delegate formatting to one of the built-in types, or use a similar " -"formatting option syntax." +"formatting options desired. The interpretation of the *format_spec* argument" +" is up to the type implementing :meth:`__format__`, however most classes " +"will either delegate formatting to one of the built-in types, or use a " +"similar formatting option syntax." msgstr "" "Llamado por la función incorporada :func:`format`, y por extensión, la " -"evaluación de :ref:`formatted string literals ` y el método :meth:" -"`str.format`, para producir la representación “formateada” de un objeto. El " -"argumento *format_spec* es una cadena que contiene una descripción de las " -"opciones de formato deseadas. La interpretación del argumento *format_spec* " -"depende del tipo que implementa :meth:`__format__`, sin embargo, ya sea que " -"la mayoría de las clases deleguen el formato a uno de los tipos " -"incorporados, o utilicen una sintaxis de opción de formato similar." +"evaluación de :ref:`formatted string literals ` y el método " +":meth:`str.format`, para producir la representación “formateada” de un " +"objeto. El argumento *format_spec* es una cadena que contiene una " +"descripción de las opciones de formato deseadas. La interpretación del " +"argumento *format_spec* depende del tipo que implementa :meth:`__format__`, " +"sin embargo, ya sea que la mayoría de las clases deleguen el formato a uno " +"de los tipos incorporados, o utilicen una sintaxis de opción de formato " +"similar." #: ../Doc/reference/datamodel.rst:1435 msgid "" @@ -2480,8 +2525,8 @@ msgid "" "The __format__ method of ``object`` itself raises a :exc:`TypeError` if " "passed any non-empty string." msgstr "" -"El método __format__ del mismo ``object`` lanza un :exc:`TypeError` si se la " -"pasa una cadena no vacía." +"El método __format__ del mismo ``object`` lanza un :exc:`TypeError` si se la" +" pasa una cadena no vacía." #: ../Doc/reference/datamodel.rst:1443 msgid "" @@ -2494,10 +2539,10 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1459 msgid "" "These are the so-called \"rich comparison\" methods. The correspondence " -"between operator symbols and method names is as follows: ``xy`` calls ``x.__gt__(y)``, and ``x>=y`` " -"calls ``x.__ge__(y)``." +"between operator symbols and method names is as follows: ``xy`` calls " +"``x.__gt__(y)``, and ``x>=y`` calls ``x.__ge__(y)``." msgstr "" "Estos son los llamados métodos de comparación *rich*. La correspondencia " "entre símbolos de operador y los nombres de método es de la siguiente " @@ -2509,8 +2554,8 @@ msgstr "" msgid "" "A rich comparison method may return the singleton ``NotImplemented`` if it " "does not implement the operation for a given pair of arguments. By " -"convention, ``False`` and ``True`` are returned for a successful comparison. " -"However, these methods can return any value, so if the comparison operator " +"convention, ``False`` and ``True`` are returned for a successful comparison." +" However, these methods can return any value, so if the comparison operator " "is used in a Boolean context (e.g., in the condition of an ``if`` " "statement), Python will call :func:`bool` on the value to determine if the " "result is true or false." @@ -2518,8 +2563,8 @@ msgstr "" "Un método de comparación *rich* puede retornar el único ``NotImplemented`` " "si no implementa la operación para un par de argumentos dados. Por " "convención, ``False`` y ``True`` son retornados para una comparación " -"exitosa. Sin embargo, estos métodos pueden retornar cualquier valor, así que " -"si el operador de comparación es utilizado en un contexto Booleano (p. ej. " +"exitosa. Sin embargo, estos métodos pueden retornar cualquier valor, así que" +" si el operador de comparación es utilizado en un contexto Booleano (p. ej. " "en la condición de una sentencia ``if``), Python llamará :func:`bool` en " "dicho valor para determinar si el resultado es verdadero (*true*) o falso " "(*false*)." @@ -2528,106 +2573,106 @@ msgstr "" msgid "" "By default, ``object`` implements :meth:`__eq__` by using ``is``, returning " "``NotImplemented`` in the case of a false comparison: ``True if x is y else " -"NotImplemented``. For :meth:`__ne__`, by default it delegates to :meth:" -"`__eq__` and inverts the result unless it is ``NotImplemented``. There are " -"no other implied relationships among the comparison operators or default " -"implementations; for example, the truth of ``(x` and :func:`@classmethod `) are implemented as " @@ -3240,75 +3290,73 @@ msgid "" "methods. This allows individual instances to acquire behaviors that differ " "from other instances of the same class." msgstr "" -"Métodos de Python (que incluyen :func:`staticmethod` y :func:`classmethod`) " -"son implementados como descriptores sin datos. Por consiguiente, las " -"instancias pueden redefinir y anular métodos. Esto permite que instancias " -"individuales adquieran comportamientos que pueden diferir de otras " -"instancias de la misma clase." +"Los métodos de Python (incluidos los decorados con :func:`@staticmethod " +"` y :func:`@classmethod `) se implementan como " +"descriptores que no son de datos. En consecuencia, las instancias pueden " +"redefinir y anular métodos. Esto permite que instancias individuales " +"adquieran comportamientos que difieren de otras instancias de la misma " +"clase." #: ../Doc/reference/datamodel.rst:1882 msgid "" "The :func:`property` function is implemented as a data descriptor. " "Accordingly, instances cannot override the behavior of a property." msgstr "" -"La función :func:`property` es implementada como un descriptor de datos. Por " -"lo tanto, las instancias no pueden anular el comportamiento de una propiedad." +"La función :func:`property` es implementada como un descriptor de datos. Por" +" lo tanto, las instancias no pueden anular el comportamiento de una " +"propiedad." #: ../Doc/reference/datamodel.rst:1889 msgid "__slots__" msgstr "__slots__" #: ../Doc/reference/datamodel.rst:1891 -#, fuzzy msgid "" "*__slots__* allow us to explicitly declare data members (like properties) " "and deny the creation of :attr:`~object.__dict__` and *__weakref__* (unless " "explicitly declared in *__slots__* or available in a parent.)" msgstr "" -"*__slots__* nos permiten declarar de manera explícita miembros de datos " -"(como propiedades) y negar la creación de *__dict__* y *__weakref__* (a " -"menos que se declare explícitamente en *__slots__* o se encuentre disponible " -"en un elemento padre.)" +"*__slots__* nos permite declarar explícitamente miembros de datos (como " +"propiedades) y denegar la creación de :attr:`~object.__dict__` y " +"*__weakref__* (a menos que se declare explícitamente en *__slots__* o esté " +"disponible en un padre)." #: ../Doc/reference/datamodel.rst:1895 -#, fuzzy msgid "" "The space saved over using :attr:`~object.__dict__` can be significant. " "Attribute lookup speed can be significantly improved as well." msgstr "" -"El espacio ganado al usar *__dict__* puede ser importante. La velocidad de " -"búsqueda de atributos también puede mejorar significativamente." +"El espacio ahorrado con el uso de :attr:`~object.__dict__` puede ser " +"significativo. La velocidad de búsqueda de atributos también se puede " +"mejorar significativamente." #: ../Doc/reference/datamodel.rst:1900 -#, fuzzy msgid "" "This class variable can be assigned a string, iterable, or sequence of " "strings with variable names used by instances. *__slots__* reserves space " -"for the declared variables and prevents the automatic creation of :attr:" -"`~object.__dict__` and *__weakref__* for each instance." +"for the declared variables and prevents the automatic creation of " +":attr:`~object.__dict__` and *__weakref__* for each instance." msgstr "" -"Esta variable de clase se le puede asignar una cadena de caracteres, un " -"elemento iterable o una secuencia de cadena de caracteres con nombres de " -"variables utilizados por instancias. *__slots__* reserva espacio para las " -"variables declaradas y previene la creación automática de *__dict__* y " -"*__weakref__* para cada instancia." +"A esta variable de clase se le puede asignar una cadena, iterable o una " +"secuencia de cadenas con nombres de variables utilizados por las instancias." +" *__slots__* reserva espacio para las variables declaradas y evita la " +"creación automática de :attr:`~object.__dict__` y *__weakref__* para cada " +"instancia." #: ../Doc/reference/datamodel.rst:1908 msgid "Notes on using *__slots__*" msgstr "Notas sobre el uso de *__slots__*" #: ../Doc/reference/datamodel.rst:1910 -#, fuzzy msgid "" -"When inheriting from a class without *__slots__*, the :attr:`~object." -"__dict__` and *__weakref__* attribute of the instances will always be " -"accessible." +"When inheriting from a class without *__slots__*, the " +":attr:`~object.__dict__` and *__weakref__* attribute of the instances will " +"always be accessible." msgstr "" -"Cuando se hereda de una clase sin *__slots__*, los atributos *__dict__* y " -"*__weakref__* de las instancias siempre serán accesibles." +"Al heredar de una clase sin *__slots__*, siempre se podrá acceder al " +"atributo :attr:`~object.__dict__` y *__weakref__* de las instancias." #: ../Doc/reference/datamodel.rst:1914 -#, fuzzy msgid "" "Without a :attr:`~object.__dict__` variable, instances cannot be assigned " "new variables not listed in the *__slots__* definition. Attempts to assign " @@ -3316,55 +3364,53 @@ msgid "" "assignment of new variables is desired, then add ``'__dict__'`` to the " "sequence of strings in the *__slots__* declaration." msgstr "" -"Sin una variable *__dict__*, no se puede asignar a instancias nuevas " -"variables que no se encuentren listadas en la definición de *__slots__*. " -"Intentos de asignación a una variable no listada lanza una excepción :exc:" -"`AttributeError`. Si se desea hacer una asignación dinámica a variables " -"nuevas, se debe agregar ``’__dict__’`` a la secuencia de cadena de " -"caracteres en la declaración de *__slots__*." +"Sin una variable :attr:`~object.__dict__`, no se pueden asignar nuevas " +"variables a las instancias que no estén incluidas en la definición " +"*__slots__*. Los intentos de asignar a un nombre de variable no listado " +"genera :exc:`AttributeError`. Si se desea la asignación dinámica de nuevas " +"variables, agregue ``'__dict__'`` a la secuencia de cadenas en la " +"declaración *__slots__*." #: ../Doc/reference/datamodel.rst:1921 -#, fuzzy msgid "" "Without a *__weakref__* variable for each instance, classes defining " "*__slots__* do not support :mod:`weak references ` to its " "instances. If weak reference support is needed, then add ``'__weakref__'`` " "to the sequence of strings in the *__slots__* declaration." msgstr "" -"Sin una variable *__weakref__* por cada instancia, las clases que definen " -"*__slots__* no soportan “referencias débiles” (*weak references*) a sus " -"instancias. Si se desea el soporte de dichas referencias, se debe agregar " -"``’__weakref__’`` a la secuencia de cadena de caracteres en la declaración " -"de *__slots__*." +"Sin una variable *__weakref__* para cada instancia, las clases que definen " +"*__slots__* no admiten :mod:`weak references ` en sus instancias. " +"Si se necesita un soporte de referencia débil, agregue ``'__weakref__'`` a " +"la secuencia de cadenas en la declaración *__slots__*." #: ../Doc/reference/datamodel.rst:1927 -#, fuzzy msgid "" -"*__slots__* are implemented at the class level by creating :ref:`descriptors " -"` for each variable name. As a result, class attributes cannot " -"be used to set default values for instance variables defined by *__slots__*; " -"otherwise, the class attribute would overwrite the descriptor assignment." +"*__slots__* are implemented at the class level by creating :ref:`descriptors" +" ` for each variable name. As a result, class attributes " +"cannot be used to set default values for instance variables defined by " +"*__slots__*; otherwise, the class attribute would overwrite the descriptor " +"assignment." msgstr "" -"*__slots__* son implementados a nivel de clase al crear descriptores (:ref:" -"`descriptors`) para cada nombre de variable. Como resultado, los atributos " -"de clase no pueden ser utilizados para establecer valores por defecto a " -"variables de instancia definidos por *__slots__*; de lo contrario, el " -"atributo de clase sobrescribirá la asignación del descriptor." +"*__slots__* se implementan a nivel de clase creando :ref:`descriptors " +"` para cada nombre de variable. Como resultado, los atributos " +"de clase no se pueden usar para establecer valores predeterminados para las " +"variables de instancia definidas por *__slots__*; de lo contrario, el " +"atributo de clase sobrescribiría la asignación del descriptor." #: ../Doc/reference/datamodel.rst:1933 -#, fuzzy msgid "" -"The action of a *__slots__* declaration is not limited to the class where it " -"is defined. *__slots__* declared in parents are available in child classes. " -"However, child subclasses will get a :attr:`~object.__dict__` and " -"*__weakref__* unless they also define *__slots__* (which should only contain " -"names of any *additional* slots)." +"The action of a *__slots__* declaration is not limited to the class where it" +" is defined. *__slots__* declared in parents are available in child " +"classes. However, child subclasses will get a :attr:`~object.__dict__` and " +"*__weakref__* unless they also define *__slots__* (which should only contain" +" names of any *additional* slots)." msgstr "" -"La acción de una declaración *__slots__* no está limitada a la clase donde " -"fue definida. *__slots__* declarado en padres, se vuelven disponibles en " -"clases hijas. Sin embargo, subclases hijas tendrán un *__dict__* y " -"*__weakref__* a menos que también se defina *__slots__* (el cual solo debe " -"contener nombres de espacios o *slots* *adicionales*)." +"La acción de una declaración *__slots__* no se limita a la clase donde se " +"define. *__slots__* declarado en padres está disponible en clases " +"secundarias. Sin embargo, las subclases secundarias obtendrán " +":attr:`~object.__dict__` y *__weakref__* a menos que también definan " +"*__slots__* (que solo debe contener nombres de cualquier ranura " +"*additional*)." #: ../Doc/reference/datamodel.rst:1939 msgid "" @@ -3383,78 +3429,82 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1944 msgid "" "Nonempty *__slots__* does not work for classes derived from \"variable-" -"length\" built-in types such as :class:`int`, :class:`bytes` and :class:" -"`tuple`." +"length\" built-in types such as :class:`int`, :class:`bytes` and " +":class:`tuple`." msgstr "" "*__slots__* no vacíos no funcionan para clases derivadas de tipos " -"incorporados de “longitud variable” como :class:`int`, :class:`bytes` y :" -"class:`tuple`." +"incorporados de “longitud variable” como :class:`int`, :class:`bytes` y " +":class:`tuple`." #: ../Doc/reference/datamodel.rst:1947 msgid "Any non-string :term:`iterable` may be assigned to *__slots__*." msgstr "" +"Cualquier :term:`iterable` que no sea una cadena se puede asignar a " +"*__slots__*." #: ../Doc/reference/datamodel.rst:1949 msgid "" "If a :class:`dictionary ` is used to assign *__slots__*, the " -"dictionary keys will be used as the slot names. The values of the dictionary " -"can be used to provide per-attribute docstrings that will be recognised by :" -"func:`inspect.getdoc` and displayed in the output of :func:`help`." +"dictionary keys will be used as the slot names. The values of the dictionary" +" can be used to provide per-attribute docstrings that will be recognised by " +":func:`inspect.getdoc` and displayed in the output of :func:`help`." msgstr "" +"Si se utiliza un :class:`dictionary ` para asignar *__slots__*, las " +"claves del diccionario se utilizarán como nombres de ranura. Los valores del" +" diccionario se pueden usar para proporcionar cadenas de documentos por " +"atributo que :func:`inspect.getdoc` reconocerá y mostrará en la salida de " +":func:`help`." #: ../Doc/reference/datamodel.rst:1954 -#, fuzzy msgid "" ":attr:`~instance.__class__` assignment works only if both classes have the " "same *__slots__*." msgstr "" -"La asignación *__class__* funciona solo si ambas clases tienen el mismo " -"*__slots__*." +"La asignación de :attr:`~instance.__class__` solo funciona si ambas clases " +"tienen el mismo *__slots__*." #: ../Doc/reference/datamodel.rst:1957 -#, fuzzy msgid "" ":ref:`Multiple inheritance ` with multiple slotted parent " "classes can be used, but only one parent is allowed to have attributes " -"created by slots (the other bases must have empty slot layouts) - violations " -"raise :exc:`TypeError`." +"created by slots (the other bases must have empty slot layouts) - violations" +" raise :exc:`TypeError`." msgstr "" -"Herencia múltiple con múltiples clases de padres con espacios (*slots*) " -"puede ser utilizada, pero solo un padre es permitido que tenga atributos " -"creados por espacios (las otras bases deben tener diseños de espacios " -"vacíos) - violaciones lanzan una excepción :exc:`TypeError`." +"Se puede usar :ref:`Multiple inheritance ` con varias clases " +"principales con ranuras, pero solo una principal puede tener atributos " +"creados por ranuras (las otras bases deben tener diseños de ranuras vacías);" +" las infracciones generan :exc:`TypeError`." #: ../Doc/reference/datamodel.rst:1963 -#, fuzzy msgid "" "If an :term:`iterator` is used for *__slots__* then a :term:`descriptor` is " "created for each of the iterator's values. However, the *__slots__* " "attribute will be an empty iterator." msgstr "" -"Si un iterados es utilizado por *__slots__*, entonces un descriptor es " -"creado para cada uno de los valores del iterador. Sin embargo, el atributo " -"*__slots__* será un iterador vacío." +"Si se utiliza un :term:`iterator` para *__slots__*, se crea un " +":term:`descriptor` para cada uno de los valores del iterador. Sin embargo, " +"el atributo *__slots__* será un iterador vacío." #: ../Doc/reference/datamodel.rst:1971 msgid "Customizing class creation" msgstr "Personalización de creación de clases" #: ../Doc/reference/datamodel.rst:1973 -#, fuzzy -msgid "" -"Whenever a class inherits from another class, :meth:`~object." -"__init_subclass__` is called on the parent class. This way, it is possible " -"to write classes which change the behavior of subclasses. This is closely " -"related to class decorators, but where class decorators only affect the " -"specific class they're applied to, ``__init_subclass__`` solely applies to " -"future subclasses of the class defining the method." -msgstr "" -"Siempre que una clase hereda de otra clase, *__init_subclass__* es llamado " -"en esa clase. De esta manera, es posible escribir clases que cambian el " -"comportamiento de las subclases. Esto está estrechamente relacionado con los " -"decoradores de clase, pero solo donde los decoradores de clase afectan a la " -"clase específica a la que son aplicados, ``__init_subclass__`` solo aplica a " -"futuras subclases de la clase que define el método." +msgid "" +"Whenever a class inherits from another class, " +":meth:`~object.__init_subclass__` is called on the parent class. This way, " +"it is possible to write classes which change the behavior of subclasses. " +"This is closely related to class decorators, but where class decorators only" +" affect the specific class they're applied to, ``__init_subclass__`` solely " +"applies to future subclasses of the class defining the method." +msgstr "" +"Cada vez que una clase hereda de otra clase, se llama a " +":meth:`~object.__init_subclass__` en la clase principal. De esta forma, es " +"posible escribir clases que cambien el comportamiento de las subclases. Esto" +" está estrechamente relacionado con los decoradores de clases, pero donde " +"los decoradores de clases solo afectan a la clase específica a la que se " +"aplican, ``__init_subclass__`` solo se aplica a las subclases futuras de la " +"clase que define el método." #: ../Doc/reference/datamodel.rst:1982 msgid "" @@ -3491,8 +3541,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2005 msgid "" "The metaclass hint ``metaclass`` is consumed by the rest of the type " -"machinery, and is never passed to ``__init_subclass__`` implementations. The " -"actual metaclass (rather than the explicit hint) can be accessed as " +"machinery, and is never passed to ``__init_subclass__`` implementations. The" +" actual metaclass (rather than the explicit hint) can be accessed as " "``type(cls)``." msgstr "" "La sugerencia de metaclase ``metaclass`` es consumido por el resto de la " @@ -3501,14 +3551,13 @@ msgstr "" "explícita) puede ser accedida como ``type(cls)``." #: ../Doc/reference/datamodel.rst:2013 -#, fuzzy msgid "" "When a class is created, :meth:`type.__new__` scans the class variables and " "makes callbacks to those with a :meth:`~object.__set_name__` hook." msgstr "" "Cuando se crea una clase, :meth:`type.__new__` escanea las variables de " -"clase y realiza retornos de llamada a aquellas con un gancho :meth:" -"`__set_name__`." +"clase y realiza devoluciones de llamada a aquellas con un gancho " +":meth:`~object.__set_name__`." #: ../Doc/reference/datamodel.rst:2018 msgid "" @@ -3520,13 +3569,13 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2024 msgid "" -"If the class variable is assigned after the class is created, :meth:" -"`__set_name__` will not be called automatically. If needed, :meth:" -"`__set_name__` can be called directly::" +"If the class variable is assigned after the class is created, " +":meth:`__set_name__` will not be called automatically. If needed, " +":meth:`__set_name__` can be called directly::" msgstr "" -"Si la variable de clase se asigna después de crear la clase, :meth:" -"`__set_name__` no se llamará automáticamente. Si es necesario, :meth:" -"`__set_name__` se puede llamar directamente::" +"Si la variable de clase se asigna después de crear la clase, " +":meth:`__set_name__` no se llamará automáticamente. Si es necesario, " +":meth:`__set_name__` se puede llamar directamente::" #: ../Doc/reference/datamodel.rst:2035 msgid "See :ref:`class-object-creation` for more details." @@ -3542,9 +3591,9 @@ msgid "" "executed in a new namespace and the class name is bound locally to the " "result of ``type(name, bases, namespace)``." msgstr "" -"Por defecto, las clases son construidas usando :func:`type`. El cuerpo de la " -"clase es ejecutado en un nuevo espacio de nombres y el nombre de la clase es " -"ligado de forma local al resultado de ``type(name, bases, namespace)``." +"Por defecto, las clases son construidas usando :func:`type`. El cuerpo de la" +" clase es ejecutado en un nuevo espacio de nombres y el nombre de la clase " +"es ligado de forma local al resultado de ``type(name, bases, namespace)``." #: ../Doc/reference/datamodel.rst:2054 msgid "" @@ -3553,8 +3602,8 @@ msgid "" "existing class that included such an argument. In the following example, " "both ``MyClass`` and ``MySubclass`` are instances of ``Meta``::" msgstr "" -"El proceso de creación de clase puede ser personalizado pasando el argumento " -"de palabra clave ``metaclass`` en la línea de definición de la clase, o al " +"El proceso de creación de clase puede ser personalizado pasando el argumento" +" de palabra clave ``metaclass`` en la línea de definición de la clase, o al " "heredar de una clase existente que incluya dicho argumento. En el siguiente " "ejemplo, ambos ``MyClass`` y ``MySubclass`` son instancias de ``Meta``::" @@ -3598,17 +3647,17 @@ msgstr "Resolviendo entradas de la Orden de Resolución de Métodos (MRU)" #: ../Doc/reference/datamodel.rst:2083 msgid "" -"If a base that appears in class definition is not an instance of :class:" -"`type`, then an ``__mro_entries__`` method is searched on it. If found, it " -"is called with the original bases tuple. This method must return a tuple of " -"classes that will be used instead of this base. The tuple may be empty, in " -"such case the original base is ignored." +"If a base that appears in class definition is not an instance of " +":class:`type`, then an ``__mro_entries__`` method is searched on it. If " +"found, it is called with the original bases tuple. This method must return a" +" tuple of classes that will be used instead of this base. The tuple may be " +"empty, in such case the original base is ignored." msgstr "" -"Si una base que aparece en la definición de una clase no es una instancia " -"de :class:`type`, entonces el método ``__mro_entries__`` se busca en ella. " -"Si es encontrado, se llama con la tupla de bases originales. Este método " -"debe retornar una tupla de clases que será utilizado en lugar de esta base. " -"La tupla puede estar vacía, en cuyo caso la base original es ignorada." +"Si una base que aparece en la definición de una clase no es una instancia de" +" :class:`type`, entonces el método ``__mro_entries__`` se busca en ella. Si " +"es encontrado, se llama con la tupla de bases originales. Este método debe " +"retornar una tupla de clases que será utilizado en lugar de esta base. La " +"tupla puede estar vacía, en cuyo caso la base original es ignorada." #: ../Doc/reference/datamodel.rst:2091 msgid ":pep:`560` - Core support for typing module and generic types" @@ -3630,13 +3679,13 @@ msgstr "" msgid "" "if no bases and no explicit metaclass are given, then :func:`type` is used;" msgstr "" -"si no se dan bases ni metaclases explícitas, entonces se utiliza :func:" -"`type`;" +"si no se dan bases ni metaclases explícitas, entonces se utiliza " +":func:`type`;" #: ../Doc/reference/datamodel.rst:2102 msgid "" -"if an explicit metaclass is given and it is *not* an instance of :func:" -"`type`, then it is used directly as the metaclass;" +"if an explicit metaclass is given and it is *not* an instance of " +":func:`type`, then it is used directly as the metaclass;" msgstr "" "si se da una metaclase explícita y *no* es una instancia de :func:`type`, " "entonces se utiliza directamente como la metaclase;" @@ -3652,39 +3701,38 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2107 msgid "" "The most derived metaclass is selected from the explicitly specified " -"metaclass (if any) and the metaclasses (i.e. ``type(cls)``) of all specified " -"base classes. The most derived metaclass is one which is a subtype of *all* " -"of these candidate metaclasses. If none of the candidate metaclasses meets " +"metaclass (if any) and the metaclasses (i.e. ``type(cls)``) of all specified" +" base classes. The most derived metaclass is one which is a subtype of *all*" +" of these candidate metaclasses. If none of the candidate metaclasses meets " "that criterion, then the class definition will fail with ``TypeError``." msgstr "" "La metaclase más derivada es elegida de la metaclase especificada " -"explícitamente (si existe) y de la metaclase (p. ej. ``type(cls)``) de todas " -"las clases base especificadas." +"explícitamente (si existe) y de la metaclase (p. ej. ``type(cls)``) de todas" +" las clases base especificadas." #: ../Doc/reference/datamodel.rst:2117 msgid "Preparing the class namespace" msgstr "Preparando el espacio de nombres de la clase" #: ../Doc/reference/datamodel.rst:2122 -#, fuzzy msgid "" -"Once the appropriate metaclass has been identified, then the class namespace " -"is prepared. If the metaclass has a ``__prepare__`` attribute, it is called " -"as ``namespace = metaclass.__prepare__(name, bases, **kwds)`` (where the " +"Once the appropriate metaclass has been identified, then the class namespace" +" is prepared. If the metaclass has a ``__prepare__`` attribute, it is called" +" as ``namespace = metaclass.__prepare__(name, bases, **kwds)`` (where the " "additional keyword arguments, if any, come from the class definition). The " "``__prepare__`` method should be implemented as a :func:`classmethod " "`. The namespace returned by ``__prepare__`` is passed in to " "``__new__``, but when the final class object is created the namespace is " "copied into a new ``dict``." msgstr "" -"Una vez que se ha identificado la metaclase apropiada, entonces se prepara " -"el espacio de nombres de la clase. Si la metaclase tiene un atributo " -"``__prepare__``, es llamado como ``namespace = metaclass.__prepare__(name, " -"bases, **kwds)`` (donde los argumentos de palabra clave adicionales, de " -"existir, provienen de la definición de la clase). El método ``__prepare__`` " -"debe ser implementado como :func:`classmethod`. El espacio de nombres " -"retornado por ``__prepare__`` es pasado a ``__new__``, pero cuando el objeto " -"de clase final es creado, el espacio de nombres es copiado en un ``dict``." +"Una vez que se ha identificado la metaclase adecuada, se prepara el espacio " +"de nombres de la clase. Si la metaclase tiene un atributo ``__prepare__``, " +"se llama ``namespace = metaclass.__prepare__(name, bases, **kwds)`` (donde " +"los argumentos de palabras clave adicionales, si los hay, provienen de la " +"definición de clase). El método ``__prepare__`` debe implementarse como " +":func:`classmethod `. El espacio de nombres devuelto por " +"``__prepare__`` se pasa a ``__new__``, pero cuando se crea el objeto de " +"clase final, el espacio de nombres se copia en un nuevo ``dict``." #: ../Doc/reference/datamodel.rst:2131 msgid "" @@ -3714,9 +3762,9 @@ msgid "" "names from the current and outer scopes when the class definition occurs " "inside a function." msgstr "" -"El cuerpo de la clase es ejecutado como ``exec(body, globals(), namespace)`` " -"(aproximadamente). La diferencia clave con un llamado normal a :func:`exec` " -"es que el alcance léxico permite que el cuerpo de la clase (incluyendo " +"El cuerpo de la clase es ejecutado como ``exec(body, globals(), namespace)``" +" (aproximadamente). La diferencia clave con un llamado normal a :func:`exec`" +" es que el alcance léxico permite que el cuerpo de la clase (incluyendo " "cualquier método) haga referencia a nombres de los alcances actuales y " "externos cuando la definición de clase sucede dentro de la función." @@ -3729,8 +3777,8 @@ msgid "" "reference described in the next section." msgstr "" "Sin embargo, aún cuando la definición de clase sucede dentro de la función, " -"los métodos definidos dentro de la clase aún no pueden ver nombres definidos " -"dentro del alcance de la clase. Variables de clase deben ser accedidas a " +"los métodos definidos dentro de la clase aún no pueden ver nombres definidos" +" dentro del alcance de la clase. Variables de clase deben ser accedidas a " "través del primer parámetro de instancia o métodos de clase, o a través de " "la referencia al léxico implícito ``__class__`` descrita en la siguiente " "sección." @@ -3741,48 +3789,49 @@ msgstr "Creando el objeto de clase" #: ../Doc/reference/datamodel.rst:2168 msgid "" -"Once the class namespace has been populated by executing the class body, the " -"class object is created by calling ``metaclass(name, bases, namespace, " +"Once the class namespace has been populated by executing the class body, the" +" class object is created by calling ``metaclass(name, bases, namespace, " "**kwds)`` (the additional keywords passed here are the same as those passed " "to ``__prepare__``)." msgstr "" -"Una vez que el espacio de nombres de la clase ha sido poblado al ejecutar el " -"cuerpo de la clase, el objeto de clase es creado al llamar ``metaclass(name, " -"bases, namespace, **kwds)`` (las palabras clave adicionales que se pasan " -"aquí, son las mismas que aquellas pasadas en ``__prepare__``)." +"Una vez que el espacio de nombres de la clase ha sido poblado al ejecutar el" +" cuerpo de la clase, el objeto de clase es creado al llamar " +"``metaclass(name, bases, namespace, **kwds)`` (las palabras clave " +"adicionales que se pasan aquí, son las mismas que aquellas pasadas en " +"``__prepare__``)." #: ../Doc/reference/datamodel.rst:2173 msgid "" "This class object is the one that will be referenced by the zero-argument " "form of :func:`super`. ``__class__`` is an implicit closure reference " "created by the compiler if any methods in a class body refer to either " -"``__class__`` or ``super``. This allows the zero argument form of :func:" -"`super` to correctly identify the class being defined based on lexical " -"scoping, while the class or instance that was used to make the current call " -"is identified based on the first argument passed to the method." -msgstr "" -"Este objeto de clase es el que será referenciado por la forma sin argumentos " -"de :func:`super`. ``__class__`` es una referencia de cierre implícita creada " -"por el compilador si cualquier método en el cuerpo de una clase se refiere " -"tanto a ``__class__`` o ``super``. Esto permite que la forma sin argumentos " -"de :func:`super` identifique correctamente la clase definida en base al " -"alcance léxico, mientras la clase o instancia que fue utilizada para hacer " -"el llamado actual es identificado en base al primer argumento que se pasa al " -"método." +"``__class__`` or ``super``. This allows the zero argument form of " +":func:`super` to correctly identify the class being defined based on lexical" +" scoping, while the class or instance that was used to make the current call" +" is identified based on the first argument passed to the method." +msgstr "" +"Este objeto de clase es el que será referenciado por la forma sin argumentos" +" de :func:`super`. ``__class__`` es una referencia de cierre implícita " +"creada por el compilador si cualquier método en el cuerpo de una clase se " +"refiere tanto a ``__class__`` o ``super``. Esto permite que la forma sin " +"argumentos de :func:`super` identifique correctamente la clase definida en " +"base al alcance léxico, mientras la clase o instancia que fue utilizada para" +" hacer el llamado actual es identificado en base al primer argumento que se " +"pasa al método." #: ../Doc/reference/datamodel.rst:2183 msgid "" "In CPython 3.6 and later, the ``__class__`` cell is passed to the metaclass " "as a ``__classcell__`` entry in the class namespace. If present, this must " "be propagated up to the ``type.__new__`` call in order for the class to be " -"initialised correctly. Failing to do so will result in a :exc:`RuntimeError` " -"in Python 3.8." +"initialised correctly. Failing to do so will result in a :exc:`RuntimeError`" +" in Python 3.8." msgstr "" "En CPython 3.6 y posterior, la celda ``__class__`` se pasa a la metaclase " "como una entrada ``__classcell__`` en el espacio de nombres de la clase. En " "caso de existir, esto debe ser propagado hacia el llamado ``type.__new__`` " -"para que la clase se inicie correctamente. No hacerlo resultará en un error :" -"exc:`RuntimeError` en Python 3.8." +"para que la clase se inicie correctamente. No hacerlo resultará en un error " +":exc:`RuntimeError` en Python 3.8." #: ../Doc/reference/datamodel.rst:2189 msgid "" @@ -3807,13 +3856,13 @@ msgid "" "Those ``__set_name__`` methods are called with the class being defined and " "the assigned name of that particular attribute;" msgstr "" -"Esos métodos ``__set_name__`` son llamados con la clase siendo definida y el " -"nombre de ese atributo particular asignado;" +"Esos métodos ``__set_name__`` son llamados con la clase siendo definida y el" +" nombre de ese atributo particular asignado;" #: ../Doc/reference/datamodel.rst:2197 msgid "" -"The :meth:`~object.__init_subclass__` hook is called on the immediate parent " -"of the new class in its method resolution order." +"The :meth:`~object.__init_subclass__` hook is called on the immediate parent" +" of the new class in its method resolution order." msgstr "" "El gancho :meth:`~object.__init_subclass__` llama al padre inmediato de la " "nueva clase en su orden de resolución del método." @@ -3838,8 +3887,8 @@ msgstr "" "Cuando una nueva clase es creada por ``type.__new__``, el objeto " "proporcionado como el parámetro de espacio de nombres es copiado a un " "trazado ordenado y el objeto original es descartado. La nueva copia es " -"*envuelta* en un proxy de solo lectura, que se convierte en el atributo :" -"attr:`~object.__dict__` del objeto de clase." +"*envuelta* en un proxy de solo lectura, que se convierte en el atributo " +":attr:`~object.__dict__` del objeto de clase." #: ../Doc/reference/datamodel.rst:2211 msgid ":pep:`3135` - New super" @@ -3871,12 +3920,12 @@ msgstr "Personalizando revisiones de instancia y subclase" #: ../Doc/reference/datamodel.rst:2227 msgid "" -"The following methods are used to override the default behavior of the :func:" -"`isinstance` and :func:`issubclass` built-in functions." +"The following methods are used to override the default behavior of the " +":func:`isinstance` and :func:`issubclass` built-in functions." msgstr "" "Los siguientes métodos son utilizados para anular el comportamiento por " -"defecto de las funciones incorporadas :func:`isinstance` y :func:" -"`issubclass`." +"defecto de las funciones incorporadas :func:`isinstance` y " +":func:`issubclass`." #: ../Doc/reference/datamodel.rst:2230 msgid "" @@ -3896,15 +3945,15 @@ msgid "" "instance of *class*. If defined, called to implement ``isinstance(instance, " "class)``." msgstr "" -"Retorna *true* si la instancia *instance* debe ser considerada una instancia " -"(directa o indirecta) de clase *class*. De ser definida, es llamado para " +"Retorna *true* si la instancia *instance* debe ser considerada una instancia" +" (directa o indirecta) de clase *class*. De ser definida, es llamado para " "implementar ``isinstance(instance, class)``." #: ../Doc/reference/datamodel.rst:2244 msgid "" "Return true if *subclass* should be considered a (direct or indirect) " -"subclass of *class*. If defined, called to implement ``issubclass(subclass, " -"class)``." +"subclass of *class*. If defined, called to implement ``issubclass(subclass," +" class)``." msgstr "" "Retorna *true* si la subclase *subclass* debe ser considerada una subclase " "(directa o indirecta) de clase *class*. De ser definida, es llamado para " @@ -3925,21 +3974,22 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2260 msgid ":pep:`3119` - Introducing Abstract Base Classes" msgstr "" -":pep:`3119` - Introducción a Clases Base Abstractas (*Abstract Base Classes*)" +":pep:`3119` - Introducción a Clases Base Abstractas (*Abstract Base " +"Classes*)" #: ../Doc/reference/datamodel.rst:2257 msgid "" -"Includes the specification for customizing :func:`isinstance` and :func:" -"`issubclass` behavior through :meth:`~class.__instancecheck__` and :meth:" -"`~class.__subclasscheck__`, with motivation for this functionality in the " -"context of adding Abstract Base Classes (see the :mod:`abc` module) to the " -"language." +"Includes the specification for customizing :func:`isinstance` and " +":func:`issubclass` behavior through :meth:`~class.__instancecheck__` and " +":meth:`~class.__subclasscheck__`, with motivation for this functionality in " +"the context of adding Abstract Base Classes (see the :mod:`abc` module) to " +"the language." msgstr "" -"Incluye la especificación para personalizar el comportamiento de :func:" -"`isinstance` y :func:`issubclass` a través de :meth:`~class." -"__instancecheck__` y :meth:`~class.__subclasscheck__`, con motivación para " -"esta funcionalidad en el contexto de agregar Clases Base Abstractas (ver el " -"módulo :mod:`abc`) al lenguaje." +"Incluye la especificación para personalizar el comportamiento de " +":func:`isinstance` y :func:`issubclass` a través de " +":meth:`~class.__instancecheck__` y :meth:`~class.__subclasscheck__`, con " +"motivación para esta funcionalidad en el contexto de agregar Clases Base " +"Abstractas (ver el módulo :mod:`abc`) al lenguaje." #: ../Doc/reference/datamodel.rst:2265 msgid "Emulating generic types" @@ -3949,43 +3999,56 @@ msgstr "Emulando tipos genéricos" msgid "" "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`." +"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 "" +"Cuando se usa :term:`type annotations`, a menudo es útil " +"*parameterize* a :term:`generic type` usando la notación de corchetes de " +"Python. Por ejemplo, la anotación ``list[int]`` podría usarse para indicar " +"un :class:`list` en el que todos los elementos son del tipo :class:`int`." #: ../Doc/reference/datamodel.rst:2275 msgid ":pep:`484` - Type Hints" -msgstr "" +msgstr ":pep:`484` - Sugerencias de tipo" #: ../Doc/reference/datamodel.rst:2275 msgid "Introducing Python's framework for type annotations" msgstr "" +"Presentamos el marco de trabajo de Python para las anotaciones de tipo" #: ../Doc/reference/datamodel.rst:2278 msgid ":ref:`Generic Alias Types`" -msgstr "" +msgstr ":ref:`Generic Alias Types`" #: ../Doc/reference/datamodel.rst:2278 msgid "Documentation for objects representing parameterized generic classes" msgstr "" +"Documentación para objetos que representan clases genéricas parametrizadas" #: ../Doc/reference/datamodel.rst:2281 msgid "" -":ref:`Generics`, :ref:`user-defined generics` and :" -"class:`typing.Generic`" +":ref:`Generics`, :ref:`user-defined generics` and " +":class:`typing.Generic`" msgstr "" +":ref:`Generics`, :ref:`user-defined generics` y " +":class:`typing.Generic`" #: ../Doc/reference/datamodel.rst:2281 msgid "" "Documentation on how to implement generic classes that can be parameterized " "at runtime and understood by static type-checkers." msgstr "" +"Documentación sobre cómo implementar clases genéricas que se pueden " +"parametrizar en tiempo de ejecución y que los verificadores de tipos " +"estáticos pueden entender." #: ../Doc/reference/datamodel.rst:2284 msgid "" "A class can *generally* only be parameterized if it defines the special " "class method ``__class_getitem__()``." msgstr "" +"Una clase *generally* solo se puede parametrizar si define el método de " +"clase especial ``__class_getitem__()``." #: ../Doc/reference/datamodel.rst:2289 msgid "" @@ -3998,41 +4061,59 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2292 msgid "" "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." +"method. As such, there is no need for it to be decorated with " +":func:`@classmethod` when it is defined." msgstr "" +"Cuando se define en una clase, ``__class_getitem__()`` es automáticamente un" +" método de clase. Como tal, no es necesario decorarlo con " +":func:`@classmethod` cuando se define." #: ../Doc/reference/datamodel.rst:2298 msgid "The purpose of *__class_getitem__*" -msgstr "" +msgstr "El propósito de *__class_getitem__*" #: ../Doc/reference/datamodel.rst:2300 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." +"parameterization of standard-library generic classes in order to more easily" +" apply :term:`type hints` to these classes." msgstr "" +"El propósito de :meth:`~object.__class_getitem__` es permitir la " +"parametrización en tiempo de ejecución de clases genéricas de biblioteca " +"estándar para aplicar :term:`type hints` a estas clases con mayor" +" facilidad." #: ../Doc/reference/datamodel.rst:2304 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__()``." +"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 "" +"Para implementar clases genéricas personalizadas que se puedan parametrizar " +"en tiempo de ejecución y que los verificadores de tipos estáticos las " +"entiendan, los usuarios deben heredar de una clase de biblioteca estándar " +"que ya implementa :meth:`~object.__class_getitem__`, o heredar de " +":class:`typing.Generic`, que tiene su propia implementación de " +"``__class_getitem__()``." #: ../Doc/reference/datamodel.rst:2310 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 " +"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 "" +"Es posible que los verificadores de tipos de terceros, como mypy, no " +"entiendan las implementaciones personalizadas de " +":meth:`~object.__class_getitem__` en clases definidas fuera de la biblioteca" +" estándar. Se desaconseja el uso de ``__class_getitem__()`` en cualquier " +"clase para fines distintos a la sugerencia de tipo." #: ../Doc/reference/datamodel.rst:2320 msgid "*__class_getitem__* versus *__getitem__*" -msgstr "" +msgstr "*__class_getitem__* frente a *__getitem__*" #: ../Doc/reference/datamodel.rst:2322 msgid "" @@ -4043,43 +4124,66 @@ msgid "" "instead. ``__class_getitem__()`` should return a :ref:`GenericAlias` object if it is properly defined." msgstr "" +"Por lo general, el :ref:`subscription` de un objeto que usa " +"corchetes llamará al método de instancia :meth:`~object.__getitem__` " +"definido en la clase del objeto. Sin embargo, si el objeto que se suscribe " +"es en sí mismo una clase, se puede llamar al método de clase " +":meth:`~object.__class_getitem__` en su lugar. ``__class_getitem__()`` " +"debería devolver un objeto :ref:`GenericAlias` si está " +"definido correctamente." #: ../Doc/reference/datamodel.rst:2329 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::" +"follows something like the following process to decide whether " +":meth:`~object.__getitem__` or :meth:`~object.__class_getitem__` should be " +"called::" msgstr "" +"Presentado con el :term:`expression` ``obj[x]``, el intérprete de Python " +"sigue un proceso similar al siguiente para decidir si se debe llamar a " +":meth:`~object.__getitem__` o :meth:`~object.__class_getitem__`:" #: ../Doc/reference/datamodel.rst:2357 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 "" +"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 "" +"En Python, todas las clases son en sí mismas instancias de otras clases. La " +"clase de una clase se conoce como :term:`metaclass` de esa clase, y la " +"mayoría de las clases tienen la clase :class:`type` como su metaclase. " +":class:`type` no define :meth:`~object.__getitem__`, lo que significa que " +"expresiones como ``list[int]``, ``dict[str, float]`` y ``tuple[str, bytes]``" +" dan como resultado que se llame a :meth:`~object.__class_getitem__`:" #: ../Doc/reference/datamodel.rst:2376 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::" +"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 "" +"Sin embargo, si una clase tiene una metaclase personalizada que define " +":meth:`~object.__getitem__`, la suscripción de la clase puede generar un " +"comportamiento diferente. Un ejemplo de esto se puede encontrar en el módulo" +" :mod:`enum`:" #: ../Doc/reference/datamodel.rst:2401 -#, fuzzy msgid ":pep:`560` - Core Support for typing module and generic types" msgstr "" -":pep:`560` - Soporte central para módulos de clasificación y tipos genéricos" +":pep:`560` - Compatibilidad básica para escribir módulos y tipos genéricos" #: ../Doc/reference/datamodel.rst:2400 msgid "" -"Introducing :meth:`~object.__class_getitem__`, and outlining when a :ref:" -"`subscription` results in ``__class_getitem__()`` being " +"Introducing :meth:`~object.__class_getitem__`, and outlining when a " +":ref:`subscription` results in ``__class_getitem__()`` being " "called instead of :meth:`~object.__getitem__`" msgstr "" +"Presentamos :meth:`~object.__class_getitem__` y describimos cuándo un " +":ref:`subscription` da como resultado que se llame a " +"``__class_getitem__()`` en lugar de :meth:`~object.__getitem__`" #: ../Doc/reference/datamodel.rst:2408 msgid "Emulating callable objects" @@ -4091,79 +4195,84 @@ msgid "" "defined, ``x(arg1, arg2, ...)`` roughly translates to ``type(x).__call__(x, " "arg1, ...)``." msgstr "" -"Es llamado cuando la instancia es “llamada” como una función; si este método " -"es definido, ``x(arg1, arg2, …)`` es una clave corta para ``x.__call__(arg1, " -"arg2, …)``." +"Es llamado cuando la instancia es “llamada” como una función; si este método" +" es definido, ``x(arg1, arg2, …)`` es una clave corta para " +"``x.__call__(arg1, arg2, …)``." #: ../Doc/reference/datamodel.rst:2422 msgid "Emulating container types" msgstr "Emulando tipos de contenedores" #: ../Doc/reference/datamodel.rst:2424 -#, fuzzy msgid "" "The following methods can be defined to implement container objects. " "Containers usually are :term:`sequences ` (such as :class:`lists " -"` or :class:`tuples `) or :term:`mappings ` (like :" -"class:`dictionaries `), but can represent other containers as well. " +"` or :class:`tuples `) or :term:`mappings ` (like " +":class:`dictionaries `), but can represent other containers as well. " "The first set of methods is used either to emulate a sequence or to emulate " "a mapping; the difference is that for a sequence, the allowable keys should " "be the integers *k* for which ``0 <= k < N`` where *N* is the length of the " "sequence, or :class:`slice` objects, which define a range of items. It is " -"also recommended that mappings provide the methods :meth:`keys`, :meth:" -"`values`, :meth:`items`, :meth:`get`, :meth:`clear`, :meth:`setdefault`, :" -"meth:`pop`, :meth:`popitem`, :meth:`!copy`, and :meth:`update` behaving " -"similar to those for Python's standard :class:`dictionary ` objects. " -"The :mod:`collections.abc` module provides a :class:`~collections.abc." -"MutableMapping` :term:`abstract base class` to help create those methods " -"from a base set of :meth:`~object.__getitem__`, :meth:`~object." -"__setitem__`, :meth:`~object.__delitem__`, and :meth:`keys`. Mutable " -"sequences should provide methods :meth:`append`, :meth:`count`, :meth:" -"`index`, :meth:`extend`, :meth:`insert`, :meth:`pop`, :meth:`remove`, :meth:" -"`reverse` and :meth:`sort`, like Python standard :class:`list` objects. " -"Finally, sequence types should implement addition (meaning concatenation) " -"and multiplication (meaning repetition) by defining the methods :meth:" -"`~object.__add__`, :meth:`~object.__radd__`, :meth:`~object.__iadd__`, :meth:" -"`~object.__mul__`, :meth:`~object.__rmul__` and :meth:`~object.__imul__` " -"described below; they should not define other numerical operators. It is " -"recommended that both mappings and sequences implement the :meth:`~object." -"__contains__` method to allow efficient use of the ``in`` operator; for " -"mappings, ``in`` should search the mapping's keys; for sequences, it should " -"search through the values. It is further recommended that both mappings and " -"sequences implement the :meth:`~object.__iter__` method to allow efficient " -"iteration through the container; for mappings, :meth:`__iter__` should " -"iterate through the object's keys; for sequences, it should iterate through " -"the values." -msgstr "" -"Los siguientes métodos pueden ser definidos para implementar objetos " -"contenedores. Los contenedores son generalmente secuencias (como listas o " -"tuplas) o mapeos (como diccionarios), pero también pueden representar otros " -"contenedores. La primera colección de métodos es utilizada ya sea para " +"also recommended that mappings provide the methods :meth:`keys`, " +":meth:`values`, :meth:`items`, :meth:`get`, :meth:`clear`, " +":meth:`setdefault`, :meth:`pop`, :meth:`popitem`, :meth:`!copy`, and " +":meth:`update` behaving similar to those for Python's standard " +":class:`dictionary ` objects. The :mod:`collections.abc` module " +"provides a :class:`~collections.abc.MutableMapping` :term:`abstract base " +"class` to help create those methods from a base set of " +":meth:`~object.__getitem__`, :meth:`~object.__setitem__`, " +":meth:`~object.__delitem__`, and :meth:`keys`. Mutable sequences should " +"provide methods :meth:`append`, :meth:`count`, :meth:`index`, " +":meth:`extend`, :meth:`insert`, :meth:`pop`, :meth:`remove`, :meth:`reverse`" +" and :meth:`sort`, like Python standard :class:`list` objects. Finally, " +"sequence types should implement addition (meaning concatenation) and " +"multiplication (meaning repetition) by defining the methods " +":meth:`~object.__add__`, :meth:`~object.__radd__`, :meth:`~object.__iadd__`," +" :meth:`~object.__mul__`, :meth:`~object.__rmul__` and " +":meth:`~object.__imul__` described below; they should not define other " +"numerical operators. It is recommended that both mappings and sequences " +"implement the :meth:`~object.__contains__` method to allow efficient use of " +"the ``in`` operator; for mappings, ``in`` should search the mapping's keys; " +"for sequences, it should search through the values. It is further " +"recommended that both mappings and sequences implement the " +":meth:`~object.__iter__` method to allow efficient iteration through the " +"container; for mappings, :meth:`__iter__` should iterate through the " +"object's keys; for sequences, it should iterate through the values." +msgstr "" +"Los siguientes métodos se pueden definir para implementar objetos " +"contenedores. Los contenedores suelen ser :term:`sequences ` (como" +" :class:`lists ` o :class:`tuples `) o :term:`mappings " +"` (como :class:`dictionaries `), pero también pueden " +"representar otros contenedores. El primer conjunto de métodos se usa para " "emular una secuencia o para emular un mapeo; la diferencia es que para una " -"secuencia, las llaves permitidas deben ser los enteros *k* por lo que ``0 <= " -"k < N`` donde *N* es la longitud de la secuencia, o secciones de objetos, " -"los cuales definen un rango de elementos. También es recomendado que los " -"mapeos proporcionen los métodos :meth:`keys`, :meth:`values`, :meth:" -"`items`, :meth:`get`, :meth:`clear`, :meth:`setdefault`, :meth:`pop`, :meth:" -"`popitem`, :meth:`!copy`, y :meth:`update` comportándose de manera similar a " -"aquellos para los objetos de diccionario estándar de Python. El módulo :mod:" -"`collections.abc` proporciona una clase base abstracta :class:`~collections." -"abc.MutableMapping` que ayuda a crear aquellos métodos desde un conjunto " -"base de :meth:`__getitem__`, :meth:`__setitem__`, :meth:`__delitem__`, y :" -"meth:`keys`. Secuencias mutables deben proporcionar métodos :meth:`append`, :" -"meth:`count`, :meth:`index`, :meth:`extend`, :meth:`insert`, :meth:`pop`, :" -"meth:`remove`, :meth:`reverse` y :meth:`sort`, como objetos de lista " -"estándar de Python. Por último, tipos de secuencia deben implementar adición " -"(concatenación) y multiplicación (repetición) al definir los métodos :meth:" -"`__add__`, :meth:`__radd__`, :meth:`__iadd__`, :meth:`__mul__`, :meth:" -"`__rmul__` y :meth:`__imul__` descritos a continuación; no deben definir " -"otros operadores numéricos. Es recomendado que ambos mapeos y secuencias " -"implementen el método :meth:`__contains__` para permitir el uso eficiente " -"del operador ``in``; para mapeos, ``in`` debe buscar las llaves de los " -"mapeos; para secuencias, debe buscar a través de los valores. Además es " -"recomendado que tanto mapeos como secuencias implementen el método :meth:" -"`__iter__` para permitir una iteración eficiente por el contenedor; para " -"mapeos, :meth:`__iter__` debe iterar a través de las llaves del objeto; para " +"secuencia, las claves permitidas deberían ser los enteros *k* para los " +"cuales ``0 <= k < N`` donde *N* es la longitud de la secuencia, u objetos " +":class:`slice`, que definen un rango de elementos. También se recomienda que" +" las asignaciones proporcionen los métodos :meth:`keys`, :meth:`values`, " +":meth:`items`, :meth:`get`, :meth:`clear`, :meth:`setdefault`, :meth:`pop`, " +":meth:`popitem`, :meth:`!copy` y :meth:`update` con un comportamiento " +"similar al de los objetos :class:`dictionary ` estándar de Python. El " +"módulo :mod:`collections.abc` proporciona un " +":class:`~collections.abc.MutableMapping` :term:`abstract base class` para " +"ayudar a crear esos métodos a partir de un conjunto base de " +":meth:`~object.__getitem__`, :meth:`~object.__setitem__`, " +":meth:`~object.__delitem__` y :meth:`keys`. Las secuencias mutables deben " +"proporcionar los métodos :meth:`append`, :meth:`count`, :meth:`index`, " +":meth:`extend`, :meth:`insert`, :meth:`pop`, :meth:`remove`, :meth:`reverse`" +" y :meth:`sort`, como los objetos :class:`list` estándar de Python. " +"Finalmente, los tipos de secuencia deben implementar la suma (es decir, la " +"concatenación) y la multiplicación (es decir, la repetición) definiendo los " +"métodos :meth:`~object.__add__`, :meth:`~object.__radd__`, " +":meth:`~object.__iadd__`, :meth:`~object.__mul__`, :meth:`~object.__rmul__` " +"y :meth:`~object.__imul__` que se describen a continuación; no deben definir" +" otros operadores numéricos. Se recomienda que tanto las asignaciones como " +"las secuencias implementen el método :meth:`~object.__contains__` para " +"permitir un uso eficiente del operador ``in``; para asignaciones, ``in`` " +"debe buscar las claves de la asignación; para secuencias, debe buscar a " +"través de los valores. Se recomienda además que tanto las asignaciones como " +"las secuencias implementen el método :meth:`~object.__iter__` para permitir " +"una iteración eficiente a través del contenedor; para asignaciones, " +":meth:`__iter__` debe iterar a través de las claves del objeto; para " "secuencias, debe iterar a través de los valores." #: ../Doc/reference/datamodel.rst:2464 @@ -4180,38 +4289,39 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2471 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:" -"`len`) may raise :exc:`OverflowError`. To prevent raising :exc:`!" -"OverflowError` by truth value testing, an object must define a :meth:" -"`__bool__` method." +"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:`len`) may raise :exc:`OverflowError`. To prevent raising " +":exc:`!OverflowError` by truth value testing, an object must define a " +":meth:`__bool__` method." msgstr "" "En CPython, se requiere que la longitud sea como mucho :attr:`sys.maxsize`. " "Si la longitud es más grande que :attr:`!sys.maxsize` algunas " -"características (como :func:`len`) pueden lanzar una excepción :exc:" -"`OverflowError`. Para prevenir lanzar una excepción :exc:`!OverflowError` al " -"validar la verdad de un valor, un objeto debe definir un método :meth:" -"`__bool__`." +"características (como :func:`len`) pueden lanzar una excepción " +":exc:`OverflowError`. Para prevenir lanzar una excepción " +":exc:`!OverflowError` al validar la verdad de un valor, un objeto debe " +"definir un método :meth:`__bool__`." #: ../Doc/reference/datamodel.rst:2480 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). " -"The length must be an integer ``>=`` 0. The return value may also be :const:" -"`NotImplemented`, which is treated the same as if the ``__length_hint__`` " -"method didn't exist at all. This method is purely an optimization and is " -"never required for correctness." +"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). The length must be an integer ``>=`` 0. The return value may also " +"be :const:`NotImplemented`, which is treated the same as if the " +"``__length_hint__`` method didn't exist at all. This method is purely an " +"optimization and is never required for correctness." msgstr "" "Es llamado para implementar :func:`operator.length_hint`. Debe retornar una " "longitud estimada para el objeto (que puede ser mayor o menor que la " "longitud actual). La longitud debe ser un entero ``>=`` 0. El valor de " -"retorno también debe ser :const:`NotImplemented` el cual es tratado de igual " -"forma a que si el método ``__length_hint__`` no existiera en absoluto. Este " -"método es puramente una optimización y nunca es requerido para precisión." +"retorno también debe ser :const:`NotImplemented` el cual es tratado de igual" +" forma a que si el método ``__length_hint__`` no existiera en absoluto. Este" +" método es puramente una optimización y nunca es requerido para precisión." #: ../Doc/reference/datamodel.rst:2494 msgid "" -"Slicing is done exclusively with the following three methods. A call like ::" +"Slicing is done exclusively with the following three methods. A call like " +"::" msgstr "" "La segmentación se hace exclusivamente con los siguientes tres métodos. Un " "llamado como ::" @@ -4223,31 +4333,31 @@ msgstr "es traducido a ::" #: ../Doc/reference/datamodel.rst:2502 msgid "and so forth. Missing slice items are always filled in with ``None``." msgstr "" -"etcétera. Elementos faltantes de segmentos siempre son llenados con ``None``." +"etcétera. Elementos faltantes de segmentos siempre son llenados con " +"``None``." #: ../Doc/reference/datamodel.rst:2507 -#, fuzzy msgid "" -"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 " +"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 "" -"Es llamado para implementar la evaluación de ``self[key]``. Para tipos de " -"secuencia, las llaves aceptadas deben ser enteros y objetos de segmento. Se " -"debe tomar en cuenta que la interpretación especial de índices negativos (si " -"la clase desea emular un tipo de secuencia) depende del método :meth:" -"`__getitem__`. Si *key* es de un tipo apropiado, se puede lanzar una " -"excepción :exc:`TypeError`; si es de un valor afuera de la colección de " -"índices para la secuencia (después de alguna interpretación especial de " -"valores negativos), se debe lanzar una excepción :exc:`IndexError`. Para " -"tipos de mapeos, si falta *key* (no en el contenedor), la excepción :exc:" -"`KeyError` debe ser lanzada." +"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 "" +"Llamado a implementar la evaluación de ``self[key]``. Para los tipos " +":term:`sequence`, las claves aceptadas deben ser números enteros y objetos " +"de división. Tenga en cuenta que la interpretación especial de los índices " +"negativos (si la clase desea emular un tipo :term:`sequence`) depende del " +"método :meth:`__getitem__`. Si *key* es de un tipo inapropiado, se puede " +"generar :exc:`TypeError`; si tiene un valor fuera del conjunto de índices de" +" la secuencia (después de cualquier interpretación especial de valores " +"negativos), se debe generar :exc:`IndexError`. Para los tipos " +":term:`mapping`, si falta *key* (no en el contenedor), debe generarse " +":exc:`KeyError`." #: ../Doc/reference/datamodel.rst:2519 msgid "" @@ -4260,18 +4370,21 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2524 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." +"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 "" +"Cuando :ref:`subscripting` a *class*, se puede llamar al " +"método de clase especial :meth:`~object.__class_getitem__` en lugar de " +"``__getitem__()``. Ver :ref:`classgetitem-versus-getitem` para más detalles." #: ../Doc/reference/datamodel.rst:2532 msgid "" -"Called to implement assignment to ``self[key]``. Same note as for :meth:" -"`__getitem__`. This should only be implemented for mappings if the objects " -"support changes to the values for keys, or if new keys can be added, or for " -"sequences if elements can be replaced. The same exceptions should be raised " -"for improper *key* values as for the :meth:`__getitem__` method." +"Called to implement assignment to ``self[key]``. Same note as for " +":meth:`__getitem__`. This should only be implemented for mappings if the " +"objects support changes to the values for keys, or if new keys can be added," +" or for sequences if elements can be replaced. The same exceptions should " +"be raised for improper *key* values as for the :meth:`__getitem__` method." msgstr "" "Es llamado para implementar la asignación a ``self[key]``. Lo mismo con " "respecto a :meth:`__getitem__`. Esto solo debe ser implementado para mapeos " @@ -4282,40 +4395,39 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2541 msgid "" -"Called to implement deletion of ``self[key]``. Same note as for :meth:" -"`__getitem__`. This should only be implemented for mappings if the objects " -"support removal of keys, or for sequences if elements can be removed from " -"the sequence. The same exceptions should be raised for improper *key* " -"values as for the :meth:`__getitem__` method." +"Called to implement deletion of ``self[key]``. Same note as for " +":meth:`__getitem__`. This should only be implemented for mappings if the " +"objects support removal of keys, or for sequences if elements can be removed" +" from the sequence. The same exceptions should be raised for improper *key*" +" values as for the :meth:`__getitem__` method." msgstr "" "Es llamado para implementar el borrado de ``self[key]``. Lo mismo con " "respecto a :meth:`__getitem__`. Esto solo debe ser implementado para mapeos " "si los objetos permiten el borrado de llaves, o para secuencias si los " "elementos pueden ser eliminados de la secuencia. Las mismas excepciones " -"deben ser lanzadas por valores de *key* inapropiados con respecto al método :" -"meth:`__getitem__`." +"deben ser lanzadas por valores de *key* inapropiados con respecto al método " +":meth:`__getitem__`." #: ../Doc/reference/datamodel.rst:2550 msgid "" -"Called by :class:`dict`\\ .\\ :meth:`__getitem__` to implement ``self[key]`` " -"for dict subclasses when key is not in the dictionary." +"Called by :class:`dict`\\ .\\ :meth:`__getitem__` to implement ``self[key]``" +" for dict subclasses when key is not in the dictionary." msgstr "" "Es llamado por :class:`dict`\\ .\\ :meth:`__getitem__` para implementar " -"``self[key]`` para subclases de diccionarios cuando la llave no se encuentra " -"en el diccionario." +"``self[key]`` para subclases de diccionarios cuando la llave no se encuentra" +" en el diccionario." #: ../Doc/reference/datamodel.rst:2556 -#, fuzzy msgid "" "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." +"the objects in the container. For mappings, it should iterate over the keys" +" of the container." msgstr "" -"Este método es llamado cuando se requiere un iterador para un contenedor. " -"Este método debe retornar un nuevo objeto iterador que pueda iterar todos " -"los objetos del contenedor. Para mapeos, debe iterar sobre las llaves del " -"contenedor." +"Se llama a este método cuando se requiere un :term:`iterator` para un " +"contenedor. Este método debería devolver un nuevo objeto iterador que pueda " +"iterar sobre todos los objetos del contenedor. Para las asignaciones, debe " +"iterar sobre las claves del contenedor." #: ../Doc/reference/datamodel.rst:2564 msgid "" @@ -4325,28 +4437,29 @@ msgid "" msgstr "" "Es llamado (si existe) por la función incorporada :func:`reversed` para " "implementar una interacción invertida. Debe retornar un nuevo objeto " -"iterador que itere sobre todos los objetos en el contenedor en orden inverso." +"iterador que itere sobre todos los objetos en el contenedor en orden " +"inverso." #: ../Doc/reference/datamodel.rst:2568 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 :" -"meth:`__getitem__`). Objects that support the sequence protocol should only " -"provide :meth:`__reversed__` if they can provide an implementation that is " -"more efficient than the one provided by :func:`reversed`." +"built-in will fall back to using the sequence protocol (:meth:`__len__` and " +":meth:`__getitem__`). Objects that support the sequence protocol should " +"only provide :meth:`__reversed__` if they can provide an implementation that" +" is more efficient than the one provided by :func:`reversed`." msgstr "" "Si el método :meth:`__reversed__` no es proporcionado, la función " "incorporada :func:`reversed` recurrirá a utilizar el protocolo de secuencia " "(:meth:`__len__` y :meth:`__getitem__`). Objetos que permiten el protocolo " -"de secuencia deben únicamente proporcionar :meth:`__reversed__` si no pueden " -"proporcionar una implementación que sea más eficiente que la proporcionada " +"de secuencia deben únicamente proporcionar :meth:`__reversed__` si no pueden" +" proporcionar una implementación que sea más eficiente que la proporcionada " "por :func:`reversed`." #: ../Doc/reference/datamodel.rst:2575 msgid "" "The membership test operators (:keyword:`in` and :keyword:`not in`) are " -"normally implemented as an iteration through a container. However, container " -"objects can supply the following special method with a more efficient " +"normally implemented as an iteration through a container. However, container" +" objects can supply the following special method with a more efficient " "implementation, which also does not require the object be iterable." msgstr "" "Los operadores de prueba de pertenencia (:keyword:`in` and :keyword:`not " @@ -4357,8 +4470,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2582 msgid "" -"Called to implement membership test operators. Should return true if *item* " -"is in *self*, false otherwise. For mapping objects, this should consider " +"Called to implement membership test operators. Should return true if *item*" +" is in *self*, false otherwise. For mapping objects, this should consider " "the keys of the mapping rather than the values or the key-item pairs." msgstr "" "Es llamado para implementar operadores de prueba de pertenencia. Deben " @@ -4375,8 +4488,8 @@ msgid "" msgstr "" "Para objetos que no definen :meth:`__contains__`, la prueba de pertenencia " "primero intenta la iteración a través de :meth:`__iter__`, y luego el " -"antiguo protocolo de iteración de secuencia a través de :meth:`__getitem__`, " -"ver :ref:`esta sección en la referencia del lenguaje `." #: ../Doc/reference/datamodel.rst:2595 @@ -4386,8 +4499,8 @@ msgstr "Emulando tipos numéricos" #: ../Doc/reference/datamodel.rst:2597 msgid "" "The following methods can be defined to emulate numeric objects. Methods " -"corresponding to operations that are not supported by the particular kind of " -"number implemented (e.g., bitwise operations for non-integral numbers) " +"corresponding to operations that are not supported by the particular kind of" +" number implemented (e.g., bitwise operations for non-integral numbers) " "should be left undefined." msgstr "" "Los siguientes métodos pueden ser definidos para emular objetos numéricos. " @@ -4396,29 +4509,28 @@ msgstr "" "enteros) se deben dejar sin definir." #: ../Doc/reference/datamodel.rst:2623 -#, fuzzy msgid "" "These methods are called to implement the binary arithmetic operations " -"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :func:" -"`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``). For instance, to " -"evaluate the expression ``x + y``, where *x* is an instance of a class that " -"has an :meth:`__add__` method, ``type(x).__add__(x, y)`` is called. The :" -"meth:`__divmod__` method should be the equivalent to using :meth:" -"`__floordiv__` and :meth:`__mod__`; it should not be related to :meth:" -"`__truediv__`. Note that :meth:`__pow__` should be defined to accept an " -"optional third argument if the ternary version of the built-in :func:`pow` " -"function is to be supported." -msgstr "" -"Estos métodos son llamados para implementar las operaciones aritméticas " -"binarias (``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :" -"func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``). Por ejemplo, para " -"evaluar la expresión ``x + y``, donde *x* es instancia de una clase que " -"tiene un método :meth:`__add__`, ``x.__add__(y)`` es llamado. El método :" -"meth:`__divmod__` debe ser el equivalente a usar :meth:`__floordiv__` y :" -"meth:`__mod__`; no debe ser relacionado a :meth:`__truediv__`. Se debe tomar " -"en cuenta que :meth:`__pow__` debe ser definido para aceptar un tercer " -"argumento opcional si la versión ternaria de la función incorporada :func:" -"`pow` es soportada." +"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " +":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``). For instance, to" +" evaluate the expression ``x + y``, where *x* is an instance of a class that" +" has an :meth:`__add__` method, ``type(x).__add__(x, y)`` is called. The " +":meth:`__divmod__` method should be the equivalent to using " +":meth:`__floordiv__` and :meth:`__mod__`; it should not be related to " +":meth:`__truediv__`. Note that :meth:`__pow__` should be defined to accept " +"an optional third argument if the ternary version of the built-in " +":func:`pow` function is to be supported." +msgstr "" +"Estos métodos se llaman para implementar las operaciones aritméticas " +"binarias (``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " +":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``). Por ejemplo, para" +" evaluar la expresión ``x + y``, donde *x* es una instancia de una clase que" +" tiene un método :meth:`__add__`, se llama a ``type(x).__add__(x, y)``. El " +"método :meth:`__divmod__` debe ser equivalente a usar :meth:`__floordiv__` y" +" :meth:`__mod__`; no debe estar relacionado con :meth:`__truediv__`. Tenga " +"en cuenta que :meth:`__pow__` debe definirse para aceptar un tercer " +"argumento opcional si se va a admitir la versión ternaria de la función " +"integrada :func:`pow`." #: ../Doc/reference/datamodel.rst:2634 msgid "" @@ -4429,27 +4541,26 @@ msgstr "" "suministrados, debe retornar ``NotImplemented``." #: ../Doc/reference/datamodel.rst:2657 -#, fuzzy msgid "" "These methods are called to implement the binary arithmetic operations " -"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :func:" -"`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``) with reflected (swapped) " -"operands. These functions are only called if the left operand does not " -"support the corresponding operation [#]_ and the operands are of different " -"types. [#]_ For instance, to evaluate the expression ``x - y``, where *y* is " -"an instance of a class that has an :meth:`__rsub__` method, ``type(y)." -"__rsub__(y, x)`` is called if ``type(x).__sub__(x, y)`` returns " +"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " +":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``) with reflected " +"(swapped) operands. These functions are only called if the left operand " +"does not support the corresponding operation [#]_ and the operands are of " +"different types. [#]_ For instance, to evaluate the expression ``x - y``, " +"where *y* is an instance of a class that has an :meth:`__rsub__` method, " +"``type(y).__rsub__(y, x)`` is called if ``type(x).__sub__(x, y)`` returns " "*NotImplemented*." msgstr "" -"Estos métodos son llamados para implementar las operaciones aritméticas " -"binarias (``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :" -"func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``) con operandos " -"reflejados (intercambiados). Estas funciones son llamadas únicamente si el " -"operando izquierdo no soporta la operación correspondiente [#]_ y los " -"operandos son de tipos diferentes. [#]_ Por ejemplo, para evaluar la " -"expresión ``x - y``, donde *y* es instancia de una clase que tiene un " -"método :meth:`__rsub__`, ``y.__rsub__(x)`` es llamado si ``x.__sub__(y)`` " -"retorna *NotImplemented*." +"Estos métodos se llaman para implementar las operaciones aritméticas " +"binarias (``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " +":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``) con operandos " +"reflejados (intercambiados). Estas funciones solo se llaman si el operando " +"izquierdo no admite la operación correspondiente [#]_ y los operandos son de" +" diferentes tipos. [#]_ Por ejemplo, para evaluar la expresión ``x - y``, " +"donde *y* es una instancia de una clase que tiene un método " +":meth:`__rsub__`, se llama a ``type(y).__rsub__(y, x)`` si " +"``type(x).__sub__(x, y)`` devuelve *NotImplemented*." #: ../Doc/reference/datamodel.rst:2669 msgid "" @@ -4471,20 +4582,20 @@ msgstr "" "Si el tipo del operando de la derecha es una subclase del tipo del operando " "de la izquierda y esa subclase proporciona el método reflejado para la " "operación, este método será llamado antes del método no reflejado del " -"operando izquierdo. Este comportamiento permite que las subclases anulen las " -"operaciones de sus predecesores." +"operando izquierdo. Este comportamiento permite que las subclases anulen las" +" operaciones de sus predecesores." #: ../Doc/reference/datamodel.rst:2695 msgid "" "These methods are called to implement the augmented arithmetic assignments " "(``+=``, ``-=``, ``*=``, ``@=``, ``/=``, ``//=``, ``%=``, ``**=``, ``<<=``, " "``>>=``, ``&=``, ``^=``, ``|=``). These methods should attempt to do the " -"operation in-place (modifying *self*) and return the result (which could be, " -"but does not have to be, *self*). If a specific method is not defined, the " -"augmented assignment falls back to the normal methods. For instance, if *x* " -"is an instance of a class with an :meth:`__iadd__` method, ``x += y`` is " -"equivalent to ``x = x.__iadd__(y)`` . Otherwise, ``x.__add__(y)`` and ``y." -"__radd__(x)`` are considered, as with the evaluation of ``x + y``. In " +"operation in-place (modifying *self*) and return the result (which could be," +" but does not have to be, *self*). If a specific method is not defined, the" +" augmented assignment falls back to the normal methods. For instance, if " +"*x* is an instance of a class with an :meth:`__iadd__` method, ``x += y`` is" +" equivalent to ``x = x.__iadd__(y)`` . Otherwise, ``x.__add__(y)`` and " +"``y.__radd__(x)`` are considered, as with the evaluation of ``x + y``. In " "certain situations, augmented assignment can result in unexpected errors " "(see :ref:`faq-augmented-assignment-tuple-error`), but this behavior is in " "fact part of the data model." @@ -4492,32 +4603,32 @@ msgstr "" "Estos métodos son llamados para implementar las asignaciones aritméticas " "aumentadas (``+=``, ``-=``, ``*=``, ``@=``, ``/=``, ``//=``, ``%=``, " "``**=``, ``<<=``, ``>>=``, ``&=``, ``^=``, ``|=``). Estos métodos deben " -"intentar realizar la operación *in-place* (modificando *self*) y retornar el " -"resultado (que puede, pero no tiene que ser *self*). Si un método específico " -"no es definido, la asignación aumentada regresa a los métodos normales. Por " -"ejemplo, si *x* es la instancia de una clase con el método :meth:`__iadd__`, " -"``x += y`` es equivalente a ``x = x.__iadd__(y)``. De lo contrario ``x." -"__add__(y)`` y ``y.__radd__(x)`` se consideran al igual que con la " -"evaluación de ``x + y``. En ciertas situaciones, asignaciones aumentadas " -"pueden resultar en errores no esperados (ver :ref:`faq-augmented-assignment-" -"tuple-error`), pero este comportamiento es en realidad parte del modelo de " -"datos." +"intentar realizar la operación *in-place* (modificando *self*) y retornar el" +" resultado (que puede, pero no tiene que ser *self*). Si un método " +"específico no es definido, la asignación aumentada regresa a los métodos " +"normales. Por ejemplo, si *x* es la instancia de una clase con el método " +":meth:`__iadd__`, ``x += y`` es equivalente a ``x = x.__iadd__(y)``. De lo " +"contrario ``x.__add__(y)`` y ``y.__radd__(x)`` se consideran al igual que " +"con la evaluación de ``x + y``. En ciertas situaciones, asignaciones " +"aumentadas pueden resultar en errores no esperados (ver :ref:`faq-augmented-" +"assignment-tuple-error`), pero este comportamiento es en realidad parte del " +"modelo de datos." #: ../Doc/reference/datamodel.rst:2716 msgid "" -"Called to implement the unary arithmetic operations (``-``, ``+``, :func:" -"`abs` and ``~``)." +"Called to implement the unary arithmetic operations (``-``, ``+``, " +":func:`abs` and ``~``)." msgstr "" "Es llamado para implementar las operaciones aritméticas unarias (``-``, " "``+``, :func:`abs` and ``~``)." #: ../Doc/reference/datamodel.rst:2729 msgid "" -"Called to implement the built-in functions :func:`complex`, :func:`int` and :" -"func:`float`. Should return a value of the appropriate type." +"Called to implement the built-in functions :func:`complex`, :func:`int` and " +":func:`float`. Should return a value of the appropriate type." msgstr "" -"Es llamado para implementar las funciones incorporadas :func:`complex`, :" -"func:`int` y :func:`float`. Debe retornar un valor del tipo apropiado." +"Es llamado para implementar las funciones incorporadas :func:`complex`, " +":func:`int` y :func:`float`. Debe retornar un valor del tipo apropiado." #: ../Doc/reference/datamodel.rst:2736 msgid "" @@ -4529,19 +4640,19 @@ msgid "" msgstr "" "Es llamado para implementar :func:`operator.index`, y cuando sea que Python " "necesite convertir sin pérdidas el objeto numérico a un objeto entero (tal " -"como en la segmentación o *slicing*, o las funciones incorporadas :func:" -"`bin`, :func:`hex` y :func:`oct`). La presencia de este método indica que el " -"objeto numérico es un tipo entero. Debe retornar un entero." +"como en la segmentación o *slicing*, o las funciones incorporadas " +":func:`bin`, :func:`hex` y :func:`oct`). La presencia de este método indica " +"que el objeto numérico es un tipo entero. Debe retornar un entero." #: ../Doc/reference/datamodel.rst:2742 msgid "" "If :meth:`__int__`, :meth:`__float__` and :meth:`__complex__` are not " -"defined then corresponding built-in functions :func:`int`, :func:`float` " -"and :func:`complex` fall back to :meth:`__index__`." +"defined then corresponding built-in functions :func:`int`, :func:`float` and" +" :func:`complex` fall back to :meth:`__index__`." msgstr "" "Si :meth:`__int__`, :meth:`__float__` y :meth:`__complex__` no son " -"definidos, entonces todas las funciones incorporadas correspondientes :func:" -"`int`, :func:`float` y :func:`complex` vuelven a :meth:`__index__`." +"definidos, entonces todas las funciones incorporadas correspondientes " +":func:`int`, :func:`float` y :func:`complex` vuelven a :meth:`__index__`." #: ../Doc/reference/datamodel.rst:2754 msgid "" @@ -4552,20 +4663,22 @@ msgid "" "(typically an :class:`int`)." msgstr "" "Es llamado para implementar la función incorporada :func:`round` y las " -"funciones :mod:`math` :func:`~math.trunc`, :func:`~math.floor` y :func:" -"`~math.ceil`. A menos que *ndigits* sea pasado a :meth:`!__round__` todos " -"estos métodos deben retornar el valor del objeto truncado a :class:`~numbers." -"Integral` (normalmente :class:`int`)." +"funciones :mod:`math` :func:`~math.trunc`, :func:`~math.floor` y " +":func:`~math.ceil`. A menos que *ndigits* sea pasado a :meth:`!__round__` " +"todos estos métodos deben retornar el valor del objeto truncado a " +":class:`~numbers.Integral` (normalmente :class:`int`)." #: ../Doc/reference/datamodel.rst:2760 msgid "" -"The built-in function :func:`int` falls back to :meth:`__trunc__` if " -"neither :meth:`__int__` nor :meth:`__index__` is defined." +"The built-in function :func:`int` falls back to :meth:`__trunc__` if neither" +" :meth:`__int__` nor :meth:`__index__` is defined." msgstr "" +"La función integrada :func:`int` recurre a :meth:`__trunc__` si no se " +"definen ni :meth:`__int__` ni :meth:`__index__`." #: ../Doc/reference/datamodel.rst:2763 msgid "The delegation of :func:`int` to :meth:`__trunc__` is deprecated." -msgstr "" +msgstr "La delegación de :func:`int` a :meth:`__trunc__` está obsoleta." #: ../Doc/reference/datamodel.rst:2770 msgid "With Statement Context Managers" @@ -4573,20 +4686,20 @@ msgstr "Gestores de Contexto en la Declaración *with*" #: ../Doc/reference/datamodel.rst:2772 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 " -"handles the entry into, and the exit from, the desired runtime context for " +"A :dfn:`context manager` is an object that defines the runtime context to be" +" established when executing a :keyword:`with` statement. The context manager" +" handles the entry into, and the exit from, the desired runtime context for " "the execution of the block of code. Context managers are normally invoked " -"using the :keyword:`!with` statement (described in section :ref:`with`), but " -"can also be used by directly invoking their methods." +"using the :keyword:`!with` statement (described in section :ref:`with`), but" +" can also be used by directly invoking their methods." msgstr "" "Un :dfn:`context manager` es un objeto que define el contexto en tiempo de " -"ejecución a ser establecido cuando se ejecuta una declaración :keyword:" -"`with`. El gestor de contexto maneja la entrada y la salida del contexto en " -"tiempo de ejecución deseado para la ejecución del bloque de código. Los " -"gestores de contexto son normalmente invocados utilizando la declaración :" -"keyword:`!with` (descritos en la sección :ref:`with`), pero también pueden " -"ser utilizados al invocar directamente sus métodos." +"ejecución a ser establecido cuando se ejecuta una declaración " +":keyword:`with`. El gestor de contexto maneja la entrada y la salida del " +"contexto en tiempo de ejecución deseado para la ejecución del bloque de " +"código. Los gestores de contexto son normalmente invocados utilizando la " +"declaración :keyword:`!with` (descritos en la sección :ref:`with`), pero " +"también pueden ser utilizados al invocar directamente sus métodos." #: ../Doc/reference/datamodel.rst:2783 msgid "" @@ -4601,14 +4714,14 @@ msgstr "" msgid "" "For more information on context managers, see :ref:`typecontextmanager`." msgstr "" -"Para más información sobre gestores de contexto, ver :ref:" -"`typecontextmanager`." +"Para más información sobre gestores de contexto, ver " +":ref:`typecontextmanager`." #: ../Doc/reference/datamodel.rst:2791 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 " -"the :keyword:`!as` clause of the statement, if any." +"statement will bind this method's return value to the target(s) specified in" +" the :keyword:`!as` clause of the statement, if any." msgstr "" "Ingresa al contexto en tiempo de ejecución relacionado con este objeto. La " "declaración :keyword:`with` ligará el valor de retorno de este método al " @@ -4617,8 +4730,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2798 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 " +"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 " "without an exception, all three arguments will be :const:`None`." msgstr "" "Sale del contexto en tiempo de ejecución relacionado a este objeto. Los " @@ -4627,8 +4740,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2802 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. " +"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. " "Otherwise, the exception will be processed normally upon exit from this " "method." msgstr "" @@ -4661,29 +4774,29 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2820 msgid "Customizing positional arguments in class pattern matching" msgstr "" -"Personalización de argumentos posicionales en la coincidencia de patrones de " -"clase" +"Personalización de argumentos posicionales en la coincidencia de patrones de" +" clase" #: ../Doc/reference/datamodel.rst:2822 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 " -"without special support in ``MyClass``. To be able to use that kind of " +"are not allowed by default, i.e. ``case MyClass(x, y)`` is typically invalid" +" without special support in ``MyClass``. To be able to use that kind of " "patterns, the class needs to define a *__match_args__* attribute." msgstr "" "Cuando se usa un nombre de clase en un patrón, los argumentos posicionales " "en el patrón no están permitidos de forma predeterminada, es decir, ``case " "MyClass(x, y)`` generalmente no es válido sin soporte especial en " -"``MyClass``. Para poder usar ese tipo de patrones, la clase necesita definir " -"un atributo *__match_args__*." +"``MyClass``. Para poder usar ese tipo de patrones, la clase necesita definir" +" un atributo *__match_args__*." #: ../Doc/reference/datamodel.rst:2829 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 " "will be converted into a keyword argument, using the corresponding value in " -"*__match_args__* as the keyword. The absence of this attribute is equivalent " -"to setting it to ``()``." +"*__match_args__* as the keyword. The absence of this attribute is equivalent" +" to setting it to ``()``." msgstr "" "A esta variable de clase se le puede asignar una tupla de cadenas. Cuando " "esta clase se utiliza en un patrón de clase con argumentos posicionales, " @@ -4697,14 +4810,14 @@ msgid "" "\"right\")`` that means that ``case MyClass(x, y)`` is equivalent to ``case " "MyClass(left=x, center=y)``. Note that the number of arguments in the " "pattern must be smaller than or equal to the number of elements in " -"*__match_args__*; if it is larger, the pattern match attempt will raise a :" -"exc:`TypeError`." +"*__match_args__*; if it is larger, the pattern match attempt will raise a " +":exc:`TypeError`." msgstr "" "Por ejemplo, si ``MyClass.__match_args__`` es ``(\"left\", \"center\", " "\"right\")`` eso significa que ``case MyClass(x, y)`` es equivalente a " "``case MyClass(left=x, center=y)``. Ten en cuenta que el número de " -"argumentos en el patrón debe ser menor o igual que el número de elementos en " -"*__match_args__*; si es más grande, el intento de coincidencia de patrón " +"argumentos en el patrón debe ser menor o igual que el número de elementos en" +" *__match_args__*; si es más grande, el intento de coincidencia de patrón " "producirá un :exc:`TypeError`." #: ../Doc/reference/datamodel.rst:2845 @@ -4733,7 +4846,6 @@ msgstr "" "excepción::" #: ../Doc/reference/datamodel.rst:2869 -#, fuzzy msgid "" "The rationale behind this behaviour lies with a number of special methods " "such as :meth:`~object.__hash__` and :meth:`~object.__repr__` that are " @@ -4741,36 +4853,33 @@ msgid "" "of these methods used the conventional lookup process, they would fail when " "invoked on the type object itself::" msgstr "" -"La razón fundamental detrás de este comportamiento yace en una serie de " -"métodos especiales como :meth:`__hash__` y :meth:`__repr__` que son " -"implementados por todos los objetos, incluyendo objetos de tipo. Si la " -"búsqueda implícita de estos métodos usaran el proceso de búsqueda " -"convencional, fallarían al ser invocados en el objeto de tipo mismo::" +"La razón de este comportamiento radica en una serie de métodos especiales, " +"como :meth:`~object.__hash__` y :meth:`~object.__repr__`, que implementan " +"todos los objetos, incluidos los objetos de tipo. Si la búsqueda implícita " +"de estos métodos usara el proceso de búsqueda convencional, fallarían cuando" +" se invocaran en el objeto de tipo en sí:" #: ../Doc/reference/datamodel.rst:2883 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 " -"the instance when looking up special methods::" +"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" +" the instance when looking up special methods::" msgstr "" "Intentar invocar de manera incorrecta el método no ligado de una clase de " "esta forma a veces es denominado como ‘confusión de metaclase’, y se evita " "sobrepasando la instancia al buscar métodos especiales::" #: ../Doc/reference/datamodel.rst:2892 -#, fuzzy msgid "" "In addition to bypassing any instance attributes in the interest of " -"correctness, implicit special method lookup generally also bypasses the :" -"meth:`~object.__getattribute__` method even of the object's metaclass::" +"correctness, implicit special method lookup generally also bypasses the " +":meth:`~object.__getattribute__` method even of the object's metaclass::" msgstr "" -"Además de sobrepasar cualquier atributo de instancia en aras de lo " -"apropiado, la búsqueda implícita del método especial generalmente también " -"sobrepasa al método :meth:`__getattribute__` incluso de la metaclase del " -"objeto::" +"Además de omitir cualquier atributo de instancia en aras de la corrección, " +"la búsqueda implícita de métodos especiales generalmente también omite el " +"método :meth:`~object.__getattribute__` incluso de la metaclase del objeto:" #: ../Doc/reference/datamodel.rst:2918 -#, fuzzy msgid "" "Bypassing the :meth:`~object.__getattribute__` machinery in this fashion " "provides significant scope for speed optimisations within the interpreter, " @@ -4778,11 +4887,12 @@ msgid "" "special method *must* be set on the class object itself in order to be " "consistently invoked by the interpreter)." msgstr "" -"Sobrepasar el mecanismo de :meth:`__getattribute__` de esta forma " -"proporciona un alcance importante para optimizaciones de velocidad dentro " -"del intérprete, a costa de cierta flexibilidad en el manejo de métodos " -"especiales (el método especial *debe* ser establecido en el objeto de clase " -"mismo para ser invocado consistentemente por el intérprete)." +"Eludir la maquinaria :meth:`~object.__getattribute__` de esta manera " +"proporciona un alcance significativo para las optimizaciones de velocidad " +"dentro del intérprete, a costa de cierta flexibilidad en el manejo de " +"métodos especiales (el método especial *must* debe establecerse en el objeto" +" de clase en sí mismo para que el intérprete lo invoque de manera " +"consistente). )." #: ../Doc/reference/datamodel.rst:2929 msgid "Coroutines" @@ -4793,32 +4903,30 @@ msgid "Awaitable Objects" msgstr "Objetos esperables" #: ../Doc/reference/datamodel.rst:2935 -#, fuzzy msgid "" -"An :term:`awaitable` object generally implements an :meth:`~object." -"__await__` method. :term:`Coroutine objects ` returned from :" -"keyword:`async def` functions are awaitable." +"An :term:`awaitable` object generally implements an " +":meth:`~object.__await__` method. :term:`Coroutine objects ` " +"returned from :keyword:`async def` functions are awaitable." msgstr "" -"Un objeto :term:`awaitable` generalmente implementa a un método :meth:" -"`__await__`. :term:`Objetos Coroutine ` retornados a partir de " -"funciones :keyword:`async def` son esperables." +"Un objeto :term:`awaitable` generalmente implementa un método " +":meth:`~object.__await__`. Las funciones :term:`Coroutine objects " +"` devueltas desde :keyword:`async def` están en espera." #: ../Doc/reference/datamodel.rst:2941 -#, fuzzy msgid "" "The :term:`generator iterator` objects returned from generators decorated " -"with :func:`types.coroutine` are also awaitable, but they do not implement :" -"meth:`~object.__await__`." +"with :func:`types.coroutine` are also awaitable, but they do not implement " +":meth:`~object.__await__`." msgstr "" -"Los objetos :term:`generator iterator` retornados a partir de generadores " -"decorados con :func:`types.coroutine` o :func:`asyncio.coroutine` también " -"son esperables, pero no implementan :meth:`__await__`." +"Los objetos :term:`generator iterator` devueltos por generadores decorados " +"con :func:`types.coroutine` también están disponibles, pero no implementan " +":meth:`~object.__await__`." #: ../Doc/reference/datamodel.rst:2947 msgid "" -"Must return an :term:`iterator`. Should be used to implement :term:" -"`awaitable` objects. For instance, :class:`asyncio.Future` implements this " -"method to be compatible with the :keyword:`await` expression." +"Must return an :term:`iterator`. Should be used to implement " +":term:`awaitable` objects. For instance, :class:`asyncio.Future` implements" +" this method to be compatible with the :keyword:`await` expression." msgstr "" "Debe retornar un :term:`iterator`. Debe ser utilizado para implementar " "objetos :term:`awaitable`. Por ejemplo, :class:`asyncio.Future` implementa " @@ -4833,24 +4941,23 @@ msgid "Coroutine Objects" msgstr "Objetos de corrutina" #: ../Doc/reference/datamodel.rst:2961 -#, fuzzy msgid "" ":term:`Coroutine objects ` are :term:`awaitable` objects. A " -"coroutine's execution can be controlled by calling :meth:`~object.__await__` " -"and iterating over the result. When the coroutine has finished executing " -"and returns, the iterator raises :exc:`StopIteration`, and the exception's :" -"attr:`~StopIteration.value` attribute holds the return value. If the " -"coroutine raises an exception, it is propagated by the iterator. Coroutines " -"should not directly raise unhandled :exc:`StopIteration` exceptions." -msgstr "" -":term:`Objetos Coroutine ` son objetos :term:`awaitable`. La " -"ejecución de una corrutina puede ser controlada llamando :meth:`__await__` e " -"iterando sobre el resultado. Cuando la corrutina ha terminado de ejecutar y " -"retorna, el iterados lanza una excepción :exc:`StopIteration`, y el " -"atributo :attr:`~StopIteration.value` de dicha excepción mantiene el valor " -"de retorno. Si la corrutina lanza una excepción, ésta es propagada por el " -"iterador. Las corrutinas no deben lanzar directamente excepciones :exc:" -"`StopIteration` no manejadas." +"coroutine's execution can be controlled by calling :meth:`~object.__await__`" +" and iterating over the result. When the coroutine has finished executing " +"and returns, the iterator raises :exc:`StopIteration`, and the exception's " +":attr:`~StopIteration.value` attribute holds the return value. If the " +"coroutine raises an exception, it is propagated by the iterator. Coroutines" +" should not directly raise unhandled :exc:`StopIteration` exceptions." +msgstr "" +":term:`Coroutine objects ` son objetos :term:`awaitable`. La " +"ejecución de una rutina se puede controlar llamando a " +":meth:`~object.__await__` e iterando sobre el resultado. Cuando la corrutina" +" ha terminado de ejecutarse y regresa, el iterador genera " +":exc:`StopIteration` y el atributo :attr:`~StopIteration.value` de la " +"excepción contiene el valor de retorno. Si la rutina genera una excepción, " +"el iterador la propaga. Las corrutinas no deben generar directamente " +"excepciones :exc:`StopIteration` no controladas." #: ../Doc/reference/datamodel.rst:2969 msgid "" @@ -4869,42 +4976,39 @@ msgstr "" "Es un error :exc:`RuntimeError` esperar a una corrutina más de una vez." #: ../Doc/reference/datamodel.rst:2979 -#, fuzzy msgid "" "Starts or resumes execution of the coroutine. If *value* is ``None``, this " -"is equivalent to advancing the iterator returned by :meth:`~object." -"__await__`. If *value* is not ``None``, this method delegates to the :meth:" -"`~generator.send` method of the iterator that caused the coroutine to " -"suspend. The result (return value, :exc:`StopIteration`, or other " -"exception) is the same as when iterating over the :meth:`__await__` return " -"value, described above." -msgstr "" -"Inicia o continua la ejecución de una corrutina. Si *value* es ``None``, " -"esto es equivalente a avanzar al iterador retornado por :meth:`__await__`. " -"Si *value* no es ``None``, este método delega al método :meth:`~generator." -"send` del iterador que causó la suspensión de la corrutina. El resultado (el " -"valor de retorno, :exc:`StopIteration`, u otra excepción) es el mismo que " -"cuando se itera sobre el valor de retorno de :meth:`__await__`, descrito " -"anteriormente." +"is equivalent to advancing the iterator returned by " +":meth:`~object.__await__`. If *value* is not ``None``, this method " +"delegates to the :meth:`~generator.send` method of the iterator that caused " +"the coroutine to suspend. The result (return value, :exc:`StopIteration`, " +"or other exception) is the same as when iterating over the :meth:`__await__`" +" return value, described above." +msgstr "" +"Inicia o reanuda la ejecución de la rutina. Si *value* es ``None``, esto " +"equivale a avanzar el iterador devuelto por :meth:`~object.__await__`. Si " +"*value* no es ``None``, este método delega al método :meth:`~generator.send`" +" del iterador que provocó la suspensión de la rutina. El resultado (valor de" +" retorno, :exc:`StopIteration` u otra excepción) es el mismo que cuando se " +"itera sobre el valor de retorno :meth:`__await__`, descrito anteriormente." #: ../Doc/reference/datamodel.rst:2990 -#, fuzzy msgid "" "Raises the specified exception in the coroutine. This method delegates to " "the :meth:`~generator.throw` method of the iterator that caused the " "coroutine to suspend, if it has such a method. Otherwise, the exception is " -"raised at the suspension point. The result (return value, :exc:" -"`StopIteration`, or other exception) is the same as when iterating over the :" -"meth:`~object.__await__` return value, described above. If the exception is " -"not caught in the coroutine, it propagates back to the caller." -msgstr "" -"Lanza la excepción especificada en la corrutina. Este método delega a :meth:" -"`~generator.throw` del iterador que causó la suspensión de la corrutina, si " -"dicho método existe. De lo contrario, la excepción es lanzada al punto de la " -"suspensión. El resultado (valor de retorno, :exc:`StopIteration`, u otra " -"excepción) es el mismo que cuando se itera sobre el valor de retorno de :" -"meth:`__await__` descrito anteriormente. Si la excepción no es obtenida en " -"la corrutina, ésta se propaga de regreso a quien realizó el llamado." +"raised at the suspension point. The result (return value, " +":exc:`StopIteration`, or other exception) is the same as when iterating over" +" the :meth:`~object.__await__` return value, described above. If the " +"exception is not caught in the coroutine, it propagates back to the caller." +msgstr "" +"Genera la excepción especificada en la rutina. Este método delega en el " +"método :meth:`~generator.throw` del iterador que provocó la suspensión de la" +" rutina, si tiene dicho método. De lo contrario, la excepción se plantea en " +"el punto de suspensión. El resultado (valor de retorno, :exc:`StopIteration`" +" u otra excepción) es el mismo que cuando se itera sobre el valor de retorno" +" :meth:`~object.__await__`, descrito anteriormente. Si la excepción no se " +"detecta en la rutina, se propaga de nuevo a la persona que llama." #: ../Doc/reference/datamodel.rst:3001 msgid "" @@ -4912,20 +5016,20 @@ msgid "" "suspended, this method first delegates to the :meth:`~generator.close` " "method of the iterator that caused the coroutine to suspend, if it has such " "a method. Then it raises :exc:`GeneratorExit` at the suspension point, " -"causing the coroutine to immediately clean itself up. Finally, the coroutine " -"is marked as having finished executing, even if it was never started." +"causing the coroutine to immediately clean itself up. Finally, the coroutine" +" is marked as having finished executing, even if it was never started." msgstr "" "Causa que la corrutina misma se borre a sí misma y termine su ejecución. Si " -"la corrutina es suspendida, este método primero delega a :meth:`~generator." -"close`, si existe, del iterador que causó la suspensión de la corrutina. " -"Luego lanza una excepción :exc:`GeneratorExit` en el punto de suspensión, " -"causando que la corrutina se borre a sí misma. Finalmente, la corrutina es " -"marcada como completada, aún si nunca inició." +"la corrutina es suspendida, este método primero delega a " +":meth:`~generator.close`, si existe, del iterador que causó la suspensión de" +" la corrutina. Luego lanza una excepción :exc:`GeneratorExit` en el punto de" +" suspensión, causando que la corrutina se borre a sí misma. Finalmente, la " +"corrutina es marcada como completada, aún si nunca inició." #: ../Doc/reference/datamodel.rst:3009 msgid "" -"Coroutine objects are automatically closed using the above process when they " -"are about to be destroyed." +"Coroutine objects are automatically closed using the above process when they" +" are about to be destroyed." msgstr "" "Objetos de corrutina son cerrados automáticamente utilizando el proceso " "anterior cuando están a punto de ser destruidos." @@ -4946,8 +5050,8 @@ msgstr "" msgid "" "Asynchronous iterators can be used in an :keyword:`async for` statement." msgstr "" -"Iteradores asíncronos pueden ser utilizados en la declaración :keyword:" -"`async for`." +"Iteradores asíncronos pueden ser utilizados en la declaración " +":keyword:`async for`." #: ../Doc/reference/datamodel.rst:3024 msgid "Must return an *asynchronous iterator* object." @@ -4967,25 +5071,24 @@ msgid "An example of an asynchronous iterable object::" msgstr "Un ejemplo de objeto iterable asíncrono::" #: ../Doc/reference/datamodel.rst:3048 -#, fuzzy msgid "" "Prior to Python 3.7, :meth:`~object.__aiter__` could return an *awaitable* " "that would resolve to an :term:`asynchronous iterator `." msgstr "" -"Antes de Python 3.7, ``__aiter__`` podía retornar un *esperable* que se " -"resolvería en un :term:`asynchronous iterator `." +"Antes de Python 3.7, :meth:`~object.__aiter__` podía devolver un *awaitable*" +" que se resolvería en un :term:`asynchronous iterator `." #: ../Doc/reference/datamodel.rst:3053 -#, fuzzy msgid "" "Starting with Python 3.7, :meth:`~object.__aiter__` must return an " -"asynchronous iterator object. Returning anything else will result in a :exc:" -"`TypeError` error." +"asynchronous iterator object. Returning anything else will result in a " +":exc:`TypeError` error." msgstr "" -"A partir de Python 3.7, ``__aiter__`` debe retornar un objeto iterador " -"asíncrono. Retornar cualquier otra cosa resultará en un error :exc:" -"`TypeError`." +"A partir de Python 3.7, :meth:`~object.__aiter__` debe devolver un objeto " +"iterador asíncrono. Devolver cualquier otra cosa dará como resultado un " +"error :exc:`TypeError`." #: ../Doc/reference/datamodel.rst:3061 msgid "Asynchronous Context Managers" @@ -5004,13 +5107,13 @@ msgid "" "Asynchronous context managers can be used in an :keyword:`async with` " "statement." msgstr "" -"Los gestores de contexto asíncronos pueden ser utilizados en una " -"declaración :keyword:`async with`." +"Los gestores de contexto asíncronos pueden ser utilizados en una declaración" +" :keyword:`async with`." #: ../Doc/reference/datamodel.rst:3070 msgid "" -"Semantically similar to :meth:`__enter__`, the only difference being that it " -"must return an *awaitable*." +"Semantically similar to :meth:`__enter__`, the only difference being that it" +" must return an *awaitable*." msgstr "" "Semánticamente similar a :meth:`__enter__`, siendo la única diferencia que " "debe retorna un *esperable*." @@ -5038,27 +5141,27 @@ msgid "" "lead to some very strange behaviour if it is handled incorrectly." msgstr "" "Es posible cambiar en algunos casos un tipo de objeto bajo ciertas " -"circunstancias controladas. Generalmente no es buena idea, ya que esto puede " -"llevar a un comportamiento bastante extraño de no ser tratado correctamente." +"circunstancias controladas. Generalmente no es buena idea, ya que esto puede" +" llevar a un comportamiento bastante extraño de no ser tratado " +"correctamente." #: ../Doc/reference/datamodel.rst:3096 -#, fuzzy msgid "" -"The :meth:`~object.__hash__`, :meth:`~object.__iter__`, :meth:`~object." -"__reversed__`, and :meth:`~object.__contains__` methods have special " -"handling for this; others will still raise a :exc:`TypeError`, but may do so " -"by relying on the behavior that ``None`` is not callable." +"The :meth:`~object.__hash__`, :meth:`~object.__iter__`, " +":meth:`~object.__reversed__`, and :meth:`~object.__contains__` methods have " +"special handling for this; others will still raise a :exc:`TypeError`, but " +"may do so by relying on the behavior that ``None`` is not callable." msgstr "" -"Los métodos :meth:`__hash__`, :meth:`__iter__`, :meth:`__reversed__`, y :" -"meth:`__contains__` tienen manejo especial para esto; otros lanzarán un " -"error :exc:`TypeError`, pero lo harán dependiendo del comportamiento de que " -"``None`` no se puede llamar." +"Los métodos :meth:`~object.__hash__`, :meth:`~object.__iter__`, " +":meth:`~object.__reversed__` y :meth:`~object.__contains__` tienen un manejo" +" especial para esto; otros aún generarán un :exc:`TypeError`, pero pueden " +"hacerlo confiando en el comportamiento de que ``None`` no es invocable." #: ../Doc/reference/datamodel.rst:3102 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 " -"want to force fallback to the right operand's reflected method—that will " +"method returns ``NotImplemented``. Do not set the method to ``None`` if you" +" want to force fallback to the right operand's reflected method—that will " "instead have the opposite effect of explicitly *blocking* such fallback." msgstr "" "“No soporta” aquí significa que la clase no tiene tal método, o el método " @@ -5068,93 +5171,11 @@ msgstr "" "retroceso." #: ../Doc/reference/datamodel.rst:3108 -#, fuzzy msgid "" "For operands of the same type, it is assumed that if the non-reflected " "method -- such as :meth:`~object.__add__` -- fails then the overall " "operation is not supported, which is why the reflected method is not called." msgstr "" -"Para operandos del mismo tipo, se asume que si el método no reflejado (como :" -"meth:`__add__`) falla, la operación no es soportada, por lo cual el método " -"reflejado no es llamado." - -#~ msgid "" -#~ "A string is a sequence of values that represent Unicode code points. All " -#~ "the code points in the range ``U+0000 - U+10FFFF`` can be represented in " -#~ "a string. Python doesn't have a :c:type:`char` type; instead, every code " -#~ "point in the string is represented as a string object with length ``1``. " -#~ "The built-in function :func:`ord` converts a code point from its string " -#~ "form to an integer in the range ``0 - 10FFFF``; :func:`chr` converts an " -#~ "integer in the range ``0 - 10FFFF`` to the corresponding length ``1`` " -#~ "string object. :meth:`str.encode` can be used to convert a :class:`str` " -#~ "to :class:`bytes` using the given text encoding, and :meth:`bytes.decode` " -#~ "can be used to achieve the opposite." -#~ msgstr "" -#~ "Una cadena de caracteres es una secuencia de valores que representan " -#~ "puntos de código *Unicode*. Todos los puntos de código en el rango " -#~ "``U+0000 - U+10FFFF`` se puede representar en una cadena de caracteres. " -#~ "Python no tiene un tipo :c:type:`char`; en cambio, cada punto de código " -#~ "en la cadena de caracteres se representa como un objeto de cadena de " -#~ "caracteres con longitud ``1``. La función incorporada :func:`ord` " -#~ "convierte un punto de código de su forma de cadena de caracteres a un " -#~ "entero en el rango ``0 - 10FFFF``; la función :func:`chr` convierte un " -#~ "entero en el rango ``0 - 10FFFF`` a la cadena de caracteres " -#~ "correspondiente de longitud ``1``. :meth:`str.encode` se puede usar para " -#~ "convertir un objeto de tipo :class:`str` a :class:`bytes` usando la " -#~ "codificación de texto dada, y :meth:`bytes.decode` se puede usar para " -#~ "lograr el caso inverso." - -#~ msgid "" -#~ "If ``a`` is an instance of :class:`super`, then the binding ``super(B, " -#~ "obj).m()`` searches ``obj.__class__.__mro__`` for the base class ``A`` " -#~ "immediately preceding ``B`` and then invokes the descriptor with the " -#~ "call: ``A.__dict__['m'].__get__(obj, obj.__class__)``." -#~ msgstr "" -#~ "Si ``a`` es una instancia de :class:`super`, entonces el enlace " -#~ "``super(B, obj).m()`` busca ``obj.__class__.__mro__`` la clase base ``A`` " -#~ "que precede inmediatamente ``B`` y luego invoca al descriptor con el " -#~ "llamado: ``A.__dict__[‘m’].__get__(obj, obj.__class__)``." - -#~ msgid "" -#~ "Any non-string iterable may be assigned to *__slots__*. Mappings may also " -#~ "be used; however, in the future, special meaning may be assigned to the " -#~ "values corresponding to each key." -#~ msgstr "" -#~ "Cualquier iterable sin cadena de caracteres puede ser asignado a " -#~ "*__slots__*. Mapeos también pueden ser utilizados; sin embargo, en el " -#~ "futuro, un significado especial puede ser asignado a los valores " -#~ "correspondientes para cada llave." - -#~ msgid "" -#~ "One can implement the generic class syntax as specified by :pep:`484` " -#~ "(for example ``List[int]``) by defining a special method:" -#~ msgstr "" -#~ "Uno puede implementar la sintaxis de clase genérica como lo especifica :" -#~ "pep:`484` (por ejemplo ``List[int]``) definiendo un método especial:" - -#~ 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 "" -#~ "Este método es buscado en el objeto de clase mismo, y cuando es definido " -#~ "en el cuerpo de la clase, este método es un método de clase implícito. " -#~ "Tome en cuenta que este mecanismo es ante todo reservado para su uso con " -#~ "sugerencias de tipo (*type hints*), no se aconseja otro uso." - -#~ 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 "" -#~ "Objetos iteradores también necesitan implementar este método; son " -#~ "requeridos para retornarse a sí mismos. Para mayor información sobre " -#~ "objetos iteradores, ver :ref:`typeiter`." - -#~ msgid "" -#~ "If :meth:`__int__` is not defined then the built-in function :func:`int` " -#~ "falls back to :meth:`__trunc__`." -#~ msgstr "" -#~ "Si :meth:`__int__` no es definido, entonces la función incorporada :func:" -#~ "`int` regresa a :meth:`__trunc__`." +"Para operandos del mismo tipo, se supone que si el método no reflejado, como" +" :meth:`~object.__add__`, falla, la operación general no es compatible, por " +"lo que no se llama al método reflejado." From e608118ef23f4442a3e11db4a9e7607c1956de4d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cristi=C3=A1n=20Maureira-Fredes?= Date: Mon, 16 Jan 2023 13:01:41 +0100 Subject: [PATCH 2/5] powrap --- reference/datamodel.po | 2724 ++++++++++++++++++++-------------------- 1 file changed, 1344 insertions(+), 1380 deletions(-) diff --git a/reference/datamodel.po b/reference/datamodel.po index a5a9e873bc..ecbe9538ca 100644 --- a/reference/datamodel.po +++ b/reference/datamodel.po @@ -37,9 +37,9 @@ msgid "" "computer\", code is also represented by objects.)" msgstr "" ":dfn:`Objects` son la abstracción de Python para los datos. Todos los datos " -"en un programa Python están representados por objetos o por relaciones entre" -" objetos. (En cierto sentido y de conformidad con el modelo de Von Neumann " -"de una \"programa almacenado de computadora\", el código también está " +"en un programa Python están representados por objetos o por relaciones entre " +"objetos. (En cierto sentido y de conformidad con el modelo de Von Neumann de " +"una \"programa almacenado de computadora\", el código también está " "representado por objetos.)" #: ../Doc/reference/datamodel.rst:35 @@ -51,10 +51,10 @@ msgid "" "identity." msgstr "" "Cada objeto tiene una identidad, un tipo y un valor. La *identidad* de un " -"objeto nunca cambia una vez que ha sido creado; puede pensar en ello como la" -" dirección del objeto en la memoria. El operador ':keyword:`is`' compara la " -"identidad de dos objetos; la función :func:`id` retorna un número entero que" -" representa su identidad." +"objeto nunca cambia una vez que ha sido creado; puede pensar en ello como la " +"dirección del objeto en la memoria. El operador ':keyword:`is`' compara la " +"identidad de dos objetos; la función :func:`id` retorna un número entero que " +"representa su identidad." #: ../Doc/reference/datamodel.rst:42 msgid "For CPython, ``id(x)`` is the memory address where ``x`` is stored." @@ -64,16 +64,16 @@ msgstr "" #: ../Doc/reference/datamodel.rst:44 msgid "" "An object's type determines the operations that the object supports (e.g., " -"\"does it have a length?\") and also defines the possible values for objects" -" of that type. The :func:`type` function returns an object's type (which is" -" an object itself). Like its identity, an object's :dfn:`type` is also " +"\"does it have a length?\") and also defines the possible values for objects " +"of that type. The :func:`type` function returns an object's type (which is " +"an object itself). Like its identity, an object's :dfn:`type` is also " "unchangeable. [#]_" msgstr "" "El tipo de un objeto determina las operaciones que admite el objeto (por " "ejemplo, \"¿tiene una longitud?\") y también define los posibles valores " "para los objetos de ese tipo. La función :func:`type` retorna el tipo de un " -"objeto (que es un objeto en sí mismo). Al igual que su identidad, también el" -" :dfn:`type` de un objeto es inmutable. [#]_" +"objeto (que es un objeto en sí mismo). Al igual que su identidad, también " +"el :dfn:`type` de un objeto es inmutable. [#]_" #: ../Doc/reference/datamodel.rst:50 msgid "" @@ -83,8 +83,8 @@ msgid "" "that contains a reference to a mutable object can change when the latter's " "value is changed; however the container is still considered immutable, " "because the collection of objects it contains cannot be changed. So, " -"immutability is not strictly the same as having an unchangeable value, it is" -" more subtle.) An object's mutability is determined by its type; for " +"immutability is not strictly the same as having an unchangeable value, it is " +"more subtle.) An object's mutability is determined by its type; for " "instance, numbers, strings and tuples are immutable, while dictionaries and " "lists are mutable." msgstr "" @@ -97,8 +97,8 @@ msgstr "" "que contiene no se puede cambiar. Por lo tanto, la inmutabilidad no es " "estrictamente lo mismo que tener un valor inmutable, es más sutil). La " "mutabilidad de un objeto está determinada por su tipo; por ejemplo, los " -"números, las cadenas de caracteres y las tuplas son inmutables, mientras que" -" los diccionarios y las listas son mutables." +"números, las cadenas de caracteres y las tuplas son inmutables, mientras que " +"los diccionarios y las listas son mutables." #: ../Doc/reference/datamodel.rst:65 msgid "" @@ -110,10 +110,10 @@ msgid "" msgstr "" "Los objetos nunca se destruyen explícitamente; sin embargo, cuando se " "vuelven inalcanzables, se pueden recolectar basura. Se permite a una " -"implementación posponer la recolección de basura u omitirla por completo; es" -" una cuestión de calidad de la implementación cómo se implementa la " -"recolección de basura, siempre que no se recolecten objetos que todavía sean" -" accesibles." +"implementación posponer la recolección de basura u omitirla por completo; es " +"una cuestión de calidad de la implementación cómo se implementa la " +"recolección de basura, siempre que no se recolecten objetos que todavía sean " +"accesibles." #: ../Doc/reference/datamodel.rst:73 msgid "" @@ -146,36 +146,35 @@ msgstr "" "Tenga en cuenta que el uso de las funciones de rastreo o depuración de la " "implementación puede mantener activos los objetos que normalmente serían " "coleccionables. También tenga en cuenta que la captura de una excepción con " -"una sentencia ':keyword:`try`...\\ :keyword:`except`' puede mantener objetos" -" activos." +"una sentencia ':keyword:`try`...\\ :keyword:`except`' puede mantener objetos " +"activos." #: ../Doc/reference/datamodel.rst:87 msgid "" -"Some objects contain references to \"external\" resources such as open files" -" or windows. It is understood that these resources are freed when the " -"object is garbage-collected, but since garbage collection is not guaranteed " -"to happen, such objects also provide an explicit way to release the external" -" resource, usually a :meth:`close` method. Programs are strongly recommended" -" to explicitly close such objects. The ':keyword:`try`...\\ " -":keyword:`finally`' statement and the ':keyword:`with`' statement provide " -"convenient ways to do this." +"Some objects contain references to \"external\" resources such as open files " +"or windows. It is understood that these resources are freed when the object " +"is garbage-collected, but since garbage collection is not guaranteed to " +"happen, such objects also provide an explicit way to release the external " +"resource, usually a :meth:`close` method. Programs are strongly recommended " +"to explicitly close such objects. The ':keyword:`try`...\\ :keyword:" +"`finally`' statement and the ':keyword:`with`' statement provide convenient " +"ways to do this." msgstr "" "Algunos objetos contienen referencias a recursos \"externos\" como archivos " "abiertos o ventanas. Se entiende que estos recursos se liberan cuando el " "objeto es eliminado por el recolector de basura, pero como no se garantiza " -"que la recolección de basura suceda, dichos objetos también proporcionan una" -" forma explícita de liberar el recurso externo, generalmente un método " -":meth:`close`. Se recomienda encarecidamente a los programas cerrar " -"explícitamente dichos objetos. La declaración ':keyword:`try`...\\ " -":keyword:`finally`' y la declaración ':keyword:`with`' proporcionan formas " -"convenientes de hacer esto." +"que la recolección de basura suceda, dichos objetos también proporcionan una " +"forma explícita de liberar el recurso externo, generalmente un método :meth:" +"`close`. Se recomienda encarecidamente a los programas cerrar explícitamente " +"dichos objetos. La declaración ':keyword:`try`...\\ :keyword:`finally`' y la " +"declaración ':keyword:`with`' proporcionan formas convenientes de hacer esto." #: ../Doc/reference/datamodel.rst:97 msgid "" "Some objects contain references to other objects; these are called " "*containers*. Examples of containers are tuples, lists and dictionaries. " -"The references are part of a container's value. In most cases, when we talk" -" about the value of a container, we imply the values, not the identities of " +"The references are part of a container's value. In most cases, when we talk " +"about the value of a container, we imply the values, not the identities of " "the contained objects; however, when we talk about the mutability of a " "container, only the identities of the immediately contained objects are " "implied. So, if an immutable container (like a tuple) contains a reference " @@ -197,9 +196,9 @@ msgid "" "object identity is affected in some sense: for immutable types, operations " "that compute new values may actually return a reference to any existing " "object with the same type and value, while for mutable objects this is not " -"allowed. E.g., after ``a = 1; b = 1``, ``a`` and ``b`` may or may not refer" -" to the same object with the value one, depending on the implementation, but" -" after ``c = []; d = []``, ``c`` and ``d`` are guaranteed to refer to two " +"allowed. E.g., after ``a = 1; b = 1``, ``a`` and ``b`` may or may not refer " +"to the same object with the value one, depending on the implementation, but " +"after ``c = []; d = []``, ``c`` and ``d`` are guaranteed to refer to two " "different, unique, newly created empty lists. (Note that ``c = d = []`` " "assigns the same object to both ``c`` and ``d``.)" msgstr "" @@ -209,11 +208,11 @@ msgstr "" "valores en realidad pueden retornar una referencia a cualquier objeto " "existente con el mismo tipo y valor, mientras que para los objetos mutables " "esto no está permitido. Por ejemplo, al hacer ``a = 1; b = 1``, ``a`` y " -"``b`` puede o no referirse al mismo objeto con el valor 1, dependiendo de la" -" implementación, pero al hacer ``c = []; d = []``, ``c`` y ``d`` se " -"garantiza que se refieren a dos listas vacías diferentes, únicas y recién " -"creadas. (Tenga en cuenta que ``c = d = []`` asigna el mismo objeto a ambos " -"``c`` y ``d``.)" +"``b`` puede o no referirse al mismo objeto con el valor 1, dependiendo de la " +"implementación, pero al hacer ``c = []; d = []``, ``c`` y ``d`` se garantiza " +"que se refieren a dos listas vacías diferentes, únicas y recién creadas. " +"(Tenga en cuenta que ``c = d = []`` asigna el mismo objeto a ambos ``c`` y " +"``d``.)" #: ../Doc/reference/datamodel.rst:120 msgid "The standard type hierarchy" @@ -223,24 +222,24 @@ msgstr "Jerarquía de tipos estándar" msgid "" "Below is a list of the types that are built into Python. Extension modules " "(written in C, Java, or other languages, depending on the implementation) " -"can define additional types. Future versions of Python may add types to the" -" type hierarchy (e.g., rational numbers, efficiently stored arrays of " +"can define additional types. Future versions of Python may add types to the " +"type hierarchy (e.g., rational numbers, efficiently stored arrays of " "integers, etc.), although such additions will often be provided via the " "standard library instead." msgstr "" "A continuación se muestra una lista de los tipos integrados en Python. Los " "módulos de extensión (escritos en C, Java u otros lenguajes, dependiendo de " "la implementación) pueden definir tipos adicionales. Las versiones futuras " -"de Python pueden agregar tipos a la jerarquía de tipos (por ejemplo, números" -" racionales, matrices de enteros almacenados de manera eficiente, etc.), " +"de Python pueden agregar tipos a la jerarquía de tipos (por ejemplo, números " +"racionales, matrices de enteros almacenados de manera eficiente, etc.), " "aunque tales adiciones a menudo se proporcionarán a través de la biblioteca " "estándar." #: ../Doc/reference/datamodel.rst:140 msgid "" "Some of the type descriptions below contain a paragraph listing 'special " -"attributes.' These are attributes that provide access to the implementation" -" and are not intended for general use. Their definition may change in the " +"attributes.' These are attributes that provide access to the implementation " +"and are not intended for general use. Their definition may change in the " "future." msgstr "" "Algunas de las descripciones de tipos a continuación contienen un párrafo " @@ -256,8 +255,8 @@ msgstr "None" msgid "" "This type has a single value. There is a single object with this value. " "This object is accessed through the built-in name ``None``. It is used to " -"signify the absence of a value in many situations, e.g., it is returned from" -" functions that don't explicitly return anything. Its truth value is false." +"signify the absence of a value in many situations, e.g., it is returned from " +"functions that don't explicitly return anything. Its truth value is false." msgstr "" "Este tipo tiene un solo valor. Hay un solo objeto con este valor. Se accede " "a este objeto a través del nombre incorporado ``None``. Se utiliza para " @@ -273,10 +272,10 @@ msgstr "NotImplemented" msgid "" "This type has a single value. There is a single object with this value. " "This object is accessed through the built-in name ``NotImplemented``. " -"Numeric methods and rich comparison methods should return this value if they" -" do not implement the operation for the operands provided. (The interpreter" -" will then try the reflected operation, or some other fallback, depending on" -" the operator.) It should not be evaluated in a boolean context." +"Numeric methods and rich comparison methods should return this value if they " +"do not implement the operation for the operands provided. (The interpreter " +"will then try the reflected operation, or some other fallback, depending on " +"the operator.) It should not be evaluated in a boolean context." msgstr "" "Este tipo tiene un solo valor. Hay un solo objeto con este valor. Se accede " "a este objeto a través del nombre integrado ``NotImplemented``. Los métodos " @@ -297,9 +296,9 @@ msgid "" "will raise a :exc:`TypeError` in a future version of Python." msgstr "" "La evaluación de ``NotImplemented`` en un contexto booleano está en desuso. " -"Si bien actualmente se evalúa como verdadero, lanzará un " -":exc:`DeprecationWarning`. Lanzará un :exc:`TypeError` en una versión futura" -" de Python." +"Si bien actualmente se evalúa como verdadero, lanzará un :exc:" +"`DeprecationWarning`. Lanzará un :exc:`TypeError` en una versión futura de " +"Python." #: ../Doc/reference/datamodel.rst:179 msgid "Ellipsis" @@ -322,8 +321,8 @@ msgstr ":class:`numbers.Number`" #: ../Doc/reference/datamodel.rst:184 msgid "" "These are created by numeric literals and returned as results by arithmetic " -"operators and arithmetic built-in functions. Numeric objects are immutable;" -" once created their value never changes. Python numbers are of course " +"operators and arithmetic built-in functions. Numeric objects are immutable; " +"once created their value never changes. Python numbers are of course " "strongly related to mathematical numbers, but subject to the limitations of " "numerical representation in computers." msgstr "" @@ -336,12 +335,12 @@ msgstr "" #: ../Doc/reference/datamodel.rst:190 msgid "" -"The string representations of the numeric classes, computed by " -":meth:`~object.__repr__` and :meth:`~object.__str__`, have the following " +"The string representations of the numeric classes, computed by :meth:" +"`~object.__repr__` and :meth:`~object.__str__`, have the following " "properties:" msgstr "" -"Las representaciones de cadena de las clases numéricas, calculadas por " -":meth:`~object.__repr__` y :meth:`~object.__str__`, tienen las siguientes " +"Las representaciones de cadena de las clases numéricas, calculadas por :meth:" +"`~object.__repr__` y :meth:`~object.__str__`, tienen las siguientes " "propiedades:" #: ../Doc/reference/datamodel.rst:194 @@ -390,8 +389,8 @@ msgstr ":class:`numbers.Integral`" #: ../Doc/reference/datamodel.rst:214 msgid "" -"These represent elements from the mathematical set of integers (positive and" -" negative)." +"These represent elements from the mathematical set of integers (positive and " +"negative)." msgstr "" "Estos representan elementos del conjunto matemático de números enteros " "(positivo y negativo)." @@ -425,18 +424,18 @@ msgstr "Booleanos (:class:`bool`)" #: ../Doc/reference/datamodel.rst:232 msgid "" "These represent the truth values False and True. The two objects " -"representing the values ``False`` and ``True`` are the only Boolean objects." -" The Boolean type is a subtype of the integer type, and Boolean values " -"behave like the values 0 and 1, respectively, in almost all contexts, the " -"exception being that when converted to a string, the strings ``\"False\"`` " -"or ``\"True\"`` are returned, respectively." +"representing the values ``False`` and ``True`` are the only Boolean objects. " +"The Boolean type is a subtype of the integer type, and Boolean values behave " +"like the values 0 and 1, respectively, in almost all contexts, the exception " +"being that when converted to a string, the strings ``\"False\"`` or " +"``\"True\"`` are returned, respectively." msgstr "" "Estos representan los valores de verdad Falso y Verdadero. Los dos objetos " "que representan los valores ``False`` y ``True`` son los únicos objetos " "booleanos. El tipo booleano es un subtipo del tipo entero y los valores " -"booleanos se comportan como los valores 0 y 1 respectivamente, en casi todos" -" los contextos, con la excepción de que cuando se convierten en una cadena " -"de caracteres, las cadenas de caracteres ``\"False\"`` o ``\"True\"`` son " +"booleanos se comportan como los valores 0 y 1 respectivamente, en casi todos " +"los contextos, con la excepción de que cuando se convierten en una cadena de " +"caracteres, las cadenas de caracteres ``\"False\"`` o ``\"True\"`` son " "retornadas respectivamente." #: ../Doc/reference/datamodel.rst:240 @@ -457,11 +456,11 @@ msgstr ":class:`numbers.Real` (:class:`float`)" msgid "" "These represent machine-level double precision floating point numbers. You " "are at the mercy of the underlying machine architecture (and C or Java " -"implementation) for the accepted range and handling of overflow. Python does" -" not support single-precision floating point numbers; the savings in " +"implementation) for the accepted range and handling of overflow. Python does " +"not support single-precision floating point numbers; the savings in " "processor and memory usage that are usually the reason for using these are " -"dwarfed by the overhead of using objects in Python, so there is no reason to" -" complicate the language with two kinds of floating point numbers." +"dwarfed by the overhead of using objects in Python, so there is no reason to " +"complicate the language with two kinds of floating point numbers." msgstr "" "Estos representan números de punto flotante de precisión doble a nivel de " "máquina. Está a merced de la arquitectura de la máquina subyacente (y la " @@ -485,8 +484,8 @@ msgid "" msgstr "" "Estos representan números complejos como un par de números de coma flotante " "de precisión doble a nivel de máquina. Se aplican las mismas advertencias " -"que para los números de coma flotante. Las partes reales e imaginarias de un" -" número complejo ``z`` se pueden obtener a través de los atributos de solo " +"que para los números de coma flotante. Las partes reales e imaginarias de un " +"número complejo ``z`` se pueden obtener a través de los atributos de solo " "lectura ``z.real`` y ``z.imag``." #: ../Doc/reference/datamodel.rst:383 @@ -501,9 +500,9 @@ msgid "" "1, ..., *n*-1. Item *i* of sequence *a* is selected by ``a[i]``." msgstr "" "Estos representan conjuntos ordenados finitos indexados por números no " -"negativos. La función incorporada :func:`len` retorna el número de elementos" -" de una secuencia. Cuando la longitud de una secuencia es *n*, el conjunto " -"de índices contiene los números 0, 1, ..., *n*-1. El elemento *i* de la " +"negativos. La función incorporada :func:`len` retorna el número de elementos " +"de una secuencia. Cuando la longitud de una secuencia es *n*, el conjunto de " +"índices contiene los números 0, 1, ..., *n*-1. El elemento *i* de la " "secuencia *a* se selecciona mediante ``a[i]``." #: ../Doc/reference/datamodel.rst:283 @@ -513,11 +512,11 @@ msgid "" "a sequence of the same type. This implies that the index set is renumbered " "so that it starts at 0." msgstr "" -"Las secuencias también admiten segmentación: ``a[i:j]`` selecciona todos los" -" elementos con índice *k* de modo que *i* ``<=`` *k* ``<`` *j*. Cuando se " +"Las secuencias también admiten segmentación: ``a[i:j]`` selecciona todos los " +"elementos con índice *k* de modo que *i* ``<=`` *k* ``<`` *j*. Cuando se " "usa como una expresión, un segmento es una secuencia del mismo tipo. Esto " -"implica que el conjunto de índices se vuelve a enumerar para que comience en" -" 0." +"implica que el conjunto de índices se vuelve a enumerar para que comience en " +"0." #: ../Doc/reference/datamodel.rst:288 msgid "" @@ -541,15 +540,15 @@ msgstr "Secuencias inmutables" #: ../Doc/reference/datamodel.rst:299 msgid "" "An object of an immutable sequence type cannot change once it is created. " -"(If the object contains references to other objects, these other objects may" -" be mutable and may be changed; however, the collection of objects directly " +"(If the object contains references to other objects, these other objects may " +"be mutable and may be changed; however, the collection of objects directly " "referenced by an immutable object cannot change.)" msgstr "" "Un objeto de un tipo de secuencia inmutable no puede cambiar una vez que se " "crea. (Si el objeto contiene referencias a otros objetos, estos otros " -"objetos pueden ser mutables y pueden cambiarse; sin embargo, la colección de" -" objetos a los que hace referencia directamente un objeto inmutable no puede" -" cambiar)." +"objetos pueden ser mutables y pueden cambiarse; sin embargo, la colección de " +"objetos a los que hace referencia directamente un objeto inmutable no puede " +"cambiar)." #: ../Doc/reference/datamodel.rst:304 msgid "The following types are immutable sequences:" @@ -561,28 +560,28 @@ msgstr "Cadenas de caracteres" #: ../Doc/reference/datamodel.rst:317 msgid "" -"A string is a sequence of values that represent Unicode code points. All the" -" code points in the range ``U+0000 - U+10FFFF`` can be represented in a " +"A string is a sequence of values that represent Unicode code points. All the " +"code points in the range ``U+0000 - U+10FFFF`` can be represented in a " "string. Python doesn't have a :c:expr:`char` type; instead, every code " "point in the string is represented as a string object with length ``1``. " -"The built-in function :func:`ord` converts a code point from its string form" -" to an integer in the range ``0 - 10FFFF``; :func:`chr` converts an integer " -"in the range ``0 - 10FFFF`` to the corresponding length ``1`` string object." -" :meth:`str.encode` can be used to convert a :class:`str` to :class:`bytes` " -"using the given text encoding, and :meth:`bytes.decode` can be used to " -"achieve the opposite." +"The built-in function :func:`ord` converts a code point from its string form " +"to an integer in the range ``0 - 10FFFF``; :func:`chr` converts an integer " +"in the range ``0 - 10FFFF`` to the corresponding length ``1`` string " +"object. :meth:`str.encode` can be used to convert a :class:`str` to :class:" +"`bytes` using the given text encoding, and :meth:`bytes.decode` can be used " +"to achieve the opposite." msgstr "" "Una cadena es una secuencia de valores que representan puntos de código " "Unicode. Todos los puntos de código en el rango ``U+0000 - U+10FFFF`` se " -"pueden representar en una cadena. Python no tiene un tipo :c:expr:`char`; en" -" su lugar, cada punto de código de la cadena se representa como un objeto de" -" cadena con una longitud ``1``. La función integrada :func:`ord` convierte " -"un punto de código de su forma de cadena a un entero en el rango ``0 - " +"pueden representar en una cadena. Python no tiene un tipo :c:expr:`char`; en " +"su lugar, cada punto de código de la cadena se representa como un objeto de " +"cadena con una longitud ``1``. La función integrada :func:`ord` convierte un " +"punto de código de su forma de cadena a un entero en el rango ``0 - " "10FFFF``; :func:`chr` convierte un entero en el rango ``0 - 10FFFF`` al " "objeto de cadena ``1`` de longitud correspondiente. :meth:`str.encode` se " "puede usar para convertir un :class:`str` a :class:`bytes` usando la " -"codificación de texto dada, y :meth:`bytes.decode` se puede usar para lograr" -" lo contrario." +"codificación de texto dada, y :meth:`bytes.decode` se puede usar para lograr " +"lo contrario." #: ../Doc/reference/datamodel.rst:340 msgid "Tuples" @@ -613,15 +612,15 @@ msgid "" "A bytes object is an immutable array. The items are 8-bit bytes, " "represented by integers in the range 0 <= x < 256. Bytes literals (like " "``b'abc'``) and the built-in :func:`bytes()` constructor can be used to " -"create bytes objects. Also, bytes objects can be decoded to strings via the" -" :meth:`~bytes.decode` method." +"create bytes objects. Also, bytes objects can be decoded to strings via " +"the :meth:`~bytes.decode` method." msgstr "" "Un objeto de bytes es una colección inmutable. Los elementos son bytes de 8 " "bits, representados por enteros en el rango 0 <= x <256. Literales de bytes " "(como ``b'abc'``) y el constructor incorporado :func:`bytes()` se puede " -"utilizar para crear objetos de bytes. Además, los objetos de bytes se pueden" -" decodificar en cadenas de caracteres a través del método " -":meth:`~bytes.decode`." +"utilizar para crear objetos de bytes. Además, los objetos de bytes se pueden " +"decodificar en cadenas de caracteres a través del método :meth:`~bytes." +"decode`." #: ../Doc/reference/datamodel.rst:383 msgid "Mutable sequences" @@ -630,8 +629,8 @@ msgstr "Secuencias mutables" #: ../Doc/reference/datamodel.rst:359 msgid "" "Mutable sequences can be changed after they are created. The subscription " -"and slicing notations can be used as the target of assignment and " -":keyword:`del` (delete) statements." +"and slicing notations can be used as the target of assignment and :keyword:" +"`del` (delete) statements." msgstr "" "Las secuencias mutables se pueden cambiar después de su creación. Las " "anotaciones de suscripción y segmentación se pueden utilizar como el " @@ -648,11 +647,11 @@ msgstr "Listas" #: ../Doc/reference/datamodel.rst:368 msgid "" "The items of a list are arbitrary Python objects. Lists are formed by " -"placing a comma-separated list of expressions in square brackets. (Note that" -" there are no special cases needed to form lists of length 0 or 1.)" +"placing a comma-separated list of expressions in square brackets. (Note that " +"there are no special cases needed to form lists of length 0 or 1.)" msgstr "" -"Los elementos de una lista son objetos de Python arbitrarios. Las listas se" -" forman colocando una lista de expresiones separadas por comas entre " +"Los elementos de una lista son objetos de Python arbitrarios. Las listas se " +"forman colocando una lista de expresiones separadas por comas entre " "corchetes. (Tome en cuenta que no hay casos especiales necesarios para " "formar listas de longitud 0 o 1.)" @@ -662,13 +661,13 @@ msgstr "Colecciones de bytes" #: ../Doc/reference/datamodel.rst:375 msgid "" -"A bytearray object is a mutable array. They are created by the built-in " -":func:`bytearray` constructor. Aside from being mutable (and hence " +"A bytearray object is a mutable array. They are created by the built-in :" +"func:`bytearray` constructor. Aside from being mutable (and hence " "unhashable), byte arrays otherwise provide the same interface and " "functionality as immutable :class:`bytes` objects." msgstr "" -"Un objeto bytearray es una colección mutable. Son creados por el constructor" -" incorporado :func:`bytearray`. Además de ser mutables (y, por lo tanto, " +"Un objeto bytearray es una colección mutable. Son creados por el constructor " +"incorporado :func:`bytearray`. Además de ser mutables (y, por lo tanto, " "inquebrantable), las colecciones de bytes proporcionan la misma interfaz y " "funcionalidad que los objetos inmutables :class:`bytes`." @@ -687,11 +686,11 @@ msgstr "Tipos de conjuntos" #: ../Doc/reference/datamodel.rst:390 msgid "" "These represent unordered, finite sets of unique, immutable objects. As " -"such, they cannot be indexed by any subscript. However, they can be iterated" -" over, and the built-in function :func:`len` returns the number of items in " -"a set. Common uses for sets are fast membership testing, removing duplicates" -" from a sequence, and computing mathematical operations such as " -"intersection, union, difference, and symmetric difference." +"such, they cannot be indexed by any subscript. However, they can be iterated " +"over, and the built-in function :func:`len` returns the number of items in a " +"set. Common uses for sets are fast membership testing, removing duplicates " +"from a sequence, and computing mathematical operations such as intersection, " +"union, difference, and symmetric difference." msgstr "" "Estos representan conjuntos finitos no ordenados de objetos únicos e " "inmutables. Como tal, no pueden ser indexados por ningún *subscript*. Sin " @@ -704,15 +703,15 @@ msgstr "" #: ../Doc/reference/datamodel.rst:397 msgid "" "For set elements, the same immutability rules apply as for dictionary keys. " -"Note that numeric types obey the normal rules for numeric comparison: if two" -" numbers compare equal (e.g., ``1`` and ``1.0``), only one of them can be " +"Note that numeric types obey the normal rules for numeric comparison: if two " +"numbers compare equal (e.g., ``1`` and ``1.0``), only one of them can be " "contained in a set." msgstr "" "Para elementos del conjunto, se aplican las mismas reglas de inmutabilidad " "que para las claves de diccionario. Tenga en cuenta que los tipos numéricos " -"obedecen las reglas normales para la comparación numérica: si dos números se" -" comparan igual (por ejemplo, ``1`` y ``1.0``), solo uno de ellos puede " -"estar contenido en un conjunto." +"obedecen las reglas normales para la comparación numérica: si dos números se " +"comparan igual (por ejemplo, ``1`` y ``1.0``), solo uno de ellos puede estar " +"contenido en un conjunto." #: ../Doc/reference/datamodel.rst:402 msgid "There are currently two intrinsic set types:" @@ -725,8 +724,8 @@ msgstr "Conjuntos" #: ../Doc/reference/datamodel.rst:407 msgid "" "These represent a mutable set. They are created by the built-in :func:`set` " -"constructor and can be modified afterwards by several methods, such as " -":meth:`~set.add`." +"constructor and can be modified afterwards by several methods, such as :meth:" +"`~set.add`." msgstr "" "Estos representan un conjunto mutable. Son creados por el constructor " "incorporado :func:`set` y puede ser modificado posteriormente por varios " @@ -738,15 +737,14 @@ msgstr "Conjuntos congelados" #: ../Doc/reference/datamodel.rst:414 msgid "" -"These represent an immutable set. They are created by the built-in " -":func:`frozenset` constructor. As a frozenset is immutable and " -":term:`hashable`, it can be used again as an element of another set, or as a" -" dictionary key." +"These represent an immutable set. They are created by the built-in :func:" +"`frozenset` constructor. As a frozenset is immutable and :term:`hashable`, " +"it can be used again as an element of another set, or as a dictionary key." msgstr "" "Estos representan un conjunto inmutable. Son creados por el constructor " -"incorporado :func:`frozenset`. Como un conjunto congelado es inmutable y " -":term:`hashable`, se puede usar nuevamente como un elemento de otro conjunto" -" o como una clave de un diccionario." +"incorporado :func:`frozenset`. Como un conjunto congelado es inmutable y :" +"term:`hashable`, se puede usar nuevamente como un elemento de otro conjunto " +"o como una clave de un diccionario." #: ../Doc/reference/datamodel.rst:464 msgid "Mappings" @@ -763,9 +761,9 @@ msgstr "" "Estos representan conjuntos finitos de objetos indexados por conjuntos de " "índices arbitrarios. La notación de subíndice ``a[k]`` selecciona el " "elemento indexado por ``k`` del mapeo ``a``; esto se puede usar en " -"expresiones y como el objetivo de asignaciones o declaraciones " -":keyword:`del`. La función incorporada :func:`len` retorna el número de " -"elementos en un mapeo." +"expresiones y como el objetivo de asignaciones o declaraciones :keyword:" +"`del`. La función incorporada :func:`len` retorna el número de elementos en " +"un mapeo." #: ../Doc/reference/datamodel.rst:431 msgid "There is currently a single intrinsic mapping type:" @@ -790,29 +788,29 @@ msgstr "" "arbitrarios. Los únicos tipos de valores no aceptables como claves son " "valores que contienen listas o diccionarios u otros tipos mutables que se " "comparan por valor en lugar de por identidad de objeto, la razón es que la " -"implementación eficiente de los diccionarios requiere que el valor *hash* de" -" una clave permanezca constante. Los tipos numéricos utilizados para las " +"implementación eficiente de los diccionarios requiere que el valor *hash* de " +"una clave permanezca constante. Los tipos numéricos utilizados para las " "claves obedecen las reglas normales para la comparación numérica: si dos " "números se comparan igual (por ejemplo, ``1`` y ``1.0``) entonces se pueden " "usar indistintamente para indexar la misma entrada del diccionario." #: ../Doc/reference/datamodel.rst:445 msgid "" -"Dictionaries preserve insertion order, meaning that keys will be produced in" -" the same order they were added sequentially over the dictionary. Replacing " +"Dictionaries preserve insertion order, meaning that keys will be produced in " +"the same order they were added sequentially over the dictionary. Replacing " "an existing key does not change the order, however removing a key and re-" "inserting it will add it to the end instead of keeping its old place." msgstr "" "Los diccionarios conservan el orden de inserción, lo que significa que las " "claves se mantendrán en el mismo orden en que se agregaron secuencialmente " -"sobre el diccionario. Reemplazar una clave existente no cambia el orden, sin" -" embargo, eliminar una clave y volver a insertarla la agregará al final en " +"sobre el diccionario. Reemplazar una clave existente no cambia el orden, sin " +"embargo, eliminar una clave y volver a insertarla la agregará al final en " "lugar de mantener su lugar anterior." #: ../Doc/reference/datamodel.rst:450 msgid "" -"Dictionaries are mutable; they can be created by the ``{...}`` notation (see" -" section :ref:`dict`)." +"Dictionaries are mutable; they can be created by the ``{...}`` notation (see " +"section :ref:`dict`)." msgstr "" "Los diccionarios son mutables; pueden ser creados por la notación ``{...}`` " "(vea la sección :ref:`dict`)." @@ -823,14 +821,14 @@ msgid "" "examples of mapping types, as does the :mod:`collections` module." msgstr "" "Los módulos de extensión :mod:`dbm.ndbm` y :mod:`dbm.gnu` proporcionan " -"ejemplos adicionales de tipos de mapeo, al igual que el módulo " -":mod:`collections`." +"ejemplos adicionales de tipos de mapeo, al igual que el módulo :mod:" +"`collections`." #: ../Doc/reference/datamodel.rst:461 msgid "" "Dictionaries did not preserve insertion order in versions of Python before " -"3.6. In CPython 3.6, insertion order was preserved, but it was considered an" -" implementation detail at that time rather than a language guarantee." +"3.6. In CPython 3.6, insertion order was preserved, but it was considered an " +"implementation detail at that time rather than a language guarantee." msgstr "" "Los diccionarios no conservaban el orden de inserción en las versiones de " "Python anteriores a 3.6. En CPython 3.6, el orden de inserción se conserva, " @@ -843,8 +841,8 @@ msgstr "Tipos invocables" #: ../Doc/reference/datamodel.rst:473 msgid "" -"These are the types to which the function call operation (see section " -":ref:`calls`) can be applied:" +"These are the types to which the function call operation (see section :ref:" +"`calls`) can be applied:" msgstr "" "Estos son los tipos a los que la operación de llamada de función (vea la " "sección :ref:`calls`) puede ser aplicado:" @@ -952,8 +950,8 @@ msgstr ":attr:`__globals__`" #: ../Doc/reference/datamodel.rst:533 msgid "" -"A reference to the dictionary that holds the function's global variables ---" -" the global namespace of the module in which the function was defined." +"A reference to the dictionary that holds the function's global variables --- " +"the global namespace of the module in which the function was defined." msgstr "" "Una referencia al diccionario que contiene las variables globales de la " "función --- el espacio de nombres global del módulo en el que se definió la " @@ -1016,17 +1014,17 @@ msgid "" "Most of the attributes labelled \"Writable\" check the type of the assigned " "value." msgstr "" -"La mayoría de los atributos etiquetados \"Escribible\" verifican el tipo del" -" valor asignado." +"La mayoría de los atributos etiquetados \"Escribible\" verifican el tipo del " +"valor asignado." #: ../Doc/reference/datamodel.rst:567 msgid "" "Function objects also support getting and setting arbitrary attributes, " "which can be used, for example, to attach metadata to functions. Regular " "attribute dot-notation is used to get and set such attributes. *Note that " -"the current implementation only supports function attributes on user-defined" -" functions. Function attributes on built-in functions may be supported in " -"the future.*" +"the current implementation only supports function attributes on user-defined " +"functions. Function attributes on built-in functions may be supported in the " +"future.*" msgstr "" "Los objetos de función también admiten la obtención y configuración de " "atributos arbitrarios, que se pueden usar, por ejemplo, para adjuntar " @@ -1047,14 +1045,13 @@ msgstr "" #: ../Doc/reference/datamodel.rst:576 msgid "" "Additional information about a function's definition can be retrieved from " -"its code object; see the description of internal types below. The " -":data:`cell ` type can be accessed in the :mod:`types` " -"module." +"its code object; see the description of internal types below. The :data:" +"`cell ` type can be accessed in the :mod:`types` module." msgstr "" "Se puede recuperar información adicional sobre la definición de una función " "desde su objeto de código; Vea la descripción de los tipos internos a " -"continuación. El tipo :data:`cell ` puede ser accedido en el" -" módulo :mod:`types`." +"continuación. El tipo :data:`cell ` puede ser accedido en el " +"módulo :mod:`types`." #: ../Doc/reference/datamodel.rst:642 msgid "Instance methods" @@ -1065,26 +1062,24 @@ msgid "" "An instance method object combines a class, a class instance and any " "callable object (normally a user-defined function)." msgstr "" -"Un objeto de método de instancia combina una clase, una instancia de clase y" -" cualquier objeto invocable (normalmente una función definida por el " -"usuario)." +"Un objeto de método de instancia combina una clase, una instancia de clase y " +"cualquier objeto invocable (normalmente una función definida por el usuario)." #: ../Doc/reference/datamodel.rst:597 msgid "" -"Special read-only attributes: :attr:`__self__` is the class instance object," -" :attr:`__func__` is the function object; :attr:`__doc__` is the method's " -"documentation (same as ``__func__.__doc__``); :attr:`~definition.__name__` " -"is the method name (same as ``__func__.__name__``); :attr:`__module__` is " -"the name of the module the method was defined in, or ``None`` if " -"unavailable." +"Special read-only attributes: :attr:`__self__` is the class instance " +"object, :attr:`__func__` is the function object; :attr:`__doc__` is the " +"method's documentation (same as ``__func__.__doc__``); :attr:`~definition." +"__name__` is the method name (same as ``__func__.__name__``); :attr:" +"`__module__` is the name of the module the method was defined in, or " +"``None`` if unavailable." msgstr "" "Atributos especiales de solo lectura: :attr:`__self__` es el objeto de " -"instancia de clase, :attr:`__func__` es el objeto de función; " -":attr:`__doc__` es la documentación del método (al igual que " -"``__func__.__doc__``); :attr:`~definition.__name__` es el nombre del método " -"(al igual que ``__func__.__name__``); :attr:`__module__` es el nombre del " -"módulo en el que el método fue definido, o ``None`` si no se encuentra " -"disponible." +"instancia de clase, :attr:`__func__` es el objeto de función; :attr:" +"`__doc__` es la documentación del método (al igual que ``__func__." +"__doc__``); :attr:`~definition.__name__` es el nombre del método (al igual " +"que ``__func__.__name__``); :attr:`__module__` es el nombre del módulo en el " +"que el método fue definido, o ``None`` si no se encuentra disponible." #: ../Doc/reference/datamodel.rst:603 msgid "" @@ -1115,36 +1110,35 @@ msgstr "" "Cuando un objeto de instancia de método es creado al obtener un objeto de " "función definida por el usuario desde una clase a través de una de sus " "instancias, su atributo :attr:`__self__` es la instancia, y el objeto de " -"método se dice que está enlazado. El nuevo atributo de método " -":attr:`__func__` es el objeto de función original." +"método se dice que está enlazado. El nuevo atributo de método :attr:" +"`__func__` es el objeto de función original." #: ../Doc/reference/datamodel.rst:616 msgid "" "When an instance method object is created by retrieving a class method " -"object from a class or instance, its :attr:`__self__` attribute is the class" -" itself, and its :attr:`__func__` attribute is the function object " -"underlying the class method." +"object from a class or instance, its :attr:`__self__` attribute is the class " +"itself, and its :attr:`__func__` attribute is the function object underlying " +"the class method." msgstr "" "Cuando un objeto de instancia de método es creado al obtener un objeto de " -"método de clase a partir de una clase o instancia, su atributo " -":attr:`__self__` es la clase misma, y su atributo :attr:`__func__` es el " -"objeto de función subyacente al método de la clase." +"método de clase a partir de una clase o instancia, su atributo :attr:" +"`__self__` es la clase misma, y su atributo :attr:`__func__` es el objeto de " +"función subyacente al método de la clase." #: ../Doc/reference/datamodel.rst:621 msgid "" -"When an instance method object is called, the underlying function " -"(:attr:`__func__`) is called, inserting the class instance " -"(:attr:`__self__`) in front of the argument list. For instance, when " -":class:`C` is a class which contains a definition for a function :meth:`f`, " -"and ``x`` is an instance of :class:`C`, calling ``x.f(1)`` is equivalent to " -"calling ``C.f(x, 1)``." +"When an instance method object is called, the underlying function (:attr:" +"`__func__`) is called, inserting the class instance (:attr:`__self__`) in " +"front of the argument list. For instance, when :class:`C` is a class which " +"contains a definition for a function :meth:`f`, and ``x`` is an instance of :" +"class:`C`, calling ``x.f(1)`` is equivalent to calling ``C.f(x, 1)``." msgstr "" "Cuando el objeto de la instancia de método es invocado, la función " -"subyacente (:attr:`__func__`) es llamada, insertando la instancia de clase " -"(:attr:`__self__`) delante de la lista de argumentos. Por ejemplo, cuando " -":class:`C` es una clase que contiene la definición de una función :meth:`f`," -" y ``x`` es una instancia de :class:`C`, invocar ``x.f(1)`` es equivalente a" -" invocar ``C.f(x, 1)``." +"subyacente (:attr:`__func__`) es llamada, insertando la instancia de clase (:" +"attr:`__self__`) delante de la lista de argumentos. Por ejemplo, cuando :" +"class:`C` es una clase que contiene la definición de una función :meth:`f`, " +"y ``x`` es una instancia de :class:`C`, invocar ``x.f(1)`` es equivalente a " +"invocar ``C.f(x, 1)``." #: ../Doc/reference/datamodel.rst:628 msgid "" @@ -1153,10 +1147,10 @@ msgid "" "itself, so that calling either ``x.f(1)`` or ``C.f(1)`` is equivalent to " "calling ``f(C,1)`` where ``f`` is the underlying function." msgstr "" -"Cuando el objeto de instancia de método es derivado del objeto del método de" -" clase, la “instancia de clase” almacenada en :attr:`__self__` en realidad " -"será la clase misma, de manera que invocar ya sea ``x.f(1)`` o ``C.f(1)`` es" -" equivalente a invocar ``f(C,1)`` donde ``f`` es la función subyacente." +"Cuando el objeto de instancia de método es derivado del objeto del método de " +"clase, la “instancia de clase” almacenada en :attr:`__self__` en realidad " +"será la clase misma, de manera que invocar ya sea ``x.f(1)`` o ``C.f(1)`` es " +"equivalente a invocar ``f(C,1)`` donde ``f`` es la función subyacente." #: ../Doc/reference/datamodel.rst:633 msgid "" @@ -1164,14 +1158,14 @@ msgid "" "happens each time the attribute is retrieved from the instance. In some " "cases, a fruitful optimization is to assign the attribute to a local " "variable and call that local variable. Also notice that this transformation " -"only happens for user-defined functions; other callable objects (and all " -"non-callable objects) are retrieved without transformation. It is also " +"only happens for user-defined functions; other callable objects (and all non-" +"callable objects) are retrieved without transformation. It is also " "important to note that user-defined functions which are attributes of a " "class instance are not converted to bound methods; this *only* happens when " "the function is an attribute of the class." msgstr "" -"Tome en cuenta que la transformación de objeto de función a objeto de método" -" de instancia ocurre cada vez que el atributo es obtenido de la instancia. " +"Tome en cuenta que la transformación de objeto de función a objeto de método " +"de instancia ocurre cada vez que el atributo es obtenido de la instancia. " "En algunos casos, una optimización fructífera es asignar el atributo a una " "variable local e invocarla. Note también que esta transformación únicamente " "ocurre con funciones definidas por usuario; otros objetos invocables (y " @@ -1187,21 +1181,21 @@ msgstr "Funciones generadoras" #: ../Doc/reference/datamodel.rst:649 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 " +"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 :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." +"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 "" "Una función o método que utiliza la instrucción :keyword:`yield` (consulte " "la sección :ref:`yield`) se denomina :dfn:`función generadora`. Una función " "de este tipo, cuando se llama, siempre devuelve un objeto :term:`iterator` " -"que se puede usar para ejecutar el cuerpo de la función: llamar al método " -":meth:`iterator.__next__` del iterador hará que la función se ejecute hasta " +"que se puede usar para ejecutar el cuerpo de la función: llamar al método :" +"meth:`iterator.__next__` del iterador hará que la función se ejecute hasta " "que proporcione un valor usando la declaración :keyword:`!yield`. Cuando la " "función ejecuta una declaración :keyword:`return` o se cae del final, se " "genera una excepción :exc:`StopIteration` y el iterador habrá llegado al " @@ -1213,17 +1207,17 @@ msgstr "Funciones de corrutina" #: ../Doc/reference/datamodel.rst:663 msgid "" -"A function or method which is defined using :keyword:`async def` is called a" -" :dfn:`coroutine function`. Such a function, when called, returns a " -":term:`coroutine` object. It may contain :keyword:`await` expressions, as " -"well as :keyword:`async with` and :keyword:`async for` statements. See also " -"the :ref:`coroutine-objects` section." +"A function or method which is defined using :keyword:`async def` is called " +"a :dfn:`coroutine function`. Such a function, when called, returns a :term:" +"`coroutine` object. It may contain :keyword:`await` expressions, as well " +"as :keyword:`async with` and :keyword:`async for` statements. See also the :" +"ref:`coroutine-objects` section." msgstr "" "Una función o método que es definido utilizando :keyword:`async def` se " -"llama :dfn:`coroutine function`. Dicha función, cuando es invocada, retorna" -" un objeto :term:`coroutine`. Éste puede contener expresiones " -":keyword:`await`, así como declaraciones :keyword:`async with` y " -":keyword:`async for`. Ver también la sección :ref:`coroutine-objects`." +"llama :dfn:`coroutine function`. Dicha función, cuando es invocada, retorna " +"un objeto :term:`coroutine`. Éste puede contener expresiones :keyword:" +"`await`, así como declaraciones :keyword:`async with` y :keyword:`async " +"for`. Ver también la sección :ref:`coroutine-objects`." #: ../Doc/reference/datamodel.rst:687 msgid "Asynchronous generator functions" @@ -1232,8 +1226,8 @@ msgstr "Funciones generadoras asincrónicas" #: ../Doc/reference/datamodel.rst:674 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 :term:`asynchronous " +"uses the :keyword:`yield` statement is called a :dfn:`asynchronous generator " +"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 "" @@ -1245,21 +1239,20 @@ msgstr "" #: ../Doc/reference/datamodel.rst:680 msgid "" -"Calling the asynchronous iterator's :meth:`aiterator.__anext__ " -"` method will return an :term:`awaitable` which when " -"awaited will execute until it provides a value using the :keyword:`yield` " -"expression. When the function executes an empty :keyword:`return` statement" -" or falls off the end, a :exc:`StopAsyncIteration` exception is raised and " -"the asynchronous iterator will have reached the end of the set of values to " -"be yielded." -msgstr "" -"Llamar al método :meth:`aiterator.__anext__ ` del iterador" -" asíncrono devolverá un :term:`awaitable` que, cuando se espera, se " -"ejecutará hasta que proporcione un valor mediante la expresión " -":keyword:`yield`. Cuando la función ejecuta una declaración " -":keyword:`return` vacía o se cae del final, se genera una excepción " -":exc:`StopAsyncIteration` y el iterador asíncrono habrá llegado al final del" -" conjunto de valores que se generarán." +"Calling the asynchronous iterator's :meth:`aiterator.__anext__ ` method will return an :term:`awaitable` which when awaited will " +"execute until it provides a value using the :keyword:`yield` expression. " +"When the function executes an empty :keyword:`return` statement or falls off " +"the end, a :exc:`StopAsyncIteration` exception is raised and the " +"asynchronous iterator will have reached the end of the set of values to be " +"yielded." +msgstr "" +"Llamar al método :meth:`aiterator.__anext__ ` del iterador " +"asíncrono devolverá un :term:`awaitable` que, cuando se espera, se ejecutará " +"hasta que proporcione un valor mediante la expresión :keyword:`yield`. " +"Cuando la función ejecuta una declaración :keyword:`return` vacía o se cae " +"del final, se genera una excepción :exc:`StopAsyncIteration` y el iterador " +"asíncrono habrá llegado al final del conjunto de valores que se generarán." #: ../Doc/reference/datamodel.rst:702 msgid "Built-in functions" @@ -1271,21 +1264,21 @@ msgid "" "built-in functions are :func:`len` and :func:`math.sin` (:mod:`math` is a " "standard built-in module). The number and type of the arguments are " "determined by the C function. Special read-only attributes: :attr:`__doc__` " -"is the function's documentation string, or ``None`` if unavailable; " -":attr:`~definition.__name__` is the function's name; :attr:`__self__` is set" -" to ``None`` (but see the next item); :attr:`__module__` is the name of the " +"is the function's documentation string, or ``None`` if unavailable; :attr:" +"`~definition.__name__` is the function's name; :attr:`__self__` is set to " +"``None`` (but see the next item); :attr:`__module__` is the name of the " "module the function was defined in or ``None`` if unavailable." msgstr "" -"Un objeto de función incorporada es un envoltorio (wrapper) alrededor de una" -" función C. Ejemplos de funciones incorporadas son :func:`len` y " -":func:`math.sin` (:mod:`math` es un módulo estándar incorporado). El número " -"y tipo de argumentos son determinados por la función C. Atributos especiales" -" de solo lectura: :attr:`__doc__` es la cadena de documentación de la " -"función, o ``None`` si no se encuentra disponible; " -":attr:`~definition.__name__` es el nombre de la función; :attr:`__init__` es" -" establecido como ``None`` (sin embargo ver el siguiente elemento); " -":attr:`__module__` es el nombre del módulo en el que la función fue definida" -" o ``None`` si no se encuentra disponible." +"Un objeto de función incorporada es un envoltorio (wrapper) alrededor de una " +"función C. Ejemplos de funciones incorporadas son :func:`len` y :func:`math." +"sin` (:mod:`math` es un módulo estándar incorporado). El número y tipo de " +"argumentos son determinados por la función C. Atributos especiales de solo " +"lectura: :attr:`__doc__` es la cadena de documentación de la función, o " +"``None`` si no se encuentra disponible; :attr:`~definition.__name__` es el " +"nombre de la función; :attr:`__init__` es establecido como ``None`` (sin " +"embargo ver el siguiente elemento); :attr:`__module__` es el nombre del " +"módulo en el que la función fue definida o ``None`` si no se encuentra " +"disponible." #: ../Doc/reference/datamodel.rst:714 msgid "Built-in methods" @@ -1294,10 +1287,10 @@ msgstr "Métodos incorporados" #: ../Doc/reference/datamodel.rst:710 msgid "" "This is really a different disguise of a built-in function, this time " -"containing an object passed to the C function as an implicit extra argument." -" An example of a built-in method is ``alist.append()``, assuming *alist* is" -" a list object. In this case, the special read-only attribute " -":attr:`__self__` is set to the object denoted by *alist*." +"containing an object passed to the C function as an implicit extra " +"argument. An example of a built-in method is ``alist.append()``, assuming " +"*alist* is a list object. In this case, the special read-only attribute :" +"attr:`__self__` is set to the object denoted by *alist*." msgstr "" "Éste es realmente un disfraz distinto de una función incorporada, esta vez " "teniendo un objeto que se pasa a la función C como un argumento extra " @@ -1314,15 +1307,15 @@ msgstr "Clases" msgid "" "Classes are callable. These objects normally act as factories for new " "instances of themselves, but variations are possible for class types that " -"override :meth:`~object.__new__`. The arguments of the call are passed to " -":meth:`__new__` and, in the typical case, to :meth:`~object.__init__` to " +"override :meth:`~object.__new__`. The arguments of the call are passed to :" +"meth:`__new__` and, in the typical case, to :meth:`~object.__init__` to " "initialize the new instance." msgstr "" "Las clases son llamables. Estos objetos normalmente actúan como fábricas " "para nuevas instancias de sí mismos, pero es posible que haya variaciones " "para los tipos de clase que anulan :meth:`~object.__new__`. Los argumentos " -"de la llamada se pasan a :meth:`__new__` y, en el caso típico, a " -":meth:`~object.__init__` para inicializar la nueva instancia." +"de la llamada se pasan a :meth:`__new__` y, en el caso típico, a :meth:" +"`~object.__init__` para inicializar la nueva instancia." #: ../Doc/reference/datamodel.rst:726 msgid "Class Instances" @@ -1330,8 +1323,8 @@ msgstr "Instancias de clases" #: ../Doc/reference/datamodel.rst:724 msgid "" -"Instances of arbitrary classes can be made callable by defining a " -":meth:`~object.__call__` method in their class." +"Instances of arbitrary classes can be made callable by defining a :meth:" +"`~object.__call__` method in their class." msgstr "" "Las instancias de clases arbitrarias se pueden hacer invocables definiendo " "un método :meth:`~object.__call__` en su clase." @@ -1343,27 +1336,27 @@ msgstr "Módulos" #: ../Doc/reference/datamodel.rst:733 msgid "" "Modules are a basic organizational unit of Python code, and are created by " -"the :ref:`import system ` as invoked either by the " -":keyword:`import` statement, or by calling functions such as " -":func:`importlib.import_module` and built-in :func:`__import__`. A module " -"object has a namespace implemented by a dictionary object (this is the " -"dictionary referenced by the ``__globals__`` attribute of functions defined " -"in the module). Attribute references are translated to lookups in this " -"dictionary, e.g., ``m.x`` is equivalent to ``m.__dict__[\"x\"]``. A module " -"object does not contain the code object used to initialize the module (since" -" it isn't needed once the initialization is done)." +"the :ref:`import system ` as invoked either by the :keyword:" +"`import` statement, or by calling functions such as :func:`importlib." +"import_module` and built-in :func:`__import__`. A module object has a " +"namespace implemented by a dictionary object (this is the dictionary " +"referenced by the ``__globals__`` attribute of functions defined in the " +"module). Attribute references are translated to lookups in this dictionary, " +"e.g., ``m.x`` is equivalent to ``m.__dict__[\"x\"]``. A module object does " +"not contain the code object used to initialize the module (since it isn't " +"needed once the initialization is done)." msgstr "" "Los módulos son una unidad básica organizacional en código Python, y son " "creados por el :ref:`import system ` al ser invocados ya sea " -"por la declaración :keyword:`import`, o invocando funciones como " -":func:`importlib.import_module` y la incorporada :func:`__import__`. Un " -"objeto de módulo tiene un espacio de nombres implementado por un objeto de " -"diccionario (éste es el diccionario al que hace referencia el atributo de " -"funciones ``__globals__`` definido en el módulo). Las referencias de " -"atributos son traducidas a búsquedas en este diccionario, p. ej., ``m.x`` es" -" equivalente a ``m.__dict__[“x”]``. Un objeto de módulo no contiene el " -"objeto de código utilizado para iniciar el módulo (ya que no es necesario " -"una vez que la inicialización es realizada)." +"por la declaración :keyword:`import`, o invocando funciones como :func:" +"`importlib.import_module` y la incorporada :func:`__import__`. Un objeto de " +"módulo tiene un espacio de nombres implementado por un objeto de diccionario " +"(éste es el diccionario al que hace referencia el atributo de funciones " +"``__globals__`` definido en el módulo). Las referencias de atributos son " +"traducidas a búsquedas en este diccionario, p. ej., ``m.x`` es equivalente a " +"``m.__dict__[“x”]``. Un objeto de módulo no contiene el objeto de código " +"utilizado para iniciar el módulo (ya que no es necesario una vez que la " +"inicialización es realizada)." #: ../Doc/reference/datamodel.rst:745 msgid "" @@ -1397,8 +1390,8 @@ msgstr ":attr:`__file__`" #: ../Doc/reference/datamodel.rst:765 msgid "" "The pathname of the file from which the module was loaded, if it was loaded " -"from a file. The :attr:`__file__` attribute may be missing for certain types" -" of modules, such as C modules that are statically linked into the " +"from a file. The :attr:`__file__` attribute may be missing for certain types " +"of modules, such as C modules that are statically linked into the " "interpreter. For extension modules loaded dynamically from a shared " "library, it's the pathname of the shared library file." msgstr "" @@ -1412,13 +1405,13 @@ msgstr "" #: ../Doc/reference/datamodel.rst:774 msgid "" "A dictionary containing :term:`variable annotations ` " -"collected during module body execution. For best practices on working with " -":attr:`__annotations__`, please see :ref:`annotations-howto`." +"collected during module body execution. For best practices on working with :" +"attr:`__annotations__`, please see :ref:`annotations-howto`." msgstr "" "Un diccionario que contiene el :term:`variable annotations ` recopilados durante la ejecución del cuerpo del módulo. Para " -"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve " -":ref:`annotations-howto`." +"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve :" +"ref:`annotations-howto`." #: ../Doc/reference/datamodel.rst:781 msgid "" @@ -1430,16 +1423,16 @@ msgstr "" #: ../Doc/reference/datamodel.rst:786 msgid "" -"Because of the way CPython clears module dictionaries, the module dictionary" -" will be cleared when the module falls out of scope even if the dictionary " +"Because of the way CPython clears module dictionaries, the module dictionary " +"will be cleared when the module falls out of scope even if the dictionary " "still has live references. To avoid this, copy the dictionary or keep the " "module around while using its dictionary directly." msgstr "" "Debido a la manera en la que CPython limpia los diccionarios de módulo, el " "diccionario de módulo será limpiado cuando el módulo se encuentra fuera de " "alcance, incluso si el diccionario aún tiene referencias existentes. Para " -"evitar esto, copie el diccionario o mantenga el módulo cerca mientras usa el" -" diccionario directamente." +"evitar esto, copie el diccionario o mantenga el módulo cerca mientras usa el " +"diccionario directamente." #: ../Doc/reference/datamodel.rst:864 msgid "Custom classes" @@ -1447,18 +1440,18 @@ msgstr "Clases personalizadas" #: ../Doc/reference/datamodel.rst:792 msgid "" -"Custom class types are typically created by class definitions (see section " -":ref:`class`). A class has a namespace implemented by a dictionary object. " -"Class attribute references are translated to lookups in this dictionary, " -"e.g., ``C.x`` is translated to ``C.__dict__[\"x\"]`` (although there are a " +"Custom class types are typically created by class definitions (see section :" +"ref:`class`). A class has a namespace implemented by a dictionary object. " +"Class attribute references are translated to lookups in this dictionary, e." +"g., ``C.x`` is translated to ``C.__dict__[\"x\"]`` (although there are a " "number of hooks which allow for other means of locating attributes). When " -"the attribute name is not found there, the attribute search continues in the" -" base classes. This search of the base classes uses the C3 method resolution" -" order which behaves correctly even in the presence of 'diamond' inheritance" -" structures where there are multiple inheritance paths leading back to a " +"the attribute name is not found there, the attribute search continues in the " +"base classes. This search of the base classes uses the C3 method resolution " +"order which behaves correctly even in the presence of 'diamond' inheritance " +"structures where there are multiple inheritance paths leading back to a " "common ancestor. Additional details on the C3 MRO used by Python can be " -"found in the documentation accompanying the 2.3 release at " -"https://www.python.org/download/releases/2.3/mro/." +"found in the documentation accompanying the 2.3 release at https://www." +"python.org/download/releases/2.3/mro/." msgstr "" "Los tipos de clases personalizadas son normalmente creadas por definiciones " "de clases (ver sección :ref:`class`). Una clase tiene implementado un " @@ -1467,32 +1460,31 @@ msgstr "" "``C.x`` es traducido a ``C.__dict__[“x”]`` (aunque hay una serie de enlaces " "que permiten la ubicación de atributos por otros medios). Cuando el nombre " "de atributo no es encontrado ahí, la búsqueda de atributo continúa en las " -"clases base. Esta búsqueda de las clases base utiliza la orden de resolución" -" de métodos C3 que se comporta correctamente aún en la presencia de " -"estructuras de herencia ‘diamante’ donde existen múltiples rutas de herencia" -" que llevan a un ancestro común. Detalles adicionales en el MRO C3 " -"utilizados por Python pueden ser encontrados en la documentación " -"correspondiente a la versión 2.3 en " -"https://www.python.org/download/releases/2.3/mro/." +"clases base. Esta búsqueda de las clases base utiliza la orden de resolución " +"de métodos C3 que se comporta correctamente aún en la presencia de " +"estructuras de herencia ‘diamante’ donde existen múltiples rutas de herencia " +"que llevan a un ancestro común. Detalles adicionales en el MRO C3 utilizados " +"por Python pueden ser encontrados en la documentación correspondiente a la " +"versión 2.3 en https://www.python.org/download/releases/2.3/mro/." #: ../Doc/reference/datamodel.rst:816 msgid "" "When a class attribute reference (for class :class:`C`, say) would yield a " -"class method object, it is transformed into an instance method object whose " -":attr:`__self__` attribute is :class:`C`. When it would yield a static " +"class method object, it is transformed into an instance method object whose :" +"attr:`__self__` attribute is :class:`C`. When it would yield a static " "method object, it is transformed into the object wrapped by the static " "method object. See section :ref:`descriptors` for another way in which " "attributes retrieved from a class may differ from those actually contained " "in its :attr:`~object.__dict__`." msgstr "" -"Cuando la referencia de un atributo de clase (digamos, para la clase " -":class:`C`) produce un objeto de método de clase, éste es transformado a un " -"objeto de método de instancia cuyo atributo :attr:`__self__` es :class:`C`." -" Cuando produce un objeto de un método estático, éste es transformado al " -"objeto envuelto por el objeto de método estático. Ver sección " -":ref:`descriptors` para otra manera en la que los atributos obtenidos de una" -" clase pueden diferir de los que en realidad están contenidos en su " -":attr:`~object.__dict__`." +"Cuando la referencia de un atributo de clase (digamos, para la clase :class:" +"`C`) produce un objeto de método de clase, éste es transformado a un objeto " +"de método de instancia cuyo atributo :attr:`__self__` es :class:`C`. Cuando " +"produce un objeto de un método estático, éste es transformado al objeto " +"envuelto por el objeto de método estático. Ver sección :ref:`descriptors` " +"para otra manera en la que los atributos obtenidos de una clase pueden " +"diferir de los que en realidad están contenidos en su :attr:`~object." +"__dict__`." #: ../Doc/reference/datamodel.rst:826 msgid "" @@ -1532,11 +1524,11 @@ msgstr ":attr:`~class.__bases__`" #: ../Doc/reference/datamodel.rst:853 msgid "" -"A tuple containing the base classes, in the order of their occurrence in the" -" base class list." +"A tuple containing the base classes, in the order of their occurrence in the " +"base class list." msgstr "" -"Una tupla conteniendo las clases de base, en orden de ocurrencia en la lista" -" de clase base." +"Una tupla conteniendo las clases de base, en orden de ocurrencia en la lista " +"de clase base." #: ../Doc/reference/datamodel.rst:857 msgid "The class's documentation string, or ``None`` if undefined." @@ -1546,13 +1538,13 @@ msgstr "" #: ../Doc/reference/datamodel.rst:860 msgid "" "A dictionary containing :term:`variable annotations ` " -"collected during class body execution. For best practices on working with " -":attr:`__annotations__`, please see :ref:`annotations-howto`." +"collected during class body execution. For best practices on working with :" +"attr:`__annotations__`, please see :ref:`annotations-howto`." msgstr "" "Un diccionario conteniendo el :term:`variable annotations ` recopilados durante la ejecución del cuerpo de la clase. Para " -"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve " -":ref:`annotations-howto`." +"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve :" +"ref:`annotations-howto`." #: ../Doc/reference/datamodel.rst:907 msgid "Class instances" @@ -1571,36 +1563,36 @@ msgid "" "\"Classes\". See section :ref:`descriptors` for another way in which " "attributes of a class retrieved via its instances may differ from the " "objects actually stored in the class's :attr:`~object.__dict__`. If no " -"class attribute is found, and the object's class has a " -":meth:`~object.__getattr__` method, that is called to satisfy the lookup." +"class attribute is found, and the object's class has a :meth:`~object." +"__getattr__` method, that is called to satisfy the lookup." msgstr "" "Una instancia de clase se crea llamando a un objeto de clase (ver arriba). " "Una instancia de clase tiene un espacio de nombres implementado como un " "diccionario que es el primer lugar en el que se buscan las referencias de " "atributos. Cuando no se encuentra un atributo allí, y la clase de la " "instancia tiene un atributo con ese nombre, la búsqueda continúa con los " -"atributos de la clase. Si se encuentra un atributo de clase que es un objeto" -" de función definido por el usuario, se transforma en un objeto de método de" -" instancia cuyo atributo :attr:`__self__` es la instancia. Los objetos de " +"atributos de la clase. Si se encuentra un atributo de clase que es un objeto " +"de función definido por el usuario, se transforma en un objeto de método de " +"instancia cuyo atributo :attr:`__self__` es la instancia. Los objetos de " "método estático y método de clase también se transforman; ver arriba en " "\"Clases\". Consulte la sección :ref:`descriptors` para conocer otra forma " "en la que los atributos de una clase recuperados a través de sus instancias " -"pueden diferir de los objetos realmente almacenados en el " -":attr:`~object.__dict__` de la clase. Si no se encuentra ningún atributo de " -"clase y la clase del objeto tiene un método :meth:`~object.__getattr__`, se " -"llama para satisfacer la búsqueda." +"pueden diferir de los objetos realmente almacenados en el :attr:`~object." +"__dict__` de la clase. Si no se encuentra ningún atributo de clase y la " +"clase del objeto tiene un método :meth:`~object.__getattr__`, se llama para " +"satisfacer la búsqueda." #: ../Doc/reference/datamodel.rst:889 msgid "" "Attribute assignments and deletions update the instance's dictionary, never " -"a class's dictionary. If the class has a :meth:`~object.__setattr__` or " -":meth:`~object.__delattr__` method, this is called instead of updating the " +"a class's dictionary. If the class has a :meth:`~object.__setattr__` or :" +"meth:`~object.__delattr__` method, this is called instead of updating the " "instance dictionary directly." msgstr "" "Las asignaciones y eliminaciones de atributos actualizan el diccionario de " -"la instancia, nunca el diccionario de una clase. Si la clase tiene un método" -" :meth:`~object.__setattr__` o :meth:`~object.__delattr__`, se llama a este " -"en lugar de actualizar el diccionario de instancias directamente." +"la instancia, nunca el diccionario de una clase. Si la clase tiene un " +"método :meth:`~object.__setattr__` o :meth:`~object.__delattr__`, se llama a " +"este en lugar de actualizar el diccionario de instancias directamente." #: ../Doc/reference/datamodel.rst:899 msgid "" @@ -1608,13 +1600,13 @@ msgid "" "have methods with certain special names. See section :ref:`specialnames`." msgstr "" "Instancias de clases pueden pretender ser números, secuencias o mapeos si " -"tienen métodos con ciertos nombres especiales. Ver sección " -":ref:`specialnames`." +"tienen métodos con ciertos nombres especiales. Ver sección :ref:" +"`specialnames`." #: ../Doc/reference/datamodel.rst:906 msgid "" -"Special attributes: :attr:`~object.__dict__` is the attribute dictionary; " -":attr:`~instance.__class__` is the instance's class." +"Special attributes: :attr:`~object.__dict__` is the attribute dictionary; :" +"attr:`~instance.__class__` is the instance's class." msgstr "" "Atributos especiales: :attr:`~object.__dict__` es el diccionario de " "atributos; :attr:`~instance.__class__` es la clase de la instancia." @@ -1627,28 +1619,28 @@ msgstr "Objetos E/S (también conocidos como objetos de archivo)" msgid "" "A :term:`file object` represents an open file. Various shortcuts are " "available to create file objects: the :func:`open` built-in function, and " -"also :func:`os.popen`, :func:`os.fdopen`, and the " -":meth:`~socket.socket.makefile` method of socket objects (and perhaps by " -"other functions or methods provided by extension modules)." +"also :func:`os.popen`, :func:`os.fdopen`, and the :meth:`~socket.socket." +"makefile` method of socket objects (and perhaps by other functions or " +"methods provided by extension modules)." msgstr "" "Un :term:`file object` representa un archivo abierto. Diversos accesos " -"directos se encuentran disponibles para crear objetos de archivo: la función" -" incorporada :func:`open`, así como :func:`os.popen`, :func:`os.fdopen`, y " -"el método de objetos socket :meth:`~socket.makefile` (y quizás por otras " +"directos se encuentran disponibles para crear objetos de archivo: la función " +"incorporada :func:`open`, así como :func:`os.popen`, :func:`os.fdopen`, y el " +"método de objetos socket :meth:`~socket.makefile` (y quizás por otras " "funciones y métodos proporcionados por módulos de extensión)." #: ../Doc/reference/datamodel.rst:929 msgid "" -"The objects ``sys.stdin``, ``sys.stdout`` and ``sys.stderr`` are initialized" -" to file objects corresponding to the interpreter's standard input, output " +"The objects ``sys.stdin``, ``sys.stdout`` and ``sys.stderr`` are initialized " +"to file objects corresponding to the interpreter's standard input, output " "and error streams; they are all open in text mode and therefore follow the " "interface defined by the :class:`io.TextIOBase` abstract class." msgstr "" "Los objetos ``sys.stdin``, ``sys.stdout`` y ``sys.stderr`` son iniciados a " "objetos de archivos correspondientes a la entrada y salida estándar del " "intérprete, así como flujos de error; todos ellos están abiertos en el modo " -"de texto y por lo tanto siguen la interface definida por la clase abstracta " -":class:`io.TextIOBase`." +"de texto y por lo tanto siguen la interface definida por la clase abstracta :" +"class:`io.TextIOBase`." #: ../Doc/reference/datamodel.rst:1219 msgid "Internal types" @@ -1670,107 +1662,104 @@ msgstr "Objetos de código" #: ../Doc/reference/datamodel.rst:947 msgid "" -"Code objects represent *byte-compiled* executable Python code, or " -":term:`bytecode`. The difference between a code object and a function object" -" is that the function object contains an explicit reference to the " -"function's globals (the module in which it was defined), while a code object" -" contains no context; also the default argument values are stored in the " -"function object, not in the code object (because they represent values " -"calculated at run-time). Unlike function objects, code objects are " -"immutable and contain no references (directly or indirectly) to mutable " -"objects." -msgstr "" -"Los objetos de código representan código de Python ejecutable *compilado por" -" bytes*, o :term:`bytecode`. La diferencia entre un objeto de código y un " +"Code objects represent *byte-compiled* executable Python code, or :term:" +"`bytecode`. The difference between a code object and a function object is " +"that the function object contains an explicit reference to the function's " +"globals (the module in which it was defined), while a code object contains " +"no context; also the default argument values are stored in the function " +"object, not in the code object (because they represent values calculated at " +"run-time). Unlike function objects, code objects are immutable and contain " +"no references (directly or indirectly) to mutable objects." +msgstr "" +"Los objetos de código representan código de Python ejecutable *compilado por " +"bytes*, o :term:`bytecode`. La diferencia entre un objeto de código y un " "objeto de función es que el objeto de función contiene una referencia " "explícita a los globales de la función (el módulo en el que fue definido), " "mientras el objeto de código no contiene contexto; de igual manera los " "valores por defecto de los argumentos son almacenados en el objeto de " -"función, no en el objeto de código (porque representan valores calculados en" -" tiempo de ejecución). A diferencia de objetos de función, los objetos de " +"función, no en el objeto de código (porque representan valores calculados en " +"tiempo de ejecución). A diferencia de objetos de función, los objetos de " "código son inmutables y no contienen referencias (directas o indirectas) a " "objetos mutables." #: ../Doc/reference/datamodel.rst:975 msgid "" -"Special read-only attributes: :attr:`co_name` gives the function name; " -":attr:`co_qualname` gives the fully qualified function name; " -":attr:`co_argcount` is the total number of positional arguments (including " -"positional-only arguments and arguments with default values); " -":attr:`co_posonlyargcount` is the number of positional-only arguments " -"(including arguments with default values); :attr:`co_kwonlyargcount` is the " -"number of keyword-only arguments (including arguments with default values); " -":attr:`co_nlocals` is the number of local variables used by the function " -"(including arguments); :attr:`co_varnames` is a tuple containing the names " -"of the local variables (starting with the argument names); " -":attr:`co_cellvars` is a tuple containing the names of local variables that " -"are referenced by nested functions; :attr:`co_freevars` is a tuple " -"containing the names of free variables; :attr:`co_code` is a string " -"representing the sequence of bytecode instructions; :attr:`co_consts` is a " -"tuple containing the literals used by the bytecode; :attr:`co_names` is a " -"tuple containing the names used by the bytecode; :attr:`co_filename` is the " -"filename from which the code was compiled; :attr:`co_firstlineno` is the " -"first line number of the function; :attr:`co_lnotab` is a string encoding " -"the mapping from bytecode offsets to line numbers (for details see the " -"source code of the interpreter); :attr:`co_stacksize` is the required stack " -"size; :attr:`co_flags` is an integer encoding a number of flags for the " -"interpreter." +"Special read-only attributes: :attr:`co_name` gives the function name; :attr:" +"`co_qualname` gives the fully qualified function name; :attr:`co_argcount` " +"is the total number of positional arguments (including positional-only " +"arguments and arguments with default values); :attr:`co_posonlyargcount` is " +"the number of positional-only arguments (including arguments with default " +"values); :attr:`co_kwonlyargcount` is the number of keyword-only arguments " +"(including arguments with default values); :attr:`co_nlocals` is the number " +"of local variables used by the function (including arguments); :attr:" +"`co_varnames` is a tuple containing the names of the local variables " +"(starting with the argument names); :attr:`co_cellvars` is a tuple " +"containing the names of local variables that are referenced by nested " +"functions; :attr:`co_freevars` is a tuple containing the names of free " +"variables; :attr:`co_code` is a string representing the sequence of bytecode " +"instructions; :attr:`co_consts` is a tuple containing the literals used by " +"the bytecode; :attr:`co_names` is a tuple containing the names used by the " +"bytecode; :attr:`co_filename` is the filename from which the code was " +"compiled; :attr:`co_firstlineno` is the first line number of the function; :" +"attr:`co_lnotab` is a string encoding the mapping from bytecode offsets to " +"line numbers (for details see the source code of the interpreter); :attr:" +"`co_stacksize` is the required stack size; :attr:`co_flags` is an integer " +"encoding a number of flags for the interpreter." msgstr "" "Atributos especiales de solo lectura: :attr:`co_name` proporciona el nombre " "de la función; :attr:`co_qualname` proporciona el nombre de función " "completo; :attr:`co_argcount` es el número total de argumentos posicionales " "(incluidos los argumentos solo posicionales y los argumentos con valores " -"predeterminados); :attr:`co_posonlyargcount` es el número de argumentos solo" -" posicionales (incluidos los argumentos con valores predeterminados); " -":attr:`co_kwonlyargcount` es el número de argumentos de solo palabras clave " +"predeterminados); :attr:`co_posonlyargcount` es el número de argumentos solo " +"posicionales (incluidos los argumentos con valores predeterminados); :attr:" +"`co_kwonlyargcount` es el número de argumentos de solo palabras clave " "(incluidos los argumentos con valores predeterminados); :attr:`co_nlocals` " "es el número de variables locales utilizadas por la función (incluidos los " "argumentos); :attr:`co_varnames` es una tupla que contiene los nombres de " -"las variables locales (comenzando con los nombres de los argumentos); " -":attr:`co_cellvars` es una tupla que contiene los nombres de las variables " -"locales a las que hacen referencia las funciones anidadas; " -":attr:`co_freevars` es una tupla que contiene los nombres de las variables " -"libres; :attr:`co_code` es una cadena que representa la secuencia de " -"instrucciones de código de bytes; :attr:`co_consts` es una tupla que " -"contiene los literales utilizados por el código de bytes; :attr:`co_names` " -"es una tupla que contiene los nombres utilizados por el código de bytes; " -":attr:`co_filename` es el nombre de archivo a partir del cual se compiló el " -"código; :attr:`co_firstlineno` es el primer número de línea de la función; " -":attr:`co_lnotab` es una cadena que codifica la asignación de compensaciones" -" de bytecode a números de línea (para obtener más información, consulte el " -"código fuente del intérprete); :attr:`co_stacksize` es el tamaño de pila " -"requerido; :attr:`co_flags` es un número entero que codifica varios " -"indicadores para el intérprete." +"las variables locales (comenzando con los nombres de los argumentos); :attr:" +"`co_cellvars` es una tupla que contiene los nombres de las variables locales " +"a las que hacen referencia las funciones anidadas; :attr:`co_freevars` es " +"una tupla que contiene los nombres de las variables libres; :attr:`co_code` " +"es una cadena que representa la secuencia de instrucciones de código de " +"bytes; :attr:`co_consts` es una tupla que contiene los literales utilizados " +"por el código de bytes; :attr:`co_names` es una tupla que contiene los " +"nombres utilizados por el código de bytes; :attr:`co_filename` es el nombre " +"de archivo a partir del cual se compiló el código; :attr:`co_firstlineno` es " +"el primer número de línea de la función; :attr:`co_lnotab` es una cadena que " +"codifica la asignación de compensaciones de bytecode a números de línea " +"(para obtener más información, consulte el código fuente del intérprete); :" +"attr:`co_stacksize` es el tamaño de pila requerido; :attr:`co_flags` es un " +"número entero que codifica varios indicadores para el intérprete." #: ../Doc/reference/datamodel.rst:1000 msgid "" "The following flag bits are defined for :attr:`co_flags`: bit ``0x04`` is " "set if the function uses the ``*arguments`` syntax to accept an arbitrary " -"number of positional arguments; bit ``0x08`` is set if the function uses the" -" ``**keywords`` syntax to accept arbitrary keyword arguments; bit ``0x20`` " -"is set if the function is a generator." +"number of positional arguments; bit ``0x08`` is set if the function uses the " +"``**keywords`` syntax to accept arbitrary keyword arguments; bit ``0x20`` is " +"set if the function is a generator." msgstr "" "Los siguientes bits de bandera son definidos por :attr:`co_flags` : bit " "``0x04`` es establecido si la función utiliza la sintaxis ``*arguments`` " "para aceptar un número arbitrario de argumentos posicionales; bit ``0x08`` " -"es establecido si la función utiliza la sintaxis ``**keywords`` para aceptar" -" argumentos de palabras clave arbitrarios; bit ``0x20`` es establecido si la" -" función es un generador." +"es establecido si la función utiliza la sintaxis ``**keywords`` para aceptar " +"argumentos de palabras clave arbitrarios; bit ``0x20`` es establecido si la " +"función es un generador." #: ../Doc/reference/datamodel.rst:1006 msgid "" "Future feature declarations (``from __future__ import division``) also use " -"bits in :attr:`co_flags` to indicate whether a code object was compiled with" -" a particular feature enabled: bit ``0x2000`` is set if the function was " +"bits in :attr:`co_flags` to indicate whether a code object was compiled with " +"a particular feature enabled: bit ``0x2000`` is set if the function was " "compiled with future division enabled; bits ``0x10`` and ``0x1000`` were " "used in earlier versions of Python." msgstr "" "Declaraciones de características futuras (``from __future__ import " "division``) también utiliza bits en :attr:`co_flags` para indicar si el " "objeto de código fue compilado con alguna característica particular " -"habilitada: el bit ``0x2000`` es establecido si la función fue compilada con" -" división futura habilitada; los bits ``0x10`` y ``0x1000`` fueron " -"utilizados en versiones previas de Python." +"habilitada: el bit ``0x2000`` es establecido si la función fue compilada con " +"división futura habilitada; los bits ``0x10`` y ``0x1000`` fueron utilizados " +"en versiones previas de Python." #: ../Doc/reference/datamodel.rst:1012 msgid "Other bits in :attr:`co_flags` are reserved for internal use." @@ -1781,9 +1770,9 @@ msgid "" "If a code object represents a function, the first item in :attr:`co_consts` " "is the documentation string of the function, or ``None`` if undefined." msgstr "" -"Si un objeto de código representa una función, el primer elemento en " -":attr:`co_consts` es la cadena de documentación de la función, o ``None`` si" -" no está definido." +"Si un objeto de código representa una función, el primer elemento en :attr:" +"`co_consts` es la cadena de documentación de la función, o ``None`` si no " +"está definido." #: ../Doc/reference/datamodel.rst:1021 msgid "" @@ -1796,9 +1785,9 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1024 msgid "" "The iterator returns tuples containing the ``(start_line, end_line, " -"start_column, end_column)``. The *i-th* tuple corresponds to the position of" -" the source code that compiled to the *i-th* instruction. Column information" -" is 0-indexed utf-8 byte offsets on the given source line." +"start_column, end_column)``. The *i-th* tuple corresponds to the position of " +"the source code that compiled to the *i-th* instruction. Column information " +"is 0-indexed utf-8 byte offsets on the given source line." msgstr "" "El iterador devuelve tuplas que contienen ``(start_line, end_line, " "start_column, end_column)``. La tupla *i-th* corresponde a la posición del " @@ -1840,8 +1829,8 @@ msgstr "" msgid "" "When this occurs, some or all of the tuple elements can be :const:`None`." msgstr "" -"Cuando esto ocurre, algunos o todos los elementos de la tupla pueden ser " -":const:`None`." +"Cuando esto ocurre, algunos o todos los elementos de la tupla pueden ser :" +"const:`None`." #: ../Doc/reference/datamodel.rst:1045 msgid "" @@ -1857,8 +1846,8 @@ msgstr "" "archivos de Python compilados o del uso de la memoria del intérprete. Para " "evitar almacenar la información extra y/o desactivar la impresión de la " "información extra de seguimiento, se puede usar el indicador de línea de " -"comando :option:`-X` ``no_debug_ranges`` o la variable de entorno " -":envvar:`PYTHONNODEBUGRANGES`." +"comando :option:`-X` ``no_debug_ranges`` o la variable de entorno :envvar:" +"`PYTHONNODEBUGRANGES`." #: ../Doc/reference/datamodel.rst:1112 msgid "Frame objects" @@ -1876,66 +1865,66 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1068 msgid "" "Special read-only attributes: :attr:`f_back` is to the previous stack frame " -"(towards the caller), or ``None`` if this is the bottom stack frame; " -":attr:`f_code` is the code object being executed in this frame; " -":attr:`f_locals` is the dictionary used to look up local variables; " -":attr:`f_globals` is used for global variables; :attr:`f_builtins` is used " -"for built-in (intrinsic) names; :attr:`f_lasti` gives the precise " -"instruction (this is an index into the bytecode string of the code object)." +"(towards the caller), or ``None`` if this is the bottom stack frame; :attr:" +"`f_code` is the code object being executed in this frame; :attr:`f_locals` " +"is the dictionary used to look up local variables; :attr:`f_globals` is used " +"for global variables; :attr:`f_builtins` is used for built-in (intrinsic) " +"names; :attr:`f_lasti` gives the precise instruction (this is an index into " +"the bytecode string of the code object)." msgstr "" "Atributos especiales de solo lectura: :attr:`f_back` es para el marco de " "pila anterior (hacia quien produce el llamado), o ``None`` si éste es el " "marco de pila inferior; :attr:`f_code` es el objeto de código ejecutado en " "este marco; :attr:`f_locals` es el diccionario utilizado para buscar " -"variables locales; :attr:`f_globals` es usado por las variables globales; " -":attr:`f_builtins` es utilizado por nombres incorporados (intrínsecos); " -":attr:`f_lasti` da la instrucción precisa (éste es un índice dentro de la " -"cadena de bytecode del objeto de código)." +"variables locales; :attr:`f_globals` es usado por las variables globales; :" +"attr:`f_builtins` es utilizado por nombres incorporados (intrínsecos); :attr:" +"`f_lasti` da la instrucción precisa (éste es un índice dentro de la cadena " +"de bytecode del objeto de código)." #: ../Doc/reference/datamodel.rst:1076 msgid "" -"Accessing ``f_code`` raises an :ref:`auditing event ` " -"``object.__getattr__`` with arguments ``obj`` and ``\"f_code\"``." +"Accessing ``f_code`` raises an :ref:`auditing event ` ``object." +"__getattr__`` with arguments ``obj`` and ``\"f_code\"``." msgstr "" "Acceder a ``f_code`` lanza un objeto :ref:`evento de auditoría ` " "``.__getattr__`` con argumentos ``obj`` y ``\"f_code\"`` ." #: ../Doc/reference/datamodel.rst:1085 msgid "" -"Special writable attributes: :attr:`f_trace`, if not ``None``, is a function" -" called for various events during code execution (this is used by the " +"Special writable attributes: :attr:`f_trace`, if not ``None``, is a function " +"called for various events during code execution (this is used by the " "debugger). Normally an event is triggered for each new source line - this " "can be disabled by setting :attr:`f_trace_lines` to :const:`False`." msgstr "" -"Atributos especiales escribibles: :attr:`f_trace`, de lo contrario ``None``," -" es una función llamada por distintos eventos durante la ejecución del " -"código (éste es utilizado por el depurador). Normalmente un evento es " -"desencadenado por cada una de las líneas fuente - esto puede ser " -"deshabilitado estableciendo :attr:`f_trace_lines` a :const:`False`." +"Atributos especiales escribibles: :attr:`f_trace`, de lo contrario ``None``, " +"es una función llamada por distintos eventos durante la ejecución del código " +"(éste es utilizado por el depurador). Normalmente un evento es desencadenado " +"por cada una de las líneas fuente - esto puede ser deshabilitado " +"estableciendo :attr:`f_trace_lines` a :const:`False`." #: ../Doc/reference/datamodel.rst:1090 msgid "" -"Implementations *may* allow per-opcode events to be requested by setting " -":attr:`f_trace_opcodes` to :const:`True`. Note that this may lead to " +"Implementations *may* allow per-opcode events to be requested by setting :" +"attr:`f_trace_opcodes` to :const:`True`. Note that this may lead to " "undefined interpreter behaviour if exceptions raised by the trace function " "escape to the function being traced." msgstr "" "Las implementaciones *pueden* permitir que eventos por código de operación " "sean solicitados estableciendo :attr:`f_trace_opcodes` a :const:`True`. " "Tenga en cuenta que esto puede llevar a un comportamiento indefinido del " -"intérprete si se levantan excepciones por la función de rastreo escape hacia" -" la función que está siendo rastreada." +"intérprete si se levantan excepciones por la función de rastreo escape hacia " +"la función que está siendo rastreada." #: ../Doc/reference/datamodel.rst:1095 msgid "" -":attr:`f_lineno` is the current line number of the frame --- writing to this" -" from within a trace function jumps to the given line (only for the bottom-" +":attr:`f_lineno` is the current line number of the frame --- writing to this " +"from within a trace function jumps to the given line (only for the bottom-" "most frame). A debugger can implement a Jump command (aka Set Next " "Statement) by writing to f_lineno." msgstr "" ":attr:`f_lineno` es el número de línea actual del marco --- escribiendo a " -"esta forma dentro de una función de rastreo salta a la línea dada (solo para" -" el último marco). Un depurador puede implementar un comando de salto " +"esta forma dentro de una función de rastreo salta a la línea dada (solo para " +"el último marco). Un depurador puede implementar un comando de salto " "(*Jump*) (también conocido como *Set Next Statement*) al escribir en " "f_lineno." @@ -1952,8 +1941,8 @@ msgid "" msgstr "" "Este método limpia todas las referencias a variables locales mantenidas por " "el marco. También, si el marco pertenecía a un generador, éste es " -"finalizado. Esto ayuda a interrumpir los ciclos de referencia que involucran" -" objetos de marco (por ejemplo al detectar una excepción y almacenando su " +"finalizado. Esto ayuda a interrumpir los ciclos de referencia que involucran " +"objetos de marco (por ejemplo al detectar una excepción y almacenando su " "rastro para uso posterior)." #: ../Doc/reference/datamodel.rst:1110 @@ -1971,8 +1960,8 @@ msgid "" "explicitly created by calling :class:`types.TracebackType`." msgstr "" "Los objetos de seguimiento de pila representan el trazo de pila (*stack " -"trace*) de una excepción. Un objeto de rastreo es creado de manera implícita" -" cuando se da una excepción, y puede ser creada de manera explícita al " +"trace*) de una excepción. Un objeto de rastreo es creado de manera implícita " +"cuando se da una excepción, y puede ser creada de manera explícita al " "llamar :class:`types.TracebackType`." #: ../Doc/reference/datamodel.rst:1131 @@ -1980,26 +1969,23 @@ msgid "" "For implicitly created tracebacks, when the search for an exception handler " "unwinds the execution stack, at each unwound level a traceback object is " "inserted in front of the current traceback. When an exception handler is " -"entered, the stack trace is made available to the program. (See section " -":ref:`try`.) It is accessible as the third item of the tuple returned by " -"``sys.exc_info()``, and as the ``__traceback__`` attribute of the caught " -"exception." +"entered, the stack trace is made available to the program. (See section :ref:" +"`try`.) It is accessible as the third item of the tuple returned by ``sys." +"exc_info()``, and as the ``__traceback__`` attribute of the caught exception." msgstr "" "Para seguimientos de pila (tracebacks) creados de manera implícita, cuando " "la búsqueda por un manejo de excepciones desenvuelve la pila de ejecución, " "en cada nivel de desenvolvimiento se inserta un objeto de rastreo al frente " "del rastreo actual. Cuando se entra a un manejo de excepción, la pila de " "rastreo se vuelve disponible para el programa. (Ver sección :ref:`try`.) Es " -"accesible como el tercer elemento de la tupla retornada por " -"``sys.exc_info()``, y como el atributo ``__traceback__`` de la excepción " -"capturada." +"accesible como el tercer elemento de la tupla retornada por ``sys." +"exc_info()``, y como el atributo ``__traceback__`` de la excepción capturada." #: ../Doc/reference/datamodel.rst:1139 msgid "" "When the program contains no suitable handler, the stack trace is written " "(nicely formatted) to the standard error stream; if the interpreter is " -"interactive, it is also made available to the user as " -"``sys.last_traceback``." +"interactive, it is also made available to the user as ``sys.last_traceback``." msgstr "" "Cuando el programa no contiene un gestor apropiado, el trazo de pila es " "escrito (muy bien formateado) a la secuencia de error estándar; si el " @@ -2018,8 +2004,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1154 msgid "" -"Special read-only attributes: :attr:`tb_frame` points to the execution frame" -" of the current level; :attr:`tb_lineno` gives the line number where the " +"Special read-only attributes: :attr:`tb_frame` points to the execution frame " +"of the current level; :attr:`tb_lineno` gives the line number where the " "exception occurred; :attr:`tb_lasti` indicates the precise instruction. The " "line number and last instruction in the traceback may differ from the line " "number of its frame object if the exception occurred in a :keyword:`try` " @@ -2029,23 +2015,23 @@ msgstr "" "ejecución del nivel actual; :attr:`tb_lineno` da el número de línea donde " "ocurrió la excepción; :attr:`tb_lasti` indica la instrucción precisa. El " "número de línea y la última instrucción en el seguimiento de pila puede " -"diferir del número de línea de su objeto de marco si la excepción ocurrió en" -" una declaración :keyword:`try` sin una cláusula de excepción (except) " +"diferir del número de línea de su objeto de marco si la excepción ocurrió en " +"una declaración :keyword:`try` sin una cláusula de excepción (except) " "correspondiente o con una cláusula *finally*." #: ../Doc/reference/datamodel.rst:1163 msgid "" -"Accessing ``tb_frame`` raises an :ref:`auditing event ` " -"``object.__getattr__`` with arguments ``obj`` and ``\"tb_frame\"``." +"Accessing ``tb_frame`` raises an :ref:`auditing event ` ``object." +"__getattr__`` with arguments ``obj`` and ``\"tb_frame\"``." msgstr "" -"Acceder a ``tb_frame`` lanza un objeto :ref:`evento de auditoría `" -" ``.__getattr__`` con argumentos ``obj`` y ``tb_frame``." +"Acceder a ``tb_frame`` lanza un objeto :ref:`evento de auditoría ` " +"``.__getattr__`` con argumentos ``obj`` y ``tb_frame``." #: ../Doc/reference/datamodel.rst:1169 msgid "" "Special writable attribute: :attr:`tb_next` is the next level in the stack " -"trace (towards the frame where the exception occurred), or ``None`` if there" -" is no next level." +"trace (towards the frame where the exception occurred), or ``None`` if there " +"is no next level." msgstr "" "Atributo especial escribible: :attr:`tb_next` es el siguiente nivel en el " "trazo de pila (hacia el marco en donde ocurrió la excepción), o ``None`` si " @@ -2069,20 +2055,20 @@ msgid "" "Slice objects are used to represent slices for :meth:`~object.__getitem__` " "methods. They are also created by the built-in :func:`slice` function." msgstr "" -"Los objetos de sector se utilizan para representar sectores para métodos " -":meth:`~object.__getitem__`. También son creados por la función integrada " -":func:`slice`." +"Los objetos de sector se utilizan para representar sectores para métodos :" +"meth:`~object.__getitem__`. También son creados por la función integrada :" +"func:`slice`." #: ../Doc/reference/datamodel.rst:1189 msgid "" -"Special read-only attributes: :attr:`~slice.start` is the lower bound; " -":attr:`~slice.stop` is the upper bound; :attr:`~slice.step` is the step " -"value; each is ``None`` if omitted. These attributes can have any type." +"Special read-only attributes: :attr:`~slice.start` is the lower bound; :attr:" +"`~slice.stop` is the upper bound; :attr:`~slice.step` is the step value; " +"each is ``None`` if omitted. These attributes can have any type." msgstr "" "Atributos especiales de solo lectura: :attr:`~slice.start` es el límite " "inferior; :attr:`~slice.stop` es el límite superior; :attr:`~slice.step` es " -"el valor de paso; cada uno es ``None`` si es omitido. Estos atributos pueden" -" ser de cualquier tipo." +"el valor de paso; cada uno es ``None`` si es omitido. Estos atributos pueden " +"ser de cualquier tipo." #: ../Doc/reference/datamodel.rst:1193 msgid "Slice objects support one method:" @@ -2118,15 +2104,15 @@ msgid "" "any further transformation. Static method objects are also callable. Static " "method objects are created by the built-in :func:`staticmethod` constructor." msgstr "" -"Los objetos de método estático proveen una forma de anular la transformación" -" de objetos de función a objetos de método descritos anteriormente. Un " -"objeto de método estático es una envoltura (*wrapper*) alrededor de " -"cualquier otro objeto, usualmente un objeto de método definido por usuario. " -"Cuando un objeto de método estático es obtenido desde una clase o una " -"instancia de clase, usualmente el objeto retornado es el objeto envuelto, el" -" cual no está objeto a ninguna transformación adicional. Los objetos de " -"método estático también pueden ser llamados. Los objetos de método estático " -"son creados por el constructor incorporado :func:`staticmethod`." +"Los objetos de método estático proveen una forma de anular la transformación " +"de objetos de función a objetos de método descritos anteriormente. Un objeto " +"de método estático es una envoltura (*wrapper*) alrededor de cualquier otro " +"objeto, usualmente un objeto de método definido por usuario. Cuando un " +"objeto de método estático es obtenido desde una clase o una instancia de " +"clase, usualmente el objeto retornado es el objeto envuelto, el cual no está " +"objeto a ninguna transformación adicional. Los objetos de método estático " +"también pueden ser llamados. Los objetos de método estático son creados por " +"el constructor incorporado :func:`staticmethod`." #: ../Doc/reference/datamodel.rst:1219 msgid "Class method objects" @@ -2136,8 +2122,8 @@ msgstr "Objetos de método de clase" msgid "" "A class method object, like a static method object, is a wrapper around " "another object that alters the way in which that object is retrieved from " -"classes and class instances. The behaviour of class method objects upon such" -" retrieval is described above, under \"User-defined methods\". Class method " +"classes and class instances. The behaviour of class method objects upon such " +"retrieval is described above, under \"User-defined methods\". Class method " "objects are created by the built-in :func:`classmethod` constructor." msgstr "" "Un objeto de método de clase, igual que un objeto de método estático, es un " @@ -2145,8 +2131,8 @@ msgstr "" "el objeto es obtenido desde las clases y las instancias de clase. El " "comportamiento de los objetos de método de clase sobre tal obtención es " "descrita más arriba, debajo de “Métodos definidos por usuario”. Objetos de " -"clase de método son creados por el constructor incorporado " -":func:`classmethod`." +"clase de método son creados por el constructor incorporado :func:" +"`classmethod`." #: ../Doc/reference/datamodel.rst:1224 msgid "Special method names" @@ -2158,46 +2144,46 @@ msgid "" "(such as arithmetic operations or subscripting and slicing) by defining " "methods with special names. This is Python's approach to :dfn:`operator " "overloading`, allowing classes to define their own behavior with respect to " -"language operators. For instance, if a class defines a method named " -":meth:`~object.__getitem__`, and ``x`` is an instance of this class, then " -"``x[i]`` is roughly equivalent to ``type(x).__getitem__(x, i)``. Except " -"where mentioned, attempts to execute an operation raise an exception when no" -" appropriate method is defined (typically :exc:`AttributeError` or " -":exc:`TypeError`)." +"language operators. For instance, if a class defines a method named :meth:" +"`~object.__getitem__`, and ``x`` is an instance of this class, then ``x[i]`` " +"is roughly equivalent to ``type(x).__getitem__(x, i)``. Except where " +"mentioned, attempts to execute an operation raise an exception when no " +"appropriate method is defined (typically :exc:`AttributeError` or :exc:" +"`TypeError`)." msgstr "" "Una clase puede implementar ciertas operaciones que son invocadas por una " "sintaxis especial (como operaciones aritméticas o subíndices y cortes) " -"definiendo métodos con nombres especiales. Este es el enfoque de Python para" -" :dfn:`sobrecarga de operadores`, que permite que las clases definan su " +"definiendo métodos con nombres especiales. Este es el enfoque de Python " +"para :dfn:`sobrecarga de operadores`, que permite que las clases definan su " "propio comportamiento con respecto a los operadores de lenguaje. Por " -"ejemplo, si una clase define un método llamado :meth:`~object.__getitem__` y" -" ``x`` es una instancia de esta clase, entonces ``x[i]`` es aproximadamente " +"ejemplo, si una clase define un método llamado :meth:`~object.__getitem__` y " +"``x`` es una instancia de esta clase, entonces ``x[i]`` es aproximadamente " "equivalente a ``type(x).__getitem__(x, i)``. Excepto donde se mencione, los " -"intentos de ejecutar una operación generan una excepción cuando no se define" -" un método apropiado (normalmente :exc:`AttributeError` o :exc:`TypeError`)." +"intentos de ejecutar una operación generan una excepción cuando no se define " +"un método apropiado (normalmente :exc:`AttributeError` o :exc:`TypeError`)." #: ../Doc/reference/datamodel.rst:1241 msgid "" "Setting a special method to ``None`` indicates that the corresponding " -"operation is not available. For example, if a class sets " -":meth:`~object.__iter__` to ``None``, the class is not iterable, so calling " -":func:`iter` on its instances will raise a :exc:`TypeError` (without falling" -" back to :meth:`~object.__getitem__`). [#]_" +"operation is not available. For example, if a class sets :meth:`~object." +"__iter__` to ``None``, the class is not iterable, so calling :func:`iter` on " +"its instances will raise a :exc:`TypeError` (without falling back to :meth:" +"`~object.__getitem__`). [#]_" msgstr "" "Establecer un método especial en ``None`` indica que la operación " -"correspondiente no está disponible. Por ejemplo, si una clase establece " -":meth:`~object.__iter__` en ``None``, la clase no es iterable, por lo que " +"correspondiente no está disponible. Por ejemplo, si una clase establece :" +"meth:`~object.__iter__` en ``None``, la clase no es iterable, por lo que " "llamar a :func:`iter` en sus instancias generará un :exc:`TypeError` (sin " "retroceder a :meth:`~object.__getitem__`). [#]_" #: ../Doc/reference/datamodel.rst:1247 msgid "" "When implementing a class that emulates any built-in type, it is important " -"that the emulation only be implemented to the degree that it makes sense for" -" the object being modelled. For example, some sequences may work well with " -"retrieval of individual elements, but extracting a slice may not make sense." -" (One example of this is the :class:`~xml.dom.NodeList` interface in the " -"W3C's Document Object Model.)" +"that the emulation only be implemented to the degree that it makes sense for " +"the object being modelled. For example, some sequences may work well with " +"retrieval of individual elements, but extracting a slice may not make " +"sense. (One example of this is the :class:`~xml.dom.NodeList` interface in " +"the W3C's Document Object Model.)" msgstr "" "Cuando se implementa una clase que emula cualquier tipo incorporado, es " "importante que la emulación solo sea implementado al grado que hace sentido " @@ -2213,15 +2199,15 @@ msgstr "Personalización básica" #: ../Doc/reference/datamodel.rst:1264 msgid "" -"Called to create a new instance of class *cls*. :meth:`__new__` is a static" -" method (special-cased so you need not declare it as such) that takes the " +"Called to create a new instance of class *cls*. :meth:`__new__` is a static " +"method (special-cased so you need not declare it as such) that takes the " "class of which an instance was requested as its first argument. The " "remaining arguments are those passed to the object constructor expression " "(the call to the class). The return value of :meth:`__new__` should be the " "new object instance (usually an instance of *cls*)." msgstr "" -"Es llamado para crear una nueva instancia de clase *cls*. :meth:`__new__` es" -" un método estático (como un caso especial, así que no se necesita declarar " +"Es llamado para crear una nueva instancia de clase *cls*. :meth:`__new__` es " +"un método estático (como un caso especial, así que no se necesita declarar " "como tal) que toma la clase de donde fue solicitada una instancia como su " "primer argumento. Los argumentos restantes son aquellos que se pasan a la " "expresión del constructor de objetos (para llamar a la clase). El valor " @@ -2235,24 +2221,24 @@ msgid "" "with appropriate arguments and then modifying the newly created instance as " "necessary before returning it." msgstr "" -"Las implementaciones típicas crean una nueva instancia de la clase invocando" -" el método :meth:`__new__` de la superclase usando ``super().__new__(cls[, " -"...])`` con los argumentos apropiados y luego modificando la instancia " -"recién creada según sea necesario antes de devolverla." +"Las implementaciones típicas crean una nueva instancia de la clase invocando " +"el método :meth:`__new__` de la superclase usando ``super()." +"__new__(cls[, ...])`` con los argumentos apropiados y luego modificando la " +"instancia recién creada según sea necesario antes de devolverla." #: ../Doc/reference/datamodel.rst:1276 msgid "" "If :meth:`__new__` is invoked during object construction and it returns an " "instance of *cls*, then the new instance’s :meth:`__init__` method will be " -"invoked like ``__init__(self[, ...])``, where *self* is the new instance and" -" the remaining arguments are the same as were passed to the object " +"invoked like ``__init__(self[, ...])``, where *self* is the new instance and " +"the remaining arguments are the same as were passed to the object " "constructor." msgstr "" "Si :meth:`__new__` es invocado durante la construcción del objeto y éste " -"retorna una instancia de *cls*, entonces el nuevo método :meth:`__init__` de" -" la instancia será invocado como ``__init__(self[, …])``, donde *self* es la" -" nueva instancia y los argumentos restantes son iguales a como fueron " -"pasados hacia el constructor de objetos." +"retorna una instancia de *cls*, entonces el nuevo método :meth:`__init__` de " +"la instancia será invocado como ``__init__(self[, …])``, donde *self* es la " +"nueva instancia y los argumentos restantes son iguales a como fueron pasados " +"hacia el constructor de objetos." #: ../Doc/reference/datamodel.rst:1281 msgid "" @@ -2278,9 +2264,9 @@ msgstr "" msgid "" "Called after the instance has been created (by :meth:`__new__`), but before " "it is returned to the caller. The arguments are those passed to the class " -"constructor expression. If a base class has an :meth:`__init__` method, the" -" derived class's :meth:`__init__` method, if any, must explicitly call it to" -" ensure proper initialization of the base class part of the instance; for " +"constructor expression. If a base class has an :meth:`__init__` method, the " +"derived class's :meth:`__init__` method, if any, must explicitly call it to " +"ensure proper initialization of the base class part of the instance; for " "example: ``super().__init__([args...])``." msgstr "" "Llamado después de que la instancia ha sido creada (por :meth:`__new__`), " @@ -2298,23 +2284,23 @@ msgid "" "it), no non-``None`` value may be returned by :meth:`__init__`; doing so " "will cause a :exc:`TypeError` to be raised at runtime." msgstr "" -"Debido a que :meth:`__new__` y :meth:`__init__` trabajan juntos construyendo" -" objetos (:meth:`__new__` para crearlo y :meth:`__init__` para " -"personalizarlo), ningún valor distinto a ``None`` puede ser retornado por " -":meth:`__init__`; hacer esto puede causar que se lance una excepción " -":exc:`TypeError` en tiempo de ejecución." +"Debido a que :meth:`__new__` y :meth:`__init__` trabajan juntos construyendo " +"objetos (:meth:`__new__` para crearlo y :meth:`__init__` para " +"personalizarlo), ningún valor distinto a ``None`` puede ser retornado por :" +"meth:`__init__`; hacer esto puede causar que se lance una excepción :exc:" +"`TypeError` en tiempo de ejecución." #: ../Doc/reference/datamodel.rst:1313 msgid "" "Called when the instance is about to be destroyed. This is also called a " -"finalizer or (improperly) a destructor. If a base class has a " -":meth:`__del__` method, the derived class's :meth:`__del__` method, if any, " -"must explicitly call it to ensure proper deletion of the base class part of " -"the instance." +"finalizer or (improperly) a destructor. If a base class has a :meth:" +"`__del__` method, the derived class's :meth:`__del__` method, if any, must " +"explicitly call it to ensure proper deletion of the base class part of the " +"instance." msgstr "" "Llamado cuando la instancia es a punto de ser destruida. Esto también es " -"llamado finalizador o (indebidamente) destructor. Si una clase base tiene un" -" método :meth:`__del__` el método :meth:`__del__` de la clase derivada, de " +"llamado finalizador o (indebidamente) destructor. Si una clase base tiene un " +"método :meth:`__del__` el método :meth:`__del__` de la clase derivada, de " "existir, debe llamarlo explícitamente para asegurar la eliminación adecuada " "de la parte de la clase base de la instancia." @@ -2323,9 +2309,9 @@ msgid "" "It is possible (though not recommended!) for the :meth:`__del__` method to " "postpone destruction of the instance by creating a new reference to it. " "This is called object *resurrection*. It is implementation-dependent " -"whether :meth:`__del__` is called a second time when a resurrected object is" -" about to be destroyed; the current :term:`CPython` implementation only " -"calls it once." +"whether :meth:`__del__` is called a second time when a resurrected object is " +"about to be destroyed; the current :term:`CPython` implementation only calls " +"it once." msgstr "" "Es posible (¡aunque no recomendable!) para el método :meth:`__del__` " "posponer la destrucción de la instancia al crear una nueva referencia hacia " @@ -2356,14 +2342,14 @@ msgstr "" msgid "" "It is possible for a reference cycle to prevent the reference count of an " "object from going to zero. In this case, the cycle will be later detected " -"and deleted by the :term:`cyclic garbage collector `. A" -" common cause of reference cycles is when an exception has been caught in a " +"and deleted by the :term:`cyclic garbage collector `. A " +"common cause of reference cycles is when an exception has been caught in a " "local variable. The frame's locals then reference the exception, which " "references its own traceback, which references the locals of all frames " "caught in the traceback." msgstr "" -"Es posible que un ciclo de referencia evite que el recuento de referencia de" -" un objeto llegue a cero. En este caso, el ciclo será posteriormente " +"Es posible que un ciclo de referencia evite que el recuento de referencia de " +"un objeto llegue a cero. En este caso, el ciclo será posteriormente " "detectado y eliminado por el :term:`cyclic garbage collector `. Una causa común de los ciclos de referencia es cuando se " "detecta una excepción en una variable local. Luego, los locales del marco " @@ -2381,40 +2367,40 @@ msgid "" "invoked, exceptions that occur during their execution are ignored, and a " "warning is printed to ``sys.stderr`` instead. In particular:" msgstr "" -"Debido a las circunstancias inciertas bajo las que los métodos " -":meth:`__del__` son invocados, las excepciones que ocurren durante su " -"ejecución son ignoradas, y una advertencia es mostrada hacia ``sys.stderr``." -" En particular:" +"Debido a las circunstancias inciertas bajo las que los métodos :meth:" +"`__del__` son invocados, las excepciones que ocurren durante su ejecución " +"son ignoradas, y una advertencia es mostrada hacia ``sys.stderr``. En " +"particular:" #: ../Doc/reference/datamodel.rst:1354 msgid "" ":meth:`__del__` can be invoked when arbitrary code is being executed, " "including from any arbitrary thread. If :meth:`__del__` needs to take a " "lock or invoke any other blocking resource, it may deadlock as the resource " -"may already be taken by the code that gets interrupted to execute " -":meth:`__del__`." +"may already be taken by the code that gets interrupted to execute :meth:" +"`__del__`." msgstr "" ":meth:`__del__` puede ser invocado cuando código arbitrario es ejecutado, " "incluyendo el de cualquier hilo arbitrario. Si :meth:`__del__` necesita " "realizar un cierre de exclusión mutua (*lock*) o invocar cualquier otro " -"recurso que lo esté bloqueando, podría provocar un bloqueo muto (*deadlock*)" -" ya que el recurso podría estar siendo utilizado por el código que se " +"recurso que lo esté bloqueando, podría provocar un bloqueo muto (*deadlock*) " +"ya que el recurso podría estar siendo utilizado por el código que se " "interrumpe al ejecutar :meth:`__del__`." #: ../Doc/reference/datamodel.rst:1360 msgid "" ":meth:`__del__` can be executed during interpreter shutdown. As a " "consequence, the global variables it needs to access (including other " -"modules) may already have been deleted or set to ``None``. Python guarantees" -" that globals whose name begins with a single underscore are deleted from " +"modules) may already have been deleted or set to ``None``. Python guarantees " +"that globals whose name begins with a single underscore are deleted from " "their module before other globals are deleted; if no other references to " "such globals exist, this may help in assuring that imported modules are " "still available at the time when the :meth:`__del__` method is called." msgstr "" ":meth:`__del__` puede ser ejecutado durante el cierre del intérprete. Como " "consecuencia, las variables globales que necesita para acceder (incluyendo " -"otros módulos) podrían haber sido borradas o establecidas a ``None``. Python" -" garantiza que los globales cuyo nombre comienza con un guión bajo simple " +"otros módulos) podrían haber sido borradas o establecidas a ``None``. Python " +"garantiza que los globales cuyo nombre comienza con un guión bajo simple " "sean borrados de su módulo antes que los globales sean borrados; si no " "existen otras referencias a dichas globales, esto puede ayudar asegurando " "que los módulos importados aún se encuentren disponibles al momento de " @@ -2424,19 +2410,18 @@ msgstr "" msgid "" "Called by the :func:`repr` built-in function to compute the \"official\" " "string representation of an object. If at all possible, this should look " -"like a valid Python expression that could be used to recreate an object with" -" the same value (given an appropriate environment). If this is not " -"possible, a string of the form ``<...some useful description...>`` should be" -" returned. The return value must be a string object. If a class defines " -":meth:`__repr__` but not :meth:`__str__`, then :meth:`__repr__` is also used" -" when an \"informal\" string representation of instances of that class is " -"required." +"like a valid Python expression that could be used to recreate an object with " +"the same value (given an appropriate environment). If this is not possible, " +"a string of the form ``<...some useful description...>`` should be returned. " +"The return value must be a string object. If a class defines :meth:" +"`__repr__` but not :meth:`__str__`, then :meth:`__repr__` is also used when " +"an \"informal\" string representation of instances of that class is required." msgstr "" "Llamado por la función incorporada :func:`repr` para calcular la cadena " "“oficial” de representación de un objeto. Si es posible, esto debería verse " "como una expresión de Python válida que puede ser utilizada para recrear un " -"objeto con el mismo valor (bajo el ambiente adecuado). Si no es posible, una" -" cadena con la forma ``<…some useful description…>`` debe ser retornada. El " +"objeto con el mismo valor (bajo el ambiente adecuado). Si no es posible, una " +"cadena con la forma ``<…some useful description…>`` debe ser retornada. El " "valor de retorno debe ser un objeto de cadena (*string*). Si una clase " "define :meth:`__repr__` pero no :meth:`__str__`, entonces :meth:`__repr__` " "también es utilizado cuando una cadena “informal” de representación de " @@ -2452,15 +2437,15 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1395 msgid "" -"Called by :func:`str(object) ` and the built-in functions " -":func:`format` and :func:`print` to compute the \"informal\" or nicely " -"printable string representation of an object. The return value must be a " -":ref:`string ` object." +"Called by :func:`str(object) ` and the built-in functions :func:" +"`format` and :func:`print` to compute the \"informal\" or nicely printable " +"string representation of an object. The return value must be a :ref:`string " +"` object." msgstr "" -"Llamado por :func:`str(object) ` y las funciones incorporadas " -":func:`format` y :func:`print` para calcular la “informal” o bien mostrada " -"cadena de representación de un objeto. El valor de retorno debe ser un " -"objeto :ref:`string `." +"Llamado por :func:`str(object) ` y las funciones incorporadas :func:" +"`format` y :func:`print` para calcular la “informal” o bien mostrada cadena " +"de representación de un objeto. El valor de retorno debe ser un objeto :ref:" +"`string `." #: ../Doc/reference/datamodel.rst:1400 msgid "" @@ -2468,8 +2453,8 @@ msgid "" "expectation that :meth:`__str__` return a valid Python expression: a more " "convenient or concise representation can be used." msgstr "" -"Este método difiere de :meth:`object.__repr__` en que no hay expectativas de" -" que :meth:`__str__` retorne una expresión de Python válida: una " +"Este método difiere de :meth:`object.__repr__` en que no hay expectativas de " +"que :meth:`__str__` retorne una expresión de Python válida: una " "representación más conveniente o concisa pueda ser utilizada." #: ../Doc/reference/datamodel.rst:1404 @@ -2477,8 +2462,8 @@ msgid "" "The default implementation defined by the built-in type :class:`object` " "calls :meth:`object.__repr__`." msgstr "" -"La implementación por defecto definida por el tipo incorporado " -":class:`object` llama a :meth:`object.__repr__`." +"La implementación por defecto definida por el tipo incorporado :class:" +"`object` llama a :meth:`object.__repr__`." #: ../Doc/reference/datamodel.rst:1414 msgid "" @@ -2490,24 +2475,23 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1425 msgid "" -"Called by the :func:`format` built-in function, and by extension, evaluation" -" of :ref:`formatted string literals ` and the :meth:`str.format` " +"Called by the :func:`format` built-in function, and by extension, evaluation " +"of :ref:`formatted string literals ` and the :meth:`str.format` " "method, to produce a \"formatted\" string representation of an object. The " "*format_spec* argument is a string that contains a description of the " -"formatting options desired. The interpretation of the *format_spec* argument" -" is up to the type implementing :meth:`__format__`, however most classes " -"will either delegate formatting to one of the built-in types, or use a " -"similar formatting option syntax." +"formatting options desired. The interpretation of the *format_spec* argument " +"is up to the type implementing :meth:`__format__`, however most classes will " +"either delegate formatting to one of the built-in types, or use a similar " +"formatting option syntax." msgstr "" "Llamado por la función incorporada :func:`format`, y por extensión, la " -"evaluación de :ref:`formatted string literals ` y el método " -":meth:`str.format`, para producir la representación “formateada” de un " -"objeto. El argumento *format_spec* es una cadena que contiene una " -"descripción de las opciones de formato deseadas. La interpretación del " -"argumento *format_spec* depende del tipo que implementa :meth:`__format__`, " -"sin embargo, ya sea que la mayoría de las clases deleguen el formato a uno " -"de los tipos incorporados, o utilicen una sintaxis de opción de formato " -"similar." +"evaluación de :ref:`formatted string literals ` y el método :meth:" +"`str.format`, para producir la representación “formateada” de un objeto. El " +"argumento *format_spec* es una cadena que contiene una descripción de las " +"opciones de formato deseadas. La interpretación del argumento *format_spec* " +"depende del tipo que implementa :meth:`__format__`, sin embargo, ya sea que " +"la mayoría de las clases deleguen el formato a uno de los tipos " +"incorporados, o utilicen una sintaxis de opción de formato similar." #: ../Doc/reference/datamodel.rst:1435 msgid "" @@ -2525,8 +2509,8 @@ msgid "" "The __format__ method of ``object`` itself raises a :exc:`TypeError` if " "passed any non-empty string." msgstr "" -"El método __format__ del mismo ``object`` lanza un :exc:`TypeError` si se la" -" pasa una cadena no vacía." +"El método __format__ del mismo ``object`` lanza un :exc:`TypeError` si se la " +"pasa una cadena no vacía." #: ../Doc/reference/datamodel.rst:1443 msgid "" @@ -2539,10 +2523,10 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1459 msgid "" "These are the so-called \"rich comparison\" methods. The correspondence " -"between operator symbols and method names is as follows: ``xy`` calls " -"``x.__gt__(y)``, and ``x>=y`` calls ``x.__ge__(y)``." +"between operator symbols and method names is as follows: ``xy`` calls ``x.__gt__(y)``, and ``x>=y`` " +"calls ``x.__ge__(y)``." msgstr "" "Estos son los llamados métodos de comparación *rich*. La correspondencia " "entre símbolos de operador y los nombres de método es de la siguiente " @@ -2554,8 +2538,8 @@ msgstr "" msgid "" "A rich comparison method may return the singleton ``NotImplemented`` if it " "does not implement the operation for a given pair of arguments. By " -"convention, ``False`` and ``True`` are returned for a successful comparison." -" However, these methods can return any value, so if the comparison operator " +"convention, ``False`` and ``True`` are returned for a successful comparison. " +"However, these methods can return any value, so if the comparison operator " "is used in a Boolean context (e.g., in the condition of an ``if`` " "statement), Python will call :func:`bool` on the value to determine if the " "result is true or false." @@ -2563,8 +2547,8 @@ msgstr "" "Un método de comparación *rich* puede retornar el único ``NotImplemented`` " "si no implementa la operación para un par de argumentos dados. Por " "convención, ``False`` y ``True`` son retornados para una comparación " -"exitosa. Sin embargo, estos métodos pueden retornar cualquier valor, así que" -" si el operador de comparación es utilizado en un contexto Booleano (p. ej. " +"exitosa. Sin embargo, estos métodos pueden retornar cualquier valor, así que " +"si el operador de comparación es utilizado en un contexto Booleano (p. ej. " "en la condición de una sentencia ``if``), Python llamará :func:`bool` en " "dicho valor para determinar si el resultado es verdadero (*true*) o falso " "(*false*)." @@ -2573,106 +2557,105 @@ msgstr "" msgid "" "By default, ``object`` implements :meth:`__eq__` by using ``is``, returning " "``NotImplemented`` in the case of a false comparison: ``True if x is y else " -"NotImplemented``. For :meth:`__ne__`, by default it delegates to " -":meth:`__eq__` and inverts the result unless it is ``NotImplemented``. " -"There are no other implied relationships among the comparison operators or " -"default implementations; for example, the truth of ``(x` y :func:`@classmethod `) se implementan como " "descriptores que no son de datos. En consecuencia, las instancias pueden " "redefinir y anular métodos. Esto permite que instancias individuales " -"adquieran comportamientos que difieren de otras instancias de la misma " -"clase." +"adquieran comportamientos que difieren de otras instancias de la misma clase." #: ../Doc/reference/datamodel.rst:1882 msgid "" "The :func:`property` function is implemented as a data descriptor. " "Accordingly, instances cannot override the behavior of a property." msgstr "" -"La función :func:`property` es implementada como un descriptor de datos. Por" -" lo tanto, las instancias no pueden anular el comportamiento de una " -"propiedad." +"La función :func:`property` es implementada como un descriptor de datos. Por " +"lo tanto, las instancias no pueden anular el comportamiento de una propiedad." #: ../Doc/reference/datamodel.rst:1889 msgid "__slots__" @@ -3334,12 +3310,12 @@ msgstr "" msgid "" "This class variable can be assigned a string, iterable, or sequence of " "strings with variable names used by instances. *__slots__* reserves space " -"for the declared variables and prevents the automatic creation of " -":attr:`~object.__dict__` and *__weakref__* for each instance." +"for the declared variables and prevents the automatic creation of :attr:" +"`~object.__dict__` and *__weakref__* for each instance." msgstr "" "A esta variable de clase se le puede asignar una cadena, iterable o una " -"secuencia de cadenas con nombres de variables utilizados por las instancias." -" *__slots__* reserva espacio para las variables declaradas y evita la " +"secuencia de cadenas con nombres de variables utilizados por las instancias. " +"*__slots__* reserva espacio para las variables declaradas y evita la " "creación automática de :attr:`~object.__dict__` y *__weakref__* para cada " "instancia." @@ -3349,9 +3325,9 @@ msgstr "Notas sobre el uso de *__slots__*" #: ../Doc/reference/datamodel.rst:1910 msgid "" -"When inheriting from a class without *__slots__*, the " -":attr:`~object.__dict__` and *__weakref__* attribute of the instances will " -"always be accessible." +"When inheriting from a class without *__slots__*, the :attr:`~object." +"__dict__` and *__weakref__* attribute of the instances will always be " +"accessible." msgstr "" "Al heredar de una clase sin *__slots__*, siempre se podrá acceder al " "atributo :attr:`~object.__dict__` y *__weakref__* de las instancias." @@ -3385,11 +3361,10 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1927 msgid "" -"*__slots__* are implemented at the class level by creating :ref:`descriptors" -" ` for each variable name. As a result, class attributes " -"cannot be used to set default values for instance variables defined by " -"*__slots__*; otherwise, the class attribute would overwrite the descriptor " -"assignment." +"*__slots__* are implemented at the class level by creating :ref:`descriptors " +"` for each variable name. As a result, class attributes cannot " +"be used to set default values for instance variables defined by *__slots__*; " +"otherwise, the class attribute would overwrite the descriptor assignment." msgstr "" "*__slots__* se implementan a nivel de clase creando :ref:`descriptors " "` para cada nombre de variable. Como resultado, los atributos " @@ -3399,18 +3374,17 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1933 msgid "" -"The action of a *__slots__* declaration is not limited to the class where it" -" is defined. *__slots__* declared in parents are available in child " -"classes. However, child subclasses will get a :attr:`~object.__dict__` and " -"*__weakref__* unless they also define *__slots__* (which should only contain" -" names of any *additional* slots)." +"The action of a *__slots__* declaration is not limited to the class where it " +"is defined. *__slots__* declared in parents are available in child classes. " +"However, child subclasses will get a :attr:`~object.__dict__` and " +"*__weakref__* unless they also define *__slots__* (which should only contain " +"names of any *additional* slots)." msgstr "" "La acción de una declaración *__slots__* no se limita a la clase donde se " "define. *__slots__* declarado en padres está disponible en clases " -"secundarias. Sin embargo, las subclases secundarias obtendrán " -":attr:`~object.__dict__` y *__weakref__* a menos que también definan " -"*__slots__* (que solo debe contener nombres de cualquier ranura " -"*additional*)." +"secundarias. Sin embargo, las subclases secundarias obtendrán :attr:`~object." +"__dict__` y *__weakref__* a menos que también definan *__slots__* (que solo " +"debe contener nombres de cualquier ranura *additional*)." #: ../Doc/reference/datamodel.rst:1939 msgid "" @@ -3429,12 +3403,12 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1944 msgid "" "Nonempty *__slots__* does not work for classes derived from \"variable-" -"length\" built-in types such as :class:`int`, :class:`bytes` and " -":class:`tuple`." +"length\" built-in types such as :class:`int`, :class:`bytes` and :class:" +"`tuple`." msgstr "" "*__slots__* no vacíos no funcionan para clases derivadas de tipos " -"incorporados de “longitud variable” como :class:`int`, :class:`bytes` y " -":class:`tuple`." +"incorporados de “longitud variable” como :class:`int`, :class:`bytes` y :" +"class:`tuple`." #: ../Doc/reference/datamodel.rst:1947 msgid "Any non-string :term:`iterable` may be assigned to *__slots__*." @@ -3445,15 +3419,15 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1949 msgid "" "If a :class:`dictionary ` is used to assign *__slots__*, the " -"dictionary keys will be used as the slot names. The values of the dictionary" -" can be used to provide per-attribute docstrings that will be recognised by " -":func:`inspect.getdoc` and displayed in the output of :func:`help`." +"dictionary keys will be used as the slot names. The values of the dictionary " +"can be used to provide per-attribute docstrings that will be recognised by :" +"func:`inspect.getdoc` and displayed in the output of :func:`help`." msgstr "" "Si se utiliza un :class:`dictionary ` para asignar *__slots__*, las " -"claves del diccionario se utilizarán como nombres de ranura. Los valores del" -" diccionario se pueden usar para proporcionar cadenas de documentos por " -"atributo que :func:`inspect.getdoc` reconocerá y mostrará en la salida de " -":func:`help`." +"claves del diccionario se utilizarán como nombres de ranura. Los valores del " +"diccionario se pueden usar para proporcionar cadenas de documentos por " +"atributo que :func:`inspect.getdoc` reconocerá y mostrará en la salida de :" +"func:`help`." #: ../Doc/reference/datamodel.rst:1954 msgid "" @@ -3467,13 +3441,13 @@ msgstr "" msgid "" ":ref:`Multiple inheritance ` with multiple slotted parent " "classes can be used, but only one parent is allowed to have attributes " -"created by slots (the other bases must have empty slot layouts) - violations" -" raise :exc:`TypeError`." +"created by slots (the other bases must have empty slot layouts) - violations " +"raise :exc:`TypeError`." msgstr "" "Se puede usar :ref:`Multiple inheritance ` con varias clases " "principales con ranuras, pero solo una principal puede tener atributos " -"creados por ranuras (las otras bases deben tener diseños de ranuras vacías);" -" las infracciones generan :exc:`TypeError`." +"creados por ranuras (las otras bases deben tener diseños de ranuras vacías); " +"las infracciones generan :exc:`TypeError`." #: ../Doc/reference/datamodel.rst:1963 msgid "" @@ -3481,9 +3455,9 @@ msgid "" "created for each of the iterator's values. However, the *__slots__* " "attribute will be an empty iterator." msgstr "" -"Si se utiliza un :term:`iterator` para *__slots__*, se crea un " -":term:`descriptor` para cada uno de los valores del iterador. Sin embargo, " -"el atributo *__slots__* será un iterador vacío." +"Si se utiliza un :term:`iterator` para *__slots__*, se crea un :term:" +"`descriptor` para cada uno de los valores del iterador. Sin embargo, el " +"atributo *__slots__* será un iterador vacío." #: ../Doc/reference/datamodel.rst:1971 msgid "Customizing class creation" @@ -3491,18 +3465,18 @@ msgstr "Personalización de creación de clases" #: ../Doc/reference/datamodel.rst:1973 msgid "" -"Whenever a class inherits from another class, " -":meth:`~object.__init_subclass__` is called on the parent class. This way, " -"it is possible to write classes which change the behavior of subclasses. " -"This is closely related to class decorators, but where class decorators only" -" affect the specific class they're applied to, ``__init_subclass__`` solely " -"applies to future subclasses of the class defining the method." -msgstr "" -"Cada vez que una clase hereda de otra clase, se llama a " -":meth:`~object.__init_subclass__` en la clase principal. De esta forma, es " -"posible escribir clases que cambien el comportamiento de las subclases. Esto" -" está estrechamente relacionado con los decoradores de clases, pero donde " -"los decoradores de clases solo afectan a la clase específica a la que se " +"Whenever a class inherits from another class, :meth:`~object." +"__init_subclass__` is called on the parent class. This way, it is possible " +"to write classes which change the behavior of subclasses. This is closely " +"related to class decorators, but where class decorators only affect the " +"specific class they're applied to, ``__init_subclass__`` solely applies to " +"future subclasses of the class defining the method." +msgstr "" +"Cada vez que una clase hereda de otra clase, se llama a :meth:`~object." +"__init_subclass__` en la clase principal. De esta forma, es posible escribir " +"clases que cambien el comportamiento de las subclases. Esto está " +"estrechamente relacionado con los decoradores de clases, pero donde los " +"decoradores de clases solo afectan a la clase específica a la que se " "aplican, ``__init_subclass__`` solo se aplica a las subclases futuras de la " "clase que define el método." @@ -3541,8 +3515,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2005 msgid "" "The metaclass hint ``metaclass`` is consumed by the rest of the type " -"machinery, and is never passed to ``__init_subclass__`` implementations. The" -" actual metaclass (rather than the explicit hint) can be accessed as " +"machinery, and is never passed to ``__init_subclass__`` implementations. The " +"actual metaclass (rather than the explicit hint) can be accessed as " "``type(cls)``." msgstr "" "La sugerencia de metaclase ``metaclass`` es consumido por el resto de la " @@ -3556,8 +3530,8 @@ msgid "" "makes callbacks to those with a :meth:`~object.__set_name__` hook." msgstr "" "Cuando se crea una clase, :meth:`type.__new__` escanea las variables de " -"clase y realiza devoluciones de llamada a aquellas con un gancho " -":meth:`~object.__set_name__`." +"clase y realiza devoluciones de llamada a aquellas con un gancho :meth:" +"`~object.__set_name__`." #: ../Doc/reference/datamodel.rst:2018 msgid "" @@ -3569,13 +3543,13 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2024 msgid "" -"If the class variable is assigned after the class is created, " -":meth:`__set_name__` will not be called automatically. If needed, " -":meth:`__set_name__` can be called directly::" +"If the class variable is assigned after the class is created, :meth:" +"`__set_name__` will not be called automatically. If needed, :meth:" +"`__set_name__` can be called directly::" msgstr "" -"Si la variable de clase se asigna después de crear la clase, " -":meth:`__set_name__` no se llamará automáticamente. Si es necesario, " -":meth:`__set_name__` se puede llamar directamente::" +"Si la variable de clase se asigna después de crear la clase, :meth:" +"`__set_name__` no se llamará automáticamente. Si es necesario, :meth:" +"`__set_name__` se puede llamar directamente::" #: ../Doc/reference/datamodel.rst:2035 msgid "See :ref:`class-object-creation` for more details." @@ -3591,9 +3565,9 @@ msgid "" "executed in a new namespace and the class name is bound locally to the " "result of ``type(name, bases, namespace)``." msgstr "" -"Por defecto, las clases son construidas usando :func:`type`. El cuerpo de la" -" clase es ejecutado en un nuevo espacio de nombres y el nombre de la clase " -"es ligado de forma local al resultado de ``type(name, bases, namespace)``." +"Por defecto, las clases son construidas usando :func:`type`. El cuerpo de la " +"clase es ejecutado en un nuevo espacio de nombres y el nombre de la clase es " +"ligado de forma local al resultado de ``type(name, bases, namespace)``." #: ../Doc/reference/datamodel.rst:2054 msgid "" @@ -3602,8 +3576,8 @@ msgid "" "existing class that included such an argument. In the following example, " "both ``MyClass`` and ``MySubclass`` are instances of ``Meta``::" msgstr "" -"El proceso de creación de clase puede ser personalizado pasando el argumento" -" de palabra clave ``metaclass`` en la línea de definición de la clase, o al " +"El proceso de creación de clase puede ser personalizado pasando el argumento " +"de palabra clave ``metaclass`` en la línea de definición de la clase, o al " "heredar de una clase existente que incluya dicho argumento. En el siguiente " "ejemplo, ambos ``MyClass`` y ``MySubclass`` son instancias de ``Meta``::" @@ -3647,17 +3621,17 @@ msgstr "Resolviendo entradas de la Orden de Resolución de Métodos (MRU)" #: ../Doc/reference/datamodel.rst:2083 msgid "" -"If a base that appears in class definition is not an instance of " -":class:`type`, then an ``__mro_entries__`` method is searched on it. If " -"found, it is called with the original bases tuple. This method must return a" -" tuple of classes that will be used instead of this base. The tuple may be " -"empty, in such case the original base is ignored." +"If a base that appears in class definition is not an instance of :class:" +"`type`, then an ``__mro_entries__`` method is searched on it. If found, it " +"is called with the original bases tuple. This method must return a tuple of " +"classes that will be used instead of this base. The tuple may be empty, in " +"such case the original base is ignored." msgstr "" -"Si una base que aparece en la definición de una clase no es una instancia de" -" :class:`type`, entonces el método ``__mro_entries__`` se busca en ella. Si " -"es encontrado, se llama con la tupla de bases originales. Este método debe " -"retornar una tupla de clases que será utilizado en lugar de esta base. La " -"tupla puede estar vacía, en cuyo caso la base original es ignorada." +"Si una base que aparece en la definición de una clase no es una instancia " +"de :class:`type`, entonces el método ``__mro_entries__`` se busca en ella. " +"Si es encontrado, se llama con la tupla de bases originales. Este método " +"debe retornar una tupla de clases que será utilizado en lugar de esta base. " +"La tupla puede estar vacía, en cuyo caso la base original es ignorada." #: ../Doc/reference/datamodel.rst:2091 msgid ":pep:`560` - Core support for typing module and generic types" @@ -3679,13 +3653,13 @@ msgstr "" msgid "" "if no bases and no explicit metaclass are given, then :func:`type` is used;" msgstr "" -"si no se dan bases ni metaclases explícitas, entonces se utiliza " -":func:`type`;" +"si no se dan bases ni metaclases explícitas, entonces se utiliza :func:" +"`type`;" #: ../Doc/reference/datamodel.rst:2102 msgid "" -"if an explicit metaclass is given and it is *not* an instance of " -":func:`type`, then it is used directly as the metaclass;" +"if an explicit metaclass is given and it is *not* an instance of :func:" +"`type`, then it is used directly as the metaclass;" msgstr "" "si se da una metaclase explícita y *no* es una instancia de :func:`type`, " "entonces se utiliza directamente como la metaclase;" @@ -3701,14 +3675,14 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2107 msgid "" "The most derived metaclass is selected from the explicitly specified " -"metaclass (if any) and the metaclasses (i.e. ``type(cls)``) of all specified" -" base classes. The most derived metaclass is one which is a subtype of *all*" -" of these candidate metaclasses. If none of the candidate metaclasses meets " +"metaclass (if any) and the metaclasses (i.e. ``type(cls)``) of all specified " +"base classes. The most derived metaclass is one which is a subtype of *all* " +"of these candidate metaclasses. If none of the candidate metaclasses meets " "that criterion, then the class definition will fail with ``TypeError``." msgstr "" "La metaclase más derivada es elegida de la metaclase especificada " -"explícitamente (si existe) y de la metaclase (p. ej. ``type(cls)``) de todas" -" las clases base especificadas." +"explícitamente (si existe) y de la metaclase (p. ej. ``type(cls)``) de todas " +"las clases base especificadas." #: ../Doc/reference/datamodel.rst:2117 msgid "Preparing the class namespace" @@ -3716,9 +3690,9 @@ msgstr "Preparando el espacio de nombres de la clase" #: ../Doc/reference/datamodel.rst:2122 msgid "" -"Once the appropriate metaclass has been identified, then the class namespace" -" is prepared. If the metaclass has a ``__prepare__`` attribute, it is called" -" as ``namespace = metaclass.__prepare__(name, bases, **kwds)`` (where the " +"Once the appropriate metaclass has been identified, then the class namespace " +"is prepared. If the metaclass has a ``__prepare__`` attribute, it is called " +"as ``namespace = metaclass.__prepare__(name, bases, **kwds)`` (where the " "additional keyword arguments, if any, come from the class definition). The " "``__prepare__`` method should be implemented as a :func:`classmethod " "`. The namespace returned by ``__prepare__`` is passed in to " @@ -3729,8 +3703,8 @@ msgstr "" "de nombres de la clase. Si la metaclase tiene un atributo ``__prepare__``, " "se llama ``namespace = metaclass.__prepare__(name, bases, **kwds)`` (donde " "los argumentos de palabras clave adicionales, si los hay, provienen de la " -"definición de clase). El método ``__prepare__`` debe implementarse como " -":func:`classmethod `. El espacio de nombres devuelto por " +"definición de clase). El método ``__prepare__`` debe implementarse como :" +"func:`classmethod `. El espacio de nombres devuelto por " "``__prepare__`` se pasa a ``__new__``, pero cuando se crea el objeto de " "clase final, el espacio de nombres se copia en un nuevo ``dict``." @@ -3762,9 +3736,9 @@ msgid "" "names from the current and outer scopes when the class definition occurs " "inside a function." msgstr "" -"El cuerpo de la clase es ejecutado como ``exec(body, globals(), namespace)``" -" (aproximadamente). La diferencia clave con un llamado normal a :func:`exec`" -" es que el alcance léxico permite que el cuerpo de la clase (incluyendo " +"El cuerpo de la clase es ejecutado como ``exec(body, globals(), namespace)`` " +"(aproximadamente). La diferencia clave con un llamado normal a :func:`exec` " +"es que el alcance léxico permite que el cuerpo de la clase (incluyendo " "cualquier método) haga referencia a nombres de los alcances actuales y " "externos cuando la definición de clase sucede dentro de la función." @@ -3777,8 +3751,8 @@ msgid "" "reference described in the next section." msgstr "" "Sin embargo, aún cuando la definición de clase sucede dentro de la función, " -"los métodos definidos dentro de la clase aún no pueden ver nombres definidos" -" dentro del alcance de la clase. Variables de clase deben ser accedidas a " +"los métodos definidos dentro de la clase aún no pueden ver nombres definidos " +"dentro del alcance de la clase. Variables de clase deben ser accedidas a " "través del primer parámetro de instancia o métodos de clase, o a través de " "la referencia al léxico implícito ``__class__`` descrita en la siguiente " "sección." @@ -3789,49 +3763,48 @@ msgstr "Creando el objeto de clase" #: ../Doc/reference/datamodel.rst:2168 msgid "" -"Once the class namespace has been populated by executing the class body, the" -" class object is created by calling ``metaclass(name, bases, namespace, " +"Once the class namespace has been populated by executing the class body, the " +"class object is created by calling ``metaclass(name, bases, namespace, " "**kwds)`` (the additional keywords passed here are the same as those passed " "to ``__prepare__``)." msgstr "" -"Una vez que el espacio de nombres de la clase ha sido poblado al ejecutar el" -" cuerpo de la clase, el objeto de clase es creado al llamar " -"``metaclass(name, bases, namespace, **kwds)`` (las palabras clave " -"adicionales que se pasan aquí, son las mismas que aquellas pasadas en " -"``__prepare__``)." +"Una vez que el espacio de nombres de la clase ha sido poblado al ejecutar el " +"cuerpo de la clase, el objeto de clase es creado al llamar ``metaclass(name, " +"bases, namespace, **kwds)`` (las palabras clave adicionales que se pasan " +"aquí, son las mismas que aquellas pasadas en ``__prepare__``)." #: ../Doc/reference/datamodel.rst:2173 msgid "" "This class object is the one that will be referenced by the zero-argument " "form of :func:`super`. ``__class__`` is an implicit closure reference " "created by the compiler if any methods in a class body refer to either " -"``__class__`` or ``super``. This allows the zero argument form of " -":func:`super` to correctly identify the class being defined based on lexical" -" scoping, while the class or instance that was used to make the current call" -" is identified based on the first argument passed to the method." -msgstr "" -"Este objeto de clase es el que será referenciado por la forma sin argumentos" -" de :func:`super`. ``__class__`` es una referencia de cierre implícita " -"creada por el compilador si cualquier método en el cuerpo de una clase se " -"refiere tanto a ``__class__`` o ``super``. Esto permite que la forma sin " -"argumentos de :func:`super` identifique correctamente la clase definida en " -"base al alcance léxico, mientras la clase o instancia que fue utilizada para" -" hacer el llamado actual es identificado en base al primer argumento que se " -"pasa al método." +"``__class__`` or ``super``. This allows the zero argument form of :func:" +"`super` to correctly identify the class being defined based on lexical " +"scoping, while the class or instance that was used to make the current call " +"is identified based on the first argument passed to the method." +msgstr "" +"Este objeto de clase es el que será referenciado por la forma sin argumentos " +"de :func:`super`. ``__class__`` es una referencia de cierre implícita creada " +"por el compilador si cualquier método en el cuerpo de una clase se refiere " +"tanto a ``__class__`` o ``super``. Esto permite que la forma sin argumentos " +"de :func:`super` identifique correctamente la clase definida en base al " +"alcance léxico, mientras la clase o instancia que fue utilizada para hacer " +"el llamado actual es identificado en base al primer argumento que se pasa al " +"método." #: ../Doc/reference/datamodel.rst:2183 msgid "" "In CPython 3.6 and later, the ``__class__`` cell is passed to the metaclass " "as a ``__classcell__`` entry in the class namespace. If present, this must " "be propagated up to the ``type.__new__`` call in order for the class to be " -"initialised correctly. Failing to do so will result in a :exc:`RuntimeError`" -" in Python 3.8." +"initialised correctly. Failing to do so will result in a :exc:`RuntimeError` " +"in Python 3.8." msgstr "" "En CPython 3.6 y posterior, la celda ``__class__`` se pasa a la metaclase " "como una entrada ``__classcell__`` en el espacio de nombres de la clase. En " "caso de existir, esto debe ser propagado hacia el llamado ``type.__new__`` " -"para que la clase se inicie correctamente. No hacerlo resultará en un error " -":exc:`RuntimeError` en Python 3.8." +"para que la clase se inicie correctamente. No hacerlo resultará en un error :" +"exc:`RuntimeError` en Python 3.8." #: ../Doc/reference/datamodel.rst:2189 msgid "" @@ -3856,13 +3829,13 @@ msgid "" "Those ``__set_name__`` methods are called with the class being defined and " "the assigned name of that particular attribute;" msgstr "" -"Esos métodos ``__set_name__`` son llamados con la clase siendo definida y el" -" nombre de ese atributo particular asignado;" +"Esos métodos ``__set_name__`` son llamados con la clase siendo definida y el " +"nombre de ese atributo particular asignado;" #: ../Doc/reference/datamodel.rst:2197 msgid "" -"The :meth:`~object.__init_subclass__` hook is called on the immediate parent" -" of the new class in its method resolution order." +"The :meth:`~object.__init_subclass__` hook is called on the immediate parent " +"of the new class in its method resolution order." msgstr "" "El gancho :meth:`~object.__init_subclass__` llama al padre inmediato de la " "nueva clase en su orden de resolución del método." @@ -3887,8 +3860,8 @@ msgstr "" "Cuando una nueva clase es creada por ``type.__new__``, el objeto " "proporcionado como el parámetro de espacio de nombres es copiado a un " "trazado ordenado y el objeto original es descartado. La nueva copia es " -"*envuelta* en un proxy de solo lectura, que se convierte en el atributo " -":attr:`~object.__dict__` del objeto de clase." +"*envuelta* en un proxy de solo lectura, que se convierte en el atributo :" +"attr:`~object.__dict__` del objeto de clase." #: ../Doc/reference/datamodel.rst:2211 msgid ":pep:`3135` - New super" @@ -3920,12 +3893,12 @@ msgstr "Personalizando revisiones de instancia y subclase" #: ../Doc/reference/datamodel.rst:2227 msgid "" -"The following methods are used to override the default behavior of the " -":func:`isinstance` and :func:`issubclass` built-in functions." +"The following methods are used to override the default behavior of the :func:" +"`isinstance` and :func:`issubclass` built-in functions." msgstr "" "Los siguientes métodos son utilizados para anular el comportamiento por " -"defecto de las funciones incorporadas :func:`isinstance` y " -":func:`issubclass`." +"defecto de las funciones incorporadas :func:`isinstance` y :func:" +"`issubclass`." #: ../Doc/reference/datamodel.rst:2230 msgid "" @@ -3945,15 +3918,15 @@ msgid "" "instance of *class*. If defined, called to implement ``isinstance(instance, " "class)``." msgstr "" -"Retorna *true* si la instancia *instance* debe ser considerada una instancia" -" (directa o indirecta) de clase *class*. De ser definida, es llamado para " +"Retorna *true* si la instancia *instance* debe ser considerada una instancia " +"(directa o indirecta) de clase *class*. De ser definida, es llamado para " "implementar ``isinstance(instance, class)``." #: ../Doc/reference/datamodel.rst:2244 msgid "" "Return true if *subclass* should be considered a (direct or indirect) " -"subclass of *class*. If defined, called to implement ``issubclass(subclass," -" class)``." +"subclass of *class*. If defined, called to implement ``issubclass(subclass, " +"class)``." msgstr "" "Retorna *true* si la subclase *subclass* debe ser considerada una subclase " "(directa o indirecta) de clase *class*. De ser definida, es llamado para " @@ -3974,22 +3947,21 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2260 msgid ":pep:`3119` - Introducing Abstract Base Classes" msgstr "" -":pep:`3119` - Introducción a Clases Base Abstractas (*Abstract Base " -"Classes*)" +":pep:`3119` - Introducción a Clases Base Abstractas (*Abstract Base Classes*)" #: ../Doc/reference/datamodel.rst:2257 msgid "" -"Includes the specification for customizing :func:`isinstance` and " -":func:`issubclass` behavior through :meth:`~class.__instancecheck__` and " -":meth:`~class.__subclasscheck__`, with motivation for this functionality in " -"the context of adding Abstract Base Classes (see the :mod:`abc` module) to " -"the language." +"Includes the specification for customizing :func:`isinstance` and :func:" +"`issubclass` behavior through :meth:`~class.__instancecheck__` and :meth:" +"`~class.__subclasscheck__`, with motivation for this functionality in the " +"context of adding Abstract Base Classes (see the :mod:`abc` module) to the " +"language." msgstr "" -"Incluye la especificación para personalizar el comportamiento de " -":func:`isinstance` y :func:`issubclass` a través de " -":meth:`~class.__instancecheck__` y :meth:`~class.__subclasscheck__`, con " -"motivación para esta funcionalidad en el contexto de agregar Clases Base " -"Abstractas (ver el módulo :mod:`abc`) al lenguaje." +"Incluye la especificación para personalizar el comportamiento de :func:" +"`isinstance` y :func:`issubclass` a través de :meth:`~class." +"__instancecheck__` y :meth:`~class.__subclasscheck__`, con motivación para " +"esta funcionalidad en el contexto de agregar Clases Base Abstractas (ver el " +"módulo :mod:`abc`) al lenguaje." #: ../Doc/reference/datamodel.rst:2265 msgid "Emulating generic types" @@ -3999,8 +3971,8 @@ msgstr "Emulando tipos genéricos" msgid "" "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`." +"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 "" "Cuando se usa :term:`type annotations`, a menudo es útil " "*parameterize* a :term:`generic type` usando la notación de corchetes de " @@ -4013,8 +3985,7 @@ msgstr ":pep:`484` - Sugerencias de tipo" #: ../Doc/reference/datamodel.rst:2275 msgid "Introducing Python's framework for type annotations" -msgstr "" -"Presentamos el marco de trabajo de Python para las anotaciones de tipo" +msgstr "Presentamos el marco de trabajo de Python para las anotaciones de tipo" #: ../Doc/reference/datamodel.rst:2278 msgid ":ref:`Generic Alias Types`" @@ -4027,11 +3998,11 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2281 msgid "" -":ref:`Generics`, :ref:`user-defined generics` and " -":class:`typing.Generic`" +":ref:`Generics`, :ref:`user-defined generics` and :" +"class:`typing.Generic`" msgstr "" -":ref:`Generics`, :ref:`user-defined generics` y " -":class:`typing.Generic`" +":ref:`Generics`, :ref:`user-defined generics` y :" +"class:`typing.Generic`" #: ../Doc/reference/datamodel.rst:2281 msgid "" @@ -4061,12 +4032,12 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2292 msgid "" "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." +"method. As such, there is no need for it to be decorated with :func:" +"`@classmethod` when it is defined." msgstr "" -"Cuando se define en una clase, ``__class_getitem__()`` es automáticamente un" -" método de clase. Como tal, no es necesario decorarlo con " -":func:`@classmethod` cuando se define." +"Cuando se define en una clase, ``__class_getitem__()`` es automáticamente un " +"método de clase. Como tal, no es necesario decorarlo con :func:" +"`@classmethod` cuando se define." #: ../Doc/reference/datamodel.rst:2298 msgid "The purpose of *__class_getitem__*" @@ -4075,41 +4046,41 @@ msgstr "El propósito de *__class_getitem__*" #: ../Doc/reference/datamodel.rst:2300 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." +"parameterization of standard-library generic classes in order to more easily " +"apply :term:`type hints` to these classes." msgstr "" "El propósito de :meth:`~object.__class_getitem__` es permitir la " "parametrización en tiempo de ejecución de clases genéricas de biblioteca " -"estándar para aplicar :term:`type hints` a estas clases con mayor" -" facilidad." +"estándar para aplicar :term:`type hints` a estas clases con mayor " +"facilidad." #: ../Doc/reference/datamodel.rst:2304 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__()``." +"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 "" "Para implementar clases genéricas personalizadas que se puedan parametrizar " "en tiempo de ejecución y que los verificadores de tipos estáticos las " "entiendan, los usuarios deben heredar de una clase de biblioteca estándar " -"que ya implementa :meth:`~object.__class_getitem__`, o heredar de " -":class:`typing.Generic`, que tiene su propia implementación de " +"que ya implementa :meth:`~object.__class_getitem__`, o heredar de :class:" +"`typing.Generic`, que tiene su propia implementación de " "``__class_getitem__()``." #: ../Doc/reference/datamodel.rst:2310 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 " +"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 "" "Es posible que los verificadores de tipos de terceros, como mypy, no " -"entiendan las implementaciones personalizadas de " -":meth:`~object.__class_getitem__` en clases definidas fuera de la biblioteca" -" estándar. Se desaconseja el uso de ``__class_getitem__()`` en cualquier " -"clase para fines distintos a la sugerencia de tipo." +"entiendan las implementaciones personalizadas de :meth:`~object." +"__class_getitem__` en clases definidas fuera de la biblioteca estándar. Se " +"desaconseja el uso de ``__class_getitem__()`` en cualquier clase para fines " +"distintos a la sugerencia de tipo." #: ../Doc/reference/datamodel.rst:2320 msgid "*__class_getitem__* versus *__getitem__*" @@ -4127,48 +4098,47 @@ msgstr "" "Por lo general, el :ref:`subscription` de un objeto que usa " "corchetes llamará al método de instancia :meth:`~object.__getitem__` " "definido en la clase del objeto. Sin embargo, si el objeto que se suscribe " -"es en sí mismo una clase, se puede llamar al método de clase " -":meth:`~object.__class_getitem__` en su lugar. ``__class_getitem__()`` " -"debería devolver un objeto :ref:`GenericAlias` si está " -"definido correctamente." +"es en sí mismo una clase, se puede llamar al método de clase :meth:`~object." +"__class_getitem__` en su lugar. ``__class_getitem__()`` debería devolver un " +"objeto :ref:`GenericAlias` si está definido " +"correctamente." #: ../Doc/reference/datamodel.rst:2329 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::" +"follows something like the following process to decide whether :meth:" +"`~object.__getitem__` or :meth:`~object.__class_getitem__` should be called::" msgstr "" "Presentado con el :term:`expression` ``obj[x]``, el intérprete de Python " -"sigue un proceso similar al siguiente para decidir si se debe llamar a " -":meth:`~object.__getitem__` o :meth:`~object.__class_getitem__`:" +"sigue un proceso similar al siguiente para decidir si se debe llamar a :meth:" +"`~object.__getitem__` o :meth:`~object.__class_getitem__`:" #: ../Doc/reference/datamodel.rst:2357 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::" +"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 "" "En Python, todas las clases son en sí mismas instancias de otras clases. La " "clase de una clase se conoce como :term:`metaclass` de esa clase, y la " -"mayoría de las clases tienen la clase :class:`type` como su metaclase. " -":class:`type` no define :meth:`~object.__getitem__`, lo que significa que " -"expresiones como ``list[int]``, ``dict[str, float]`` y ``tuple[str, bytes]``" -" dan como resultado que se llame a :meth:`~object.__class_getitem__`:" +"mayoría de las clases tienen la clase :class:`type` como su metaclase. :" +"class:`type` no define :meth:`~object.__getitem__`, lo que significa que " +"expresiones como ``list[int]``, ``dict[str, float]`` y ``tuple[str, bytes]`` " +"dan como resultado que se llame a :meth:`~object.__class_getitem__`:" #: ../Doc/reference/datamodel.rst:2376 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::" +"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 "" -"Sin embargo, si una clase tiene una metaclase personalizada que define " -":meth:`~object.__getitem__`, la suscripción de la clase puede generar un " -"comportamiento diferente. Un ejemplo de esto se puede encontrar en el módulo" -" :mod:`enum`:" +"Sin embargo, si una clase tiene una metaclase personalizada que define :meth:" +"`~object.__getitem__`, la suscripción de la clase puede generar un " +"comportamiento diferente. Un ejemplo de esto se puede encontrar en el " +"módulo :mod:`enum`:" #: ../Doc/reference/datamodel.rst:2401 msgid ":pep:`560` - Core Support for typing module and generic types" @@ -4177,12 +4147,12 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2400 msgid "" -"Introducing :meth:`~object.__class_getitem__`, and outlining when a " -":ref:`subscription` results in ``__class_getitem__()`` being " +"Introducing :meth:`~object.__class_getitem__`, and outlining when a :ref:" +"`subscription` results in ``__class_getitem__()`` being " "called instead of :meth:`~object.__getitem__`" msgstr "" -"Presentamos :meth:`~object.__class_getitem__` y describimos cuándo un " -":ref:`subscription` da como resultado que se llame a " +"Presentamos :meth:`~object.__class_getitem__` y describimos cuándo un :ref:" +"`subscription` da como resultado que se llame a " "``__class_getitem__()`` en lugar de :meth:`~object.__getitem__`" #: ../Doc/reference/datamodel.rst:2408 @@ -4195,9 +4165,9 @@ msgid "" "defined, ``x(arg1, arg2, ...)`` roughly translates to ``type(x).__call__(x, " "arg1, ...)``." msgstr "" -"Es llamado cuando la instancia es “llamada” como una función; si este método" -" es definido, ``x(arg1, arg2, …)`` es una clave corta para " -"``x.__call__(arg1, arg2, …)``." +"Es llamado cuando la instancia es “llamada” como una función; si este método " +"es definido, ``x(arg1, arg2, …)`` es una clave corta para ``x.__call__(arg1, " +"arg2, …)``." #: ../Doc/reference/datamodel.rst:2422 msgid "Emulating container types" @@ -4207,73 +4177,71 @@ msgstr "Emulando tipos de contenedores" msgid "" "The following methods can be defined to implement container objects. " "Containers usually are :term:`sequences ` (such as :class:`lists " -"` or :class:`tuples `) or :term:`mappings ` (like " -":class:`dictionaries `), but can represent other containers as well. " +"` or :class:`tuples `) or :term:`mappings ` (like :" +"class:`dictionaries `), but can represent other containers as well. " "The first set of methods is used either to emulate a sequence or to emulate " "a mapping; the difference is that for a sequence, the allowable keys should " "be the integers *k* for which ``0 <= k < N`` where *N* is the length of the " "sequence, or :class:`slice` objects, which define a range of items. It is " -"also recommended that mappings provide the methods :meth:`keys`, " -":meth:`values`, :meth:`items`, :meth:`get`, :meth:`clear`, " -":meth:`setdefault`, :meth:`pop`, :meth:`popitem`, :meth:`!copy`, and " -":meth:`update` behaving similar to those for Python's standard " -":class:`dictionary ` objects. The :mod:`collections.abc` module " -"provides a :class:`~collections.abc.MutableMapping` :term:`abstract base " -"class` to help create those methods from a base set of " -":meth:`~object.__getitem__`, :meth:`~object.__setitem__`, " -":meth:`~object.__delitem__`, and :meth:`keys`. Mutable sequences should " -"provide methods :meth:`append`, :meth:`count`, :meth:`index`, " -":meth:`extend`, :meth:`insert`, :meth:`pop`, :meth:`remove`, :meth:`reverse`" -" and :meth:`sort`, like Python standard :class:`list` objects. Finally, " -"sequence types should implement addition (meaning concatenation) and " -"multiplication (meaning repetition) by defining the methods " -":meth:`~object.__add__`, :meth:`~object.__radd__`, :meth:`~object.__iadd__`," -" :meth:`~object.__mul__`, :meth:`~object.__rmul__` and " -":meth:`~object.__imul__` described below; they should not define other " -"numerical operators. It is recommended that both mappings and sequences " -"implement the :meth:`~object.__contains__` method to allow efficient use of " -"the ``in`` operator; for mappings, ``in`` should search the mapping's keys; " -"for sequences, it should search through the values. It is further " -"recommended that both mappings and sequences implement the " -":meth:`~object.__iter__` method to allow efficient iteration through the " -"container; for mappings, :meth:`__iter__` should iterate through the " -"object's keys; for sequences, it should iterate through the values." +"also recommended that mappings provide the methods :meth:`keys`, :meth:" +"`values`, :meth:`items`, :meth:`get`, :meth:`clear`, :meth:`setdefault`, :" +"meth:`pop`, :meth:`popitem`, :meth:`!copy`, and :meth:`update` behaving " +"similar to those for Python's standard :class:`dictionary ` objects. " +"The :mod:`collections.abc` module provides a :class:`~collections.abc." +"MutableMapping` :term:`abstract base class` to help create those methods " +"from a base set of :meth:`~object.__getitem__`, :meth:`~object." +"__setitem__`, :meth:`~object.__delitem__`, and :meth:`keys`. Mutable " +"sequences should provide methods :meth:`append`, :meth:`count`, :meth:" +"`index`, :meth:`extend`, :meth:`insert`, :meth:`pop`, :meth:`remove`, :meth:" +"`reverse` and :meth:`sort`, like Python standard :class:`list` objects. " +"Finally, sequence types should implement addition (meaning concatenation) " +"and multiplication (meaning repetition) by defining the methods :meth:" +"`~object.__add__`, :meth:`~object.__radd__`, :meth:`~object.__iadd__`, :meth:" +"`~object.__mul__`, :meth:`~object.__rmul__` and :meth:`~object.__imul__` " +"described below; they should not define other numerical operators. It is " +"recommended that both mappings and sequences implement the :meth:`~object." +"__contains__` method to allow efficient use of the ``in`` operator; for " +"mappings, ``in`` should search the mapping's keys; for sequences, it should " +"search through the values. It is further recommended that both mappings and " +"sequences implement the :meth:`~object.__iter__` method to allow efficient " +"iteration through the container; for mappings, :meth:`__iter__` should " +"iterate through the object's keys; for sequences, it should iterate through " +"the values." msgstr "" "Los siguientes métodos se pueden definir para implementar objetos " -"contenedores. Los contenedores suelen ser :term:`sequences ` (como" -" :class:`lists ` o :class:`tuples `) o :term:`mappings " +"contenedores. Los contenedores suelen ser :term:`sequences ` " +"(como :class:`lists ` o :class:`tuples `) o :term:`mappings " "` (como :class:`dictionaries `), pero también pueden " "representar otros contenedores. El primer conjunto de métodos se usa para " "emular una secuencia o para emular un mapeo; la diferencia es que para una " "secuencia, las claves permitidas deberían ser los enteros *k* para los " -"cuales ``0 <= k < N`` donde *N* es la longitud de la secuencia, u objetos " -":class:`slice`, que definen un rango de elementos. También se recomienda que" -" las asignaciones proporcionen los métodos :meth:`keys`, :meth:`values`, " -":meth:`items`, :meth:`get`, :meth:`clear`, :meth:`setdefault`, :meth:`pop`, " -":meth:`popitem`, :meth:`!copy` y :meth:`update` con un comportamiento " -"similar al de los objetos :class:`dictionary ` estándar de Python. El " -"módulo :mod:`collections.abc` proporciona un " -":class:`~collections.abc.MutableMapping` :term:`abstract base class` para " -"ayudar a crear esos métodos a partir de un conjunto base de " -":meth:`~object.__getitem__`, :meth:`~object.__setitem__`, " -":meth:`~object.__delitem__` y :meth:`keys`. Las secuencias mutables deben " -"proporcionar los métodos :meth:`append`, :meth:`count`, :meth:`index`, " -":meth:`extend`, :meth:`insert`, :meth:`pop`, :meth:`remove`, :meth:`reverse`" -" y :meth:`sort`, como los objetos :class:`list` estándar de Python. " +"cuales ``0 <= k < N`` donde *N* es la longitud de la secuencia, u objetos :" +"class:`slice`, que definen un rango de elementos. También se recomienda que " +"las asignaciones proporcionen los métodos :meth:`keys`, :meth:`values`, :" +"meth:`items`, :meth:`get`, :meth:`clear`, :meth:`setdefault`, :meth:`pop`, :" +"meth:`popitem`, :meth:`!copy` y :meth:`update` con un comportamiento similar " +"al de los objetos :class:`dictionary ` estándar de Python. El módulo :" +"mod:`collections.abc` proporciona un :class:`~collections.abc." +"MutableMapping` :term:`abstract base class` para ayudar a crear esos métodos " +"a partir de un conjunto base de :meth:`~object.__getitem__`, :meth:`~object." +"__setitem__`, :meth:`~object.__delitem__` y :meth:`keys`. Las secuencias " +"mutables deben proporcionar los métodos :meth:`append`, :meth:`count`, :meth:" +"`index`, :meth:`extend`, :meth:`insert`, :meth:`pop`, :meth:`remove`, :meth:" +"`reverse` y :meth:`sort`, como los objetos :class:`list` estándar de Python. " "Finalmente, los tipos de secuencia deben implementar la suma (es decir, la " "concatenación) y la multiplicación (es decir, la repetición) definiendo los " -"métodos :meth:`~object.__add__`, :meth:`~object.__radd__`, " -":meth:`~object.__iadd__`, :meth:`~object.__mul__`, :meth:`~object.__rmul__` " -"y :meth:`~object.__imul__` que se describen a continuación; no deben definir" -" otros operadores numéricos. Se recomienda que tanto las asignaciones como " -"las secuencias implementen el método :meth:`~object.__contains__` para " -"permitir un uso eficiente del operador ``in``; para asignaciones, ``in`` " -"debe buscar las claves de la asignación; para secuencias, debe buscar a " -"través de los valores. Se recomienda además que tanto las asignaciones como " -"las secuencias implementen el método :meth:`~object.__iter__` para permitir " -"una iteración eficiente a través del contenedor; para asignaciones, " -":meth:`__iter__` debe iterar a través de las claves del objeto; para " -"secuencias, debe iterar a través de los valores." +"métodos :meth:`~object.__add__`, :meth:`~object.__radd__`, :meth:`~object." +"__iadd__`, :meth:`~object.__mul__`, :meth:`~object.__rmul__` y :meth:" +"`~object.__imul__` que se describen a continuación; no deben definir otros " +"operadores numéricos. Se recomienda que tanto las asignaciones como las " +"secuencias implementen el método :meth:`~object.__contains__` para permitir " +"un uso eficiente del operador ``in``; para asignaciones, ``in`` debe buscar " +"las claves de la asignación; para secuencias, debe buscar a través de los " +"valores. Se recomienda además que tanto las asignaciones como las secuencias " +"implementen el método :meth:`~object.__iter__` para permitir una iteración " +"eficiente a través del contenedor; para asignaciones, :meth:`__iter__` debe " +"iterar a través de las claves del objeto; para secuencias, debe iterar a " +"través de los valores." #: ../Doc/reference/datamodel.rst:2464 msgid "" @@ -4289,39 +4257,38 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2471 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:`len`) may raise :exc:`OverflowError`. To prevent raising " -":exc:`!OverflowError` by truth value testing, an object must define a " -":meth:`__bool__` method." +"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:" +"`len`) may raise :exc:`OverflowError`. To prevent raising :exc:`!" +"OverflowError` by truth value testing, an object must define a :meth:" +"`__bool__` method." msgstr "" "En CPython, se requiere que la longitud sea como mucho :attr:`sys.maxsize`. " "Si la longitud es más grande que :attr:`!sys.maxsize` algunas " -"características (como :func:`len`) pueden lanzar una excepción " -":exc:`OverflowError`. Para prevenir lanzar una excepción " -":exc:`!OverflowError` al validar la verdad de un valor, un objeto debe " -"definir un método :meth:`__bool__`." +"características (como :func:`len`) pueden lanzar una excepción :exc:" +"`OverflowError`. Para prevenir lanzar una excepción :exc:`!OverflowError` al " +"validar la verdad de un valor, un objeto debe definir un método :meth:" +"`__bool__`." #: ../Doc/reference/datamodel.rst:2480 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). The length must be an integer ``>=`` 0. The return value may also " -"be :const:`NotImplemented`, which is treated the same as if the " -"``__length_hint__`` method didn't exist at all. This method is purely an " -"optimization and is never required for correctness." +"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). " +"The length must be an integer ``>=`` 0. The return value may also be :const:" +"`NotImplemented`, which is treated the same as if the ``__length_hint__`` " +"method didn't exist at all. This method is purely an optimization and is " +"never required for correctness." msgstr "" "Es llamado para implementar :func:`operator.length_hint`. Debe retornar una " "longitud estimada para el objeto (que puede ser mayor o menor que la " "longitud actual). La longitud debe ser un entero ``>=`` 0. El valor de " -"retorno también debe ser :const:`NotImplemented` el cual es tratado de igual" -" forma a que si el método ``__length_hint__`` no existiera en absoluto. Este" -" método es puramente una optimización y nunca es requerido para precisión." +"retorno también debe ser :const:`NotImplemented` el cual es tratado de igual " +"forma a que si el método ``__length_hint__`` no existiera en absoluto. Este " +"método es puramente una optimización y nunca es requerido para precisión." #: ../Doc/reference/datamodel.rst:2494 msgid "" -"Slicing is done exclusively with the following three methods. A call like " -"::" +"Slicing is done exclusively with the following three methods. A call like ::" msgstr "" "La segmentación se hace exclusivamente con los siguientes tres métodos. Un " "llamado como ::" @@ -4333,31 +4300,30 @@ msgstr "es traducido a ::" #: ../Doc/reference/datamodel.rst:2502 msgid "and so forth. Missing slice items are always filled in with ``None``." msgstr "" -"etcétera. Elementos faltantes de segmentos siempre son llenados con " -"``None``." +"etcétera. Elementos faltantes de segmentos siempre son llenados con ``None``." #: ../Doc/reference/datamodel.rst:2507 msgid "" -"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 " +"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." +"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 "" -"Llamado a implementar la evaluación de ``self[key]``. Para los tipos " -":term:`sequence`, las claves aceptadas deben ser números enteros y objetos " -"de división. Tenga en cuenta que la interpretación especial de los índices " +"Llamado a implementar la evaluación de ``self[key]``. Para los tipos :term:" +"`sequence`, las claves aceptadas deben ser números enteros y objetos de " +"división. Tenga en cuenta que la interpretación especial de los índices " "negativos (si la clase desea emular un tipo :term:`sequence`) depende del " "método :meth:`__getitem__`. Si *key* es de un tipo inapropiado, se puede " -"generar :exc:`TypeError`; si tiene un valor fuera del conjunto de índices de" -" la secuencia (después de cualquier interpretación especial de valores " -"negativos), se debe generar :exc:`IndexError`. Para los tipos " -":term:`mapping`, si falta *key* (no en el contenedor), debe generarse " -":exc:`KeyError`." +"generar :exc:`TypeError`; si tiene un valor fuera del conjunto de índices de " +"la secuencia (después de cualquier interpretación especial de valores " +"negativos), se debe generar :exc:`IndexError`. Para los tipos :term:" +"`mapping`, si falta *key* (no en el contenedor), debe generarse :exc:" +"`KeyError`." #: ../Doc/reference/datamodel.rst:2519 msgid "" @@ -4370,9 +4336,9 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2524 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." +"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 "" "Cuando :ref:`subscripting` a *class*, se puede llamar al " "método de clase especial :meth:`~object.__class_getitem__` en lugar de " @@ -4380,11 +4346,11 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2532 msgid "" -"Called to implement assignment to ``self[key]``. Same note as for " -":meth:`__getitem__`. This should only be implemented for mappings if the " -"objects support changes to the values for keys, or if new keys can be added," -" or for sequences if elements can be replaced. The same exceptions should " -"be raised for improper *key* values as for the :meth:`__getitem__` method." +"Called to implement assignment to ``self[key]``. Same note as for :meth:" +"`__getitem__`. This should only be implemented for mappings if the objects " +"support changes to the values for keys, or if new keys can be added, or for " +"sequences if elements can be replaced. The same exceptions should be raised " +"for improper *key* values as for the :meth:`__getitem__` method." msgstr "" "Es llamado para implementar la asignación a ``self[key]``. Lo mismo con " "respecto a :meth:`__getitem__`. Esto solo debe ser implementado para mapeos " @@ -4395,34 +4361,34 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2541 msgid "" -"Called to implement deletion of ``self[key]``. Same note as for " -":meth:`__getitem__`. This should only be implemented for mappings if the " -"objects support removal of keys, or for sequences if elements can be removed" -" from the sequence. The same exceptions should be raised for improper *key*" -" values as for the :meth:`__getitem__` method." +"Called to implement deletion of ``self[key]``. Same note as for :meth:" +"`__getitem__`. This should only be implemented for mappings if the objects " +"support removal of keys, or for sequences if elements can be removed from " +"the sequence. The same exceptions should be raised for improper *key* " +"values as for the :meth:`__getitem__` method." msgstr "" "Es llamado para implementar el borrado de ``self[key]``. Lo mismo con " "respecto a :meth:`__getitem__`. Esto solo debe ser implementado para mapeos " "si los objetos permiten el borrado de llaves, o para secuencias si los " "elementos pueden ser eliminados de la secuencia. Las mismas excepciones " -"deben ser lanzadas por valores de *key* inapropiados con respecto al método " -":meth:`__getitem__`." +"deben ser lanzadas por valores de *key* inapropiados con respecto al método :" +"meth:`__getitem__`." #: ../Doc/reference/datamodel.rst:2550 msgid "" -"Called by :class:`dict`\\ .\\ :meth:`__getitem__` to implement ``self[key]``" -" for dict subclasses when key is not in the dictionary." +"Called by :class:`dict`\\ .\\ :meth:`__getitem__` to implement ``self[key]`` " +"for dict subclasses when key is not in the dictionary." msgstr "" "Es llamado por :class:`dict`\\ .\\ :meth:`__getitem__` para implementar " -"``self[key]`` para subclases de diccionarios cuando la llave no se encuentra" -" en el diccionario." +"``self[key]`` para subclases de diccionarios cuando la llave no se encuentra " +"en el diccionario." #: ../Doc/reference/datamodel.rst:2556 msgid "" "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." +"the objects in the container. For mappings, it should iterate over the keys " +"of the container." msgstr "" "Se llama a este método cuando se requiere un :term:`iterator` para un " "contenedor. Este método debería devolver un nuevo objeto iterador que pueda " @@ -4437,29 +4403,28 @@ msgid "" msgstr "" "Es llamado (si existe) por la función incorporada :func:`reversed` para " "implementar una interacción invertida. Debe retornar un nuevo objeto " -"iterador que itere sobre todos los objetos en el contenedor en orden " -"inverso." +"iterador que itere sobre todos los objetos en el contenedor en orden inverso." #: ../Doc/reference/datamodel.rst:2568 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 " -":meth:`__getitem__`). Objects that support the sequence protocol should " -"only provide :meth:`__reversed__` if they can provide an implementation that" -" is more efficient than the one provided by :func:`reversed`." +"built-in will fall back to using the sequence protocol (:meth:`__len__` and :" +"meth:`__getitem__`). Objects that support the sequence protocol should only " +"provide :meth:`__reversed__` if they can provide an implementation that is " +"more efficient than the one provided by :func:`reversed`." msgstr "" "Si el método :meth:`__reversed__` no es proporcionado, la función " "incorporada :func:`reversed` recurrirá a utilizar el protocolo de secuencia " "(:meth:`__len__` y :meth:`__getitem__`). Objetos que permiten el protocolo " -"de secuencia deben únicamente proporcionar :meth:`__reversed__` si no pueden" -" proporcionar una implementación que sea más eficiente que la proporcionada " +"de secuencia deben únicamente proporcionar :meth:`__reversed__` si no pueden " +"proporcionar una implementación que sea más eficiente que la proporcionada " "por :func:`reversed`." #: ../Doc/reference/datamodel.rst:2575 msgid "" "The membership test operators (:keyword:`in` and :keyword:`not in`) are " -"normally implemented as an iteration through a container. However, container" -" objects can supply the following special method with a more efficient " +"normally implemented as an iteration through a container. However, container " +"objects can supply the following special method with a more efficient " "implementation, which also does not require the object be iterable." msgstr "" "Los operadores de prueba de pertenencia (:keyword:`in` and :keyword:`not " @@ -4470,8 +4435,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2582 msgid "" -"Called to implement membership test operators. Should return true if *item*" -" is in *self*, false otherwise. For mapping objects, this should consider " +"Called to implement membership test operators. Should return true if *item* " +"is in *self*, false otherwise. For mapping objects, this should consider " "the keys of the mapping rather than the values or the key-item pairs." msgstr "" "Es llamado para implementar operadores de prueba de pertenencia. Deben " @@ -4488,8 +4453,8 @@ msgid "" msgstr "" "Para objetos que no definen :meth:`__contains__`, la prueba de pertenencia " "primero intenta la iteración a través de :meth:`__iter__`, y luego el " -"antiguo protocolo de iteración de secuencia a través de :meth:`__getitem__`," -" ver :ref:`esta sección en la referencia del lenguaje `." #: ../Doc/reference/datamodel.rst:2595 @@ -4499,8 +4464,8 @@ msgstr "Emulando tipos numéricos" #: ../Doc/reference/datamodel.rst:2597 msgid "" "The following methods can be defined to emulate numeric objects. Methods " -"corresponding to operations that are not supported by the particular kind of" -" number implemented (e.g., bitwise operations for non-integral numbers) " +"corresponding to operations that are not supported by the particular kind of " +"number implemented (e.g., bitwise operations for non-integral numbers) " "should be left undefined." msgstr "" "Los siguientes métodos pueden ser definidos para emular objetos numéricos. " @@ -4511,23 +4476,23 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2623 msgid "" "These methods are called to implement the binary arithmetic operations " -"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " -":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``). For instance, to" -" evaluate the expression ``x + y``, where *x* is an instance of a class that" -" has an :meth:`__add__` method, ``type(x).__add__(x, y)`` is called. The " -":meth:`__divmod__` method should be the equivalent to using " -":meth:`__floordiv__` and :meth:`__mod__`; it should not be related to " -":meth:`__truediv__`. Note that :meth:`__pow__` should be defined to accept " -"an optional third argument if the ternary version of the built-in " -":func:`pow` function is to be supported." +"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :func:" +"`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``). For instance, to " +"evaluate the expression ``x + y``, where *x* is an instance of a class that " +"has an :meth:`__add__` method, ``type(x).__add__(x, y)`` is called. The :" +"meth:`__divmod__` method should be the equivalent to using :meth:" +"`__floordiv__` and :meth:`__mod__`; it should not be related to :meth:" +"`__truediv__`. Note that :meth:`__pow__` should be defined to accept an " +"optional third argument if the ternary version of the built-in :func:`pow` " +"function is to be supported." msgstr "" "Estos métodos se llaman para implementar las operaciones aritméticas " -"binarias (``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " -":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``). Por ejemplo, para" -" evaluar la expresión ``x + y``, donde *x* es una instancia de una clase que" -" tiene un método :meth:`__add__`, se llama a ``type(x).__add__(x, y)``. El " -"método :meth:`__divmod__` debe ser equivalente a usar :meth:`__floordiv__` y" -" :meth:`__mod__`; no debe estar relacionado con :meth:`__truediv__`. Tenga " +"binarias (``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :" +"func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``). Por ejemplo, para " +"evaluar la expresión ``x + y``, donde *x* es una instancia de una clase que " +"tiene un método :meth:`__add__`, se llama a ``type(x).__add__(x, y)``. El " +"método :meth:`__divmod__` debe ser equivalente a usar :meth:`__floordiv__` " +"y :meth:`__mod__`; no debe estar relacionado con :meth:`__truediv__`. Tenga " "en cuenta que :meth:`__pow__` debe definirse para aceptar un tercer " "argumento opcional si se va a admitir la versión ternaria de la función " "integrada :func:`pow`." @@ -4543,24 +4508,24 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2657 msgid "" "These methods are called to implement the binary arithmetic operations " -"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " -":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``) with reflected " -"(swapped) operands. These functions are only called if the left operand " -"does not support the corresponding operation [#]_ and the operands are of " -"different types. [#]_ For instance, to evaluate the expression ``x - y``, " -"where *y* is an instance of a class that has an :meth:`__rsub__` method, " -"``type(y).__rsub__(y, x)`` is called if ``type(x).__sub__(x, y)`` returns " +"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :func:" +"`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``) with reflected (swapped) " +"operands. These functions are only called if the left operand does not " +"support the corresponding operation [#]_ and the operands are of different " +"types. [#]_ For instance, to evaluate the expression ``x - y``, where *y* is " +"an instance of a class that has an :meth:`__rsub__` method, ``type(y)." +"__rsub__(y, x)`` is called if ``type(x).__sub__(x, y)`` returns " "*NotImplemented*." msgstr "" "Estos métodos se llaman para implementar las operaciones aritméticas " -"binarias (``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " -":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``) con operandos " +"binarias (``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :" +"func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``) con operandos " "reflejados (intercambiados). Estas funciones solo se llaman si el operando " -"izquierdo no admite la operación correspondiente [#]_ y los operandos son de" -" diferentes tipos. [#]_ Por ejemplo, para evaluar la expresión ``x - y``, " -"donde *y* es una instancia de una clase que tiene un método " -":meth:`__rsub__`, se llama a ``type(y).__rsub__(y, x)`` si " -"``type(x).__sub__(x, y)`` devuelve *NotImplemented*." +"izquierdo no admite la operación correspondiente [#]_ y los operandos son de " +"diferentes tipos. [#]_ Por ejemplo, para evaluar la expresión ``x - y``, " +"donde *y* es una instancia de una clase que tiene un método :meth:" +"`__rsub__`, se llama a ``type(y).__rsub__(y, x)`` si ``type(x).__sub__(x, " +"y)`` devuelve *NotImplemented*." #: ../Doc/reference/datamodel.rst:2669 msgid "" @@ -4582,20 +4547,20 @@ msgstr "" "Si el tipo del operando de la derecha es una subclase del tipo del operando " "de la izquierda y esa subclase proporciona el método reflejado para la " "operación, este método será llamado antes del método no reflejado del " -"operando izquierdo. Este comportamiento permite que las subclases anulen las" -" operaciones de sus predecesores." +"operando izquierdo. Este comportamiento permite que las subclases anulen las " +"operaciones de sus predecesores." #: ../Doc/reference/datamodel.rst:2695 msgid "" "These methods are called to implement the augmented arithmetic assignments " "(``+=``, ``-=``, ``*=``, ``@=``, ``/=``, ``//=``, ``%=``, ``**=``, ``<<=``, " "``>>=``, ``&=``, ``^=``, ``|=``). These methods should attempt to do the " -"operation in-place (modifying *self*) and return the result (which could be," -" but does not have to be, *self*). If a specific method is not defined, the" -" augmented assignment falls back to the normal methods. For instance, if " -"*x* is an instance of a class with an :meth:`__iadd__` method, ``x += y`` is" -" equivalent to ``x = x.__iadd__(y)`` . Otherwise, ``x.__add__(y)`` and " -"``y.__radd__(x)`` are considered, as with the evaluation of ``x + y``. In " +"operation in-place (modifying *self*) and return the result (which could be, " +"but does not have to be, *self*). If a specific method is not defined, the " +"augmented assignment falls back to the normal methods. For instance, if *x* " +"is an instance of a class with an :meth:`__iadd__` method, ``x += y`` is " +"equivalent to ``x = x.__iadd__(y)`` . Otherwise, ``x.__add__(y)`` and ``y." +"__radd__(x)`` are considered, as with the evaluation of ``x + y``. In " "certain situations, augmented assignment can result in unexpected errors " "(see :ref:`faq-augmented-assignment-tuple-error`), but this behavior is in " "fact part of the data model." @@ -4603,32 +4568,32 @@ msgstr "" "Estos métodos son llamados para implementar las asignaciones aritméticas " "aumentadas (``+=``, ``-=``, ``*=``, ``@=``, ``/=``, ``//=``, ``%=``, " "``**=``, ``<<=``, ``>>=``, ``&=``, ``^=``, ``|=``). Estos métodos deben " -"intentar realizar la operación *in-place* (modificando *self*) y retornar el" -" resultado (que puede, pero no tiene que ser *self*). Si un método " -"específico no es definido, la asignación aumentada regresa a los métodos " -"normales. Por ejemplo, si *x* es la instancia de una clase con el método " -":meth:`__iadd__`, ``x += y`` es equivalente a ``x = x.__iadd__(y)``. De lo " -"contrario ``x.__add__(y)`` y ``y.__radd__(x)`` se consideran al igual que " -"con la evaluación de ``x + y``. En ciertas situaciones, asignaciones " -"aumentadas pueden resultar en errores no esperados (ver :ref:`faq-augmented-" -"assignment-tuple-error`), pero este comportamiento es en realidad parte del " -"modelo de datos." +"intentar realizar la operación *in-place* (modificando *self*) y retornar el " +"resultado (que puede, pero no tiene que ser *self*). Si un método específico " +"no es definido, la asignación aumentada regresa a los métodos normales. Por " +"ejemplo, si *x* es la instancia de una clase con el método :meth:`__iadd__`, " +"``x += y`` es equivalente a ``x = x.__iadd__(y)``. De lo contrario ``x." +"__add__(y)`` y ``y.__radd__(x)`` se consideran al igual que con la " +"evaluación de ``x + y``. En ciertas situaciones, asignaciones aumentadas " +"pueden resultar en errores no esperados (ver :ref:`faq-augmented-assignment-" +"tuple-error`), pero este comportamiento es en realidad parte del modelo de " +"datos." #: ../Doc/reference/datamodel.rst:2716 msgid "" -"Called to implement the unary arithmetic operations (``-``, ``+``, " -":func:`abs` and ``~``)." +"Called to implement the unary arithmetic operations (``-``, ``+``, :func:" +"`abs` and ``~``)." msgstr "" "Es llamado para implementar las operaciones aritméticas unarias (``-``, " "``+``, :func:`abs` and ``~``)." #: ../Doc/reference/datamodel.rst:2729 msgid "" -"Called to implement the built-in functions :func:`complex`, :func:`int` and " -":func:`float`. Should return a value of the appropriate type." +"Called to implement the built-in functions :func:`complex`, :func:`int` and :" +"func:`float`. Should return a value of the appropriate type." msgstr "" -"Es llamado para implementar las funciones incorporadas :func:`complex`, " -":func:`int` y :func:`float`. Debe retornar un valor del tipo apropiado." +"Es llamado para implementar las funciones incorporadas :func:`complex`, :" +"func:`int` y :func:`float`. Debe retornar un valor del tipo apropiado." #: ../Doc/reference/datamodel.rst:2736 msgid "" @@ -4640,19 +4605,19 @@ msgid "" msgstr "" "Es llamado para implementar :func:`operator.index`, y cuando sea que Python " "necesite convertir sin pérdidas el objeto numérico a un objeto entero (tal " -"como en la segmentación o *slicing*, o las funciones incorporadas " -":func:`bin`, :func:`hex` y :func:`oct`). La presencia de este método indica " -"que el objeto numérico es un tipo entero. Debe retornar un entero." +"como en la segmentación o *slicing*, o las funciones incorporadas :func:" +"`bin`, :func:`hex` y :func:`oct`). La presencia de este método indica que el " +"objeto numérico es un tipo entero. Debe retornar un entero." #: ../Doc/reference/datamodel.rst:2742 msgid "" "If :meth:`__int__`, :meth:`__float__` and :meth:`__complex__` are not " -"defined then corresponding built-in functions :func:`int`, :func:`float` and" -" :func:`complex` fall back to :meth:`__index__`." +"defined then corresponding built-in functions :func:`int`, :func:`float` " +"and :func:`complex` fall back to :meth:`__index__`." msgstr "" "Si :meth:`__int__`, :meth:`__float__` y :meth:`__complex__` no son " -"definidos, entonces todas las funciones incorporadas correspondientes " -":func:`int`, :func:`float` y :func:`complex` vuelven a :meth:`__index__`." +"definidos, entonces todas las funciones incorporadas correspondientes :func:" +"`int`, :func:`float` y :func:`complex` vuelven a :meth:`__index__`." #: ../Doc/reference/datamodel.rst:2754 msgid "" @@ -4663,15 +4628,15 @@ msgid "" "(typically an :class:`int`)." msgstr "" "Es llamado para implementar la función incorporada :func:`round` y las " -"funciones :mod:`math` :func:`~math.trunc`, :func:`~math.floor` y " -":func:`~math.ceil`. A menos que *ndigits* sea pasado a :meth:`!__round__` " -"todos estos métodos deben retornar el valor del objeto truncado a " -":class:`~numbers.Integral` (normalmente :class:`int`)." +"funciones :mod:`math` :func:`~math.trunc`, :func:`~math.floor` y :func:" +"`~math.ceil`. A menos que *ndigits* sea pasado a :meth:`!__round__` todos " +"estos métodos deben retornar el valor del objeto truncado a :class:`~numbers." +"Integral` (normalmente :class:`int`)." #: ../Doc/reference/datamodel.rst:2760 msgid "" -"The built-in function :func:`int` falls back to :meth:`__trunc__` if neither" -" :meth:`__int__` nor :meth:`__index__` is defined." +"The built-in function :func:`int` falls back to :meth:`__trunc__` if " +"neither :meth:`__int__` nor :meth:`__index__` is defined." msgstr "" "La función integrada :func:`int` recurre a :meth:`__trunc__` si no se " "definen ni :meth:`__int__` ni :meth:`__index__`." @@ -4686,20 +4651,20 @@ msgstr "Gestores de Contexto en la Declaración *with*" #: ../Doc/reference/datamodel.rst:2772 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" -" handles the entry into, and the exit from, the desired runtime context for " +"A :dfn:`context manager` is an object that defines the runtime context to be " +"established when executing a :keyword:`with` statement. The context manager " +"handles the entry into, and the exit from, the desired runtime context for " "the execution of the block of code. Context managers are normally invoked " -"using the :keyword:`!with` statement (described in section :ref:`with`), but" -" can also be used by directly invoking their methods." +"using the :keyword:`!with` statement (described in section :ref:`with`), but " +"can also be used by directly invoking their methods." msgstr "" "Un :dfn:`context manager` es un objeto que define el contexto en tiempo de " -"ejecución a ser establecido cuando se ejecuta una declaración " -":keyword:`with`. El gestor de contexto maneja la entrada y la salida del " -"contexto en tiempo de ejecución deseado para la ejecución del bloque de " -"código. Los gestores de contexto son normalmente invocados utilizando la " -"declaración :keyword:`!with` (descritos en la sección :ref:`with`), pero " -"también pueden ser utilizados al invocar directamente sus métodos." +"ejecución a ser establecido cuando se ejecuta una declaración :keyword:" +"`with`. El gestor de contexto maneja la entrada y la salida del contexto en " +"tiempo de ejecución deseado para la ejecución del bloque de código. Los " +"gestores de contexto son normalmente invocados utilizando la declaración :" +"keyword:`!with` (descritos en la sección :ref:`with`), pero también pueden " +"ser utilizados al invocar directamente sus métodos." #: ../Doc/reference/datamodel.rst:2783 msgid "" @@ -4714,14 +4679,14 @@ msgstr "" msgid "" "For more information on context managers, see :ref:`typecontextmanager`." msgstr "" -"Para más información sobre gestores de contexto, ver " -":ref:`typecontextmanager`." +"Para más información sobre gestores de contexto, ver :ref:" +"`typecontextmanager`." #: ../Doc/reference/datamodel.rst:2791 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" -" the :keyword:`!as` clause of the statement, if any." +"statement will bind this method's return value to the target(s) specified in " +"the :keyword:`!as` clause of the statement, if any." msgstr "" "Ingresa al contexto en tiempo de ejecución relacionado con este objeto. La " "declaración :keyword:`with` ligará el valor de retorno de este método al " @@ -4730,8 +4695,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2798 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 " +"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 " "without an exception, all three arguments will be :const:`None`." msgstr "" "Sale del contexto en tiempo de ejecución relacionado a este objeto. Los " @@ -4740,8 +4705,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2802 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. " +"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. " "Otherwise, the exception will be processed normally upon exit from this " "method." msgstr "" @@ -4774,29 +4739,29 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2820 msgid "Customizing positional arguments in class pattern matching" msgstr "" -"Personalización de argumentos posicionales en la coincidencia de patrones de" -" clase" +"Personalización de argumentos posicionales en la coincidencia de patrones de " +"clase" #: ../Doc/reference/datamodel.rst:2822 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" -" without special support in ``MyClass``. To be able to use that kind of " +"are not allowed by default, i.e. ``case MyClass(x, y)`` is typically invalid " +"without special support in ``MyClass``. To be able to use that kind of " "patterns, the class needs to define a *__match_args__* attribute." msgstr "" "Cuando se usa un nombre de clase en un patrón, los argumentos posicionales " "en el patrón no están permitidos de forma predeterminada, es decir, ``case " "MyClass(x, y)`` generalmente no es válido sin soporte especial en " -"``MyClass``. Para poder usar ese tipo de patrones, la clase necesita definir" -" un atributo *__match_args__*." +"``MyClass``. Para poder usar ese tipo de patrones, la clase necesita definir " +"un atributo *__match_args__*." #: ../Doc/reference/datamodel.rst:2829 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 " "will be converted into a keyword argument, using the corresponding value in " -"*__match_args__* as the keyword. The absence of this attribute is equivalent" -" to setting it to ``()``." +"*__match_args__* as the keyword. The absence of this attribute is equivalent " +"to setting it to ``()``." msgstr "" "A esta variable de clase se le puede asignar una tupla de cadenas. Cuando " "esta clase se utiliza en un patrón de clase con argumentos posicionales, " @@ -4810,14 +4775,14 @@ msgid "" "\"right\")`` that means that ``case MyClass(x, y)`` is equivalent to ``case " "MyClass(left=x, center=y)``. Note that the number of arguments in the " "pattern must be smaller than or equal to the number of elements in " -"*__match_args__*; if it is larger, the pattern match attempt will raise a " -":exc:`TypeError`." +"*__match_args__*; if it is larger, the pattern match attempt will raise a :" +"exc:`TypeError`." msgstr "" "Por ejemplo, si ``MyClass.__match_args__`` es ``(\"left\", \"center\", " "\"right\")`` eso significa que ``case MyClass(x, y)`` es equivalente a " "``case MyClass(left=x, center=y)``. Ten en cuenta que el número de " -"argumentos en el patrón debe ser menor o igual que el número de elementos en" -" *__match_args__*; si es más grande, el intento de coincidencia de patrón " +"argumentos en el patrón debe ser menor o igual que el número de elementos en " +"*__match_args__*; si es más grande, el intento de coincidencia de patrón " "producirá un :exc:`TypeError`." #: ../Doc/reference/datamodel.rst:2845 @@ -4856,14 +4821,14 @@ msgstr "" "La razón de este comportamiento radica en una serie de métodos especiales, " "como :meth:`~object.__hash__` y :meth:`~object.__repr__`, que implementan " "todos los objetos, incluidos los objetos de tipo. Si la búsqueda implícita " -"de estos métodos usara el proceso de búsqueda convencional, fallarían cuando" -" se invocaran en el objeto de tipo en sí:" +"de estos métodos usara el proceso de búsqueda convencional, fallarían cuando " +"se invocaran en el objeto de tipo en sí:" #: ../Doc/reference/datamodel.rst:2883 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" -" the instance when looking up special methods::" +"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 " +"the instance when looking up special methods::" msgstr "" "Intentar invocar de manera incorrecta el método no ligado de una clase de " "esta forma a veces es denominado como ‘confusión de metaclase’, y se evita " @@ -4872,8 +4837,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2892 msgid "" "In addition to bypassing any instance attributes in the interest of " -"correctness, implicit special method lookup generally also bypasses the " -":meth:`~object.__getattribute__` method even of the object's metaclass::" +"correctness, implicit special method lookup generally also bypasses the :" +"meth:`~object.__getattribute__` method even of the object's metaclass::" msgstr "" "Además de omitir cualquier atributo de instancia en aras de la corrección, " "la búsqueda implícita de métodos especiales generalmente también omite el " @@ -4890,8 +4855,8 @@ msgstr "" "Eludir la maquinaria :meth:`~object.__getattribute__` de esta manera " "proporciona un alcance significativo para las optimizaciones de velocidad " "dentro del intérprete, a costa de cierta flexibilidad en el manejo de " -"métodos especiales (el método especial *must* debe establecerse en el objeto" -" de clase en sí mismo para que el intérprete lo invoque de manera " +"métodos especiales (el método especial *must* debe establecerse en el objeto " +"de clase en sí mismo para que el intérprete lo invoque de manera " "consistente). )." #: ../Doc/reference/datamodel.rst:2929 @@ -4904,29 +4869,29 @@ msgstr "Objetos esperables" #: ../Doc/reference/datamodel.rst:2935 msgid "" -"An :term:`awaitable` object generally implements an " -":meth:`~object.__await__` method. :term:`Coroutine objects ` " -"returned from :keyword:`async def` functions are awaitable." +"An :term:`awaitable` object generally implements an :meth:`~object." +"__await__` method. :term:`Coroutine objects ` returned from :" +"keyword:`async def` functions are awaitable." msgstr "" -"Un objeto :term:`awaitable` generalmente implementa un método " -":meth:`~object.__await__`. Las funciones :term:`Coroutine objects " -"` devueltas desde :keyword:`async def` están en espera." +"Un objeto :term:`awaitable` generalmente implementa un método :meth:`~object." +"__await__`. Las funciones :term:`Coroutine objects ` devueltas " +"desde :keyword:`async def` están en espera." #: ../Doc/reference/datamodel.rst:2941 msgid "" "The :term:`generator iterator` objects returned from generators decorated " -"with :func:`types.coroutine` are also awaitable, but they do not implement " -":meth:`~object.__await__`." +"with :func:`types.coroutine` are also awaitable, but they do not implement :" +"meth:`~object.__await__`." msgstr "" "Los objetos :term:`generator iterator` devueltos por generadores decorados " -"con :func:`types.coroutine` también están disponibles, pero no implementan " -":meth:`~object.__await__`." +"con :func:`types.coroutine` también están disponibles, pero no implementan :" +"meth:`~object.__await__`." #: ../Doc/reference/datamodel.rst:2947 msgid "" -"Must return an :term:`iterator`. Should be used to implement " -":term:`awaitable` objects. For instance, :class:`asyncio.Future` implements" -" this method to be compatible with the :keyword:`await` expression." +"Must return an :term:`iterator`. Should be used to implement :term:" +"`awaitable` objects. For instance, :class:`asyncio.Future` implements this " +"method to be compatible with the :keyword:`await` expression." msgstr "" "Debe retornar un :term:`iterator`. Debe ser utilizado para implementar " "objetos :term:`awaitable`. Por ejemplo, :class:`asyncio.Future` implementa " @@ -4943,21 +4908,21 @@ msgstr "Objetos de corrutina" #: ../Doc/reference/datamodel.rst:2961 msgid "" ":term:`Coroutine objects ` are :term:`awaitable` objects. A " -"coroutine's execution can be controlled by calling :meth:`~object.__await__`" -" and iterating over the result. When the coroutine has finished executing " -"and returns, the iterator raises :exc:`StopIteration`, and the exception's " -":attr:`~StopIteration.value` attribute holds the return value. If the " -"coroutine raises an exception, it is propagated by the iterator. Coroutines" -" should not directly raise unhandled :exc:`StopIteration` exceptions." +"coroutine's execution can be controlled by calling :meth:`~object.__await__` " +"and iterating over the result. When the coroutine has finished executing " +"and returns, the iterator raises :exc:`StopIteration`, and the exception's :" +"attr:`~StopIteration.value` attribute holds the return value. If the " +"coroutine raises an exception, it is propagated by the iterator. Coroutines " +"should not directly raise unhandled :exc:`StopIteration` exceptions." msgstr "" ":term:`Coroutine objects ` son objetos :term:`awaitable`. La " -"ejecución de una rutina se puede controlar llamando a " -":meth:`~object.__await__` e iterando sobre el resultado. Cuando la corrutina" -" ha terminado de ejecutarse y regresa, el iterador genera " -":exc:`StopIteration` y el atributo :attr:`~StopIteration.value` de la " -"excepción contiene el valor de retorno. Si la rutina genera una excepción, " -"el iterador la propaga. Las corrutinas no deben generar directamente " -"excepciones :exc:`StopIteration` no controladas." +"ejecución de una rutina se puede controlar llamando a :meth:`~object." +"__await__` e iterando sobre el resultado. Cuando la corrutina ha terminado " +"de ejecutarse y regresa, el iterador genera :exc:`StopIteration` y el " +"atributo :attr:`~StopIteration.value` de la excepción contiene el valor de " +"retorno. Si la rutina genera una excepción, el iterador la propaga. Las " +"corrutinas no deben generar directamente excepciones :exc:`StopIteration` no " +"controladas." #: ../Doc/reference/datamodel.rst:2969 msgid "" @@ -4978,18 +4943,18 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2979 msgid "" "Starts or resumes execution of the coroutine. If *value* is ``None``, this " -"is equivalent to advancing the iterator returned by " -":meth:`~object.__await__`. If *value* is not ``None``, this method " -"delegates to the :meth:`~generator.send` method of the iterator that caused " -"the coroutine to suspend. The result (return value, :exc:`StopIteration`, " -"or other exception) is the same as when iterating over the :meth:`__await__`" -" return value, described above." +"is equivalent to advancing the iterator returned by :meth:`~object." +"__await__`. If *value* is not ``None``, this method delegates to the :meth:" +"`~generator.send` method of the iterator that caused the coroutine to " +"suspend. The result (return value, :exc:`StopIteration`, or other " +"exception) is the same as when iterating over the :meth:`__await__` return " +"value, described above." msgstr "" "Inicia o reanuda la ejecución de la rutina. Si *value* es ``None``, esto " "equivale a avanzar el iterador devuelto por :meth:`~object.__await__`. Si " -"*value* no es ``None``, este método delega al método :meth:`~generator.send`" -" del iterador que provocó la suspensión de la rutina. El resultado (valor de" -" retorno, :exc:`StopIteration` u otra excepción) es el mismo que cuando se " +"*value* no es ``None``, este método delega al método :meth:`~generator.send` " +"del iterador que provocó la suspensión de la rutina. El resultado (valor de " +"retorno, :exc:`StopIteration` u otra excepción) es el mismo que cuando se " "itera sobre el valor de retorno :meth:`__await__`, descrito anteriormente." #: ../Doc/reference/datamodel.rst:2990 @@ -4997,17 +4962,17 @@ msgid "" "Raises the specified exception in the coroutine. This method delegates to " "the :meth:`~generator.throw` method of the iterator that caused the " "coroutine to suspend, if it has such a method. Otherwise, the exception is " -"raised at the suspension point. The result (return value, " -":exc:`StopIteration`, or other exception) is the same as when iterating over" -" the :meth:`~object.__await__` return value, described above. If the " -"exception is not caught in the coroutine, it propagates back to the caller." +"raised at the suspension point. The result (return value, :exc:" +"`StopIteration`, or other exception) is the same as when iterating over the :" +"meth:`~object.__await__` return value, described above. If the exception is " +"not caught in the coroutine, it propagates back to the caller." msgstr "" "Genera la excepción especificada en la rutina. Este método delega en el " -"método :meth:`~generator.throw` del iterador que provocó la suspensión de la" -" rutina, si tiene dicho método. De lo contrario, la excepción se plantea en " -"el punto de suspensión. El resultado (valor de retorno, :exc:`StopIteration`" -" u otra excepción) es el mismo que cuando se itera sobre el valor de retorno" -" :meth:`~object.__await__`, descrito anteriormente. Si la excepción no se " +"método :meth:`~generator.throw` del iterador que provocó la suspensión de la " +"rutina, si tiene dicho método. De lo contrario, la excepción se plantea en " +"el punto de suspensión. El resultado (valor de retorno, :exc:`StopIteration` " +"u otra excepción) es el mismo que cuando se itera sobre el valor de retorno :" +"meth:`~object.__await__`, descrito anteriormente. Si la excepción no se " "detecta en la rutina, se propaga de nuevo a la persona que llama." #: ../Doc/reference/datamodel.rst:3001 @@ -5016,20 +4981,20 @@ msgid "" "suspended, this method first delegates to the :meth:`~generator.close` " "method of the iterator that caused the coroutine to suspend, if it has such " "a method. Then it raises :exc:`GeneratorExit` at the suspension point, " -"causing the coroutine to immediately clean itself up. Finally, the coroutine" -" is marked as having finished executing, even if it was never started." +"causing the coroutine to immediately clean itself up. Finally, the coroutine " +"is marked as having finished executing, even if it was never started." msgstr "" "Causa que la corrutina misma se borre a sí misma y termine su ejecución. Si " -"la corrutina es suspendida, este método primero delega a " -":meth:`~generator.close`, si existe, del iterador que causó la suspensión de" -" la corrutina. Luego lanza una excepción :exc:`GeneratorExit` en el punto de" -" suspensión, causando que la corrutina se borre a sí misma. Finalmente, la " -"corrutina es marcada como completada, aún si nunca inició." +"la corrutina es suspendida, este método primero delega a :meth:`~generator." +"close`, si existe, del iterador que causó la suspensión de la corrutina. " +"Luego lanza una excepción :exc:`GeneratorExit` en el punto de suspensión, " +"causando que la corrutina se borre a sí misma. Finalmente, la corrutina es " +"marcada como completada, aún si nunca inició." #: ../Doc/reference/datamodel.rst:3009 msgid "" -"Coroutine objects are automatically closed using the above process when they" -" are about to be destroyed." +"Coroutine objects are automatically closed using the above process when they " +"are about to be destroyed." msgstr "" "Objetos de corrutina son cerrados automáticamente utilizando el proceso " "anterior cuando están a punto de ser destruidos." @@ -5050,8 +5015,8 @@ msgstr "" msgid "" "Asynchronous iterators can be used in an :keyword:`async for` statement." msgstr "" -"Iteradores asíncronos pueden ser utilizados en la declaración " -":keyword:`async for`." +"Iteradores asíncronos pueden ser utilizados en la declaración :keyword:" +"`async for`." #: ../Doc/reference/datamodel.rst:3024 msgid "Must return an *asynchronous iterator* object." @@ -5076,15 +5041,15 @@ msgid "" "that would resolve to an :term:`asynchronous iterator `." msgstr "" -"Antes de Python 3.7, :meth:`~object.__aiter__` podía devolver un *awaitable*" -" que se resolvería en un :term:`asynchronous iterator `." #: ../Doc/reference/datamodel.rst:3053 msgid "" "Starting with Python 3.7, :meth:`~object.__aiter__` must return an " -"asynchronous iterator object. Returning anything else will result in a " -":exc:`TypeError` error." +"asynchronous iterator object. Returning anything else will result in a :exc:" +"`TypeError` error." msgstr "" "A partir de Python 3.7, :meth:`~object.__aiter__` debe devolver un objeto " "iterador asíncrono. Devolver cualquier otra cosa dará como resultado un " @@ -5107,13 +5072,13 @@ msgid "" "Asynchronous context managers can be used in an :keyword:`async with` " "statement." msgstr "" -"Los gestores de contexto asíncronos pueden ser utilizados en una declaración" -" :keyword:`async with`." +"Los gestores de contexto asíncronos pueden ser utilizados en una " +"declaración :keyword:`async with`." #: ../Doc/reference/datamodel.rst:3070 msgid "" -"Semantically similar to :meth:`__enter__`, the only difference being that it" -" must return an *awaitable*." +"Semantically similar to :meth:`__enter__`, the only difference being that it " +"must return an *awaitable*." msgstr "" "Semánticamente similar a :meth:`__enter__`, siendo la única diferencia que " "debe retorna un *esperable*." @@ -5141,27 +5106,26 @@ msgid "" "lead to some very strange behaviour if it is handled incorrectly." msgstr "" "Es posible cambiar en algunos casos un tipo de objeto bajo ciertas " -"circunstancias controladas. Generalmente no es buena idea, ya que esto puede" -" llevar a un comportamiento bastante extraño de no ser tratado " -"correctamente." +"circunstancias controladas. Generalmente no es buena idea, ya que esto puede " +"llevar a un comportamiento bastante extraño de no ser tratado correctamente." #: ../Doc/reference/datamodel.rst:3096 msgid "" -"The :meth:`~object.__hash__`, :meth:`~object.__iter__`, " -":meth:`~object.__reversed__`, and :meth:`~object.__contains__` methods have " -"special handling for this; others will still raise a :exc:`TypeError`, but " -"may do so by relying on the behavior that ``None`` is not callable." +"The :meth:`~object.__hash__`, :meth:`~object.__iter__`, :meth:`~object." +"__reversed__`, and :meth:`~object.__contains__` methods have special " +"handling for this; others will still raise a :exc:`TypeError`, but may do so " +"by relying on the behavior that ``None`` is not callable." msgstr "" -"Los métodos :meth:`~object.__hash__`, :meth:`~object.__iter__`, " -":meth:`~object.__reversed__` y :meth:`~object.__contains__` tienen un manejo" -" especial para esto; otros aún generarán un :exc:`TypeError`, pero pueden " +"Los métodos :meth:`~object.__hash__`, :meth:`~object.__iter__`, :meth:" +"`~object.__reversed__` y :meth:`~object.__contains__` tienen un manejo " +"especial para esto; otros aún generarán un :exc:`TypeError`, pero pueden " "hacerlo confiando en el comportamiento de que ``None`` no es invocable." #: ../Doc/reference/datamodel.rst:3102 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" -" want to force fallback to the right operand's reflected method—that will " +"method returns ``NotImplemented``. Do not set the method to ``None`` if you " +"want to force fallback to the right operand's reflected method—that will " "instead have the opposite effect of explicitly *blocking* such fallback." msgstr "" "“No soporta” aquí significa que la clase no tiene tal método, o el método " @@ -5176,6 +5140,6 @@ msgid "" "method -- such as :meth:`~object.__add__` -- fails then the overall " "operation is not supported, which is why the reflected method is not called." msgstr "" -"Para operandos del mismo tipo, se supone que si el método no reflejado, como" -" :meth:`~object.__add__`, falla, la operación general no es compatible, por " -"lo que no se llama al método reflejado." +"Para operandos del mismo tipo, se supone que si el método no reflejado, " +"como :meth:`~object.__add__`, falla, la operación general no es compatible, " +"por lo que no se llama al método reflejado." From 76cbd360e720921b1c4ab83deae677d8bbb33321 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cristi=C3=A1n=20Maureira-Fredes?= Date: Tue, 9 May 2023 21:07:50 +0200 Subject: [PATCH 3/5] powrap --- reference/datamodel.po | 46 +++++++++++++++++++++--------------------- 1 file changed, 23 insertions(+), 23 deletions(-) diff --git a/reference/datamodel.po b/reference/datamodel.po index ecbe9538ca..7725e8111b 100644 --- a/reference/datamodel.po +++ b/reference/datamodel.po @@ -279,7 +279,7 @@ msgid "" msgstr "" "Este tipo tiene un solo valor. Hay un solo objeto con este valor. Se accede " "a este objeto a través del nombre integrado ``NotImplemented``. Los métodos " -"numéricos y los métodos de comparación enriquecidos deben devolver este " +"numéricos y los métodos de comparación enriquecidos deben retornar este " "valor si no implementan la operación para los operandos proporcionados. (El " "intérprete intentará entonces la operación reflejada, o alguna otra " "alternativa, dependiendo del operador). No debe evaluarse en un contexto " @@ -1193,13 +1193,13 @@ msgid "" msgstr "" "Una función o método que utiliza la instrucción :keyword:`yield` (consulte " "la sección :ref:`yield`) se denomina :dfn:`función generadora`. Una función " -"de este tipo, cuando se llama, siempre devuelve un objeto :term:`iterator` " +"de este tipo, cuando se llama, siempre retorna un objeto :term:`iterator` " "que se puede usar para ejecutar el cuerpo de la función: llamar al método :" "meth:`iterator.__next__` del iterador hará que la función se ejecute hasta " "que proporcione un valor usando la declaración :keyword:`!yield`. Cuando la " "función ejecuta una declaración :keyword:`return` o se cae del final, se " "genera una excepción :exc:`StopIteration` y el iterador habrá llegado al " -"final del conjunto de valores que se devolverán." +"final del conjunto de valores que se retornarán." #: ../Doc/reference/datamodel.rst:667 msgid "Coroutine functions" @@ -1233,8 +1233,8 @@ msgid "" msgstr "" "Una función o método que se define utilizando :keyword:`async def` y que " "utiliza la instrucción :keyword:`yield` se denomina :dfn:`función de " -"generador asíncrono`. Cuando se llama a una función de este tipo, devuelve " -"un objeto :term:`asynchronous iterator` que se puede utilizar en una " +"generador asíncrono`. Cuando se llama a una función de este tipo, retorna un " +"objeto :term:`asynchronous iterator` que se puede utilizar en una " "instrucción :keyword:`async for` para ejecutar el cuerpo de la función." #: ../Doc/reference/datamodel.rst:680 @@ -1248,7 +1248,7 @@ msgid "" "yielded." msgstr "" "Llamar al método :meth:`aiterator.__anext__ ` del iterador " -"asíncrono devolverá un :term:`awaitable` que, cuando se espera, se ejecutará " +"asíncrono retornará un :term:`awaitable` que, cuando se espera, se ejecutará " "hasta que proporcione un valor mediante la expresión :keyword:`yield`. " "Cuando la función ejecuta una declaración :keyword:`return` vacía o se cae " "del final, se genera una excepción :exc:`StopAsyncIteration` y el iterador " @@ -1779,7 +1779,7 @@ msgid "" "Returns an iterable over the source code positions of each bytecode " "instruction in the code object." msgstr "" -"Devuelve un iterable sobre las posiciones del código fuente de cada " +"retorna un iterable sobre las posiciones del código fuente de cada " "instrucción de código de bytes en el objeto de código." #: ../Doc/reference/datamodel.rst:1024 @@ -1789,7 +1789,7 @@ msgid "" "the source code that compiled to the *i-th* instruction. Column information " "is 0-indexed utf-8 byte offsets on the given source line." msgstr "" -"El iterador devuelve tuplas que contienen ``(start_line, end_line, " +"El iterador retorna tuplas que contienen ``(start_line, end_line, " "start_column, end_column)``. La tupla *i-th* corresponde a la posición del " "código fuente que se compiló en la instrucción *i-th*. La información de la " "columna son compensaciones de utf-8 bytes indexadas en 0 en la línea de " @@ -2224,7 +2224,7 @@ msgstr "" "Las implementaciones típicas crean una nueva instancia de la clase invocando " "el método :meth:`__new__` de la superclase usando ``super()." "__new__(cls[, ...])`` con los argumentos apropiados y luego modificando la " -"instancia recién creada según sea necesario antes de devolverla." +"instancia recién creada según sea necesario antes de retornarla." #: ../Doc/reference/datamodel.rst:1276 msgid "" @@ -2619,7 +2619,7 @@ msgid "" msgstr "" "Llamado por la función integrada :func:`hash` y para operaciones en miembros " "de colecciones con hash, incluidos :class:`set`, :class:`frozenset` y :class:" -"`dict`. El método ``__hash__()`` debería devolver un número entero. La única " +"`dict`. El método ``__hash__()`` debería retornar un número entero. La única " "propiedad requerida es que los objetos que se comparan iguales tengan el " "mismo valor hash; se recomienda mezclar los valores hash de los componentes " "del objeto que también desempeñan un papel en la comparación de los objetos, " @@ -3225,8 +3225,8 @@ msgid "" "__get__(a, A)``. If not a descriptor, ``x`` is returned unchanged." msgstr "" "Una búsqueda punteada como ``super(A, a).x`` busca en ``a.__class__." -"__mro__`` una clase base ``B`` después de ``A`` y luego devuelve ``B." -"__dict__['x'].__get__(a, A)``. Si no es un descriptor, ``x`` se devuelve sin " +"__mro__`` una clase base ``B`` después de ``A`` y luego retorna ``B." +"__dict__['x'].__get__(a, A)``. Si no es un descriptor, ``x`` se retorna sin " "cambios." #: ../Doc/reference/datamodel.rst:1862 @@ -3249,7 +3249,7 @@ msgstr "" "descriptor depende de qué métodos de descriptor se definan. Un descriptor " "puede definir cualquier combinación de :meth:`~object.__get__`, :meth:" "`~object.__set__` y :meth:`~object.__delete__`. Si no define :meth:" -"`__get__`, el acceso al atributo devolverá el objeto descriptor en sí, a " +"`__get__`, el acceso al atributo retornará el objeto descriptor en sí, a " "menos que haya un valor en el diccionario de instancias del objeto. Si el " "descriptor define :meth:`__set__` y/o :meth:`__delete__`, es un descriptor " "de datos; si no define ninguno, es un descriptor que no es de datos. " @@ -3704,7 +3704,7 @@ msgstr "" "se llama ``namespace = metaclass.__prepare__(name, bases, **kwds)`` (donde " "los argumentos de palabras clave adicionales, si los hay, provienen de la " "definición de clase). El método ``__prepare__`` debe implementarse como :" -"func:`classmethod `. El espacio de nombres devuelto por " +"func:`classmethod `. El espacio de nombres retornado por " "``__prepare__`` se pasa a ``__new__``, pero cuando se crea el objeto de " "clase final, el espacio de nombres se copia en un nuevo ``dict``." @@ -4099,7 +4099,7 @@ msgstr "" "corchetes llamará al método de instancia :meth:`~object.__getitem__` " "definido en la clase del objeto. Sin embargo, si el objeto que se suscribe " "es en sí mismo una clase, se puede llamar al método de clase :meth:`~object." -"__class_getitem__` en su lugar. ``__class_getitem__()`` debería devolver un " +"__class_getitem__` en su lugar. ``__class_getitem__()`` debería retornar un " "objeto :ref:`GenericAlias` si está definido " "correctamente." @@ -4391,7 +4391,7 @@ msgid "" "of the container." msgstr "" "Se llama a este método cuando se requiere un :term:`iterator` para un " -"contenedor. Este método debería devolver un nuevo objeto iterador que pueda " +"contenedor. Este método debería retornar un nuevo objeto iterador que pueda " "iterar sobre todos los objetos del contenedor. Para las asignaciones, debe " "iterar sobre las claves del contenedor." @@ -4525,7 +4525,7 @@ msgstr "" "diferentes tipos. [#]_ Por ejemplo, para evaluar la expresión ``x - y``, " "donde *y* es una instancia de una clase que tiene un método :meth:" "`__rsub__`, se llama a ``type(y).__rsub__(y, x)`` si ``type(x).__sub__(x, " -"y)`` devuelve *NotImplemented*." +"y)`` retorna *NotImplemented*." #: ../Doc/reference/datamodel.rst:2669 msgid "" @@ -4874,7 +4874,7 @@ msgid "" "keyword:`async def` functions are awaitable." msgstr "" "Un objeto :term:`awaitable` generalmente implementa un método :meth:`~object." -"__await__`. Las funciones :term:`Coroutine objects ` devueltas " +"__await__`. Las funciones :term:`Coroutine objects ` retornadas " "desde :keyword:`async def` están en espera." #: ../Doc/reference/datamodel.rst:2941 @@ -4883,7 +4883,7 @@ msgid "" "with :func:`types.coroutine` are also awaitable, but they do not implement :" "meth:`~object.__await__`." msgstr "" -"Los objetos :term:`generator iterator` devueltos por generadores decorados " +"Los objetos :term:`generator iterator` retornados por generadores decorados " "con :func:`types.coroutine` también están disponibles, pero no implementan :" "meth:`~object.__await__`." @@ -4951,7 +4951,7 @@ msgid "" "value, described above." msgstr "" "Inicia o reanuda la ejecución de la rutina. Si *value* es ``None``, esto " -"equivale a avanzar el iterador devuelto por :meth:`~object.__await__`. Si " +"equivale a avanzar el iterador retornado por :meth:`~object.__await__`. Si " "*value* no es ``None``, este método delega al método :meth:`~generator.send` " "del iterador que provocó la suspensión de la rutina. El resultado (valor de " "retorno, :exc:`StopIteration` u otra excepción) es el mismo que cuando se " @@ -5041,7 +5041,7 @@ msgid "" "that would resolve to an :term:`asynchronous iterator `." msgstr "" -"Antes de Python 3.7, :meth:`~object.__aiter__` podía devolver un *awaitable* " +"Antes de Python 3.7, :meth:`~object.__aiter__` podía retornar un *awaitable* " "que se resolvería en un :term:`asynchronous iterator `." @@ -5051,8 +5051,8 @@ msgid "" "asynchronous iterator object. Returning anything else will result in a :exc:" "`TypeError` error." msgstr "" -"A partir de Python 3.7, :meth:`~object.__aiter__` debe devolver un objeto " -"iterador asíncrono. Devolver cualquier otra cosa dará como resultado un " +"A partir de Python 3.7, :meth:`~object.__aiter__` debe retornar un objeto " +"iterador asíncrono. retornar cualquier otra cosa dará como resultado un " "error :exc:`TypeError`." #: ../Doc/reference/datamodel.rst:3061 From 3066ec1e9559f0956086a25f8c5b2dc0cc230f10 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cristi=C3=A1n=20Maureira-Fredes?= Date: Fri, 5 Jan 2024 11:07:02 +0100 Subject: [PATCH 4/5] Translating last entries and adding new words --- dictionaries/reference_datamodel.txt | 10 + reference/datamodel.po | 2869 +++++++++++++++----------- 2 files changed, 1652 insertions(+), 1227 deletions(-) diff --git a/dictionaries/reference_datamodel.txt b/dictionaries/reference_datamodel.txt index 1aefc2b7b2..54eab3418d 100644 --- a/dictionaries/reference_datamodel.txt +++ b/dictionaries/reference_datamodel.txt @@ -1,4 +1,14 @@ +argcount awaitable +classcell +consts empaquetándolos +firstlineno +kwdefaults +lasti +nlocals objects +posonlyargcount +stacksize +varnames zero diff --git a/reference/datamodel.po b/reference/datamodel.po index 5eac921325..815165451a 100644 --- a/reference/datamodel.po +++ b/reference/datamodel.po @@ -36,9 +36,9 @@ msgid "" "computer\", code is also represented by objects.)" msgstr "" ":dfn:`Objects` son la abstracción de Python para los datos. Todos los datos " -"en un programa Python están representados por objetos o por relaciones entre " -"objetos. (En cierto sentido y de conformidad con el modelo de Von Neumann de " -"una \"programa almacenado de computadora\", el código también está " +"en un programa Python están representados por objetos o por relaciones entre" +" objetos. (En cierto sentido y de conformidad con el modelo de Von Neumann " +"de una \"programa almacenado de computadora\", el código también está " "representado por objetos.)" #: ../Doc/reference/datamodel.rst:35 @@ -50,10 +50,10 @@ msgid "" "identity." msgstr "" "Cada objeto tiene una identidad, un tipo y un valor. La *identidad* de un " -"objeto nunca cambia una vez que ha sido creado; puede pensar en ello como la " -"dirección del objeto en la memoria. El operador ':keyword:`is`' compara la " -"identidad de dos objetos; la función :func:`id` retorna un número entero que " -"representa su identidad." +"objeto nunca cambia una vez que ha sido creado; puede pensar en ello como la" +" dirección del objeto en la memoria. El operador ':keyword:`is`' compara la " +"identidad de dos objetos; la función :func:`id` retorna un número entero que" +" representa su identidad." #: ../Doc/reference/datamodel.rst:42 msgid "For CPython, ``id(x)`` is the memory address where ``x`` is stored." @@ -63,16 +63,16 @@ msgstr "" #: ../Doc/reference/datamodel.rst:44 msgid "" "An object's type determines the operations that the object supports (e.g., " -"\"does it have a length?\") and also defines the possible values for objects " -"of that type. The :func:`type` function returns an object's type (which is " -"an object itself). Like its identity, an object's :dfn:`type` is also " +"\"does it have a length?\") and also defines the possible values for objects" +" of that type. The :func:`type` function returns an object's type (which is" +" an object itself). Like its identity, an object's :dfn:`type` is also " "unchangeable. [#]_" msgstr "" "El tipo de un objeto determina las operaciones que admite el objeto (por " "ejemplo, \"¿tiene una longitud?\") y también define los posibles valores " "para los objetos de ese tipo. La función :func:`type` retorna el tipo de un " -"objeto (que es un objeto en sí mismo). Al igual que su identidad, también " -"el :dfn:`type` de un objeto es inmutable. [#]_" +"objeto (que es un objeto en sí mismo). Al igual que su identidad, también el" +" :dfn:`type` de un objeto es inmutable. [#]_" #: ../Doc/reference/datamodel.rst:50 msgid "" @@ -82,8 +82,8 @@ msgid "" "that contains a reference to a mutable object can change when the latter's " "value is changed; however the container is still considered immutable, " "because the collection of objects it contains cannot be changed. So, " -"immutability is not strictly the same as having an unchangeable value, it is " -"more subtle.) An object's mutability is determined by its type; for " +"immutability is not strictly the same as having an unchangeable value, it is" +" more subtle.) An object's mutability is determined by its type; for " "instance, numbers, strings and tuples are immutable, while dictionaries and " "lists are mutable." msgstr "" @@ -96,8 +96,8 @@ msgstr "" "que contiene no se puede cambiar. Por lo tanto, la inmutabilidad no es " "estrictamente lo mismo que tener un valor inmutable, es más sutil). La " "mutabilidad de un objeto está determinada por su tipo; por ejemplo, los " -"números, las cadenas de caracteres y las tuplas son inmutables, mientras que " -"los diccionarios y las listas son mutables." +"números, las cadenas de caracteres y las tuplas son inmutables, mientras que" +" los diccionarios y las listas son mutables." #: ../Doc/reference/datamodel.rst:65 msgid "" @@ -109,10 +109,10 @@ msgid "" msgstr "" "Los objetos nunca se destruyen explícitamente; sin embargo, cuando se " "vuelven inalcanzables, se pueden recolectar basura. Se permite a una " -"implementación posponer la recolección de basura u omitirla por completo; es " -"una cuestión de calidad de la implementación cómo se implementa la " -"recolección de basura, siempre que no se recolecten objetos que todavía sean " -"accesibles." +"implementación posponer la recolección de basura u omitirla por completo; es" +" una cuestión de calidad de la implementación cómo se implementa la " +"recolección de basura, siempre que no se recolecten objetos que todavía sean" +" accesibles." #: ../Doc/reference/datamodel.rst:73 msgid "" @@ -145,35 +145,36 @@ msgstr "" "Tenga en cuenta que el uso de las funciones de rastreo o depuración de la " "implementación puede mantener activos los objetos que normalmente serían " "coleccionables. También tenga en cuenta que la captura de una excepción con " -"una sentencia ':keyword:`try`...\\ :keyword:`except`' puede mantener objetos " -"activos." +"una sentencia ':keyword:`try`...\\ :keyword:`except`' puede mantener objetos" +" activos." #: ../Doc/reference/datamodel.rst:87 msgid "" -"Some objects contain references to \"external\" resources such as open files " -"or windows. It is understood that these resources are freed when the object " -"is garbage-collected, but since garbage collection is not guaranteed to " -"happen, such objects also provide an explicit way to release the external " -"resource, usually a :meth:`close` method. Programs are strongly recommended " -"to explicitly close such objects. The ':keyword:`try`...\\ :keyword:" -"`finally`' statement and the ':keyword:`with`' statement provide convenient " -"ways to do this." +"Some objects contain references to \"external\" resources such as open files" +" or windows. It is understood that these resources are freed when the " +"object is garbage-collected, but since garbage collection is not guaranteed " +"to happen, such objects also provide an explicit way to release the external" +" resource, usually a :meth:`close` method. Programs are strongly recommended" +" to explicitly close such objects. The ':keyword:`try`...\\ " +":keyword:`finally`' statement and the ':keyword:`with`' statement provide " +"convenient ways to do this." msgstr "" "Algunos objetos contienen referencias a recursos \"externos\" como archivos " "abiertos o ventanas. Se entiende que estos recursos se liberan cuando el " "objeto es eliminado por el recolector de basura, pero como no se garantiza " -"que la recolección de basura suceda, dichos objetos también proporcionan una " -"forma explícita de liberar el recurso externo, generalmente un método :meth:" -"`close`. Se recomienda encarecidamente a los programas cerrar explícitamente " -"dichos objetos. La declaración ':keyword:`try`...\\ :keyword:`finally`' y la " -"declaración ':keyword:`with`' proporcionan formas convenientes de hacer esto." +"que la recolección de basura suceda, dichos objetos también proporcionan una" +" forma explícita de liberar el recurso externo, generalmente un método " +":meth:`close`. Se recomienda encarecidamente a los programas cerrar " +"explícitamente dichos objetos. La declaración ':keyword:`try`...\\ " +":keyword:`finally`' y la declaración ':keyword:`with`' proporcionan formas " +"convenientes de hacer esto." #: ../Doc/reference/datamodel.rst:97 msgid "" "Some objects contain references to other objects; these are called " "*containers*. Examples of containers are tuples, lists and dictionaries. " -"The references are part of a container's value. In most cases, when we talk " -"about the value of a container, we imply the values, not the identities of " +"The references are part of a container's value. In most cases, when we talk" +" about the value of a container, we imply the values, not the identities of " "the contained objects; however, when we talk about the mutability of a " "container, only the identities of the immediately contained objects are " "implied. So, if an immutable container (like a tuple) contains a reference " @@ -195,9 +196,9 @@ msgid "" "object identity is affected in some sense: for immutable types, operations " "that compute new values may actually return a reference to any existing " "object with the same type and value, while for mutable objects this is not " -"allowed. E.g., after ``a = 1; b = 1``, ``a`` and ``b`` may or may not refer " -"to the same object with the value one, depending on the implementation, but " -"after ``c = []; d = []``, ``c`` and ``d`` are guaranteed to refer to two " +"allowed. E.g., after ``a = 1; b = 1``, ``a`` and ``b`` may or may not refer" +" to the same object with the value one, depending on the implementation, but" +" after ``c = []; d = []``, ``c`` and ``d`` are guaranteed to refer to two " "different, unique, newly created empty lists. (Note that ``c = d = []`` " "assigns the same object to both ``c`` and ``d``.)" msgstr "" @@ -207,11 +208,11 @@ msgstr "" "valores en realidad pueden retornar una referencia a cualquier objeto " "existente con el mismo tipo y valor, mientras que para los objetos mutables " "esto no está permitido. Por ejemplo, al hacer ``a = 1; b = 1``, ``a`` y " -"``b`` puede o no referirse al mismo objeto con el valor 1, dependiendo de la " -"implementación, pero al hacer ``c = []; d = []``, ``c`` y ``d`` se garantiza " -"que se refieren a dos listas vacías diferentes, únicas y recién creadas. " -"(Tenga en cuenta que ``c = d = []`` asigna el mismo objeto a ambos ``c`` y " -"``d``.)" +"``b`` puede o no referirse al mismo objeto con el valor 1, dependiendo de la" +" implementación, pero al hacer ``c = []; d = []``, ``c`` y ``d`` se " +"garantiza que se refieren a dos listas vacías diferentes, únicas y recién " +"creadas. (Tenga en cuenta que ``c = d = []`` asigna el mismo objeto a ambos " +"``c`` y ``d``.)" #: ../Doc/reference/datamodel.rst:120 msgid "The standard type hierarchy" @@ -221,24 +222,24 @@ msgstr "Jerarquía de tipos estándar" msgid "" "Below is a list of the types that are built into Python. Extension modules " "(written in C, Java, or other languages, depending on the implementation) " -"can define additional types. Future versions of Python may add types to the " -"type hierarchy (e.g., rational numbers, efficiently stored arrays of " +"can define additional types. Future versions of Python may add types to the" +" type hierarchy (e.g., rational numbers, efficiently stored arrays of " "integers, etc.), although such additions will often be provided via the " "standard library instead." msgstr "" "A continuación se muestra una lista de los tipos integrados en Python. Los " "módulos de extensión (escritos en C, Java u otros lenguajes, dependiendo de " "la implementación) pueden definir tipos adicionales. Las versiones futuras " -"de Python pueden agregar tipos a la jerarquía de tipos (por ejemplo, números " -"racionales, matrices de enteros almacenados de manera eficiente, etc.), " +"de Python pueden agregar tipos a la jerarquía de tipos (por ejemplo, números" +" racionales, matrices de enteros almacenados de manera eficiente, etc.), " "aunque tales adiciones a menudo se proporcionarán a través de la biblioteca " "estándar." #: ../Doc/reference/datamodel.rst:140 msgid "" "Some of the type descriptions below contain a paragraph listing 'special " -"attributes.' These are attributes that provide access to the implementation " -"and are not intended for general use. Their definition may change in the " +"attributes.' These are attributes that provide access to the implementation" +" and are not intended for general use. Their definition may change in the " "future." msgstr "" "Algunas de las descripciones de tipos a continuación contienen un párrafo " @@ -254,8 +255,8 @@ msgstr "None" msgid "" "This type has a single value. There is a single object with this value. " "This object is accessed through the built-in name ``None``. It is used to " -"signify the absence of a value in many situations, e.g., it is returned from " -"functions that don't explicitly return anything. Its truth value is false." +"signify the absence of a value in many situations, e.g., it is returned from" +" functions that don't explicitly return anything. Its truth value is false." msgstr "" "Este tipo tiene un solo valor. Hay un solo objeto con este valor. Se accede " "a este objeto a través del nombre incorporado ``None``. Se utiliza para " @@ -271,10 +272,10 @@ msgstr "NotImplemented" msgid "" "This type has a single value. There is a single object with this value. " "This object is accessed through the built-in name ``NotImplemented``. " -"Numeric methods and rich comparison methods should return this value if they " -"do not implement the operation for the operands provided. (The interpreter " -"will then try the reflected operation, or some other fallback, depending on " -"the operator.) It should not be evaluated in a boolean context." +"Numeric methods and rich comparison methods should return this value if they" +" do not implement the operation for the operands provided. (The interpreter" +" will then try the reflected operation, or some other fallback, depending on" +" the operator.) It should not be evaluated in a boolean context." msgstr "" "Este tipo tiene un solo valor. Hay un solo objeto con este valor. Se accede " "a este objeto a través del nombre integrado ``NotImplemented``. Los métodos " @@ -295,9 +296,9 @@ msgid "" "will raise a :exc:`TypeError` in a future version of Python." msgstr "" "La evaluación de ``NotImplemented`` en un contexto booleano está en desuso. " -"Si bien actualmente se evalúa como verdadero, lanzará un :exc:" -"`DeprecationWarning`. Lanzará un :exc:`TypeError` en una versión futura de " -"Python." +"Si bien actualmente se evalúa como verdadero, lanzará un " +":exc:`DeprecationWarning`. Lanzará un :exc:`TypeError` en una versión futura" +" de Python." #: ../Doc/reference/datamodel.rst:179 ../Doc/reference/datamodel.rst:180 msgid "Ellipsis" @@ -320,8 +321,8 @@ msgstr ":class:`numbers.Number`" #: ../Doc/reference/datamodel.rst:194 msgid "" "These are created by numeric literals and returned as results by arithmetic " -"operators and arithmetic built-in functions. Numeric objects are immutable; " -"once created their value never changes. Python numbers are of course " +"operators and arithmetic built-in functions. Numeric objects are immutable;" +" once created their value never changes. Python numbers are of course " "strongly related to mathematical numbers, but subject to the limitations of " "numerical representation in computers." msgstr "" @@ -335,12 +336,12 @@ msgstr "" #: ../Doc/reference/datamodel.rst:200 #, fuzzy msgid "" -"The string representations of the numeric classes, computed by :meth:" -"`~object.__repr__` and :meth:`~object.__str__`, have the following " +"The string representations of the numeric classes, computed by " +":meth:`~object.__repr__` and :meth:`~object.__str__`, have the following " "properties:" msgstr "" -"Las representaciones de cadena de las clases numéricas, calculadas por :meth:" -"`~object.__repr__` y :meth:`~object.__str__`, tienen las siguientes " +"Las representaciones de cadena de las clases numéricas, calculadas por " +":meth:`~object.__repr__` y :meth:`~object.__str__`, tienen las siguientes " "propiedades:" #: ../Doc/reference/datamodel.rst:204 @@ -389,8 +390,8 @@ msgstr ":class:`numbers.Integral`" #: ../Doc/reference/datamodel.rst:227 msgid "" -"These represent elements from the mathematical set of integers (positive and " -"negative)." +"These represent elements from the mathematical set of integers (positive and" +" negative)." msgstr "" "Estos representan elementos del conjunto matemático de números enteros " "(positivo y negativo)." @@ -434,18 +435,18 @@ msgstr "Booleanos (:class:`bool`)" #: ../Doc/reference/datamodel.rst:251 msgid "" "These represent the truth values False and True. The two objects " -"representing the values ``False`` and ``True`` are the only Boolean objects. " -"The Boolean type is a subtype of the integer type, and Boolean values behave " -"like the values 0 and 1, respectively, in almost all contexts, the exception " -"being that when converted to a string, the strings ``\"False\"`` or " -"``\"True\"`` are returned, respectively." +"representing the values ``False`` and ``True`` are the only Boolean objects." +" The Boolean type is a subtype of the integer type, and Boolean values " +"behave like the values 0 and 1, respectively, in almost all contexts, the " +"exception being that when converted to a string, the strings ``\"False\"`` " +"or ``\"True\"`` are returned, respectively." msgstr "" "Estos representan los valores de verdad Falso y Verdadero. Los dos objetos " "que representan los valores ``False`` y ``True`` son los únicos objetos " "booleanos. El tipo booleano es un subtipo del tipo entero y los valores " -"booleanos se comportan como los valores 0 y 1 respectivamente, en casi todos " -"los contextos, con la excepción de que cuando se convierten en una cadena de " -"caracteres, las cadenas de caracteres ``\"False\"`` o ``\"True\"`` son " +"booleanos se comportan como los valores 0 y 1 respectivamente, en casi todos" +" los contextos, con la excepción de que cuando se convierten en una cadena " +"de caracteres, las cadenas de caracteres ``\"False\"`` o ``\"True\"`` son " "retornadas respectivamente." #: ../Doc/reference/datamodel.rst:259 @@ -456,11 +457,11 @@ msgstr ":class:`numbers.Real` (:class:`float`)" msgid "" "These represent machine-level double precision floating point numbers. You " "are at the mercy of the underlying machine architecture (and C or Java " -"implementation) for the accepted range and handling of overflow. Python does " -"not support single-precision floating point numbers; the savings in " +"implementation) for the accepted range and handling of overflow. Python does" +" not support single-precision floating point numbers; the savings in " "processor and memory usage that are usually the reason for using these are " -"dwarfed by the overhead of using objects in Python, so there is no reason to " -"complicate the language with two kinds of floating point numbers." +"dwarfed by the overhead of using objects in Python, so there is no reason to" +" complicate the language with two kinds of floating point numbers." msgstr "" "Estos representan números de punto flotante de precisión doble a nivel de " "máquina. Está a merced de la arquitectura de la máquina subyacente (y la " @@ -484,8 +485,8 @@ msgid "" msgstr "" "Estos representan números complejos como un par de números de coma flotante " "de precisión doble a nivel de máquina. Se aplican las mismas advertencias " -"que para los números de coma flotante. Las partes reales e imaginarias de un " -"número complejo ``z`` se pueden obtener a través de los atributos de solo " +"que para los números de coma flotante. Las partes reales e imaginarias de un" +" número complejo ``z`` se pueden obtener a través de los atributos de solo " "lectura ``z.real`` y ``z.imag``." #: ../Doc/reference/datamodel.rst:290 @@ -500,9 +501,9 @@ msgid "" "1, ..., *n*-1. Item *i* of sequence *a* is selected by ``a[i]``." msgstr "" "Estos representan conjuntos ordenados finitos indexados por números no " -"negativos. La función incorporada :func:`len` retorna el número de elementos " -"de una secuencia. Cuando la longitud de una secuencia es *n*, el conjunto de " -"índices contiene los números 0, 1, ..., *n*-1. El elemento *i* de la " +"negativos. La función incorporada :func:`len` retorna el número de elementos" +" de una secuencia. Cuando la longitud de una secuencia es *n*, el conjunto " +"de índices contiene los números 0, 1, ..., *n*-1. El elemento *i* de la " "secuencia *a* se selecciona mediante ``a[i]``." #: ../Doc/reference/datamodel.rst:306 @@ -512,11 +513,11 @@ msgid "" "a sequence of the same type. This implies that the index set is renumbered " "so that it starts at 0." msgstr "" -"Las secuencias también admiten segmentación: ``a[i:j]`` selecciona todos los " -"elementos con índice *k* de modo que *i* ``<=`` *k* ``<`` *j*. Cuando se " +"Las secuencias también admiten segmentación: ``a[i:j]`` selecciona todos los" +" elementos con índice *k* de modo que *i* ``<=`` *k* ``<`` *j*. Cuando se " "usa como una expresión, un segmento es una secuencia del mismo tipo. Esto " -"implica que el conjunto de índices se vuelve a enumerar para que comience en " -"0." +"implica que el conjunto de índices se vuelve a enumerar para que comience en" +" 0." #: ../Doc/reference/datamodel.rst:311 msgid "" @@ -540,15 +541,15 @@ msgstr "Secuencias inmutables" #: ../Doc/reference/datamodel.rst:325 msgid "" "An object of an immutable sequence type cannot change once it is created. " -"(If the object contains references to other objects, these other objects may " -"be mutable and may be changed; however, the collection of objects directly " +"(If the object contains references to other objects, these other objects may" +" be mutable and may be changed; however, the collection of objects directly " "referenced by an immutable object cannot change.)" msgstr "" "Un objeto de un tipo de secuencia inmutable no puede cambiar una vez que se " "crea. (Si el objeto contiene referencias a otros objetos, estos otros " -"objetos pueden ser mutables y pueden cambiarse; sin embargo, la colección de " -"objetos a los que hace referencia directamente un objeto inmutable no puede " -"cambiar)." +"objetos pueden ser mutables y pueden cambiarse; sin embargo, la colección de" +" objetos a los que hace referencia directamente un objeto inmutable no puede" +" cambiar)." #: ../Doc/reference/datamodel.rst:330 msgid "The following types are immutable sequences:" @@ -560,28 +561,28 @@ msgstr "Cadenas de caracteres" #: ../Doc/reference/datamodel.rst:343 msgid "" -"A string is a sequence of values that represent Unicode code points. All the " -"code points in the range ``U+0000 - U+10FFFF`` can be represented in a " +"A string is a sequence of values that represent Unicode code points. All the" +" code points in the range ``U+0000 - U+10FFFF`` can be represented in a " "string. Python doesn't have a :c:expr:`char` type; instead, every code " "point in the string is represented as a string object with length ``1``. " -"The built-in function :func:`ord` converts a code point from its string form " -"to an integer in the range ``0 - 10FFFF``; :func:`chr` converts an integer " -"in the range ``0 - 10FFFF`` to the corresponding length ``1`` string " -"object. :meth:`str.encode` can be used to convert a :class:`str` to :class:" -"`bytes` using the given text encoding, and :meth:`bytes.decode` can be used " -"to achieve the opposite." +"The built-in function :func:`ord` converts a code point from its string form" +" to an integer in the range ``0 - 10FFFF``; :func:`chr` converts an integer " +"in the range ``0 - 10FFFF`` to the corresponding length ``1`` string object." +" :meth:`str.encode` can be used to convert a :class:`str` to :class:`bytes` " +"using the given text encoding, and :meth:`bytes.decode` can be used to " +"achieve the opposite." msgstr "" "Una cadena es una secuencia de valores que representan puntos de código " "Unicode. Todos los puntos de código en el rango ``U+0000 - U+10FFFF`` se " -"pueden representar en una cadena. Python no tiene un tipo :c:expr:`char`; en " -"su lugar, cada punto de código de la cadena se representa como un objeto de " -"cadena con una longitud ``1``. La función integrada :func:`ord` convierte un " -"punto de código de su forma de cadena a un entero en el rango ``0 - " +"pueden representar en una cadena. Python no tiene un tipo :c:expr:`char`; en" +" su lugar, cada punto de código de la cadena se representa como un objeto de" +" cadena con una longitud ``1``. La función integrada :func:`ord` convierte " +"un punto de código de su forma de cadena a un entero en el rango ``0 - " "10FFFF``; :func:`chr` convierte un entero en el rango ``0 - 10FFFF`` al " "objeto de cadena ``1`` de longitud correspondiente. :meth:`str.encode` se " "puede usar para convertir un :class:`str` a :class:`bytes` usando la " -"codificación de texto dada, y :meth:`bytes.decode` se puede usar para lograr " -"lo contrario." +"codificación de texto dada, y :meth:`bytes.decode` se puede usar para lograr" +" lo contrario." #: ../Doc/reference/datamodel.rst:366 msgid "Tuples" @@ -612,15 +613,15 @@ msgid "" "A bytes object is an immutable array. The items are 8-bit bytes, " "represented by integers in the range 0 <= x < 256. Bytes literals (like " "``b'abc'``) and the built-in :func:`bytes()` constructor can be used to " -"create bytes objects. Also, bytes objects can be decoded to strings via " -"the :meth:`~bytes.decode` method." +"create bytes objects. Also, bytes objects can be decoded to strings via the" +" :meth:`~bytes.decode` method." msgstr "" "Un objeto de bytes es una colección inmutable. Los elementos son bytes de 8 " "bits, representados por enteros en el rango 0 <= x <256. Literales de bytes " "(como ``b'abc'``) y el constructor incorporado :func:`bytes()` se puede " -"utilizar para crear objetos de bytes. Además, los objetos de bytes se pueden " -"decodificar en cadenas de caracteres a través del método :meth:`~bytes." -"decode`." +"utilizar para crear objetos de bytes. Además, los objetos de bytes se pueden" +" decodificar en cadenas de caracteres a través del método " +":meth:`~bytes.decode`." #: ../Doc/reference/datamodel.rst:379 msgid "Mutable sequences" @@ -629,8 +630,8 @@ msgstr "Secuencias mutables" #: ../Doc/reference/datamodel.rst:388 msgid "" "Mutable sequences can be changed after they are created. The subscription " -"and slicing notations can be used as the target of assignment and :keyword:" -"`del` (delete) statements." +"and slicing notations can be used as the target of assignment and " +":keyword:`del` (delete) statements." msgstr "" "Las secuencias mutables se pueden cambiar después de su creación. Las " "anotaciones de suscripción y segmentación se pueden utilizar como el " @@ -641,6 +642,8 @@ msgid "" "The :mod:`collections` and :mod:`array` module provide additional examples " "of mutable sequence types." msgstr "" +"Los módulos :mod:`collections` y :mod:`array` proporcionan ejemplos " +"adicionales de tipos de secuencias mutables." #: ../Doc/reference/datamodel.rst:399 msgid "There are currently two intrinsic mutable sequence types:" @@ -653,11 +656,11 @@ msgstr "Listas" #: ../Doc/reference/datamodel.rst:404 msgid "" "The items of a list are arbitrary Python objects. Lists are formed by " -"placing a comma-separated list of expressions in square brackets. (Note that " -"there are no special cases needed to form lists of length 0 or 1.)" +"placing a comma-separated list of expressions in square brackets. (Note that" +" there are no special cases needed to form lists of length 0 or 1.)" msgstr "" -"Los elementos de una lista son objetos de Python arbitrarios. Las listas se " -"forman colocando una lista de expresiones separadas por comas entre " +"Los elementos de una lista son objetos de Python arbitrarios. Las listas se" +" forman colocando una lista de expresiones separadas por comas entre " "corchetes. (Tome en cuenta que no hay casos especiales necesarios para " "formar listas de longitud 0 o 1.)" @@ -667,13 +670,13 @@ msgstr "Colecciones de bytes" #: ../Doc/reference/datamodel.rst:411 msgid "" -"A bytearray object is a mutable array. They are created by the built-in :" -"func:`bytearray` constructor. Aside from being mutable (and hence " +"A bytearray object is a mutable array. They are created by the built-in " +":func:`bytearray` constructor. Aside from being mutable (and hence " "unhashable), byte arrays otherwise provide the same interface and " "functionality as immutable :class:`bytes` objects." msgstr "" -"Un objeto bytearray es una colección mutable. Son creados por el constructor " -"incorporado :func:`bytearray`. Además de ser mutables (y, por lo tanto, " +"Un objeto bytearray es una colección mutable. Son creados por el constructor" +" incorporado :func:`bytearray`. Además de ser mutables (y, por lo tanto, " "inquebrantable), las colecciones de bytes proporcionan la misma interfaz y " "funcionalidad que los objetos inmutables :class:`bytes`." @@ -684,11 +687,11 @@ msgstr "Tipos de conjuntos" #: ../Doc/reference/datamodel.rst:424 msgid "" "These represent unordered, finite sets of unique, immutable objects. As " -"such, they cannot be indexed by any subscript. However, they can be iterated " -"over, and the built-in function :func:`len` returns the number of items in a " -"set. Common uses for sets are fast membership testing, removing duplicates " -"from a sequence, and computing mathematical operations such as intersection, " -"union, difference, and symmetric difference." +"such, they cannot be indexed by any subscript. However, they can be iterated" +" over, and the built-in function :func:`len` returns the number of items in " +"a set. Common uses for sets are fast membership testing, removing duplicates" +" from a sequence, and computing mathematical operations such as " +"intersection, union, difference, and symmetric difference." msgstr "" "Estos representan conjuntos finitos no ordenados de objetos únicos e " "inmutables. Como tal, no pueden ser indexados por ningún *subscript*. Sin " @@ -701,15 +704,15 @@ msgstr "" #: ../Doc/reference/datamodel.rst:431 msgid "" "For set elements, the same immutability rules apply as for dictionary keys. " -"Note that numeric types obey the normal rules for numeric comparison: if two " -"numbers compare equal (e.g., ``1`` and ``1.0``), only one of them can be " +"Note that numeric types obey the normal rules for numeric comparison: if two" +" numbers compare equal (e.g., ``1`` and ``1.0``), only one of them can be " "contained in a set." msgstr "" "Para elementos del conjunto, se aplican las mismas reglas de inmutabilidad " "que para las claves de diccionario. Tenga en cuenta que los tipos numéricos " -"obedecen las reglas normales para la comparación numérica: si dos números se " -"comparan igual (por ejemplo, ``1`` y ``1.0``), solo uno de ellos puede estar " -"contenido en un conjunto." +"obedecen las reglas normales para la comparación numérica: si dos números se" +" comparan igual (por ejemplo, ``1`` y ``1.0``), solo uno de ellos puede " +"estar contenido en un conjunto." #: ../Doc/reference/datamodel.rst:436 msgid "There are currently two intrinsic set types:" @@ -722,8 +725,8 @@ msgstr "Conjuntos" #: ../Doc/reference/datamodel.rst:442 msgid "" "These represent a mutable set. They are created by the built-in :func:`set` " -"constructor and can be modified afterwards by several methods, such as :meth:" -"`~set.add`." +"constructor and can be modified afterwards by several methods, such as " +":meth:`~set.add`." msgstr "" "Estos representan un conjunto mutable. Son creados por el constructor " "incorporado :func:`set` y puede ser modificado posteriormente por varios " @@ -735,14 +738,15 @@ msgstr "Conjuntos congelados" #: ../Doc/reference/datamodel.rst:450 msgid "" -"These represent an immutable set. They are created by the built-in :func:" -"`frozenset` constructor. As a frozenset is immutable and :term:`hashable`, " -"it can be used again as an element of another set, or as a dictionary key." +"These represent an immutable set. They are created by the built-in " +":func:`frozenset` constructor. As a frozenset is immutable and " +":term:`hashable`, it can be used again as an element of another set, or as a" +" dictionary key." msgstr "" "Estos representan un conjunto inmutable. Son creados por el constructor " -"incorporado :func:`frozenset`. Como un conjunto congelado es inmutable y :" -"term:`hashable`, se puede usar nuevamente como un elemento de otro conjunto " -"o como una clave de un diccionario." +"incorporado :func:`frozenset`. Como un conjunto congelado es inmutable y " +":term:`hashable`, se puede usar nuevamente como un elemento de otro conjunto" +" o como una clave de un diccionario." #: ../Doc/reference/datamodel.rst:457 msgid "Mappings" @@ -759,9 +763,9 @@ msgstr "" "Estos representan conjuntos finitos de objetos indexados por conjuntos de " "índices arbitrarios. La notación de subíndice ``a[k]`` selecciona el " "elemento indexado por ``k`` del mapeo ``a``; esto se puede usar en " -"expresiones y como el objetivo de asignaciones o declaraciones :keyword:" -"`del`. La función incorporada :func:`len` retorna el número de elementos en " -"un mapeo." +"expresiones y como el objetivo de asignaciones o declaraciones " +":keyword:`del`. La función incorporada :func:`len` retorna el número de " +"elementos en un mapeo." #: ../Doc/reference/datamodel.rst:470 msgid "There is currently a single intrinsic mapping type:" @@ -786,29 +790,29 @@ msgstr "" "arbitrarios. Los únicos tipos de valores no aceptables como claves son " "valores que contienen listas o diccionarios u otros tipos mutables que se " "comparan por valor en lugar de por identidad de objeto, la razón es que la " -"implementación eficiente de los diccionarios requiere que el valor *hash* de " -"una clave permanezca constante. Los tipos numéricos utilizados para las " +"implementación eficiente de los diccionarios requiere que el valor *hash* de" +" una clave permanezca constante. Los tipos numéricos utilizados para las " "claves obedecen las reglas normales para la comparación numérica: si dos " "números se comparan igual (por ejemplo, ``1`` y ``1.0``) entonces se pueden " "usar indistintamente para indexar la misma entrada del diccionario." #: ../Doc/reference/datamodel.rst:487 msgid "" -"Dictionaries preserve insertion order, meaning that keys will be produced in " -"the same order they were added sequentially over the dictionary. Replacing " +"Dictionaries preserve insertion order, meaning that keys will be produced in" +" the same order they were added sequentially over the dictionary. Replacing " "an existing key does not change the order, however removing a key and re-" "inserting it will add it to the end instead of keeping its old place." msgstr "" "Los diccionarios conservan el orden de inserción, lo que significa que las " "claves se mantendrán en el mismo orden en que se agregaron secuencialmente " -"sobre el diccionario. Reemplazar una clave existente no cambia el orden, sin " -"embargo, eliminar una clave y volver a insertarla la agregará al final en " +"sobre el diccionario. Reemplazar una clave existente no cambia el orden, sin" +" embargo, eliminar una clave y volver a insertarla la agregará al final en " "lugar de mantener su lugar anterior." #: ../Doc/reference/datamodel.rst:492 msgid "" -"Dictionaries are mutable; they can be created by the ``{...}`` notation (see " -"section :ref:`dict`)." +"Dictionaries are mutable; they can be created by the ``{...}`` notation (see" +" section :ref:`dict`)." msgstr "" "Los diccionarios son mutables; pueden ser creados por la notación ``{...}`` " "(vea la sección :ref:`dict`)." @@ -819,14 +823,14 @@ msgid "" "examples of mapping types, as does the :mod:`collections` module." msgstr "" "Los módulos de extensión :mod:`dbm.ndbm` y :mod:`dbm.gnu` proporcionan " -"ejemplos adicionales de tipos de mapeo, al igual que el módulo :mod:" -"`collections`." +"ejemplos adicionales de tipos de mapeo, al igual que el módulo " +":mod:`collections`." #: ../Doc/reference/datamodel.rst:503 msgid "" "Dictionaries did not preserve insertion order in versions of Python before " -"3.6. In CPython 3.6, insertion order was preserved, but it was considered an " -"implementation detail at that time rather than a language guarantee." +"3.6. In CPython 3.6, insertion order was preserved, but it was considered an" +" implementation detail at that time rather than a language guarantee." msgstr "" "Los diccionarios no conservaban el orden de inserción en las versiones de " "Python anteriores a 3.6. En CPython 3.6, el orden de inserción se conserva, " @@ -839,8 +843,8 @@ msgstr "Tipos invocables" #: ../Doc/reference/datamodel.rst:518 msgid "" -"These are the types to which the function call operation (see section :ref:" -"`calls`) can be applied:" +"These are the types to which the function call operation (see section " +":ref:`calls`) can be applied:" msgstr "" "Estos son los tipos a los que la operación de llamada de función (vea la " "sección :ref:`calls`) puede ser aplicado:" @@ -948,8 +952,8 @@ msgstr ":attr:`__globals__`" #: ../Doc/reference/datamodel.rst:582 msgid "" -"A reference to the dictionary that holds the function's global variables --- " -"the global namespace of the module in which the function was defined." +"A reference to the dictionary that holds the function's global variables ---" +" the global namespace of the module in which the function was defined." msgstr "" "Una referencia al diccionario que contiene las variables globales de la " "función --- el espacio de nombres global del módulo en el que se definió la " @@ -1014,26 +1018,28 @@ msgstr ":attr:`__name__`" #: ../Doc/reference/datamodel.rst:613 msgid "" -"A tuple containing the :ref:`type parameters ` of a :ref:" -"`generic function `." +"A tuple containing the :ref:`type parameters ` of a " +":ref:`generic function `." msgstr "" +"Una tupla que contiene el :ref:`type parameters ` de un " +":ref:`generic function `." #: ../Doc/reference/datamodel.rst:620 msgid "" "Most of the attributes labelled \"Writable\" check the type of the assigned " "value." msgstr "" -"La mayoría de los atributos etiquetados \"Escribible\" verifican el tipo del " -"valor asignado." +"La mayoría de los atributos etiquetados \"Escribible\" verifican el tipo del" +" valor asignado." #: ../Doc/reference/datamodel.rst:622 msgid "" "Function objects also support getting and setting arbitrary attributes, " "which can be used, for example, to attach metadata to functions. Regular " "attribute dot-notation is used to get and set such attributes. *Note that " -"the current implementation only supports function attributes on user-defined " -"functions. Function attributes on built-in functions may be supported in the " -"future.*" +"the current implementation only supports function attributes on user-defined" +" functions. Function attributes on built-in functions may be supported in " +"the future.*" msgstr "" "Los objetos de función también admiten la obtención y configuración de " "atributos arbitrarios, que se pueden usar, por ejemplo, para adjuntar " @@ -1054,13 +1060,14 @@ msgstr "" #: ../Doc/reference/datamodel.rst:631 msgid "" "Additional information about a function's definition can be retrieved from " -"its code object; see the description of internal types below. The :data:" -"`cell ` type can be accessed in the :mod:`types` module." +"its code object; see the description of internal types below. The " +":data:`cell ` type can be accessed in the :mod:`types` " +"module." msgstr "" "Se puede recuperar información adicional sobre la definición de una función " "desde su objeto de código; Vea la descripción de los tipos internos a " -"continuación. El tipo :data:`cell ` puede ser accedido en el " -"módulo :mod:`types`." +"continuación. El tipo :data:`cell ` puede ser accedido en el" +" módulo :mod:`types`." #: ../Doc/reference/datamodel.rst:638 msgid "Instance methods" @@ -1071,24 +1078,26 @@ msgid "" "An instance method object combines a class, a class instance and any " "callable object (normally a user-defined function)." msgstr "" -"Un objeto de método de instancia combina una clase, una instancia de clase y " -"cualquier objeto invocable (normalmente una función definida por el usuario)." +"Un objeto de método de instancia combina una clase, una instancia de clase y" +" cualquier objeto invocable (normalmente una función definida por el " +"usuario)." #: ../Doc/reference/datamodel.rst:655 msgid "" -"Special read-only attributes: :attr:`__self__` is the class instance " -"object, :attr:`__func__` is the function object; :attr:`__doc__` is the " -"method's documentation (same as ``__func__.__doc__``); :attr:`~definition." -"__name__` is the method name (same as ``__func__.__name__``); :attr:" -"`__module__` is the name of the module the method was defined in, or " -"``None`` if unavailable." +"Special read-only attributes: :attr:`__self__` is the class instance object," +" :attr:`__func__` is the function object; :attr:`__doc__` is the method's " +"documentation (same as ``__func__.__doc__``); :attr:`~definition.__name__` " +"is the method name (same as ``__func__.__name__``); :attr:`__module__` is " +"the name of the module the method was defined in, or ``None`` if " +"unavailable." msgstr "" "Atributos especiales de solo lectura: :attr:`__self__` es el objeto de " -"instancia de clase, :attr:`__func__` es el objeto de función; :attr:" -"`__doc__` es la documentación del método (al igual que ``__func__." -"__doc__``); :attr:`~definition.__name__` es el nombre del método (al igual " -"que ``__func__.__name__``); :attr:`__module__` es el nombre del módulo en el " -"que el método fue definido, o ``None`` si no se encuentra disponible." +"instancia de clase, :attr:`__func__` es el objeto de función; " +":attr:`__doc__` es la documentación del método (al igual que " +"``__func__.__doc__``); :attr:`~definition.__name__` es el nombre del método " +"(al igual que ``__func__.__name__``); :attr:`__module__` es el nombre del " +"módulo en el que el método fue definido, o ``None`` si no se encuentra " +"disponible." #: ../Doc/reference/datamodel.rst:661 msgid "" @@ -1119,35 +1128,36 @@ msgstr "" "Cuando un objeto de instancia de método es creado al obtener un objeto de " "función definida por el usuario desde una clase a través de una de sus " "instancias, su atributo :attr:`__self__` es la instancia, y el objeto de " -"método se dice que está enlazado. El nuevo atributo de método :attr:" -"`__func__` es el objeto de función original." +"método se dice que está enlazado. El nuevo atributo de método " +":attr:`__func__` es el objeto de función original." #: ../Doc/reference/datamodel.rst:674 msgid "" "When an instance method object is created by retrieving a class method " -"object from a class or instance, its :attr:`__self__` attribute is the class " -"itself, and its :attr:`__func__` attribute is the function object underlying " -"the class method." +"object from a class or instance, its :attr:`__self__` attribute is the class" +" itself, and its :attr:`__func__` attribute is the function object " +"underlying the class method." msgstr "" "Cuando un objeto de instancia de método es creado al obtener un objeto de " -"método de clase a partir de una clase o instancia, su atributo :attr:" -"`__self__` es la clase misma, y su atributo :attr:`__func__` es el objeto de " -"función subyacente al método de la clase." +"método de clase a partir de una clase o instancia, su atributo " +":attr:`__self__` es la clase misma, y su atributo :attr:`__func__` es el " +"objeto de función subyacente al método de la clase." #: ../Doc/reference/datamodel.rst:679 msgid "" -"When an instance method object is called, the underlying function (:attr:" -"`__func__`) is called, inserting the class instance (:attr:`__self__`) in " -"front of the argument list. For instance, when :class:`C` is a class which " -"contains a definition for a function :meth:`f`, and ``x`` is an instance of :" -"class:`C`, calling ``x.f(1)`` is equivalent to calling ``C.f(x, 1)``." +"When an instance method object is called, the underlying function " +"(:attr:`__func__`) is called, inserting the class instance " +"(:attr:`__self__`) in front of the argument list. For instance, when " +":class:`C` is a class which contains a definition for a function :meth:`f`, " +"and ``x`` is an instance of :class:`C`, calling ``x.f(1)`` is equivalent to " +"calling ``C.f(x, 1)``." msgstr "" "Cuando el objeto de la instancia de método es invocado, la función " -"subyacente (:attr:`__func__`) es llamada, insertando la instancia de clase (:" -"attr:`__self__`) delante de la lista de argumentos. Por ejemplo, cuando :" -"class:`C` es una clase que contiene la definición de una función :meth:`f`, " -"y ``x`` es una instancia de :class:`C`, invocar ``x.f(1)`` es equivalente a " -"invocar ``C.f(x, 1)``." +"subyacente (:attr:`__func__`) es llamada, insertando la instancia de clase " +"(:attr:`__self__`) delante de la lista de argumentos. Por ejemplo, cuando " +":class:`C` es una clase que contiene la definición de una función :meth:`f`," +" y ``x`` es una instancia de :class:`C`, invocar ``x.f(1)`` es equivalente a" +" invocar ``C.f(x, 1)``." #: ../Doc/reference/datamodel.rst:686 msgid "" @@ -1156,10 +1166,10 @@ msgid "" "itself, so that calling either ``x.f(1)`` or ``C.f(1)`` is equivalent to " "calling ``f(C,1)`` where ``f`` is the underlying function." msgstr "" -"Cuando el objeto de instancia de método es derivado del objeto del método de " -"clase, la “instancia de clase” almacenada en :attr:`__self__` en realidad " -"será la clase misma, de manera que invocar ya sea ``x.f(1)`` o ``C.f(1)`` es " -"equivalente a invocar ``f(C,1)`` donde ``f`` es la función subyacente." +"Cuando el objeto de instancia de método es derivado del objeto del método de" +" clase, la “instancia de clase” almacenada en :attr:`__self__` en realidad " +"será la clase misma, de manera que invocar ya sea ``x.f(1)`` o ``C.f(1)`` es" +" equivalente a invocar ``f(C,1)`` donde ``f`` es la función subyacente." #: ../Doc/reference/datamodel.rst:691 msgid "" @@ -1167,14 +1177,14 @@ msgid "" "happens each time the attribute is retrieved from the instance. In some " "cases, a fruitful optimization is to assign the attribute to a local " "variable and call that local variable. Also notice that this transformation " -"only happens for user-defined functions; other callable objects (and all non-" -"callable objects) are retrieved without transformation. It is also " +"only happens for user-defined functions; other callable objects (and all " +"non-callable objects) are retrieved without transformation. It is also " "important to note that user-defined functions which are attributes of a " "class instance are not converted to bound methods; this *only* happens when " "the function is an attribute of the class." msgstr "" -"Tome en cuenta que la transformación de objeto de función a objeto de método " -"de instancia ocurre cada vez que el atributo es obtenido de la instancia. " +"Tome en cuenta que la transformación de objeto de función a objeto de método" +" de instancia ocurre cada vez que el atributo es obtenido de la instancia. " "En algunos casos, una optimización fructífera es asignar el atributo a una " "variable local e invocarla. Note también que esta transformación únicamente " "ocurre con funciones definidas por usuario; otros objetos invocables (y " @@ -1190,16 +1200,25 @@ msgstr "Funciones generadoras" #: ../Doc/reference/datamodel.rst:710 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 " +"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 :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 "" +"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 "" +"Una función o método que utiliza la instrucción :keyword:`yield` (consulte " +"la sección :ref:`yield`) se denomina :dfn:`función generadora`. Una función " +"de este tipo, cuando se llama, siempre retorna un objeto :term:`iterator` " +"que se puede usar para ejecutar el cuerpo de la función: llamar al método " +":meth:`iterator.__next__` del iterador hará que la función se ejecute hasta " +"que proporcione un valor usando la instrucción :keyword:`!yield`. Cuando la " +"función ejecuta una instrucción :keyword:`return` o se sale del final, se " +"genera una excepción :exc:`StopIteration` y el iterador habrá llegado al " +"final del conjunto de valores que se retornarán." #: ../Doc/reference/datamodel.rst:722 msgid "Coroutine functions" @@ -1207,42 +1226,53 @@ msgstr "Funciones de corrutina" #: ../Doc/reference/datamodel.rst:727 msgid "" -"A function or method which is defined using :keyword:`async def` is called " -"a :dfn:`coroutine function`. Such a function, when called, returns a :term:" -"`coroutine` object. It may contain :keyword:`await` expressions, as well " -"as :keyword:`async with` and :keyword:`async for` statements. See also the :" -"ref:`coroutine-objects` section." +"A function or method which is defined using :keyword:`async def` is called a" +" :dfn:`coroutine function`. Such a function, when called, returns a " +":term:`coroutine` object. It may contain :keyword:`await` expressions, as " +"well as :keyword:`async with` and :keyword:`async for` statements. See also " +"the :ref:`coroutine-objects` section." msgstr "" "Una función o método que es definido utilizando :keyword:`async def` se " -"llama :dfn:`coroutine function`. Dicha función, cuando es invocada, retorna " -"un objeto :term:`coroutine`. Éste puede contener expresiones :keyword:" -"`await`, así como declaraciones :keyword:`async with` y :keyword:`async " -"for`. Ver también la sección :ref:`coroutine-objects`." +"llama :dfn:`coroutine function`. Dicha función, cuando es invocada, retorna" +" un objeto :term:`coroutine`. Éste puede contener expresiones " +":keyword:`await`, así como declaraciones :keyword:`async with` y " +":keyword:`async for`. Ver también la sección :ref:`coroutine-objects`." #: ../Doc/reference/datamodel.rst:735 msgid "Asynchronous generator functions" msgstr "Funciones generadoras asincrónicas" #: ../Doc/reference/datamodel.rst:741 - 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 :term:`asynchronous " +"uses the :keyword:`yield` statement is called a :dfn:`asynchronous generator" +" 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 "" +"Una función o método que se define usando :keyword:`async def` y que usa la " +"declaración :keyword:`yield` se llama :dfn:`función generadora asíncrona`. " +"Una función de este tipo, cuando se llama, retorna un objeto " +":term:`asynchronous iterator` que se puede utilizar en una instrucción " +":keyword:`async for` para ejecutar el cuerpo de la función." #: ../Doc/reference/datamodel.rst:747 msgid "" -"Calling the asynchronous iterator's :meth:`aiterator.__anext__ ` method will return an :term:`awaitable` which when awaited will " -"execute until it provides a value using the :keyword:`yield` expression. " -"When the function executes an empty :keyword:`return` statement or falls off " -"the end, a :exc:`StopAsyncIteration` exception is raised and the " -"asynchronous iterator will have reached the end of the set of values to be " -"yielded." -msgstr "" +"Calling the asynchronous iterator's :meth:`aiterator.__anext__ " +"` method will return an :term:`awaitable` which when " +"awaited will execute until it provides a value using the :keyword:`yield` " +"expression. When the function executes an empty :keyword:`return` statement" +" or falls off the end, a :exc:`StopAsyncIteration` exception is raised and " +"the asynchronous iterator will have reached the end of the set of values to " +"be yielded." +msgstr "" +"Llamar al método :meth:`aiterator.__anext__ ` del iterador" +" asíncrono retornará un :term:`awaitable` que, cuando se espere, se " +"ejecutará hasta que proporcione un valor utilizando la expresión " +":keyword:`yield`. Cuando la función ejecuta una instrucción " +":keyword:`return` vacía o se sale del final, se genera una excepción " +":exc:`StopAsyncIteration` y el iterador asincrónico habrá llegado al final " +"del conjunto de valores que se generarán." #: ../Doc/reference/datamodel.rst:758 msgid "Built-in functions" @@ -1254,21 +1284,21 @@ msgid "" "built-in functions are :func:`len` and :func:`math.sin` (:mod:`math` is a " "standard built-in module). The number and type of the arguments are " "determined by the C function. Special read-only attributes: :attr:`__doc__` " -"is the function's documentation string, or ``None`` if unavailable; :attr:" -"`~definition.__name__` is the function's name; :attr:`__self__` is set to " -"``None`` (but see the next item); :attr:`__module__` is the name of the " +"is the function's documentation string, or ``None`` if unavailable; " +":attr:`~definition.__name__` is the function's name; :attr:`__self__` is set" +" to ``None`` (but see the next item); :attr:`__module__` is the name of the " "module the function was defined in or ``None`` if unavailable." msgstr "" -"Un objeto de función incorporada es un envoltorio (wrapper) alrededor de una " -"función C. Ejemplos de funciones incorporadas son :func:`len` y :func:`math." -"sin` (:mod:`math` es un módulo estándar incorporado). El número y tipo de " -"argumentos son determinados por la función C. Atributos especiales de solo " -"lectura: :attr:`__doc__` es la cadena de documentación de la función, o " -"``None`` si no se encuentra disponible; :attr:`~definition.__name__` es el " -"nombre de la función; :attr:`__init__` es establecido como ``None`` (sin " -"embargo ver el siguiente elemento); :attr:`__module__` es el nombre del " -"módulo en el que la función fue definida o ``None`` si no se encuentra " -"disponible." +"Un objeto de función incorporada es un envoltorio (wrapper) alrededor de una" +" función C. Ejemplos de funciones incorporadas son :func:`len` y " +":func:`math.sin` (:mod:`math` es un módulo estándar incorporado). El número " +"y tipo de argumentos son determinados por la función C. Atributos especiales" +" de solo lectura: :attr:`__doc__` es la cadena de documentación de la " +"función, o ``None`` si no se encuentra disponible; " +":attr:`~definition.__name__` es el nombre de la función; :attr:`__init__` es" +" establecido como ``None`` (sin embargo ver el siguiente elemento); " +":attr:`__module__` es el nombre del módulo en el que la función fue definida" +" o ``None`` si no se encuentra disponible." #: ../Doc/reference/datamodel.rst:776 msgid "Built-in methods" @@ -1277,10 +1307,10 @@ msgstr "Métodos incorporados" #: ../Doc/reference/datamodel.rst:783 msgid "" "This is really a different disguise of a built-in function, this time " -"containing an object passed to the C function as an implicit extra " -"argument. An example of a built-in method is ``alist.append()``, assuming " -"*alist* is a list object. In this case, the special read-only attribute :" -"attr:`__self__` is set to the object denoted by *alist*." +"containing an object passed to the C function as an implicit extra argument." +" An example of a built-in method is ``alist.append()``, assuming *alist* is" +" a list object. In this case, the special read-only attribute " +":attr:`__self__` is set to the object denoted by *alist*." msgstr "" "Éste es realmente un disfraz distinto de una función incorporada, esta vez " "teniendo un objeto que se pasa a la función C como un argumento extra " @@ -1297,10 +1327,15 @@ msgstr "Clases" msgid "" "Classes are callable. These objects normally act as factories for new " "instances of themselves, but variations are possible for class types that " -"override :meth:`~object.__new__`. The arguments of the call are passed to :" -"meth:`__new__` and, in the typical case, to :meth:`~object.__init__` to " +"override :meth:`~object.__new__`. The arguments of the call are passed to " +":meth:`__new__` and, in the typical case, to :meth:`~object.__init__` to " "initialize the new instance." msgstr "" +"Las clases son invocables. Estos objetos normalmente actúan como fábricas " +"para nuevas instancias de sí mismos, pero son posibles variaciones para los " +"tipos de clases que anulan :meth:`~object.__new__`. Los argumentos de la " +"llamada se pasan a :meth:`__new__` y, en el caso típico, a " +":meth:`~object.__init__` para inicializar la nueva instancia." #: ../Doc/reference/datamodel.rst:801 msgid "Class Instances" @@ -1308,8 +1343,8 @@ msgstr "Instancias de clases" #: ../Doc/reference/datamodel.rst:803 msgid "" -"Instances of arbitrary classes can be made callable by defining a :meth:" -"`~object.__call__` method in their class." +"Instances of arbitrary classes can be made callable by defining a " +":meth:`~object.__call__` method in their class." msgstr "" "Las instancias de clases arbitrarias se pueden hacer invocables definiendo " "un método :meth:`~object.__call__` en su clase." @@ -1321,27 +1356,27 @@ msgstr "Módulos" #: ../Doc/reference/datamodel.rst:814 msgid "" "Modules are a basic organizational unit of Python code, and are created by " -"the :ref:`import system ` as invoked either by the :keyword:" -"`import` statement, or by calling functions such as :func:`importlib." -"import_module` and built-in :func:`__import__`. A module object has a " -"namespace implemented by a dictionary object (this is the dictionary " -"referenced by the ``__globals__`` attribute of functions defined in the " -"module). Attribute references are translated to lookups in this dictionary, " -"e.g., ``m.x`` is equivalent to ``m.__dict__[\"x\"]``. A module object does " -"not contain the code object used to initialize the module (since it isn't " -"needed once the initialization is done)." +"the :ref:`import system ` as invoked either by the " +":keyword:`import` statement, or by calling functions such as " +":func:`importlib.import_module` and built-in :func:`__import__`. A module " +"object has a namespace implemented by a dictionary object (this is the " +"dictionary referenced by the ``__globals__`` attribute of functions defined " +"in the module). Attribute references are translated to lookups in this " +"dictionary, e.g., ``m.x`` is equivalent to ``m.__dict__[\"x\"]``. A module " +"object does not contain the code object used to initialize the module (since" +" it isn't needed once the initialization is done)." msgstr "" "Los módulos son una unidad básica organizacional en código Python, y son " "creados por el :ref:`import system ` al ser invocados ya sea " -"por la declaración :keyword:`import`, o invocando funciones como :func:" -"`importlib.import_module` y la incorporada :func:`__import__`. Un objeto de " -"módulo tiene un espacio de nombres implementado por un objeto de diccionario " -"(éste es el diccionario al que hace referencia el atributo de funciones " -"``__globals__`` definido en el módulo). Las referencias de atributos son " -"traducidas a búsquedas en este diccionario, p. ej., ``m.x`` es equivalente a " -"``m.__dict__[“x”]``. Un objeto de módulo no contiene el objeto de código " -"utilizado para iniciar el módulo (ya que no es necesario una vez que la " -"inicialización es realizada)." +"por la declaración :keyword:`import`, o invocando funciones como " +":func:`importlib.import_module` y la incorporada :func:`__import__`. Un " +"objeto de módulo tiene un espacio de nombres implementado por un objeto de " +"diccionario (éste es el diccionario al que hace referencia el atributo de " +"funciones ``__globals__`` definido en el módulo). Las referencias de " +"atributos son traducidas a búsquedas en este diccionario, p. ej., ``m.x`` es" +" equivalente a ``m.__dict__[“x”]``. Un objeto de módulo no contiene el " +"objeto de código utilizado para iniciar el módulo (ya que no es necesario " +"una vez que la inicialización es realizada)." #: ../Doc/reference/datamodel.rst:826 msgid "" @@ -1375,8 +1410,8 @@ msgstr ":attr:`__file__`" #: ../Doc/reference/datamodel.rst:846 msgid "" "The pathname of the file from which the module was loaded, if it was loaded " -"from a file. The :attr:`__file__` attribute may be missing for certain types " -"of modules, such as C modules that are statically linked into the " +"from a file. The :attr:`__file__` attribute may be missing for certain types" +" of modules, such as C modules that are statically linked into the " "interpreter. For extension modules loaded dynamically from a shared " "library, it's the pathname of the shared library file." msgstr "" @@ -1390,13 +1425,13 @@ msgstr "" #: ../Doc/reference/datamodel.rst:855 msgid "" "A dictionary containing :term:`variable annotations ` " -"collected during module body execution. For best practices on working with :" -"attr:`__annotations__`, please see :ref:`annotations-howto`." +"collected during module body execution. For best practices on working with " +":attr:`__annotations__`, please see :ref:`annotations-howto`." msgstr "" "Un diccionario que contiene el :term:`variable annotations ` recopilados durante la ejecución del cuerpo del módulo. Para " -"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve :" -"ref:`annotations-howto`." +"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve " +":ref:`annotations-howto`." #: ../Doc/reference/datamodel.rst:862 msgid "" @@ -1408,16 +1443,16 @@ msgstr "" #: ../Doc/reference/datamodel.rst:867 msgid "" -"Because of the way CPython clears module dictionaries, the module dictionary " -"will be cleared when the module falls out of scope even if the dictionary " +"Because of the way CPython clears module dictionaries, the module dictionary" +" will be cleared when the module falls out of scope even if the dictionary " "still has live references. To avoid this, copy the dictionary or keep the " "module around while using its dictionary directly." msgstr "" "Debido a la manera en la que CPython limpia los diccionarios de módulo, el " "diccionario de módulo será limpiado cuando el módulo se encuentra fuera de " "alcance, incluso si el diccionario aún tiene referencias existentes. Para " -"evitar esto, copie el diccionario o mantenga el módulo cerca mientras usa el " -"diccionario directamente." +"evitar esto, copie el diccionario o mantenga el módulo cerca mientras usa el" +" diccionario directamente." #: ../Doc/reference/datamodel.rst:874 msgid "Custom classes" @@ -1425,18 +1460,18 @@ msgstr "Clases personalizadas" #: ../Doc/reference/datamodel.rst:876 msgid "" -"Custom class types are typically created by class definitions (see section :" -"ref:`class`). A class has a namespace implemented by a dictionary object. " -"Class attribute references are translated to lookups in this dictionary, e." -"g., ``C.x`` is translated to ``C.__dict__[\"x\"]`` (although there are a " +"Custom class types are typically created by class definitions (see section " +":ref:`class`). A class has a namespace implemented by a dictionary object. " +"Class attribute references are translated to lookups in this dictionary, " +"e.g., ``C.x`` is translated to ``C.__dict__[\"x\"]`` (although there are a " "number of hooks which allow for other means of locating attributes). When " -"the attribute name is not found there, the attribute search continues in the " -"base classes. This search of the base classes uses the C3 method resolution " -"order which behaves correctly even in the presence of 'diamond' inheritance " -"structures where there are multiple inheritance paths leading back to a " +"the attribute name is not found there, the attribute search continues in the" +" base classes. This search of the base classes uses the C3 method resolution" +" order which behaves correctly even in the presence of 'diamond' inheritance" +" structures where there are multiple inheritance paths leading back to a " "common ancestor. Additional details on the C3 MRO used by Python can be " -"found in the documentation accompanying the 2.3 release at https://www." -"python.org/download/releases/2.3/mro/." +"found in the documentation accompanying the 2.3 release at " +"https://www.python.org/download/releases/2.3/mro/." msgstr "" "Los tipos de clases personalizadas son normalmente creadas por definiciones " "de clases (ver sección :ref:`class`). Una clase tiene implementado un " @@ -1445,31 +1480,32 @@ msgstr "" "``C.x`` es traducido a ``C.__dict__[“x”]`` (aunque hay una serie de enlaces " "que permiten la ubicación de atributos por otros medios). Cuando el nombre " "de atributo no es encontrado ahí, la búsqueda de atributo continúa en las " -"clases base. Esta búsqueda de las clases base utiliza la orden de resolución " -"de métodos C3 que se comporta correctamente aún en la presencia de " -"estructuras de herencia ‘diamante’ donde existen múltiples rutas de herencia " -"que llevan a un ancestro común. Detalles adicionales en el MRO C3 utilizados " -"por Python pueden ser encontrados en la documentación correspondiente a la " -"versión 2.3 en https://www.python.org/download/releases/2.3/mro/." +"clases base. Esta búsqueda de las clases base utiliza la orden de resolución" +" de métodos C3 que se comporta correctamente aún en la presencia de " +"estructuras de herencia ‘diamante’ donde existen múltiples rutas de herencia" +" que llevan a un ancestro común. Detalles adicionales en el MRO C3 " +"utilizados por Python pueden ser encontrados en la documentación " +"correspondiente a la versión 2.3 en " +"https://www.python.org/download/releases/2.3/mro/." #: ../Doc/reference/datamodel.rst:900 msgid "" "When a class attribute reference (for class :class:`C`, say) would yield a " -"class method object, it is transformed into an instance method object whose :" -"attr:`__self__` attribute is :class:`C`. When it would yield a static " +"class method object, it is transformed into an instance method object whose " +":attr:`__self__` attribute is :class:`C`. When it would yield a static " "method object, it is transformed into the object wrapped by the static " "method object. See section :ref:`descriptors` for another way in which " "attributes retrieved from a class may differ from those actually contained " "in its :attr:`~object.__dict__`." msgstr "" -"Cuando la referencia de un atributo de clase (digamos, para la clase :class:" -"`C`) produce un objeto de método de clase, éste es transformado a un objeto " -"de método de instancia cuyo atributo :attr:`__self__` es :class:`C`. Cuando " -"produce un objeto de un método estático, éste es transformado al objeto " -"envuelto por el objeto de método estático. Ver sección :ref:`descriptors` " -"para otra manera en la que los atributos obtenidos de una clase pueden " -"diferir de los que en realidad están contenidos en su :attr:`~object." -"__dict__`." +"Cuando la referencia de un atributo de clase (digamos, para la clase " +":class:`C`) produce un objeto de método de clase, éste es transformado a un " +"objeto de método de instancia cuyo atributo :attr:`__self__` es :class:`C`." +" Cuando produce un objeto de un método estático, éste es transformado al " +"objeto envuelto por el objeto de método estático. Ver sección " +":ref:`descriptors` para otra manera en la que los atributos obtenidos de una" +" clase pueden diferir de los que en realidad están contenidos en su " +":attr:`~object.__dict__`." #: ../Doc/reference/datamodel.rst:910 msgid "" @@ -1509,11 +1545,11 @@ msgstr ":attr:`~class.__bases__`" #: ../Doc/reference/datamodel.rst:938 msgid "" -"A tuple containing the base classes, in the order of their occurrence in the " -"base class list." +"A tuple containing the base classes, in the order of their occurrence in the" +" base class list." msgstr "" -"Una tupla conteniendo las clases de base, en orden de ocurrencia en la lista " -"de clase base." +"Una tupla conteniendo las clases de base, en orden de ocurrencia en la lista" +" de clase base." #: ../Doc/reference/datamodel.rst:942 msgid "The class's documentation string, or ``None`` if undefined." @@ -1523,19 +1559,21 @@ msgstr "" #: ../Doc/reference/datamodel.rst:945 msgid "" "A dictionary containing :term:`variable annotations ` " -"collected during class body execution. For best practices on working with :" -"attr:`__annotations__`, please see :ref:`annotations-howto`." +"collected during class body execution. For best practices on working with " +":attr:`__annotations__`, please see :ref:`annotations-howto`." msgstr "" "Un diccionario conteniendo el :term:`variable annotations ` recopilados durante la ejecución del cuerpo de la clase. Para " -"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve :" -"ref:`annotations-howto`." +"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve " +":ref:`annotations-howto`." #: ../Doc/reference/datamodel.rst:952 msgid "" -"A tuple containing the :ref:`type parameters ` of a :ref:" -"`generic class `." +"A tuple containing the :ref:`type parameters ` of a " +":ref:`generic class `." msgstr "" +"Una tupla que contiene el :ref:`type parameters ` de un " +":ref:`generic class `." #: ../Doc/reference/datamodel.rst:957 msgid "Class instances" @@ -1554,17 +1592,36 @@ msgid "" "\"Classes\". See section :ref:`descriptors` for another way in which " "attributes of a class retrieved via its instances may differ from the " "objects actually stored in the class's :attr:`~object.__dict__`. If no " -"class attribute is found, and the object's class has a :meth:`~object." -"__getattr__` method, that is called to satisfy the lookup." -msgstr "" +"class attribute is found, and the object's class has a " +":meth:`~object.__getattr__` method, that is called to satisfy the lookup." +msgstr "" +"Una instancia de clase se crea llamando a un objeto de clase (ver arriba). " +"Una instancia de clase tiene un espacio de nombres implementado como un " +"diccionario, que es el primer lugar en el que se buscan las referencias de " +"atributos. Cuando no se encuentra un atributo allí y la clase de la " +"instancia tiene un atributo con ese nombre, la búsqueda continúa con los " +"atributos de la clase. Si se encuentra un atributo de clase que es un objeto" +" de función definido por el usuario, se transforma en un objeto de método de" +" instancia cuyo atributo :attr:`__self__` es la instancia. Los objetos de " +"métodos estáticos y de clases también se transforman; consulte más arriba en" +" \"Clases\". Consulte la sección :ref:`descriptors` para conocer otra forma " +"en la que los atributos de una clase recuperados a través de sus instancias " +"pueden diferir de los objetos realmente almacenados en el " +":attr:`~object.__dict__` de la clase. Si no se encuentra ningún atributo de " +"clase y la clase del objeto tiene un método :meth:`~object.__getattr__`, se " +"llama para satisfacer la búsqueda." #: ../Doc/reference/datamodel.rst:981 msgid "" "Attribute assignments and deletions update the instance's dictionary, never " -"a class's dictionary. If the class has a :meth:`~object.__setattr__` or :" -"meth:`~object.__delattr__` method, this is called instead of updating the " +"a class's dictionary. If the class has a :meth:`~object.__setattr__` or " +":meth:`~object.__delattr__` method, this is called instead of updating the " "instance dictionary directly." msgstr "" +"Las asignaciones y eliminaciones de atributos actualizan el diccionario de " +"la instancia, nunca el diccionario de una clase. Si la clase tiene un método" +" :meth:`~object.__setattr__` o :meth:`~object.__delattr__`, se llama a este " +"en lugar de actualizar el diccionario de instancia directamente." #: ../Doc/reference/datamodel.rst:991 msgid "" @@ -1572,13 +1629,13 @@ msgid "" "have methods with certain special names. See section :ref:`specialnames`." msgstr "" "Instancias de clases pueden pretender ser números, secuencias o mapeos si " -"tienen métodos con ciertos nombres especiales. Ver sección :ref:" -"`specialnames`." +"tienen métodos con ciertos nombres especiales. Ver sección " +":ref:`specialnames`." #: ../Doc/reference/datamodel.rst:998 msgid "" -"Special attributes: :attr:`~object.__dict__` is the attribute dictionary; :" -"attr:`~instance.__class__` is the instance's class." +"Special attributes: :attr:`~object.__dict__` is the attribute dictionary; " +":attr:`~instance.__class__` is the instance's class." msgstr "" "Atributos especiales: :attr:`~object.__dict__` es el diccionario de " "atributos; :attr:`~instance.__class__` es la clase de la instancia." @@ -1591,28 +1648,28 @@ msgstr "Objetos E/S (también conocidos como objetos de archivo)" msgid "" "A :term:`file object` represents an open file. Various shortcuts are " "available to create file objects: the :func:`open` built-in function, and " -"also :func:`os.popen`, :func:`os.fdopen`, and the :meth:`~socket.socket." -"makefile` method of socket objects (and perhaps by other functions or " -"methods provided by extension modules)." +"also :func:`os.popen`, :func:`os.fdopen`, and the " +":meth:`~socket.socket.makefile` method of socket objects (and perhaps by " +"other functions or methods provided by extension modules)." msgstr "" "Un :term:`file object` representa un archivo abierto. Diversos accesos " -"directos se encuentran disponibles para crear objetos de archivo: la función " -"incorporada :func:`open`, así como :func:`os.popen`, :func:`os.fdopen`, y el " -"método de objetos socket :meth:`~socket.makefile` (y quizás por otras " +"directos se encuentran disponibles para crear objetos de archivo: la función" +" incorporada :func:`open`, así como :func:`os.popen`, :func:`os.fdopen`, y " +"el método de objetos socket :meth:`~socket.makefile` (y quizás por otras " "funciones y métodos proporcionados por módulos de extensión)." #: ../Doc/reference/datamodel.rst:1024 msgid "" -"The objects ``sys.stdin``, ``sys.stdout`` and ``sys.stderr`` are initialized " -"to file objects corresponding to the interpreter's standard input, output " +"The objects ``sys.stdin``, ``sys.stdout`` and ``sys.stderr`` are initialized" +" to file objects corresponding to the interpreter's standard input, output " "and error streams; they are all open in text mode and therefore follow the " "interface defined by the :class:`io.TextIOBase` abstract class." msgstr "" "Los objetos ``sys.stdin``, ``sys.stdout`` y ``sys.stderr`` son iniciados a " "objetos de archivos correspondientes a la entrada y salida estándar del " "intérprete, así como flujos de error; todos ellos están abiertos en el modo " -"de texto y por lo tanto siguen la interface definida por la clase abstracta :" -"class:`io.TextIOBase`." +"de texto y por lo tanto siguen la interface definida por la clase abstracta " +":class:`io.TextIOBase`." #: ../Doc/reference/datamodel.rst:1032 msgid "Internal types" @@ -1634,81 +1691,108 @@ msgstr "Objetos de código" #: ../Doc/reference/datamodel.rst:1050 msgid "" -"Code objects represent *byte-compiled* executable Python code, or :term:" -"`bytecode`. The difference between a code object and a function object is " -"that the function object contains an explicit reference to the function's " -"globals (the module in which it was defined), while a code object contains " -"no context; also the default argument values are stored in the function " -"object, not in the code object (because they represent values calculated at " -"run-time). Unlike function objects, code objects are immutable and contain " -"no references (directly or indirectly) to mutable objects." -msgstr "" -"Los objetos de código representan código de Python ejecutable *compilado por " -"bytes*, o :term:`bytecode`. La diferencia entre un objeto de código y un " +"Code objects represent *byte-compiled* executable Python code, or " +":term:`bytecode`. The difference between a code object and a function object" +" is that the function object contains an explicit reference to the " +"function's globals (the module in which it was defined), while a code object" +" contains no context; also the default argument values are stored in the " +"function object, not in the code object (because they represent values " +"calculated at run-time). Unlike function objects, code objects are " +"immutable and contain no references (directly or indirectly) to mutable " +"objects." +msgstr "" +"Los objetos de código representan código de Python ejecutable *compilado por" +" bytes*, o :term:`bytecode`. La diferencia entre un objeto de código y un " "objeto de función es que el objeto de función contiene una referencia " "explícita a los globales de la función (el módulo en el que fue definido), " "mientras el objeto de código no contiene contexto; de igual manera los " "valores por defecto de los argumentos son almacenados en el objeto de " -"función, no en el objeto de código (porque representan valores calculados en " -"tiempo de ejecución). A diferencia de objetos de función, los objetos de " +"función, no en el objeto de código (porque representan valores calculados en" +" tiempo de ejecución). A diferencia de objetos de función, los objetos de " "código son inmutables y no contienen referencias (directas o indirectas) a " "objetos mutables." #: ../Doc/reference/datamodel.rst:1078 msgid "" -"Special read-only attributes: :attr:`co_name` gives the function name; :attr:" -"`co_qualname` gives the fully qualified function name; :attr:`co_argcount` " -"is the total number of positional arguments (including positional-only " -"arguments and arguments with default values); :attr:`co_posonlyargcount` is " -"the number of positional-only arguments (including arguments with default " -"values); :attr:`co_kwonlyargcount` is the number of keyword-only arguments " -"(including arguments with default values); :attr:`co_nlocals` is the number " -"of local variables used by the function (including arguments); :attr:" -"`co_varnames` is a tuple containing the names of the local variables " -"(starting with the argument names); :attr:`co_cellvars` is a tuple " -"containing the names of local variables that are referenced by nested " -"functions; :attr:`co_freevars` is a tuple containing the names of free " -"variables; :attr:`co_code` is a string representing the sequence of bytecode " -"instructions; :attr:`co_consts` is a tuple containing the literals used by " -"the bytecode; :attr:`co_names` is a tuple containing the names used by the " -"bytecode; :attr:`co_filename` is the filename from which the code was " -"compiled; :attr:`co_firstlineno` is the first line number of the function; :" -"attr:`co_lnotab` is a string encoding the mapping from bytecode offsets to " -"line numbers (for details see the source code of the interpreter, is " -"deprecated since 3.12 and may be removed in 3.14); :attr:`co_stacksize` is " -"the required stack size; :attr:`co_flags` is an integer encoding a number of " -"flags for the interpreter." -msgstr "" +"Special read-only attributes: :attr:`co_name` gives the function name; " +":attr:`co_qualname` gives the fully qualified function name; " +":attr:`co_argcount` is the total number of positional arguments (including " +"positional-only arguments and arguments with default values); " +":attr:`co_posonlyargcount` is the number of positional-only arguments " +"(including arguments with default values); :attr:`co_kwonlyargcount` is the " +"number of keyword-only arguments (including arguments with default values); " +":attr:`co_nlocals` is the number of local variables used by the function " +"(including arguments); :attr:`co_varnames` is a tuple containing the names " +"of the local variables (starting with the argument names); " +":attr:`co_cellvars` is a tuple containing the names of local variables that " +"are referenced by nested functions; :attr:`co_freevars` is a tuple " +"containing the names of free variables; :attr:`co_code` is a string " +"representing the sequence of bytecode instructions; :attr:`co_consts` is a " +"tuple containing the literals used by the bytecode; :attr:`co_names` is a " +"tuple containing the names used by the bytecode; :attr:`co_filename` is the " +"filename from which the code was compiled; :attr:`co_firstlineno` is the " +"first line number of the function; :attr:`co_lnotab` is a string encoding " +"the mapping from bytecode offsets to line numbers (for details see the " +"source code of the interpreter, is deprecated since 3.12 and may be removed " +"in 3.14); :attr:`co_stacksize` is the required stack size; :attr:`co_flags` " +"is an integer encoding a number of flags for the interpreter." +msgstr "" +"Atributos especiales de solo lectura: :attr:`co_name` proporciona el nombre " +"de la función; :attr:`co_qualname` proporciona el nombre completo de la " +"función; :attr:`co_argcount` es el número total de argumentos posicionales " +"(incluidos los argumentos solo posicionales y los argumentos con valores " +"predeterminados); :attr:`co_posonlyargcount` es el número de argumentos solo" +" posicionales (incluidos los argumentos con valores predeterminados); " +":attr:`co_kwonlyargcount` es el número de argumentos de solo palabras clave " +"(incluidos los argumentos con valores predeterminados); :attr:`co_nlocals` " +"es el número de variables locales utilizadas por la función (incluidos los " +"argumentos); :attr:`co_varnames` es una tupla que contiene los nombres de " +"las variables locales (comenzando con los nombres de los argumentos); " +":attr:`co_cellvars` es una tupla que contiene los nombres de las variables " +"locales a las que hacen referencia las funciones anidadas; " +":attr:`co_freevars` es una tupla que contiene los nombres de las variables " +"libres; :attr:`co_code` es una cadena que representa la secuencia de " +"instrucciones de código de bytes; :attr:`co_consts` es una tupla que " +"contiene los literales utilizados por el código de bytes; :attr:`co_names` " +"es una tupla que contiene los nombres utilizados por el código de bytes; " +":attr:`co_filename` es el nombre del archivo a partir del cual se compiló el" +" código; :attr:`co_firstlineno` es el número de primera línea de la función;" +" :attr:`co_lnotab` es una cadena que codifica la asignación de " +"desplazamientos de código de bytes a números de línea (para obtener más " +"detalles, consulte el código fuente del intérprete, está en desuso desde " +"3.12 y puede eliminarse en 3.14); :attr:`co_stacksize` es el tamaño de pila " +"requerido; :attr:`co_flags` es un número entero que codifica una serie de " +"indicadores para el intérprete." #: ../Doc/reference/datamodel.rst:1104 msgid "" "The following flag bits are defined for :attr:`co_flags`: bit ``0x04`` is " "set if the function uses the ``*arguments`` syntax to accept an arbitrary " -"number of positional arguments; bit ``0x08`` is set if the function uses the " -"``**keywords`` syntax to accept arbitrary keyword arguments; bit ``0x20`` is " -"set if the function is a generator." +"number of positional arguments; bit ``0x08`` is set if the function uses the" +" ``**keywords`` syntax to accept arbitrary keyword arguments; bit ``0x20`` " +"is set if the function is a generator." msgstr "" "Los siguientes bits de bandera son definidos por :attr:`co_flags` : bit " "``0x04`` es establecido si la función utiliza la sintaxis ``*arguments`` " "para aceptar un número arbitrario de argumentos posicionales; bit ``0x08`` " -"es establecido si la función utiliza la sintaxis ``**keywords`` para aceptar " -"argumentos de palabras clave arbitrarios; bit ``0x20`` es establecido si la " -"función es un generador." +"es establecido si la función utiliza la sintaxis ``**keywords`` para aceptar" +" argumentos de palabras clave arbitrarios; bit ``0x20`` es establecido si la" +" función es un generador." #: ../Doc/reference/datamodel.rst:1110 msgid "" "Future feature declarations (``from __future__ import division``) also use " -"bits in :attr:`co_flags` to indicate whether a code object was compiled with " -"a particular feature enabled: bit ``0x2000`` is set if the function was " +"bits in :attr:`co_flags` to indicate whether a code object was compiled with" +" a particular feature enabled: bit ``0x2000`` is set if the function was " "compiled with future division enabled; bits ``0x10`` and ``0x1000`` were " "used in earlier versions of Python." msgstr "" "Declaraciones de características futuras (``from __future__ import " "division``) también utiliza bits en :attr:`co_flags` para indicar si el " "objeto de código fue compilado con alguna característica particular " -"habilitada: el bit ``0x2000`` es establecido si la función fue compilada con " -"división futura habilitada; los bits ``0x10`` y ``0x1000`` fueron utilizados " -"en versiones previas de Python." +"habilitada: el bit ``0x2000`` es establecido si la función fue compilada con" +" división futura habilitada; los bits ``0x10`` y ``0x1000`` fueron " +"utilizados en versiones previas de Python." #: ../Doc/reference/datamodel.rst:1116 msgid "Other bits in :attr:`co_flags` are reserved for internal use." @@ -1719,24 +1803,24 @@ msgid "" "If a code object represents a function, the first item in :attr:`co_consts` " "is the documentation string of the function, or ``None`` if undefined." msgstr "" -"Si un objeto de código representa una función, el primer elemento en :attr:" -"`co_consts` es la cadena de documentación de la función, o ``None`` si no " -"está definido." +"Si un objeto de código representa una función, el primer elemento en " +":attr:`co_consts` es la cadena de documentación de la función, o ``None`` si" +" no está definido." #: ../Doc/reference/datamodel.rst:1125 msgid "" "Returns an iterable over the source code positions of each bytecode " "instruction in the code object." msgstr "" -"retorna un iterable sobre las posiciones del código fuente de cada " +"Retorna un iterable sobre las posiciones del código fuente de cada " "instrucción de código de bytes en el objeto de código." #: ../Doc/reference/datamodel.rst:1128 msgid "" "The iterator returns tuples containing the ``(start_line, end_line, " -"start_column, end_column)``. The *i-th* tuple corresponds to the position of " -"the source code that compiled to the *i-th* instruction. Column information " -"is 0-indexed utf-8 byte offsets on the given source line." +"start_column, end_column)``. The *i-th* tuple corresponds to the position of" +" the source code that compiled to the *i-th* instruction. Column information" +" is 0-indexed utf-8 byte offsets on the given source line." msgstr "" "El iterador retorna tuplas que contienen ``(start_line, end_line, " "start_column, end_column)``. La tupla *i-th* corresponde a la posición del " @@ -1778,8 +1862,8 @@ msgstr "" msgid "" "When this occurs, some or all of the tuple elements can be :const:`None`." msgstr "" -"Cuando esto ocurre, algunos o todos los elementos de la tupla pueden ser :" -"const:`None`." +"Cuando esto ocurre, algunos o todos los elementos de la tupla pueden ser " +":const:`None`." #: ../Doc/reference/datamodel.rst:1149 msgid "" @@ -1795,8 +1879,8 @@ msgstr "" "archivos de Python compilados o del uso de la memoria del intérprete. Para " "evitar almacenar la información extra y/o desactivar la impresión de la " "información extra de seguimiento, se puede usar el indicador de línea de " -"comando :option:`-X` ``no_debug_ranges`` o la variable de entorno :envvar:" -"`PYTHONNODEBUGRANGES`." +"comando :option:`-X` ``no_debug_ranges`` o la variable de entorno " +":envvar:`PYTHONNODEBUGRANGES`." #: ../Doc/reference/datamodel.rst:1160 msgid "Frame objects" @@ -1814,66 +1898,66 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1175 msgid "" "Special read-only attributes: :attr:`f_back` is to the previous stack frame " -"(towards the caller), or ``None`` if this is the bottom stack frame; :attr:" -"`f_code` is the code object being executed in this frame; :attr:`f_locals` " -"is the dictionary used to look up local variables; :attr:`f_globals` is used " -"for global variables; :attr:`f_builtins` is used for built-in (intrinsic) " -"names; :attr:`f_lasti` gives the precise instruction (this is an index into " -"the bytecode string of the code object)." +"(towards the caller), or ``None`` if this is the bottom stack frame; " +":attr:`f_code` is the code object being executed in this frame; " +":attr:`f_locals` is the dictionary used to look up local variables; " +":attr:`f_globals` is used for global variables; :attr:`f_builtins` is used " +"for built-in (intrinsic) names; :attr:`f_lasti` gives the precise " +"instruction (this is an index into the bytecode string of the code object)." msgstr "" "Atributos especiales de solo lectura: :attr:`f_back` es para el marco de " "pila anterior (hacia quien produce el llamado), o ``None`` si éste es el " "marco de pila inferior; :attr:`f_code` es el objeto de código ejecutado en " "este marco; :attr:`f_locals` es el diccionario utilizado para buscar " -"variables locales; :attr:`f_globals` es usado por las variables globales; :" -"attr:`f_builtins` es utilizado por nombres incorporados (intrínsecos); :attr:" -"`f_lasti` da la instrucción precisa (éste es un índice dentro de la cadena " -"de bytecode del objeto de código)." +"variables locales; :attr:`f_globals` es usado por las variables globales; " +":attr:`f_builtins` es utilizado por nombres incorporados (intrínsecos); " +":attr:`f_lasti` da la instrucción precisa (éste es un índice dentro de la " +"cadena de bytecode del objeto de código)." #: ../Doc/reference/datamodel.rst:1183 msgid "" -"Accessing ``f_code`` raises an :ref:`auditing event ` ``object." -"__getattr__`` with arguments ``obj`` and ``\"f_code\"``." +"Accessing ``f_code`` raises an :ref:`auditing event ` " +"``object.__getattr__`` with arguments ``obj`` and ``\"f_code\"``." msgstr "" "Acceder a ``f_code`` lanza un objeto :ref:`evento de auditoría ` " "``.__getattr__`` con argumentos ``obj`` y ``\"f_code\"`` ." #: ../Doc/reference/datamodel.rst:1192 msgid "" -"Special writable attributes: :attr:`f_trace`, if not ``None``, is a function " -"called for various events during code execution (this is used by the " +"Special writable attributes: :attr:`f_trace`, if not ``None``, is a function" +" called for various events during code execution (this is used by the " "debugger). Normally an event is triggered for each new source line - this " "can be disabled by setting :attr:`f_trace_lines` to :const:`False`." msgstr "" -"Atributos especiales escribibles: :attr:`f_trace`, de lo contrario ``None``, " -"es una función llamada por distintos eventos durante la ejecución del código " -"(éste es utilizado por el depurador). Normalmente un evento es desencadenado " -"por cada una de las líneas fuente - esto puede ser deshabilitado " -"estableciendo :attr:`f_trace_lines` a :const:`False`." +"Atributos especiales escribibles: :attr:`f_trace`, de lo contrario ``None``," +" es una función llamada por distintos eventos durante la ejecución del " +"código (éste es utilizado por el depurador). Normalmente un evento es " +"desencadenado por cada una de las líneas fuente - esto puede ser " +"deshabilitado estableciendo :attr:`f_trace_lines` a :const:`False`." #: ../Doc/reference/datamodel.rst:1197 msgid "" -"Implementations *may* allow per-opcode events to be requested by setting :" -"attr:`f_trace_opcodes` to :const:`True`. Note that this may lead to " +"Implementations *may* allow per-opcode events to be requested by setting " +":attr:`f_trace_opcodes` to :const:`True`. Note that this may lead to " "undefined interpreter behaviour if exceptions raised by the trace function " "escape to the function being traced." msgstr "" "Las implementaciones *pueden* permitir que eventos por código de operación " "sean solicitados estableciendo :attr:`f_trace_opcodes` a :const:`True`. " "Tenga en cuenta que esto puede llevar a un comportamiento indefinido del " -"intérprete si se levantan excepciones por la función de rastreo escape hacia " -"la función que está siendo rastreada." +"intérprete si se levantan excepciones por la función de rastreo escape hacia" +" la función que está siendo rastreada." #: ../Doc/reference/datamodel.rst:1202 msgid "" -":attr:`f_lineno` is the current line number of the frame --- writing to this " -"from within a trace function jumps to the given line (only for the bottom-" +":attr:`f_lineno` is the current line number of the frame --- writing to this" +" from within a trace function jumps to the given line (only for the bottom-" "most frame). A debugger can implement a Jump command (aka Set Next " "Statement) by writing to f_lineno." msgstr "" ":attr:`f_lineno` es el número de línea actual del marco --- escribiendo a " -"esta forma dentro de una función de rastreo salta a la línea dada (solo para " -"el último marco). Un depurador puede implementar un comando de salto " +"esta forma dentro de una función de rastreo salta a la línea dada (solo para" +" el último marco). Un depurador puede implementar un comando de salto " "(*Jump*) (también conocido como *Set Next Statement*) al escribir en " "f_lineno." @@ -1890,8 +1974,8 @@ msgid "" msgstr "" "Este método limpia todas las referencias a variables locales mantenidas por " "el marco. También, si el marco pertenecía a un generador, éste es " -"finalizado. Esto ayuda a interrumpir los ciclos de referencia que involucran " -"objetos de marco (por ejemplo al detectar una excepción y almacenando su " +"finalizado. Esto ayuda a interrumpir los ciclos de referencia que involucran" +" objetos de marco (por ejemplo al detectar una excepción y almacenando su " "rastro para uso posterior)." #: ../Doc/reference/datamodel.rst:1217 @@ -1909,8 +1993,8 @@ msgid "" "explicitly created by calling :class:`types.TracebackType`." msgstr "" "Los objetos de seguimiento de pila representan el trazo de pila (*stack " -"trace*) de una excepción. Un objeto de rastreo es creado de manera implícita " -"cuando se da una excepción, y puede ser creada de manera explícita al " +"trace*) de una excepción. Un objeto de rastreo es creado de manera implícita" +" cuando se da una excepción, y puede ser creada de manera explícita al " "llamar :class:`types.TracebackType`." #: ../Doc/reference/datamodel.rst:1242 @@ -1918,23 +2002,26 @@ msgid "" "For implicitly created tracebacks, when the search for an exception handler " "unwinds the execution stack, at each unwound level a traceback object is " "inserted in front of the current traceback. When an exception handler is " -"entered, the stack trace is made available to the program. (See section :ref:" -"`try`.) It is accessible as the third item of the tuple returned by ``sys." -"exc_info()``, and as the ``__traceback__`` attribute of the caught exception." +"entered, the stack trace is made available to the program. (See section " +":ref:`try`.) It is accessible as the third item of the tuple returned by " +"``sys.exc_info()``, and as the ``__traceback__`` attribute of the caught " +"exception." msgstr "" "Para seguimientos de pila (tracebacks) creados de manera implícita, cuando " "la búsqueda por un manejo de excepciones desenvuelve la pila de ejecución, " "en cada nivel de desenvolvimiento se inserta un objeto de rastreo al frente " "del rastreo actual. Cuando se entra a un manejo de excepción, la pila de " "rastreo se vuelve disponible para el programa. (Ver sección :ref:`try`.) Es " -"accesible como el tercer elemento de la tupla retornada por ``sys." -"exc_info()``, y como el atributo ``__traceback__`` de la excepción capturada." +"accesible como el tercer elemento de la tupla retornada por " +"``sys.exc_info()``, y como el atributo ``__traceback__`` de la excepción " +"capturada." #: ../Doc/reference/datamodel.rst:1250 msgid "" "When the program contains no suitable handler, the stack trace is written " "(nicely formatted) to the standard error stream; if the interpreter is " -"interactive, it is also made available to the user as ``sys.last_traceback``." +"interactive, it is also made available to the user as " +"``sys.last_traceback``." msgstr "" "Cuando el programa no contiene un gestor apropiado, el trazo de pila es " "escrito (muy bien formateado) a la secuencia de error estándar; si el " @@ -1953,8 +2040,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1265 msgid "" -"Special read-only attributes: :attr:`tb_frame` points to the execution frame " -"of the current level; :attr:`tb_lineno` gives the line number where the " +"Special read-only attributes: :attr:`tb_frame` points to the execution frame" +" of the current level; :attr:`tb_lineno` gives the line number where the " "exception occurred; :attr:`tb_lasti` indicates the precise instruction. The " "line number and last instruction in the traceback may differ from the line " "number of its frame object if the exception occurred in a :keyword:`try` " @@ -1964,23 +2051,23 @@ msgstr "" "ejecución del nivel actual; :attr:`tb_lineno` da el número de línea donde " "ocurrió la excepción; :attr:`tb_lasti` indica la instrucción precisa. El " "número de línea y la última instrucción en el seguimiento de pila puede " -"diferir del número de línea de su objeto de marco si la excepción ocurrió en " -"una declaración :keyword:`try` sin una cláusula de excepción (except) " +"diferir del número de línea de su objeto de marco si la excepción ocurrió en" +" una declaración :keyword:`try` sin una cláusula de excepción (except) " "correspondiente o con una cláusula *finally*." #: ../Doc/reference/datamodel.rst:1274 msgid "" -"Accessing ``tb_frame`` raises an :ref:`auditing event ` ``object." -"__getattr__`` with arguments ``obj`` and ``\"tb_frame\"``." +"Accessing ``tb_frame`` raises an :ref:`auditing event ` " +"``object.__getattr__`` with arguments ``obj`` and ``\"tb_frame\"``." msgstr "" -"Acceder a ``tb_frame`` lanza un objeto :ref:`evento de auditoría ` " -"``.__getattr__`` con argumentos ``obj`` y ``tb_frame``." +"Acceder a ``tb_frame`` lanza un objeto :ref:`evento de auditoría `" +" ``.__getattr__`` con argumentos ``obj`` y ``tb_frame``." #: ../Doc/reference/datamodel.rst:1280 msgid "" "Special writable attribute: :attr:`tb_next` is the next level in the stack " -"trace (towards the frame where the exception occurred), or ``None`` if there " -"is no next level." +"trace (towards the frame where the exception occurred), or ``None`` if there" +" is no next level." msgstr "" "Atributo especial escribible: :attr:`tb_next` es el siguiente nivel en el " "trazo de pila (hacia el marco en donde ocurrió la excepción), o ``None`` si " @@ -2004,20 +2091,20 @@ msgid "" "Slice objects are used to represent slices for :meth:`~object.__getitem__` " "methods. They are also created by the built-in :func:`slice` function." msgstr "" -"Los objetos de sector se utilizan para representar sectores para métodos :" -"meth:`~object.__getitem__`. También son creados por la función integrada :" -"func:`slice`." +"Los objetos de sector se utilizan para representar sectores para métodos " +":meth:`~object.__getitem__`. También son creados por la función integrada " +":func:`slice`." #: ../Doc/reference/datamodel.rst:1303 msgid "" -"Special read-only attributes: :attr:`~slice.start` is the lower bound; :attr:" -"`~slice.stop` is the upper bound; :attr:`~slice.step` is the step value; " -"each is ``None`` if omitted. These attributes can have any type." +"Special read-only attributes: :attr:`~slice.start` is the lower bound; " +":attr:`~slice.stop` is the upper bound; :attr:`~slice.step` is the step " +"value; each is ``None`` if omitted. These attributes can have any type." msgstr "" "Atributos especiales de solo lectura: :attr:`~slice.start` es el límite " "inferior; :attr:`~slice.stop` es el límite superior; :attr:`~slice.step` es " -"el valor de paso; cada uno es ``None`` si es omitido. Estos atributos pueden " -"ser de cualquier tipo." +"el valor de paso; cada uno es ``None`` si es omitido. Estos atributos pueden" +" ser de cualquier tipo." #: ../Doc/reference/datamodel.rst:1307 msgid "Slice objects support one method:" @@ -2053,15 +2140,15 @@ msgid "" "any further transformation. Static method objects are also callable. Static " "method objects are created by the built-in :func:`staticmethod` constructor." msgstr "" -"Los objetos de método estático proveen una forma de anular la transformación " -"de objetos de función a objetos de método descritos anteriormente. Un objeto " -"de método estático es una envoltura (*wrapper*) alrededor de cualquier otro " -"objeto, usualmente un objeto de método definido por usuario. Cuando un " -"objeto de método estático es obtenido desde una clase o una instancia de " -"clase, usualmente el objeto retornado es el objeto envuelto, el cual no está " -"objeto a ninguna transformación adicional. Los objetos de método estático " -"también pueden ser llamados. Los objetos de método estático son creados por " -"el constructor incorporado :func:`staticmethod`." +"Los objetos de método estático proveen una forma de anular la transformación" +" de objetos de función a objetos de método descritos anteriormente. Un " +"objeto de método estático es una envoltura (*wrapper*) alrededor de " +"cualquier otro objeto, usualmente un objeto de método definido por usuario. " +"Cuando un objeto de método estático es obtenido desde una clase o una " +"instancia de clase, usualmente el objeto retornado es el objeto envuelto, el" +" cual no está objeto a ninguna transformación adicional. Los objetos de " +"método estático también pueden ser llamados. Los objetos de método estático " +"son creados por el constructor incorporado :func:`staticmethod`." #: ../Doc/reference/datamodel.rst:1332 msgid "Class method objects" @@ -2071,8 +2158,8 @@ msgstr "Objetos de método de clase" msgid "" "A class method object, like a static method object, is a wrapper around " "another object that alters the way in which that object is retrieved from " -"classes and class instances. The behaviour of class method objects upon such " -"retrieval is described above, under \"User-defined methods\". Class method " +"classes and class instances. The behaviour of class method objects upon such" +" retrieval is described above, under \"User-defined methods\". Class method " "objects are created by the built-in :func:`classmethod` constructor." msgstr "" "Un objeto de método de clase, igual que un objeto de método estático, es un " @@ -2080,8 +2167,8 @@ msgstr "" "el objeto es obtenido desde las clases y las instancias de clase. El " "comportamiento de los objetos de método de clase sobre tal obtención es " "descrita más arriba, debajo de “Métodos definidos por usuario”. Objetos de " -"clase de método son creados por el constructor incorporado :func:" -"`classmethod`." +"clase de método son creados por el constructor incorporado " +":func:`classmethod`." #: ../Doc/reference/datamodel.rst:1344 msgid "Special method names" @@ -2093,31 +2180,47 @@ msgid "" "(such as arithmetic operations or subscripting and slicing) by defining " "methods with special names. This is Python's approach to :dfn:`operator " "overloading`, allowing classes to define their own behavior with respect to " -"language operators. For instance, if a class defines a method named :meth:" -"`~object.__getitem__`, and ``x`` is an instance of this class, then ``x[i]`` " -"is roughly equivalent to ``type(x).__getitem__(x, i)``. Except where " -"mentioned, attempts to execute an operation raise an exception when no " -"appropriate method is defined (typically :exc:`AttributeError` or :exc:" -"`TypeError`)." -msgstr "" +"language operators. For instance, if a class defines a method named " +":meth:`~object.__getitem__`, and ``x`` is an instance of this class, then " +"``x[i]`` is roughly equivalent to ``type(x).__getitem__(x, i)``. Except " +"where mentioned, attempts to execute an operation raise an exception when no" +" appropriate method is defined (typically :exc:`AttributeError` or " +":exc:`TypeError`)." +msgstr "" +"Una clase puede implementar ciertas operaciones que se invocan mediante una " +"sintaxis especial (como operaciones aritméticas o subíndices y divisiones) " +"definiendo métodos con nombres especiales. Este es el enfoque de Python para" +" :dfn:`sobrecarga de operadores`, permitiendo a las clases definir su propio" +" comportamiento con respecto a los operadores del lenguaje. Por ejemplo, si " +"una clase define un método denominado :meth:`~object.__getitem__` y ``x`` es" +" una instancia de esta clase, entonces ``x[i]`` es aproximadamente " +"equivalente a ``type(x).__getitem__(x, i)``. Excepto donde se mencione, los " +"intentos de ejecutar una operación generan una excepción cuando no se define" +" ningún método apropiado (normalmente :exc:`AttributeError` o " +":exc:`TypeError`)." #: ../Doc/reference/datamodel.rst:1361 msgid "" "Setting a special method to ``None`` indicates that the corresponding " -"operation is not available. For example, if a class sets :meth:`~object." -"__iter__` to ``None``, the class is not iterable, so calling :func:`iter` on " -"its instances will raise a :exc:`TypeError` (without falling back to :meth:" -"`~object.__getitem__`). [#]_" +"operation is not available. For example, if a class sets " +":meth:`~object.__iter__` to ``None``, the class is not iterable, so calling " +":func:`iter` on its instances will raise a :exc:`TypeError` (without falling" +" back to :meth:`~object.__getitem__`). [#]_" msgstr "" +"Establecer un método especial en ``None`` indica que la operación " +"correspondiente no está disponible. Por ejemplo, si una clase establece " +":meth:`~object.__iter__` en ``None``, la clase no es iterable, por lo que " +"llamar a :func:`iter` en sus instancias generará un :exc:`TypeError` (sin " +"recurrir a :meth:`~object.__getitem__`). [#]_" #: ../Doc/reference/datamodel.rst:1367 msgid "" "When implementing a class that emulates any built-in type, it is important " -"that the emulation only be implemented to the degree that it makes sense for " -"the object being modelled. For example, some sequences may work well with " -"retrieval of individual elements, but extracting a slice may not make " -"sense. (One example of this is the :class:`~xml.dom.NodeList` interface in " -"the W3C's Document Object Model.)" +"that the emulation only be implemented to the degree that it makes sense for" +" the object being modelled. For example, some sequences may work well with " +"retrieval of individual elements, but extracting a slice may not make sense." +" (One example of this is the :class:`~xml.dom.NodeList` interface in the " +"W3C's Document Object Model.)" msgstr "" "Cuando se implementa una clase que emula cualquier tipo incorporado, es " "importante que la emulación solo sea implementado al grado que hace sentido " @@ -2133,15 +2236,15 @@ msgstr "Personalización básica" #: ../Doc/reference/datamodel.rst:1384 msgid "" -"Called to create a new instance of class *cls*. :meth:`__new__` is a static " -"method (special-cased so you need not declare it as such) that takes the " +"Called to create a new instance of class *cls*. :meth:`__new__` is a static" +" method (special-cased so you need not declare it as such) that takes the " "class of which an instance was requested as its first argument. The " "remaining arguments are those passed to the object constructor expression " "(the call to the class). The return value of :meth:`__new__` should be the " "new object instance (usually an instance of *cls*)." msgstr "" -"Es llamado para crear una nueva instancia de clase *cls*. :meth:`__new__` es " -"un método estático (como un caso especial, así que no se necesita declarar " +"Es llamado para crear una nueva instancia de clase *cls*. :meth:`__new__` es" +" un método estático (como un caso especial, así que no se necesita declarar " "como tal) que toma la clase de donde fue solicitada una instancia como su " "primer argumento. Los argumentos restantes son aquellos que se pasan a la " "expresión del constructor de objetos (para llamar a la clase). El valor " @@ -2155,20 +2258,24 @@ msgid "" "with appropriate arguments and then modifying the newly created instance as " "necessary before returning it." msgstr "" +"Las implementaciones típicas crean una nueva instancia de la clase invocando" +" el método :meth:`__new__` de la superclase usando ``super().__new__(cls[, " +"...])`` con los argumentos apropiados y luego modificando la instancia " +"recién creada según sea necesario antes de retornarla." #: ../Doc/reference/datamodel.rst:1396 msgid "" "If :meth:`__new__` is invoked during object construction and it returns an " "instance of *cls*, then the new instance’s :meth:`__init__` method will be " -"invoked like ``__init__(self[, ...])``, where *self* is the new instance and " -"the remaining arguments are the same as were passed to the object " +"invoked like ``__init__(self[, ...])``, where *self* is the new instance and" +" the remaining arguments are the same as were passed to the object " "constructor." msgstr "" "Si :meth:`__new__` es invocado durante la construcción del objeto y éste " -"retorna una instancia de *cls*, entonces el nuevo método :meth:`__init__` de " -"la instancia será invocado como ``__init__(self[, …])``, donde *self* es la " -"nueva instancia y los argumentos restantes son iguales a como fueron pasados " -"hacia el constructor de objetos." +"retorna una instancia de *cls*, entonces el nuevo método :meth:`__init__` de" +" la instancia será invocado como ``__init__(self[, …])``, donde *self* es la" +" nueva instancia y los argumentos restantes son iguales a como fueron " +"pasados hacia el constructor de objetos." #: ../Doc/reference/datamodel.rst:1401 msgid "" @@ -2194,9 +2301,9 @@ msgstr "" msgid "" "Called after the instance has been created (by :meth:`__new__`), but before " "it is returned to the caller. The arguments are those passed to the class " -"constructor expression. If a base class has an :meth:`__init__` method, the " -"derived class's :meth:`__init__` method, if any, must explicitly call it to " -"ensure proper initialization of the base class part of the instance; for " +"constructor expression. If a base class has an :meth:`__init__` method, the" +" derived class's :meth:`__init__` method, if any, must explicitly call it to" +" ensure proper initialization of the base class part of the instance; for " "example: ``super().__init__([args...])``." msgstr "" "Llamado después de que la instancia ha sido creada (por :meth:`__new__`), " @@ -2214,23 +2321,23 @@ msgid "" "it), no non-``None`` value may be returned by :meth:`__init__`; doing so " "will cause a :exc:`TypeError` to be raised at runtime." msgstr "" -"Debido a que :meth:`__new__` y :meth:`__init__` trabajan juntos construyendo " -"objetos (:meth:`__new__` para crearlo y :meth:`__init__` para " -"personalizarlo), ningún valor distinto a ``None`` puede ser retornado por :" -"meth:`__init__`; hacer esto puede causar que se lance una excepción :exc:" -"`TypeError` en tiempo de ejecución." +"Debido a que :meth:`__new__` y :meth:`__init__` trabajan juntos construyendo" +" objetos (:meth:`__new__` para crearlo y :meth:`__init__` para " +"personalizarlo), ningún valor distinto a ``None`` puede ser retornado por " +":meth:`__init__`; hacer esto puede causar que se lance una excepción " +":exc:`TypeError` en tiempo de ejecución." #: ../Doc/reference/datamodel.rst:1433 msgid "" "Called when the instance is about to be destroyed. This is also called a " -"finalizer or (improperly) a destructor. If a base class has a :meth:" -"`__del__` method, the derived class's :meth:`__del__` method, if any, must " -"explicitly call it to ensure proper deletion of the base class part of the " -"instance." +"finalizer or (improperly) a destructor. If a base class has a " +":meth:`__del__` method, the derived class's :meth:`__del__` method, if any, " +"must explicitly call it to ensure proper deletion of the base class part of " +"the instance." msgstr "" "Llamado cuando la instancia es a punto de ser destruida. Esto también es " -"llamado finalizador o (indebidamente) destructor. Si una clase base tiene un " -"método :meth:`__del__` el método :meth:`__del__` de la clase derivada, de " +"llamado finalizador o (indebidamente) destructor. Si una clase base tiene un" +" método :meth:`__del__` el método :meth:`__del__` de la clase derivada, de " "existir, debe llamarlo explícitamente para asegurar la eliminación adecuada " "de la parte de la clase base de la instancia." @@ -2239,9 +2346,9 @@ msgid "" "It is possible (though not recommended!) for the :meth:`__del__` method to " "postpone destruction of the instance by creating a new reference to it. " "This is called object *resurrection*. It is implementation-dependent " -"whether :meth:`__del__` is called a second time when a resurrected object is " -"about to be destroyed; the current :term:`CPython` implementation only calls " -"it once." +"whether :meth:`__del__` is called a second time when a resurrected object is" +" about to be destroyed; the current :term:`CPython` implementation only " +"calls it once." msgstr "" "Es posible (¡aunque no recomendable!) para el método :meth:`__del__` " "posponer la destrucción de la instancia al crear una nueva referencia hacia " @@ -2272,14 +2379,14 @@ msgstr "" msgid "" "It is possible for a reference cycle to prevent the reference count of an " "object from going to zero. In this case, the cycle will be later detected " -"and deleted by the :term:`cyclic garbage collector `. A " -"common cause of reference cycles is when an exception has been caught in a " +"and deleted by the :term:`cyclic garbage collector `. A" +" common cause of reference cycles is when an exception has been caught in a " "local variable. The frame's locals then reference the exception, which " "references its own traceback, which references the locals of all frames " "caught in the traceback." msgstr "" -"Es posible que un ciclo de referencia evite que el recuento de referencia de " -"un objeto llegue a cero. En este caso, el ciclo será posteriormente " +"Es posible que un ciclo de referencia evite que el recuento de referencia de" +" un objeto llegue a cero. En este caso, el ciclo será posteriormente " "detectado y eliminado por el :term:`cyclic garbage collector `. Una causa común de los ciclos de referencia es cuando se " "detecta una excepción en una variable local. Luego, los locales del marco " @@ -2297,40 +2404,40 @@ msgid "" "invoked, exceptions that occur during their execution are ignored, and a " "warning is printed to ``sys.stderr`` instead. In particular:" msgstr "" -"Debido a las circunstancias inciertas bajo las que los métodos :meth:" -"`__del__` son invocados, las excepciones que ocurren durante su ejecución " -"son ignoradas, y una advertencia es mostrada hacia ``sys.stderr``. En " -"particular:" +"Debido a las circunstancias inciertas bajo las que los métodos " +":meth:`__del__` son invocados, las excepciones que ocurren durante su " +"ejecución son ignoradas, y una advertencia es mostrada hacia ``sys.stderr``." +" En particular:" #: ../Doc/reference/datamodel.rst:1474 msgid "" ":meth:`__del__` can be invoked when arbitrary code is being executed, " "including from any arbitrary thread. If :meth:`__del__` needs to take a " "lock or invoke any other blocking resource, it may deadlock as the resource " -"may already be taken by the code that gets interrupted to execute :meth:" -"`__del__`." +"may already be taken by the code that gets interrupted to execute " +":meth:`__del__`." msgstr "" ":meth:`__del__` puede ser invocado cuando código arbitrario es ejecutado, " "incluyendo el de cualquier hilo arbitrario. Si :meth:`__del__` necesita " "realizar un cierre de exclusión mutua (*lock*) o invocar cualquier otro " -"recurso que lo esté bloqueando, podría provocar un bloqueo muto (*deadlock*) " -"ya que el recurso podría estar siendo utilizado por el código que se " +"recurso que lo esté bloqueando, podría provocar un bloqueo muto (*deadlock*)" +" ya que el recurso podría estar siendo utilizado por el código que se " "interrumpe al ejecutar :meth:`__del__`." #: ../Doc/reference/datamodel.rst:1480 msgid "" ":meth:`__del__` can be executed during interpreter shutdown. As a " "consequence, the global variables it needs to access (including other " -"modules) may already have been deleted or set to ``None``. Python guarantees " -"that globals whose name begins with a single underscore are deleted from " +"modules) may already have been deleted or set to ``None``. Python guarantees" +" that globals whose name begins with a single underscore are deleted from " "their module before other globals are deleted; if no other references to " "such globals exist, this may help in assuring that imported modules are " "still available at the time when the :meth:`__del__` method is called." msgstr "" ":meth:`__del__` puede ser ejecutado durante el cierre del intérprete. Como " "consecuencia, las variables globales que necesita para acceder (incluyendo " -"otros módulos) podrían haber sido borradas o establecidas a ``None``. Python " -"garantiza que los globales cuyo nombre comienza con un guión bajo simple " +"otros módulos) podrían haber sido borradas o establecidas a ``None``. Python" +" garantiza que los globales cuyo nombre comienza con un guión bajo simple " "sean borrados de su módulo antes que los globales sean borrados; si no " "existen otras referencias a dichas globales, esto puede ayudar asegurando " "que los módulos importados aún se encuentren disponibles al momento de " @@ -2340,18 +2447,19 @@ msgstr "" msgid "" "Called by the :func:`repr` built-in function to compute the \"official\" " "string representation of an object. If at all possible, this should look " -"like a valid Python expression that could be used to recreate an object with " -"the same value (given an appropriate environment). If this is not possible, " -"a string of the form ``<...some useful description...>`` should be returned. " -"The return value must be a string object. If a class defines :meth:" -"`__repr__` but not :meth:`__str__`, then :meth:`__repr__` is also used when " -"an \"informal\" string representation of instances of that class is required." +"like a valid Python expression that could be used to recreate an object with" +" the same value (given an appropriate environment). If this is not " +"possible, a string of the form ``<...some useful description...>`` should be" +" returned. The return value must be a string object. If a class defines " +":meth:`__repr__` but not :meth:`__str__`, then :meth:`__repr__` is also used" +" when an \"informal\" string representation of instances of that class is " +"required." msgstr "" "Llamado por la función incorporada :func:`repr` para calcular la cadena " "“oficial” de representación de un objeto. Si es posible, esto debería verse " "como una expresión de Python válida que puede ser utilizada para recrear un " -"objeto con el mismo valor (bajo el ambiente adecuado). Si no es posible, una " -"cadena con la forma ``<…some useful description…>`` debe ser retornada. El " +"objeto con el mismo valor (bajo el ambiente adecuado). Si no es posible, una" +" cadena con la forma ``<…some useful description…>`` debe ser retornada. El " "valor de retorno debe ser un objeto de cadena (*string*). Si una clase " "define :meth:`__repr__` pero no :meth:`__str__`, entonces :meth:`__repr__` " "también es utilizado cuando una cadena “informal” de representación de " @@ -2367,15 +2475,15 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1515 msgid "" -"Called by :func:`str(object) ` and the built-in functions :func:" -"`format` and :func:`print` to compute the \"informal\" or nicely printable " -"string representation of an object. The return value must be a :ref:`string " -"` object." +"Called by :func:`str(object) ` and the built-in functions " +":func:`format` and :func:`print` to compute the \"informal\" or nicely " +"printable string representation of an object. The return value must be a " +":ref:`string ` object." msgstr "" -"Llamado por :func:`str(object) ` y las funciones incorporadas :func:" -"`format` y :func:`print` para calcular la “informal” o bien mostrada cadena " -"de representación de un objeto. El valor de retorno debe ser un objeto :ref:" -"`string `." +"Llamado por :func:`str(object) ` y las funciones incorporadas " +":func:`format` y :func:`print` para calcular la “informal” o bien mostrada " +"cadena de representación de un objeto. El valor de retorno debe ser un " +"objeto :ref:`string `." #: ../Doc/reference/datamodel.rst:1520 msgid "" @@ -2383,8 +2491,8 @@ msgid "" "expectation that :meth:`__str__` return a valid Python expression: a more " "convenient or concise representation can be used." msgstr "" -"Este método difiere de :meth:`object.__repr__` en que no hay expectativas de " -"que :meth:`__str__` retorne una expresión de Python válida: una " +"Este método difiere de :meth:`object.__repr__` en que no hay expectativas de" +" que :meth:`__str__` retorne una expresión de Python válida: una " "representación más conveniente o concisa pueda ser utilizada." #: ../Doc/reference/datamodel.rst:1524 @@ -2392,8 +2500,8 @@ msgid "" "The default implementation defined by the built-in type :class:`object` " "calls :meth:`object.__repr__`." msgstr "" -"La implementación por defecto definida por el tipo incorporado :class:" -"`object` llama a :meth:`object.__repr__`." +"La implementación por defecto definida por el tipo incorporado " +":class:`object` llama a :meth:`object.__repr__`." #: ../Doc/reference/datamodel.rst:1534 msgid "" @@ -2405,23 +2513,24 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1545 msgid "" -"Called by the :func:`format` built-in function, and by extension, evaluation " -"of :ref:`formatted string literals ` and the :meth:`str.format` " +"Called by the :func:`format` built-in function, and by extension, evaluation" +" of :ref:`formatted string literals ` and the :meth:`str.format` " "method, to produce a \"formatted\" string representation of an object. The " "*format_spec* argument is a string that contains a description of the " -"formatting options desired. The interpretation of the *format_spec* argument " -"is up to the type implementing :meth:`__format__`, however most classes will " -"either delegate formatting to one of the built-in types, or use a similar " -"formatting option syntax." +"formatting options desired. The interpretation of the *format_spec* argument" +" is up to the type implementing :meth:`__format__`, however most classes " +"will either delegate formatting to one of the built-in types, or use a " +"similar formatting option syntax." msgstr "" "Llamado por la función incorporada :func:`format`, y por extensión, la " -"evaluación de :ref:`formatted string literals ` y el método :meth:" -"`str.format`, para producir la representación “formateada” de un objeto. El " -"argumento *format_spec* es una cadena que contiene una descripción de las " -"opciones de formato deseadas. La interpretación del argumento *format_spec* " -"depende del tipo que implementa :meth:`__format__`, sin embargo, ya sea que " -"la mayoría de las clases deleguen el formato a uno de los tipos " -"incorporados, o utilicen una sintaxis de opción de formato similar." +"evaluación de :ref:`formatted string literals ` y el método " +":meth:`str.format`, para producir la representación “formateada” de un " +"objeto. El argumento *format_spec* es una cadena que contiene una " +"descripción de las opciones de formato deseadas. La interpretación del " +"argumento *format_spec* depende del tipo que implementa :meth:`__format__`, " +"sin embargo, ya sea que la mayoría de las clases deleguen el formato a uno " +"de los tipos incorporados, o utilicen una sintaxis de opción de formato " +"similar." #: ../Doc/reference/datamodel.rst:1555 msgid "" @@ -2439,8 +2548,8 @@ msgid "" "The __format__ method of ``object`` itself raises a :exc:`TypeError` if " "passed any non-empty string." msgstr "" -"El método __format__ del mismo ``object`` lanza un :exc:`TypeError` si se la " -"pasa una cadena no vacía." +"El método __format__ del mismo ``object`` lanza un :exc:`TypeError` si se la" +" pasa una cadena no vacía." #: ../Doc/reference/datamodel.rst:1563 msgid "" @@ -2453,10 +2562,10 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1579 msgid "" "These are the so-called \"rich comparison\" methods. The correspondence " -"between operator symbols and method names is as follows: ``xy`` calls ``x.__gt__(y)``, and ``x>=y`` " -"calls ``x.__ge__(y)``." +"between operator symbols and method names is as follows: ``xy`` calls " +"``x.__gt__(y)``, and ``x>=y`` calls ``x.__ge__(y)``." msgstr "" "Estos son los llamados métodos de comparación *rich*. La correspondencia " "entre símbolos de operador y los nombres de método es de la siguiente " @@ -2468,8 +2577,8 @@ msgstr "" msgid "" "A rich comparison method may return the singleton ``NotImplemented`` if it " "does not implement the operation for a given pair of arguments. By " -"convention, ``False`` and ``True`` are returned for a successful comparison. " -"However, these methods can return any value, so if the comparison operator " +"convention, ``False`` and ``True`` are returned for a successful comparison." +" However, these methods can return any value, so if the comparison operator " "is used in a Boolean context (e.g., in the condition of an ``if`` " "statement), Python will call :func:`bool` on the value to determine if the " "result is true or false." @@ -2477,8 +2586,8 @@ msgstr "" "Un método de comparación *rich* puede retornar el único ``NotImplemented`` " "si no implementa la operación para un par de argumentos dados. Por " "convención, ``False`` y ``True`` son retornados para una comparación " -"exitosa. Sin embargo, estos métodos pueden retornar cualquier valor, así que " -"si el operador de comparación es utilizado en un contexto Booleano (p. ej. " +"exitosa. Sin embargo, estos métodos pueden retornar cualquier valor, así que" +" si el operador de comparación es utilizado en un contexto Booleano (p. ej. " "en la condición de una sentencia ``if``), Python llamará :func:`bool` en " "dicho valor para determinar si el resultado es verdadero (*true*) o falso " "(*false*)." @@ -2487,124 +2596,139 @@ msgstr "" msgid "" "By default, ``object`` implements :meth:`__eq__` by using ``is``, returning " "``NotImplemented`` in the case of a false comparison: ``True if x is y else " -"NotImplemented``. For :meth:`__ne__`, by default it delegates to :meth:" -"`__eq__` and inverts the result unless it is ``NotImplemented``. There are " -"no other implied relationships among the comparison operators or default " -"implementations; for example, the truth of ``(x` y :func:`@classmethod `) se implementan como " +"descriptores sin datos. En consecuencia, las instancias pueden redefinir y " +"anular métodos. Esto permite que las instancias individuales adquieran " +"comportamientos que difieren de otras instancias de la misma clase." #: ../Doc/reference/datamodel.rst:2002 msgid "" "The :func:`property` function is implemented as a data descriptor. " "Accordingly, instances cannot override the behavior of a property." msgstr "" -"La función :func:`property` es implementada como un descriptor de datos. Por " -"lo tanto, las instancias no pueden anular el comportamiento de una propiedad." +"La función :func:`property` es implementada como un descriptor de datos. Por" +" lo tanto, las instancias no pueden anular el comportamiento de una " +"propiedad." #: ../Doc/reference/datamodel.rst:2009 msgid "__slots__" @@ -3172,20 +3336,32 @@ msgid "" "and deny the creation of :attr:`~object.__dict__` and *__weakref__* (unless " "explicitly declared in *__slots__* or available in a parent.)" msgstr "" +"*__slots__* nos permite declarar explícitamente miembros de datos (como " +"propiedades) y denegar la creación de :attr:`~object.__dict__` y " +"*__weakref__* (a menos que se declare explícitamente en *__slots__* o esté " +"disponible en un padre)." #: ../Doc/reference/datamodel.rst:2015 msgid "" "The space saved over using :attr:`~object.__dict__` can be significant. " "Attribute lookup speed can be significantly improved as well." msgstr "" +"El espacio ahorrado al usar :attr:`~object.__dict__` puede ser " +"significativo. La velocidad de búsqueda de atributos también se puede " +"mejorar significativamente." #: ../Doc/reference/datamodel.rst:2020 msgid "" "This class variable can be assigned a string, iterable, or sequence of " "strings with variable names used by instances. *__slots__* reserves space " -"for the declared variables and prevents the automatic creation of :attr:" -"`~object.__dict__` and *__weakref__* for each instance." +"for the declared variables and prevents the automatic creation of " +":attr:`~object.__dict__` and *__weakref__* for each instance." msgstr "" +"A esta variable de clase se le puede asignar una cadena, un iterable o una " +"secuencia de cadenas con nombres de variables utilizados por las instancias." +" *__slots__* reserva espacio para las variables declaradas y evita la " +"creación automática de :attr:`~object.__dict__` y *__weakref__* para cada " +"instancia." #: ../Doc/reference/datamodel.rst:2029 msgid "Notes on using *__slots__*:" @@ -3193,10 +3369,13 @@ msgstr "Notas sobre el uso de *__slots__*" #: ../Doc/reference/datamodel.rst:2031 msgid "" -"When inheriting from a class without *__slots__*, the :attr:`~object." -"__dict__` and *__weakref__* attribute of the instances will always be " -"accessible." +"When inheriting from a class without *__slots__*, the " +":attr:`~object.__dict__` and *__weakref__* attribute of the instances will " +"always be accessible." msgstr "" +"Al heredar de una clase sin *__slots__*, los atributos " +":attr:`~object.__dict__` y *__weakref__* de las instancias siempre estarán " +"accesibles." #: ../Doc/reference/datamodel.rst:2035 msgid "" @@ -3206,6 +3385,12 @@ msgid "" "assignment of new variables is desired, then add ``'__dict__'`` to the " "sequence of strings in the *__slots__* declaration." msgstr "" +"Sin una variable :attr:`~object.__dict__`, a las instancias no se les pueden" +" asignar nuevas variables que no figuran en la definición *__slots__*. Los " +"intentos de asignar un nombre de variable no listado generan " +":exc:`AttributeError`. Si desea una asignación dinámica de nuevas variables," +" agregue ``'__dict__'`` a la secuencia de cadenas en la declaración " +"*__slots__*." #: ../Doc/reference/datamodel.rst:2042 msgid "" @@ -3214,23 +3399,39 @@ msgid "" "instances. If weak reference support is needed, then add ``'__weakref__'`` " "to the sequence of strings in the *__slots__* declaration." msgstr "" +"Sin una variable *__weakref__* para cada instancia, las clases que definen " +"*__slots__* no admiten :mod:`weak references ` en sus instancias. " +"Si se necesita soporte de referencia débil, agregue ``'__weakref__'`` a la " +"secuencia de cadenas en la declaración *__slots__*." #: ../Doc/reference/datamodel.rst:2048 msgid "" -"*__slots__* are implemented at the class level by creating :ref:`descriptors " -"` for each variable name. As a result, class attributes cannot " -"be used to set default values for instance variables defined by *__slots__*; " -"otherwise, the class attribute would overwrite the descriptor assignment." +"*__slots__* are implemented at the class level by creating :ref:`descriptors" +" ` for each variable name. As a result, class attributes " +"cannot be used to set default values for instance variables defined by " +"*__slots__*; otherwise, the class attribute would overwrite the descriptor " +"assignment." msgstr "" +"*__slots__* se implementa a nivel de clase creando :ref:`descriptors " +"` para cada nombre de variable. Como resultado, los atributos " +"de clase no se pueden utilizar para establecer valores predeterminados, por " +"ejemplo, variables definidas por *__slots__*; de lo contrario, el atributo " +"de clase sobrescribiría la asignación del descriptor." #: ../Doc/reference/datamodel.rst:2054 msgid "" -"The action of a *__slots__* declaration is not limited to the class where it " -"is defined. *__slots__* declared in parents are available in child classes. " -"However, child subclasses will get a :attr:`~object.__dict__` and " -"*__weakref__* unless they also define *__slots__* (which should only contain " -"names of any *additional* slots)." +"The action of a *__slots__* declaration is not limited to the class where it" +" is defined. *__slots__* declared in parents are available in child " +"classes. However, child subclasses will get a :attr:`~object.__dict__` and " +"*__weakref__* unless they also define *__slots__* (which should only contain" +" names of any *additional* slots)." msgstr "" +"La acción de una declaración *__slots__* no se limita a la clase donde se " +"define. *__slots__* declarado en padres está disponible en clases " +"secundarias. Sin embargo, las subclases secundarias obtendrán " +":attr:`~object.__dict__` y *__weakref__* a menos que también definan " +"*__slots__* (que solo debe contener nombres de cualquier ranura " +"*additional*)." #: ../Doc/reference/datamodel.rst:2060 msgid "" @@ -3250,9 +3451,13 @@ msgstr "" msgid "" ":exc:`TypeError` will be raised if nonempty *__slots__* are defined for a " "class derived from a :c:member:`\"variable-length\" built-in type " -"` such as :class:`int`, :class:`bytes`, and :class:" -"`tuple`." +"` such as :class:`int`, :class:`bytes`, and " +":class:`tuple`." msgstr "" +":exc:`TypeError` se generará si se definen *__slots__* no vacíos para una " +"clase derivada de un :c:member:`\"variable-length\" built-in type " +"` como :class:`int`, :class:`bytes` y " +":class:`tuple`." #: ../Doc/reference/datamodel.rst:2070 msgid "Any non-string :term:`iterable` may be assigned to *__slots__*." @@ -3263,29 +3468,35 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2072 msgid "" "If a :class:`dictionary ` is used to assign *__slots__*, the " -"dictionary keys will be used as the slot names. The values of the dictionary " -"can be used to provide per-attribute docstrings that will be recognised by :" -"func:`inspect.getdoc` and displayed in the output of :func:`help`." +"dictionary keys will be used as the slot names. The values of the dictionary" +" can be used to provide per-attribute docstrings that will be recognised by " +":func:`inspect.getdoc` and displayed in the output of :func:`help`." msgstr "" "Si se utiliza un :class:`dictionary ` para asignar *__slots__*, las " -"claves del diccionario se utilizarán como nombres de ranura. Los valores del " -"diccionario se pueden usar para proporcionar cadenas de documentos por " -"atributo que :func:`inspect.getdoc` reconocerá y mostrará en la salida de :" -"func:`help`." +"claves del diccionario se utilizarán como nombres de ranura. Los valores del" +" diccionario se pueden usar para proporcionar cadenas de documentos por " +"atributo que :func:`inspect.getdoc` reconocerá y mostrará en la salida de " +":func:`help`." #: ../Doc/reference/datamodel.rst:2077 msgid "" ":attr:`~instance.__class__` assignment works only if both classes have the " "same *__slots__*." msgstr "" +"La asignación de :attr:`~instance.__class__` solo funciona si ambas clases " +"tienen el mismo *__slots__*." #: ../Doc/reference/datamodel.rst:2080 msgid "" ":ref:`Multiple inheritance ` with multiple slotted parent " "classes can be used, but only one parent is allowed to have attributes " -"created by slots (the other bases must have empty slot layouts) - violations " -"raise :exc:`TypeError`." +"created by slots (the other bases must have empty slot layouts) - violations" +" raise :exc:`TypeError`." msgstr "" +"Se puede usar :ref:`Multiple inheritance ` con varias clases " +"principales con ranuras, pero solo a una de las clases principales se le " +"permite tener atributos creados por ranuras (las otras bases deben tener " +"diseños de ranuras vacías); las infracciones generan :exc:`TypeError`." #: ../Doc/reference/datamodel.rst:2086 msgid "" @@ -3293,6 +3504,9 @@ msgid "" "created for each of the iterator's values. However, the *__slots__* " "attribute will be an empty iterator." msgstr "" +"Si se utiliza un :term:`iterator` para *__slots__*, entonces se crea un " +":term:`descriptor` para cada uno de los valores del iterador. Sin embargo, " +"el atributo *__slots__* será un iterador vacío." #: ../Doc/reference/datamodel.rst:2094 msgid "Customizing class creation" @@ -3300,13 +3514,20 @@ msgstr "Personalización de creación de clases" #: ../Doc/reference/datamodel.rst:2096 msgid "" -"Whenever a class inherits from another class, :meth:`~object." -"__init_subclass__` is called on the parent class. This way, it is possible " -"to write classes which change the behavior of subclasses. This is closely " -"related to class decorators, but where class decorators only affect the " -"specific class they're applied to, ``__init_subclass__`` solely applies to " -"future subclasses of the class defining the method." -msgstr "" +"Whenever a class inherits from another class, " +":meth:`~object.__init_subclass__` is called on the parent class. This way, " +"it is possible to write classes which change the behavior of subclasses. " +"This is closely related to class decorators, but where class decorators only" +" affect the specific class they're applied to, ``__init_subclass__`` solely " +"applies to future subclasses of the class defining the method." +msgstr "" +"Siempre que una clase hereda de otra clase, se llama a " +":meth:`~object.__init_subclass__` en la clase principal. De esta forma, es " +"posible escribir clases que cambien el comportamiento de las subclases. Esto" +" está estrechamente relacionado con los decoradores de clases, pero mientras" +" los decoradores de clases solo afectan la clase específica a la que se " +"aplican, ``__init_subclass__`` solo se aplica a futuras subclases de la " +"clase que define el método." #: ../Doc/reference/datamodel.rst:2105 msgid "" @@ -3343,8 +3564,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2128 msgid "" "The metaclass hint ``metaclass`` is consumed by the rest of the type " -"machinery, and is never passed to ``__init_subclass__`` implementations. The " -"actual metaclass (rather than the explicit hint) can be accessed as " +"machinery, and is never passed to ``__init_subclass__`` implementations. The" +" actual metaclass (rather than the explicit hint) can be accessed as " "``type(cls)``." msgstr "" "La sugerencia de metaclase ``metaclass`` es consumido por el resto de la " @@ -3357,6 +3578,9 @@ msgid "" "When a class is created, :meth:`type.__new__` scans the class variables and " "makes callbacks to those with a :meth:`~object.__set_name__` hook." msgstr "" +"Cuando se crea una clase, :meth:`type.__new__` escanea las variables de " +"clase y realiza la retrollamada a aquellas con un enlace " +":meth:`~object.__set_name__`." #: ../Doc/reference/datamodel.rst:2141 msgid "" @@ -3368,13 +3592,13 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2147 msgid "" -"If the class variable is assigned after the class is created, :meth:" -"`__set_name__` will not be called automatically. If needed, :meth:" -"`__set_name__` can be called directly::" +"If the class variable is assigned after the class is created, " +":meth:`__set_name__` will not be called automatically. If needed, " +":meth:`__set_name__` can be called directly::" msgstr "" -"Si la variable de clase se asigna después de crear la clase, :meth:" -"`__set_name__` no se llamará automáticamente. Si es necesario, :meth:" -"`__set_name__` se puede llamar directamente::" +"Si la variable de clase se asigna después de crear la clase, " +":meth:`__set_name__` no se llamará automáticamente. Si es necesario, " +":meth:`__set_name__` se puede llamar directamente::" #: ../Doc/reference/datamodel.rst:2158 msgid "See :ref:`class-object-creation` for more details." @@ -3390,9 +3614,9 @@ msgid "" "executed in a new namespace and the class name is bound locally to the " "result of ``type(name, bases, namespace)``." msgstr "" -"Por defecto, las clases son construidas usando :func:`type`. El cuerpo de la " -"clase es ejecutado en un nuevo espacio de nombres y el nombre de la clase es " -"ligado de forma local al resultado de ``type(name, bases, namespace)``." +"Por defecto, las clases son construidas usando :func:`type`. El cuerpo de la" +" clase es ejecutado en un nuevo espacio de nombres y el nombre de la clase " +"es ligado de forma local al resultado de ``type(name, bases, namespace)``." #: ../Doc/reference/datamodel.rst:2177 msgid "" @@ -3401,8 +3625,8 @@ msgid "" "existing class that included such an argument. In the following example, " "both ``MyClass`` and ``MySubclass`` are instances of ``Meta``::" msgstr "" -"El proceso de creación de clase puede ser personalizado pasando el argumento " -"de palabra clave ``metaclass`` en la línea de definición de la clase, o al " +"El proceso de creación de clase puede ser personalizado pasando el argumento" +" de palabra clave ``metaclass`` en la línea de definición de la clase, o al " "heredar de una clase existente que incluya dicho argumento. En el siguiente " "ejemplo, ambos ``MyClass`` y ``MySubclass`` son instancias de ``Meta``::" @@ -3446,41 +3670,51 @@ msgstr "Resolviendo entradas de la Orden de Resolución de Métodos (MRU)" #: ../Doc/reference/datamodel.rst:2208 msgid "" -"If a base that appears in a class definition is not an instance of :class:" -"`type`, then an :meth:`!__mro_entries__` method is searched on the base. If " -"an :meth:`!__mro_entries__` method is found, the base is substituted with " -"the result of a call to :meth:`!__mro_entries__` when creating the class. " -"The method is called with the original bases tuple passed to the *bases* " -"parameter, and must return a tuple of classes that will be used instead of " -"the base. The returned tuple may be empty: in these cases, the original base " -"is ignored." -msgstr "" +"If a base that appears in a class definition is not an instance of " +":class:`type`, then an :meth:`!__mro_entries__` method is searched on the " +"base. If an :meth:`!__mro_entries__` method is found, the base is " +"substituted with the result of a call to :meth:`!__mro_entries__` when " +"creating the class. The method is called with the original bases tuple " +"passed to the *bases* parameter, and must return a tuple of classes that " +"will be used instead of the base. The returned tuple may be empty: in these " +"cases, the original base is ignored." +msgstr "" +"Si una base que aparece en una definición de clase no es una instancia de " +":class:`type`, entonces se busca un método :meth:`!__mro_entries__` en la " +"base. Si se encuentra un método :meth:`!__mro_entries__`, la base se " +"sustituye por el resultado de una llamada a :meth:`!__mro_entries__` al " +"crear la clase. El método se llama con la tupla de bases original pasada al " +"parámetro *bases* y debe retornar una tupla de clases que se utilizará en " +"lugar de la base. La tupla retornada puede estar vacía: en estos casos, se " +"ignora la base original." #: ../Doc/reference/datamodel.rst:2220 msgid ":func:`types.resolve_bases`" -msgstr "" +msgstr ":func:`types.resolve_bases`" #: ../Doc/reference/datamodel.rst:2220 msgid "Dynamically resolve bases that are not instances of :class:`type`." -msgstr "" +msgstr "Resuelva dinámicamente bases que no sean instancias de :class:`type`." #: ../Doc/reference/datamodel.rst:2224 msgid ":func:`types.get_original_bases`" -msgstr "" +msgstr ":func:`types.get_original_bases`" #: ../Doc/reference/datamodel.rst:2223 msgid "" -"Retrieve a class's \"original bases\" prior to modifications by :meth:" -"`~object.__mro_entries__`." +"Retrieve a class's \"original bases\" prior to modifications by " +":meth:`~object.__mro_entries__`." msgstr "" +"Recupera las \"bases originales\" de una clase antes de las modificaciones " +"realizadas por :meth:`~object.__mro_entries__`." #: ../Doc/reference/datamodel.rst:2226 msgid ":pep:`560`" -msgstr "" +msgstr ":pep:`560`" #: ../Doc/reference/datamodel.rst:2227 msgid "Core support for typing module and generic types." -msgstr "" +msgstr "Soporte principal para módulos de escritura y tipos genéricos." #: ../Doc/reference/datamodel.rst:2231 msgid "Determining the appropriate metaclass" @@ -3497,13 +3731,13 @@ msgstr "" msgid "" "if no bases and no explicit metaclass are given, then :func:`type` is used;" msgstr "" -"si no se dan bases ni metaclases explícitas, entonces se utiliza :func:" -"`type`;" +"si no se dan bases ni metaclases explícitas, entonces se utiliza " +":func:`type`;" #: ../Doc/reference/datamodel.rst:2238 msgid "" -"if an explicit metaclass is given and it is *not* an instance of :func:" -"`type`, then it is used directly as the metaclass;" +"if an explicit metaclass is given and it is *not* an instance of " +":func:`type`, then it is used directly as the metaclass;" msgstr "" "si se da una metaclase explícita y *no* es una instancia de :func:`type`, " "entonces se utiliza directamente como la metaclase;" @@ -3519,14 +3753,14 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2243 msgid "" "The most derived metaclass is selected from the explicitly specified " -"metaclass (if any) and the metaclasses (i.e. ``type(cls)``) of all specified " -"base classes. The most derived metaclass is one which is a subtype of *all* " -"of these candidate metaclasses. If none of the candidate metaclasses meets " +"metaclass (if any) and the metaclasses (i.e. ``type(cls)``) of all specified" +" base classes. The most derived metaclass is one which is a subtype of *all*" +" of these candidate metaclasses. If none of the candidate metaclasses meets " "that criterion, then the class definition will fail with ``TypeError``." msgstr "" "La metaclase más derivada es elegida de la metaclase especificada " -"explícitamente (si existe) y de la metaclase (p. ej. ``type(cls)``) de todas " -"las clases base especificadas." +"explícitamente (si existe) y de la metaclase (p. ej. ``type(cls)``) de todas" +" las clases base especificadas." #: ../Doc/reference/datamodel.rst:2253 msgid "Preparing the class namespace" @@ -3534,15 +3768,23 @@ msgstr "Preparando el espacio de nombres de la clase" #: ../Doc/reference/datamodel.rst:2258 msgid "" -"Once the appropriate metaclass has been identified, then the class namespace " -"is prepared. If the metaclass has a ``__prepare__`` attribute, it is called " -"as ``namespace = metaclass.__prepare__(name, bases, **kwds)`` (where the " +"Once the appropriate metaclass has been identified, then the class namespace" +" is prepared. If the metaclass has a ``__prepare__`` attribute, it is called" +" as ``namespace = metaclass.__prepare__(name, bases, **kwds)`` (where the " "additional keyword arguments, if any, come from the class definition). The " "``__prepare__`` method should be implemented as a :func:`classmethod " "`. The namespace returned by ``__prepare__`` is passed in to " "``__new__``, but when the final class object is created the namespace is " "copied into a new ``dict``." msgstr "" +"Una vez que se ha identificado la metaclase adecuada, se prepara el espacio " +"de nombres de la clase. Si la metaclase tiene un atributo ``__prepare__``, " +"se llama ``namespace = metaclass.__prepare__(name, bases, **kwds)`` (donde " +"los argumentos de palabras clave adicionales, si los hay, provienen de la " +"definición de clase). El método ``__prepare__`` debe implementarse como " +":func:`classmethod `. El espacio de nombres retornado por " +"``__prepare__`` se pasa a ``__new__``, pero cuando se crea el objeto de " +"clase final, el espacio de nombres se copia en un nuevo ``dict``." #: ../Doc/reference/datamodel.rst:2267 msgid "" @@ -3572,9 +3814,9 @@ msgid "" "names from the current and outer scopes when the class definition occurs " "inside a function." msgstr "" -"El cuerpo de la clase es ejecutado como ``exec(body, globals(), namespace)`` " -"(aproximadamente). La diferencia clave con un llamado normal a :func:`exec` " -"es que el alcance léxico permite que el cuerpo de la clase (incluyendo " +"El cuerpo de la clase es ejecutado como ``exec(body, globals(), namespace)``" +" (aproximadamente). La diferencia clave con un llamado normal a :func:`exec`" +" es que el alcance léxico permite que el cuerpo de la clase (incluyendo " "cualquier método) haga referencia a nombres de los alcances actuales y " "externos cuando la definición de clase sucede dentro de la función." @@ -3587,8 +3829,8 @@ msgid "" "reference described in the next section." msgstr "" "Sin embargo, aún cuando la definición de clase sucede dentro de la función, " -"los métodos definidos dentro de la clase aún no pueden ver nombres definidos " -"dentro del alcance de la clase. Variables de clase deben ser accedidas a " +"los métodos definidos dentro de la clase aún no pueden ver nombres definidos" +" dentro del alcance de la clase. Variables de clase deben ser accedidas a " "través del primer parámetro de instancia o métodos de clase, o a través de " "la referencia al léxico implícito ``__class__`` descrita en la siguiente " "sección." @@ -3599,48 +3841,49 @@ msgstr "Creando el objeto de clase" #: ../Doc/reference/datamodel.rst:2304 msgid "" -"Once the class namespace has been populated by executing the class body, the " -"class object is created by calling ``metaclass(name, bases, namespace, " +"Once the class namespace has been populated by executing the class body, the" +" class object is created by calling ``metaclass(name, bases, namespace, " "**kwds)`` (the additional keywords passed here are the same as those passed " "to ``__prepare__``)." msgstr "" -"Una vez que el espacio de nombres de la clase ha sido poblado al ejecutar el " -"cuerpo de la clase, el objeto de clase es creado al llamar ``metaclass(name, " -"bases, namespace, **kwds)`` (las palabras clave adicionales que se pasan " -"aquí, son las mismas que aquellas pasadas en ``__prepare__``)." +"Una vez que el espacio de nombres de la clase ha sido poblado al ejecutar el" +" cuerpo de la clase, el objeto de clase es creado al llamar " +"``metaclass(name, bases, namespace, **kwds)`` (las palabras clave " +"adicionales que se pasan aquí, son las mismas que aquellas pasadas en " +"``__prepare__``)." #: ../Doc/reference/datamodel.rst:2309 msgid "" "This class object is the one that will be referenced by the zero-argument " "form of :func:`super`. ``__class__`` is an implicit closure reference " "created by the compiler if any methods in a class body refer to either " -"``__class__`` or ``super``. This allows the zero argument form of :func:" -"`super` to correctly identify the class being defined based on lexical " -"scoping, while the class or instance that was used to make the current call " -"is identified based on the first argument passed to the method." -msgstr "" -"Este objeto de clase es el que será referenciado por la forma sin argumentos " -"de :func:`super`. ``__class__`` es una referencia de cierre implícita creada " -"por el compilador si cualquier método en el cuerpo de una clase se refiere " -"tanto a ``__class__`` o ``super``. Esto permite que la forma sin argumentos " -"de :func:`super` identifique correctamente la clase definida en base al " -"alcance léxico, mientras la clase o instancia que fue utilizada para hacer " -"el llamado actual es identificado en base al primer argumento que se pasa al " -"método." +"``__class__`` or ``super``. This allows the zero argument form of " +":func:`super` to correctly identify the class being defined based on lexical" +" scoping, while the class or instance that was used to make the current call" +" is identified based on the first argument passed to the method." +msgstr "" +"Este objeto de clase es el que será referenciado por la forma sin argumentos" +" de :func:`super`. ``__class__`` es una referencia de cierre implícita " +"creada por el compilador si cualquier método en el cuerpo de una clase se " +"refiere tanto a ``__class__`` o ``super``. Esto permite que la forma sin " +"argumentos de :func:`super` identifique correctamente la clase definida en " +"base al alcance léxico, mientras la clase o instancia que fue utilizada para" +" hacer el llamado actual es identificado en base al primer argumento que se " +"pasa al método." #: ../Doc/reference/datamodel.rst:2319 msgid "" "In CPython 3.6 and later, the ``__class__`` cell is passed to the metaclass " "as a ``__classcell__`` entry in the class namespace. If present, this must " "be propagated up to the ``type.__new__`` call in order for the class to be " -"initialised correctly. Failing to do so will result in a :exc:`RuntimeError` " -"in Python 3.8." +"initialised correctly. Failing to do so will result in a :exc:`RuntimeError`" +" in Python 3.8." msgstr "" "En CPython 3.6 y posterior, la celda ``__class__`` se pasa a la metaclase " "como una entrada ``__classcell__`` en el espacio de nombres de la clase. En " "caso de existir, esto debe ser propagado hacia el llamado ``type.__new__`` " -"para que la clase se inicie correctamente. No hacerlo resultará en un error :" -"exc:`RuntimeError` en Python 3.8." +"para que la clase se inicie correctamente. No hacerlo resultará en un error " +":exc:`RuntimeError` en Python 3.8." #: ../Doc/reference/datamodel.rst:2325 msgid "" @@ -3665,13 +3908,13 @@ msgid "" "Those ``__set_name__`` methods are called with the class being defined and " "the assigned name of that particular attribute;" msgstr "" -"Esos métodos ``__set_name__`` son llamados con la clase siendo definida y el " -"nombre de ese atributo particular asignado;" +"Esos métodos ``__set_name__`` son llamados con la clase siendo definida y el" +" nombre de ese atributo particular asignado;" #: ../Doc/reference/datamodel.rst:2333 msgid "" -"The :meth:`~object.__init_subclass__` hook is called on the immediate parent " -"of the new class in its method resolution order." +"The :meth:`~object.__init_subclass__` hook is called on the immediate parent" +" of the new class in its method resolution order." msgstr "" "El gancho :meth:`~object.__init_subclass__` llama al padre inmediato de la " "nueva clase en su orden de resolución del método." @@ -3696,8 +3939,8 @@ msgstr "" "Cuando una nueva clase es creada por ``type.__new__``, el objeto " "proporcionado como el parámetro de espacio de nombres es copiado a un " "trazado ordenado y el objeto original es descartado. La nueva copia es " -"*envuelta* en un proxy de solo lectura, que se convierte en el atributo :" -"attr:`~object.__dict__` del objeto de clase." +"*envuelta* en un proxy de solo lectura, que se convierte en el atributo " +":attr:`~object.__dict__` del objeto de clase." #: ../Doc/reference/datamodel.rst:2347 msgid ":pep:`3135` - New super" @@ -3729,12 +3972,12 @@ msgstr "Personalizando revisiones de instancia y subclase" #: ../Doc/reference/datamodel.rst:2363 msgid "" -"The following methods are used to override the default behavior of the :func:" -"`isinstance` and :func:`issubclass` built-in functions." +"The following methods are used to override the default behavior of the " +":func:`isinstance` and :func:`issubclass` built-in functions." msgstr "" "Los siguientes métodos son utilizados para anular el comportamiento por " -"defecto de las funciones incorporadas :func:`isinstance` y :func:" -"`issubclass`." +"defecto de las funciones incorporadas :func:`isinstance` y " +":func:`issubclass`." #: ../Doc/reference/datamodel.rst:2366 msgid "" @@ -3754,15 +3997,15 @@ msgid "" "instance of *class*. If defined, called to implement ``isinstance(instance, " "class)``." msgstr "" -"Retorna *true* si la instancia *instance* debe ser considerada una instancia " -"(directa o indirecta) de clase *class*. De ser definida, es llamado para " +"Retorna *true* si la instancia *instance* debe ser considerada una instancia" +" (directa o indirecta) de clase *class*. De ser definida, es llamado para " "implementar ``isinstance(instance, class)``." #: ../Doc/reference/datamodel.rst:2380 msgid "" "Return true if *subclass* should be considered a (direct or indirect) " -"subclass of *class*. If defined, called to implement ``issubclass(subclass, " -"class)``." +"subclass of *class*. If defined, called to implement ``issubclass(subclass," +" class)``." msgstr "" "Retorna *true* si la subclase *subclass* debe ser considerada una subclase " "(directa o indirecta) de clase *class*. De ser definida, es llamado para " @@ -3783,21 +4026,22 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2396 msgid ":pep:`3119` - Introducing Abstract Base Classes" msgstr "" -":pep:`3119` - Introducción a Clases Base Abstractas (*Abstract Base Classes*)" +":pep:`3119` - Introducción a Clases Base Abstractas (*Abstract Base " +"Classes*)" #: ../Doc/reference/datamodel.rst:2393 msgid "" -"Includes the specification for customizing :func:`isinstance` and :func:" -"`issubclass` behavior through :meth:`~class.__instancecheck__` and :meth:" -"`~class.__subclasscheck__`, with motivation for this functionality in the " -"context of adding Abstract Base Classes (see the :mod:`abc` module) to the " -"language." +"Includes the specification for customizing :func:`isinstance` and " +":func:`issubclass` behavior through :meth:`~class.__instancecheck__` and " +":meth:`~class.__subclasscheck__`, with motivation for this functionality in " +"the context of adding Abstract Base Classes (see the :mod:`abc` module) to " +"the language." msgstr "" -"Incluye la especificación para personalizar el comportamiento de :func:" -"`isinstance` y :func:`issubclass` a través de :meth:`~class." -"__instancecheck__` y :meth:`~class.__subclasscheck__`, con motivación para " -"esta funcionalidad en el contexto de agregar Clases Base Abstractas (ver el " -"módulo :mod:`abc`) al lenguaje." +"Incluye la especificación para personalizar el comportamiento de " +":func:`isinstance` y :func:`issubclass` a través de " +":meth:`~class.__instancecheck__` y :meth:`~class.__subclasscheck__`, con " +"motivación para esta funcionalidad en el contexto de agregar Clases Base " +"Abstractas (ver el módulo :mod:`abc`) al lenguaje." #: ../Doc/reference/datamodel.rst:2401 msgid "Emulating generic types" @@ -3807,8 +4051,8 @@ msgstr "Emulando tipos genéricos" msgid "" "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`." +"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 "" "Cuando se usa :term:`type annotations`, a menudo es útil " "*parameterize* a :term:`generic type` usando la notación de corchetes de " @@ -3821,7 +4065,8 @@ msgstr ":pep:`484` - Sugerencias de tipo" #: ../Doc/reference/datamodel.rst:2411 msgid "Introducing Python's framework for type annotations" -msgstr "Presentamos el marco de trabajo de Python para las anotaciones de tipo" +msgstr "" +"Presentamos el marco de trabajo de Python para las anotaciones de tipo" #: ../Doc/reference/datamodel.rst:2414 msgid ":ref:`Generic Alias Types`" @@ -3834,11 +4079,11 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2417 msgid "" -":ref:`Generics`, :ref:`user-defined generics` and :" -"class:`typing.Generic`" +":ref:`Generics`, :ref:`user-defined generics` and " +":class:`typing.Generic`" msgstr "" -":ref:`Generics`, :ref:`user-defined generics` y :" -"class:`typing.Generic`" +":ref:`Generics`, :ref:`user-defined generics` y " +":class:`typing.Generic`" #: ../Doc/reference/datamodel.rst:2417 msgid "" @@ -3868,12 +4113,12 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2428 msgid "" "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." +"method. As such, there is no need for it to be decorated with " +":func:`@classmethod` when it is defined." msgstr "" -"Cuando se define en una clase, ``__class_getitem__()`` es automáticamente un " -"método de clase. Como tal, no es necesario decorarlo con :func:" -"`@classmethod` cuando se define." +"Cuando se define en una clase, ``__class_getitem__()`` es automáticamente un" +" método de clase. Como tal, no es necesario decorarlo con " +":func:`@classmethod` cuando se define." #: ../Doc/reference/datamodel.rst:2434 msgid "The purpose of *__class_getitem__*" @@ -3882,41 +4127,41 @@ msgstr "El propósito de *__class_getitem__*" #: ../Doc/reference/datamodel.rst:2436 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." +"parameterization of standard-library generic classes in order to more easily" +" apply :term:`type hints` to these classes." msgstr "" "El propósito de :meth:`~object.__class_getitem__` es permitir la " "parametrización en tiempo de ejecución de clases genéricas de biblioteca " -"estándar para aplicar :term:`type hints` a estas clases con mayor " -"facilidad." +"estándar para aplicar :term:`type hints` a estas clases con mayor" +" facilidad." #: ../Doc/reference/datamodel.rst:2440 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__()``." +"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 "" "Para implementar clases genéricas personalizadas que se puedan parametrizar " "en tiempo de ejecución y que los verificadores de tipos estáticos las " "entiendan, los usuarios deben heredar de una clase de biblioteca estándar " -"que ya implementa :meth:`~object.__class_getitem__`, o heredar de :class:" -"`typing.Generic`, que tiene su propia implementación de " +"que ya implementa :meth:`~object.__class_getitem__`, o heredar de " +":class:`typing.Generic`, que tiene su propia implementación de " "``__class_getitem__()``." #: ../Doc/reference/datamodel.rst:2446 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 " +"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 "" "Es posible que los verificadores de tipos de terceros, como mypy, no " -"entiendan las implementaciones personalizadas de :meth:`~object." -"__class_getitem__` en clases definidas fuera de la biblioteca estándar. Se " -"desaconseja el uso de ``__class_getitem__()`` en cualquier clase para fines " -"distintos a la sugerencia de tipo." +"entiendan las implementaciones personalizadas de " +":meth:`~object.__class_getitem__` en clases definidas fuera de la biblioteca" +" estándar. Se desaconseja el uso de ``__class_getitem__()`` en cualquier " +"clase para fines distintos a la sugerencia de tipo." #: ../Doc/reference/datamodel.rst:2456 msgid "*__class_getitem__* versus *__getitem__*" @@ -3934,60 +4179,62 @@ msgstr "" "Por lo general, el :ref:`subscription` de un objeto que usa " "corchetes llamará al método de instancia :meth:`~object.__getitem__` " "definido en la clase del objeto. Sin embargo, si el objeto que se suscribe " -"es en sí mismo una clase, se puede llamar al método de clase :meth:`~object." -"__class_getitem__` en su lugar. ``__class_getitem__()`` debería retornar un " -"objeto :ref:`GenericAlias` si está definido " -"correctamente." +"es en sí mismo una clase, se puede llamar al método de clase " +":meth:`~object.__class_getitem__` en su lugar. ``__class_getitem__()`` " +"debería retornar un objeto :ref:`GenericAlias` si está " +"definido correctamente." #: ../Doc/reference/datamodel.rst:2465 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::" +"follows something like the following process to decide whether " +":meth:`~object.__getitem__` or :meth:`~object.__class_getitem__` should be " +"called::" msgstr "" "Presentado con el :term:`expression` ``obj[x]``, el intérprete de Python " -"sigue un proceso similar al siguiente para decidir si se debe llamar a :meth:" -"`~object.__getitem__` o :meth:`~object.__class_getitem__`:" +"sigue un proceso similar al siguiente para decidir si se debe llamar a " +":meth:`~object.__getitem__` o :meth:`~object.__class_getitem__`:" #: ../Doc/reference/datamodel.rst:2493 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::" +"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 "" "En Python, todas las clases son en sí mismas instancias de otras clases. La " "clase de una clase se conoce como :term:`metaclass` de esa clase, y la " -"mayoría de las clases tienen la clase :class:`type` como su metaclase. :" -"class:`type` no define :meth:`~object.__getitem__`, lo que significa que " -"expresiones como ``list[int]``, ``dict[str, float]`` y ``tuple[str, bytes]`` " -"dan como resultado que se llame a :meth:`~object.__class_getitem__`:" +"mayoría de las clases tienen la clase :class:`type` como su metaclase. " +":class:`type` no define :meth:`~object.__getitem__`, lo que significa que " +"expresiones como ``list[int]``, ``dict[str, float]`` y ``tuple[str, bytes]``" +" dan como resultado que se llame a :meth:`~object.__class_getitem__`:" #: ../Doc/reference/datamodel.rst:2512 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::" +"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 "" -"Sin embargo, si una clase tiene una metaclase personalizada que define :meth:" -"`~object.__getitem__`, la suscripción de la clase puede generar un " -"comportamiento diferente. Un ejemplo de esto se puede encontrar en el " -"módulo :mod:`enum`:" +"Sin embargo, si una clase tiene una metaclase personalizada que define " +":meth:`~object.__getitem__`, la suscripción de la clase puede generar un " +"comportamiento diferente. Un ejemplo de esto se puede encontrar en el módulo" +" :mod:`enum`:" #: ../Doc/reference/datamodel.rst:2537 msgid ":pep:`560` - Core Support for typing module and generic types" msgstr "" +":pep:`560`: soporte principal para módulo de escritura y tipos genéricos" #: ../Doc/reference/datamodel.rst:2536 msgid "" -"Introducing :meth:`~object.__class_getitem__`, and outlining when a :ref:" -"`subscription` results in ``__class_getitem__()`` being " +"Introducing :meth:`~object.__class_getitem__`, and outlining when a " +":ref:`subscription` results in ``__class_getitem__()`` being " "called instead of :meth:`~object.__getitem__`" msgstr "" -"Presentamos :meth:`~object.__class_getitem__` y describimos cuándo un :ref:" -"`subscription` da como resultado que se llame a " +"Presentamos :meth:`~object.__class_getitem__` y describimos cuándo un " +":ref:`subscription` da como resultado que se llame a " "``__class_getitem__()`` en lugar de :meth:`~object.__getitem__`" #: ../Doc/reference/datamodel.rst:2544 @@ -4000,9 +4247,9 @@ msgid "" "defined, ``x(arg1, arg2, ...)`` roughly translates to ``type(x).__call__(x, " "arg1, ...)``." msgstr "" -"Es llamado cuando la instancia es “llamada” como una función; si este método " -"es definido, ``x(arg1, arg2, …)`` es una clave corta para ``x.__call__(arg1, " -"arg2, …)``." +"Es llamado cuando la instancia es “llamada” como una función; si este método" +" es definido, ``x(arg1, arg2, …)`` es una clave corta para " +"``x.__call__(arg1, arg2, …)``." #: ../Doc/reference/datamodel.rst:2558 msgid "Emulating container types" @@ -4012,37 +4259,73 @@ msgstr "Emulando tipos de contenedores" msgid "" "The following methods can be defined to implement container objects. " "Containers usually are :term:`sequences ` (such as :class:`lists " -"` or :class:`tuples `) or :term:`mappings ` (like :" -"class:`dictionaries `), but can represent other containers as well. " +"` or :class:`tuples `) or :term:`mappings ` (like " +":class:`dictionaries `), but can represent other containers as well. " "The first set of methods is used either to emulate a sequence or to emulate " "a mapping; the difference is that for a sequence, the allowable keys should " "be the integers *k* for which ``0 <= k < N`` where *N* is the length of the " "sequence, or :class:`slice` objects, which define a range of items. It is " -"also recommended that mappings provide the methods :meth:`keys`, :meth:" -"`values`, :meth:`items`, :meth:`get`, :meth:`clear`, :meth:`setdefault`, :" -"meth:`pop`, :meth:`popitem`, :meth:`!copy`, and :meth:`update` behaving " -"similar to those for Python's standard :class:`dictionary ` objects. " -"The :mod:`collections.abc` module provides a :class:`~collections.abc." -"MutableMapping` :term:`abstract base class` to help create those methods " -"from a base set of :meth:`~object.__getitem__`, :meth:`~object." -"__setitem__`, :meth:`~object.__delitem__`, and :meth:`keys`. Mutable " -"sequences should provide methods :meth:`append`, :meth:`count`, :meth:" -"`index`, :meth:`extend`, :meth:`insert`, :meth:`pop`, :meth:`remove`, :meth:" -"`reverse` and :meth:`sort`, like Python standard :class:`list` objects. " -"Finally, sequence types should implement addition (meaning concatenation) " -"and multiplication (meaning repetition) by defining the methods :meth:" -"`~object.__add__`, :meth:`~object.__radd__`, :meth:`~object.__iadd__`, :meth:" -"`~object.__mul__`, :meth:`~object.__rmul__` and :meth:`~object.__imul__` " -"described below; they should not define other numerical operators. It is " -"recommended that both mappings and sequences implement the :meth:`~object." -"__contains__` method to allow efficient use of the ``in`` operator; for " -"mappings, ``in`` should search the mapping's keys; for sequences, it should " -"search through the values. It is further recommended that both mappings and " -"sequences implement the :meth:`~object.__iter__` method to allow efficient " -"iteration through the container; for mappings, :meth:`__iter__` should " -"iterate through the object's keys; for sequences, it should iterate through " -"the values." -msgstr "" +"also recommended that mappings provide the methods :meth:`keys`, " +":meth:`values`, :meth:`items`, :meth:`get`, :meth:`clear`, " +":meth:`setdefault`, :meth:`pop`, :meth:`popitem`, :meth:`!copy`, and " +":meth:`update` behaving similar to those for Python's standard " +":class:`dictionary ` objects. The :mod:`collections.abc` module " +"provides a :class:`~collections.abc.MutableMapping` :term:`abstract base " +"class` to help create those methods from a base set of " +":meth:`~object.__getitem__`, :meth:`~object.__setitem__`, " +":meth:`~object.__delitem__`, and :meth:`keys`. Mutable sequences should " +"provide methods :meth:`append`, :meth:`count`, :meth:`index`, " +":meth:`extend`, :meth:`insert`, :meth:`pop`, :meth:`remove`, :meth:`reverse`" +" and :meth:`sort`, like Python standard :class:`list` objects. Finally, " +"sequence types should implement addition (meaning concatenation) and " +"multiplication (meaning repetition) by defining the methods " +":meth:`~object.__add__`, :meth:`~object.__radd__`, :meth:`~object.__iadd__`," +" :meth:`~object.__mul__`, :meth:`~object.__rmul__` and " +":meth:`~object.__imul__` described below; they should not define other " +"numerical operators. It is recommended that both mappings and sequences " +"implement the :meth:`~object.__contains__` method to allow efficient use of " +"the ``in`` operator; for mappings, ``in`` should search the mapping's keys; " +"for sequences, it should search through the values. It is further " +"recommended that both mappings and sequences implement the " +":meth:`~object.__iter__` method to allow efficient iteration through the " +"container; for mappings, :meth:`__iter__` should iterate through the " +"object's keys; for sequences, it should iterate through the values." +msgstr "" +"Se pueden definir los siguientes métodos para implementar objetos " +"contenedores. Los contenedores suelen ser :term:`sequences ` (como" +" :class:`lists ` o :class:`tuples `) o :term:`mappings " +"` (como :class:`dictionaries `), pero también pueden " +"representar otros contenedores. El primer conjunto de métodos se utiliza " +"para emular una secuencia o un mapeo; la diferencia es que para una " +"secuencia, las claves permitidas deben ser los números enteros *k* para los " +"cuales ``0 <= k < N`` donde *N* es la longitud de la secuencia, u objetos " +":class:`slice`, que definen un rango de elementos. También se recomienda que" +" las asignaciones proporcionen los métodos :meth:`keys`, :meth:`values`, " +":meth:`items`, :meth:`get`, :meth:`clear`, :meth:`setdefault`, :meth:`pop`, " +":meth:`popitem`, :meth:`!copy` y :meth:`update` que se comportan de manera " +"similar a los de los objetos :class:`dictionary ` estándar de Python. " +"El módulo :mod:`collections.abc` proporciona un " +":class:`~collections.abc.MutableMapping` :term:`abstract base class` para " +"ayudar a crear esos métodos a partir de un conjunto básico de " +":meth:`~object.__getitem__`, :meth:`~object.__setitem__`, " +":meth:`~object.__delitem__` y :meth:`keys`. Las secuencias mutables deben " +"proporcionar los métodos :meth:`append`, :meth:`count`, :meth:`index`, " +":meth:`extend`, :meth:`insert`, :meth:`pop`, :meth:`remove`, :meth:`reverse`" +" y :meth:`sort`, como los objetos :class:`list` estándar de Python. " +"Finalmente, los tipos de secuencia deben implementar la suma (es decir, " +"concatenación) y la multiplicación (es decir, repetición) definiendo los " +"métodos :meth:`~object.__add__`, :meth:`~object.__radd__`, " +":meth:`~object.__iadd__`, :meth:`~object.__mul__`, :meth:`~object.__rmul__` " +"y :meth:`~object.__imul__` que se describen a continuación; no deben definir" +" otros operadores numéricos. Se recomienda que tanto las asignaciones como " +"las secuencias implementen el método :meth:`~object.__contains__` para " +"permitir el uso eficiente del operador ``in``; para asignaciones, ``in`` " +"debería buscar las claves de la asignación; para secuencias, debe buscar " +"entre los valores. Se recomienda además que tanto las asignaciones como las " +"secuencias implementen el método :meth:`~object.__iter__` para permitir una " +"iteración eficiente a través del contenedor; para asignaciones, " +":meth:`__iter__` debe iterar a través de las claves del objeto; para " +"secuencias, debe iterar a través de los valores." #: ../Doc/reference/datamodel.rst:2600 msgid "" @@ -4051,35 +4334,45 @@ msgid "" "define a :meth:`~object.__bool__` method and whose :meth:`!__len__` method " "returns zero is considered to be false in a Boolean context." msgstr "" +"Llamado para implementar la función incorporada :func:`len`. Debería " +"retornar la longitud del objeto, un número entero ``>=`` 0. Además, un " +"objeto que no define un método :meth:`~object.__bool__` y cuyo método " +":meth:`!__len__` retorna cero se considera falso en un contexto booleano." #: ../Doc/reference/datamodel.rst:2607 msgid "" -"In CPython, the length is required to be at most :data:`sys.maxsize`. If the " -"length is larger than :data:`!sys.maxsize` some features (such as :func:" -"`len`) may raise :exc:`OverflowError`. To prevent raising :exc:`!" -"OverflowError` by truth value testing, an object must define a :meth:" -"`~object.__bool__` method." +"In CPython, the length is required to be at most :data:`sys.maxsize`. If the" +" length is larger than :data:`!sys.maxsize` some features (such as " +":func:`len`) may raise :exc:`OverflowError`. To prevent raising " +":exc:`!OverflowError` by truth value testing, an object must define a " +":meth:`~object.__bool__` method." msgstr "" +"En CPython, se requiere que la longitud sea como máximo :data:`sys.maxsize`." +" Si la longitud es mayor que :data:`!sys.maxsize`, algunas funciones (como " +":func:`len`) pueden generar :exc:`OverflowError`. Para evitar que se genere " +":exc:`!OverflowError` mediante pruebas de valor de verdad, un objeto debe " +"definir un método :meth:`~object.__bool__`." #: ../Doc/reference/datamodel.rst:2616 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). " -"The length must be an integer ``>=`` 0. The return value may also be :const:" -"`NotImplemented`, which is treated the same as if the ``__length_hint__`` " -"method didn't exist at all. This method is purely an optimization and is " -"never required for correctness." +"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). The length must be an integer ``>=`` 0. The return value may also " +"be :const:`NotImplemented`, which is treated the same as if the " +"``__length_hint__`` method didn't exist at all. This method is purely an " +"optimization and is never required for correctness." msgstr "" "Es llamado para implementar :func:`operator.length_hint`. Debe retornar una " "longitud estimada para el objeto (que puede ser mayor o menor que la " "longitud actual). La longitud debe ser un entero ``>=`` 0. El valor de " -"retorno también debe ser :const:`NotImplemented` el cual es tratado de igual " -"forma a que si el método ``__length_hint__`` no existiera en absoluto. Este " -"método es puramente una optimización y nunca es requerido para precisión." +"retorno también debe ser :const:`NotImplemented` el cual es tratado de igual" +" forma a que si el método ``__length_hint__`` no existiera en absoluto. Este" +" método es puramente una optimización y nunca es requerido para precisión." #: ../Doc/reference/datamodel.rst:2630 msgid "" -"Slicing is done exclusively with the following three methods. A call like ::" +"Slicing is done exclusively with the following three methods. A call like " +"::" msgstr "" "La segmentación se hace exclusivamente con los siguientes tres métodos. Un " "llamado como ::" @@ -4091,20 +4384,31 @@ msgstr "es traducido a ::" #: ../Doc/reference/datamodel.rst:2638 msgid "and so forth. Missing slice items are always filled in with ``None``." msgstr "" -"etcétera. Elementos faltantes de segmentos siempre son llenados con ``None``." +"etcétera. Elementos faltantes de segmentos siempre son llenados con " +"``None``." #: ../Doc/reference/datamodel.rst:2643 msgid "" -"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 " +"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 "" +"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 "" +"Llamado a implementar evaluación de ``self[key]``. Para los tipos " +":term:`sequence`, las claves aceptadas deben ser números enteros y objetos " +"de segmento. Tenga en cuenta que la interpretación especial de los índices " +"negativos (si la clase desea emular un tipo :term:`sequence`) depende del " +"método :meth:`__getitem__`. Si *key* es de un tipo inadecuado, es posible " +"que se genere :exc:`TypeError`; si se trata de un valor fuera del conjunto " +"de índices de la secuencia (después de cualquier interpretación especial de " +"valores negativos), se debe generar :exc:`IndexError`. Para los tipos " +":term:`mapping`, si falta *key* (no en el contenedor), se debe generar " +":exc:`KeyError`." #: ../Doc/reference/datamodel.rst:2655 msgid "" @@ -4117,9 +4421,9 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2660 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." +"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 "" "Cuando :ref:`subscripting` a *class*, se puede llamar al " "método de clase especial :meth:`~object.__class_getitem__` en lugar de " @@ -4127,11 +4431,11 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2668 msgid "" -"Called to implement assignment to ``self[key]``. Same note as for :meth:" -"`__getitem__`. This should only be implemented for mappings if the objects " -"support changes to the values for keys, or if new keys can be added, or for " -"sequences if elements can be replaced. The same exceptions should be raised " -"for improper *key* values as for the :meth:`__getitem__` method." +"Called to implement assignment to ``self[key]``. Same note as for " +":meth:`__getitem__`. This should only be implemented for mappings if the " +"objects support changes to the values for keys, or if new keys can be added," +" or for sequences if elements can be replaced. The same exceptions should " +"be raised for improper *key* values as for the :meth:`__getitem__` method." msgstr "" "Es llamado para implementar la asignación a ``self[key]``. Lo mismo con " "respecto a :meth:`__getitem__`. Esto solo debe ser implementado para mapeos " @@ -4142,35 +4446,39 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2677 msgid "" -"Called to implement deletion of ``self[key]``. Same note as for :meth:" -"`__getitem__`. This should only be implemented for mappings if the objects " -"support removal of keys, or for sequences if elements can be removed from " -"the sequence. The same exceptions should be raised for improper *key* " -"values as for the :meth:`__getitem__` method." +"Called to implement deletion of ``self[key]``. Same note as for " +":meth:`__getitem__`. This should only be implemented for mappings if the " +"objects support removal of keys, or for sequences if elements can be removed" +" from the sequence. The same exceptions should be raised for improper *key*" +" values as for the :meth:`__getitem__` method." msgstr "" "Es llamado para implementar el borrado de ``self[key]``. Lo mismo con " "respecto a :meth:`__getitem__`. Esto solo debe ser implementado para mapeos " "si los objetos permiten el borrado de llaves, o para secuencias si los " "elementos pueden ser eliminados de la secuencia. Las mismas excepciones " -"deben ser lanzadas por valores de *key* inapropiados con respecto al método :" -"meth:`__getitem__`." +"deben ser lanzadas por valores de *key* inapropiados con respecto al método " +":meth:`__getitem__`." #: ../Doc/reference/datamodel.rst:2686 msgid "" -"Called by :class:`dict`\\ .\\ :meth:`__getitem__` to implement ``self[key]`` " -"for dict subclasses when key is not in the dictionary." +"Called by :class:`dict`\\ .\\ :meth:`__getitem__` to implement ``self[key]``" +" for dict subclasses when key is not in the dictionary." msgstr "" "Es llamado por :class:`dict`\\ .\\ :meth:`__getitem__` para implementar " -"``self[key]`` para subclases de diccionarios cuando la llave no se encuentra " -"en el diccionario." +"``self[key]`` para subclases de diccionarios cuando la llave no se encuentra" +" en el diccionario." #: ../Doc/reference/datamodel.rst:2692 msgid "" "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." +"the objects in the container. For mappings, it should iterate over the keys" +" of the container." msgstr "" +"Se llama a este método cuando se requiere un :term:`iterator` para un " +"contenedor. Este método debería retornar un nuevo objeto iterador que pueda " +"iterar sobre todos los objetos del contenedor. Para las asignaciones, debe " +"iterar sobre las claves del contenedor." #: ../Doc/reference/datamodel.rst:2700 msgid "" @@ -4180,28 +4488,29 @@ msgid "" msgstr "" "Es llamado (si existe) por la función incorporada :func:`reversed` para " "implementar una interacción invertida. Debe retornar un nuevo objeto " -"iterador que itere sobre todos los objetos en el contenedor en orden inverso." +"iterador que itere sobre todos los objetos en el contenedor en orden " +"inverso." #: ../Doc/reference/datamodel.rst:2704 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 :" -"meth:`__getitem__`). Objects that support the sequence protocol should only " -"provide :meth:`__reversed__` if they can provide an implementation that is " -"more efficient than the one provided by :func:`reversed`." +"built-in will fall back to using the sequence protocol (:meth:`__len__` and " +":meth:`__getitem__`). Objects that support the sequence protocol should " +"only provide :meth:`__reversed__` if they can provide an implementation that" +" is more efficient than the one provided by :func:`reversed`." msgstr "" "Si el método :meth:`__reversed__` no es proporcionado, la función " "incorporada :func:`reversed` recurrirá a utilizar el protocolo de secuencia " "(:meth:`__len__` y :meth:`__getitem__`). Objetos que permiten el protocolo " -"de secuencia deben únicamente proporcionar :meth:`__reversed__` si no pueden " -"proporcionar una implementación que sea más eficiente que la proporcionada " +"de secuencia deben únicamente proporcionar :meth:`__reversed__` si no pueden" +" proporcionar una implementación que sea más eficiente que la proporcionada " "por :func:`reversed`." #: ../Doc/reference/datamodel.rst:2711 msgid "" "The membership test operators (:keyword:`in` and :keyword:`not in`) are " -"normally implemented as an iteration through a container. However, container " -"objects can supply the following special method with a more efficient " +"normally implemented as an iteration through a container. However, container" +" objects can supply the following special method with a more efficient " "implementation, which also does not require the object be iterable." msgstr "" "Los operadores de prueba de pertenencia (:keyword:`in` and :keyword:`not " @@ -4212,8 +4521,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2718 msgid "" -"Called to implement membership test operators. Should return true if *item* " -"is in *self*, false otherwise. For mapping objects, this should consider " +"Called to implement membership test operators. Should return true if *item*" +" is in *self*, false otherwise. For mapping objects, this should consider " "the keys of the mapping rather than the values or the key-item pairs." msgstr "" "Es llamado para implementar operadores de prueba de pertenencia. Deben " @@ -4230,8 +4539,8 @@ msgid "" msgstr "" "Para objetos que no definen :meth:`__contains__`, la prueba de pertenencia " "primero intenta la iteración a través de :meth:`__iter__`, y luego el " -"antiguo protocolo de iteración de secuencia a través de :meth:`__getitem__`, " -"ver :ref:`esta sección en la referencia del lenguaje `." #: ../Doc/reference/datamodel.rst:2731 @@ -4241,8 +4550,8 @@ msgstr "Emulando tipos numéricos" #: ../Doc/reference/datamodel.rst:2733 msgid "" "The following methods can be defined to emulate numeric objects. Methods " -"corresponding to operations that are not supported by the particular kind of " -"number implemented (e.g., bitwise operations for non-integral numbers) " +"corresponding to operations that are not supported by the particular kind of" +" number implemented (e.g., bitwise operations for non-integral numbers) " "should be left undefined." msgstr "" "Los siguientes métodos pueden ser definidos para emular objetos numéricos. " @@ -4253,16 +4562,26 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2759 msgid "" "These methods are called to implement the binary arithmetic operations " -"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :func:" -"`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``). For instance, to " -"evaluate the expression ``x + y``, where *x* is an instance of a class that " -"has an :meth:`__add__` method, ``type(x).__add__(x, y)`` is called. The :" -"meth:`__divmod__` method should be the equivalent to using :meth:" -"`__floordiv__` and :meth:`__mod__`; it should not be related to :meth:" -"`__truediv__`. Note that :meth:`__pow__` should be defined to accept an " -"optional third argument if the ternary version of the built-in :func:`pow` " -"function is to be supported." -msgstr "" +"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " +":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``). For instance, to" +" evaluate the expression ``x + y``, where *x* is an instance of a class that" +" has an :meth:`__add__` method, ``type(x).__add__(x, y)`` is called. The " +":meth:`__divmod__` method should be the equivalent to using " +":meth:`__floordiv__` and :meth:`__mod__`; it should not be related to " +":meth:`__truediv__`. Note that :meth:`__pow__` should be defined to accept " +"an optional third argument if the ternary version of the built-in " +":func:`pow` function is to be supported." +msgstr "" +"Estos métodos se llaman para implementar las operaciones aritméticas " +"binarias (``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " +":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``). Por ejemplo, para" +" evaluar la expresión ``x + y``, donde *x* es una instancia de una clase que" +" tiene un método :meth:`__add__`, se llama a ``type(x).__add__(x, y)``. El " +"método :meth:`__divmod__` debería ser equivalente al uso de " +":meth:`__floordiv__` y :meth:`__mod__`; no debería estar relacionado con " +":meth:`__truediv__`. Tenga en cuenta que :meth:`__pow__` debe definirse para" +" aceptar un tercer argumento opcional si se va a admitir la versión ternaria" +" de la función incorporada :func:`pow`." #: ../Doc/reference/datamodel.rst:2770 msgid "" @@ -4275,15 +4594,24 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2793 msgid "" "These methods are called to implement the binary arithmetic operations " -"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :func:" -"`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``) with reflected (swapped) " -"operands. These functions are only called if the left operand does not " -"support the corresponding operation [#]_ and the operands are of different " -"types. [#]_ For instance, to evaluate the expression ``x - y``, where *y* is " -"an instance of a class that has an :meth:`__rsub__` method, ``type(y)." -"__rsub__(y, x)`` is called if ``type(x).__sub__(x, y)`` returns " +"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " +":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``) with reflected " +"(swapped) operands. These functions are only called if the left operand " +"does not support the corresponding operation [#]_ and the operands are of " +"different types. [#]_ For instance, to evaluate the expression ``x - y``, " +"where *y* is an instance of a class that has an :meth:`__rsub__` method, " +"``type(y).__rsub__(y, x)`` is called if ``type(x).__sub__(x, y)`` returns " "*NotImplemented*." msgstr "" +"Estos métodos se llaman para implementar las operaciones aritméticas " +"binarias (``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " +":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``) con operandos " +"reflejados (intercambiados). Estas funciones solo se llaman si el operando " +"izquierdo no admite la operación correspondiente [#]_ y los operandos son de" +" diferentes tipos. [#]_ Por ejemplo, para evaluar la expresión ``x - y``, " +"donde *y* es una instancia de una clase que tiene un método " +":meth:`__rsub__`, se llama a ``type(y).__rsub__(y, x)`` si " +"``type(x).__sub__(x, y)`` retorna *NotImplemented*." #: ../Doc/reference/datamodel.rst:2805 msgid "" @@ -4305,20 +4633,20 @@ msgstr "" "Si el tipo del operando de la derecha es una subclase del tipo del operando " "de la izquierda y esa subclase proporciona el método reflejado para la " "operación, este método será llamado antes del método no reflejado del " -"operando izquierdo. Este comportamiento permite que las subclases anulen las " -"operaciones de sus predecesores." +"operando izquierdo. Este comportamiento permite que las subclases anulen las" +" operaciones de sus predecesores." #: ../Doc/reference/datamodel.rst:2831 msgid "" "These methods are called to implement the augmented arithmetic assignments " "(``+=``, ``-=``, ``*=``, ``@=``, ``/=``, ``//=``, ``%=``, ``**=``, ``<<=``, " "``>>=``, ``&=``, ``^=``, ``|=``). These methods should attempt to do the " -"operation in-place (modifying *self*) and return the result (which could be, " -"but does not have to be, *self*). If a specific method is not defined, the " -"augmented assignment falls back to the normal methods. For instance, if *x* " -"is an instance of a class with an :meth:`__iadd__` method, ``x += y`` is " -"equivalent to ``x = x.__iadd__(y)`` . Otherwise, ``x.__add__(y)`` and ``y." -"__radd__(x)`` are considered, as with the evaluation of ``x + y``. In " +"operation in-place (modifying *self*) and return the result (which could be," +" but does not have to be, *self*). If a specific method is not defined, the" +" augmented assignment falls back to the normal methods. For instance, if " +"*x* is an instance of a class with an :meth:`__iadd__` method, ``x += y`` is" +" equivalent to ``x = x.__iadd__(y)`` . Otherwise, ``x.__add__(y)`` and " +"``y.__radd__(x)`` are considered, as with the evaluation of ``x + y``. In " "certain situations, augmented assignment can result in unexpected errors " "(see :ref:`faq-augmented-assignment-tuple-error`), but this behavior is in " "fact part of the data model." @@ -4326,32 +4654,32 @@ msgstr "" "Estos métodos son llamados para implementar las asignaciones aritméticas " "aumentadas (``+=``, ``-=``, ``*=``, ``@=``, ``/=``, ``//=``, ``%=``, " "``**=``, ``<<=``, ``>>=``, ``&=``, ``^=``, ``|=``). Estos métodos deben " -"intentar realizar la operación *in-place* (modificando *self*) y retornar el " -"resultado (que puede, pero no tiene que ser *self*). Si un método específico " -"no es definido, la asignación aumentada regresa a los métodos normales. Por " -"ejemplo, si *x* es la instancia de una clase con el método :meth:`__iadd__`, " -"``x += y`` es equivalente a ``x = x.__iadd__(y)``. De lo contrario ``x." -"__add__(y)`` y ``y.__radd__(x)`` se consideran al igual que con la " -"evaluación de ``x + y``. En ciertas situaciones, asignaciones aumentadas " -"pueden resultar en errores no esperados (ver :ref:`faq-augmented-assignment-" -"tuple-error`), pero este comportamiento es en realidad parte del modelo de " -"datos." +"intentar realizar la operación *in-place* (modificando *self*) y retornar el" +" resultado (que puede, pero no tiene que ser *self*). Si un método " +"específico no es definido, la asignación aumentada regresa a los métodos " +"normales. Por ejemplo, si *x* es la instancia de una clase con el método " +":meth:`__iadd__`, ``x += y`` es equivalente a ``x = x.__iadd__(y)``. De lo " +"contrario ``x.__add__(y)`` y ``y.__radd__(x)`` se consideran al igual que " +"con la evaluación de ``x + y``. En ciertas situaciones, asignaciones " +"aumentadas pueden resultar en errores no esperados (ver :ref:`faq-augmented-" +"assignment-tuple-error`), pero este comportamiento es en realidad parte del " +"modelo de datos." #: ../Doc/reference/datamodel.rst:2852 msgid "" -"Called to implement the unary arithmetic operations (``-``, ``+``, :func:" -"`abs` and ``~``)." +"Called to implement the unary arithmetic operations (``-``, ``+``, " +":func:`abs` and ``~``)." msgstr "" "Es llamado para implementar las operaciones aritméticas unarias (``-``, " "``+``, :func:`abs` and ``~``)." #: ../Doc/reference/datamodel.rst:2865 msgid "" -"Called to implement the built-in functions :func:`complex`, :func:`int` and :" -"func:`float`. Should return a value of the appropriate type." +"Called to implement the built-in functions :func:`complex`, :func:`int` and " +":func:`float`. Should return a value of the appropriate type." msgstr "" -"Es llamado para implementar las funciones incorporadas :func:`complex`, :" -"func:`int` y :func:`float`. Debe retornar un valor del tipo apropiado." +"Es llamado para implementar las funciones incorporadas :func:`complex`, " +":func:`int` y :func:`float`. Debe retornar un valor del tipo apropiado." #: ../Doc/reference/datamodel.rst:2872 msgid "" @@ -4363,19 +4691,19 @@ msgid "" msgstr "" "Es llamado para implementar :func:`operator.index`, y cuando sea que Python " "necesite convertir sin pérdidas el objeto numérico a un objeto entero (tal " -"como en la segmentación o *slicing*, o las funciones incorporadas :func:" -"`bin`, :func:`hex` y :func:`oct`). La presencia de este método indica que el " -"objeto numérico es un tipo entero. Debe retornar un entero." +"como en la segmentación o *slicing*, o las funciones incorporadas " +":func:`bin`, :func:`hex` y :func:`oct`). La presencia de este método indica " +"que el objeto numérico es un tipo entero. Debe retornar un entero." #: ../Doc/reference/datamodel.rst:2878 msgid "" "If :meth:`__int__`, :meth:`__float__` and :meth:`__complex__` are not " -"defined then corresponding built-in functions :func:`int`, :func:`float` " -"and :func:`complex` fall back to :meth:`__index__`." +"defined then corresponding built-in functions :func:`int`, :func:`float` and" +" :func:`complex` fall back to :meth:`__index__`." msgstr "" "Si :meth:`__int__`, :meth:`__float__` y :meth:`__complex__` no son " -"definidos, entonces todas las funciones incorporadas correspondientes :func:" -"`int`, :func:`float` y :func:`complex` vuelven a :meth:`__index__`." +"definidos, entonces todas las funciones incorporadas correspondientes " +":func:`int`, :func:`float` y :func:`complex` vuelven a :meth:`__index__`." #: ../Doc/reference/datamodel.rst:2890 msgid "" @@ -4386,15 +4714,15 @@ msgid "" "(typically an :class:`int`)." msgstr "" "Es llamado para implementar la función incorporada :func:`round` y las " -"funciones :mod:`math` :func:`~math.trunc`, :func:`~math.floor` y :func:" -"`~math.ceil`. A menos que *ndigits* sea pasado a :meth:`!__round__` todos " -"estos métodos deben retornar el valor del objeto truncado a :class:`~numbers." -"Integral` (normalmente :class:`int`)." +"funciones :mod:`math` :func:`~math.trunc`, :func:`~math.floor` y " +":func:`~math.ceil`. A menos que *ndigits* sea pasado a :meth:`!__round__` " +"todos estos métodos deben retornar el valor del objeto truncado a " +":class:`~numbers.Integral` (normalmente :class:`int`)." #: ../Doc/reference/datamodel.rst:2896 msgid "" -"The built-in function :func:`int` falls back to :meth:`__trunc__` if " -"neither :meth:`__int__` nor :meth:`__index__` is defined." +"The built-in function :func:`int` falls back to :meth:`__trunc__` if neither" +" :meth:`__int__` nor :meth:`__index__` is defined." msgstr "" "La función integrada :func:`int` recurre a :meth:`__trunc__` si no se " "definen ni :meth:`__int__` ni :meth:`__index__`." @@ -4409,20 +4737,20 @@ msgstr "Gestores de Contexto en la Declaración *with*" #: ../Doc/reference/datamodel.rst:2908 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 " -"handles the entry into, and the exit from, the desired runtime context for " +"A :dfn:`context manager` is an object that defines the runtime context to be" +" established when executing a :keyword:`with` statement. The context manager" +" handles the entry into, and the exit from, the desired runtime context for " "the execution of the block of code. Context managers are normally invoked " -"using the :keyword:`!with` statement (described in section :ref:`with`), but " -"can also be used by directly invoking their methods." +"using the :keyword:`!with` statement (described in section :ref:`with`), but" +" can also be used by directly invoking their methods." msgstr "" "Un :dfn:`context manager` es un objeto que define el contexto en tiempo de " -"ejecución a ser establecido cuando se ejecuta una declaración :keyword:" -"`with`. El gestor de contexto maneja la entrada y la salida del contexto en " -"tiempo de ejecución deseado para la ejecución del bloque de código. Los " -"gestores de contexto son normalmente invocados utilizando la declaración :" -"keyword:`!with` (descritos en la sección :ref:`with`), pero también pueden " -"ser utilizados al invocar directamente sus métodos." +"ejecución a ser establecido cuando se ejecuta una declaración " +":keyword:`with`. El gestor de contexto maneja la entrada y la salida del " +"contexto en tiempo de ejecución deseado para la ejecución del bloque de " +"código. Los gestores de contexto son normalmente invocados utilizando la " +"declaración :keyword:`!with` (descritos en la sección :ref:`with`), pero " +"también pueden ser utilizados al invocar directamente sus métodos." #: ../Doc/reference/datamodel.rst:2919 msgid "" @@ -4437,14 +4765,14 @@ msgstr "" msgid "" "For more information on context managers, see :ref:`typecontextmanager`." msgstr "" -"Para más información sobre gestores de contexto, ver :ref:" -"`typecontextmanager`." +"Para más información sobre gestores de contexto, ver " +":ref:`typecontextmanager`." #: ../Doc/reference/datamodel.rst:2927 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 " -"the :keyword:`!as` clause of the statement, if any." +"statement will bind this method's return value to the target(s) specified in" +" the :keyword:`!as` clause of the statement, if any." msgstr "" "Ingresa al contexto en tiempo de ejecución relacionado con este objeto. La " "declaración :keyword:`with` ligará el valor de retorno de este método al " @@ -4453,8 +4781,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2934 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 " +"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 " "without an exception, all three arguments will be :const:`None`." msgstr "" "Sale del contexto en tiempo de ejecución relacionado a este objeto. Los " @@ -4463,8 +4791,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2938 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. " +"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. " "Otherwise, the exception will be processed normally upon exit from this " "method." msgstr "" @@ -4497,24 +4825,29 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2956 msgid "Customizing positional arguments in class pattern matching" msgstr "" -"Personalización de argumentos posicionales en la coincidencia de patrones de " -"clase" +"Personalización de argumentos posicionales en la coincidencia de patrones de" +" clase" #: ../Doc/reference/datamodel.rst:2958 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 " -"without special support in ``MyClass``. To be able to use that kind of " +"are not allowed by default, i.e. ``case MyClass(x, y)`` is typically invalid" +" without special support in ``MyClass``. To be able to use that kind of " "pattern, the class needs to define a *__match_args__* attribute." msgstr "" +"Cuando se utiliza un nombre de clase en un patrón, los argumentos " +"posicionales en el patrón no están permitidos de forma predeterminada, es " +"decir, ``case MyClass(x, y)`` normalmente no es válido sin un soporte " +"especial en ``MyClass``. Para poder utilizar ese tipo de patrón, la clase " +"necesita definir un atributo *__match_args__*." #: ../Doc/reference/datamodel.rst:2965 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 " "will be converted into a keyword argument, using the corresponding value in " -"*__match_args__* as the keyword. The absence of this attribute is equivalent " -"to setting it to ``()``." +"*__match_args__* as the keyword. The absence of this attribute is equivalent" +" to setting it to ``()``." msgstr "" "A esta variable de clase se le puede asignar una tupla de cadenas. Cuando " "esta clase se utiliza en un patrón de clase con argumentos posicionales, " @@ -4528,14 +4861,14 @@ msgid "" "\"right\")`` that means that ``case MyClass(x, y)`` is equivalent to ``case " "MyClass(left=x, center=y)``. Note that the number of arguments in the " "pattern must be smaller than or equal to the number of elements in " -"*__match_args__*; if it is larger, the pattern match attempt will raise a :" -"exc:`TypeError`." +"*__match_args__*; if it is larger, the pattern match attempt will raise a " +":exc:`TypeError`." msgstr "" "Por ejemplo, si ``MyClass.__match_args__`` es ``(\"left\", \"center\", " "\"right\")`` eso significa que ``case MyClass(x, y)`` es equivalente a " "``case MyClass(left=x, center=y)``. Ten en cuenta que el número de " -"argumentos en el patrón debe ser menor o igual que el número de elementos en " -"*__match_args__*; si es más grande, el intento de coincidencia de patrón " +"argumentos en el patrón debe ser menor o igual que el número de elementos en" +" *__match_args__*; si es más grande, el intento de coincidencia de patrón " "producirá un :exc:`TypeError`." #: ../Doc/reference/datamodel.rst:2981 @@ -4552,53 +4885,73 @@ msgstr "Emulando tipos de búfer" #: ../Doc/reference/datamodel.rst:2990 msgid "" -"The :ref:`buffer protocol ` provides a way for Python objects " -"to expose efficient access to a low-level memory array. This protocol is " -"implemented by builtin types such as :class:`bytes` and :class:`memoryview`, " -"and third-party libraries may define additional buffer types." +"The :ref:`buffer protocol ` provides a way for Python objects" +" to expose efficient access to a low-level memory array. This protocol is " +"implemented by builtin types such as :class:`bytes` and :class:`memoryview`," +" and third-party libraries may define additional buffer types." msgstr "" +":ref:`buffer protocol ` proporciona una forma para que los " +"objetos Python expongan un acceso eficiente a una matriz de memoria de bajo " +"nivel. Este protocolo se implementa mediante tipos integrados como " +":class:`bytes` y :class:`memoryview`, y bibliotecas de terceros pueden " +"definir tipos de búfer adicionales." #: ../Doc/reference/datamodel.rst:2995 msgid "" "While buffer types are usually implemented in C, it is also possible to " "implement the protocol in Python." msgstr "" +"Si bien los tipos de búfer generalmente se implementan en C, también es " +"posible implementar el protocolo en Python." #: ../Doc/reference/datamodel.rst:3000 msgid "" -"Called when a buffer is requested from *self* (for example, by the :class:" -"`memoryview` constructor). The *flags* argument is an integer representing " -"the kind of buffer requested, affecting for example whether the returned " -"buffer is read-only or writable. :class:`inspect.BufferFlags` provides a " -"convenient way to interpret the flags. The method must return a :class:" -"`memoryview` object." -msgstr "" +"Called when a buffer is requested from *self* (for example, by the " +":class:`memoryview` constructor). The *flags* argument is an integer " +"representing the kind of buffer requested, affecting for example whether the" +" returned buffer is read-only or writable. :class:`inspect.BufferFlags` " +"provides a convenient way to interpret the flags. The method must return a " +":class:`memoryview` object." +msgstr "" +"Se llama cuando se solicita un búfer desde *self* (por ejemplo, por el " +"constructor :class:`memoryview`). El argumento *flags* es un número entero " +"que representa el tipo de búfer solicitado y afecta, por ejemplo, si el " +"búfer retornado es de solo lectura o de escritura. " +":class:`inspect.BufferFlags` proporciona una manera conveniente de " +"interpretar las banderas. El método debe retornar un objeto " +":class:`memoryview`." #: ../Doc/reference/datamodel.rst:3009 msgid "" -"Called when a buffer is no longer needed. The *buffer* argument is a :class:" -"`memoryview` object that was previously returned by :meth:`~object." -"__buffer__`. The method must release any resources associated with the " -"buffer. This method should return ``None``. Buffer objects that do not need " -"to perform any cleanup are not required to implement this method." -msgstr "" +"Called when a buffer is no longer needed. The *buffer* argument is a " +":class:`memoryview` object that was previously returned by " +":meth:`~object.__buffer__`. The method must release any resources associated" +" with the buffer. This method should return ``None``. Buffer objects that do" +" not need to perform any cleanup are not required to implement this method." +msgstr "" +"Se llama cuando ya no se necesita un búfer. El argumento *buffer* es un " +"objeto :class:`memoryview` que :meth:`~object.__buffer__` retornó " +"anteriormente. El método debe liberar todos los recursos asociados con el " +"búfer. Este método debería retornar ``None``. Los objetos de búfer que no " +"necesitan realizar ninguna limpieza no son necesarios para implementar este " +"método." #: ../Doc/reference/datamodel.rst:3021 msgid ":pep:`688` - Making the buffer protocol accessible in Python" -msgstr "" +msgstr ":pep:`688`: hacer accesible el protocolo de búfer en Python" #: ../Doc/reference/datamodel.rst:3021 msgid "" "Introduces the Python ``__buffer__`` and ``__release_buffer__`` methods." -msgstr "" +msgstr "Presenta los métodos Python ``__buffer__`` y ``__release_buffer__``." #: ../Doc/reference/datamodel.rst:3023 msgid ":class:`collections.abc.Buffer`" -msgstr "" +msgstr ":class:`collections.abc.Buffer`" #: ../Doc/reference/datamodel.rst:3024 msgid "ABC for buffer types." -msgstr "" +msgstr "ABC para tipos de buffer." #: ../Doc/reference/datamodel.rst:3029 msgid "Special method lookup" @@ -4625,12 +4978,17 @@ msgid "" "of these methods used the conventional lookup process, they would fail when " "invoked on the type object itself::" msgstr "" +"La razón detrás de este comportamiento radica en una serie de métodos " +"especiales, como :meth:`~object.__hash__` y :meth:`~object.__repr__`, que " +"implementan todos los objetos, incluidos los objetos de tipo. Si la búsqueda" +" implícita de estos métodos utilizara el proceso de búsqueda convencional, " +"fallarían cuando se invocaran en el objeto de tipo mismo:" #: ../Doc/reference/datamodel.rst:3060 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 " -"the instance when looking up special methods::" +"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" +" the instance when looking up special methods::" msgstr "" "Intentar invocar de manera incorrecta el método no ligado de una clase de " "esta forma a veces es denominado como ‘confusión de metaclase’, y se evita " @@ -4639,9 +4997,12 @@ msgstr "" #: ../Doc/reference/datamodel.rst:3069 msgid "" "In addition to bypassing any instance attributes in the interest of " -"correctness, implicit special method lookup generally also bypasses the :" -"meth:`~object.__getattribute__` method even of the object's metaclass::" +"correctness, implicit special method lookup generally also bypasses the " +":meth:`~object.__getattribute__` method even of the object's metaclass::" msgstr "" +"Además de omitir cualquier atributo de instancia en aras de la corrección, " +"la búsqueda implícita de métodos especiales generalmente también omite el " +"método :meth:`~object.__getattribute__` incluso de la metaclase del objeto::" #: ../Doc/reference/datamodel.rst:3095 msgid "" @@ -4651,6 +5012,11 @@ msgid "" "special method *must* be set on the class object itself in order to be " "consistently invoked by the interpreter)." msgstr "" +"Omitir la maquinaria :meth:`~object.__getattribute__` de esta manera " +"proporciona un margen significativo para optimizar la velocidad dentro del " +"intérprete, a costa de cierta flexibilidad en el manejo de métodos " +"especiales (el método especial *must* debe configurarse en el propio objeto " +"de clase para que el intérprete lo invoque consistentemente). )." #: ../Doc/reference/datamodel.rst:3106 msgid "Coroutines" @@ -4662,23 +5028,29 @@ msgstr "Objetos esperables" #: ../Doc/reference/datamodel.rst:3112 msgid "" -"An :term:`awaitable` object generally implements an :meth:`~object." -"__await__` method. :term:`Coroutine objects ` returned from :" -"keyword:`async def` functions are awaitable." +"An :term:`awaitable` object generally implements an " +":meth:`~object.__await__` method. :term:`Coroutine objects ` " +"returned from :keyword:`async def` functions are awaitable." msgstr "" +"Un objeto :term:`awaitable` generalmente implementa un método " +":meth:`~object.__await__`. :term:`Coroutine objects ` retornado " +"por las funciones :keyword:`async def` están a la espera." #: ../Doc/reference/datamodel.rst:3118 msgid "" "The :term:`generator iterator` objects returned from generators decorated " -"with :func:`types.coroutine` are also awaitable, but they do not implement :" -"meth:`~object.__await__`." +"with :func:`types.coroutine` are also awaitable, but they do not implement " +":meth:`~object.__await__`." msgstr "" +"Los objetos :term:`generator iterator` retornados por generadores decorados " +"con :func:`types.coroutine` también están a la espera, pero no implementan " +":meth:`~object.__await__`." #: ../Doc/reference/datamodel.rst:3124 msgid "" -"Must return an :term:`iterator`. Should be used to implement :term:" -"`awaitable` objects. For instance, :class:`asyncio.Future` implements this " -"method to be compatible with the :keyword:`await` expression." +"Must return an :term:`iterator`. Should be used to implement " +":term:`awaitable` objects. For instance, :class:`asyncio.Future` implements" +" this method to be compatible with the :keyword:`await` expression." msgstr "" "Debe retornar un :term:`iterator`. Debe ser utilizado para implementar " "objetos :term:`awaitable`. Por ejemplo, :class:`asyncio.Future` implementa " @@ -4688,9 +5060,13 @@ msgstr "" msgid "" "The language doesn't place any restriction on the type or value of the " "objects yielded by the iterator returned by ``__await__``, as this is " -"specific to the implementation of the asynchronous execution framework (e." -"g. :mod:`asyncio`) that will be managing the :term:`awaitable` object." +"specific to the implementation of the asynchronous execution framework (e.g." +" :mod:`asyncio`) that will be managing the :term:`awaitable` object." msgstr "" +"El lenguaje no impone ninguna restricción sobre el tipo o valor de los " +"objetos generados por el iterador retornado por ``__await__``, ya que esto " +"es específico de la implementación del marco de ejecución asincrónica (por " +"ejemplo, :mod:`asyncio`) que administrará el objeto :term:`awaitable`." #: ../Doc/reference/datamodel.rst:3138 msgid ":pep:`492` for additional information about awaitable objects." @@ -4703,13 +5079,21 @@ msgstr "Objetos de corrutina" #: ../Doc/reference/datamodel.rst:3146 msgid "" ":term:`Coroutine objects ` are :term:`awaitable` objects. A " -"coroutine's execution can be controlled by calling :meth:`~object.__await__` " -"and iterating over the result. When the coroutine has finished executing " -"and returns, the iterator raises :exc:`StopIteration`, and the exception's :" -"attr:`~StopIteration.value` attribute holds the return value. If the " -"coroutine raises an exception, it is propagated by the iterator. Coroutines " -"should not directly raise unhandled :exc:`StopIteration` exceptions." -msgstr "" +"coroutine's execution can be controlled by calling :meth:`~object.__await__`" +" and iterating over the result. When the coroutine has finished executing " +"and returns, the iterator raises :exc:`StopIteration`, and the exception's " +":attr:`~StopIteration.value` attribute holds the return value. If the " +"coroutine raises an exception, it is propagated by the iterator. Coroutines" +" should not directly raise unhandled :exc:`StopIteration` exceptions." +msgstr "" +":term:`Coroutine objects ` son objetos :term:`awaitable`. La " +"ejecución de una corrutina se puede controlar llamando a " +":meth:`~object.__await__` e iterando sobre el resultado. Cuando la rutina " +"termina de ejecutarse y regresa, el iterador genera :exc:`StopIteration` y " +"el atributo :attr:`~StopIteration.value` de la excepción contiene el valor " +"de retorno. Si la rutina genera una excepción, el iterador la propaga. Las " +"corrutinas no deberían generar directamente excepciones :exc:`StopIteration`" +" no controladas." #: ../Doc/reference/datamodel.rst:3154 msgid "" @@ -4730,30 +5114,47 @@ msgstr "" #: ../Doc/reference/datamodel.rst:3164 msgid "" "Starts or resumes execution of the coroutine. If *value* is ``None``, this " -"is equivalent to advancing the iterator returned by :meth:`~object." -"__await__`. If *value* is not ``None``, this method delegates to the :meth:" -"`~generator.send` method of the iterator that caused the coroutine to " -"suspend. The result (return value, :exc:`StopIteration`, or other " -"exception) is the same as when iterating over the :meth:`__await__` return " -"value, described above." -msgstr "" +"is equivalent to advancing the iterator returned by " +":meth:`~object.__await__`. If *value* is not ``None``, this method " +"delegates to the :meth:`~generator.send` method of the iterator that caused " +"the coroutine to suspend. The result (return value, :exc:`StopIteration`, " +"or other exception) is the same as when iterating over the :meth:`__await__`" +" return value, described above." +msgstr "" +"Inicia o reanuda la ejecución de la corrutina. Si *value* es ``None``, esto " +"equivale a avanzar el iterador retornado por :meth:`~object.__await__`. Si " +"*value* no es ``None``, este método delega en el método " +":meth:`~generator.send` del iterador que provocó la suspensión de la rutina." +" El resultado (valor de retorno, :exc:`StopIteration` u otra excepción) es " +"el mismo que cuando se itera sobre el valor de retorno :meth:`__await__`, " +"descrito anteriormente." #: ../Doc/reference/datamodel.rst:3175 msgid "" "Raises the specified exception in the coroutine. This method delegates to " "the :meth:`~generator.throw` method of the iterator that caused the " "coroutine to suspend, if it has such a method. Otherwise, the exception is " -"raised at the suspension point. The result (return value, :exc:" -"`StopIteration`, or other exception) is the same as when iterating over the :" -"meth:`~object.__await__` return value, described above. If the exception is " -"not caught in the coroutine, it propagates back to the caller." -msgstr "" +"raised at the suspension point. The result (return value, " +":exc:`StopIteration`, or other exception) is the same as when iterating over" +" the :meth:`~object.__await__` return value, described above. If the " +"exception is not caught in the coroutine, it propagates back to the caller." +msgstr "" +"Genera la excepción especificada en la corrutina. Este método delega al " +"método :meth:`~generator.throw` del iterador que provocó la suspensión de la" +" rutina, si tiene dicho método. En caso contrario, la excepción se plantea " +"en el punto de suspensión. El resultado (valor de retorno, " +":exc:`StopIteration` u otra excepción) es el mismo que cuando se itera sobre" +" el valor de retorno :meth:`~object.__await__`, descrito anteriormente. Si " +"la excepción no queda atrapada en la rutina, se propaga de nuevo a la " +"persona que llama." #: ../Doc/reference/datamodel.rst:3186 msgid "" "The second signature \\(type\\[, value\\[, traceback\\]\\]\\) is deprecated " "and may be removed in a future version of Python." msgstr "" +"La segunda firma \\(type\\[, value\\[, traceback\\]\\]\\) está obsoleta y " +"puede eliminarse en una versión futura de Python." #: ../Doc/reference/datamodel.rst:3191 msgid "" @@ -4761,20 +5162,20 @@ msgid "" "suspended, this method first delegates to the :meth:`~generator.close` " "method of the iterator that caused the coroutine to suspend, if it has such " "a method. Then it raises :exc:`GeneratorExit` at the suspension point, " -"causing the coroutine to immediately clean itself up. Finally, the coroutine " -"is marked as having finished executing, even if it was never started." +"causing the coroutine to immediately clean itself up. Finally, the coroutine" +" is marked as having finished executing, even if it was never started." msgstr "" "Causa que la corrutina misma se borre a sí misma y termine su ejecución. Si " -"la corrutina es suspendida, este método primero delega a :meth:`~generator." -"close`, si existe, del iterador que causó la suspensión de la corrutina. " -"Luego lanza una excepción :exc:`GeneratorExit` en el punto de suspensión, " -"causando que la corrutina se borre a sí misma. Finalmente, la corrutina es " -"marcada como completada, aún si nunca inició." +"la corrutina es suspendida, este método primero delega a " +":meth:`~generator.close`, si existe, del iterador que causó la suspensión de" +" la corrutina. Luego lanza una excepción :exc:`GeneratorExit` en el punto de" +" suspensión, causando que la corrutina se borre a sí misma. Finalmente, la " +"corrutina es marcada como completada, aún si nunca inició." #: ../Doc/reference/datamodel.rst:3199 msgid "" -"Coroutine objects are automatically closed using the above process when they " -"are about to be destroyed." +"Coroutine objects are automatically closed using the above process when they" +" are about to be destroyed." msgstr "" "Objetos de corrutina son cerrados automáticamente utilizando el proceso " "anterior cuando están a punto de ser destruidos." @@ -4795,8 +5196,8 @@ msgstr "" msgid "" "Asynchronous iterators can be used in an :keyword:`async for` statement." msgstr "" -"Iteradores asíncronos pueden ser utilizados en la declaración :keyword:" -"`async for`." +"Iteradores asíncronos pueden ser utilizados en la declaración " +":keyword:`async for`." #: ../Doc/reference/datamodel.rst:3214 msgid "Must return an *asynchronous iterator* object." @@ -4821,13 +5222,19 @@ msgid "" "that would resolve to an :term:`asynchronous iterator `." msgstr "" +"Antes de Python 3.7, :meth:`~object.__aiter__` podía retornar un *awaitable*" +" que se resolvería en un :term:`asynchronous iterator `." #: ../Doc/reference/datamodel.rst:3243 msgid "" "Starting with Python 3.7, :meth:`~object.__aiter__` must return an " -"asynchronous iterator object. Returning anything else will result in a :exc:" -"`TypeError` error." +"asynchronous iterator object. Returning anything else will result in a " +":exc:`TypeError` error." msgstr "" +"A partir de Python 3.7, :meth:`~object.__aiter__` debe retornar un objeto " +"iterador asincrónico. Retornar cualquier otra cosa resultará en un error " +":exc:`TypeError`." #: ../Doc/reference/datamodel.rst:3251 msgid "Asynchronous Context Managers" @@ -4846,13 +5253,13 @@ msgid "" "Asynchronous context managers can be used in an :keyword:`async with` " "statement." msgstr "" -"Los gestores de contexto asíncronos pueden ser utilizados en una " -"declaración :keyword:`async with`." +"Los gestores de contexto asíncronos pueden ser utilizados en una declaración" +" :keyword:`async with`." #: ../Doc/reference/datamodel.rst:3260 msgid "" -"Semantically similar to :meth:`__enter__`, the only difference being that it " -"must return an *awaitable*." +"Semantically similar to :meth:`__enter__`, the only difference being that it" +" must return an *awaitable*." msgstr "" "Semánticamente similar a :meth:`__enter__`, siendo la única diferencia que " "debe retorna un *esperable*." @@ -4880,22 +5287,28 @@ msgid "" "lead to some very strange behaviour if it is handled incorrectly." msgstr "" "Es posible cambiar en algunos casos un tipo de objeto bajo ciertas " -"circunstancias controladas. Generalmente no es buena idea, ya que esto puede " -"llevar a un comportamiento bastante extraño de no ser tratado correctamente." +"circunstancias controladas. Generalmente no es buena idea, ya que esto puede" +" llevar a un comportamiento bastante extraño de no ser tratado " +"correctamente." #: ../Doc/reference/datamodel.rst:3286 msgid "" -"The :meth:`~object.__hash__`, :meth:`~object.__iter__`, :meth:`~object." -"__reversed__`, and :meth:`~object.__contains__` methods have special " -"handling for this; others will still raise a :exc:`TypeError`, but may do so " -"by relying on the behavior that ``None`` is not callable." +"The :meth:`~object.__hash__`, :meth:`~object.__iter__`, " +":meth:`~object.__reversed__`, and :meth:`~object.__contains__` methods have " +"special handling for this; others will still raise a :exc:`TypeError`, but " +"may do so by relying on the behavior that ``None`` is not callable." msgstr "" +"Los métodos :meth:`~object.__hash__`, :meth:`~object.__iter__`, " +":meth:`~object.__reversed__` y :meth:`~object.__contains__` tienen un manejo" +" especial para esto; otros seguirán generando un :exc:`TypeError`, pero " +"pueden hacerlo confiando en el comportamiento de que ``None`` no es " +"invocable." #: ../Doc/reference/datamodel.rst:3292 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 " -"want to force fallback to the right operand's reflected method—that will " +"method returns ``NotImplemented``. Do not set the method to ``None`` if you" +" want to force fallback to the right operand's reflected method—that will " "instead have the opposite effect of explicitly *blocking* such fallback." msgstr "" "“No soporta” aquí significa que la clase no tiene tal método, o el método " @@ -4910,7 +5323,9 @@ msgid "" "method -- such as :meth:`~object.__add__` -- fails then the overall " "operation is not supported, which is why the reflected method is not called." msgstr "" - +"Para operandos del mismo tipo, se supone que si el método no reflejado (como" +" :meth:`~object.__add__`) falla, entonces la operación general no es " +"compatible, razón por la cual no se llama al método reflejado." #: ../Doc/reference/datamodel.rst:14 ../Doc/reference/datamodel.rst:148 #: ../Doc/reference/datamodel.rst:159 ../Doc/reference/datamodel.rst:180 @@ -4934,7 +5349,7 @@ msgstr "Objetos" #: ../Doc/reference/datamodel.rst:14 ../Doc/reference/datamodel.rst:122 msgid "data" -msgstr "" +msgstr "datos" #: ../Doc/reference/datamodel.rst:23 ../Doc/reference/datamodel.rst:292 #: ../Doc/reference/datamodel.rst:336 ../Doc/reference/datamodel.rst:420 @@ -4951,7 +5366,7 @@ msgstr "Funciones incorporadas" #: ../Doc/reference/datamodel.rst:23 msgid "id" -msgstr "" +msgstr "identificación" #: ../Doc/reference/datamodel.rst:23 ../Doc/reference/datamodel.rst:122 #: ../Doc/reference/datamodel.rst:2168 @@ -4988,7 +5403,7 @@ msgstr "conteo de referencias" #: ../Doc/reference/datamodel.rst:60 msgid "unreachable object" -msgstr "bjetos que no se pueden acceder" +msgstr "objetos que no se pueden acceder" #: ../Doc/reference/datamodel.rst:95 ../Doc/reference/datamodel.rst:891 msgid "container" @@ -5080,12 +5495,12 @@ msgstr "Java" #: ../Doc/reference/datamodel.rst:279 ../Doc/reference/datamodel.rst:2860 msgid "complex" -msgstr "" +msgstr "complejo" #: ../Doc/reference/datamodel.rst:292 ../Doc/reference/datamodel.rst:420 #: ../Doc/reference/datamodel.rst:459 ../Doc/reference/datamodel.rst:2596 msgid "len" -msgstr "" +msgstr "len" #: ../Doc/reference/datamodel.rst:292 ../Doc/reference/datamodel.rst:986 msgid "sequence" @@ -5093,20 +5508,20 @@ msgstr "Secuencias" #: ../Doc/reference/datamodel.rst:292 msgid "index operation" -msgstr "" +msgstr "operación de índice" #: ../Doc/reference/datamodel.rst:292 msgid "item selection" -msgstr "" +msgstr "selección de artículos" #: ../Doc/reference/datamodel.rst:292 ../Doc/reference/datamodel.rst:381 #: ../Doc/reference/datamodel.rst:459 msgid "subscription" -msgstr "" +msgstr "suscripción" #: ../Doc/reference/datamodel.rst:304 ../Doc/reference/datamodel.rst:381 msgid "slicing" -msgstr "" +msgstr "rebanar" #: ../Doc/reference/datamodel.rst:321 msgid "immutable sequence" @@ -5151,7 +5566,7 @@ msgstr "único" #: ../Doc/reference/datamodel.rst:356 msgid "empty" -msgstr "" +msgstr "vacío" #: ../Doc/reference/datamodel.rst:369 ../Doc/reference/datamodel.rst:1532 msgid "bytes" @@ -5250,7 +5665,7 @@ msgstr "argumento" #: ../Doc/reference/datamodel.rst:525 ../Doc/reference/datamodel.rst:640 msgid "user-defined" -msgstr definida por el usuario" +msgstr "definida por el usuario" #: ../Doc/reference/datamodel.rst:525 msgid "user-defined function" @@ -5578,7 +5993,7 @@ msgstr "co_qualname (atributo de objeto de código)" #: ../Doc/reference/datamodel.rst:1118 msgid "documentation string" -msgstr "cade de caracteres de documentación" +msgstr "cadena de caracteres de documentación" #: ../Doc/reference/datamodel.rst:1162 msgid "frame" @@ -5863,4 +6278,4 @@ msgstr "with" #: ../Doc/reference/datamodel.rst:2915 msgid "context manager" -msgstr "gestor de contexto" \ No newline at end of file +msgstr "gestor de contexto" From ce113464283734c5379a59430ed035358a89802d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cristi=C3=A1n=20Maureira-Fredes?= Date: Fri, 5 Jan 2024 11:09:13 +0100 Subject: [PATCH 5/5] Quitando dos entradas fuzzy --- reference/datamodel.po | 2836 ++++++++++++++++++++-------------------- 1 file changed, 1399 insertions(+), 1437 deletions(-) diff --git a/reference/datamodel.po b/reference/datamodel.po index 815165451a..2d183989e1 100644 --- a/reference/datamodel.po +++ b/reference/datamodel.po @@ -36,9 +36,9 @@ msgid "" "computer\", code is also represented by objects.)" msgstr "" ":dfn:`Objects` son la abstracción de Python para los datos. Todos los datos " -"en un programa Python están representados por objetos o por relaciones entre" -" objetos. (En cierto sentido y de conformidad con el modelo de Von Neumann " -"de una \"programa almacenado de computadora\", el código también está " +"en un programa Python están representados por objetos o por relaciones entre " +"objetos. (En cierto sentido y de conformidad con el modelo de Von Neumann de " +"una \"programa almacenado de computadora\", el código también está " "representado por objetos.)" #: ../Doc/reference/datamodel.rst:35 @@ -50,10 +50,10 @@ msgid "" "identity." msgstr "" "Cada objeto tiene una identidad, un tipo y un valor. La *identidad* de un " -"objeto nunca cambia una vez que ha sido creado; puede pensar en ello como la" -" dirección del objeto en la memoria. El operador ':keyword:`is`' compara la " -"identidad de dos objetos; la función :func:`id` retorna un número entero que" -" representa su identidad." +"objeto nunca cambia una vez que ha sido creado; puede pensar en ello como la " +"dirección del objeto en la memoria. El operador ':keyword:`is`' compara la " +"identidad de dos objetos; la función :func:`id` retorna un número entero que " +"representa su identidad." #: ../Doc/reference/datamodel.rst:42 msgid "For CPython, ``id(x)`` is the memory address where ``x`` is stored." @@ -63,16 +63,16 @@ msgstr "" #: ../Doc/reference/datamodel.rst:44 msgid "" "An object's type determines the operations that the object supports (e.g., " -"\"does it have a length?\") and also defines the possible values for objects" -" of that type. The :func:`type` function returns an object's type (which is" -" an object itself). Like its identity, an object's :dfn:`type` is also " +"\"does it have a length?\") and also defines the possible values for objects " +"of that type. The :func:`type` function returns an object's type (which is " +"an object itself). Like its identity, an object's :dfn:`type` is also " "unchangeable. [#]_" msgstr "" "El tipo de un objeto determina las operaciones que admite el objeto (por " "ejemplo, \"¿tiene una longitud?\") y también define los posibles valores " "para los objetos de ese tipo. La función :func:`type` retorna el tipo de un " -"objeto (que es un objeto en sí mismo). Al igual que su identidad, también el" -" :dfn:`type` de un objeto es inmutable. [#]_" +"objeto (que es un objeto en sí mismo). Al igual que su identidad, también " +"el :dfn:`type` de un objeto es inmutable. [#]_" #: ../Doc/reference/datamodel.rst:50 msgid "" @@ -82,8 +82,8 @@ msgid "" "that contains a reference to a mutable object can change when the latter's " "value is changed; however the container is still considered immutable, " "because the collection of objects it contains cannot be changed. So, " -"immutability is not strictly the same as having an unchangeable value, it is" -" more subtle.) An object's mutability is determined by its type; for " +"immutability is not strictly the same as having an unchangeable value, it is " +"more subtle.) An object's mutability is determined by its type; for " "instance, numbers, strings and tuples are immutable, while dictionaries and " "lists are mutable." msgstr "" @@ -96,8 +96,8 @@ msgstr "" "que contiene no se puede cambiar. Por lo tanto, la inmutabilidad no es " "estrictamente lo mismo que tener un valor inmutable, es más sutil). La " "mutabilidad de un objeto está determinada por su tipo; por ejemplo, los " -"números, las cadenas de caracteres y las tuplas son inmutables, mientras que" -" los diccionarios y las listas son mutables." +"números, las cadenas de caracteres y las tuplas son inmutables, mientras que " +"los diccionarios y las listas son mutables." #: ../Doc/reference/datamodel.rst:65 msgid "" @@ -109,10 +109,10 @@ msgid "" msgstr "" "Los objetos nunca se destruyen explícitamente; sin embargo, cuando se " "vuelven inalcanzables, se pueden recolectar basura. Se permite a una " -"implementación posponer la recolección de basura u omitirla por completo; es" -" una cuestión de calidad de la implementación cómo se implementa la " -"recolección de basura, siempre que no se recolecten objetos que todavía sean" -" accesibles." +"implementación posponer la recolección de basura u omitirla por completo; es " +"una cuestión de calidad de la implementación cómo se implementa la " +"recolección de basura, siempre que no se recolecten objetos que todavía sean " +"accesibles." #: ../Doc/reference/datamodel.rst:73 msgid "" @@ -145,36 +145,35 @@ msgstr "" "Tenga en cuenta que el uso de las funciones de rastreo o depuración de la " "implementación puede mantener activos los objetos que normalmente serían " "coleccionables. También tenga en cuenta que la captura de una excepción con " -"una sentencia ':keyword:`try`...\\ :keyword:`except`' puede mantener objetos" -" activos." +"una sentencia ':keyword:`try`...\\ :keyword:`except`' puede mantener objetos " +"activos." #: ../Doc/reference/datamodel.rst:87 msgid "" -"Some objects contain references to \"external\" resources such as open files" -" or windows. It is understood that these resources are freed when the " -"object is garbage-collected, but since garbage collection is not guaranteed " -"to happen, such objects also provide an explicit way to release the external" -" resource, usually a :meth:`close` method. Programs are strongly recommended" -" to explicitly close such objects. The ':keyword:`try`...\\ " -":keyword:`finally`' statement and the ':keyword:`with`' statement provide " -"convenient ways to do this." +"Some objects contain references to \"external\" resources such as open files " +"or windows. It is understood that these resources are freed when the object " +"is garbage-collected, but since garbage collection is not guaranteed to " +"happen, such objects also provide an explicit way to release the external " +"resource, usually a :meth:`close` method. Programs are strongly recommended " +"to explicitly close such objects. The ':keyword:`try`...\\ :keyword:" +"`finally`' statement and the ':keyword:`with`' statement provide convenient " +"ways to do this." msgstr "" "Algunos objetos contienen referencias a recursos \"externos\" como archivos " "abiertos o ventanas. Se entiende que estos recursos se liberan cuando el " "objeto es eliminado por el recolector de basura, pero como no se garantiza " -"que la recolección de basura suceda, dichos objetos también proporcionan una" -" forma explícita de liberar el recurso externo, generalmente un método " -":meth:`close`. Se recomienda encarecidamente a los programas cerrar " -"explícitamente dichos objetos. La declaración ':keyword:`try`...\\ " -":keyword:`finally`' y la declaración ':keyword:`with`' proporcionan formas " -"convenientes de hacer esto." +"que la recolección de basura suceda, dichos objetos también proporcionan una " +"forma explícita de liberar el recurso externo, generalmente un método :meth:" +"`close`. Se recomienda encarecidamente a los programas cerrar explícitamente " +"dichos objetos. La declaración ':keyword:`try`...\\ :keyword:`finally`' y la " +"declaración ':keyword:`with`' proporcionan formas convenientes de hacer esto." #: ../Doc/reference/datamodel.rst:97 msgid "" "Some objects contain references to other objects; these are called " "*containers*. Examples of containers are tuples, lists and dictionaries. " -"The references are part of a container's value. In most cases, when we talk" -" about the value of a container, we imply the values, not the identities of " +"The references are part of a container's value. In most cases, when we talk " +"about the value of a container, we imply the values, not the identities of " "the contained objects; however, when we talk about the mutability of a " "container, only the identities of the immediately contained objects are " "implied. So, if an immutable container (like a tuple) contains a reference " @@ -196,9 +195,9 @@ msgid "" "object identity is affected in some sense: for immutable types, operations " "that compute new values may actually return a reference to any existing " "object with the same type and value, while for mutable objects this is not " -"allowed. E.g., after ``a = 1; b = 1``, ``a`` and ``b`` may or may not refer" -" to the same object with the value one, depending on the implementation, but" -" after ``c = []; d = []``, ``c`` and ``d`` are guaranteed to refer to two " +"allowed. E.g., after ``a = 1; b = 1``, ``a`` and ``b`` may or may not refer " +"to the same object with the value one, depending on the implementation, but " +"after ``c = []; d = []``, ``c`` and ``d`` are guaranteed to refer to two " "different, unique, newly created empty lists. (Note that ``c = d = []`` " "assigns the same object to both ``c`` and ``d``.)" msgstr "" @@ -208,11 +207,11 @@ msgstr "" "valores en realidad pueden retornar una referencia a cualquier objeto " "existente con el mismo tipo y valor, mientras que para los objetos mutables " "esto no está permitido. Por ejemplo, al hacer ``a = 1; b = 1``, ``a`` y " -"``b`` puede o no referirse al mismo objeto con el valor 1, dependiendo de la" -" implementación, pero al hacer ``c = []; d = []``, ``c`` y ``d`` se " -"garantiza que se refieren a dos listas vacías diferentes, únicas y recién " -"creadas. (Tenga en cuenta que ``c = d = []`` asigna el mismo objeto a ambos " -"``c`` y ``d``.)" +"``b`` puede o no referirse al mismo objeto con el valor 1, dependiendo de la " +"implementación, pero al hacer ``c = []; d = []``, ``c`` y ``d`` se garantiza " +"que se refieren a dos listas vacías diferentes, únicas y recién creadas. " +"(Tenga en cuenta que ``c = d = []`` asigna el mismo objeto a ambos ``c`` y " +"``d``.)" #: ../Doc/reference/datamodel.rst:120 msgid "The standard type hierarchy" @@ -222,24 +221,24 @@ msgstr "Jerarquía de tipos estándar" msgid "" "Below is a list of the types that are built into Python. Extension modules " "(written in C, Java, or other languages, depending on the implementation) " -"can define additional types. Future versions of Python may add types to the" -" type hierarchy (e.g., rational numbers, efficiently stored arrays of " +"can define additional types. Future versions of Python may add types to the " +"type hierarchy (e.g., rational numbers, efficiently stored arrays of " "integers, etc.), although such additions will often be provided via the " "standard library instead." msgstr "" "A continuación se muestra una lista de los tipos integrados en Python. Los " "módulos de extensión (escritos en C, Java u otros lenguajes, dependiendo de " "la implementación) pueden definir tipos adicionales. Las versiones futuras " -"de Python pueden agregar tipos a la jerarquía de tipos (por ejemplo, números" -" racionales, matrices de enteros almacenados de manera eficiente, etc.), " +"de Python pueden agregar tipos a la jerarquía de tipos (por ejemplo, números " +"racionales, matrices de enteros almacenados de manera eficiente, etc.), " "aunque tales adiciones a menudo se proporcionarán a través de la biblioteca " "estándar." #: ../Doc/reference/datamodel.rst:140 msgid "" "Some of the type descriptions below contain a paragraph listing 'special " -"attributes.' These are attributes that provide access to the implementation" -" and are not intended for general use. Their definition may change in the " +"attributes.' These are attributes that provide access to the implementation " +"and are not intended for general use. Their definition may change in the " "future." msgstr "" "Algunas de las descripciones de tipos a continuación contienen un párrafo " @@ -255,8 +254,8 @@ msgstr "None" msgid "" "This type has a single value. There is a single object with this value. " "This object is accessed through the built-in name ``None``. It is used to " -"signify the absence of a value in many situations, e.g., it is returned from" -" functions that don't explicitly return anything. Its truth value is false." +"signify the absence of a value in many situations, e.g., it is returned from " +"functions that don't explicitly return anything. Its truth value is false." msgstr "" "Este tipo tiene un solo valor. Hay un solo objeto con este valor. Se accede " "a este objeto a través del nombre incorporado ``None``. Se utiliza para " @@ -272,10 +271,10 @@ msgstr "NotImplemented" msgid "" "This type has a single value. There is a single object with this value. " "This object is accessed through the built-in name ``NotImplemented``. " -"Numeric methods and rich comparison methods should return this value if they" -" do not implement the operation for the operands provided. (The interpreter" -" will then try the reflected operation, or some other fallback, depending on" -" the operator.) It should not be evaluated in a boolean context." +"Numeric methods and rich comparison methods should return this value if they " +"do not implement the operation for the operands provided. (The interpreter " +"will then try the reflected operation, or some other fallback, depending on " +"the operator.) It should not be evaluated in a boolean context." msgstr "" "Este tipo tiene un solo valor. Hay un solo objeto con este valor. Se accede " "a este objeto a través del nombre integrado ``NotImplemented``. Los métodos " @@ -296,9 +295,9 @@ msgid "" "will raise a :exc:`TypeError` in a future version of Python." msgstr "" "La evaluación de ``NotImplemented`` en un contexto booleano está en desuso. " -"Si bien actualmente se evalúa como verdadero, lanzará un " -":exc:`DeprecationWarning`. Lanzará un :exc:`TypeError` en una versión futura" -" de Python." +"Si bien actualmente se evalúa como verdadero, lanzará un :exc:" +"`DeprecationWarning`. Lanzará un :exc:`TypeError` en una versión futura de " +"Python." #: ../Doc/reference/datamodel.rst:179 ../Doc/reference/datamodel.rst:180 msgid "Ellipsis" @@ -321,8 +320,8 @@ msgstr ":class:`numbers.Number`" #: ../Doc/reference/datamodel.rst:194 msgid "" "These are created by numeric literals and returned as results by arithmetic " -"operators and arithmetic built-in functions. Numeric objects are immutable;" -" once created their value never changes. Python numbers are of course " +"operators and arithmetic built-in functions. Numeric objects are immutable; " +"once created their value never changes. Python numbers are of course " "strongly related to mathematical numbers, but subject to the limitations of " "numerical representation in computers." msgstr "" @@ -334,15 +333,14 @@ msgstr "" "numérica en las computadoras." #: ../Doc/reference/datamodel.rst:200 -#, fuzzy msgid "" -"The string representations of the numeric classes, computed by " -":meth:`~object.__repr__` and :meth:`~object.__str__`, have the following " +"The string representations of the numeric classes, computed by :meth:" +"`~object.__repr__` and :meth:`~object.__str__`, have the following " "properties:" msgstr "" -"Las representaciones de cadena de las clases numéricas, calculadas por " -":meth:`~object.__repr__` y :meth:`~object.__str__`, tienen las siguientes " -"propiedades:" +"Las representaciones de cadena de caracteres de las clases numéricas, " +"calculadas por :meth:`~object.__repr__` y :meth:`~object.__str__`, tienen " +"las siguientes propiedades:" #: ../Doc/reference/datamodel.rst:204 msgid "" @@ -390,8 +388,8 @@ msgstr ":class:`numbers.Integral`" #: ../Doc/reference/datamodel.rst:227 msgid "" -"These represent elements from the mathematical set of integers (positive and" -" negative)." +"These represent elements from the mathematical set of integers (positive and " +"negative)." msgstr "" "Estos representan elementos del conjunto matemático de números enteros " "(positivo y negativo)." @@ -435,18 +433,18 @@ msgstr "Booleanos (:class:`bool`)" #: ../Doc/reference/datamodel.rst:251 msgid "" "These represent the truth values False and True. The two objects " -"representing the values ``False`` and ``True`` are the only Boolean objects." -" The Boolean type is a subtype of the integer type, and Boolean values " -"behave like the values 0 and 1, respectively, in almost all contexts, the " -"exception being that when converted to a string, the strings ``\"False\"`` " -"or ``\"True\"`` are returned, respectively." +"representing the values ``False`` and ``True`` are the only Boolean objects. " +"The Boolean type is a subtype of the integer type, and Boolean values behave " +"like the values 0 and 1, respectively, in almost all contexts, the exception " +"being that when converted to a string, the strings ``\"False\"`` or " +"``\"True\"`` are returned, respectively." msgstr "" "Estos representan los valores de verdad Falso y Verdadero. Los dos objetos " "que representan los valores ``False`` y ``True`` son los únicos objetos " "booleanos. El tipo booleano es un subtipo del tipo entero y los valores " -"booleanos se comportan como los valores 0 y 1 respectivamente, en casi todos" -" los contextos, con la excepción de que cuando se convierten en una cadena " -"de caracteres, las cadenas de caracteres ``\"False\"`` o ``\"True\"`` son " +"booleanos se comportan como los valores 0 y 1 respectivamente, en casi todos " +"los contextos, con la excepción de que cuando se convierten en una cadena de " +"caracteres, las cadenas de caracteres ``\"False\"`` o ``\"True\"`` son " "retornadas respectivamente." #: ../Doc/reference/datamodel.rst:259 @@ -457,11 +455,11 @@ msgstr ":class:`numbers.Real` (:class:`float`)" msgid "" "These represent machine-level double precision floating point numbers. You " "are at the mercy of the underlying machine architecture (and C or Java " -"implementation) for the accepted range and handling of overflow. Python does" -" not support single-precision floating point numbers; the savings in " +"implementation) for the accepted range and handling of overflow. Python does " +"not support single-precision floating point numbers; the savings in " "processor and memory usage that are usually the reason for using these are " -"dwarfed by the overhead of using objects in Python, so there is no reason to" -" complicate the language with two kinds of floating point numbers." +"dwarfed by the overhead of using objects in Python, so there is no reason to " +"complicate the language with two kinds of floating point numbers." msgstr "" "Estos representan números de punto flotante de precisión doble a nivel de " "máquina. Está a merced de la arquitectura de la máquina subyacente (y la " @@ -485,8 +483,8 @@ msgid "" msgstr "" "Estos representan números complejos como un par de números de coma flotante " "de precisión doble a nivel de máquina. Se aplican las mismas advertencias " -"que para los números de coma flotante. Las partes reales e imaginarias de un" -" número complejo ``z`` se pueden obtener a través de los atributos de solo " +"que para los números de coma flotante. Las partes reales e imaginarias de un " +"número complejo ``z`` se pueden obtener a través de los atributos de solo " "lectura ``z.real`` y ``z.imag``." #: ../Doc/reference/datamodel.rst:290 @@ -501,9 +499,9 @@ msgid "" "1, ..., *n*-1. Item *i* of sequence *a* is selected by ``a[i]``." msgstr "" "Estos representan conjuntos ordenados finitos indexados por números no " -"negativos. La función incorporada :func:`len` retorna el número de elementos" -" de una secuencia. Cuando la longitud de una secuencia es *n*, el conjunto " -"de índices contiene los números 0, 1, ..., *n*-1. El elemento *i* de la " +"negativos. La función incorporada :func:`len` retorna el número de elementos " +"de una secuencia. Cuando la longitud de una secuencia es *n*, el conjunto de " +"índices contiene los números 0, 1, ..., *n*-1. El elemento *i* de la " "secuencia *a* se selecciona mediante ``a[i]``." #: ../Doc/reference/datamodel.rst:306 @@ -513,11 +511,11 @@ msgid "" "a sequence of the same type. This implies that the index set is renumbered " "so that it starts at 0." msgstr "" -"Las secuencias también admiten segmentación: ``a[i:j]`` selecciona todos los" -" elementos con índice *k* de modo que *i* ``<=`` *k* ``<`` *j*. Cuando se " +"Las secuencias también admiten segmentación: ``a[i:j]`` selecciona todos los " +"elementos con índice *k* de modo que *i* ``<=`` *k* ``<`` *j*. Cuando se " "usa como una expresión, un segmento es una secuencia del mismo tipo. Esto " -"implica que el conjunto de índices se vuelve a enumerar para que comience en" -" 0." +"implica que el conjunto de índices se vuelve a enumerar para que comience en " +"0." #: ../Doc/reference/datamodel.rst:311 msgid "" @@ -541,15 +539,15 @@ msgstr "Secuencias inmutables" #: ../Doc/reference/datamodel.rst:325 msgid "" "An object of an immutable sequence type cannot change once it is created. " -"(If the object contains references to other objects, these other objects may" -" be mutable and may be changed; however, the collection of objects directly " +"(If the object contains references to other objects, these other objects may " +"be mutable and may be changed; however, the collection of objects directly " "referenced by an immutable object cannot change.)" msgstr "" "Un objeto de un tipo de secuencia inmutable no puede cambiar una vez que se " "crea. (Si el objeto contiene referencias a otros objetos, estos otros " -"objetos pueden ser mutables y pueden cambiarse; sin embargo, la colección de" -" objetos a los que hace referencia directamente un objeto inmutable no puede" -" cambiar)." +"objetos pueden ser mutables y pueden cambiarse; sin embargo, la colección de " +"objetos a los que hace referencia directamente un objeto inmutable no puede " +"cambiar)." #: ../Doc/reference/datamodel.rst:330 msgid "The following types are immutable sequences:" @@ -561,28 +559,28 @@ msgstr "Cadenas de caracteres" #: ../Doc/reference/datamodel.rst:343 msgid "" -"A string is a sequence of values that represent Unicode code points. All the" -" code points in the range ``U+0000 - U+10FFFF`` can be represented in a " +"A string is a sequence of values that represent Unicode code points. All the " +"code points in the range ``U+0000 - U+10FFFF`` can be represented in a " "string. Python doesn't have a :c:expr:`char` type; instead, every code " "point in the string is represented as a string object with length ``1``. " -"The built-in function :func:`ord` converts a code point from its string form" -" to an integer in the range ``0 - 10FFFF``; :func:`chr` converts an integer " -"in the range ``0 - 10FFFF`` to the corresponding length ``1`` string object." -" :meth:`str.encode` can be used to convert a :class:`str` to :class:`bytes` " -"using the given text encoding, and :meth:`bytes.decode` can be used to " -"achieve the opposite." +"The built-in function :func:`ord` converts a code point from its string form " +"to an integer in the range ``0 - 10FFFF``; :func:`chr` converts an integer " +"in the range ``0 - 10FFFF`` to the corresponding length ``1`` string " +"object. :meth:`str.encode` can be used to convert a :class:`str` to :class:" +"`bytes` using the given text encoding, and :meth:`bytes.decode` can be used " +"to achieve the opposite." msgstr "" "Una cadena es una secuencia de valores que representan puntos de código " "Unicode. Todos los puntos de código en el rango ``U+0000 - U+10FFFF`` se " -"pueden representar en una cadena. Python no tiene un tipo :c:expr:`char`; en" -" su lugar, cada punto de código de la cadena se representa como un objeto de" -" cadena con una longitud ``1``. La función integrada :func:`ord` convierte " -"un punto de código de su forma de cadena a un entero en el rango ``0 - " +"pueden representar en una cadena. Python no tiene un tipo :c:expr:`char`; en " +"su lugar, cada punto de código de la cadena se representa como un objeto de " +"cadena con una longitud ``1``. La función integrada :func:`ord` convierte un " +"punto de código de su forma de cadena a un entero en el rango ``0 - " "10FFFF``; :func:`chr` convierte un entero en el rango ``0 - 10FFFF`` al " "objeto de cadena ``1`` de longitud correspondiente. :meth:`str.encode` se " "puede usar para convertir un :class:`str` a :class:`bytes` usando la " -"codificación de texto dada, y :meth:`bytes.decode` se puede usar para lograr" -" lo contrario." +"codificación de texto dada, y :meth:`bytes.decode` se puede usar para lograr " +"lo contrario." #: ../Doc/reference/datamodel.rst:366 msgid "Tuples" @@ -613,15 +611,15 @@ msgid "" "A bytes object is an immutable array. The items are 8-bit bytes, " "represented by integers in the range 0 <= x < 256. Bytes literals (like " "``b'abc'``) and the built-in :func:`bytes()` constructor can be used to " -"create bytes objects. Also, bytes objects can be decoded to strings via the" -" :meth:`~bytes.decode` method." +"create bytes objects. Also, bytes objects can be decoded to strings via " +"the :meth:`~bytes.decode` method." msgstr "" "Un objeto de bytes es una colección inmutable. Los elementos son bytes de 8 " "bits, representados por enteros en el rango 0 <= x <256. Literales de bytes " "(como ``b'abc'``) y el constructor incorporado :func:`bytes()` se puede " -"utilizar para crear objetos de bytes. Además, los objetos de bytes se pueden" -" decodificar en cadenas de caracteres a través del método " -":meth:`~bytes.decode`." +"utilizar para crear objetos de bytes. Además, los objetos de bytes se pueden " +"decodificar en cadenas de caracteres a través del método :meth:`~bytes." +"decode`." #: ../Doc/reference/datamodel.rst:379 msgid "Mutable sequences" @@ -630,8 +628,8 @@ msgstr "Secuencias mutables" #: ../Doc/reference/datamodel.rst:388 msgid "" "Mutable sequences can be changed after they are created. The subscription " -"and slicing notations can be used as the target of assignment and " -":keyword:`del` (delete) statements." +"and slicing notations can be used as the target of assignment and :keyword:" +"`del` (delete) statements." msgstr "" "Las secuencias mutables se pueden cambiar después de su creación. Las " "anotaciones de suscripción y segmentación se pueden utilizar como el " @@ -656,11 +654,11 @@ msgstr "Listas" #: ../Doc/reference/datamodel.rst:404 msgid "" "The items of a list are arbitrary Python objects. Lists are formed by " -"placing a comma-separated list of expressions in square brackets. (Note that" -" there are no special cases needed to form lists of length 0 or 1.)" +"placing a comma-separated list of expressions in square brackets. (Note that " +"there are no special cases needed to form lists of length 0 or 1.)" msgstr "" -"Los elementos de una lista son objetos de Python arbitrarios. Las listas se" -" forman colocando una lista de expresiones separadas por comas entre " +"Los elementos de una lista son objetos de Python arbitrarios. Las listas se " +"forman colocando una lista de expresiones separadas por comas entre " "corchetes. (Tome en cuenta que no hay casos especiales necesarios para " "formar listas de longitud 0 o 1.)" @@ -670,13 +668,13 @@ msgstr "Colecciones de bytes" #: ../Doc/reference/datamodel.rst:411 msgid "" -"A bytearray object is a mutable array. They are created by the built-in " -":func:`bytearray` constructor. Aside from being mutable (and hence " +"A bytearray object is a mutable array. They are created by the built-in :" +"func:`bytearray` constructor. Aside from being mutable (and hence " "unhashable), byte arrays otherwise provide the same interface and " "functionality as immutable :class:`bytes` objects." msgstr "" -"Un objeto bytearray es una colección mutable. Son creados por el constructor" -" incorporado :func:`bytearray`. Además de ser mutables (y, por lo tanto, " +"Un objeto bytearray es una colección mutable. Son creados por el constructor " +"incorporado :func:`bytearray`. Además de ser mutables (y, por lo tanto, " "inquebrantable), las colecciones de bytes proporcionan la misma interfaz y " "funcionalidad que los objetos inmutables :class:`bytes`." @@ -687,11 +685,11 @@ msgstr "Tipos de conjuntos" #: ../Doc/reference/datamodel.rst:424 msgid "" "These represent unordered, finite sets of unique, immutable objects. As " -"such, they cannot be indexed by any subscript. However, they can be iterated" -" over, and the built-in function :func:`len` returns the number of items in " -"a set. Common uses for sets are fast membership testing, removing duplicates" -" from a sequence, and computing mathematical operations such as " -"intersection, union, difference, and symmetric difference." +"such, they cannot be indexed by any subscript. However, they can be iterated " +"over, and the built-in function :func:`len` returns the number of items in a " +"set. Common uses for sets are fast membership testing, removing duplicates " +"from a sequence, and computing mathematical operations such as intersection, " +"union, difference, and symmetric difference." msgstr "" "Estos representan conjuntos finitos no ordenados de objetos únicos e " "inmutables. Como tal, no pueden ser indexados por ningún *subscript*. Sin " @@ -704,15 +702,15 @@ msgstr "" #: ../Doc/reference/datamodel.rst:431 msgid "" "For set elements, the same immutability rules apply as for dictionary keys. " -"Note that numeric types obey the normal rules for numeric comparison: if two" -" numbers compare equal (e.g., ``1`` and ``1.0``), only one of them can be " +"Note that numeric types obey the normal rules for numeric comparison: if two " +"numbers compare equal (e.g., ``1`` and ``1.0``), only one of them can be " "contained in a set." msgstr "" "Para elementos del conjunto, se aplican las mismas reglas de inmutabilidad " "que para las claves de diccionario. Tenga en cuenta que los tipos numéricos " -"obedecen las reglas normales para la comparación numérica: si dos números se" -" comparan igual (por ejemplo, ``1`` y ``1.0``), solo uno de ellos puede " -"estar contenido en un conjunto." +"obedecen las reglas normales para la comparación numérica: si dos números se " +"comparan igual (por ejemplo, ``1`` y ``1.0``), solo uno de ellos puede estar " +"contenido en un conjunto." #: ../Doc/reference/datamodel.rst:436 msgid "There are currently two intrinsic set types:" @@ -725,8 +723,8 @@ msgstr "Conjuntos" #: ../Doc/reference/datamodel.rst:442 msgid "" "These represent a mutable set. They are created by the built-in :func:`set` " -"constructor and can be modified afterwards by several methods, such as " -":meth:`~set.add`." +"constructor and can be modified afterwards by several methods, such as :meth:" +"`~set.add`." msgstr "" "Estos representan un conjunto mutable. Son creados por el constructor " "incorporado :func:`set` y puede ser modificado posteriormente por varios " @@ -738,15 +736,14 @@ msgstr "Conjuntos congelados" #: ../Doc/reference/datamodel.rst:450 msgid "" -"These represent an immutable set. They are created by the built-in " -":func:`frozenset` constructor. As a frozenset is immutable and " -":term:`hashable`, it can be used again as an element of another set, or as a" -" dictionary key." +"These represent an immutable set. They are created by the built-in :func:" +"`frozenset` constructor. As a frozenset is immutable and :term:`hashable`, " +"it can be used again as an element of another set, or as a dictionary key." msgstr "" "Estos representan un conjunto inmutable. Son creados por el constructor " -"incorporado :func:`frozenset`. Como un conjunto congelado es inmutable y " -":term:`hashable`, se puede usar nuevamente como un elemento de otro conjunto" -" o como una clave de un diccionario." +"incorporado :func:`frozenset`. Como un conjunto congelado es inmutable y :" +"term:`hashable`, se puede usar nuevamente como un elemento de otro conjunto " +"o como una clave de un diccionario." #: ../Doc/reference/datamodel.rst:457 msgid "Mappings" @@ -763,9 +760,9 @@ msgstr "" "Estos representan conjuntos finitos de objetos indexados por conjuntos de " "índices arbitrarios. La notación de subíndice ``a[k]`` selecciona el " "elemento indexado por ``k`` del mapeo ``a``; esto se puede usar en " -"expresiones y como el objetivo de asignaciones o declaraciones " -":keyword:`del`. La función incorporada :func:`len` retorna el número de " -"elementos en un mapeo." +"expresiones y como el objetivo de asignaciones o declaraciones :keyword:" +"`del`. La función incorporada :func:`len` retorna el número de elementos en " +"un mapeo." #: ../Doc/reference/datamodel.rst:470 msgid "There is currently a single intrinsic mapping type:" @@ -790,29 +787,29 @@ msgstr "" "arbitrarios. Los únicos tipos de valores no aceptables como claves son " "valores que contienen listas o diccionarios u otros tipos mutables que se " "comparan por valor en lugar de por identidad de objeto, la razón es que la " -"implementación eficiente de los diccionarios requiere que el valor *hash* de" -" una clave permanezca constante. Los tipos numéricos utilizados para las " +"implementación eficiente de los diccionarios requiere que el valor *hash* de " +"una clave permanezca constante. Los tipos numéricos utilizados para las " "claves obedecen las reglas normales para la comparación numérica: si dos " "números se comparan igual (por ejemplo, ``1`` y ``1.0``) entonces se pueden " "usar indistintamente para indexar la misma entrada del diccionario." #: ../Doc/reference/datamodel.rst:487 msgid "" -"Dictionaries preserve insertion order, meaning that keys will be produced in" -" the same order they were added sequentially over the dictionary. Replacing " +"Dictionaries preserve insertion order, meaning that keys will be produced in " +"the same order they were added sequentially over the dictionary. Replacing " "an existing key does not change the order, however removing a key and re-" "inserting it will add it to the end instead of keeping its old place." msgstr "" "Los diccionarios conservan el orden de inserción, lo que significa que las " "claves se mantendrán en el mismo orden en que se agregaron secuencialmente " -"sobre el diccionario. Reemplazar una clave existente no cambia el orden, sin" -" embargo, eliminar una clave y volver a insertarla la agregará al final en " +"sobre el diccionario. Reemplazar una clave existente no cambia el orden, sin " +"embargo, eliminar una clave y volver a insertarla la agregará al final en " "lugar de mantener su lugar anterior." #: ../Doc/reference/datamodel.rst:492 msgid "" -"Dictionaries are mutable; they can be created by the ``{...}`` notation (see" -" section :ref:`dict`)." +"Dictionaries are mutable; they can be created by the ``{...}`` notation (see " +"section :ref:`dict`)." msgstr "" "Los diccionarios son mutables; pueden ser creados por la notación ``{...}`` " "(vea la sección :ref:`dict`)." @@ -823,14 +820,14 @@ msgid "" "examples of mapping types, as does the :mod:`collections` module." msgstr "" "Los módulos de extensión :mod:`dbm.ndbm` y :mod:`dbm.gnu` proporcionan " -"ejemplos adicionales de tipos de mapeo, al igual que el módulo " -":mod:`collections`." +"ejemplos adicionales de tipos de mapeo, al igual que el módulo :mod:" +"`collections`." #: ../Doc/reference/datamodel.rst:503 msgid "" "Dictionaries did not preserve insertion order in versions of Python before " -"3.6. In CPython 3.6, insertion order was preserved, but it was considered an" -" implementation detail at that time rather than a language guarantee." +"3.6. In CPython 3.6, insertion order was preserved, but it was considered an " +"implementation detail at that time rather than a language guarantee." msgstr "" "Los diccionarios no conservaban el orden de inserción en las versiones de " "Python anteriores a 3.6. En CPython 3.6, el orden de inserción se conserva, " @@ -843,8 +840,8 @@ msgstr "Tipos invocables" #: ../Doc/reference/datamodel.rst:518 msgid "" -"These are the types to which the function call operation (see section " -":ref:`calls`) can be applied:" +"These are the types to which the function call operation (see section :ref:" +"`calls`) can be applied:" msgstr "" "Estos son los tipos a los que la operación de llamada de función (vea la " "sección :ref:`calls`) puede ser aplicado:" @@ -952,8 +949,8 @@ msgstr ":attr:`__globals__`" #: ../Doc/reference/datamodel.rst:582 msgid "" -"A reference to the dictionary that holds the function's global variables ---" -" the global namespace of the module in which the function was defined." +"A reference to the dictionary that holds the function's global variables --- " +"the global namespace of the module in which the function was defined." msgstr "" "Una referencia al diccionario que contiene las variables globales de la " "función --- el espacio de nombres global del módulo en el que se definió la " @@ -1012,34 +1009,33 @@ msgstr "" "palabras clave." #: ../Doc/reference/datamodel.rst:613 ../Doc/reference/datamodel.rst:954 -#, fuzzy msgid ":attr:`__type_params__`" -msgstr ":attr:`__name__`" +msgstr ":attr:`__type_params__`" #: ../Doc/reference/datamodel.rst:613 msgid "" -"A tuple containing the :ref:`type parameters ` of a " -":ref:`generic function `." +"A tuple containing the :ref:`type parameters ` of a :ref:" +"`generic function `." msgstr "" -"Una tupla que contiene el :ref:`type parameters ` de un " -":ref:`generic function `." +"Una tupla que contiene el :ref:`type parameters ` de un :ref:" +"`generic function `." #: ../Doc/reference/datamodel.rst:620 msgid "" "Most of the attributes labelled \"Writable\" check the type of the assigned " "value." msgstr "" -"La mayoría de los atributos etiquetados \"Escribible\" verifican el tipo del" -" valor asignado." +"La mayoría de los atributos etiquetados \"Escribible\" verifican el tipo del " +"valor asignado." #: ../Doc/reference/datamodel.rst:622 msgid "" "Function objects also support getting and setting arbitrary attributes, " "which can be used, for example, to attach metadata to functions. Regular " "attribute dot-notation is used to get and set such attributes. *Note that " -"the current implementation only supports function attributes on user-defined" -" functions. Function attributes on built-in functions may be supported in " -"the future.*" +"the current implementation only supports function attributes on user-defined " +"functions. Function attributes on built-in functions may be supported in the " +"future.*" msgstr "" "Los objetos de función también admiten la obtención y configuración de " "atributos arbitrarios, que se pueden usar, por ejemplo, para adjuntar " @@ -1060,14 +1056,13 @@ msgstr "" #: ../Doc/reference/datamodel.rst:631 msgid "" "Additional information about a function's definition can be retrieved from " -"its code object; see the description of internal types below. The " -":data:`cell ` type can be accessed in the :mod:`types` " -"module." +"its code object; see the description of internal types below. The :data:" +"`cell ` type can be accessed in the :mod:`types` module." msgstr "" "Se puede recuperar información adicional sobre la definición de una función " "desde su objeto de código; Vea la descripción de los tipos internos a " -"continuación. El tipo :data:`cell ` puede ser accedido en el" -" módulo :mod:`types`." +"continuación. El tipo :data:`cell ` puede ser accedido en el " +"módulo :mod:`types`." #: ../Doc/reference/datamodel.rst:638 msgid "Instance methods" @@ -1078,26 +1073,24 @@ msgid "" "An instance method object combines a class, a class instance and any " "callable object (normally a user-defined function)." msgstr "" -"Un objeto de método de instancia combina una clase, una instancia de clase y" -" cualquier objeto invocable (normalmente una función definida por el " -"usuario)." +"Un objeto de método de instancia combina una clase, una instancia de clase y " +"cualquier objeto invocable (normalmente una función definida por el usuario)." #: ../Doc/reference/datamodel.rst:655 msgid "" -"Special read-only attributes: :attr:`__self__` is the class instance object," -" :attr:`__func__` is the function object; :attr:`__doc__` is the method's " -"documentation (same as ``__func__.__doc__``); :attr:`~definition.__name__` " -"is the method name (same as ``__func__.__name__``); :attr:`__module__` is " -"the name of the module the method was defined in, or ``None`` if " -"unavailable." +"Special read-only attributes: :attr:`__self__` is the class instance " +"object, :attr:`__func__` is the function object; :attr:`__doc__` is the " +"method's documentation (same as ``__func__.__doc__``); :attr:`~definition." +"__name__` is the method name (same as ``__func__.__name__``); :attr:" +"`__module__` is the name of the module the method was defined in, or " +"``None`` if unavailable." msgstr "" "Atributos especiales de solo lectura: :attr:`__self__` es el objeto de " -"instancia de clase, :attr:`__func__` es el objeto de función; " -":attr:`__doc__` es la documentación del método (al igual que " -"``__func__.__doc__``); :attr:`~definition.__name__` es el nombre del método " -"(al igual que ``__func__.__name__``); :attr:`__module__` es el nombre del " -"módulo en el que el método fue definido, o ``None`` si no se encuentra " -"disponible." +"instancia de clase, :attr:`__func__` es el objeto de función; :attr:" +"`__doc__` es la documentación del método (al igual que ``__func__." +"__doc__``); :attr:`~definition.__name__` es el nombre del método (al igual " +"que ``__func__.__name__``); :attr:`__module__` es el nombre del módulo en el " +"que el método fue definido, o ``None`` si no se encuentra disponible." #: ../Doc/reference/datamodel.rst:661 msgid "" @@ -1128,36 +1121,35 @@ msgstr "" "Cuando un objeto de instancia de método es creado al obtener un objeto de " "función definida por el usuario desde una clase a través de una de sus " "instancias, su atributo :attr:`__self__` es la instancia, y el objeto de " -"método se dice que está enlazado. El nuevo atributo de método " -":attr:`__func__` es el objeto de función original." +"método se dice que está enlazado. El nuevo atributo de método :attr:" +"`__func__` es el objeto de función original." #: ../Doc/reference/datamodel.rst:674 msgid "" "When an instance method object is created by retrieving a class method " -"object from a class or instance, its :attr:`__self__` attribute is the class" -" itself, and its :attr:`__func__` attribute is the function object " -"underlying the class method." +"object from a class or instance, its :attr:`__self__` attribute is the class " +"itself, and its :attr:`__func__` attribute is the function object underlying " +"the class method." msgstr "" "Cuando un objeto de instancia de método es creado al obtener un objeto de " -"método de clase a partir de una clase o instancia, su atributo " -":attr:`__self__` es la clase misma, y su atributo :attr:`__func__` es el " -"objeto de función subyacente al método de la clase." +"método de clase a partir de una clase o instancia, su atributo :attr:" +"`__self__` es la clase misma, y su atributo :attr:`__func__` es el objeto de " +"función subyacente al método de la clase." #: ../Doc/reference/datamodel.rst:679 msgid "" -"When an instance method object is called, the underlying function " -"(:attr:`__func__`) is called, inserting the class instance " -"(:attr:`__self__`) in front of the argument list. For instance, when " -":class:`C` is a class which contains a definition for a function :meth:`f`, " -"and ``x`` is an instance of :class:`C`, calling ``x.f(1)`` is equivalent to " -"calling ``C.f(x, 1)``." +"When an instance method object is called, the underlying function (:attr:" +"`__func__`) is called, inserting the class instance (:attr:`__self__`) in " +"front of the argument list. For instance, when :class:`C` is a class which " +"contains a definition for a function :meth:`f`, and ``x`` is an instance of :" +"class:`C`, calling ``x.f(1)`` is equivalent to calling ``C.f(x, 1)``." msgstr "" "Cuando el objeto de la instancia de método es invocado, la función " -"subyacente (:attr:`__func__`) es llamada, insertando la instancia de clase " -"(:attr:`__self__`) delante de la lista de argumentos. Por ejemplo, cuando " -":class:`C` es una clase que contiene la definición de una función :meth:`f`," -" y ``x`` es una instancia de :class:`C`, invocar ``x.f(1)`` es equivalente a" -" invocar ``C.f(x, 1)``." +"subyacente (:attr:`__func__`) es llamada, insertando la instancia de clase (:" +"attr:`__self__`) delante de la lista de argumentos. Por ejemplo, cuando :" +"class:`C` es una clase que contiene la definición de una función :meth:`f`, " +"y ``x`` es una instancia de :class:`C`, invocar ``x.f(1)`` es equivalente a " +"invocar ``C.f(x, 1)``." #: ../Doc/reference/datamodel.rst:686 msgid "" @@ -1166,10 +1158,10 @@ msgid "" "itself, so that calling either ``x.f(1)`` or ``C.f(1)`` is equivalent to " "calling ``f(C,1)`` where ``f`` is the underlying function." msgstr "" -"Cuando el objeto de instancia de método es derivado del objeto del método de" -" clase, la “instancia de clase” almacenada en :attr:`__self__` en realidad " -"será la clase misma, de manera que invocar ya sea ``x.f(1)`` o ``C.f(1)`` es" -" equivalente a invocar ``f(C,1)`` donde ``f`` es la función subyacente." +"Cuando el objeto de instancia de método es derivado del objeto del método de " +"clase, la “instancia de clase” almacenada en :attr:`__self__` en realidad " +"será la clase misma, de manera que invocar ya sea ``x.f(1)`` o ``C.f(1)`` es " +"equivalente a invocar ``f(C,1)`` donde ``f`` es la función subyacente." #: ../Doc/reference/datamodel.rst:691 msgid "" @@ -1177,14 +1169,14 @@ msgid "" "happens each time the attribute is retrieved from the instance. In some " "cases, a fruitful optimization is to assign the attribute to a local " "variable and call that local variable. Also notice that this transformation " -"only happens for user-defined functions; other callable objects (and all " -"non-callable objects) are retrieved without transformation. It is also " +"only happens for user-defined functions; other callable objects (and all non-" +"callable objects) are retrieved without transformation. It is also " "important to note that user-defined functions which are attributes of a " "class instance are not converted to bound methods; this *only* happens when " "the function is an attribute of the class." msgstr "" -"Tome en cuenta que la transformación de objeto de función a objeto de método" -" de instancia ocurre cada vez que el atributo es obtenido de la instancia. " +"Tome en cuenta que la transformación de objeto de función a objeto de método " +"de instancia ocurre cada vez que el atributo es obtenido de la instancia. " "En algunos casos, una optimización fructífera es asignar el atributo a una " "variable local e invocarla. Note también que esta transformación únicamente " "ocurre con funciones definidas por usuario; otros objetos invocables (y " @@ -1200,21 +1192,21 @@ msgstr "Funciones generadoras" #: ../Doc/reference/datamodel.rst:710 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 " +"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 :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." +"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 "" "Una función o método que utiliza la instrucción :keyword:`yield` (consulte " "la sección :ref:`yield`) se denomina :dfn:`función generadora`. Una función " "de este tipo, cuando se llama, siempre retorna un objeto :term:`iterator` " -"que se puede usar para ejecutar el cuerpo de la función: llamar al método " -":meth:`iterator.__next__` del iterador hará que la función se ejecute hasta " +"que se puede usar para ejecutar el cuerpo de la función: llamar al método :" +"meth:`iterator.__next__` del iterador hará que la función se ejecute hasta " "que proporcione un valor usando la instrucción :keyword:`!yield`. Cuando la " "función ejecuta una instrucción :keyword:`return` o se sale del final, se " "genera una excepción :exc:`StopIteration` y el iterador habrá llegado al " @@ -1226,17 +1218,17 @@ msgstr "Funciones de corrutina" #: ../Doc/reference/datamodel.rst:727 msgid "" -"A function or method which is defined using :keyword:`async def` is called a" -" :dfn:`coroutine function`. Such a function, when called, returns a " -":term:`coroutine` object. It may contain :keyword:`await` expressions, as " -"well as :keyword:`async with` and :keyword:`async for` statements. See also " -"the :ref:`coroutine-objects` section." +"A function or method which is defined using :keyword:`async def` is called " +"a :dfn:`coroutine function`. Such a function, when called, returns a :term:" +"`coroutine` object. It may contain :keyword:`await` expressions, as well " +"as :keyword:`async with` and :keyword:`async for` statements. See also the :" +"ref:`coroutine-objects` section." msgstr "" "Una función o método que es definido utilizando :keyword:`async def` se " -"llama :dfn:`coroutine function`. Dicha función, cuando es invocada, retorna" -" un objeto :term:`coroutine`. Éste puede contener expresiones " -":keyword:`await`, así como declaraciones :keyword:`async with` y " -":keyword:`async for`. Ver también la sección :ref:`coroutine-objects`." +"llama :dfn:`coroutine function`. Dicha función, cuando es invocada, retorna " +"un objeto :term:`coroutine`. Éste puede contener expresiones :keyword:" +"`await`, así como declaraciones :keyword:`async with` y :keyword:`async " +"for`. Ver también la sección :ref:`coroutine-objects`." #: ../Doc/reference/datamodel.rst:735 msgid "Asynchronous generator functions" @@ -1245,34 +1237,33 @@ msgstr "Funciones generadoras asincrónicas" #: ../Doc/reference/datamodel.rst:741 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 :term:`asynchronous " +"uses the :keyword:`yield` statement is called a :dfn:`asynchronous generator " +"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 "" "Una función o método que se define usando :keyword:`async def` y que usa la " "declaración :keyword:`yield` se llama :dfn:`función generadora asíncrona`. " -"Una función de este tipo, cuando se llama, retorna un objeto " -":term:`asynchronous iterator` que se puede utilizar en una instrucción " -":keyword:`async for` para ejecutar el cuerpo de la función." +"Una función de este tipo, cuando se llama, retorna un objeto :term:" +"`asynchronous iterator` que se puede utilizar en una instrucción :keyword:" +"`async for` para ejecutar el cuerpo de la función." #: ../Doc/reference/datamodel.rst:747 msgid "" -"Calling the asynchronous iterator's :meth:`aiterator.__anext__ " -"` method will return an :term:`awaitable` which when " -"awaited will execute until it provides a value using the :keyword:`yield` " -"expression. When the function executes an empty :keyword:`return` statement" -" or falls off the end, a :exc:`StopAsyncIteration` exception is raised and " -"the asynchronous iterator will have reached the end of the set of values to " -"be yielded." -msgstr "" -"Llamar al método :meth:`aiterator.__anext__ ` del iterador" -" asíncrono retornará un :term:`awaitable` que, cuando se espere, se " -"ejecutará hasta que proporcione un valor utilizando la expresión " -":keyword:`yield`. Cuando la función ejecuta una instrucción " -":keyword:`return` vacía o se sale del final, se genera una excepción " -":exc:`StopAsyncIteration` y el iterador asincrónico habrá llegado al final " -"del conjunto de valores que se generarán." +"Calling the asynchronous iterator's :meth:`aiterator.__anext__ ` method will return an :term:`awaitable` which when awaited will " +"execute until it provides a value using the :keyword:`yield` expression. " +"When the function executes an empty :keyword:`return` statement or falls off " +"the end, a :exc:`StopAsyncIteration` exception is raised and the " +"asynchronous iterator will have reached the end of the set of values to be " +"yielded." +msgstr "" +"Llamar al método :meth:`aiterator.__anext__ ` del iterador " +"asíncrono retornará un :term:`awaitable` que, cuando se espere, se ejecutará " +"hasta que proporcione un valor utilizando la expresión :keyword:`yield`. " +"Cuando la función ejecuta una instrucción :keyword:`return` vacía o se sale " +"del final, se genera una excepción :exc:`StopAsyncIteration` y el iterador " +"asincrónico habrá llegado al final del conjunto de valores que se generarán." #: ../Doc/reference/datamodel.rst:758 msgid "Built-in functions" @@ -1284,21 +1275,21 @@ msgid "" "built-in functions are :func:`len` and :func:`math.sin` (:mod:`math` is a " "standard built-in module). The number and type of the arguments are " "determined by the C function. Special read-only attributes: :attr:`__doc__` " -"is the function's documentation string, or ``None`` if unavailable; " -":attr:`~definition.__name__` is the function's name; :attr:`__self__` is set" -" to ``None`` (but see the next item); :attr:`__module__` is the name of the " +"is the function's documentation string, or ``None`` if unavailable; :attr:" +"`~definition.__name__` is the function's name; :attr:`__self__` is set to " +"``None`` (but see the next item); :attr:`__module__` is the name of the " "module the function was defined in or ``None`` if unavailable." msgstr "" -"Un objeto de función incorporada es un envoltorio (wrapper) alrededor de una" -" función C. Ejemplos de funciones incorporadas son :func:`len` y " -":func:`math.sin` (:mod:`math` es un módulo estándar incorporado). El número " -"y tipo de argumentos son determinados por la función C. Atributos especiales" -" de solo lectura: :attr:`__doc__` es la cadena de documentación de la " -"función, o ``None`` si no se encuentra disponible; " -":attr:`~definition.__name__` es el nombre de la función; :attr:`__init__` es" -" establecido como ``None`` (sin embargo ver el siguiente elemento); " -":attr:`__module__` es el nombre del módulo en el que la función fue definida" -" o ``None`` si no se encuentra disponible." +"Un objeto de función incorporada es un envoltorio (wrapper) alrededor de una " +"función C. Ejemplos de funciones incorporadas son :func:`len` y :func:`math." +"sin` (:mod:`math` es un módulo estándar incorporado). El número y tipo de " +"argumentos son determinados por la función C. Atributos especiales de solo " +"lectura: :attr:`__doc__` es la cadena de documentación de la función, o " +"``None`` si no se encuentra disponible; :attr:`~definition.__name__` es el " +"nombre de la función; :attr:`__init__` es establecido como ``None`` (sin " +"embargo ver el siguiente elemento); :attr:`__module__` es el nombre del " +"módulo en el que la función fue definida o ``None`` si no se encuentra " +"disponible." #: ../Doc/reference/datamodel.rst:776 msgid "Built-in methods" @@ -1307,10 +1298,10 @@ msgstr "Métodos incorporados" #: ../Doc/reference/datamodel.rst:783 msgid "" "This is really a different disguise of a built-in function, this time " -"containing an object passed to the C function as an implicit extra argument." -" An example of a built-in method is ``alist.append()``, assuming *alist* is" -" a list object. In this case, the special read-only attribute " -":attr:`__self__` is set to the object denoted by *alist*." +"containing an object passed to the C function as an implicit extra " +"argument. An example of a built-in method is ``alist.append()``, assuming " +"*alist* is a list object. In this case, the special read-only attribute :" +"attr:`__self__` is set to the object denoted by *alist*." msgstr "" "Éste es realmente un disfraz distinto de una función incorporada, esta vez " "teniendo un objeto que se pasa a la función C como un argumento extra " @@ -1327,15 +1318,15 @@ msgstr "Clases" msgid "" "Classes are callable. These objects normally act as factories for new " "instances of themselves, but variations are possible for class types that " -"override :meth:`~object.__new__`. The arguments of the call are passed to " -":meth:`__new__` and, in the typical case, to :meth:`~object.__init__` to " +"override :meth:`~object.__new__`. The arguments of the call are passed to :" +"meth:`__new__` and, in the typical case, to :meth:`~object.__init__` to " "initialize the new instance." msgstr "" "Las clases son invocables. Estos objetos normalmente actúan como fábricas " "para nuevas instancias de sí mismos, pero son posibles variaciones para los " "tipos de clases que anulan :meth:`~object.__new__`. Los argumentos de la " -"llamada se pasan a :meth:`__new__` y, en el caso típico, a " -":meth:`~object.__init__` para inicializar la nueva instancia." +"llamada se pasan a :meth:`__new__` y, en el caso típico, a :meth:`~object." +"__init__` para inicializar la nueva instancia." #: ../Doc/reference/datamodel.rst:801 msgid "Class Instances" @@ -1343,8 +1334,8 @@ msgstr "Instancias de clases" #: ../Doc/reference/datamodel.rst:803 msgid "" -"Instances of arbitrary classes can be made callable by defining a " -":meth:`~object.__call__` method in their class." +"Instances of arbitrary classes can be made callable by defining a :meth:" +"`~object.__call__` method in their class." msgstr "" "Las instancias de clases arbitrarias se pueden hacer invocables definiendo " "un método :meth:`~object.__call__` en su clase." @@ -1356,27 +1347,27 @@ msgstr "Módulos" #: ../Doc/reference/datamodel.rst:814 msgid "" "Modules are a basic organizational unit of Python code, and are created by " -"the :ref:`import system ` as invoked either by the " -":keyword:`import` statement, or by calling functions such as " -":func:`importlib.import_module` and built-in :func:`__import__`. A module " -"object has a namespace implemented by a dictionary object (this is the " -"dictionary referenced by the ``__globals__`` attribute of functions defined " -"in the module). Attribute references are translated to lookups in this " -"dictionary, e.g., ``m.x`` is equivalent to ``m.__dict__[\"x\"]``. A module " -"object does not contain the code object used to initialize the module (since" -" it isn't needed once the initialization is done)." +"the :ref:`import system ` as invoked either by the :keyword:" +"`import` statement, or by calling functions such as :func:`importlib." +"import_module` and built-in :func:`__import__`. A module object has a " +"namespace implemented by a dictionary object (this is the dictionary " +"referenced by the ``__globals__`` attribute of functions defined in the " +"module). Attribute references are translated to lookups in this dictionary, " +"e.g., ``m.x`` is equivalent to ``m.__dict__[\"x\"]``. A module object does " +"not contain the code object used to initialize the module (since it isn't " +"needed once the initialization is done)." msgstr "" "Los módulos son una unidad básica organizacional en código Python, y son " "creados por el :ref:`import system ` al ser invocados ya sea " -"por la declaración :keyword:`import`, o invocando funciones como " -":func:`importlib.import_module` y la incorporada :func:`__import__`. Un " -"objeto de módulo tiene un espacio de nombres implementado por un objeto de " -"diccionario (éste es el diccionario al que hace referencia el atributo de " -"funciones ``__globals__`` definido en el módulo). Las referencias de " -"atributos son traducidas a búsquedas en este diccionario, p. ej., ``m.x`` es" -" equivalente a ``m.__dict__[“x”]``. Un objeto de módulo no contiene el " -"objeto de código utilizado para iniciar el módulo (ya que no es necesario " -"una vez que la inicialización es realizada)." +"por la declaración :keyword:`import`, o invocando funciones como :func:" +"`importlib.import_module` y la incorporada :func:`__import__`. Un objeto de " +"módulo tiene un espacio de nombres implementado por un objeto de diccionario " +"(éste es el diccionario al que hace referencia el atributo de funciones " +"``__globals__`` definido en el módulo). Las referencias de atributos son " +"traducidas a búsquedas en este diccionario, p. ej., ``m.x`` es equivalente a " +"``m.__dict__[“x”]``. Un objeto de módulo no contiene el objeto de código " +"utilizado para iniciar el módulo (ya que no es necesario una vez que la " +"inicialización es realizada)." #: ../Doc/reference/datamodel.rst:826 msgid "" @@ -1410,8 +1401,8 @@ msgstr ":attr:`__file__`" #: ../Doc/reference/datamodel.rst:846 msgid "" "The pathname of the file from which the module was loaded, if it was loaded " -"from a file. The :attr:`__file__` attribute may be missing for certain types" -" of modules, such as C modules that are statically linked into the " +"from a file. The :attr:`__file__` attribute may be missing for certain types " +"of modules, such as C modules that are statically linked into the " "interpreter. For extension modules loaded dynamically from a shared " "library, it's the pathname of the shared library file." msgstr "" @@ -1425,13 +1416,13 @@ msgstr "" #: ../Doc/reference/datamodel.rst:855 msgid "" "A dictionary containing :term:`variable annotations ` " -"collected during module body execution. For best practices on working with " -":attr:`__annotations__`, please see :ref:`annotations-howto`." +"collected during module body execution. For best practices on working with :" +"attr:`__annotations__`, please see :ref:`annotations-howto`." msgstr "" "Un diccionario que contiene el :term:`variable annotations ` recopilados durante la ejecución del cuerpo del módulo. Para " -"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve " -":ref:`annotations-howto`." +"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve :" +"ref:`annotations-howto`." #: ../Doc/reference/datamodel.rst:862 msgid "" @@ -1443,16 +1434,16 @@ msgstr "" #: ../Doc/reference/datamodel.rst:867 msgid "" -"Because of the way CPython clears module dictionaries, the module dictionary" -" will be cleared when the module falls out of scope even if the dictionary " +"Because of the way CPython clears module dictionaries, the module dictionary " +"will be cleared when the module falls out of scope even if the dictionary " "still has live references. To avoid this, copy the dictionary or keep the " "module around while using its dictionary directly." msgstr "" "Debido a la manera en la que CPython limpia los diccionarios de módulo, el " "diccionario de módulo será limpiado cuando el módulo se encuentra fuera de " "alcance, incluso si el diccionario aún tiene referencias existentes. Para " -"evitar esto, copie el diccionario o mantenga el módulo cerca mientras usa el" -" diccionario directamente." +"evitar esto, copie el diccionario o mantenga el módulo cerca mientras usa el " +"diccionario directamente." #: ../Doc/reference/datamodel.rst:874 msgid "Custom classes" @@ -1460,18 +1451,18 @@ msgstr "Clases personalizadas" #: ../Doc/reference/datamodel.rst:876 msgid "" -"Custom class types are typically created by class definitions (see section " -":ref:`class`). A class has a namespace implemented by a dictionary object. " -"Class attribute references are translated to lookups in this dictionary, " -"e.g., ``C.x`` is translated to ``C.__dict__[\"x\"]`` (although there are a " +"Custom class types are typically created by class definitions (see section :" +"ref:`class`). A class has a namespace implemented by a dictionary object. " +"Class attribute references are translated to lookups in this dictionary, e." +"g., ``C.x`` is translated to ``C.__dict__[\"x\"]`` (although there are a " "number of hooks which allow for other means of locating attributes). When " -"the attribute name is not found there, the attribute search continues in the" -" base classes. This search of the base classes uses the C3 method resolution" -" order which behaves correctly even in the presence of 'diamond' inheritance" -" structures where there are multiple inheritance paths leading back to a " +"the attribute name is not found there, the attribute search continues in the " +"base classes. This search of the base classes uses the C3 method resolution " +"order which behaves correctly even in the presence of 'diamond' inheritance " +"structures where there are multiple inheritance paths leading back to a " "common ancestor. Additional details on the C3 MRO used by Python can be " -"found in the documentation accompanying the 2.3 release at " -"https://www.python.org/download/releases/2.3/mro/." +"found in the documentation accompanying the 2.3 release at https://www." +"python.org/download/releases/2.3/mro/." msgstr "" "Los tipos de clases personalizadas son normalmente creadas por definiciones " "de clases (ver sección :ref:`class`). Una clase tiene implementado un " @@ -1480,32 +1471,31 @@ msgstr "" "``C.x`` es traducido a ``C.__dict__[“x”]`` (aunque hay una serie de enlaces " "que permiten la ubicación de atributos por otros medios). Cuando el nombre " "de atributo no es encontrado ahí, la búsqueda de atributo continúa en las " -"clases base. Esta búsqueda de las clases base utiliza la orden de resolución" -" de métodos C3 que se comporta correctamente aún en la presencia de " -"estructuras de herencia ‘diamante’ donde existen múltiples rutas de herencia" -" que llevan a un ancestro común. Detalles adicionales en el MRO C3 " -"utilizados por Python pueden ser encontrados en la documentación " -"correspondiente a la versión 2.3 en " -"https://www.python.org/download/releases/2.3/mro/." +"clases base. Esta búsqueda de las clases base utiliza la orden de resolución " +"de métodos C3 que se comporta correctamente aún en la presencia de " +"estructuras de herencia ‘diamante’ donde existen múltiples rutas de herencia " +"que llevan a un ancestro común. Detalles adicionales en el MRO C3 utilizados " +"por Python pueden ser encontrados en la documentación correspondiente a la " +"versión 2.3 en https://www.python.org/download/releases/2.3/mro/." #: ../Doc/reference/datamodel.rst:900 msgid "" "When a class attribute reference (for class :class:`C`, say) would yield a " -"class method object, it is transformed into an instance method object whose " -":attr:`__self__` attribute is :class:`C`. When it would yield a static " +"class method object, it is transformed into an instance method object whose :" +"attr:`__self__` attribute is :class:`C`. When it would yield a static " "method object, it is transformed into the object wrapped by the static " "method object. See section :ref:`descriptors` for another way in which " "attributes retrieved from a class may differ from those actually contained " "in its :attr:`~object.__dict__`." msgstr "" -"Cuando la referencia de un atributo de clase (digamos, para la clase " -":class:`C`) produce un objeto de método de clase, éste es transformado a un " -"objeto de método de instancia cuyo atributo :attr:`__self__` es :class:`C`." -" Cuando produce un objeto de un método estático, éste es transformado al " -"objeto envuelto por el objeto de método estático. Ver sección " -":ref:`descriptors` para otra manera en la que los atributos obtenidos de una" -" clase pueden diferir de los que en realidad están contenidos en su " -":attr:`~object.__dict__`." +"Cuando la referencia de un atributo de clase (digamos, para la clase :class:" +"`C`) produce un objeto de método de clase, éste es transformado a un objeto " +"de método de instancia cuyo atributo :attr:`__self__` es :class:`C`. Cuando " +"produce un objeto de un método estático, éste es transformado al objeto " +"envuelto por el objeto de método estático. Ver sección :ref:`descriptors` " +"para otra manera en la que los atributos obtenidos de una clase pueden " +"diferir de los que en realidad están contenidos en su :attr:`~object." +"__dict__`." #: ../Doc/reference/datamodel.rst:910 msgid "" @@ -1545,11 +1535,11 @@ msgstr ":attr:`~class.__bases__`" #: ../Doc/reference/datamodel.rst:938 msgid "" -"A tuple containing the base classes, in the order of their occurrence in the" -" base class list." +"A tuple containing the base classes, in the order of their occurrence in the " +"base class list." msgstr "" -"Una tupla conteniendo las clases de base, en orden de ocurrencia en la lista" -" de clase base." +"Una tupla conteniendo las clases de base, en orden de ocurrencia en la lista " +"de clase base." #: ../Doc/reference/datamodel.rst:942 msgid "The class's documentation string, or ``None`` if undefined." @@ -1559,21 +1549,21 @@ msgstr "" #: ../Doc/reference/datamodel.rst:945 msgid "" "A dictionary containing :term:`variable annotations ` " -"collected during class body execution. For best practices on working with " -":attr:`__annotations__`, please see :ref:`annotations-howto`." +"collected during class body execution. For best practices on working with :" +"attr:`__annotations__`, please see :ref:`annotations-howto`." msgstr "" "Un diccionario conteniendo el :term:`variable annotations ` recopilados durante la ejecución del cuerpo de la clase. Para " -"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve " -":ref:`annotations-howto`." +"buenas prácticas sobre trabajar con :attr:`__annotations__`, por favor ve :" +"ref:`annotations-howto`." #: ../Doc/reference/datamodel.rst:952 msgid "" -"A tuple containing the :ref:`type parameters ` of a " -":ref:`generic class `." +"A tuple containing the :ref:`type parameters ` of a :ref:" +"`generic class `." msgstr "" -"Una tupla que contiene el :ref:`type parameters ` de un " -":ref:`generic class `." +"Una tupla que contiene el :ref:`type parameters ` de un :ref:" +"`generic class `." #: ../Doc/reference/datamodel.rst:957 msgid "Class instances" @@ -1592,36 +1582,36 @@ msgid "" "\"Classes\". See section :ref:`descriptors` for another way in which " "attributes of a class retrieved via its instances may differ from the " "objects actually stored in the class's :attr:`~object.__dict__`. If no " -"class attribute is found, and the object's class has a " -":meth:`~object.__getattr__` method, that is called to satisfy the lookup." +"class attribute is found, and the object's class has a :meth:`~object." +"__getattr__` method, that is called to satisfy the lookup." msgstr "" "Una instancia de clase se crea llamando a un objeto de clase (ver arriba). " "Una instancia de clase tiene un espacio de nombres implementado como un " "diccionario, que es el primer lugar en el que se buscan las referencias de " "atributos. Cuando no se encuentra un atributo allí y la clase de la " "instancia tiene un atributo con ese nombre, la búsqueda continúa con los " -"atributos de la clase. Si se encuentra un atributo de clase que es un objeto" -" de función definido por el usuario, se transforma en un objeto de método de" -" instancia cuyo atributo :attr:`__self__` es la instancia. Los objetos de " -"métodos estáticos y de clases también se transforman; consulte más arriba en" -" \"Clases\". Consulte la sección :ref:`descriptors` para conocer otra forma " +"atributos de la clase. Si se encuentra un atributo de clase que es un objeto " +"de función definido por el usuario, se transforma en un objeto de método de " +"instancia cuyo atributo :attr:`__self__` es la instancia. Los objetos de " +"métodos estáticos y de clases también se transforman; consulte más arriba en " +"\"Clases\". Consulte la sección :ref:`descriptors` para conocer otra forma " "en la que los atributos de una clase recuperados a través de sus instancias " -"pueden diferir de los objetos realmente almacenados en el " -":attr:`~object.__dict__` de la clase. Si no se encuentra ningún atributo de " -"clase y la clase del objeto tiene un método :meth:`~object.__getattr__`, se " -"llama para satisfacer la búsqueda." +"pueden diferir de los objetos realmente almacenados en el :attr:`~object." +"__dict__` de la clase. Si no se encuentra ningún atributo de clase y la " +"clase del objeto tiene un método :meth:`~object.__getattr__`, se llama para " +"satisfacer la búsqueda." #: ../Doc/reference/datamodel.rst:981 msgid "" "Attribute assignments and deletions update the instance's dictionary, never " -"a class's dictionary. If the class has a :meth:`~object.__setattr__` or " -":meth:`~object.__delattr__` method, this is called instead of updating the " +"a class's dictionary. If the class has a :meth:`~object.__setattr__` or :" +"meth:`~object.__delattr__` method, this is called instead of updating the " "instance dictionary directly." msgstr "" "Las asignaciones y eliminaciones de atributos actualizan el diccionario de " -"la instancia, nunca el diccionario de una clase. Si la clase tiene un método" -" :meth:`~object.__setattr__` o :meth:`~object.__delattr__`, se llama a este " -"en lugar de actualizar el diccionario de instancia directamente." +"la instancia, nunca el diccionario de una clase. Si la clase tiene un " +"método :meth:`~object.__setattr__` o :meth:`~object.__delattr__`, se llama a " +"este en lugar de actualizar el diccionario de instancia directamente." #: ../Doc/reference/datamodel.rst:991 msgid "" @@ -1629,13 +1619,13 @@ msgid "" "have methods with certain special names. See section :ref:`specialnames`." msgstr "" "Instancias de clases pueden pretender ser números, secuencias o mapeos si " -"tienen métodos con ciertos nombres especiales. Ver sección " -":ref:`specialnames`." +"tienen métodos con ciertos nombres especiales. Ver sección :ref:" +"`specialnames`." #: ../Doc/reference/datamodel.rst:998 msgid "" -"Special attributes: :attr:`~object.__dict__` is the attribute dictionary; " -":attr:`~instance.__class__` is the instance's class." +"Special attributes: :attr:`~object.__dict__` is the attribute dictionary; :" +"attr:`~instance.__class__` is the instance's class." msgstr "" "Atributos especiales: :attr:`~object.__dict__` es el diccionario de " "atributos; :attr:`~instance.__class__` es la clase de la instancia." @@ -1648,28 +1638,28 @@ msgstr "Objetos E/S (también conocidos como objetos de archivo)" msgid "" "A :term:`file object` represents an open file. Various shortcuts are " "available to create file objects: the :func:`open` built-in function, and " -"also :func:`os.popen`, :func:`os.fdopen`, and the " -":meth:`~socket.socket.makefile` method of socket objects (and perhaps by " -"other functions or methods provided by extension modules)." +"also :func:`os.popen`, :func:`os.fdopen`, and the :meth:`~socket.socket." +"makefile` method of socket objects (and perhaps by other functions or " +"methods provided by extension modules)." msgstr "" "Un :term:`file object` representa un archivo abierto. Diversos accesos " -"directos se encuentran disponibles para crear objetos de archivo: la función" -" incorporada :func:`open`, así como :func:`os.popen`, :func:`os.fdopen`, y " -"el método de objetos socket :meth:`~socket.makefile` (y quizás por otras " +"directos se encuentran disponibles para crear objetos de archivo: la función " +"incorporada :func:`open`, así como :func:`os.popen`, :func:`os.fdopen`, y el " +"método de objetos socket :meth:`~socket.makefile` (y quizás por otras " "funciones y métodos proporcionados por módulos de extensión)." #: ../Doc/reference/datamodel.rst:1024 msgid "" -"The objects ``sys.stdin``, ``sys.stdout`` and ``sys.stderr`` are initialized" -" to file objects corresponding to the interpreter's standard input, output " +"The objects ``sys.stdin``, ``sys.stdout`` and ``sys.stderr`` are initialized " +"to file objects corresponding to the interpreter's standard input, output " "and error streams; they are all open in text mode and therefore follow the " "interface defined by the :class:`io.TextIOBase` abstract class." msgstr "" "Los objetos ``sys.stdin``, ``sys.stdout`` y ``sys.stderr`` son iniciados a " "objetos de archivos correspondientes a la entrada y salida estándar del " "intérprete, así como flujos de error; todos ellos están abiertos en el modo " -"de texto y por lo tanto siguen la interface definida por la clase abstracta " -":class:`io.TextIOBase`." +"de texto y por lo tanto siguen la interface definida por la clase abstracta :" +"class:`io.TextIOBase`." #: ../Doc/reference/datamodel.rst:1032 msgid "Internal types" @@ -1691,108 +1681,106 @@ msgstr "Objetos de código" #: ../Doc/reference/datamodel.rst:1050 msgid "" -"Code objects represent *byte-compiled* executable Python code, or " -":term:`bytecode`. The difference between a code object and a function object" -" is that the function object contains an explicit reference to the " -"function's globals (the module in which it was defined), while a code object" -" contains no context; also the default argument values are stored in the " -"function object, not in the code object (because they represent values " -"calculated at run-time). Unlike function objects, code objects are " -"immutable and contain no references (directly or indirectly) to mutable " -"objects." -msgstr "" -"Los objetos de código representan código de Python ejecutable *compilado por" -" bytes*, o :term:`bytecode`. La diferencia entre un objeto de código y un " +"Code objects represent *byte-compiled* executable Python code, or :term:" +"`bytecode`. The difference between a code object and a function object is " +"that the function object contains an explicit reference to the function's " +"globals (the module in which it was defined), while a code object contains " +"no context; also the default argument values are stored in the function " +"object, not in the code object (because they represent values calculated at " +"run-time). Unlike function objects, code objects are immutable and contain " +"no references (directly or indirectly) to mutable objects." +msgstr "" +"Los objetos de código representan código de Python ejecutable *compilado por " +"bytes*, o :term:`bytecode`. La diferencia entre un objeto de código y un " "objeto de función es que el objeto de función contiene una referencia " "explícita a los globales de la función (el módulo en el que fue definido), " "mientras el objeto de código no contiene contexto; de igual manera los " "valores por defecto de los argumentos son almacenados en el objeto de " -"función, no en el objeto de código (porque representan valores calculados en" -" tiempo de ejecución). A diferencia de objetos de función, los objetos de " +"función, no en el objeto de código (porque representan valores calculados en " +"tiempo de ejecución). A diferencia de objetos de función, los objetos de " "código son inmutables y no contienen referencias (directas o indirectas) a " "objetos mutables." #: ../Doc/reference/datamodel.rst:1078 msgid "" -"Special read-only attributes: :attr:`co_name` gives the function name; " -":attr:`co_qualname` gives the fully qualified function name; " -":attr:`co_argcount` is the total number of positional arguments (including " -"positional-only arguments and arguments with default values); " -":attr:`co_posonlyargcount` is the number of positional-only arguments " -"(including arguments with default values); :attr:`co_kwonlyargcount` is the " -"number of keyword-only arguments (including arguments with default values); " -":attr:`co_nlocals` is the number of local variables used by the function " -"(including arguments); :attr:`co_varnames` is a tuple containing the names " -"of the local variables (starting with the argument names); " -":attr:`co_cellvars` is a tuple containing the names of local variables that " -"are referenced by nested functions; :attr:`co_freevars` is a tuple " -"containing the names of free variables; :attr:`co_code` is a string " -"representing the sequence of bytecode instructions; :attr:`co_consts` is a " -"tuple containing the literals used by the bytecode; :attr:`co_names` is a " -"tuple containing the names used by the bytecode; :attr:`co_filename` is the " -"filename from which the code was compiled; :attr:`co_firstlineno` is the " -"first line number of the function; :attr:`co_lnotab` is a string encoding " -"the mapping from bytecode offsets to line numbers (for details see the " -"source code of the interpreter, is deprecated since 3.12 and may be removed " -"in 3.14); :attr:`co_stacksize` is the required stack size; :attr:`co_flags` " -"is an integer encoding a number of flags for the interpreter." +"Special read-only attributes: :attr:`co_name` gives the function name; :attr:" +"`co_qualname` gives the fully qualified function name; :attr:`co_argcount` " +"is the total number of positional arguments (including positional-only " +"arguments and arguments with default values); :attr:`co_posonlyargcount` is " +"the number of positional-only arguments (including arguments with default " +"values); :attr:`co_kwonlyargcount` is the number of keyword-only arguments " +"(including arguments with default values); :attr:`co_nlocals` is the number " +"of local variables used by the function (including arguments); :attr:" +"`co_varnames` is a tuple containing the names of the local variables " +"(starting with the argument names); :attr:`co_cellvars` is a tuple " +"containing the names of local variables that are referenced by nested " +"functions; :attr:`co_freevars` is a tuple containing the names of free " +"variables; :attr:`co_code` is a string representing the sequence of bytecode " +"instructions; :attr:`co_consts` is a tuple containing the literals used by " +"the bytecode; :attr:`co_names` is a tuple containing the names used by the " +"bytecode; :attr:`co_filename` is the filename from which the code was " +"compiled; :attr:`co_firstlineno` is the first line number of the function; :" +"attr:`co_lnotab` is a string encoding the mapping from bytecode offsets to " +"line numbers (for details see the source code of the interpreter, is " +"deprecated since 3.12 and may be removed in 3.14); :attr:`co_stacksize` is " +"the required stack size; :attr:`co_flags` is an integer encoding a number of " +"flags for the interpreter." msgstr "" "Atributos especiales de solo lectura: :attr:`co_name` proporciona el nombre " "de la función; :attr:`co_qualname` proporciona el nombre completo de la " "función; :attr:`co_argcount` es el número total de argumentos posicionales " "(incluidos los argumentos solo posicionales y los argumentos con valores " -"predeterminados); :attr:`co_posonlyargcount` es el número de argumentos solo" -" posicionales (incluidos los argumentos con valores predeterminados); " -":attr:`co_kwonlyargcount` es el número de argumentos de solo palabras clave " +"predeterminados); :attr:`co_posonlyargcount` es el número de argumentos solo " +"posicionales (incluidos los argumentos con valores predeterminados); :attr:" +"`co_kwonlyargcount` es el número de argumentos de solo palabras clave " "(incluidos los argumentos con valores predeterminados); :attr:`co_nlocals` " "es el número de variables locales utilizadas por la función (incluidos los " "argumentos); :attr:`co_varnames` es una tupla que contiene los nombres de " -"las variables locales (comenzando con los nombres de los argumentos); " -":attr:`co_cellvars` es una tupla que contiene los nombres de las variables " -"locales a las que hacen referencia las funciones anidadas; " -":attr:`co_freevars` es una tupla que contiene los nombres de las variables " -"libres; :attr:`co_code` es una cadena que representa la secuencia de " -"instrucciones de código de bytes; :attr:`co_consts` es una tupla que " -"contiene los literales utilizados por el código de bytes; :attr:`co_names` " -"es una tupla que contiene los nombres utilizados por el código de bytes; " -":attr:`co_filename` es el nombre del archivo a partir del cual se compiló el" -" código; :attr:`co_firstlineno` es el número de primera línea de la función;" -" :attr:`co_lnotab` es una cadena que codifica la asignación de " -"desplazamientos de código de bytes a números de línea (para obtener más " -"detalles, consulte el código fuente del intérprete, está en desuso desde " -"3.12 y puede eliminarse en 3.14); :attr:`co_stacksize` es el tamaño de pila " -"requerido; :attr:`co_flags` es un número entero que codifica una serie de " -"indicadores para el intérprete." +"las variables locales (comenzando con los nombres de los argumentos); :attr:" +"`co_cellvars` es una tupla que contiene los nombres de las variables locales " +"a las que hacen referencia las funciones anidadas; :attr:`co_freevars` es " +"una tupla que contiene los nombres de las variables libres; :attr:`co_code` " +"es una cadena que representa la secuencia de instrucciones de código de " +"bytes; :attr:`co_consts` es una tupla que contiene los literales utilizados " +"por el código de bytes; :attr:`co_names` es una tupla que contiene los " +"nombres utilizados por el código de bytes; :attr:`co_filename` es el nombre " +"del archivo a partir del cual se compiló el código; :attr:`co_firstlineno` " +"es el número de primera línea de la función; :attr:`co_lnotab` es una cadena " +"que codifica la asignación de desplazamientos de código de bytes a números " +"de línea (para obtener más detalles, consulte el código fuente del " +"intérprete, está en desuso desde 3.12 y puede eliminarse en 3.14); :attr:" +"`co_stacksize` es el tamaño de pila requerido; :attr:`co_flags` es un número " +"entero que codifica una serie de indicadores para el intérprete." #: ../Doc/reference/datamodel.rst:1104 msgid "" "The following flag bits are defined for :attr:`co_flags`: bit ``0x04`` is " "set if the function uses the ``*arguments`` syntax to accept an arbitrary " -"number of positional arguments; bit ``0x08`` is set if the function uses the" -" ``**keywords`` syntax to accept arbitrary keyword arguments; bit ``0x20`` " -"is set if the function is a generator." +"number of positional arguments; bit ``0x08`` is set if the function uses the " +"``**keywords`` syntax to accept arbitrary keyword arguments; bit ``0x20`` is " +"set if the function is a generator." msgstr "" "Los siguientes bits de bandera son definidos por :attr:`co_flags` : bit " "``0x04`` es establecido si la función utiliza la sintaxis ``*arguments`` " "para aceptar un número arbitrario de argumentos posicionales; bit ``0x08`` " -"es establecido si la función utiliza la sintaxis ``**keywords`` para aceptar" -" argumentos de palabras clave arbitrarios; bit ``0x20`` es establecido si la" -" función es un generador." +"es establecido si la función utiliza la sintaxis ``**keywords`` para aceptar " +"argumentos de palabras clave arbitrarios; bit ``0x20`` es establecido si la " +"función es un generador." #: ../Doc/reference/datamodel.rst:1110 msgid "" "Future feature declarations (``from __future__ import division``) also use " -"bits in :attr:`co_flags` to indicate whether a code object was compiled with" -" a particular feature enabled: bit ``0x2000`` is set if the function was " +"bits in :attr:`co_flags` to indicate whether a code object was compiled with " +"a particular feature enabled: bit ``0x2000`` is set if the function was " "compiled with future division enabled; bits ``0x10`` and ``0x1000`` were " "used in earlier versions of Python." msgstr "" "Declaraciones de características futuras (``from __future__ import " "division``) también utiliza bits en :attr:`co_flags` para indicar si el " "objeto de código fue compilado con alguna característica particular " -"habilitada: el bit ``0x2000`` es establecido si la función fue compilada con" -" división futura habilitada; los bits ``0x10`` y ``0x1000`` fueron " -"utilizados en versiones previas de Python." +"habilitada: el bit ``0x2000`` es establecido si la función fue compilada con " +"división futura habilitada; los bits ``0x10`` y ``0x1000`` fueron utilizados " +"en versiones previas de Python." #: ../Doc/reference/datamodel.rst:1116 msgid "Other bits in :attr:`co_flags` are reserved for internal use." @@ -1803,9 +1791,9 @@ msgid "" "If a code object represents a function, the first item in :attr:`co_consts` " "is the documentation string of the function, or ``None`` if undefined." msgstr "" -"Si un objeto de código representa una función, el primer elemento en " -":attr:`co_consts` es la cadena de documentación de la función, o ``None`` si" -" no está definido." +"Si un objeto de código representa una función, el primer elemento en :attr:" +"`co_consts` es la cadena de documentación de la función, o ``None`` si no " +"está definido." #: ../Doc/reference/datamodel.rst:1125 msgid "" @@ -1818,9 +1806,9 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1128 msgid "" "The iterator returns tuples containing the ``(start_line, end_line, " -"start_column, end_column)``. The *i-th* tuple corresponds to the position of" -" the source code that compiled to the *i-th* instruction. Column information" -" is 0-indexed utf-8 byte offsets on the given source line." +"start_column, end_column)``. The *i-th* tuple corresponds to the position of " +"the source code that compiled to the *i-th* instruction. Column information " +"is 0-indexed utf-8 byte offsets on the given source line." msgstr "" "El iterador retorna tuplas que contienen ``(start_line, end_line, " "start_column, end_column)``. La tupla *i-th* corresponde a la posición del " @@ -1862,8 +1850,8 @@ msgstr "" msgid "" "When this occurs, some or all of the tuple elements can be :const:`None`." msgstr "" -"Cuando esto ocurre, algunos o todos los elementos de la tupla pueden ser " -":const:`None`." +"Cuando esto ocurre, algunos o todos los elementos de la tupla pueden ser :" +"const:`None`." #: ../Doc/reference/datamodel.rst:1149 msgid "" @@ -1879,8 +1867,8 @@ msgstr "" "archivos de Python compilados o del uso de la memoria del intérprete. Para " "evitar almacenar la información extra y/o desactivar la impresión de la " "información extra de seguimiento, se puede usar el indicador de línea de " -"comando :option:`-X` ``no_debug_ranges`` o la variable de entorno " -":envvar:`PYTHONNODEBUGRANGES`." +"comando :option:`-X` ``no_debug_ranges`` o la variable de entorno :envvar:" +"`PYTHONNODEBUGRANGES`." #: ../Doc/reference/datamodel.rst:1160 msgid "Frame objects" @@ -1898,66 +1886,66 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1175 msgid "" "Special read-only attributes: :attr:`f_back` is to the previous stack frame " -"(towards the caller), or ``None`` if this is the bottom stack frame; " -":attr:`f_code` is the code object being executed in this frame; " -":attr:`f_locals` is the dictionary used to look up local variables; " -":attr:`f_globals` is used for global variables; :attr:`f_builtins` is used " -"for built-in (intrinsic) names; :attr:`f_lasti` gives the precise " -"instruction (this is an index into the bytecode string of the code object)." +"(towards the caller), or ``None`` if this is the bottom stack frame; :attr:" +"`f_code` is the code object being executed in this frame; :attr:`f_locals` " +"is the dictionary used to look up local variables; :attr:`f_globals` is used " +"for global variables; :attr:`f_builtins` is used for built-in (intrinsic) " +"names; :attr:`f_lasti` gives the precise instruction (this is an index into " +"the bytecode string of the code object)." msgstr "" "Atributos especiales de solo lectura: :attr:`f_back` es para el marco de " "pila anterior (hacia quien produce el llamado), o ``None`` si éste es el " "marco de pila inferior; :attr:`f_code` es el objeto de código ejecutado en " "este marco; :attr:`f_locals` es el diccionario utilizado para buscar " -"variables locales; :attr:`f_globals` es usado por las variables globales; " -":attr:`f_builtins` es utilizado por nombres incorporados (intrínsecos); " -":attr:`f_lasti` da la instrucción precisa (éste es un índice dentro de la " -"cadena de bytecode del objeto de código)." +"variables locales; :attr:`f_globals` es usado por las variables globales; :" +"attr:`f_builtins` es utilizado por nombres incorporados (intrínsecos); :attr:" +"`f_lasti` da la instrucción precisa (éste es un índice dentro de la cadena " +"de bytecode del objeto de código)." #: ../Doc/reference/datamodel.rst:1183 msgid "" -"Accessing ``f_code`` raises an :ref:`auditing event ` " -"``object.__getattr__`` with arguments ``obj`` and ``\"f_code\"``." +"Accessing ``f_code`` raises an :ref:`auditing event ` ``object." +"__getattr__`` with arguments ``obj`` and ``\"f_code\"``." msgstr "" "Acceder a ``f_code`` lanza un objeto :ref:`evento de auditoría ` " "``.__getattr__`` con argumentos ``obj`` y ``\"f_code\"`` ." #: ../Doc/reference/datamodel.rst:1192 msgid "" -"Special writable attributes: :attr:`f_trace`, if not ``None``, is a function" -" called for various events during code execution (this is used by the " +"Special writable attributes: :attr:`f_trace`, if not ``None``, is a function " +"called for various events during code execution (this is used by the " "debugger). Normally an event is triggered for each new source line - this " "can be disabled by setting :attr:`f_trace_lines` to :const:`False`." msgstr "" -"Atributos especiales escribibles: :attr:`f_trace`, de lo contrario ``None``," -" es una función llamada por distintos eventos durante la ejecución del " -"código (éste es utilizado por el depurador). Normalmente un evento es " -"desencadenado por cada una de las líneas fuente - esto puede ser " -"deshabilitado estableciendo :attr:`f_trace_lines` a :const:`False`." +"Atributos especiales escribibles: :attr:`f_trace`, de lo contrario ``None``, " +"es una función llamada por distintos eventos durante la ejecución del código " +"(éste es utilizado por el depurador). Normalmente un evento es desencadenado " +"por cada una de las líneas fuente - esto puede ser deshabilitado " +"estableciendo :attr:`f_trace_lines` a :const:`False`." #: ../Doc/reference/datamodel.rst:1197 msgid "" -"Implementations *may* allow per-opcode events to be requested by setting " -":attr:`f_trace_opcodes` to :const:`True`. Note that this may lead to " +"Implementations *may* allow per-opcode events to be requested by setting :" +"attr:`f_trace_opcodes` to :const:`True`. Note that this may lead to " "undefined interpreter behaviour if exceptions raised by the trace function " "escape to the function being traced." msgstr "" "Las implementaciones *pueden* permitir que eventos por código de operación " "sean solicitados estableciendo :attr:`f_trace_opcodes` a :const:`True`. " "Tenga en cuenta que esto puede llevar a un comportamiento indefinido del " -"intérprete si se levantan excepciones por la función de rastreo escape hacia" -" la función que está siendo rastreada." +"intérprete si se levantan excepciones por la función de rastreo escape hacia " +"la función que está siendo rastreada." #: ../Doc/reference/datamodel.rst:1202 msgid "" -":attr:`f_lineno` is the current line number of the frame --- writing to this" -" from within a trace function jumps to the given line (only for the bottom-" +":attr:`f_lineno` is the current line number of the frame --- writing to this " +"from within a trace function jumps to the given line (only for the bottom-" "most frame). A debugger can implement a Jump command (aka Set Next " "Statement) by writing to f_lineno." msgstr "" ":attr:`f_lineno` es el número de línea actual del marco --- escribiendo a " -"esta forma dentro de una función de rastreo salta a la línea dada (solo para" -" el último marco). Un depurador puede implementar un comando de salto " +"esta forma dentro de una función de rastreo salta a la línea dada (solo para " +"el último marco). Un depurador puede implementar un comando de salto " "(*Jump*) (también conocido como *Set Next Statement*) al escribir en " "f_lineno." @@ -1974,8 +1962,8 @@ msgid "" msgstr "" "Este método limpia todas las referencias a variables locales mantenidas por " "el marco. También, si el marco pertenecía a un generador, éste es " -"finalizado. Esto ayuda a interrumpir los ciclos de referencia que involucran" -" objetos de marco (por ejemplo al detectar una excepción y almacenando su " +"finalizado. Esto ayuda a interrumpir los ciclos de referencia que involucran " +"objetos de marco (por ejemplo al detectar una excepción y almacenando su " "rastro para uso posterior)." #: ../Doc/reference/datamodel.rst:1217 @@ -1993,8 +1981,8 @@ msgid "" "explicitly created by calling :class:`types.TracebackType`." msgstr "" "Los objetos de seguimiento de pila representan el trazo de pila (*stack " -"trace*) de una excepción. Un objeto de rastreo es creado de manera implícita" -" cuando se da una excepción, y puede ser creada de manera explícita al " +"trace*) de una excepción. Un objeto de rastreo es creado de manera implícita " +"cuando se da una excepción, y puede ser creada de manera explícita al " "llamar :class:`types.TracebackType`." #: ../Doc/reference/datamodel.rst:1242 @@ -2002,26 +1990,23 @@ msgid "" "For implicitly created tracebacks, when the search for an exception handler " "unwinds the execution stack, at each unwound level a traceback object is " "inserted in front of the current traceback. When an exception handler is " -"entered, the stack trace is made available to the program. (See section " -":ref:`try`.) It is accessible as the third item of the tuple returned by " -"``sys.exc_info()``, and as the ``__traceback__`` attribute of the caught " -"exception." +"entered, the stack trace is made available to the program. (See section :ref:" +"`try`.) It is accessible as the third item of the tuple returned by ``sys." +"exc_info()``, and as the ``__traceback__`` attribute of the caught exception." msgstr "" "Para seguimientos de pila (tracebacks) creados de manera implícita, cuando " "la búsqueda por un manejo de excepciones desenvuelve la pila de ejecución, " "en cada nivel de desenvolvimiento se inserta un objeto de rastreo al frente " "del rastreo actual. Cuando se entra a un manejo de excepción, la pila de " "rastreo se vuelve disponible para el programa. (Ver sección :ref:`try`.) Es " -"accesible como el tercer elemento de la tupla retornada por " -"``sys.exc_info()``, y como el atributo ``__traceback__`` de la excepción " -"capturada." +"accesible como el tercer elemento de la tupla retornada por ``sys." +"exc_info()``, y como el atributo ``__traceback__`` de la excepción capturada." #: ../Doc/reference/datamodel.rst:1250 msgid "" "When the program contains no suitable handler, the stack trace is written " "(nicely formatted) to the standard error stream; if the interpreter is " -"interactive, it is also made available to the user as " -"``sys.last_traceback``." +"interactive, it is also made available to the user as ``sys.last_traceback``." msgstr "" "Cuando el programa no contiene un gestor apropiado, el trazo de pila es " "escrito (muy bien formateado) a la secuencia de error estándar; si el " @@ -2040,8 +2025,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1265 msgid "" -"Special read-only attributes: :attr:`tb_frame` points to the execution frame" -" of the current level; :attr:`tb_lineno` gives the line number where the " +"Special read-only attributes: :attr:`tb_frame` points to the execution frame " +"of the current level; :attr:`tb_lineno` gives the line number where the " "exception occurred; :attr:`tb_lasti` indicates the precise instruction. The " "line number and last instruction in the traceback may differ from the line " "number of its frame object if the exception occurred in a :keyword:`try` " @@ -2051,23 +2036,23 @@ msgstr "" "ejecución del nivel actual; :attr:`tb_lineno` da el número de línea donde " "ocurrió la excepción; :attr:`tb_lasti` indica la instrucción precisa. El " "número de línea y la última instrucción en el seguimiento de pila puede " -"diferir del número de línea de su objeto de marco si la excepción ocurrió en" -" una declaración :keyword:`try` sin una cláusula de excepción (except) " +"diferir del número de línea de su objeto de marco si la excepción ocurrió en " +"una declaración :keyword:`try` sin una cláusula de excepción (except) " "correspondiente o con una cláusula *finally*." #: ../Doc/reference/datamodel.rst:1274 msgid "" -"Accessing ``tb_frame`` raises an :ref:`auditing event ` " -"``object.__getattr__`` with arguments ``obj`` and ``\"tb_frame\"``." +"Accessing ``tb_frame`` raises an :ref:`auditing event ` ``object." +"__getattr__`` with arguments ``obj`` and ``\"tb_frame\"``." msgstr "" -"Acceder a ``tb_frame`` lanza un objeto :ref:`evento de auditoría `" -" ``.__getattr__`` con argumentos ``obj`` y ``tb_frame``." +"Acceder a ``tb_frame`` lanza un objeto :ref:`evento de auditoría ` " +"``.__getattr__`` con argumentos ``obj`` y ``tb_frame``." #: ../Doc/reference/datamodel.rst:1280 msgid "" "Special writable attribute: :attr:`tb_next` is the next level in the stack " -"trace (towards the frame where the exception occurred), or ``None`` if there" -" is no next level." +"trace (towards the frame where the exception occurred), or ``None`` if there " +"is no next level." msgstr "" "Atributo especial escribible: :attr:`tb_next` es el siguiente nivel en el " "trazo de pila (hacia el marco en donde ocurrió la excepción), o ``None`` si " @@ -2091,20 +2076,20 @@ msgid "" "Slice objects are used to represent slices for :meth:`~object.__getitem__` " "methods. They are also created by the built-in :func:`slice` function." msgstr "" -"Los objetos de sector se utilizan para representar sectores para métodos " -":meth:`~object.__getitem__`. También son creados por la función integrada " -":func:`slice`." +"Los objetos de sector se utilizan para representar sectores para métodos :" +"meth:`~object.__getitem__`. También son creados por la función integrada :" +"func:`slice`." #: ../Doc/reference/datamodel.rst:1303 msgid "" -"Special read-only attributes: :attr:`~slice.start` is the lower bound; " -":attr:`~slice.stop` is the upper bound; :attr:`~slice.step` is the step " -"value; each is ``None`` if omitted. These attributes can have any type." +"Special read-only attributes: :attr:`~slice.start` is the lower bound; :attr:" +"`~slice.stop` is the upper bound; :attr:`~slice.step` is the step value; " +"each is ``None`` if omitted. These attributes can have any type." msgstr "" "Atributos especiales de solo lectura: :attr:`~slice.start` es el límite " "inferior; :attr:`~slice.stop` es el límite superior; :attr:`~slice.step` es " -"el valor de paso; cada uno es ``None`` si es omitido. Estos atributos pueden" -" ser de cualquier tipo." +"el valor de paso; cada uno es ``None`` si es omitido. Estos atributos pueden " +"ser de cualquier tipo." #: ../Doc/reference/datamodel.rst:1307 msgid "Slice objects support one method:" @@ -2140,15 +2125,15 @@ msgid "" "any further transformation. Static method objects are also callable. Static " "method objects are created by the built-in :func:`staticmethod` constructor." msgstr "" -"Los objetos de método estático proveen una forma de anular la transformación" -" de objetos de función a objetos de método descritos anteriormente. Un " -"objeto de método estático es una envoltura (*wrapper*) alrededor de " -"cualquier otro objeto, usualmente un objeto de método definido por usuario. " -"Cuando un objeto de método estático es obtenido desde una clase o una " -"instancia de clase, usualmente el objeto retornado es el objeto envuelto, el" -" cual no está objeto a ninguna transformación adicional. Los objetos de " -"método estático también pueden ser llamados. Los objetos de método estático " -"son creados por el constructor incorporado :func:`staticmethod`." +"Los objetos de método estático proveen una forma de anular la transformación " +"de objetos de función a objetos de método descritos anteriormente. Un objeto " +"de método estático es una envoltura (*wrapper*) alrededor de cualquier otro " +"objeto, usualmente un objeto de método definido por usuario. Cuando un " +"objeto de método estático es obtenido desde una clase o una instancia de " +"clase, usualmente el objeto retornado es el objeto envuelto, el cual no está " +"objeto a ninguna transformación adicional. Los objetos de método estático " +"también pueden ser llamados. Los objetos de método estático son creados por " +"el constructor incorporado :func:`staticmethod`." #: ../Doc/reference/datamodel.rst:1332 msgid "Class method objects" @@ -2158,8 +2143,8 @@ msgstr "Objetos de método de clase" msgid "" "A class method object, like a static method object, is a wrapper around " "another object that alters the way in which that object is retrieved from " -"classes and class instances. The behaviour of class method objects upon such" -" retrieval is described above, under \"User-defined methods\". Class method " +"classes and class instances. The behaviour of class method objects upon such " +"retrieval is described above, under \"User-defined methods\". Class method " "objects are created by the built-in :func:`classmethod` constructor." msgstr "" "Un objeto de método de clase, igual que un objeto de método estático, es un " @@ -2167,8 +2152,8 @@ msgstr "" "el objeto es obtenido desde las clases y las instancias de clase. El " "comportamiento de los objetos de método de clase sobre tal obtención es " "descrita más arriba, debajo de “Métodos definidos por usuario”. Objetos de " -"clase de método son creados por el constructor incorporado " -":func:`classmethod`." +"clase de método son creados por el constructor incorporado :func:" +"`classmethod`." #: ../Doc/reference/datamodel.rst:1344 msgid "Special method names" @@ -2180,47 +2165,47 @@ msgid "" "(such as arithmetic operations or subscripting and slicing) by defining " "methods with special names. This is Python's approach to :dfn:`operator " "overloading`, allowing classes to define their own behavior with respect to " -"language operators. For instance, if a class defines a method named " -":meth:`~object.__getitem__`, and ``x`` is an instance of this class, then " -"``x[i]`` is roughly equivalent to ``type(x).__getitem__(x, i)``. Except " -"where mentioned, attempts to execute an operation raise an exception when no" -" appropriate method is defined (typically :exc:`AttributeError` or " -":exc:`TypeError`)." +"language operators. For instance, if a class defines a method named :meth:" +"`~object.__getitem__`, and ``x`` is an instance of this class, then ``x[i]`` " +"is roughly equivalent to ``type(x).__getitem__(x, i)``. Except where " +"mentioned, attempts to execute an operation raise an exception when no " +"appropriate method is defined (typically :exc:`AttributeError` or :exc:" +"`TypeError`)." msgstr "" "Una clase puede implementar ciertas operaciones que se invocan mediante una " "sintaxis especial (como operaciones aritméticas o subíndices y divisiones) " -"definiendo métodos con nombres especiales. Este es el enfoque de Python para" -" :dfn:`sobrecarga de operadores`, permitiendo a las clases definir su propio" -" comportamiento con respecto a los operadores del lenguaje. Por ejemplo, si " -"una clase define un método denominado :meth:`~object.__getitem__` y ``x`` es" -" una instancia de esta clase, entonces ``x[i]`` es aproximadamente " -"equivalente a ``type(x).__getitem__(x, i)``. Excepto donde se mencione, los " -"intentos de ejecutar una operación generan una excepción cuando no se define" -" ningún método apropiado (normalmente :exc:`AttributeError` o " -":exc:`TypeError`)." +"definiendo métodos con nombres especiales. Este es el enfoque de Python " +"para :dfn:`sobrecarga de operadores`, permitiendo a las clases definir su " +"propio comportamiento con respecto a los operadores del lenguaje. Por " +"ejemplo, si una clase define un método denominado :meth:`~object." +"__getitem__` y ``x`` es una instancia de esta clase, entonces ``x[i]`` es " +"aproximadamente equivalente a ``type(x).__getitem__(x, i)``. Excepto donde " +"se mencione, los intentos de ejecutar una operación generan una excepción " +"cuando no se define ningún método apropiado (normalmente :exc:" +"`AttributeError` o :exc:`TypeError`)." #: ../Doc/reference/datamodel.rst:1361 msgid "" "Setting a special method to ``None`` indicates that the corresponding " -"operation is not available. For example, if a class sets " -":meth:`~object.__iter__` to ``None``, the class is not iterable, so calling " -":func:`iter` on its instances will raise a :exc:`TypeError` (without falling" -" back to :meth:`~object.__getitem__`). [#]_" +"operation is not available. For example, if a class sets :meth:`~object." +"__iter__` to ``None``, the class is not iterable, so calling :func:`iter` on " +"its instances will raise a :exc:`TypeError` (without falling back to :meth:" +"`~object.__getitem__`). [#]_" msgstr "" "Establecer un método especial en ``None`` indica que la operación " -"correspondiente no está disponible. Por ejemplo, si una clase establece " -":meth:`~object.__iter__` en ``None``, la clase no es iterable, por lo que " +"correspondiente no está disponible. Por ejemplo, si una clase establece :" +"meth:`~object.__iter__` en ``None``, la clase no es iterable, por lo que " "llamar a :func:`iter` en sus instancias generará un :exc:`TypeError` (sin " "recurrir a :meth:`~object.__getitem__`). [#]_" #: ../Doc/reference/datamodel.rst:1367 msgid "" "When implementing a class that emulates any built-in type, it is important " -"that the emulation only be implemented to the degree that it makes sense for" -" the object being modelled. For example, some sequences may work well with " -"retrieval of individual elements, but extracting a slice may not make sense." -" (One example of this is the :class:`~xml.dom.NodeList` interface in the " -"W3C's Document Object Model.)" +"that the emulation only be implemented to the degree that it makes sense for " +"the object being modelled. For example, some sequences may work well with " +"retrieval of individual elements, but extracting a slice may not make " +"sense. (One example of this is the :class:`~xml.dom.NodeList` interface in " +"the W3C's Document Object Model.)" msgstr "" "Cuando se implementa una clase que emula cualquier tipo incorporado, es " "importante que la emulación solo sea implementado al grado que hace sentido " @@ -2236,15 +2221,15 @@ msgstr "Personalización básica" #: ../Doc/reference/datamodel.rst:1384 msgid "" -"Called to create a new instance of class *cls*. :meth:`__new__` is a static" -" method (special-cased so you need not declare it as such) that takes the " +"Called to create a new instance of class *cls*. :meth:`__new__` is a static " +"method (special-cased so you need not declare it as such) that takes the " "class of which an instance was requested as its first argument. The " "remaining arguments are those passed to the object constructor expression " "(the call to the class). The return value of :meth:`__new__` should be the " "new object instance (usually an instance of *cls*)." msgstr "" -"Es llamado para crear una nueva instancia de clase *cls*. :meth:`__new__` es" -" un método estático (como un caso especial, así que no se necesita declarar " +"Es llamado para crear una nueva instancia de clase *cls*. :meth:`__new__` es " +"un método estático (como un caso especial, así que no se necesita declarar " "como tal) que toma la clase de donde fue solicitada una instancia como su " "primer argumento. Los argumentos restantes son aquellos que se pasan a la " "expresión del constructor de objetos (para llamar a la clase). El valor " @@ -2258,24 +2243,24 @@ msgid "" "with appropriate arguments and then modifying the newly created instance as " "necessary before returning it." msgstr "" -"Las implementaciones típicas crean una nueva instancia de la clase invocando" -" el método :meth:`__new__` de la superclase usando ``super().__new__(cls[, " -"...])`` con los argumentos apropiados y luego modificando la instancia " -"recién creada según sea necesario antes de retornarla." +"Las implementaciones típicas crean una nueva instancia de la clase invocando " +"el método :meth:`__new__` de la superclase usando ``super()." +"__new__(cls[, ...])`` con los argumentos apropiados y luego modificando la " +"instancia recién creada según sea necesario antes de retornarla." #: ../Doc/reference/datamodel.rst:1396 msgid "" "If :meth:`__new__` is invoked during object construction and it returns an " "instance of *cls*, then the new instance’s :meth:`__init__` method will be " -"invoked like ``__init__(self[, ...])``, where *self* is the new instance and" -" the remaining arguments are the same as were passed to the object " +"invoked like ``__init__(self[, ...])``, where *self* is the new instance and " +"the remaining arguments are the same as were passed to the object " "constructor." msgstr "" "Si :meth:`__new__` es invocado durante la construcción del objeto y éste " -"retorna una instancia de *cls*, entonces el nuevo método :meth:`__init__` de" -" la instancia será invocado como ``__init__(self[, …])``, donde *self* es la" -" nueva instancia y los argumentos restantes son iguales a como fueron " -"pasados hacia el constructor de objetos." +"retorna una instancia de *cls*, entonces el nuevo método :meth:`__init__` de " +"la instancia será invocado como ``__init__(self[, …])``, donde *self* es la " +"nueva instancia y los argumentos restantes son iguales a como fueron pasados " +"hacia el constructor de objetos." #: ../Doc/reference/datamodel.rst:1401 msgid "" @@ -2301,9 +2286,9 @@ msgstr "" msgid "" "Called after the instance has been created (by :meth:`__new__`), but before " "it is returned to the caller. The arguments are those passed to the class " -"constructor expression. If a base class has an :meth:`__init__` method, the" -" derived class's :meth:`__init__` method, if any, must explicitly call it to" -" ensure proper initialization of the base class part of the instance; for " +"constructor expression. If a base class has an :meth:`__init__` method, the " +"derived class's :meth:`__init__` method, if any, must explicitly call it to " +"ensure proper initialization of the base class part of the instance; for " "example: ``super().__init__([args...])``." msgstr "" "Llamado después de que la instancia ha sido creada (por :meth:`__new__`), " @@ -2321,23 +2306,23 @@ msgid "" "it), no non-``None`` value may be returned by :meth:`__init__`; doing so " "will cause a :exc:`TypeError` to be raised at runtime." msgstr "" -"Debido a que :meth:`__new__` y :meth:`__init__` trabajan juntos construyendo" -" objetos (:meth:`__new__` para crearlo y :meth:`__init__` para " -"personalizarlo), ningún valor distinto a ``None`` puede ser retornado por " -":meth:`__init__`; hacer esto puede causar que se lance una excepción " -":exc:`TypeError` en tiempo de ejecución." +"Debido a que :meth:`__new__` y :meth:`__init__` trabajan juntos construyendo " +"objetos (:meth:`__new__` para crearlo y :meth:`__init__` para " +"personalizarlo), ningún valor distinto a ``None`` puede ser retornado por :" +"meth:`__init__`; hacer esto puede causar que se lance una excepción :exc:" +"`TypeError` en tiempo de ejecución." #: ../Doc/reference/datamodel.rst:1433 msgid "" "Called when the instance is about to be destroyed. This is also called a " -"finalizer or (improperly) a destructor. If a base class has a " -":meth:`__del__` method, the derived class's :meth:`__del__` method, if any, " -"must explicitly call it to ensure proper deletion of the base class part of " -"the instance." +"finalizer or (improperly) a destructor. If a base class has a :meth:" +"`__del__` method, the derived class's :meth:`__del__` method, if any, must " +"explicitly call it to ensure proper deletion of the base class part of the " +"instance." msgstr "" "Llamado cuando la instancia es a punto de ser destruida. Esto también es " -"llamado finalizador o (indebidamente) destructor. Si una clase base tiene un" -" método :meth:`__del__` el método :meth:`__del__` de la clase derivada, de " +"llamado finalizador o (indebidamente) destructor. Si una clase base tiene un " +"método :meth:`__del__` el método :meth:`__del__` de la clase derivada, de " "existir, debe llamarlo explícitamente para asegurar la eliminación adecuada " "de la parte de la clase base de la instancia." @@ -2346,9 +2331,9 @@ msgid "" "It is possible (though not recommended!) for the :meth:`__del__` method to " "postpone destruction of the instance by creating a new reference to it. " "This is called object *resurrection*. It is implementation-dependent " -"whether :meth:`__del__` is called a second time when a resurrected object is" -" about to be destroyed; the current :term:`CPython` implementation only " -"calls it once." +"whether :meth:`__del__` is called a second time when a resurrected object is " +"about to be destroyed; the current :term:`CPython` implementation only calls " +"it once." msgstr "" "Es posible (¡aunque no recomendable!) para el método :meth:`__del__` " "posponer la destrucción de la instancia al crear una nueva referencia hacia " @@ -2379,14 +2364,14 @@ msgstr "" msgid "" "It is possible for a reference cycle to prevent the reference count of an " "object from going to zero. In this case, the cycle will be later detected " -"and deleted by the :term:`cyclic garbage collector `. A" -" common cause of reference cycles is when an exception has been caught in a " +"and deleted by the :term:`cyclic garbage collector `. A " +"common cause of reference cycles is when an exception has been caught in a " "local variable. The frame's locals then reference the exception, which " "references its own traceback, which references the locals of all frames " "caught in the traceback." msgstr "" -"Es posible que un ciclo de referencia evite que el recuento de referencia de" -" un objeto llegue a cero. En este caso, el ciclo será posteriormente " +"Es posible que un ciclo de referencia evite que el recuento de referencia de " +"un objeto llegue a cero. En este caso, el ciclo será posteriormente " "detectado y eliminado por el :term:`cyclic garbage collector `. Una causa común de los ciclos de referencia es cuando se " "detecta una excepción en una variable local. Luego, los locales del marco " @@ -2404,40 +2389,40 @@ msgid "" "invoked, exceptions that occur during their execution are ignored, and a " "warning is printed to ``sys.stderr`` instead. In particular:" msgstr "" -"Debido a las circunstancias inciertas bajo las que los métodos " -":meth:`__del__` son invocados, las excepciones que ocurren durante su " -"ejecución son ignoradas, y una advertencia es mostrada hacia ``sys.stderr``." -" En particular:" +"Debido a las circunstancias inciertas bajo las que los métodos :meth:" +"`__del__` son invocados, las excepciones que ocurren durante su ejecución " +"son ignoradas, y una advertencia es mostrada hacia ``sys.stderr``. En " +"particular:" #: ../Doc/reference/datamodel.rst:1474 msgid "" ":meth:`__del__` can be invoked when arbitrary code is being executed, " "including from any arbitrary thread. If :meth:`__del__` needs to take a " "lock or invoke any other blocking resource, it may deadlock as the resource " -"may already be taken by the code that gets interrupted to execute " -":meth:`__del__`." +"may already be taken by the code that gets interrupted to execute :meth:" +"`__del__`." msgstr "" ":meth:`__del__` puede ser invocado cuando código arbitrario es ejecutado, " "incluyendo el de cualquier hilo arbitrario. Si :meth:`__del__` necesita " "realizar un cierre de exclusión mutua (*lock*) o invocar cualquier otro " -"recurso que lo esté bloqueando, podría provocar un bloqueo muto (*deadlock*)" -" ya que el recurso podría estar siendo utilizado por el código que se " +"recurso que lo esté bloqueando, podría provocar un bloqueo muto (*deadlock*) " +"ya que el recurso podría estar siendo utilizado por el código que se " "interrumpe al ejecutar :meth:`__del__`." #: ../Doc/reference/datamodel.rst:1480 msgid "" ":meth:`__del__` can be executed during interpreter shutdown. As a " "consequence, the global variables it needs to access (including other " -"modules) may already have been deleted or set to ``None``. Python guarantees" -" that globals whose name begins with a single underscore are deleted from " +"modules) may already have been deleted or set to ``None``. Python guarantees " +"that globals whose name begins with a single underscore are deleted from " "their module before other globals are deleted; if no other references to " "such globals exist, this may help in assuring that imported modules are " "still available at the time when the :meth:`__del__` method is called." msgstr "" ":meth:`__del__` puede ser ejecutado durante el cierre del intérprete. Como " "consecuencia, las variables globales que necesita para acceder (incluyendo " -"otros módulos) podrían haber sido borradas o establecidas a ``None``. Python" -" garantiza que los globales cuyo nombre comienza con un guión bajo simple " +"otros módulos) podrían haber sido borradas o establecidas a ``None``. Python " +"garantiza que los globales cuyo nombre comienza con un guión bajo simple " "sean borrados de su módulo antes que los globales sean borrados; si no " "existen otras referencias a dichas globales, esto puede ayudar asegurando " "que los módulos importados aún se encuentren disponibles al momento de " @@ -2447,19 +2432,18 @@ msgstr "" msgid "" "Called by the :func:`repr` built-in function to compute the \"official\" " "string representation of an object. If at all possible, this should look " -"like a valid Python expression that could be used to recreate an object with" -" the same value (given an appropriate environment). If this is not " -"possible, a string of the form ``<...some useful description...>`` should be" -" returned. The return value must be a string object. If a class defines " -":meth:`__repr__` but not :meth:`__str__`, then :meth:`__repr__` is also used" -" when an \"informal\" string representation of instances of that class is " -"required." +"like a valid Python expression that could be used to recreate an object with " +"the same value (given an appropriate environment). If this is not possible, " +"a string of the form ``<...some useful description...>`` should be returned. " +"The return value must be a string object. If a class defines :meth:" +"`__repr__` but not :meth:`__str__`, then :meth:`__repr__` is also used when " +"an \"informal\" string representation of instances of that class is required." msgstr "" "Llamado por la función incorporada :func:`repr` para calcular la cadena " "“oficial” de representación de un objeto. Si es posible, esto debería verse " "como una expresión de Python válida que puede ser utilizada para recrear un " -"objeto con el mismo valor (bajo el ambiente adecuado). Si no es posible, una" -" cadena con la forma ``<…some useful description…>`` debe ser retornada. El " +"objeto con el mismo valor (bajo el ambiente adecuado). Si no es posible, una " +"cadena con la forma ``<…some useful description…>`` debe ser retornada. El " "valor de retorno debe ser un objeto de cadena (*string*). Si una clase " "define :meth:`__repr__` pero no :meth:`__str__`, entonces :meth:`__repr__` " "también es utilizado cuando una cadena “informal” de representación de " @@ -2475,15 +2459,15 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1515 msgid "" -"Called by :func:`str(object) ` and the built-in functions " -":func:`format` and :func:`print` to compute the \"informal\" or nicely " -"printable string representation of an object. The return value must be a " -":ref:`string ` object." +"Called by :func:`str(object) ` and the built-in functions :func:" +"`format` and :func:`print` to compute the \"informal\" or nicely printable " +"string representation of an object. The return value must be a :ref:`string " +"` object." msgstr "" -"Llamado por :func:`str(object) ` y las funciones incorporadas " -":func:`format` y :func:`print` para calcular la “informal” o bien mostrada " -"cadena de representación de un objeto. El valor de retorno debe ser un " -"objeto :ref:`string `." +"Llamado por :func:`str(object) ` y las funciones incorporadas :func:" +"`format` y :func:`print` para calcular la “informal” o bien mostrada cadena " +"de representación de un objeto. El valor de retorno debe ser un objeto :ref:" +"`string `." #: ../Doc/reference/datamodel.rst:1520 msgid "" @@ -2491,8 +2475,8 @@ msgid "" "expectation that :meth:`__str__` return a valid Python expression: a more " "convenient or concise representation can be used." msgstr "" -"Este método difiere de :meth:`object.__repr__` en que no hay expectativas de" -" que :meth:`__str__` retorne una expresión de Python válida: una " +"Este método difiere de :meth:`object.__repr__` en que no hay expectativas de " +"que :meth:`__str__` retorne una expresión de Python válida: una " "representación más conveniente o concisa pueda ser utilizada." #: ../Doc/reference/datamodel.rst:1524 @@ -2500,8 +2484,8 @@ msgid "" "The default implementation defined by the built-in type :class:`object` " "calls :meth:`object.__repr__`." msgstr "" -"La implementación por defecto definida por el tipo incorporado " -":class:`object` llama a :meth:`object.__repr__`." +"La implementación por defecto definida por el tipo incorporado :class:" +"`object` llama a :meth:`object.__repr__`." #: ../Doc/reference/datamodel.rst:1534 msgid "" @@ -2513,24 +2497,23 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1545 msgid "" -"Called by the :func:`format` built-in function, and by extension, evaluation" -" of :ref:`formatted string literals ` and the :meth:`str.format` " +"Called by the :func:`format` built-in function, and by extension, evaluation " +"of :ref:`formatted string literals ` and the :meth:`str.format` " "method, to produce a \"formatted\" string representation of an object. The " "*format_spec* argument is a string that contains a description of the " -"formatting options desired. The interpretation of the *format_spec* argument" -" is up to the type implementing :meth:`__format__`, however most classes " -"will either delegate formatting to one of the built-in types, or use a " -"similar formatting option syntax." +"formatting options desired. The interpretation of the *format_spec* argument " +"is up to the type implementing :meth:`__format__`, however most classes will " +"either delegate formatting to one of the built-in types, or use a similar " +"formatting option syntax." msgstr "" "Llamado por la función incorporada :func:`format`, y por extensión, la " -"evaluación de :ref:`formatted string literals ` y el método " -":meth:`str.format`, para producir la representación “formateada” de un " -"objeto. El argumento *format_spec* es una cadena que contiene una " -"descripción de las opciones de formato deseadas. La interpretación del " -"argumento *format_spec* depende del tipo que implementa :meth:`__format__`, " -"sin embargo, ya sea que la mayoría de las clases deleguen el formato a uno " -"de los tipos incorporados, o utilicen una sintaxis de opción de formato " -"similar." +"evaluación de :ref:`formatted string literals ` y el método :meth:" +"`str.format`, para producir la representación “formateada” de un objeto. El " +"argumento *format_spec* es una cadena que contiene una descripción de las " +"opciones de formato deseadas. La interpretación del argumento *format_spec* " +"depende del tipo que implementa :meth:`__format__`, sin embargo, ya sea que " +"la mayoría de las clases deleguen el formato a uno de los tipos " +"incorporados, o utilicen una sintaxis de opción de formato similar." #: ../Doc/reference/datamodel.rst:1555 msgid "" @@ -2548,8 +2531,8 @@ msgid "" "The __format__ method of ``object`` itself raises a :exc:`TypeError` if " "passed any non-empty string." msgstr "" -"El método __format__ del mismo ``object`` lanza un :exc:`TypeError` si se la" -" pasa una cadena no vacía." +"El método __format__ del mismo ``object`` lanza un :exc:`TypeError` si se la " +"pasa una cadena no vacía." #: ../Doc/reference/datamodel.rst:1563 msgid "" @@ -2562,10 +2545,10 @@ msgstr "" #: ../Doc/reference/datamodel.rst:1579 msgid "" "These are the so-called \"rich comparison\" methods. The correspondence " -"between operator symbols and method names is as follows: ``xy`` calls " -"``x.__gt__(y)``, and ``x>=y`` calls ``x.__ge__(y)``." +"between operator symbols and method names is as follows: ``xy`` calls ``x.__gt__(y)``, and ``x>=y`` " +"calls ``x.__ge__(y)``." msgstr "" "Estos son los llamados métodos de comparación *rich*. La correspondencia " "entre símbolos de operador y los nombres de método es de la siguiente " @@ -2577,8 +2560,8 @@ msgstr "" msgid "" "A rich comparison method may return the singleton ``NotImplemented`` if it " "does not implement the operation for a given pair of arguments. By " -"convention, ``False`` and ``True`` are returned for a successful comparison." -" However, these methods can return any value, so if the comparison operator " +"convention, ``False`` and ``True`` are returned for a successful comparison. " +"However, these methods can return any value, so if the comparison operator " "is used in a Boolean context (e.g., in the condition of an ``if`` " "statement), Python will call :func:`bool` on the value to determine if the " "result is true or false." @@ -2586,8 +2569,8 @@ msgstr "" "Un método de comparación *rich* puede retornar el único ``NotImplemented`` " "si no implementa la operación para un par de argumentos dados. Por " "convención, ``False`` y ``True`` son retornados para una comparación " -"exitosa. Sin embargo, estos métodos pueden retornar cualquier valor, así que" -" si el operador de comparación es utilizado en un contexto Booleano (p. ej. " +"exitosa. Sin embargo, estos métodos pueden retornar cualquier valor, así que " +"si el operador de comparación es utilizado en un contexto Booleano (p. ej. " "en la condición de una sentencia ``if``), Python llamará :func:`bool` en " "dicho valor para determinar si el resultado es verdadero (*true*) o falso " "(*false*)." @@ -2596,139 +2579,139 @@ msgstr "" msgid "" "By default, ``object`` implements :meth:`__eq__` by using ``is``, returning " "``NotImplemented`` in the case of a false comparison: ``True if x is y else " -"NotImplemented``. For :meth:`__ne__`, by default it delegates to " -":meth:`__eq__` and inverts the result unless it is ``NotImplemented``. " -"There are no other implied relationships among the comparison operators or " -"default implementations; for example, the truth of ``(x` for each variable name. As a result, class attributes " -"cannot be used to set default values for instance variables defined by " -"*__slots__*; otherwise, the class attribute would overwrite the descriptor " -"assignment." +"*__slots__* are implemented at the class level by creating :ref:`descriptors " +"` for each variable name. As a result, class attributes cannot " +"be used to set default values for instance variables defined by *__slots__*; " +"otherwise, the class attribute would overwrite the descriptor assignment." msgstr "" "*__slots__* se implementa a nivel de clase creando :ref:`descriptors " "` para cada nombre de variable. Como resultado, los atributos " @@ -3420,18 +3395,17 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2054 msgid "" -"The action of a *__slots__* declaration is not limited to the class where it" -" is defined. *__slots__* declared in parents are available in child " -"classes. However, child subclasses will get a :attr:`~object.__dict__` and " -"*__weakref__* unless they also define *__slots__* (which should only contain" -" names of any *additional* slots)." +"The action of a *__slots__* declaration is not limited to the class where it " +"is defined. *__slots__* declared in parents are available in child classes. " +"However, child subclasses will get a :attr:`~object.__dict__` and " +"*__weakref__* unless they also define *__slots__* (which should only contain " +"names of any *additional* slots)." msgstr "" "La acción de una declaración *__slots__* no se limita a la clase donde se " "define. *__slots__* declarado en padres está disponible en clases " -"secundarias. Sin embargo, las subclases secundarias obtendrán " -":attr:`~object.__dict__` y *__weakref__* a menos que también definan " -"*__slots__* (que solo debe contener nombres de cualquier ranura " -"*additional*)." +"secundarias. Sin embargo, las subclases secundarias obtendrán :attr:`~object." +"__dict__` y *__weakref__* a menos que también definan *__slots__* (que solo " +"debe contener nombres de cualquier ranura *additional*)." #: ../Doc/reference/datamodel.rst:2060 msgid "" @@ -3451,13 +3425,13 @@ msgstr "" msgid "" ":exc:`TypeError` will be raised if nonempty *__slots__* are defined for a " "class derived from a :c:member:`\"variable-length\" built-in type " -"` such as :class:`int`, :class:`bytes`, and " -":class:`tuple`." +"` such as :class:`int`, :class:`bytes`, and :class:" +"`tuple`." msgstr "" ":exc:`TypeError` se generará si se definen *__slots__* no vacíos para una " "clase derivada de un :c:member:`\"variable-length\" built-in type " -"` como :class:`int`, :class:`bytes` y " -":class:`tuple`." +"` como :class:`int`, :class:`bytes` y :class:" +"`tuple`." #: ../Doc/reference/datamodel.rst:2070 msgid "Any non-string :term:`iterable` may be assigned to *__slots__*." @@ -3468,15 +3442,15 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2072 msgid "" "If a :class:`dictionary ` is used to assign *__slots__*, the " -"dictionary keys will be used as the slot names. The values of the dictionary" -" can be used to provide per-attribute docstrings that will be recognised by " -":func:`inspect.getdoc` and displayed in the output of :func:`help`." +"dictionary keys will be used as the slot names. The values of the dictionary " +"can be used to provide per-attribute docstrings that will be recognised by :" +"func:`inspect.getdoc` and displayed in the output of :func:`help`." msgstr "" "Si se utiliza un :class:`dictionary ` para asignar *__slots__*, las " -"claves del diccionario se utilizarán como nombres de ranura. Los valores del" -" diccionario se pueden usar para proporcionar cadenas de documentos por " -"atributo que :func:`inspect.getdoc` reconocerá y mostrará en la salida de " -":func:`help`." +"claves del diccionario se utilizarán como nombres de ranura. Los valores del " +"diccionario se pueden usar para proporcionar cadenas de documentos por " +"atributo que :func:`inspect.getdoc` reconocerá y mostrará en la salida de :" +"func:`help`." #: ../Doc/reference/datamodel.rst:2077 msgid "" @@ -3490,8 +3464,8 @@ msgstr "" msgid "" ":ref:`Multiple inheritance ` with multiple slotted parent " "classes can be used, but only one parent is allowed to have attributes " -"created by slots (the other bases must have empty slot layouts) - violations" -" raise :exc:`TypeError`." +"created by slots (the other bases must have empty slot layouts) - violations " +"raise :exc:`TypeError`." msgstr "" "Se puede usar :ref:`Multiple inheritance ` con varias clases " "principales con ranuras, pero solo a una de las clases principales se le " @@ -3504,9 +3478,9 @@ msgid "" "created for each of the iterator's values. However, the *__slots__* " "attribute will be an empty iterator." msgstr "" -"Si se utiliza un :term:`iterator` para *__slots__*, entonces se crea un " -":term:`descriptor` para cada uno de los valores del iterador. Sin embargo, " -"el atributo *__slots__* será un iterador vacío." +"Si se utiliza un :term:`iterator` para *__slots__*, entonces se crea un :" +"term:`descriptor` para cada uno de los valores del iterador. Sin embargo, el " +"atributo *__slots__* será un iterador vacío." #: ../Doc/reference/datamodel.rst:2094 msgid "Customizing class creation" @@ -3514,20 +3488,20 @@ msgstr "Personalización de creación de clases" #: ../Doc/reference/datamodel.rst:2096 msgid "" -"Whenever a class inherits from another class, " -":meth:`~object.__init_subclass__` is called on the parent class. This way, " -"it is possible to write classes which change the behavior of subclasses. " -"This is closely related to class decorators, but where class decorators only" -" affect the specific class they're applied to, ``__init_subclass__`` solely " -"applies to future subclasses of the class defining the method." -msgstr "" -"Siempre que una clase hereda de otra clase, se llama a " -":meth:`~object.__init_subclass__` en la clase principal. De esta forma, es " -"posible escribir clases que cambien el comportamiento de las subclases. Esto" -" está estrechamente relacionado con los decoradores de clases, pero mientras" -" los decoradores de clases solo afectan la clase específica a la que se " -"aplican, ``__init_subclass__`` solo se aplica a futuras subclases de la " -"clase que define el método." +"Whenever a class inherits from another class, :meth:`~object." +"__init_subclass__` is called on the parent class. This way, it is possible " +"to write classes which change the behavior of subclasses. This is closely " +"related to class decorators, but where class decorators only affect the " +"specific class they're applied to, ``__init_subclass__`` solely applies to " +"future subclasses of the class defining the method." +msgstr "" +"Siempre que una clase hereda de otra clase, se llama a :meth:`~object." +"__init_subclass__` en la clase principal. De esta forma, es posible escribir " +"clases que cambien el comportamiento de las subclases. Esto está " +"estrechamente relacionado con los decoradores de clases, pero mientras los " +"decoradores de clases solo afectan la clase específica a la que se aplican, " +"``__init_subclass__`` solo se aplica a futuras subclases de la clase que " +"define el método." #: ../Doc/reference/datamodel.rst:2105 msgid "" @@ -3564,8 +3538,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2128 msgid "" "The metaclass hint ``metaclass`` is consumed by the rest of the type " -"machinery, and is never passed to ``__init_subclass__`` implementations. The" -" actual metaclass (rather than the explicit hint) can be accessed as " +"machinery, and is never passed to ``__init_subclass__`` implementations. The " +"actual metaclass (rather than the explicit hint) can be accessed as " "``type(cls)``." msgstr "" "La sugerencia de metaclase ``metaclass`` es consumido por el resto de la " @@ -3579,8 +3553,8 @@ msgid "" "makes callbacks to those with a :meth:`~object.__set_name__` hook." msgstr "" "Cuando se crea una clase, :meth:`type.__new__` escanea las variables de " -"clase y realiza la retrollamada a aquellas con un enlace " -":meth:`~object.__set_name__`." +"clase y realiza la retrollamada a aquellas con un enlace :meth:`~object." +"__set_name__`." #: ../Doc/reference/datamodel.rst:2141 msgid "" @@ -3592,13 +3566,13 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2147 msgid "" -"If the class variable is assigned after the class is created, " -":meth:`__set_name__` will not be called automatically. If needed, " -":meth:`__set_name__` can be called directly::" +"If the class variable is assigned after the class is created, :meth:" +"`__set_name__` will not be called automatically. If needed, :meth:" +"`__set_name__` can be called directly::" msgstr "" -"Si la variable de clase se asigna después de crear la clase, " -":meth:`__set_name__` no se llamará automáticamente. Si es necesario, " -":meth:`__set_name__` se puede llamar directamente::" +"Si la variable de clase se asigna después de crear la clase, :meth:" +"`__set_name__` no se llamará automáticamente. Si es necesario, :meth:" +"`__set_name__` se puede llamar directamente::" #: ../Doc/reference/datamodel.rst:2158 msgid "See :ref:`class-object-creation` for more details." @@ -3614,9 +3588,9 @@ msgid "" "executed in a new namespace and the class name is bound locally to the " "result of ``type(name, bases, namespace)``." msgstr "" -"Por defecto, las clases son construidas usando :func:`type`. El cuerpo de la" -" clase es ejecutado en un nuevo espacio de nombres y el nombre de la clase " -"es ligado de forma local al resultado de ``type(name, bases, namespace)``." +"Por defecto, las clases son construidas usando :func:`type`. El cuerpo de la " +"clase es ejecutado en un nuevo espacio de nombres y el nombre de la clase es " +"ligado de forma local al resultado de ``type(name, bases, namespace)``." #: ../Doc/reference/datamodel.rst:2177 msgid "" @@ -3625,8 +3599,8 @@ msgid "" "existing class that included such an argument. In the following example, " "both ``MyClass`` and ``MySubclass`` are instances of ``Meta``::" msgstr "" -"El proceso de creación de clase puede ser personalizado pasando el argumento" -" de palabra clave ``metaclass`` en la línea de definición de la clase, o al " +"El proceso de creación de clase puede ser personalizado pasando el argumento " +"de palabra clave ``metaclass`` en la línea de definición de la clase, o al " "heredar de una clase existente que incluya dicho argumento. En el siguiente " "ejemplo, ambos ``MyClass`` y ``MySubclass`` son instancias de ``Meta``::" @@ -3670,17 +3644,17 @@ msgstr "Resolviendo entradas de la Orden de Resolución de Métodos (MRU)" #: ../Doc/reference/datamodel.rst:2208 msgid "" -"If a base that appears in a class definition is not an instance of " -":class:`type`, then an :meth:`!__mro_entries__` method is searched on the " -"base. If an :meth:`!__mro_entries__` method is found, the base is " -"substituted with the result of a call to :meth:`!__mro_entries__` when " -"creating the class. The method is called with the original bases tuple " -"passed to the *bases* parameter, and must return a tuple of classes that " -"will be used instead of the base. The returned tuple may be empty: in these " -"cases, the original base is ignored." -msgstr "" -"Si una base que aparece en una definición de clase no es una instancia de " -":class:`type`, entonces se busca un método :meth:`!__mro_entries__` en la " +"If a base that appears in a class definition is not an instance of :class:" +"`type`, then an :meth:`!__mro_entries__` method is searched on the base. If " +"an :meth:`!__mro_entries__` method is found, the base is substituted with " +"the result of a call to :meth:`!__mro_entries__` when creating the class. " +"The method is called with the original bases tuple passed to the *bases* " +"parameter, and must return a tuple of classes that will be used instead of " +"the base. The returned tuple may be empty: in these cases, the original base " +"is ignored." +msgstr "" +"Si una base que aparece en una definición de clase no es una instancia de :" +"class:`type`, entonces se busca un método :meth:`!__mro_entries__` en la " "base. Si se encuentra un método :meth:`!__mro_entries__`, la base se " "sustituye por el resultado de una llamada a :meth:`!__mro_entries__` al " "crear la clase. El método se llama con la tupla de bases original pasada al " @@ -3702,8 +3676,8 @@ msgstr ":func:`types.get_original_bases`" #: ../Doc/reference/datamodel.rst:2223 msgid "" -"Retrieve a class's \"original bases\" prior to modifications by " -":meth:`~object.__mro_entries__`." +"Retrieve a class's \"original bases\" prior to modifications by :meth:" +"`~object.__mro_entries__`." msgstr "" "Recupera las \"bases originales\" de una clase antes de las modificaciones " "realizadas por :meth:`~object.__mro_entries__`." @@ -3731,13 +3705,13 @@ msgstr "" msgid "" "if no bases and no explicit metaclass are given, then :func:`type` is used;" msgstr "" -"si no se dan bases ni metaclases explícitas, entonces se utiliza " -":func:`type`;" +"si no se dan bases ni metaclases explícitas, entonces se utiliza :func:" +"`type`;" #: ../Doc/reference/datamodel.rst:2238 msgid "" -"if an explicit metaclass is given and it is *not* an instance of " -":func:`type`, then it is used directly as the metaclass;" +"if an explicit metaclass is given and it is *not* an instance of :func:" +"`type`, then it is used directly as the metaclass;" msgstr "" "si se da una metaclase explícita y *no* es una instancia de :func:`type`, " "entonces se utiliza directamente como la metaclase;" @@ -3753,14 +3727,14 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2243 msgid "" "The most derived metaclass is selected from the explicitly specified " -"metaclass (if any) and the metaclasses (i.e. ``type(cls)``) of all specified" -" base classes. The most derived metaclass is one which is a subtype of *all*" -" of these candidate metaclasses. If none of the candidate metaclasses meets " +"metaclass (if any) and the metaclasses (i.e. ``type(cls)``) of all specified " +"base classes. The most derived metaclass is one which is a subtype of *all* " +"of these candidate metaclasses. If none of the candidate metaclasses meets " "that criterion, then the class definition will fail with ``TypeError``." msgstr "" "La metaclase más derivada es elegida de la metaclase especificada " -"explícitamente (si existe) y de la metaclase (p. ej. ``type(cls)``) de todas" -" las clases base especificadas." +"explícitamente (si existe) y de la metaclase (p. ej. ``type(cls)``) de todas " +"las clases base especificadas." #: ../Doc/reference/datamodel.rst:2253 msgid "Preparing the class namespace" @@ -3768,9 +3742,9 @@ msgstr "Preparando el espacio de nombres de la clase" #: ../Doc/reference/datamodel.rst:2258 msgid "" -"Once the appropriate metaclass has been identified, then the class namespace" -" is prepared. If the metaclass has a ``__prepare__`` attribute, it is called" -" as ``namespace = metaclass.__prepare__(name, bases, **kwds)`` (where the " +"Once the appropriate metaclass has been identified, then the class namespace " +"is prepared. If the metaclass has a ``__prepare__`` attribute, it is called " +"as ``namespace = metaclass.__prepare__(name, bases, **kwds)`` (where the " "additional keyword arguments, if any, come from the class definition). The " "``__prepare__`` method should be implemented as a :func:`classmethod " "`. The namespace returned by ``__prepare__`` is passed in to " @@ -3781,8 +3755,8 @@ msgstr "" "de nombres de la clase. Si la metaclase tiene un atributo ``__prepare__``, " "se llama ``namespace = metaclass.__prepare__(name, bases, **kwds)`` (donde " "los argumentos de palabras clave adicionales, si los hay, provienen de la " -"definición de clase). El método ``__prepare__`` debe implementarse como " -":func:`classmethod `. El espacio de nombres retornado por " +"definición de clase). El método ``__prepare__`` debe implementarse como :" +"func:`classmethod `. El espacio de nombres retornado por " "``__prepare__`` se pasa a ``__new__``, pero cuando se crea el objeto de " "clase final, el espacio de nombres se copia en un nuevo ``dict``." @@ -3814,9 +3788,9 @@ msgid "" "names from the current and outer scopes when the class definition occurs " "inside a function." msgstr "" -"El cuerpo de la clase es ejecutado como ``exec(body, globals(), namespace)``" -" (aproximadamente). La diferencia clave con un llamado normal a :func:`exec`" -" es que el alcance léxico permite que el cuerpo de la clase (incluyendo " +"El cuerpo de la clase es ejecutado como ``exec(body, globals(), namespace)`` " +"(aproximadamente). La diferencia clave con un llamado normal a :func:`exec` " +"es que el alcance léxico permite que el cuerpo de la clase (incluyendo " "cualquier método) haga referencia a nombres de los alcances actuales y " "externos cuando la definición de clase sucede dentro de la función." @@ -3829,8 +3803,8 @@ msgid "" "reference described in the next section." msgstr "" "Sin embargo, aún cuando la definición de clase sucede dentro de la función, " -"los métodos definidos dentro de la clase aún no pueden ver nombres definidos" -" dentro del alcance de la clase. Variables de clase deben ser accedidas a " +"los métodos definidos dentro de la clase aún no pueden ver nombres definidos " +"dentro del alcance de la clase. Variables de clase deben ser accedidas a " "través del primer parámetro de instancia o métodos de clase, o a través de " "la referencia al léxico implícito ``__class__`` descrita en la siguiente " "sección." @@ -3841,49 +3815,48 @@ msgstr "Creando el objeto de clase" #: ../Doc/reference/datamodel.rst:2304 msgid "" -"Once the class namespace has been populated by executing the class body, the" -" class object is created by calling ``metaclass(name, bases, namespace, " +"Once the class namespace has been populated by executing the class body, the " +"class object is created by calling ``metaclass(name, bases, namespace, " "**kwds)`` (the additional keywords passed here are the same as those passed " "to ``__prepare__``)." msgstr "" -"Una vez que el espacio de nombres de la clase ha sido poblado al ejecutar el" -" cuerpo de la clase, el objeto de clase es creado al llamar " -"``metaclass(name, bases, namespace, **kwds)`` (las palabras clave " -"adicionales que se pasan aquí, son las mismas que aquellas pasadas en " -"``__prepare__``)." +"Una vez que el espacio de nombres de la clase ha sido poblado al ejecutar el " +"cuerpo de la clase, el objeto de clase es creado al llamar ``metaclass(name, " +"bases, namespace, **kwds)`` (las palabras clave adicionales que se pasan " +"aquí, son las mismas que aquellas pasadas en ``__prepare__``)." #: ../Doc/reference/datamodel.rst:2309 msgid "" "This class object is the one that will be referenced by the zero-argument " "form of :func:`super`. ``__class__`` is an implicit closure reference " "created by the compiler if any methods in a class body refer to either " -"``__class__`` or ``super``. This allows the zero argument form of " -":func:`super` to correctly identify the class being defined based on lexical" -" scoping, while the class or instance that was used to make the current call" -" is identified based on the first argument passed to the method." -msgstr "" -"Este objeto de clase es el que será referenciado por la forma sin argumentos" -" de :func:`super`. ``__class__`` es una referencia de cierre implícita " -"creada por el compilador si cualquier método en el cuerpo de una clase se " -"refiere tanto a ``__class__`` o ``super``. Esto permite que la forma sin " -"argumentos de :func:`super` identifique correctamente la clase definida en " -"base al alcance léxico, mientras la clase o instancia que fue utilizada para" -" hacer el llamado actual es identificado en base al primer argumento que se " -"pasa al método." +"``__class__`` or ``super``. This allows the zero argument form of :func:" +"`super` to correctly identify the class being defined based on lexical " +"scoping, while the class or instance that was used to make the current call " +"is identified based on the first argument passed to the method." +msgstr "" +"Este objeto de clase es el que será referenciado por la forma sin argumentos " +"de :func:`super`. ``__class__`` es una referencia de cierre implícita creada " +"por el compilador si cualquier método en el cuerpo de una clase se refiere " +"tanto a ``__class__`` o ``super``. Esto permite que la forma sin argumentos " +"de :func:`super` identifique correctamente la clase definida en base al " +"alcance léxico, mientras la clase o instancia que fue utilizada para hacer " +"el llamado actual es identificado en base al primer argumento que se pasa al " +"método." #: ../Doc/reference/datamodel.rst:2319 msgid "" "In CPython 3.6 and later, the ``__class__`` cell is passed to the metaclass " "as a ``__classcell__`` entry in the class namespace. If present, this must " "be propagated up to the ``type.__new__`` call in order for the class to be " -"initialised correctly. Failing to do so will result in a :exc:`RuntimeError`" -" in Python 3.8." +"initialised correctly. Failing to do so will result in a :exc:`RuntimeError` " +"in Python 3.8." msgstr "" "En CPython 3.6 y posterior, la celda ``__class__`` se pasa a la metaclase " "como una entrada ``__classcell__`` en el espacio de nombres de la clase. En " "caso de existir, esto debe ser propagado hacia el llamado ``type.__new__`` " -"para que la clase se inicie correctamente. No hacerlo resultará en un error " -":exc:`RuntimeError` en Python 3.8." +"para que la clase se inicie correctamente. No hacerlo resultará en un error :" +"exc:`RuntimeError` en Python 3.8." #: ../Doc/reference/datamodel.rst:2325 msgid "" @@ -3908,13 +3881,13 @@ msgid "" "Those ``__set_name__`` methods are called with the class being defined and " "the assigned name of that particular attribute;" msgstr "" -"Esos métodos ``__set_name__`` son llamados con la clase siendo definida y el" -" nombre de ese atributo particular asignado;" +"Esos métodos ``__set_name__`` son llamados con la clase siendo definida y el " +"nombre de ese atributo particular asignado;" #: ../Doc/reference/datamodel.rst:2333 msgid "" -"The :meth:`~object.__init_subclass__` hook is called on the immediate parent" -" of the new class in its method resolution order." +"The :meth:`~object.__init_subclass__` hook is called on the immediate parent " +"of the new class in its method resolution order." msgstr "" "El gancho :meth:`~object.__init_subclass__` llama al padre inmediato de la " "nueva clase en su orden de resolución del método." @@ -3939,8 +3912,8 @@ msgstr "" "Cuando una nueva clase es creada por ``type.__new__``, el objeto " "proporcionado como el parámetro de espacio de nombres es copiado a un " "trazado ordenado y el objeto original es descartado. La nueva copia es " -"*envuelta* en un proxy de solo lectura, que se convierte en el atributo " -":attr:`~object.__dict__` del objeto de clase." +"*envuelta* en un proxy de solo lectura, que se convierte en el atributo :" +"attr:`~object.__dict__` del objeto de clase." #: ../Doc/reference/datamodel.rst:2347 msgid ":pep:`3135` - New super" @@ -3972,12 +3945,12 @@ msgstr "Personalizando revisiones de instancia y subclase" #: ../Doc/reference/datamodel.rst:2363 msgid "" -"The following methods are used to override the default behavior of the " -":func:`isinstance` and :func:`issubclass` built-in functions." +"The following methods are used to override the default behavior of the :func:" +"`isinstance` and :func:`issubclass` built-in functions." msgstr "" "Los siguientes métodos son utilizados para anular el comportamiento por " -"defecto de las funciones incorporadas :func:`isinstance` y " -":func:`issubclass`." +"defecto de las funciones incorporadas :func:`isinstance` y :func:" +"`issubclass`." #: ../Doc/reference/datamodel.rst:2366 msgid "" @@ -3997,15 +3970,15 @@ msgid "" "instance of *class*. If defined, called to implement ``isinstance(instance, " "class)``." msgstr "" -"Retorna *true* si la instancia *instance* debe ser considerada una instancia" -" (directa o indirecta) de clase *class*. De ser definida, es llamado para " +"Retorna *true* si la instancia *instance* debe ser considerada una instancia " +"(directa o indirecta) de clase *class*. De ser definida, es llamado para " "implementar ``isinstance(instance, class)``." #: ../Doc/reference/datamodel.rst:2380 msgid "" "Return true if *subclass* should be considered a (direct or indirect) " -"subclass of *class*. If defined, called to implement ``issubclass(subclass," -" class)``." +"subclass of *class*. If defined, called to implement ``issubclass(subclass, " +"class)``." msgstr "" "Retorna *true* si la subclase *subclass* debe ser considerada una subclase " "(directa o indirecta) de clase *class*. De ser definida, es llamado para " @@ -4026,22 +3999,21 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2396 msgid ":pep:`3119` - Introducing Abstract Base Classes" msgstr "" -":pep:`3119` - Introducción a Clases Base Abstractas (*Abstract Base " -"Classes*)" +":pep:`3119` - Introducción a Clases Base Abstractas (*Abstract Base Classes*)" #: ../Doc/reference/datamodel.rst:2393 msgid "" -"Includes the specification for customizing :func:`isinstance` and " -":func:`issubclass` behavior through :meth:`~class.__instancecheck__` and " -":meth:`~class.__subclasscheck__`, with motivation for this functionality in " -"the context of adding Abstract Base Classes (see the :mod:`abc` module) to " -"the language." +"Includes the specification for customizing :func:`isinstance` and :func:" +"`issubclass` behavior through :meth:`~class.__instancecheck__` and :meth:" +"`~class.__subclasscheck__`, with motivation for this functionality in the " +"context of adding Abstract Base Classes (see the :mod:`abc` module) to the " +"language." msgstr "" -"Incluye la especificación para personalizar el comportamiento de " -":func:`isinstance` y :func:`issubclass` a través de " -":meth:`~class.__instancecheck__` y :meth:`~class.__subclasscheck__`, con " -"motivación para esta funcionalidad en el contexto de agregar Clases Base " -"Abstractas (ver el módulo :mod:`abc`) al lenguaje." +"Incluye la especificación para personalizar el comportamiento de :func:" +"`isinstance` y :func:`issubclass` a través de :meth:`~class." +"__instancecheck__` y :meth:`~class.__subclasscheck__`, con motivación para " +"esta funcionalidad en el contexto de agregar Clases Base Abstractas (ver el " +"módulo :mod:`abc`) al lenguaje." #: ../Doc/reference/datamodel.rst:2401 msgid "Emulating generic types" @@ -4051,8 +4023,8 @@ msgstr "Emulando tipos genéricos" msgid "" "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`." +"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 "" "Cuando se usa :term:`type annotations`, a menudo es útil " "*parameterize* a :term:`generic type` usando la notación de corchetes de " @@ -4065,8 +4037,7 @@ msgstr ":pep:`484` - Sugerencias de tipo" #: ../Doc/reference/datamodel.rst:2411 msgid "Introducing Python's framework for type annotations" -msgstr "" -"Presentamos el marco de trabajo de Python para las anotaciones de tipo" +msgstr "Presentamos el marco de trabajo de Python para las anotaciones de tipo" #: ../Doc/reference/datamodel.rst:2414 msgid ":ref:`Generic Alias Types`" @@ -4079,11 +4050,11 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2417 msgid "" -":ref:`Generics`, :ref:`user-defined generics` and " -":class:`typing.Generic`" +":ref:`Generics`, :ref:`user-defined generics` and :" +"class:`typing.Generic`" msgstr "" -":ref:`Generics`, :ref:`user-defined generics` y " -":class:`typing.Generic`" +":ref:`Generics`, :ref:`user-defined generics` y :" +"class:`typing.Generic`" #: ../Doc/reference/datamodel.rst:2417 msgid "" @@ -4113,12 +4084,12 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2428 msgid "" "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." +"method. As such, there is no need for it to be decorated with :func:" +"`@classmethod` when it is defined." msgstr "" -"Cuando se define en una clase, ``__class_getitem__()`` es automáticamente un" -" método de clase. Como tal, no es necesario decorarlo con " -":func:`@classmethod` cuando se define." +"Cuando se define en una clase, ``__class_getitem__()`` es automáticamente un " +"método de clase. Como tal, no es necesario decorarlo con :func:" +"`@classmethod` cuando se define." #: ../Doc/reference/datamodel.rst:2434 msgid "The purpose of *__class_getitem__*" @@ -4127,41 +4098,41 @@ msgstr "El propósito de *__class_getitem__*" #: ../Doc/reference/datamodel.rst:2436 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." +"parameterization of standard-library generic classes in order to more easily " +"apply :term:`type hints` to these classes." msgstr "" "El propósito de :meth:`~object.__class_getitem__` es permitir la " "parametrización en tiempo de ejecución de clases genéricas de biblioteca " -"estándar para aplicar :term:`type hints` a estas clases con mayor" -" facilidad." +"estándar para aplicar :term:`type hints` a estas clases con mayor " +"facilidad." #: ../Doc/reference/datamodel.rst:2440 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__()``." +"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 "" "Para implementar clases genéricas personalizadas que se puedan parametrizar " "en tiempo de ejecución y que los verificadores de tipos estáticos las " "entiendan, los usuarios deben heredar de una clase de biblioteca estándar " -"que ya implementa :meth:`~object.__class_getitem__`, o heredar de " -":class:`typing.Generic`, que tiene su propia implementación de " +"que ya implementa :meth:`~object.__class_getitem__`, o heredar de :class:" +"`typing.Generic`, que tiene su propia implementación de " "``__class_getitem__()``." #: ../Doc/reference/datamodel.rst:2446 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 " +"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 "" "Es posible que los verificadores de tipos de terceros, como mypy, no " -"entiendan las implementaciones personalizadas de " -":meth:`~object.__class_getitem__` en clases definidas fuera de la biblioteca" -" estándar. Se desaconseja el uso de ``__class_getitem__()`` en cualquier " -"clase para fines distintos a la sugerencia de tipo." +"entiendan las implementaciones personalizadas de :meth:`~object." +"__class_getitem__` en clases definidas fuera de la biblioteca estándar. Se " +"desaconseja el uso de ``__class_getitem__()`` en cualquier clase para fines " +"distintos a la sugerencia de tipo." #: ../Doc/reference/datamodel.rst:2456 msgid "*__class_getitem__* versus *__getitem__*" @@ -4179,48 +4150,47 @@ msgstr "" "Por lo general, el :ref:`subscription` de un objeto que usa " "corchetes llamará al método de instancia :meth:`~object.__getitem__` " "definido en la clase del objeto. Sin embargo, si el objeto que se suscribe " -"es en sí mismo una clase, se puede llamar al método de clase " -":meth:`~object.__class_getitem__` en su lugar. ``__class_getitem__()`` " -"debería retornar un objeto :ref:`GenericAlias` si está " -"definido correctamente." +"es en sí mismo una clase, se puede llamar al método de clase :meth:`~object." +"__class_getitem__` en su lugar. ``__class_getitem__()`` debería retornar un " +"objeto :ref:`GenericAlias` si está definido " +"correctamente." #: ../Doc/reference/datamodel.rst:2465 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::" +"follows something like the following process to decide whether :meth:" +"`~object.__getitem__` or :meth:`~object.__class_getitem__` should be called::" msgstr "" "Presentado con el :term:`expression` ``obj[x]``, el intérprete de Python " -"sigue un proceso similar al siguiente para decidir si se debe llamar a " -":meth:`~object.__getitem__` o :meth:`~object.__class_getitem__`:" +"sigue un proceso similar al siguiente para decidir si se debe llamar a :meth:" +"`~object.__getitem__` o :meth:`~object.__class_getitem__`:" #: ../Doc/reference/datamodel.rst:2493 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::" +"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 "" "En Python, todas las clases son en sí mismas instancias de otras clases. La " "clase de una clase se conoce como :term:`metaclass` de esa clase, y la " -"mayoría de las clases tienen la clase :class:`type` como su metaclase. " -":class:`type` no define :meth:`~object.__getitem__`, lo que significa que " -"expresiones como ``list[int]``, ``dict[str, float]`` y ``tuple[str, bytes]``" -" dan como resultado que se llame a :meth:`~object.__class_getitem__`:" +"mayoría de las clases tienen la clase :class:`type` como su metaclase. :" +"class:`type` no define :meth:`~object.__getitem__`, lo que significa que " +"expresiones como ``list[int]``, ``dict[str, float]`` y ``tuple[str, bytes]`` " +"dan como resultado que se llame a :meth:`~object.__class_getitem__`:" #: ../Doc/reference/datamodel.rst:2512 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::" +"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 "" -"Sin embargo, si una clase tiene una metaclase personalizada que define " -":meth:`~object.__getitem__`, la suscripción de la clase puede generar un " -"comportamiento diferente. Un ejemplo de esto se puede encontrar en el módulo" -" :mod:`enum`:" +"Sin embargo, si una clase tiene una metaclase personalizada que define :meth:" +"`~object.__getitem__`, la suscripción de la clase puede generar un " +"comportamiento diferente. Un ejemplo de esto se puede encontrar en el " +"módulo :mod:`enum`:" #: ../Doc/reference/datamodel.rst:2537 msgid ":pep:`560` - Core Support for typing module and generic types" @@ -4229,12 +4199,12 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2536 msgid "" -"Introducing :meth:`~object.__class_getitem__`, and outlining when a " -":ref:`subscription` results in ``__class_getitem__()`` being " +"Introducing :meth:`~object.__class_getitem__`, and outlining when a :ref:" +"`subscription` results in ``__class_getitem__()`` being " "called instead of :meth:`~object.__getitem__`" msgstr "" -"Presentamos :meth:`~object.__class_getitem__` y describimos cuándo un " -":ref:`subscription` da como resultado que se llame a " +"Presentamos :meth:`~object.__class_getitem__` y describimos cuándo un :ref:" +"`subscription` da como resultado que se llame a " "``__class_getitem__()`` en lugar de :meth:`~object.__getitem__`" #: ../Doc/reference/datamodel.rst:2544 @@ -4247,9 +4217,9 @@ msgid "" "defined, ``x(arg1, arg2, ...)`` roughly translates to ``type(x).__call__(x, " "arg1, ...)``." msgstr "" -"Es llamado cuando la instancia es “llamada” como una función; si este método" -" es definido, ``x(arg1, arg2, …)`` es una clave corta para " -"``x.__call__(arg1, arg2, …)``." +"Es llamado cuando la instancia es “llamada” como una función; si este método " +"es definido, ``x(arg1, arg2, …)`` es una clave corta para ``x.__call__(arg1, " +"arg2, …)``." #: ../Doc/reference/datamodel.rst:2558 msgid "Emulating container types" @@ -4259,73 +4229,71 @@ msgstr "Emulando tipos de contenedores" msgid "" "The following methods can be defined to implement container objects. " "Containers usually are :term:`sequences ` (such as :class:`lists " -"` or :class:`tuples `) or :term:`mappings ` (like " -":class:`dictionaries `), but can represent other containers as well. " +"` or :class:`tuples `) or :term:`mappings ` (like :" +"class:`dictionaries `), but can represent other containers as well. " "The first set of methods is used either to emulate a sequence or to emulate " "a mapping; the difference is that for a sequence, the allowable keys should " "be the integers *k* for which ``0 <= k < N`` where *N* is the length of the " "sequence, or :class:`slice` objects, which define a range of items. It is " -"also recommended that mappings provide the methods :meth:`keys`, " -":meth:`values`, :meth:`items`, :meth:`get`, :meth:`clear`, " -":meth:`setdefault`, :meth:`pop`, :meth:`popitem`, :meth:`!copy`, and " -":meth:`update` behaving similar to those for Python's standard " -":class:`dictionary ` objects. The :mod:`collections.abc` module " -"provides a :class:`~collections.abc.MutableMapping` :term:`abstract base " -"class` to help create those methods from a base set of " -":meth:`~object.__getitem__`, :meth:`~object.__setitem__`, " -":meth:`~object.__delitem__`, and :meth:`keys`. Mutable sequences should " -"provide methods :meth:`append`, :meth:`count`, :meth:`index`, " -":meth:`extend`, :meth:`insert`, :meth:`pop`, :meth:`remove`, :meth:`reverse`" -" and :meth:`sort`, like Python standard :class:`list` objects. Finally, " -"sequence types should implement addition (meaning concatenation) and " -"multiplication (meaning repetition) by defining the methods " -":meth:`~object.__add__`, :meth:`~object.__radd__`, :meth:`~object.__iadd__`," -" :meth:`~object.__mul__`, :meth:`~object.__rmul__` and " -":meth:`~object.__imul__` described below; they should not define other " -"numerical operators. It is recommended that both mappings and sequences " -"implement the :meth:`~object.__contains__` method to allow efficient use of " -"the ``in`` operator; for mappings, ``in`` should search the mapping's keys; " -"for sequences, it should search through the values. It is further " -"recommended that both mappings and sequences implement the " -":meth:`~object.__iter__` method to allow efficient iteration through the " -"container; for mappings, :meth:`__iter__` should iterate through the " -"object's keys; for sequences, it should iterate through the values." +"also recommended that mappings provide the methods :meth:`keys`, :meth:" +"`values`, :meth:`items`, :meth:`get`, :meth:`clear`, :meth:`setdefault`, :" +"meth:`pop`, :meth:`popitem`, :meth:`!copy`, and :meth:`update` behaving " +"similar to those for Python's standard :class:`dictionary ` objects. " +"The :mod:`collections.abc` module provides a :class:`~collections.abc." +"MutableMapping` :term:`abstract base class` to help create those methods " +"from a base set of :meth:`~object.__getitem__`, :meth:`~object." +"__setitem__`, :meth:`~object.__delitem__`, and :meth:`keys`. Mutable " +"sequences should provide methods :meth:`append`, :meth:`count`, :meth:" +"`index`, :meth:`extend`, :meth:`insert`, :meth:`pop`, :meth:`remove`, :meth:" +"`reverse` and :meth:`sort`, like Python standard :class:`list` objects. " +"Finally, sequence types should implement addition (meaning concatenation) " +"and multiplication (meaning repetition) by defining the methods :meth:" +"`~object.__add__`, :meth:`~object.__radd__`, :meth:`~object.__iadd__`, :meth:" +"`~object.__mul__`, :meth:`~object.__rmul__` and :meth:`~object.__imul__` " +"described below; they should not define other numerical operators. It is " +"recommended that both mappings and sequences implement the :meth:`~object." +"__contains__` method to allow efficient use of the ``in`` operator; for " +"mappings, ``in`` should search the mapping's keys; for sequences, it should " +"search through the values. It is further recommended that both mappings and " +"sequences implement the :meth:`~object.__iter__` method to allow efficient " +"iteration through the container; for mappings, :meth:`__iter__` should " +"iterate through the object's keys; for sequences, it should iterate through " +"the values." msgstr "" "Se pueden definir los siguientes métodos para implementar objetos " -"contenedores. Los contenedores suelen ser :term:`sequences ` (como" -" :class:`lists ` o :class:`tuples `) o :term:`mappings " +"contenedores. Los contenedores suelen ser :term:`sequences ` " +"(como :class:`lists ` o :class:`tuples `) o :term:`mappings " "` (como :class:`dictionaries `), pero también pueden " "representar otros contenedores. El primer conjunto de métodos se utiliza " "para emular una secuencia o un mapeo; la diferencia es que para una " "secuencia, las claves permitidas deben ser los números enteros *k* para los " -"cuales ``0 <= k < N`` donde *N* es la longitud de la secuencia, u objetos " -":class:`slice`, que definen un rango de elementos. También se recomienda que" -" las asignaciones proporcionen los métodos :meth:`keys`, :meth:`values`, " -":meth:`items`, :meth:`get`, :meth:`clear`, :meth:`setdefault`, :meth:`pop`, " -":meth:`popitem`, :meth:`!copy` y :meth:`update` que se comportan de manera " +"cuales ``0 <= k < N`` donde *N* es la longitud de la secuencia, u objetos :" +"class:`slice`, que definen un rango de elementos. También se recomienda que " +"las asignaciones proporcionen los métodos :meth:`keys`, :meth:`values`, :" +"meth:`items`, :meth:`get`, :meth:`clear`, :meth:`setdefault`, :meth:`pop`, :" +"meth:`popitem`, :meth:`!copy` y :meth:`update` que se comportan de manera " "similar a los de los objetos :class:`dictionary ` estándar de Python. " -"El módulo :mod:`collections.abc` proporciona un " -":class:`~collections.abc.MutableMapping` :term:`abstract base class` para " -"ayudar a crear esos métodos a partir de un conjunto básico de " -":meth:`~object.__getitem__`, :meth:`~object.__setitem__`, " -":meth:`~object.__delitem__` y :meth:`keys`. Las secuencias mutables deben " -"proporcionar los métodos :meth:`append`, :meth:`count`, :meth:`index`, " -":meth:`extend`, :meth:`insert`, :meth:`pop`, :meth:`remove`, :meth:`reverse`" -" y :meth:`sort`, como los objetos :class:`list` estándar de Python. " -"Finalmente, los tipos de secuencia deben implementar la suma (es decir, " -"concatenación) y la multiplicación (es decir, repetición) definiendo los " -"métodos :meth:`~object.__add__`, :meth:`~object.__radd__`, " -":meth:`~object.__iadd__`, :meth:`~object.__mul__`, :meth:`~object.__rmul__` " -"y :meth:`~object.__imul__` que se describen a continuación; no deben definir" -" otros operadores numéricos. Se recomienda que tanto las asignaciones como " +"El módulo :mod:`collections.abc` proporciona un :class:`~collections.abc." +"MutableMapping` :term:`abstract base class` para ayudar a crear esos métodos " +"a partir de un conjunto básico de :meth:`~object.__getitem__`, :meth:" +"`~object.__setitem__`, :meth:`~object.__delitem__` y :meth:`keys`. Las " +"secuencias mutables deben proporcionar los métodos :meth:`append`, :meth:" +"`count`, :meth:`index`, :meth:`extend`, :meth:`insert`, :meth:`pop`, :meth:" +"`remove`, :meth:`reverse` y :meth:`sort`, como los objetos :class:`list` " +"estándar de Python. Finalmente, los tipos de secuencia deben implementar la " +"suma (es decir, concatenación) y la multiplicación (es decir, repetición) " +"definiendo los métodos :meth:`~object.__add__`, :meth:`~object.__radd__`, :" +"meth:`~object.__iadd__`, :meth:`~object.__mul__`, :meth:`~object.__rmul__` " +"y :meth:`~object.__imul__` que se describen a continuación; no deben definir " +"otros operadores numéricos. Se recomienda que tanto las asignaciones como " "las secuencias implementen el método :meth:`~object.__contains__` para " "permitir el uso eficiente del operador ``in``; para asignaciones, ``in`` " "debería buscar las claves de la asignación; para secuencias, debe buscar " "entre los valores. Se recomienda además que tanto las asignaciones como las " "secuencias implementen el método :meth:`~object.__iter__` para permitir una " -"iteración eficiente a través del contenedor; para asignaciones, " -":meth:`__iter__` debe iterar a través de las claves del objeto; para " -"secuencias, debe iterar a través de los valores." +"iteración eficiente a través del contenedor; para asignaciones, :meth:" +"`__iter__` debe iterar a través de las claves del objeto; para secuencias, " +"debe iterar a través de los valores." #: ../Doc/reference/datamodel.rst:2600 msgid "" @@ -4336,43 +4304,42 @@ msgid "" msgstr "" "Llamado para implementar la función incorporada :func:`len`. Debería " "retornar la longitud del objeto, un número entero ``>=`` 0. Además, un " -"objeto que no define un método :meth:`~object.__bool__` y cuyo método " -":meth:`!__len__` retorna cero se considera falso en un contexto booleano." +"objeto que no define un método :meth:`~object.__bool__` y cuyo método :meth:" +"`!__len__` retorna cero se considera falso en un contexto booleano." #: ../Doc/reference/datamodel.rst:2607 msgid "" -"In CPython, the length is required to be at most :data:`sys.maxsize`. If the" -" length is larger than :data:`!sys.maxsize` some features (such as " -":func:`len`) may raise :exc:`OverflowError`. To prevent raising " -":exc:`!OverflowError` by truth value testing, an object must define a " -":meth:`~object.__bool__` method." +"In CPython, the length is required to be at most :data:`sys.maxsize`. If the " +"length is larger than :data:`!sys.maxsize` some features (such as :func:" +"`len`) may raise :exc:`OverflowError`. To prevent raising :exc:`!" +"OverflowError` by truth value testing, an object must define a :meth:" +"`~object.__bool__` method." msgstr "" -"En CPython, se requiere que la longitud sea como máximo :data:`sys.maxsize`." -" Si la longitud es mayor que :data:`!sys.maxsize`, algunas funciones (como " -":func:`len`) pueden generar :exc:`OverflowError`. Para evitar que se genere " -":exc:`!OverflowError` mediante pruebas de valor de verdad, un objeto debe " +"En CPython, se requiere que la longitud sea como máximo :data:`sys.maxsize`. " +"Si la longitud es mayor que :data:`!sys.maxsize`, algunas funciones (como :" +"func:`len`) pueden generar :exc:`OverflowError`. Para evitar que se genere :" +"exc:`!OverflowError` mediante pruebas de valor de verdad, un objeto debe " "definir un método :meth:`~object.__bool__`." #: ../Doc/reference/datamodel.rst:2616 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). The length must be an integer ``>=`` 0. The return value may also " -"be :const:`NotImplemented`, which is treated the same as if the " -"``__length_hint__`` method didn't exist at all. This method is purely an " -"optimization and is never required for correctness." +"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). " +"The length must be an integer ``>=`` 0. The return value may also be :const:" +"`NotImplemented`, which is treated the same as if the ``__length_hint__`` " +"method didn't exist at all. This method is purely an optimization and is " +"never required for correctness." msgstr "" "Es llamado para implementar :func:`operator.length_hint`. Debe retornar una " "longitud estimada para el objeto (que puede ser mayor o menor que la " "longitud actual). La longitud debe ser un entero ``>=`` 0. El valor de " -"retorno también debe ser :const:`NotImplemented` el cual es tratado de igual" -" forma a que si el método ``__length_hint__`` no existiera en absoluto. Este" -" método es puramente una optimización y nunca es requerido para precisión." +"retorno también debe ser :const:`NotImplemented` el cual es tratado de igual " +"forma a que si el método ``__length_hint__`` no existiera en absoluto. Este " +"método es puramente una optimización y nunca es requerido para precisión." #: ../Doc/reference/datamodel.rst:2630 msgid "" -"Slicing is done exclusively with the following three methods. A call like " -"::" +"Slicing is done exclusively with the following three methods. A call like ::" msgstr "" "La segmentación se hace exclusivamente con los siguientes tres métodos. Un " "llamado como ::" @@ -4384,31 +4351,30 @@ msgstr "es traducido a ::" #: ../Doc/reference/datamodel.rst:2638 msgid "and so forth. Missing slice items are always filled in with ``None``." msgstr "" -"etcétera. Elementos faltantes de segmentos siempre son llenados con " -"``None``." +"etcétera. Elementos faltantes de segmentos siempre son llenados con ``None``." #: ../Doc/reference/datamodel.rst:2643 msgid "" -"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 " +"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." +"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 "" -"Llamado a implementar evaluación de ``self[key]``. Para los tipos " -":term:`sequence`, las claves aceptadas deben ser números enteros y objetos " -"de segmento. Tenga en cuenta que la interpretación especial de los índices " +"Llamado a implementar evaluación de ``self[key]``. Para los tipos :term:" +"`sequence`, las claves aceptadas deben ser números enteros y objetos de " +"segmento. Tenga en cuenta que la interpretación especial de los índices " "negativos (si la clase desea emular un tipo :term:`sequence`) depende del " "método :meth:`__getitem__`. Si *key* es de un tipo inadecuado, es posible " "que se genere :exc:`TypeError`; si se trata de un valor fuera del conjunto " "de índices de la secuencia (después de cualquier interpretación especial de " -"valores negativos), se debe generar :exc:`IndexError`. Para los tipos " -":term:`mapping`, si falta *key* (no en el contenedor), se debe generar " -":exc:`KeyError`." +"valores negativos), se debe generar :exc:`IndexError`. Para los tipos :term:" +"`mapping`, si falta *key* (no en el contenedor), se debe generar :exc:" +"`KeyError`." #: ../Doc/reference/datamodel.rst:2655 msgid "" @@ -4421,9 +4387,9 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2660 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." +"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 "" "Cuando :ref:`subscripting` a *class*, se puede llamar al " "método de clase especial :meth:`~object.__class_getitem__` en lugar de " @@ -4431,11 +4397,11 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2668 msgid "" -"Called to implement assignment to ``self[key]``. Same note as for " -":meth:`__getitem__`. This should only be implemented for mappings if the " -"objects support changes to the values for keys, or if new keys can be added," -" or for sequences if elements can be replaced. The same exceptions should " -"be raised for improper *key* values as for the :meth:`__getitem__` method." +"Called to implement assignment to ``self[key]``. Same note as for :meth:" +"`__getitem__`. This should only be implemented for mappings if the objects " +"support changes to the values for keys, or if new keys can be added, or for " +"sequences if elements can be replaced. The same exceptions should be raised " +"for improper *key* values as for the :meth:`__getitem__` method." msgstr "" "Es llamado para implementar la asignación a ``self[key]``. Lo mismo con " "respecto a :meth:`__getitem__`. Esto solo debe ser implementado para mapeos " @@ -4446,34 +4412,34 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2677 msgid "" -"Called to implement deletion of ``self[key]``. Same note as for " -":meth:`__getitem__`. This should only be implemented for mappings if the " -"objects support removal of keys, or for sequences if elements can be removed" -" from the sequence. The same exceptions should be raised for improper *key*" -" values as for the :meth:`__getitem__` method." +"Called to implement deletion of ``self[key]``. Same note as for :meth:" +"`__getitem__`. This should only be implemented for mappings if the objects " +"support removal of keys, or for sequences if elements can be removed from " +"the sequence. The same exceptions should be raised for improper *key* " +"values as for the :meth:`__getitem__` method." msgstr "" "Es llamado para implementar el borrado de ``self[key]``. Lo mismo con " "respecto a :meth:`__getitem__`. Esto solo debe ser implementado para mapeos " "si los objetos permiten el borrado de llaves, o para secuencias si los " "elementos pueden ser eliminados de la secuencia. Las mismas excepciones " -"deben ser lanzadas por valores de *key* inapropiados con respecto al método " -":meth:`__getitem__`." +"deben ser lanzadas por valores de *key* inapropiados con respecto al método :" +"meth:`__getitem__`." #: ../Doc/reference/datamodel.rst:2686 msgid "" -"Called by :class:`dict`\\ .\\ :meth:`__getitem__` to implement ``self[key]``" -" for dict subclasses when key is not in the dictionary." +"Called by :class:`dict`\\ .\\ :meth:`__getitem__` to implement ``self[key]`` " +"for dict subclasses when key is not in the dictionary." msgstr "" "Es llamado por :class:`dict`\\ .\\ :meth:`__getitem__` para implementar " -"``self[key]`` para subclases de diccionarios cuando la llave no se encuentra" -" en el diccionario." +"``self[key]`` para subclases de diccionarios cuando la llave no se encuentra " +"en el diccionario." #: ../Doc/reference/datamodel.rst:2692 msgid "" "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." +"the objects in the container. For mappings, it should iterate over the keys " +"of the container." msgstr "" "Se llama a este método cuando se requiere un :term:`iterator` para un " "contenedor. Este método debería retornar un nuevo objeto iterador que pueda " @@ -4488,29 +4454,28 @@ msgid "" msgstr "" "Es llamado (si existe) por la función incorporada :func:`reversed` para " "implementar una interacción invertida. Debe retornar un nuevo objeto " -"iterador que itere sobre todos los objetos en el contenedor en orden " -"inverso." +"iterador que itere sobre todos los objetos en el contenedor en orden inverso." #: ../Doc/reference/datamodel.rst:2704 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 " -":meth:`__getitem__`). Objects that support the sequence protocol should " -"only provide :meth:`__reversed__` if they can provide an implementation that" -" is more efficient than the one provided by :func:`reversed`." +"built-in will fall back to using the sequence protocol (:meth:`__len__` and :" +"meth:`__getitem__`). Objects that support the sequence protocol should only " +"provide :meth:`__reversed__` if they can provide an implementation that is " +"more efficient than the one provided by :func:`reversed`." msgstr "" "Si el método :meth:`__reversed__` no es proporcionado, la función " "incorporada :func:`reversed` recurrirá a utilizar el protocolo de secuencia " "(:meth:`__len__` y :meth:`__getitem__`). Objetos que permiten el protocolo " -"de secuencia deben únicamente proporcionar :meth:`__reversed__` si no pueden" -" proporcionar una implementación que sea más eficiente que la proporcionada " +"de secuencia deben únicamente proporcionar :meth:`__reversed__` si no pueden " +"proporcionar una implementación que sea más eficiente que la proporcionada " "por :func:`reversed`." #: ../Doc/reference/datamodel.rst:2711 msgid "" "The membership test operators (:keyword:`in` and :keyword:`not in`) are " -"normally implemented as an iteration through a container. However, container" -" objects can supply the following special method with a more efficient " +"normally implemented as an iteration through a container. However, container " +"objects can supply the following special method with a more efficient " "implementation, which also does not require the object be iterable." msgstr "" "Los operadores de prueba de pertenencia (:keyword:`in` and :keyword:`not " @@ -4521,8 +4486,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2718 msgid "" -"Called to implement membership test operators. Should return true if *item*" -" is in *self*, false otherwise. For mapping objects, this should consider " +"Called to implement membership test operators. Should return true if *item* " +"is in *self*, false otherwise. For mapping objects, this should consider " "the keys of the mapping rather than the values or the key-item pairs." msgstr "" "Es llamado para implementar operadores de prueba de pertenencia. Deben " @@ -4539,8 +4504,8 @@ msgid "" msgstr "" "Para objetos que no definen :meth:`__contains__`, la prueba de pertenencia " "primero intenta la iteración a través de :meth:`__iter__`, y luego el " -"antiguo protocolo de iteración de secuencia a través de :meth:`__getitem__`," -" ver :ref:`esta sección en la referencia del lenguaje `." #: ../Doc/reference/datamodel.rst:2731 @@ -4550,8 +4515,8 @@ msgstr "Emulando tipos numéricos" #: ../Doc/reference/datamodel.rst:2733 msgid "" "The following methods can be defined to emulate numeric objects. Methods " -"corresponding to operations that are not supported by the particular kind of" -" number implemented (e.g., bitwise operations for non-integral numbers) " +"corresponding to operations that are not supported by the particular kind of " +"number implemented (e.g., bitwise operations for non-integral numbers) " "should be left undefined." msgstr "" "Los siguientes métodos pueden ser definidos para emular objetos numéricos. " @@ -4562,26 +4527,26 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2759 msgid "" "These methods are called to implement the binary arithmetic operations " -"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " -":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``). For instance, to" -" evaluate the expression ``x + y``, where *x* is an instance of a class that" -" has an :meth:`__add__` method, ``type(x).__add__(x, y)`` is called. The " -":meth:`__divmod__` method should be the equivalent to using " -":meth:`__floordiv__` and :meth:`__mod__`; it should not be related to " -":meth:`__truediv__`. Note that :meth:`__pow__` should be defined to accept " -"an optional third argument if the ternary version of the built-in " -":func:`pow` function is to be supported." +"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :func:" +"`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``). For instance, to " +"evaluate the expression ``x + y``, where *x* is an instance of a class that " +"has an :meth:`__add__` method, ``type(x).__add__(x, y)`` is called. The :" +"meth:`__divmod__` method should be the equivalent to using :meth:" +"`__floordiv__` and :meth:`__mod__`; it should not be related to :meth:" +"`__truediv__`. Note that :meth:`__pow__` should be defined to accept an " +"optional third argument if the ternary version of the built-in :func:`pow` " +"function is to be supported." msgstr "" "Estos métodos se llaman para implementar las operaciones aritméticas " -"binarias (``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " -":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``). Por ejemplo, para" -" evaluar la expresión ``x + y``, donde *x* es una instancia de una clase que" -" tiene un método :meth:`__add__`, se llama a ``type(x).__add__(x, y)``. El " -"método :meth:`__divmod__` debería ser equivalente al uso de " -":meth:`__floordiv__` y :meth:`__mod__`; no debería estar relacionado con " -":meth:`__truediv__`. Tenga en cuenta que :meth:`__pow__` debe definirse para" -" aceptar un tercer argumento opcional si se va a admitir la versión ternaria" -" de la función incorporada :func:`pow`." +"binarias (``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :" +"func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``). Por ejemplo, para " +"evaluar la expresión ``x + y``, donde *x* es una instancia de una clase que " +"tiene un método :meth:`__add__`, se llama a ``type(x).__add__(x, y)``. El " +"método :meth:`__divmod__` debería ser equivalente al uso de :meth:" +"`__floordiv__` y :meth:`__mod__`; no debería estar relacionado con :meth:" +"`__truediv__`. Tenga en cuenta que :meth:`__pow__` debe definirse para " +"aceptar un tercer argumento opcional si se va a admitir la versión ternaria " +"de la función incorporada :func:`pow`." #: ../Doc/reference/datamodel.rst:2770 msgid "" @@ -4594,24 +4559,24 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2793 msgid "" "These methods are called to implement the binary arithmetic operations " -"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " -":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``) with reflected " -"(swapped) operands. These functions are only called if the left operand " -"does not support the corresponding operation [#]_ and the operands are of " -"different types. [#]_ For instance, to evaluate the expression ``x - y``, " -"where *y* is an instance of a class that has an :meth:`__rsub__` method, " -"``type(y).__rsub__(y, x)`` is called if ``type(x).__sub__(x, y)`` returns " +"(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :func:" +"`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``) with reflected (swapped) " +"operands. These functions are only called if the left operand does not " +"support the corresponding operation [#]_ and the operands are of different " +"types. [#]_ For instance, to evaluate the expression ``x - y``, where *y* is " +"an instance of a class that has an :meth:`__rsub__` method, ``type(y)." +"__rsub__(y, x)`` is called if ``type(x).__sub__(x, y)`` returns " "*NotImplemented*." msgstr "" "Estos métodos se llaman para implementar las operaciones aritméticas " -"binarias (``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, " -":func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``) con operandos " +"binarias (``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :" +"func:`pow`, ``**``, ``<<``, ``>>``, ``&``, ``^``, ``|``) con operandos " "reflejados (intercambiados). Estas funciones solo se llaman si el operando " -"izquierdo no admite la operación correspondiente [#]_ y los operandos son de" -" diferentes tipos. [#]_ Por ejemplo, para evaluar la expresión ``x - y``, " -"donde *y* es una instancia de una clase que tiene un método " -":meth:`__rsub__`, se llama a ``type(y).__rsub__(y, x)`` si " -"``type(x).__sub__(x, y)`` retorna *NotImplemented*." +"izquierdo no admite la operación correspondiente [#]_ y los operandos son de " +"diferentes tipos. [#]_ Por ejemplo, para evaluar la expresión ``x - y``, " +"donde *y* es una instancia de una clase que tiene un método :meth:" +"`__rsub__`, se llama a ``type(y).__rsub__(y, x)`` si ``type(x).__sub__(x, " +"y)`` retorna *NotImplemented*." #: ../Doc/reference/datamodel.rst:2805 msgid "" @@ -4633,20 +4598,20 @@ msgstr "" "Si el tipo del operando de la derecha es una subclase del tipo del operando " "de la izquierda y esa subclase proporciona el método reflejado para la " "operación, este método será llamado antes del método no reflejado del " -"operando izquierdo. Este comportamiento permite que las subclases anulen las" -" operaciones de sus predecesores." +"operando izquierdo. Este comportamiento permite que las subclases anulen las " +"operaciones de sus predecesores." #: ../Doc/reference/datamodel.rst:2831 msgid "" "These methods are called to implement the augmented arithmetic assignments " "(``+=``, ``-=``, ``*=``, ``@=``, ``/=``, ``//=``, ``%=``, ``**=``, ``<<=``, " "``>>=``, ``&=``, ``^=``, ``|=``). These methods should attempt to do the " -"operation in-place (modifying *self*) and return the result (which could be," -" but does not have to be, *self*). If a specific method is not defined, the" -" augmented assignment falls back to the normal methods. For instance, if " -"*x* is an instance of a class with an :meth:`__iadd__` method, ``x += y`` is" -" equivalent to ``x = x.__iadd__(y)`` . Otherwise, ``x.__add__(y)`` and " -"``y.__radd__(x)`` are considered, as with the evaluation of ``x + y``. In " +"operation in-place (modifying *self*) and return the result (which could be, " +"but does not have to be, *self*). If a specific method is not defined, the " +"augmented assignment falls back to the normal methods. For instance, if *x* " +"is an instance of a class with an :meth:`__iadd__` method, ``x += y`` is " +"equivalent to ``x = x.__iadd__(y)`` . Otherwise, ``x.__add__(y)`` and ``y." +"__radd__(x)`` are considered, as with the evaluation of ``x + y``. In " "certain situations, augmented assignment can result in unexpected errors " "(see :ref:`faq-augmented-assignment-tuple-error`), but this behavior is in " "fact part of the data model." @@ -4654,32 +4619,32 @@ msgstr "" "Estos métodos son llamados para implementar las asignaciones aritméticas " "aumentadas (``+=``, ``-=``, ``*=``, ``@=``, ``/=``, ``//=``, ``%=``, " "``**=``, ``<<=``, ``>>=``, ``&=``, ``^=``, ``|=``). Estos métodos deben " -"intentar realizar la operación *in-place* (modificando *self*) y retornar el" -" resultado (que puede, pero no tiene que ser *self*). Si un método " -"específico no es definido, la asignación aumentada regresa a los métodos " -"normales. Por ejemplo, si *x* es la instancia de una clase con el método " -":meth:`__iadd__`, ``x += y`` es equivalente a ``x = x.__iadd__(y)``. De lo " -"contrario ``x.__add__(y)`` y ``y.__radd__(x)`` se consideran al igual que " -"con la evaluación de ``x + y``. En ciertas situaciones, asignaciones " -"aumentadas pueden resultar en errores no esperados (ver :ref:`faq-augmented-" -"assignment-tuple-error`), pero este comportamiento es en realidad parte del " -"modelo de datos." +"intentar realizar la operación *in-place* (modificando *self*) y retornar el " +"resultado (que puede, pero no tiene que ser *self*). Si un método específico " +"no es definido, la asignación aumentada regresa a los métodos normales. Por " +"ejemplo, si *x* es la instancia de una clase con el método :meth:`__iadd__`, " +"``x += y`` es equivalente a ``x = x.__iadd__(y)``. De lo contrario ``x." +"__add__(y)`` y ``y.__radd__(x)`` se consideran al igual que con la " +"evaluación de ``x + y``. En ciertas situaciones, asignaciones aumentadas " +"pueden resultar en errores no esperados (ver :ref:`faq-augmented-assignment-" +"tuple-error`), pero este comportamiento es en realidad parte del modelo de " +"datos." #: ../Doc/reference/datamodel.rst:2852 msgid "" -"Called to implement the unary arithmetic operations (``-``, ``+``, " -":func:`abs` and ``~``)." +"Called to implement the unary arithmetic operations (``-``, ``+``, :func:" +"`abs` and ``~``)." msgstr "" "Es llamado para implementar las operaciones aritméticas unarias (``-``, " "``+``, :func:`abs` and ``~``)." #: ../Doc/reference/datamodel.rst:2865 msgid "" -"Called to implement the built-in functions :func:`complex`, :func:`int` and " -":func:`float`. Should return a value of the appropriate type." +"Called to implement the built-in functions :func:`complex`, :func:`int` and :" +"func:`float`. Should return a value of the appropriate type." msgstr "" -"Es llamado para implementar las funciones incorporadas :func:`complex`, " -":func:`int` y :func:`float`. Debe retornar un valor del tipo apropiado." +"Es llamado para implementar las funciones incorporadas :func:`complex`, :" +"func:`int` y :func:`float`. Debe retornar un valor del tipo apropiado." #: ../Doc/reference/datamodel.rst:2872 msgid "" @@ -4691,19 +4656,19 @@ msgid "" msgstr "" "Es llamado para implementar :func:`operator.index`, y cuando sea que Python " "necesite convertir sin pérdidas el objeto numérico a un objeto entero (tal " -"como en la segmentación o *slicing*, o las funciones incorporadas " -":func:`bin`, :func:`hex` y :func:`oct`). La presencia de este método indica " -"que el objeto numérico es un tipo entero. Debe retornar un entero." +"como en la segmentación o *slicing*, o las funciones incorporadas :func:" +"`bin`, :func:`hex` y :func:`oct`). La presencia de este método indica que el " +"objeto numérico es un tipo entero. Debe retornar un entero." #: ../Doc/reference/datamodel.rst:2878 msgid "" "If :meth:`__int__`, :meth:`__float__` and :meth:`__complex__` are not " -"defined then corresponding built-in functions :func:`int`, :func:`float` and" -" :func:`complex` fall back to :meth:`__index__`." +"defined then corresponding built-in functions :func:`int`, :func:`float` " +"and :func:`complex` fall back to :meth:`__index__`." msgstr "" "Si :meth:`__int__`, :meth:`__float__` y :meth:`__complex__` no son " -"definidos, entonces todas las funciones incorporadas correspondientes " -":func:`int`, :func:`float` y :func:`complex` vuelven a :meth:`__index__`." +"definidos, entonces todas las funciones incorporadas correspondientes :func:" +"`int`, :func:`float` y :func:`complex` vuelven a :meth:`__index__`." #: ../Doc/reference/datamodel.rst:2890 msgid "" @@ -4714,15 +4679,15 @@ msgid "" "(typically an :class:`int`)." msgstr "" "Es llamado para implementar la función incorporada :func:`round` y las " -"funciones :mod:`math` :func:`~math.trunc`, :func:`~math.floor` y " -":func:`~math.ceil`. A menos que *ndigits* sea pasado a :meth:`!__round__` " -"todos estos métodos deben retornar el valor del objeto truncado a " -":class:`~numbers.Integral` (normalmente :class:`int`)." +"funciones :mod:`math` :func:`~math.trunc`, :func:`~math.floor` y :func:" +"`~math.ceil`. A menos que *ndigits* sea pasado a :meth:`!__round__` todos " +"estos métodos deben retornar el valor del objeto truncado a :class:`~numbers." +"Integral` (normalmente :class:`int`)." #: ../Doc/reference/datamodel.rst:2896 msgid "" -"The built-in function :func:`int` falls back to :meth:`__trunc__` if neither" -" :meth:`__int__` nor :meth:`__index__` is defined." +"The built-in function :func:`int` falls back to :meth:`__trunc__` if " +"neither :meth:`__int__` nor :meth:`__index__` is defined." msgstr "" "La función integrada :func:`int` recurre a :meth:`__trunc__` si no se " "definen ni :meth:`__int__` ni :meth:`__index__`." @@ -4737,20 +4702,20 @@ msgstr "Gestores de Contexto en la Declaración *with*" #: ../Doc/reference/datamodel.rst:2908 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" -" handles the entry into, and the exit from, the desired runtime context for " +"A :dfn:`context manager` is an object that defines the runtime context to be " +"established when executing a :keyword:`with` statement. The context manager " +"handles the entry into, and the exit from, the desired runtime context for " "the execution of the block of code. Context managers are normally invoked " -"using the :keyword:`!with` statement (described in section :ref:`with`), but" -" can also be used by directly invoking their methods." +"using the :keyword:`!with` statement (described in section :ref:`with`), but " +"can also be used by directly invoking their methods." msgstr "" "Un :dfn:`context manager` es un objeto que define el contexto en tiempo de " -"ejecución a ser establecido cuando se ejecuta una declaración " -":keyword:`with`. El gestor de contexto maneja la entrada y la salida del " -"contexto en tiempo de ejecución deseado para la ejecución del bloque de " -"código. Los gestores de contexto son normalmente invocados utilizando la " -"declaración :keyword:`!with` (descritos en la sección :ref:`with`), pero " -"también pueden ser utilizados al invocar directamente sus métodos." +"ejecución a ser establecido cuando se ejecuta una declaración :keyword:" +"`with`. El gestor de contexto maneja la entrada y la salida del contexto en " +"tiempo de ejecución deseado para la ejecución del bloque de código. Los " +"gestores de contexto son normalmente invocados utilizando la declaración :" +"keyword:`!with` (descritos en la sección :ref:`with`), pero también pueden " +"ser utilizados al invocar directamente sus métodos." #: ../Doc/reference/datamodel.rst:2919 msgid "" @@ -4765,14 +4730,14 @@ msgstr "" msgid "" "For more information on context managers, see :ref:`typecontextmanager`." msgstr "" -"Para más información sobre gestores de contexto, ver " -":ref:`typecontextmanager`." +"Para más información sobre gestores de contexto, ver :ref:" +"`typecontextmanager`." #: ../Doc/reference/datamodel.rst:2927 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" -" the :keyword:`!as` clause of the statement, if any." +"statement will bind this method's return value to the target(s) specified in " +"the :keyword:`!as` clause of the statement, if any." msgstr "" "Ingresa al contexto en tiempo de ejecución relacionado con este objeto. La " "declaración :keyword:`with` ligará el valor de retorno de este método al " @@ -4781,8 +4746,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2934 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 " +"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 " "without an exception, all three arguments will be :const:`None`." msgstr "" "Sale del contexto en tiempo de ejecución relacionado a este objeto. Los " @@ -4791,8 +4756,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2938 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. " +"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. " "Otherwise, the exception will be processed normally upon exit from this " "method." msgstr "" @@ -4825,14 +4790,14 @@ msgstr "" #: ../Doc/reference/datamodel.rst:2956 msgid "Customizing positional arguments in class pattern matching" msgstr "" -"Personalización de argumentos posicionales en la coincidencia de patrones de" -" clase" +"Personalización de argumentos posicionales en la coincidencia de patrones de " +"clase" #: ../Doc/reference/datamodel.rst:2958 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" -" without special support in ``MyClass``. To be able to use that kind of " +"are not allowed by default, i.e. ``case MyClass(x, y)`` is typically invalid " +"without special support in ``MyClass``. To be able to use that kind of " "pattern, the class needs to define a *__match_args__* attribute." msgstr "" "Cuando se utiliza un nombre de clase en un patrón, los argumentos " @@ -4846,8 +4811,8 @@ 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 " "will be converted into a keyword argument, using the corresponding value in " -"*__match_args__* as the keyword. The absence of this attribute is equivalent" -" to setting it to ``()``." +"*__match_args__* as the keyword. The absence of this attribute is equivalent " +"to setting it to ``()``." msgstr "" "A esta variable de clase se le puede asignar una tupla de cadenas. Cuando " "esta clase se utiliza en un patrón de clase con argumentos posicionales, " @@ -4861,14 +4826,14 @@ msgid "" "\"right\")`` that means that ``case MyClass(x, y)`` is equivalent to ``case " "MyClass(left=x, center=y)``. Note that the number of arguments in the " "pattern must be smaller than or equal to the number of elements in " -"*__match_args__*; if it is larger, the pattern match attempt will raise a " -":exc:`TypeError`." +"*__match_args__*; if it is larger, the pattern match attempt will raise a :" +"exc:`TypeError`." msgstr "" "Por ejemplo, si ``MyClass.__match_args__`` es ``(\"left\", \"center\", " "\"right\")`` eso significa que ``case MyClass(x, y)`` es equivalente a " "``case MyClass(left=x, center=y)``. Ten en cuenta que el número de " -"argumentos en el patrón debe ser menor o igual que el número de elementos en" -" *__match_args__*; si es más grande, el intento de coincidencia de patrón " +"argumentos en el patrón debe ser menor o igual que el número de elementos en " +"*__match_args__*; si es más grande, el intento de coincidencia de patrón " "producirá un :exc:`TypeError`." #: ../Doc/reference/datamodel.rst:2981 @@ -4885,16 +4850,16 @@ msgstr "Emulando tipos de búfer" #: ../Doc/reference/datamodel.rst:2990 msgid "" -"The :ref:`buffer protocol ` provides a way for Python objects" -" to expose efficient access to a low-level memory array. This protocol is " -"implemented by builtin types such as :class:`bytes` and :class:`memoryview`," -" and third-party libraries may define additional buffer types." +"The :ref:`buffer protocol ` provides a way for Python objects " +"to expose efficient access to a low-level memory array. This protocol is " +"implemented by builtin types such as :class:`bytes` and :class:`memoryview`, " +"and third-party libraries may define additional buffer types." msgstr "" ":ref:`buffer protocol ` proporciona una forma para que los " "objetos Python expongan un acceso eficiente a una matriz de memoria de bajo " -"nivel. Este protocolo se implementa mediante tipos integrados como " -":class:`bytes` y :class:`memoryview`, y bibliotecas de terceros pueden " -"definir tipos de búfer adicionales." +"nivel. Este protocolo se implementa mediante tipos integrados como :class:" +"`bytes` y :class:`memoryview`, y bibliotecas de terceros pueden definir " +"tipos de búfer adicionales." #: ../Doc/reference/datamodel.rst:2995 msgid "" @@ -4906,28 +4871,27 @@ msgstr "" #: ../Doc/reference/datamodel.rst:3000 msgid "" -"Called when a buffer is requested from *self* (for example, by the " -":class:`memoryview` constructor). The *flags* argument is an integer " -"representing the kind of buffer requested, affecting for example whether the" -" returned buffer is read-only or writable. :class:`inspect.BufferFlags` " -"provides a convenient way to interpret the flags. The method must return a " -":class:`memoryview` object." +"Called when a buffer is requested from *self* (for example, by the :class:" +"`memoryview` constructor). The *flags* argument is an integer representing " +"the kind of buffer requested, affecting for example whether the returned " +"buffer is read-only or writable. :class:`inspect.BufferFlags` provides a " +"convenient way to interpret the flags. The method must return a :class:" +"`memoryview` object." msgstr "" "Se llama cuando se solicita un búfer desde *self* (por ejemplo, por el " "constructor :class:`memoryview`). El argumento *flags* es un número entero " "que representa el tipo de búfer solicitado y afecta, por ejemplo, si el " -"búfer retornado es de solo lectura o de escritura. " -":class:`inspect.BufferFlags` proporciona una manera conveniente de " -"interpretar las banderas. El método debe retornar un objeto " -":class:`memoryview`." +"búfer retornado es de solo lectura o de escritura. :class:`inspect." +"BufferFlags` proporciona una manera conveniente de interpretar las banderas. " +"El método debe retornar un objeto :class:`memoryview`." #: ../Doc/reference/datamodel.rst:3009 msgid "" -"Called when a buffer is no longer needed. The *buffer* argument is a " -":class:`memoryview` object that was previously returned by " -":meth:`~object.__buffer__`. The method must release any resources associated" -" with the buffer. This method should return ``None``. Buffer objects that do" -" not need to perform any cleanup are not required to implement this method." +"Called when a buffer is no longer needed. The *buffer* argument is a :class:" +"`memoryview` object that was previously returned by :meth:`~object." +"__buffer__`. The method must release any resources associated with the " +"buffer. This method should return ``None``. Buffer objects that do not need " +"to perform any cleanup are not required to implement this method." msgstr "" "Se llama cuando ya no se necesita un búfer. El argumento *buffer* es un " "objeto :class:`memoryview` que :meth:`~object.__buffer__` retornó " @@ -4980,15 +4944,15 @@ msgid "" msgstr "" "La razón detrás de este comportamiento radica en una serie de métodos " "especiales, como :meth:`~object.__hash__` y :meth:`~object.__repr__`, que " -"implementan todos los objetos, incluidos los objetos de tipo. Si la búsqueda" -" implícita de estos métodos utilizara el proceso de búsqueda convencional, " +"implementan todos los objetos, incluidos los objetos de tipo. Si la búsqueda " +"implícita de estos métodos utilizara el proceso de búsqueda convencional, " "fallarían cuando se invocaran en el objeto de tipo mismo:" #: ../Doc/reference/datamodel.rst:3060 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" -" the instance when looking up special methods::" +"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 " +"the instance when looking up special methods::" msgstr "" "Intentar invocar de manera incorrecta el método no ligado de una clase de " "esta forma a veces es denominado como ‘confusión de metaclase’, y se evita " @@ -4997,8 +4961,8 @@ msgstr "" #: ../Doc/reference/datamodel.rst:3069 msgid "" "In addition to bypassing any instance attributes in the interest of " -"correctness, implicit special method lookup generally also bypasses the " -":meth:`~object.__getattribute__` method even of the object's metaclass::" +"correctness, implicit special method lookup generally also bypasses the :" +"meth:`~object.__getattribute__` method even of the object's metaclass::" msgstr "" "Además de omitir cualquier atributo de instancia en aras de la corrección, " "la búsqueda implícita de métodos especiales generalmente también omite el " @@ -5028,29 +4992,29 @@ msgstr "Objetos esperables" #: ../Doc/reference/datamodel.rst:3112 msgid "" -"An :term:`awaitable` object generally implements an " -":meth:`~object.__await__` method. :term:`Coroutine objects ` " -"returned from :keyword:`async def` functions are awaitable." +"An :term:`awaitable` object generally implements an :meth:`~object." +"__await__` method. :term:`Coroutine objects ` returned from :" +"keyword:`async def` functions are awaitable." msgstr "" -"Un objeto :term:`awaitable` generalmente implementa un método " -":meth:`~object.__await__`. :term:`Coroutine objects ` retornado " -"por las funciones :keyword:`async def` están a la espera." +"Un objeto :term:`awaitable` generalmente implementa un método :meth:`~object." +"__await__`. :term:`Coroutine objects ` retornado por las " +"funciones :keyword:`async def` están a la espera." #: ../Doc/reference/datamodel.rst:3118 msgid "" "The :term:`generator iterator` objects returned from generators decorated " -"with :func:`types.coroutine` are also awaitable, but they do not implement " -":meth:`~object.__await__`." +"with :func:`types.coroutine` are also awaitable, but they do not implement :" +"meth:`~object.__await__`." msgstr "" "Los objetos :term:`generator iterator` retornados por generadores decorados " -"con :func:`types.coroutine` también están a la espera, pero no implementan " -":meth:`~object.__await__`." +"con :func:`types.coroutine` también están a la espera, pero no implementan :" +"meth:`~object.__await__`." #: ../Doc/reference/datamodel.rst:3124 msgid "" -"Must return an :term:`iterator`. Should be used to implement " -":term:`awaitable` objects. For instance, :class:`asyncio.Future` implements" -" this method to be compatible with the :keyword:`await` expression." +"Must return an :term:`iterator`. Should be used to implement :term:" +"`awaitable` objects. For instance, :class:`asyncio.Future` implements this " +"method to be compatible with the :keyword:`await` expression." msgstr "" "Debe retornar un :term:`iterator`. Debe ser utilizado para implementar " "objetos :term:`awaitable`. Por ejemplo, :class:`asyncio.Future` implementa " @@ -5060,8 +5024,8 @@ msgstr "" msgid "" "The language doesn't place any restriction on the type or value of the " "objects yielded by the iterator returned by ``__await__``, as this is " -"specific to the implementation of the asynchronous execution framework (e.g." -" :mod:`asyncio`) that will be managing the :term:`awaitable` object." +"specific to the implementation of the asynchronous execution framework (e." +"g. :mod:`asyncio`) that will be managing the :term:`awaitable` object." msgstr "" "El lenguaje no impone ninguna restricción sobre el tipo o valor de los " "objetos generados por el iterador retornado por ``__await__``, ya que esto " @@ -5079,21 +5043,21 @@ msgstr "Objetos de corrutina" #: ../Doc/reference/datamodel.rst:3146 msgid "" ":term:`Coroutine objects ` are :term:`awaitable` objects. A " -"coroutine's execution can be controlled by calling :meth:`~object.__await__`" -" and iterating over the result. When the coroutine has finished executing " -"and returns, the iterator raises :exc:`StopIteration`, and the exception's " -":attr:`~StopIteration.value` attribute holds the return value. If the " -"coroutine raises an exception, it is propagated by the iterator. Coroutines" -" should not directly raise unhandled :exc:`StopIteration` exceptions." +"coroutine's execution can be controlled by calling :meth:`~object.__await__` " +"and iterating over the result. When the coroutine has finished executing " +"and returns, the iterator raises :exc:`StopIteration`, and the exception's :" +"attr:`~StopIteration.value` attribute holds the return value. If the " +"coroutine raises an exception, it is propagated by the iterator. Coroutines " +"should not directly raise unhandled :exc:`StopIteration` exceptions." msgstr "" ":term:`Coroutine objects ` son objetos :term:`awaitable`. La " -"ejecución de una corrutina se puede controlar llamando a " -":meth:`~object.__await__` e iterando sobre el resultado. Cuando la rutina " -"termina de ejecutarse y regresa, el iterador genera :exc:`StopIteration` y " -"el atributo :attr:`~StopIteration.value` de la excepción contiene el valor " -"de retorno. Si la rutina genera una excepción, el iterador la propaga. Las " -"corrutinas no deberían generar directamente excepciones :exc:`StopIteration`" -" no controladas." +"ejecución de una corrutina se puede controlar llamando a :meth:`~object." +"__await__` e iterando sobre el resultado. Cuando la rutina termina de " +"ejecutarse y regresa, el iterador genera :exc:`StopIteration` y el atributo :" +"attr:`~StopIteration.value` de la excepción contiene el valor de retorno. Si " +"la rutina genera una excepción, el iterador la propaga. Las corrutinas no " +"deberían generar directamente excepciones :exc:`StopIteration` no " +"controladas." #: ../Doc/reference/datamodel.rst:3154 msgid "" @@ -5114,39 +5078,38 @@ msgstr "" #: ../Doc/reference/datamodel.rst:3164 msgid "" "Starts or resumes execution of the coroutine. If *value* is ``None``, this " -"is equivalent to advancing the iterator returned by " -":meth:`~object.__await__`. If *value* is not ``None``, this method " -"delegates to the :meth:`~generator.send` method of the iterator that caused " -"the coroutine to suspend. The result (return value, :exc:`StopIteration`, " -"or other exception) is the same as when iterating over the :meth:`__await__`" -" return value, described above." +"is equivalent to advancing the iterator returned by :meth:`~object." +"__await__`. If *value* is not ``None``, this method delegates to the :meth:" +"`~generator.send` method of the iterator that caused the coroutine to " +"suspend. The result (return value, :exc:`StopIteration`, or other " +"exception) is the same as when iterating over the :meth:`__await__` return " +"value, described above." msgstr "" "Inicia o reanuda la ejecución de la corrutina. Si *value* es ``None``, esto " "equivale a avanzar el iterador retornado por :meth:`~object.__await__`. Si " -"*value* no es ``None``, este método delega en el método " -":meth:`~generator.send` del iterador que provocó la suspensión de la rutina." -" El resultado (valor de retorno, :exc:`StopIteration` u otra excepción) es " -"el mismo que cuando se itera sobre el valor de retorno :meth:`__await__`, " -"descrito anteriormente." +"*value* no es ``None``, este método delega en el método :meth:`~generator." +"send` del iterador que provocó la suspensión de la rutina. El resultado " +"(valor de retorno, :exc:`StopIteration` u otra excepción) es el mismo que " +"cuando se itera sobre el valor de retorno :meth:`__await__`, descrito " +"anteriormente." #: ../Doc/reference/datamodel.rst:3175 msgid "" "Raises the specified exception in the coroutine. This method delegates to " "the :meth:`~generator.throw` method of the iterator that caused the " "coroutine to suspend, if it has such a method. Otherwise, the exception is " -"raised at the suspension point. The result (return value, " -":exc:`StopIteration`, or other exception) is the same as when iterating over" -" the :meth:`~object.__await__` return value, described above. If the " -"exception is not caught in the coroutine, it propagates back to the caller." +"raised at the suspension point. The result (return value, :exc:" +"`StopIteration`, or other exception) is the same as when iterating over the :" +"meth:`~object.__await__` return value, described above. If the exception is " +"not caught in the coroutine, it propagates back to the caller." msgstr "" "Genera la excepción especificada en la corrutina. Este método delega al " -"método :meth:`~generator.throw` del iterador que provocó la suspensión de la" -" rutina, si tiene dicho método. En caso contrario, la excepción se plantea " -"en el punto de suspensión. El resultado (valor de retorno, " -":exc:`StopIteration` u otra excepción) es el mismo que cuando se itera sobre" -" el valor de retorno :meth:`~object.__await__`, descrito anteriormente. Si " -"la excepción no queda atrapada en la rutina, se propaga de nuevo a la " -"persona que llama." +"método :meth:`~generator.throw` del iterador que provocó la suspensión de la " +"rutina, si tiene dicho método. En caso contrario, la excepción se plantea en " +"el punto de suspensión. El resultado (valor de retorno, :exc:`StopIteration` " +"u otra excepción) es el mismo que cuando se itera sobre el valor de retorno :" +"meth:`~object.__await__`, descrito anteriormente. Si la excepción no queda " +"atrapada en la rutina, se propaga de nuevo a la persona que llama." #: ../Doc/reference/datamodel.rst:3186 msgid "" @@ -5162,20 +5125,20 @@ msgid "" "suspended, this method first delegates to the :meth:`~generator.close` " "method of the iterator that caused the coroutine to suspend, if it has such " "a method. Then it raises :exc:`GeneratorExit` at the suspension point, " -"causing the coroutine to immediately clean itself up. Finally, the coroutine" -" is marked as having finished executing, even if it was never started." +"causing the coroutine to immediately clean itself up. Finally, the coroutine " +"is marked as having finished executing, even if it was never started." msgstr "" "Causa que la corrutina misma se borre a sí misma y termine su ejecución. Si " -"la corrutina es suspendida, este método primero delega a " -":meth:`~generator.close`, si existe, del iterador que causó la suspensión de" -" la corrutina. Luego lanza una excepción :exc:`GeneratorExit` en el punto de" -" suspensión, causando que la corrutina se borre a sí misma. Finalmente, la " -"corrutina es marcada como completada, aún si nunca inició." +"la corrutina es suspendida, este método primero delega a :meth:`~generator." +"close`, si existe, del iterador que causó la suspensión de la corrutina. " +"Luego lanza una excepción :exc:`GeneratorExit` en el punto de suspensión, " +"causando que la corrutina se borre a sí misma. Finalmente, la corrutina es " +"marcada como completada, aún si nunca inició." #: ../Doc/reference/datamodel.rst:3199 msgid "" -"Coroutine objects are automatically closed using the above process when they" -" are about to be destroyed." +"Coroutine objects are automatically closed using the above process when they " +"are about to be destroyed." msgstr "" "Objetos de corrutina son cerrados automáticamente utilizando el proceso " "anterior cuando están a punto de ser destruidos." @@ -5196,8 +5159,8 @@ msgstr "" msgid "" "Asynchronous iterators can be used in an :keyword:`async for` statement." msgstr "" -"Iteradores asíncronos pueden ser utilizados en la declaración " -":keyword:`async for`." +"Iteradores asíncronos pueden ser utilizados en la declaración :keyword:" +"`async for`." #: ../Doc/reference/datamodel.rst:3214 msgid "Must return an *asynchronous iterator* object." @@ -5222,19 +5185,19 @@ msgid "" "that would resolve to an :term:`asynchronous iterator `." msgstr "" -"Antes de Python 3.7, :meth:`~object.__aiter__` podía retornar un *awaitable*" -" que se resolvería en un :term:`asynchronous iterator `." #: ../Doc/reference/datamodel.rst:3243 msgid "" "Starting with Python 3.7, :meth:`~object.__aiter__` must return an " -"asynchronous iterator object. Returning anything else will result in a " -":exc:`TypeError` error." +"asynchronous iterator object. Returning anything else will result in a :exc:" +"`TypeError` error." msgstr "" "A partir de Python 3.7, :meth:`~object.__aiter__` debe retornar un objeto " -"iterador asincrónico. Retornar cualquier otra cosa resultará en un error " -":exc:`TypeError`." +"iterador asincrónico. Retornar cualquier otra cosa resultará en un error :" +"exc:`TypeError`." #: ../Doc/reference/datamodel.rst:3251 msgid "Asynchronous Context Managers" @@ -5253,13 +5216,13 @@ msgid "" "Asynchronous context managers can be used in an :keyword:`async with` " "statement." msgstr "" -"Los gestores de contexto asíncronos pueden ser utilizados en una declaración" -" :keyword:`async with`." +"Los gestores de contexto asíncronos pueden ser utilizados en una " +"declaración :keyword:`async with`." #: ../Doc/reference/datamodel.rst:3260 msgid "" -"Semantically similar to :meth:`__enter__`, the only difference being that it" -" must return an *awaitable*." +"Semantically similar to :meth:`__enter__`, the only difference being that it " +"must return an *awaitable*." msgstr "" "Semánticamente similar a :meth:`__enter__`, siendo la única diferencia que " "debe retorna un *esperable*." @@ -5287,28 +5250,27 @@ msgid "" "lead to some very strange behaviour if it is handled incorrectly." msgstr "" "Es posible cambiar en algunos casos un tipo de objeto bajo ciertas " -"circunstancias controladas. Generalmente no es buena idea, ya que esto puede" -" llevar a un comportamiento bastante extraño de no ser tratado " -"correctamente." +"circunstancias controladas. Generalmente no es buena idea, ya que esto puede " +"llevar a un comportamiento bastante extraño de no ser tratado correctamente." #: ../Doc/reference/datamodel.rst:3286 msgid "" -"The :meth:`~object.__hash__`, :meth:`~object.__iter__`, " -":meth:`~object.__reversed__`, and :meth:`~object.__contains__` methods have " -"special handling for this; others will still raise a :exc:`TypeError`, but " -"may do so by relying on the behavior that ``None`` is not callable." +"The :meth:`~object.__hash__`, :meth:`~object.__iter__`, :meth:`~object." +"__reversed__`, and :meth:`~object.__contains__` methods have special " +"handling for this; others will still raise a :exc:`TypeError`, but may do so " +"by relying on the behavior that ``None`` is not callable." msgstr "" -"Los métodos :meth:`~object.__hash__`, :meth:`~object.__iter__`, " -":meth:`~object.__reversed__` y :meth:`~object.__contains__` tienen un manejo" -" especial para esto; otros seguirán generando un :exc:`TypeError`, pero " +"Los métodos :meth:`~object.__hash__`, :meth:`~object.__iter__`, :meth:" +"`~object.__reversed__` y :meth:`~object.__contains__` tienen un manejo " +"especial para esto; otros seguirán generando un :exc:`TypeError`, pero " "pueden hacerlo confiando en el comportamiento de que ``None`` no es " "invocable." #: ../Doc/reference/datamodel.rst:3292 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" -" want to force fallback to the right operand's reflected method—that will " +"method returns ``NotImplemented``. Do not set the method to ``None`` if you " +"want to force fallback to the right operand's reflected method—that will " "instead have the opposite effect of explicitly *blocking* such fallback." msgstr "" "“No soporta” aquí significa que la clase no tiene tal método, o el método " @@ -5323,8 +5285,8 @@ msgid "" "method -- such as :meth:`~object.__add__` -- fails then the overall " "operation is not supported, which is why the reflected method is not called." msgstr "" -"Para operandos del mismo tipo, se supone que si el método no reflejado (como" -" :meth:`~object.__add__`) falla, entonces la operación general no es " +"Para operandos del mismo tipo, se supone que si el método no reflejado " +"(como :meth:`~object.__add__`) falla, entonces la operación general no es " "compatible, razón por la cual no se llama al método reflejado." #: ../Doc/reference/datamodel.rst:14 ../Doc/reference/datamodel.rst:148