<commit_before># Copyright (c) 2016-2017 <NAME>, <NAME>.
#
# Licensed under the BSD 3-Clause License
# <LICENSE.rst or https://opensource.org/licenses/BSD-3-Clause>.
# This file may not be copied, modified, or distributed except
# according to those terms.

import os

from bugzilla import *
from string import Template

from .base import BaseTracker


class BugzillaReport(BaseTracker):

    def __init__(self, product, url, template, title=None):
        BaseTracker.__init__(self, template=template, title=title)
        self.product = product
        self.bzapi = Bugzilla(url)

    @property
    def logged_in(self):
        return self.bzapi.user

    def login(self, username, pwd):
        try:
            self.bzapi.login(user=username, password=<PASSWORD>)
            return True<commit_msg>Remove unused import from bugzilla.py.<commit_after># Copyright (c) 2016-2018 <NAME>, <NAME>.
#
# Licensed under the BSD 3-Clause License
# <LICENSE.rst or https://opensource.org/licenses/BSD-3-Clause>.
# This file may not be copied, modified, or distributed except
# according to those terms.

import os

from bugzilla import *

from .base import BaseTracker


class BugzillaReport(BaseTracker):

    def __init__(self, product, url, template, title=None):
        BaseTracker.__init__(self, template=template, title=title)
        self.product = product
        self.bzapi = Bugzilla(url)

    @property
    def logged_in(self):
        return self.bzapi.user

    def login(self, username, pwd):
        try:
            self.bzapi.login(user=username, password=<PASSWORD>)
            return True
{'fraction_non_alphanumeric': 0.10230817217716781, 'fraction_numerical': 0.012476606363069246, 'mean_word_length': 3.2546419098143238, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 11, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3603104', 'n_tokens_mistral': 496, 'n_tokens_neox': 458, 'n_words': 141}