diff --git a/config/repository.yaml b/config/repository.yaml index 3b90b80..fe7b462 100644 --- a/config/repository.yaml +++ b/config/repository.yaml @@ -44,8 +44,7 @@ repositories: languages: - name: zh path: content/zh - labels: - - lang/zh + labels: [] - name: jp path: content/jp labels: diff --git a/errbot-plugin/Dockerfile b/errbot-plugin/Dockerfile index 54b4cb2..10812db 100644 --- a/errbot-plugin/Dockerfile +++ b/errbot-plugin/Dockerfile @@ -5,5 +5,5 @@ RUN /usr/local/bin/prepare.sh COPY config.py /errbot/ COPY transbot /errbot/plugins/transbot WORKDIR /errbot -VOLUME ["/errbot/data", "/errbot/config"] -CMD ["/usr/local/bin/entry.sh"] \ No newline at end of file +VOLUME ["/errbot/data", "/errbot/config", "/errbot/repository"] +CMD ["/usr/local/bin/entry.sh"] diff --git a/errbot-plugin/requirements.txt b/errbot-plugin/requirements.txt index 9884867..37e0620 100644 --- a/errbot-plugin/requirements.txt +++ b/errbot-plugin/requirements.txt @@ -2,4 +2,5 @@ PyGithub PyYAML markdown<3.0 sleekxmpp +python-telegram-bot==10.1.0 errbot[slack,telegram,IRC,hipchat] \ No newline at end of file diff --git a/errbot-plugin/transbot/transbot.py b/errbot-plugin/transbot/transbot.py index 21065bb..af4404c 100644 --- a/errbot-plugin/transbot/transbot.py +++ b/errbot-plugin/transbot/transbot.py @@ -61,11 +61,9 @@ def build_issue(trans, branch, item_list): skip_count += 1 else: new_count += 1 - yield ("New Issue: #{}: {}".format( - new_issue.number, new_issue.title)) if new_count >= MAX_WRITE: break - return new_count, skip_count + return new_count, skip_count def remote_repository_name(): diff --git a/transutil/transutil.py b/transutil/transutil.py index af9e277..6086e53 100644 --- a/transutil/transutil.py +++ b/transutil/transutil.py @@ -225,7 +225,7 @@ def create_issue(self, github_repository, title, body, labels=[], dupe = True break else: - if set(search_labels) & set(issue_record["labels"]) == set(search_labels): + if set(search_labels).issubset(issue_record["labels"]): dupe = True break