desc stringlengths 3 26.7k | decl stringlengths 11 7.89k | bodies stringlengths 8 553k |
|---|---|---|
'Set a bunch of values in the cache at once. For certain backends
(memcached), this is much more efficient than calling delete() multiple
times.'
| def delete_many(self, keys):
| for key in keys:
self.delete(key)
|
'Remove *all* values from the cache at once.'
| def clear(self):
| raise NotImplementedError
|
'Warn about keys that would not be portable to the memcached
backend. This encourages (but does not force) writing backend-portable
cache code.'
| def validate_key(self, key):
| if (len(key) > MEMCACHE_MAX_KEY_LENGTH):
warnings.warn(('Cache key will cause errors if used with memcached: %s (longer than %s)' % (key, MEMCACHE_MAX_KEY_LENGTH)), CacheKeyWarning)
for char in key:
if ((ord(char) < 33) or (ord(char) == 127)):
warn... |
'Convert the filename into an md5 string. We\'ll turn the first couple
bits of the path into directory prefixes to be nice to filesystems
that have problems with large numbers of files in a directory.
Thus, a cache key of "foo" gets turnned into a file named
``{cache-dir}ac/bd/18db4cc2f85cedef654fccc4a4d8``.'
| def _key_to_file(self, key):
| path = md5_constructor(key.encode('utf-8')).hexdigest()
path = os.path.join(path[:2], path[2:4], path[4:])
return os.path.join(self._dir, path)
|
'Memcached deals with long (> 30 days) timeouts in a special
way. Call this function to obtain a safe value for your timeout.'
| def _get_memcache_timeout(self, timeout):
| timeout = (timeout or self.default_timeout)
if (timeout > 2592000):
timeout += int(time.time())
return timeout
|
'Validates that the input matches the regular expression.'
| def __call__(self, value):
| if (not self.regex.search(smart_unicode(value))):
raise ValidationError(self.message, code=self.code)
|
'Called to manually configure the settings. The \'default_settings\'
parameter sets where to retrieve any unspecified values from (its
argument must support attribute access (__getattr__)).'
| def configure(self, default_settings=global_settings, **options):
| self.holder = UserSettingsHolder(default_settings)
for (name, value) in options.items():
setattr(self.holder, name, value)
|
'Requests for configuration variables not in this class are satisfied
from the module specified in default_settings (if possible).'
| def __init__(self, default_settings):
| self.default_settings = default_settings
|
'Tests that 1 + 1 always equals 2.'
| def test_basic_addition(self):
| self.failUnlessEqual((1 + 1), 2)
|
'Display stage -- can be called many times'
| def render(self, context):
| context.render_context.push()
try:
return self._render(context)
finally:
context.render_context.pop()
|
'Return a list of tokens from a given template_string.'
| def tokenize(self):
| in_tag = False
result = []
for bit in tag_re.split(self.template_string):
if bit:
result.append(self.create_token(bit, in_tag))
in_tag = (not in_tag)
return result
|
'Convert the given token string into a new Token object and return it.
If in_tag is True, we are processing something that matched a tag,
otherwise it should be treated as a literal string.'
| def create_token(self, token_string, in_tag):
| if in_tag:
if token_string.startswith(VARIABLE_TAG_START):
token = Token(TOKEN_VAR, token_string[len(VARIABLE_TAG_START):(- len(VARIABLE_TAG_END))].strip())
elif token_string.startswith(BLOCK_TAG_START):
token = Token(TOKEN_BLOCK, token_string[len(BLOCK_TAG_START):(- len(BLOC... |
'Convenient wrapper for FilterExpression'
| def compile_filter(self, token):
| return FilterExpression(token, self)
|
'Overload this method to do the actual parsing and return the result.'
| def top(self):
| raise NotImplementedError()
|
'Returns True if there is more stuff in the tag.'
| def more(self):
| return (self.pointer < len(self.subject))
|
'Undoes the last microparser. Use this for lookahead and backtracking.'
| def back(self):
| if (not len(self.backout)):
raise TemplateSyntaxError('back called without some previous parsing')
self.pointer = self.backout.pop()
|
'A microparser that just returns the next tag from the line.'
| def tag(self):
| subject = self.subject
i = self.pointer
if (i >= len(subject)):
raise TemplateSyntaxError(('expected another tag, found end of string: %s' % subject))
p = i
while ((i < len(subject)) and (subject[i] not in (' ', ' DCTB '))):
i += 1
s = subject[p:i]
whi... |
'A microparser that parses for a value: some string constant or variable name.'
| def value(self):
| subject = self.subject
i = self.pointer
def next_space_index(subject, i):
'Increment pointer until a real space (i.e. a space not within quotes) is encountered'
while ((i < len(subject)) and (subject[i] not in (' ', ' DCTB '))):
if (subje... |
'Resolve this variable against a given context.'
| def resolve(self, context):
| if (self.lookups is not None):
value = self._resolve_lookup(context)
else:
value = self.literal
if self.translate:
return ugettext_lazy(value)
return value
|
'Performs resolution of a real variable (i.e. not a literal) against the
given context.
As indicated by the method\'s name, this method is an implementation
detail and shouldn\'t be called by external code. Use Variable.resolve()
instead.'
| def _resolve_lookup(self, context):
| current = context
for bit in self.lookups:
try:
current = current[bit]
except (TypeError, AttributeError, KeyError):
try:
current = getattr(current, bit)
if callable(current):
if getattr(current, 'alters_data', False):
... |
'Return the node rendered as a string'
| def render(self, context):
| pass
|
'Return a list of all nodes (within this node and its nodelist) of the given type'
| def get_nodes_by_type(self, nodetype):
| nodes = []
if isinstance(self, nodetype):
nodes.append(self)
for attr in self.child_nodelists:
nodelist = getattr(self, attr, None)
if nodelist:
nodes.extend(nodelist.get_nodes_by_type(nodetype))
return nodes
|
'Return a list of all nodes of the given type'
| def get_nodes_by_type(self, nodetype):
| nodes = []
for node in self:
nodes.extend(node.get_nodes_by_type(nodetype))
return nodes
|
'Returns a tuple containing the source and origin for the given template
name.'
| def load_template_source(self, template_name, template_dirs=None):
| raise NotImplementedError
|
'Resets any state maintained by the loader instance (e.g., cached
templates or cached loader modules).'
| def reset(self):
| pass
|
'Empty the template cache.'
| def reset(self):
| self.template_cache.clear()
|
'Loads templates from Python eggs via pkg_resource.resource_string.
For every installed app, it tries to get the resource (app, template_name).'
| def load_template_source(self, template_name, template_dirs=None):
| if (resource_string is not None):
pkg_name = ('templates/' + template_name)
for app in settings.INSTALLED_APPS:
try:
return (resource_string(app, pkg_name).decode(settings.FILE_CHARSET), ('egg:%s:%s' % (app, pkg_name)))
except:
pass
raise T... |
'Returns the absolute paths to "template_name", when appended to each
directory in "template_dirs". Any paths that don\'t lie inside one of the
template dirs are excluded from the result set, for security reasons.'
| def get_template_sources(self, template_name, template_dirs=None):
| if (not template_dirs):
template_dirs = settings.TEMPLATE_DIRS
for template_dir in template_dirs:
try:
(yield safe_join(template_dir, template_name))
except UnicodeDecodeError:
raise
except ValueError:
pass
|
'Returns the absolute paths to "template_name", when appended to each
directory in "template_dirs". Any paths that don\'t lie inside one of the
template dirs are excluded from the result set, for security reasons.'
| def get_template_sources(self, template_name, template_dirs=None):
| if (not template_dirs):
template_dirs = app_template_dirs
for template_dir in template_dirs:
try:
(yield safe_join(template_dir, template_name))
except UnicodeDecodeError:
raise
except ValueError:
pass
|
'Returns what to display in error messages for this node'
| def display(self):
| return self.id
|
'Set a variable in the current context'
| def __setitem__(self, key, value):
| self.dicts[(-1)][key] = value
|
'Get a variable\'s value, starting at the current context and going upward'
| def __getitem__(self, key):
| for d in reversed(self.dicts):
if (key in d):
return d[key]
raise KeyError(key)
|
'Delete a variable from the current context'
| def __delitem__(self, key):
| del self.dicts[(-1)][key]
|
'Like dict.update(). Pushes an entire dictionary\'s keys and values onto the context.'
| def update(self, other_dict):
| if (not hasattr(other_dict, '__getitem__')):
raise TypeError('other_dict must be a mapping (dictionary-like) object.')
self.dicts.append(other_dict)
return other_dict
|
'Return a list of tokens from a given template_string'
| def tokenize(self):
| (result, upto) = ([], 0)
for match in tag_re.finditer(self.template_string):
(start, end) = match.span()
if (start > upto):
result.append(self.create_token(self.template_string[upto:start], (upto, start), False))
upto = start
result.append(self.create_token(self.t... |
'Adds an item to the feed. All args are expected to be Python Unicode
objects except pubdate, which is a datetime.datetime object, and
enclosure, which is an instance of the Enclosure class.'
| def add_item(self, title, link, description, author_email=None, author_name=None, author_link=None, pubdate=None, comments=None, unique_id=None, enclosure=None, categories=(), item_copyright=None, ttl=None, **kwargs):
| to_unicode = (lambda s: force_unicode(s, strings_only=True))
if categories:
categories = [to_unicode(c) for c in categories]
if (ttl is not None):
ttl = force_unicode(ttl)
item = {'title': to_unicode(title), 'link': iri_to_uri(link), 'description': to_unicode(description), 'author_email'... |
'Return extra attributes to place on the root (i.e. feed/channel) element.
Called from write().'
| def root_attributes(self):
| return {}
|
'Add elements in the root (i.e. feed/channel) element. Called
from write().'
| def add_root_elements(self, handler):
| pass
|
'Return extra attributes to place on each item (i.e. item/entry) element.'
| def item_attributes(self, item):
| return {}
|
'Add elements on each item (i.e. item/entry) element.'
| def add_item_elements(self, handler, item):
| pass
|
'Outputs the feed in the given encoding to outfile, which is a file-like
object. Subclasses should override this.'
| def write(self, outfile, encoding):
| raise NotImplementedError
|
'Returns the feed in the given encoding as a string.'
| def writeString(self, encoding):
| from StringIO import StringIO
s = StringIO()
self.write(s, encoding)
return s.getvalue()
|
'Returns the latest item\'s pubdate. If none of them have a pubdate,
this returns the current date/time.'
| def latest_post_date(self):
| updates = [i['pubdate'] for i in self.items if (i['pubdate'] is not None)]
if (len(updates) > 0):
updates.sort()
return updates[(-1)]
else:
return datetime.datetime.now()
|
'All args are expected to be Python Unicode objects'
| def __init__(self, url, length, mime_type):
| (self.length, self.mime_type) = (length, mime_type)
self.url = iri_to_uri(url)
|
'Concatenating a safe string with another safe string or safe unicode
object is safe. Otherwise, the result is no longer safe.'
| def __add__(self, rhs):
| t = super(SafeString, self).__add__(rhs)
if isinstance(rhs, SafeUnicode):
return SafeUnicode(t)
elif isinstance(rhs, SafeString):
return SafeString(t)
return t
|
'Wrap a call to a normal unicode method up so that we return safe
results. The method that is being wrapped is passed in the \'method\'
argument.'
| def _proxy_method(self, *args, **kwargs):
| method = kwargs.pop('method')
data = method(self, *args, **kwargs)
if isinstance(data, str):
return SafeString(data)
else:
return SafeUnicode(data)
|
'Concatenating a safe unicode object with another safe string or safe
unicode object is safe. Otherwise, the result is no longer safe.'
| def __add__(self, rhs):
| t = super(SafeUnicode, self).__add__(rhs)
if isinstance(rhs, SafeData):
return SafeUnicode(t)
return t
|
'Wrap a call to a normal unicode method up so that we return safe
results. The method that is being wrapped is passed in the \'method\'
argument.'
| def _proxy_method(self, *args, **kwargs):
| method = kwargs.pop('method')
data = method(self, *args, **kwargs)
if isinstance(data, str):
return SafeString(data)
else:
return SafeUnicode(data)
|
'Returns a copy of this object.'
| def copy(self):
| return self.__copy__()
|
'Returns the value of the item at the given zero-based index.'
| def value_for_index(self, index):
| return self[self.keyOrder[index]]
|
'Inserts the key, value pair before the item with the given index.'
| def insert(self, index, key, value):
| if (key in self.keyOrder):
n = self.keyOrder.index(key)
del self.keyOrder[n]
if (n < index):
index -= 1
self.keyOrder.insert(index, key)
super(SortedDict, self).__setitem__(key, value)
|
'Returns a copy of this object.'
| def copy(self):
| obj = self.__class__(self)
obj.keyOrder = self.keyOrder[:]
return obj
|
'Replaces the normal dict.__repr__ with a version that returns the keys
in their sorted order.'
| def __repr__(self):
| return ('{%s}' % ', '.join([('%r: %r' % (k, v)) for (k, v) in self.items()]))
|
'Returns the last data value for this key, or [] if it\'s an empty list;
raises KeyError if not found.'
| def __getitem__(self, key):
| try:
list_ = super(MultiValueDict, self).__getitem__(key)
except KeyError:
raise MultiValueDictKeyError(('Key %r not found in %r' % (key, self)))
try:
return list_[(-1)]
except IndexError:
return []
|
'Returns the last data value for the passed key. If key doesn\'t exist
or value is an empty list, then default is returned.'
| def get(self, key, default=None):
| try:
val = self[key]
except KeyError:
return default
if (val == []):
return default
return val
|
'Returns the list of values for the passed key. If key doesn\'t exist,
then an empty list is returned.'
| def getlist(self, key):
| try:
return super(MultiValueDict, self).__getitem__(key)
except KeyError:
return []
|
'Appends an item to the internal list associated with key.'
| def appendlist(self, key, value):
| self.setlistdefault(key, [])
super(MultiValueDict, self).__setitem__(key, (self.getlist(key) + [value]))
|
'Returns a list of (key, value) pairs, where value is the last item in
the list associated with the key.'
| def items(self):
| return [(key, self[key]) for key in self.keys()]
|
'Yields (key, value) pairs, where value is the last item in the list
associated with the key.'
| def iteritems(self):
| for key in self.keys():
(yield (key, self[key]))
|
'Returns a list of (key, list) pairs.'
| def lists(self):
| return super(MultiValueDict, self).items()
|
'Yields (key, list) pairs.'
| def iterlists(self):
| return super(MultiValueDict, self).iteritems()
|
'Returns a list of the last value on every key list.'
| def values(self):
| return [self[key] for key in self.keys()]
|
'Yield the last value on every key list.'
| def itervalues(self):
| for key in self.iterkeys():
(yield self[key])
|
'Returns a copy of this object.'
| def copy(self):
| return self.__deepcopy__()
|
'update() extends rather than replaces existing key lists.
Also accepts keyword args.'
| def update(self, *args, **kwargs):
| if (len(args) > 1):
raise TypeError(('update expected at most 1 arguments, got %d' % len(args)))
if args:
other_dict = args[0]
if isinstance(other_dict, MultiValueDict):
for (key, value_list) in other_dict.lists():
self.setlistdefault(key,... |
'Retrieves the real value after stripping the prefix string (if
present). If the prefix is present, pass the value through self.func
before returning, otherwise return the raw value.'
| def __getitem__(self, key):
| if key.startswith(self.prefix):
use_func = True
key = key[len(self.prefix):]
else:
use_func = False
value = super(DictWrapper, self).__getitem__(key)
if use_func:
return self.func(value)
return value
|
'Convenience method for adding an element with no children'
| def addQuickElement(self, name, contents=None, attrs=None):
| if (attrs is None):
attrs = {}
self.startElement(name, attrs)
if (contents is not None):
self.characters(contents)
self.endElement(name)
|
'Constructs a new Node. If no connector is given, the default will be
used.
Warning: You probably don\'t want to pass in the \'negated\' parameter. It
is NOT the same as constructing a node and calling negate() on the
result.'
| def __init__(self, children=None, connector=None, negated=False):
| self.children = ((children and children[:]) or [])
self.connector = (connector or self.default)
self.subtree_parents = []
self.negated = negated
|
'This is called to create a new instance of this class when we need new
Nodes (or subclasses) in the internal code in this class. Normally, it
just shadows __init__(). However, subclasses with an __init__ signature
that is not an extension of Node.__init__ might need to implement this
method to allow a Node to create a... | def _new_instance(cls, children=None, connector=None, negated=False):
| obj = Node(children, connector, negated)
obj.__class__ = cls
return obj
|
'Utility method used by copy.deepcopy().'
| def __deepcopy__(self, memodict):
| obj = Node(connector=self.connector, negated=self.negated)
obj.__class__ = self.__class__
obj.children = deepcopy(self.children, memodict)
obj.subtree_parents = deepcopy(self.subtree_parents, memodict)
return obj
|
'The size of a node if the number of children it has.'
| def __len__(self):
| return len(self.children)
|
'For truth value testing.'
| def __nonzero__(self):
| return bool(self.children)
|
'Returns True is \'other\' is a direct child of this instance.'
| def __contains__(self, other):
| return (other in self.children)
|
'Adds a new node to the tree. If the conn_type is the same as the root\'s
current connector type, the node is added to the first level.
Otherwise, the whole tree is pushed down one level and a new root
connector is created, connecting the existing tree and the new node.'
| def add(self, node, conn_type):
| if ((node in self.children) and (conn_type == self.connector)):
return
if (len(self.children) < 2):
self.connector = conn_type
if (self.connector == conn_type):
if (isinstance(node, Node) and ((node.connector == conn_type) or (len(node) == 1))):
self.children.extend(node.... |
'Negate the sense of the root connector. This reorganises the children
so that the current node has a single child: a negated node containing
all the previous children. This slightly odd construction makes adding
new children behave more intuitively.
Interpreting the meaning of this negate is up to client code. This
me... | def negate(self):
| self.children = [self._new_instance(self.children, self.connector, (not self.negated))]
self.connector = self.default
|
'Sets up internal state so that new nodes are added to a subtree of the
current node. The conn_type specifies how the sub-tree is joined to the
existing children.'
| def start_subtree(self, conn_type):
| if (len(self.children) == 1):
self.connector = conn_type
elif (self.connector != conn_type):
self.children = [self._new_instance(self.children, self.connector, self.negated)]
self.connector = conn_type
self.negated = False
self.subtree_parents.append(self.__class__(self.child... |
'Closes off the most recently unmatched start_subtree() call.
This puts the current state into a node of the parent tree and returns
the current instances state to be the parent.'
| def end_subtree(self):
| obj = self.subtree_parents.pop()
node = self.__class__(self.children, self.connector)
self.connector = obj.connector
self.negated = obj.negated
self.children = obj.children
self.children.append(node)
|
'Must be implemented by subclasses to initialise the wrapped object.'
| def _setup(self):
| raise NotImplementedError
|
'Pass in a callable that returns the object to be wrapped.
If copies are made of the resulting SimpleLazyObject, which can happen
in various circumstances within Django, then you must ensure that the
callable can be safely run more than once and will return the same
value.'
| def __init__(self, func):
| self.__dict__['_setupfunc'] = func
self._wrapped = None
|
'Constructor for JSONEncoder, with sensible defaults.
If skipkeys is False, then it is a TypeError to attempt
encoding of keys that are not str, int, long, float or None. If
skipkeys is True, such items are simply skipped.
If ensure_ascii is True, the output is guaranteed to be str
objects with all incoming unicode ch... | def __init__(self, skipkeys=False, ensure_ascii=True, check_circular=True, allow_nan=True, sort_keys=False, indent=None, separators=None, encoding='utf-8', default=None):
| self.skipkeys = skipkeys
self.ensure_ascii = ensure_ascii
self.check_circular = check_circular
self.allow_nan = allow_nan
self.sort_keys = sort_keys
self.indent = indent
if (separators is not None):
(self.item_separator, self.key_separator) = separators
if (default is not None):
... |
'Implement this method in a subclass such that it returns
a serializable object for ``o``, or calls the base implementation
(to raise a ``TypeError``).
For example, to support arbitrary iterators, you could
implement default like this::
def default(self, o):
try:
iterable = iter(o)
except TypeError:
pass
else:
return l... | def default(self, o):
| raise TypeError(('%r is not JSON serializable' % (o,)))
|
'Return a JSON string representation of a Python data structure.
>>> JSONEncoder().encode({"foo": ["bar", "baz"]})
\'{"foo": ["bar", "baz"]}\''
| def encode(self, o):
| if isinstance(o, basestring):
if isinstance(o, str):
_encoding = self.encoding
if ((_encoding is not None) and (not (_encoding == 'utf-8'))):
o = o.decode(_encoding)
if self.ensure_ascii:
return encode_basestring_ascii(o)
else:
... |
'Encode the given object and yield each string
representation as available.
For example::
for chunk in JSONEncoder().iterencode(bigobject):
mysocket.write(chunk)'
| def iterencode(self, o, _one_shot=False):
| if self.check_circular:
markers = {}
else:
markers = None
if self.ensure_ascii:
_encoder = encode_basestring_ascii
else:
_encoder = encode_basestring
if (self.encoding != 'utf-8'):
def _encoder(o, _orig_encoder=_encoder, _encoding=self.encoding):
i... |
'``encoding`` determines the encoding used to interpret any ``str``
objects decoded by this instance (utf-8 by default). It has no
effect when decoding ``unicode`` objects.
Note that currently only encodings that are a superset of ASCII work,
strings of other encodings should be passed in as ``unicode``.
``object_hook... | def __init__(self, encoding=None, object_hook=None, parse_float=None, parse_int=None, parse_constant=None, strict=True):
| self.encoding = encoding
self.object_hook = object_hook
self.parse_float = (parse_float or float)
self.parse_int = (parse_int or int)
self.parse_constant = (parse_constant or _CONSTANTS.__getitem__)
self.strict = strict
self.parse_object = JSONObject
self.parse_array = JSONArray
self... |
'Return the Python representation of ``s`` (a ``str`` or ``unicode``
instance containing a JSON document)'
| def decode(self, s, _w=WHITESPACE.match):
| (obj, end) = self.raw_decode(s, idx=_w(s, 0).end())
end = _w(s, end).end()
if (end != len(s)):
raise ValueError(errmsg('Extra data', s, end, len(s)))
return obj
|
'Decode a JSON document from ``s`` (a ``str`` or ``unicode`` beginning
with a JSON document) and return a 2-tuple of the Python
representation and the index in ``s`` where the document ended.
This can be used to decode a JSON document from a string that may
have extraneous data at the end.'
| def raw_decode(self, s, idx=0):
| try:
(obj, end) = self.scan_once(s, idx)
except StopIteration:
raise ValueError('No JSON object could be decoded')
return (obj, end)
|
'\'a.m.\' or \'p.m.\''
| def a(self):
| if (self.data.hour > 11):
return _('p.m.')
return _('a.m.')
|
'\'AM\' or \'PM\''
| def A(self):
| if (self.data.hour > 11):
return _('PM')
return _('AM')
|
'Swatch Internet time'
| def B(self):
| raise NotImplementedError
|
'Time, in 12-hour hours and minutes, with minutes left off if they\'re
zero.
Examples: \'1\', \'1:30\', \'2:05\', \'2\'
Proprietary extension.'
| def f(self):
| if (self.data.minute == 0):
return self.g()
return (u'%s:%s' % (self.g(), self.i()))
|
'Hour, 12-hour format without leading zeros; i.e. \'1\' to \'12\''
| def g(self):
| if (self.data.hour == 0):
return 12
if (self.data.hour > 12):
return (self.data.hour - 12)
return self.data.hour
|
'Hour, 24-hour format without leading zeros; i.e. \'0\' to \'23\''
| def G(self):
| return self.data.hour
|
'Hour, 12-hour format; i.e. \'01\' to \'12\''
| def h(self):
| return (u'%02d' % self.g())
|
'Hour, 24-hour format; i.e. \'00\' to \'23\''
| def H(self):
| return (u'%02d' % self.G())
|
'Minutes; i.e. \'00\' to \'59\''
| def i(self):
| return (u'%02d' % self.data.minute)
|
'Time, in 12-hour hours, minutes and \'a.m.\'/\'p.m.\', with minutes left off
if they\'re zero and the strings \'midnight\' and \'noon\' if appropriate.
Examples: \'1 a.m.\', \'1:30 p.m.\', \'midnight\', \'noon\', \'12:30 p.m.\'
Proprietary extension.'
| def P(self):
| if ((self.data.minute == 0) and (self.data.hour == 0)):
return _('midnight')
if ((self.data.minute == 0) and (self.data.hour == 12)):
return _('noon')
return (u'%s %s' % (self.f(), self.a()))
|
'Seconds; i.e. \'00\' to \'59\''
| def s(self):
| return (u'%02d' % self.data.second)
|
'Microseconds'
| def u(self):
| return self.data.microsecond
|
'Month, textual, 3 letters, lowercase; e.g. \'jan\''
| def b(self):
| return MONTHS_3[self.data.month]
|
'ISO 8601 Format
Example : \'2008-01-02T10:30:00.000123\''
| def c(self):
| return self.data.isoformat()
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.