8000 feat: Update bucketing library by Hellebore · Pull Request #2 · sourcery-ai-experiments/python-server-sdk · GitHub
[go: up one dir, main page]

Skip to content

feat: Update bucketing library#2

Open
Hellebore wants to merge 8 commits intobase-sha/ed3644f7a424d0daf703cc802e0124dc2d2a9961from
head-sha/da3e36cb602d15f9bbd762d736dbc4864debab00/2024-05-17T08-33-27/7d89fc
Open

feat: Update bucketing library#2
Hellebore wants to merge 8 commits intobase-sha/ed3644f7a424d0daf703cc802e0124dc2d2a9961from
head-sha/da3e36cb602d15f9bbd762d736dbc4864debab00/2024-05-17T08-33-27/7d89fc

Conversation

@Hellebore
Copy link

No description provided.

@Hellebore
Copy link
Author

This is an experiment review for experiment review_of_reviews_20240515
Run ID: review_of_reviews_20240515/run_2024-05-17T08-31-16_v1-18-0-44-g4e567da0c-dirty
The benchmark review for this pull request can be found at #1.
This pull request was cloned from https://github.com/DevCycleHQ/python-server-sdk/pull/67. (Note: the URL is not a link to avoid triggering a notification on the original pull request.)

Experiment configuration
review_config:
  # User configuration for the review
  # - benchmark - use the user config from the benchmark reviews
  # - <value> - use the value directly
  user_review_config:
    enable_ai_review: true
    enable_rule_comments: false

    enable_complexity_comments: benchmark
    enable_docstring_comments: benchmark
    enable_security_comments: benchmark
    enable_tests_comments: benchmark
    enable_comment_suggestions: benchmark
    enable_functionality_review: benchmark

    enable_approvals: true

  ai_review_config:
    # The model responses to use for the experiment
    # - benchmark - use the model responses from the benchmark reviews
    # - llm - call the language model to generate responses
    model_responses:
      comments_model: llm
      comment_validation_model: llm
      comment_suggestion_model: llm
      complexity_model: llm
      docstrings_model: llm
      functionality_model: llm
      security_model: llm
      tests_model: llm

# The pull request dataset to run the experiment on
pull_request_dataset:
- https://github.com/adbar/shoten/pull/7
- https://github.com/javierriveracastro/betteroll-swade/pull/715
- https://github.com/nbhirud/system_update/pull/38
- https://github.com/nbhirud/system_update/pull/39
- https://github.com/nbhirud/system_update/pull/40
- https://github.com/AdamOswald/PKHeX/pull/9
- https://github.com/okisdev/ChatChat/pull/326
- https://github.com/DevCycleHQ/js-sdks/pull/856
- https://github.com/DevCycleHQ/python-server-sdk/pull/67
- https://github.com/duyet/clickhouse-monitoring/pull/236
- https://github.com/Nuitka/Nuitka/pull/2855
- https://github.com/xbinner18/Japanese-X-Userbot/pull/1
- https://github.com/xbinner18/Japanese-X-Userbot/pull/2
- https://github.com/xbinner18/Japanese-X-Userbot/pull/3
- https://github.com/Remi-Gau/reproschema-demo-protocol/pull/1
- https://github.com/badd9yang/StyleSVC/pull/1
- https://github.com/nuxeo/nuxeo-drive/pull/4871
- https://github.com/kevingreenman/chemprop/pull/15
- https://github.com/kevingreenman/chemprop/pull/16
- https://github.com/allthingslinux/tux/pull/222
- https://github.com/kloudlite/operator/pull/187
- https://github.com/gdsfactory/gdsfactory/pull/2739
- https://github.com/gdsfactory/gdsfactory/pull/2741
- https://github.com/gdsfactory/gdsfactory/pull/2742
- https://github.com/gdsfactory/gdsfactory/pull/2743
- https://github.com/gdsfactory/gdsfactory/pull/2745
- https://github.com/gdsfactory/gdsfactory/pull/2746
- https://github.com/gdsfactory/ubc/pull/382
- https://github.com/gdsfactory/gdsfactory/pull/2747
- https://github.com/gdsfactory/gplugins/pull/401
- https://github.com/gdsfactory/gdsfactory/pull/2748
- https://github.com/osama1998H/spms/pull/60
- https://github.com/osama1998H/spms/pull/61
- https://github.com/osama1998H/spms/pull/62
- https://github.com/Stagietechs/data.home-assistant/pull/1
- https://github.com/erxes/erxes/pull/5206
- https://github.com/wearypossum4770/vue-times-news/pull/1
- https://github.com/wearypossum4770/vue-times-news/pull/2
- https://github.com/wearypossum4770/vue-times-news/pull/3
- https://github.com/W-zrd/unishare_mobile/pull/15
- https://github.com/W-zrd/unishare_mobile/pull/16
- https://github.com/elifdy/omopsurvey/pull/3
- https://github.com/phenobarbital/asyncdb/pull/1097
- https://github.com/Xmaster6y/lczerolens/pull/17
- https://github.com/PickwickSoft/pystreamapi/pull/91
- https://github.com/martimlobao/regybox/pull/113
- https://github.com/phenobarbital/asyncdb/pull/1091
- https://github.com/phenobarbital/asyncdb/pull/1092
- https://github.com/phenobarbital/asyncdb/pull/1093
- https://github.com/christian80gabi/skills-github-pages/pull/1
review_comment_labels:
- label: correct
  question: Is this comment correct?
- label: helpful
  question: Is this comment helpful?
