获取答案点赞用户，返回生成器.

        :return: 点赞用户
        :rtype: Author.Iterable
499154
def upvoters(self):
        
        self._make_soup()
        next_req = '/answer/' + str(self.aid) + '/voters_profile'
        while next_req != '':
            data = self._session.get(Zhihu_URL + next_req).json()
            next_req = data['paging']['next']
            for html in data['payload']:
                soup = BeautifulSoup(html)
                yield self._parse_author_soup(soup)
136740
def list_authors():
    """"""
    authors = Author.query.all()
    content = '<p>Authors:</p>'
    for author in authors:
        content += '<p>%s</p>' % author.name
    return content
1026606
def serializeInstitution(self):
        
        institution_data = []
        institution_instance_data = []
        affiliation_data = []
        affiliation_id = tethnedao.getMaxAffiliationID()
        institution_id = tethnedao.getMaxInstitutionID()
        institution_instance_id = tethnedao.getMaxInstitutionInstanceID()

        for paper in self.corpus:
            if hasattr(paper, 'authorAddress'):
                paper_key = getattr(paper, Serialize.paper_source_map[self.source])
                if type(paper.authorAddress) is unicode:
                    institution_id += 1
                    institution_instance_id += 1
                    institute_literal, authors = SerializeUtility.get_auth_inst(paper.authorAddress)
                    institute_row, institute_instance_row = self.get_details_from_inst_literal(institute_literal,
                                                                                               institution_id,
                                                                                               institution_instance_id,
                                                                                               paper_key)
                    if institute_row:
                        institution_data.append(institute_row)
                    institution_instance_data.append(institute_instance_row)
                    if authors:
                        for author in authors:
                            affiliation_id += 1
                            affiliation_row = self.get_affiliation_details(author, affiliation_id, institute_literal)
                            affiliation_data.append(affiliation_row)

                elif type(paper.authorAddress) is list:
                    for address in paper.authorAddress:
                        institution_id += 1
                        institution_instance_id += 1
                        institute_literal, authors = SerializeUtility.get_auth_inst(address)
                        institute_row, institute_instance_row = self.get_details_from_inst_literal(institute_literal,
                                                                                                   institution_id,
                                                                                                   institution_instance_id,
                                                                                                   paper_key)
                        if institute_row:
                            institution_data.append(institute_row)
                        institution_instance_data.append(institute_instance_row)
                        if authors is None:
                            authors = prevAuthors
                        for author in authors:
                            affiliation_id += 1
                            affiliation_row = self.get_affiliation_details(author, affiliation_id, institute_literal)
                            affiliation_data.append(affiliation_row)
                        prevAuthors = authors
        return institution_data, institution_instance_data, affiliation_data
714028
def generate_authors():
    
    print('Generating AUTHORS')

    # Get our list of authors
    print('Collecting author names')
    r = subprocess.Popen(['git', 'log', '--use-mailmap', '--format=%aN'],
                         stdout=subprocess.PIPE)
    seen_authors = []
    authors = []
    for authfile in ('AUTHORS', 'AUTHORS.rst'):
        if os.path.exists(authfile):
            break
    with open(authfile, 'r') as f:
        for line in f.readlines():
            if line.startswith("*"):
                author = force_text(line).strip("* \n")
                if author.lower() not in seen_authors:
                    seen_authors.append(author.lower())
                    authors.append(author)
    for author in r.stdout.readlines():
        author = force_text(author).strip()
        if author.lower() not in seen_authors:
            seen_authors.append(author.lower())
            authors.append(author)

    # Sort our list of Authors by their case insensitive name
    authors = sorted(authors, key=lambda x: x.lower())

    # Write our authors to the AUTHORS file
    print('Authors (%s):\n\n\n* %s' % (len(authors), '\n* '.join(authors)))
130111
def _parse_authors(authors):
    
    link = authors.find("a")
    link = link[0].params.get("href") if link else None

    author_list = _strip_content(authors)

    if "(" in author_list:
        author_list = author_list.split("(")[0]

    if not author_list.strip():
        return []

    return map(
        lambda author: Author(author.strip(), link),
        author_list.strip().split(",")
    )
570997
def author_mail_from_system(self):
        
        self.author_mail = getpass.getuser() + '@' + socket.gethostname()
        return self.author_mail
1368653
def postprocess_authors_init(self, entry):
        
        if type(entry.authors_init) is not list:
            entry.authors_init = [entry.authors_init]
1046923
function author() {
      function _author(auth) {
        var format;
        if (typeof auth === 'string') {
          return auth;
        }
        format = require('util').format;
        return format('%s <%s>', auth.name, auth.email);
      }

      if (Array.isArray(pkg.author)) {
        return pkg.author.map(function makeAuthor(auth) {
          return _author(auth);
        }).join(', ');
      }
      return _author(pkg.author);
    }
446306
def get_new_author(self, api_author):
        
        return Author(site_id=self.site_id,
                      wp_id=api_author["ID"],
                      **self.api_object_data("author", api_author))
237013
def full_author_notes(soup, fntype_filter=None):
    
    notes = []

    author_notes_section = raw_parser.author_notes(soup)
    if author_notes_section:
        fn_nodes = raw_parser.fn(author_notes_section)
        notes = footnotes(fn_nodes, fntype_filter)

    return notes
553278
def top_authors(self):
        
        from .author import Author, ANONYMOUS
        self._make_soup()
        t = self.soup.find('div', id='zh-topic-top-answerer')
        if t is None:
            return
        for d in t.find_all('div', class_='zm-topic-side-person-item-content'):
            url = Zhihu_URL + d.a['href']
            name = d.a.text
            motto = d.find('span', class_='bio')['title']
            try:
                yield Author(url, name, motto, session=self._session)
            except ValueError:  # invalid url
                yield ANONYMOUS
784411
def create_authors(project_dir=os.curdir):
    
    pkg_info_file = os.path.join(project_dir, 'PKG-INFO')
    authors_file = os.path.join(project_dir, 'AUTHORS')
    if os.path.exists(pkg_info_file):
        return

    authors = get_authors(project_dir=project_dir)
    with open(authors_file, 'wb') as authors_fd:
        authors_fd.write(
            b'\n'.join(a.encode('utf-8') for a in authors) + b'\n'
        )
522387
def authors(self):
        '''
            
        '''
        qs = self._valid_submissions().values_list('authors',flat=True).distinct()
        return qs
606890
def authors():
    
    fmt_re = re.compile(r'([^<]+) <([^>]+)>')
    authors = local('git shortlog -s -e -n | cut -f 2-', capture=True)
    with open('AUTHORS', 'w') as fh:
        fh.write('Project contributors\n')
        fh.write('====================\n\n')
        for line in authors.splitlines():
            match = fmt_re.match(line)
            name, email = match.groups()
            if email in env.ignored_authors:
                continue
            fh.write(' * ')
            fh.write(line)
            fh.write('\n')
484316
def author(self):
        
        from .author import Author, ANONYMOUS

        logs = self._query_logs()
        author_a = logs[-1].find_all('div')[0].a
        if author_a.text == '匿名用户':
            return ANONYMOUS
        else:
            url = Zhihu_URL + author_a['href']
            return Author(url, name=author_a.text, session=self._session)
768759
def author(self) -> Developer:
        
        return Developer(self._c_object.author.name,
                         self._c_object.author.email)
119397
def author(self):
        
        if self.api and self.author_id:
            return self.api._get_user(self.author_id)