Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(12)  |  Call(8)  |  Derive(0)  |  Import(4)

src/b/n/bnw-HEAD/bnw/xmpp/formatters_simple.py   bnw(Download)
import datetime
from bnw.core.base import get_webui_base
 
formatters = {
    'comment': None,
         'rc': msg['replycount'],
         'text': msg['text'],
         'web': get_webui_base(request.user),
         }
    return result
            'text': msg['text'],
            'date': datetime.datetime.utcfromtimestamp(msg['date']).strftime('%d.%m.%Y %H:%M:%S'),
            'web': get_webui_base(request.user),
            }
    formatstring = ('' if short else 'Reply by ') + '@%(author)s:\n'

src/b/n/bnw-HEAD/bnw/xmpp/formatters_redeye.py   bnw(Download)
import datetime
from bnw.core.base import get_webui_base
 
formatters = {
    'comment': None,
    result += '\n%s\n' % (msg['text'],)
    result += '--- %(id)s (%(rc)d) %(base_url)s/p/%(id)s' % {
        'base_url': get_webui_base(request.user),
        'id': msg['id'].upper(),
        'rc': msg['replycount'],
            'num': msg.get('num', -1),
            'date': datetime.datetime.utcfromtimestamp(msg['date']).strftime('%d.%m.%Y %H:%M:%S'),
            'web': get_webui_base(request.user),
            }
    formatstring = '+++ [ %(date)s ] %(author)s'
        out.append('@%s: %s (%s%%)\n%s\n\n#%s %s/p/%s' % (
            res['user'], res['tags_info'], res['percent'], res['text'],
            res['id'], get_webui_base(request.user),
            res['id'].replace('/', '#')))
    return '\n\n'.join(out)

src/b/n/bnw-HEAD/bnw/handlers/command_post.py   bnw(Download)
import random
import time
from bnw.core.base import BnwResponse, get_webui_base
import bnw.core.bnw_objects as objs
from bnw.core.post import publish
                     desc='Message #%s has been delivered '
                          'to %d users. %s/p/%s' % (
                     msgid, recepients, get_webui_base(request.user),
                     msgid),
                     id=msgid))
                          'to %d users. %s/p/%s' % (
                     msgid, num, recepients, get_webui_base(
                     request.user),
                     msgid.replace('/', '#')),
                     id=msgid,

src/b/n/bnw-HEAD/bnw/handlers/command_login.py   bnw(Download)
# -*- coding: utf-8 -*-
# from twisted.words.xish import domish
 
from base import *
from bnw.core.base import get_webui_base
        ok=True,
        desc='%s/login?key=%s' % (
            get_webui_base(request.user),
            request.user.get('login_key', '')))