- label: comment-type
  question: Is the comment type correct?
- label: comment-area
  question: Is the comment area correct?
- label: llm-test
  question: |
    What type of LLM test could this comment become?
    - 👍 - this comment is really good/important and we should always make it
    - 👎 - this comment is really bad and we should never make it
    - no reaction - don't turn this comment into an LLM test

# Benchmark reviews generated by running
#   python -m scripts.experiment benchmark <experiment_name>
benchmark_reviews:
- dataset_pull_request: https://github.com/adbar/shoten/pull/7
  review_pull_request: https://github.com/sourcery-ai-experiments/shoten/pull/1
- dataset_pull_request: https://github.com/javierriveracastro/betteroll-swade/pull/715
  review_pull_request: https://github.com/sourcery-ai-experiments/betteroll-swade/pull/1
- dataset_pull_request: https://github.com/nbhirud/system_update/pull/38
  review_pull_request: https://github.com/sourcery-ai-experiments/system_update/pull/20
- dataset_pull_request: https://github.com/nbhirud/system_update/pull/39
  review_pull_request: https://github.com/sourcery-ai-experiments/system_update/pull/19
- dataset_pull_request: https://github.com/nbhirud/system_update/pull/40
  review_pull_request: https://github.com/sourcery-ai-experiments/system_update/pull/18
- dataset_pull_request: https://github.com/DevCycleHQ/js-sdks/pull/856
  review_pull_request: https://github.com/sourcery-ai-experiments/js-sdks/pull/2
- dataset_pull_request: https://github.com/DevCycleHQ/python-server-sdk/pull/67
  review_pull_request: https://github.com/sourcery-ai-experiments/python-server-sdk/pull/1
- dataset_pull_request: https://github.com/duyet/clickhouse-monitoring/pull/236
  review_pull_request: https://github.com/sourcery-ai-experiments/clickhouse-monitoring/pull/1
- dataset_pull_request: https://github.com/xbinner18/Japanese-X-Userbot/pull/1
  review_pull_request: https://github.com/sourcery-ai-experiments/Japanese-X-Userbot/pull/1
- dataset_pull_request: https://github.com/xbinner18/Japanese-X-Userbot/pull/2
  review_pull_request: https://github.com/sourcery-ai-experiments/Japanese-X-Userbot/pull/2
- dataset_pull_request: https://github.com/xbinner18/Japanese-X-Userbot/pull/3
  review_pull_request: https://github.com/sourcery-ai-experiments/Japanese-X-Userbot/pull/3
- dataset_pull_request: https://github.com/kevingreenman/chemprop/pull/15
  review_pull_request: https://github.com/sourcery-ai-experiments/chemprop/pull/1
- dataset_pull_request: https://github.com/kevingreenman/chemprop/pull/16
  review_pull_request: https://github.com/sourcery-ai-experiments/chemprop/pull/2
- dataset_pull_request: https://github.com/allthingslinux/tux/pull/222
  review_pull_request: https://github.com/sourcery-ai-experiments/tux/pull/3
- dataset_pull_request: https://github.com/kloudlite/operator/pull/187
  review_pull_request: https://github.com/sourcery-ai-experiments/operator/pull/20
- dataset_pull_request: https://github.com/Stagietechs/data.home-assistant/pull/1
  review_pull_request: https://github.com/sourcery-ai-experiments/data.home-assistant/pull/1
- dataset_pull_request: https://github.com/W-zrd/unishare_mobile/pull/16
  review_pull_request: https://github.com/sourcery-ai-experiments/unishare_mobile/pull/23
- dataset_pull_request: https://github.com/phenobarbital/asyncdb/pull/1092
  review_pull_request: https://github.com/sourcery-ai-experiments/asyncdb/pull/3

Copy link
@SourceryAI SourceryAI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @Hellebore - I've reviewed your changes and they look great!

Here's what I looked at during the review
  • 🟡 General issues: 2 issues found
  • 🟢 Security: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good

LangSmith trace

Help me be more useful! Please click 👍 or 👎 on each comment to tell me if it was helpful.

@staticmethod
def create_user_from_context(context: EvaluationContext) -> "DevCycleUser":
def create_user_from_context(
context: Optional[EvaluationContext],

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: Consider adding a type hint for the return value.

Adding a type hint for the return value of the create_user_from_context method would improve code readability and help with static analysis.

Suggested change
context: Optional[EvaluationContext],
from typing import Optional
@staticmethod
def create_user_from_context(
context: Optional[EvaluationContext],
) -> "DevCycleUser":

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this comment correct?

10BC0 Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this comment helpful?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the comment type correct?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the comment area correct?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What type of LLM test could this comment become?

  • 👍 - this comment is really good/important and we should always make it
  • 👎 - this comment is really bad and we should never make it
  • no reaction - don't turn this comment into an LLM test

if "edgeDB" in data
else None,
opt_in=OptInSettings.from_json(data["optIn"]) if "optIn" in data else None,
disable_passthrough_rollouts=data.get("disablePassthroughRollouts", False),

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

question: Default value for disable_passthrough_rollouts might be misleading.

Setting the default value of disable_passthrough_rollouts to False might be misleading if the absence of this key should imply a different default behavior. Consider explicitly documenting this behavior or revisiting the default value.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this comment correct?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this comment helpful?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the comment type correct?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the comment area correct?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What type of LLM test could this comment become?

  • 👍 - this comment is really good/important and we should always make it
  • 👎 - this comment is really bad and we should never make it
  • no reaction - don't turn this comment into an LLM test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

0