Ticket #1627: typos.diff

File typos.diff, 9.8 KB (added by dexter@…, 18 years ago)
  • django/db/models/manipulators.py

     
    260260            if self.opts.one_to_one_field:
    261261                # Sanity check -- Make sure the "parent" object exists.
    262262                # For example, make sure the Place exists for the Restaurant.
    263                 # Let the ObjectDoesNotExist exception propogate up.
     263                # Let the ObjectDoesNotExist exception propagate up.
    264264                lookup_kwargs = self.opts.one_to_one_field.rel.limit_choices_to
    265265                lookup_kwargs['%s__exact' % self.opts.one_to_one_field.rel.field_name] = obj_key
    266266                self.opts.one_to_one_field.rel.to.get_model_module().get(**lookup_kwargs)
  • django/db/models/fields/__init__.py

     
    4141
    4242# A guide to Field parameters:
    4343#
    44 #   * name:      The name of the field specifed in the model.
     44#   * name:      The name of the field specified in the model.
    4545#   * attname:   The attribute to use on the model object. This is the same as
    4646#                "name", except in the case of ForeignKeys, where "_id" is
    4747#                appended.
  • django/db/models/query.py

     
    268268        """
    269269        assert kind in ("month", "year", "day"), "'kind' must be one of 'year', 'month' or 'day'."
    270270        assert order in ('ASC', 'DESC'), "'order' must be either 'ASC' or 'DESC'."
    271         # Let the FieldDoesNotExist exception propogate.
     271        # Let the FieldDoesNotExist exception propagate.
    272272        field = self.model._meta.get_field(field_name, many_to_many=False)
    273273        assert isinstance(field, DateField), "%r isn't a DateField." % field_name
    274274        return self._clone(klass=DateQuerySet, _field=field, _kind=kind, _order=order)
  • django/core/servers/basehttp.py

     
    4646        raise StopIteration
    4747
    4848# Regular expression that matches `special' characters in parameters, the
    49 # existance of which force quoting of the parameter value.
     49# existence of which force quoting of the parameter value.
    5050tspecials = re.compile(r'[ \(\)<>@,;:\\"/\[\]\?=]')
    5151
    5252def _formatparam(param, value=None, quote=1):
  • django/core/management.py

     
    119119    # but don't exist physically
    120120    not_installed_models = set(pending_references.keys())
    121121    if not_installed_models:
    122         final_output.append('-- The following references should be added but depend on non-existant tables:')
     122        final_output.append('-- The following references should be added but depend on non-existent tables:')
    123123        for klass in not_installed_models:
    124124            final_output.extend(['-- ' + sql for sql in
    125125                _get_sql_for_pending_references(klass, pending_references)])
     
    247247    from django.db import backend, connection, models, get_introspection_module
    248248    introspection = get_introspection_module()
    249249
    250     # This should work even if a connecton isn't available
     250    # This should work even if a connection isn't available
    251251    try:
    252252        cursor = connection.cursor()
    253253    except:
  • django/utils/_threading_local.py

     
    149149            raise TypeError("Initialization arguments are not supported")
    150150
    151151        # We need to create the thread dict in anticipation of
    152         # __init__ being called, to make sire we don't cal it
     152        # __init__ being called, to make sure we don't call it
    153153        # again ourselves.
    154154        dict = object.__getattribute__(self, '__dict__')
    155155        currentThread().__dict__[key] = dict
  • django/contrib/admin/templatetags/admin_list.py

     
    8080            if field_name == '__str__':
    8181                header = lookup_opts.verbose_name
    8282            else:
    83                 attr = getattr(cl.model, field_name) # Let AttributeErrors propogate.
     83                attr = getattr(cl.model, field_name) # Let AttributeErrors propagate.
    8484                try:
    8585                    header = attr.short_description
    8686                except AttributeError:
  • tests/modeltests/basic/models.py

     
    330330
    331331API_TESTS += """
    332332
    333 # You can manually specify the primary key when creating a new objet
     333# You can manually specify the primary key when creating a new object
    334334>>> a101 = Article(id=101, headline='Article 101', pub_date=datetime(2005, 7, 31, 12, 30, 45))
    335335>>> a101.save()
    336336>>> a101 = Article.objects.get(pk=101)
  • tests/modeltests/transactions/models.py

     
    3636[Alice Smith]
    3737
    3838# the autocommit decorator works exactly the same as the default behavior
    39 >>> autocomitted_create_then_fail = transaction.autocommit(create_a_reporter_then_fail)
    40 >>> autocomitted_create_then_fail("Ben", "Jones")
     39>>> autocommitted_create_then_fail = transaction.autocommit(create_a_reporter_then_fail)
     40>>> autocommitted_create_then_fail("Ben", "Jones")
    4141Traceback (most recent call last):
    4242    ...
    4343Exception: I meant to do that
     
    4646>>> Reporter.objects.all()
    4747[Alice Smith, Ben Jones]
    4848
    49 # With the commit_on_success decorator, the transaction is only comitted if the
     49# With the commit_on_success decorator, the transaction is only committed if the
    5050# function doesn't throw an exception
    5151>>> committed_on_success = transaction.commit_on_success(create_a_reporter_then_fail)
    5252>>> committed_on_success("Carol", "Doe")
     
    6363...     r = Reporter.objects.get(first_name="Alice")
    6464...     r.delete()
    6565...
    66 >>> remove_comitted_on_success = transaction.commit_on_success(remove_a_reporter)
    67 >>> remove_comitted_on_success()
     66>>> remove_committed_on_success = transaction.commit_on_success(remove_a_reporter)
     67>>> remove_committed_on_success()
    6868>>> Reporter.objects.all()
    6969[Ben Jones]
    7070
     
    8989Traceback (most recent call last):
    9090    ...
    9191TransactionManagementError: Transaction managed block ended with pending COMMIT/ROLLBACK
    92 """
    93  No newline at end of file
     92"""
  • tests/othertests/templates.py

     
    149149    'basic-syntax33': (r'1{{ var.method3 }}2', {"var": SomeClass()}, "12"),
    150150
    151151    # In methods that raise an exception without a "silent_variable_attribute" set to True,
    152     # the exception propogates
     152    # the exception propagates
    153153    'basic-syntax34': (r'1{{ var.method4 }}2', {"var": SomeClass()}, SomeOtherException),
    154154
    155155    ### COMMENT TAG ###########################################################
  • tests/othertests/cache.py

     
    1515cache.set("key", "value")
    1616assert cache.get("key") == "value"
    1717
    18 # get with non-existant keys
     18# get with non-existent keys
    1919assert cache.get("does not exist") is None
    2020assert cache.get("does not exist", "bang!") == "bang!"
    2121
     
    5757# expiration
    5858cache.set('expire', 'very quickly', 1)
    5959time.sleep(2)
    60 assert cache.get("expire") == None
    61  No newline at end of file
     60assert cache.get("expire") == None
  • tests/doctest.py

     
    846846        if extraglobs is not None:
    847847            globs.update(extraglobs)
    848848
    849         # Recursively expore `obj`, extracting DocTests.
     849        # Recursively explore `obj`, extracting DocTests.
    850850        tests = []
    851851        self._find(tests, obj, name, module, source_lines, globs, {})
    852852        return tests
     
    12101210        # Process each example.
    12111211        for examplenum, example in enumerate(test.examples):
    12121212
    1213             # If REPORT_ONLY_FIRST_FAILURE is set, then supress
     1213            # If REPORT_ONLY_FIRST_FAILURE is set, then suppress
    12141214            # reporting after the first failure.
    12151215            quiet = (self.optionflags & REPORT_ONLY_FIRST_FAILURE and
    12161216                     failures > 0)
  • docs/modpython.txt

     
    190190==============
    191191
    192192When you use Apache/mod_python, errors will be caught by Django -- in other
    193 words, they won't propogate to the Apache level and won't appear in the Apache
     193words, they won't propagate to the Apache level and won't appear in the Apache
    194194``error_log``.
    195195
    196196The exception for this is if something is really wonky in your Django setup. In
Back to Top