problem_id
stringlengths
18
22
source
stringclasses
1 value
task_type
stringclasses
1 value
in_source_id
stringlengths
13
58
prompt
stringlengths
1.1k
10.2k
golden_diff
stringlengths
151
4.94k
verification_info
stringlengths
582
21k
num_tokens
int64
271
2.05k
num_tokens_diff
int64
47
1.02k
gh_patches_debug_13037
rasdani/github-patches
git_diff
psf__black-2739
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Custom cache directory to be thread/process safe **Is your feature request related to a problem? Please describe.** The cache files are not thread/process safe. I've checked multiple projects simultaneousl...
diff --git a/src/black/cache.py b/src/black/cache.py --- a/src/black/cache.py +++ b/src/black/cache.py @@ -20,7 +20,23 @@ Cache = Dict[str, CacheInfo] -CACHE_DIR = Path(user_cache_dir("black", version=__version__)) +def get_cache_dir() -> Path: + """Get the cache directory used by black. + + Users can custom...
{"golden_diff": "diff --git a/src/black/cache.py b/src/black/cache.py\n--- a/src/black/cache.py\n+++ b/src/black/cache.py\n@@ -20,7 +20,23 @@\n Cache = Dict[str, CacheInfo]\n \n \n-CACHE_DIR = Path(user_cache_dir(\"black\", version=__version__))\n+def get_cache_dir() -> Path:\n+ \"\"\"Get the cache directory used by...
1,297
236
gh_patches_debug_1081
rasdani/github-patches
git_diff
mlcommons__GaNDLF-315
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Add an easy way to verify installation **Is your feature request related to a problem? Please describe.** Currently, we are asking users to run specific commands to verify installation, which can be cumburso...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -99,6 +99,7 @@ "gandlf_patchMiner", "gandlf_preprocess", "gandlf_anonymizer", + "gandlf_verifyInstall", ], classifiers=[ "Development Status :: 3 - Alpha",
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -99,6 +99,7 @@\n \"gandlf_patchMiner\",\n \"gandlf_preprocess\",\n \"gandlf_anonymizer\",\n+ \"gandlf_verifyInstall\",\n ],\n classifiers=[\n \"Development Status :: 3 - Alpha\",\n", "iss...
1,739
82
gh_patches_debug_27670
rasdani/github-patches
git_diff
crytic__slither-211
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Bug in function-id printer Hi there! There is an issue connected to `function-id` printer that I faced: when you create a dynamic array with `public` visibility modifier compiler automatically generates a ...
diff --git a/slither/printers/summary/function_ids.py b/slither/printers/summary/function_ids.py --- a/slither/printers/summary/function_ids.py +++ b/slither/printers/summary/function_ids.py @@ -3,6 +3,8 @@ """ import collections from prettytable import PrettyTable + +from slither.core.solidity_types import ArrayTyp...
{"golden_diff": "diff --git a/slither/printers/summary/function_ids.py b/slither/printers/summary/function_ids.py\n--- a/slither/printers/summary/function_ids.py\n+++ b/slither/printers/summary/function_ids.py\n@@ -3,6 +3,8 @@\n \"\"\"\n import collections\n from prettytable import PrettyTable\n+\n+from slither.core.so...
788
336
gh_patches_debug_5271
rasdani/github-patches
git_diff
safe-global__safe-config-service-145
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Increase max limit for the chains endpoint --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --- BEGIN FILES --- Path: `src/chains/view...
diff --git a/src/chains/views.py b/src/chains/views.py --- a/src/chains/views.py +++ b/src/chains/views.py @@ -9,7 +9,7 @@ class ChainsListView(ListAPIView): serializer_class = ChainSerializer pagination_class = LimitOffsetPagination - pagination_class.max_limit = 10 + pagination_class.max_limit = 100 ...
{"golden_diff": "diff --git a/src/chains/views.py b/src/chains/views.py\n--- a/src/chains/views.py\n+++ b/src/chains/views.py\n@@ -9,7 +9,7 @@\n class ChainsListView(ListAPIView):\n serializer_class = ChainSerializer\n pagination_class = LimitOffsetPagination\n- pagination_class.max_limit = 10\n+ paginati...
463
114
gh_patches_debug_24394
rasdani/github-patches
git_diff
pulp__pulpcore-4182
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Reclaim space for repository fails with Cannot delete some instances of model 'Artifact' because they are referenced through protected foreign keys: 'ContentArtifact.artifact'." **Version** 3.16, but probabl...
diff --git a/pulpcore/app/tasks/reclaim_space.py b/pulpcore/app/tasks/reclaim_space.py --- a/pulpcore/app/tasks/reclaim_space.py +++ b/pulpcore/app/tasks/reclaim_space.py @@ -1,3 +1,7 @@ +from logging import getLogger + +from django.db.models.deletion import ProtectedError + from pulpcore.app.models import ( Arti...
{"golden_diff": "diff --git a/pulpcore/app/tasks/reclaim_space.py b/pulpcore/app/tasks/reclaim_space.py\n--- a/pulpcore/app/tasks/reclaim_space.py\n+++ b/pulpcore/app/tasks/reclaim_space.py\n@@ -1,3 +1,7 @@\n+from logging import getLogger\n+\n+from django.db.models.deletion import ProtectedError\n+\n from pulpcore.app....
1,349
322
gh_patches_debug_5389
rasdani/github-patches
git_diff
vega__altair-989
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- scatter-matrix example don't fit into screen https://altair-viz.github.io/gallery/scatter_matrix.html#scatter-matrix ![image](https://user-images.githubusercontent.com/11561581/42128898-7df8a956-7cbe-11e8-8a...
diff --git a/altair/vegalite/v2/examples/scatter_matrix.py b/altair/vegalite/v2/examples/scatter_matrix.py --- a/altair/vegalite/v2/examples/scatter_matrix.py +++ b/altair/vegalite/v2/examples/scatter_matrix.py @@ -13,8 +13,8 @@ alt.Y(alt.repeat("row"), type='quantitative'), color='Origin:N' ).properties( - ...
{"golden_diff": "diff --git a/altair/vegalite/v2/examples/scatter_matrix.py b/altair/vegalite/v2/examples/scatter_matrix.py\n--- a/altair/vegalite/v2/examples/scatter_matrix.py\n+++ b/altair/vegalite/v2/examples/scatter_matrix.py\n@@ -13,8 +13,8 @@\n alt.Y(alt.repeat(\"row\"), type='quantitative'),\n color='Ori...
592
172
gh_patches_debug_16489
rasdani/github-patches
git_diff
fossasia__open-event-server-6754
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Error in migrations **Describe the bug** Due to recent merging of PRs https://github.com/fossasia/open-event-server/pull/6744/ https://github.com/fossasia/open-event-server/pull/6748 The PR https://github...
diff --git a/migrations/versions/rev-2020-01-17-18:09:31-6ebafb385765_.py b/migrations/versions/rev-2020-01-17-18:09:31-6ebafb385765_.py --- a/migrations/versions/rev-2020-01-17-18:09:31-6ebafb385765_.py +++ b/migrations/versions/rev-2020-01-17-18:09:31-6ebafb385765_.py @@ -18,7 +18,6 @@ def upgrade(): # ### co...
{"golden_diff": "diff --git a/migrations/versions/rev-2020-01-17-18:09:31-6ebafb385765_.py b/migrations/versions/rev-2020-01-17-18:09:31-6ebafb385765_.py\n--- a/migrations/versions/rev-2020-01-17-18:09:31-6ebafb385765_.py\n+++ b/migrations/versions/rev-2020-01-17-18:09:31-6ebafb385765_.py\n@@ -18,7 +18,6 @@\n \n def up...
734
313
gh_patches_debug_13555
rasdani/github-patches
git_diff
cisagov__manage.get.gov-1461
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Content: Clarify that a domain that appears "available" is not guaranteed ### Story As an applicant I want to understand that my requested domain is not guaranteed so that I can set appropriate expectations f...
diff --git a/src/api/views.py b/src/api/views.py --- a/src/api/views.py +++ b/src/api/views.py @@ -32,7 +32,9 @@ "Read more about choosing your .gov domain.</a>".format(public_site_url("domains/choosing")) ), "invalid": "Enter a domain using only letters, numbers, or hyphens (though we don't recommen...
{"golden_diff": "diff --git a/src/api/views.py b/src/api/views.py\n--- a/src/api/views.py\n+++ b/src/api/views.py\n@@ -32,7 +32,9 @@\n \"Read more about choosing your .gov domain.</a>\".format(public_site_url(\"domains/choosing\"))\n ),\n \"invalid\": \"Enter a domain using only letters, numbers, or hyp...
1,925
175
gh_patches_debug_5180
rasdani/github-patches
git_diff
oppia__oppia-7075
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Add the practice session experience to the topic viewer Add an option in the topic viewer page that can start the practice session, based on the skills that are part of the topic. Add the practice session exp...
diff --git a/core/controllers/topic_viewer.py b/core/controllers/topic_viewer.py --- a/core/controllers/topic_viewer.py +++ b/core/controllers/topic_viewer.py @@ -73,6 +73,7 @@ self.values.update({ 'topic_name': topic.name, + 'topic_id': topic.id, 'canonical_story_dicts':...
{"golden_diff": "diff --git a/core/controllers/topic_viewer.py b/core/controllers/topic_viewer.py\n--- a/core/controllers/topic_viewer.py\n+++ b/core/controllers/topic_viewer.py\n@@ -73,6 +73,7 @@\n \n self.values.update({\n 'topic_name': topic.name,\n+ 'topic_id': topic.id,\n ...
1,058
99
gh_patches_debug_42262
rasdani/github-patches
git_diff
open-telemetry__opentelemetry-python-806
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- ext/pyramid: add docs page An entry in the docs is missing for the pyramid instrumentation. --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain ...
diff --git a/ext/opentelemetry-ext-pyramid/src/opentelemetry/ext/pyramid/__init__.py b/ext/opentelemetry-ext-pyramid/src/opentelemetry/ext/pyramid/__init__.py --- a/ext/opentelemetry-ext-pyramid/src/opentelemetry/ext/pyramid/__init__.py +++ b/ext/opentelemetry-ext-pyramid/src/opentelemetry/ext/pyramid/__init__.py @@ -2...
{"golden_diff": "diff --git a/ext/opentelemetry-ext-pyramid/src/opentelemetry/ext/pyramid/__init__.py b/ext/opentelemetry-ext-pyramid/src/opentelemetry/ext/pyramid/__init__.py\n--- a/ext/opentelemetry-ext-pyramid/src/opentelemetry/ext/pyramid/__init__.py\n+++ b/ext/opentelemetry-ext-pyramid/src/opentelemetry/ext/pyrami...
1,691
789
gh_patches_debug_18633
rasdani/github-patches
git_diff
microsoft__botbuilder-python-1970
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Version dependency between Botbuilder and Question Answering ### [Github issues](https://github.com/Microsoft/botbuilder-python) should be used for bugs and feature requests. Use [Stack Overflow](https://stac...
diff --git a/libraries/botbuilder-schema/setup.py b/libraries/botbuilder-schema/setup.py --- a/libraries/botbuilder-schema/setup.py +++ b/libraries/botbuilder-schema/setup.py @@ -6,7 +6,7 @@ NAME = "botbuilder-schema" VERSION = os.environ["packageVersion"] if "packageVersion" in os.environ else "4.15.0" -REQUIRE...
{"golden_diff": "diff --git a/libraries/botbuilder-schema/setup.py b/libraries/botbuilder-schema/setup.py\n--- a/libraries/botbuilder-schema/setup.py\n+++ b/libraries/botbuilder-schema/setup.py\n@@ -6,7 +6,7 @@\n \r\n NAME = \"botbuilder-schema\"\r\n VERSION = os.environ[\"packageVersion\"] if \"packageVersion\" in os....
1,605
331
gh_patches_debug_30898
rasdani/github-patches
git_diff
mlflow__mlflow-5403
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [BUG] XGBoost autologging breaks when metric with @ is used Thank you for submitting an issue. Please refer to our [issue policy](https://www.github.com/mlflow/mlflow/blob/master/ISSUE_POLICY.md) for addition...
diff --git a/mlflow/xgboost/_autolog.py b/mlflow/xgboost/_autolog.py --- a/mlflow/xgboost/_autolog.py +++ b/mlflow/xgboost/_autolog.py @@ -6,9 +6,15 @@ from mlflow.utils.autologging_utils import ExceptionSafeAbstractClass +def _patch_metric_names(metric_dict): + # XGBoost provides some metrics with "@", e.g. "n...
{"golden_diff": "diff --git a/mlflow/xgboost/_autolog.py b/mlflow/xgboost/_autolog.py\n--- a/mlflow/xgboost/_autolog.py\n+++ b/mlflow/xgboost/_autolog.py\n@@ -6,9 +6,15 @@\n from mlflow.utils.autologging_utils import ExceptionSafeAbstractClass\n \n \n+def _patch_metric_names(metric_dict):\n+ # XGBoost provides some ...
1,967
384
gh_patches_debug_21014
rasdani/github-patches
git_diff
python__peps-3559
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Infra: Allow dismissing the historical note banner These notes take up more than a 1/3 of my screen and make it significantly harder to read the PEP. I can developer console it out of existence on my laptop, ...
diff --git a/pep_sphinx_extensions/pep_processor/parsing/pep_banner_directive.py b/pep_sphinx_extensions/pep_processor/parsing/pep_banner_directive.py --- a/pep_sphinx_extensions/pep_processor/parsing/pep_banner_directive.py +++ b/pep_sphinx_extensions/pep_processor/parsing/pep_banner_directive.py @@ -34,6 +34,9 @@ ...
{"golden_diff": "diff --git a/pep_sphinx_extensions/pep_processor/parsing/pep_banner_directive.py b/pep_sphinx_extensions/pep_processor/parsing/pep_banner_directive.py\n--- a/pep_sphinx_extensions/pep_processor/parsing/pep_banner_directive.py\n+++ b/pep_sphinx_extensions/pep_processor/parsing/pep_banner_directive.py\n@...
1,311
263
gh_patches_debug_13591
rasdani/github-patches
git_diff
freqtrade__freqtrade-4189
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- StoplossGuard should include stoploss_on_exchange as well The document is here: https://www.freqtrade.io/en/latest/configuration/#stoploss-guard But it should include stoploss_on_exchange as well. --- END...
diff --git a/freqtrade/plugins/protections/stoploss_guard.py b/freqtrade/plugins/protections/stoploss_guard.py --- a/freqtrade/plugins/protections/stoploss_guard.py +++ b/freqtrade/plugins/protections/stoploss_guard.py @@ -53,8 +53,9 @@ # trades = Trade.get_trades(filters).all() trades1 = Trade.get_...
{"golden_diff": "diff --git a/freqtrade/plugins/protections/stoploss_guard.py b/freqtrade/plugins/protections/stoploss_guard.py\n--- a/freqtrade/plugins/protections/stoploss_guard.py\n+++ b/freqtrade/plugins/protections/stoploss_guard.py\n@@ -53,8 +53,9 @@\n # trades = Trade.get_trades(filters).all()\n \n ...
1,257
228
gh_patches_debug_4850
rasdani/github-patches
git_diff
python__python-docs-es-1000
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Translate `library/signal.po` This needs to reach 100% translated. Current stats for `library/signal.po`: - Fuzzy: 0 - Percent translated: 0% - Entries: 0 / 119 - Untranslated: 119 Please, comment here if ...
diff --git a/conf.py b/conf.py --- a/conf.py +++ b/conf.py @@ -42,8 +42,9 @@ # Extend settings from upstream _exclude_patterns = [ - # This file is not included and it not marked as :orphan: - '*/distutils/_setuptools_disclaimer.rst', + # This file is not included and it's not marked as :orphan: + 'dist...
{"golden_diff": "diff --git a/conf.py b/conf.py\n--- a/conf.py\n+++ b/conf.py\n@@ -42,8 +42,9 @@\n \n # Extend settings from upstream\n _exclude_patterns = [\n- # This file is not included and it not marked as :orphan:\n- '*/distutils/_setuptools_disclaimer.rst',\n+ # This file is not included and it's not mar...
1,918
140
gh_patches_debug_17067
rasdani/github-patches
git_diff
keras-team__autokeras-241
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- "numpy.linalg.linalg.LinAlgError: N-th leading minor of the array is not positive definite" exception while training ImageClassifier <!--- **If you are reporting a bug:** * Verify that your issue is not be...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -5,12 +5,12 @@ packages=['autokeras'], # this must be the same as the name above install_requires=['torch==0.4.1', 'torchvision==0.2.1', 'numpy>=1.14.5', 'keras==2.2.2', 'scikit-learn==0.19.1', 'tensorflow>=1.10.0', 'tqd...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -5,12 +5,12 @@\n packages=['autokeras'], # this must be the same as the name above\n install_requires=['torch==0.4.1', 'torchvision==0.2.1', 'numpy>=1.14.5', 'keras==2.2.2', 'scikit-learn==0.19.1',\n 'te...
860
266
gh_patches_debug_31843
rasdani/github-patches
git_diff
freedomofpress__securedrop-238
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Overly permissive Database privileges for “securedrop” user The privileges given the MySQL user accessing the SecureDrop database are overly permissive and allow an attacker after a successful SQL injection a...
diff --git a/install_files/document.config.py b/install_files/document.config.py --- a/install_files/document.config.py +++ b/install_files/document.config.py @@ -46,15 +46,15 @@ # Database Configuration # Default to using a sqlite database file for development -#DATABASE_ENGINE = 'sqlite' -#DATABASE_FILE=os.path.j...
{"golden_diff": "diff --git a/install_files/document.config.py b/install_files/document.config.py\n--- a/install_files/document.config.py\n+++ b/install_files/document.config.py\n@@ -46,15 +46,15 @@\n # Database Configuration\n \n # Default to using a sqlite database file for development\n-#DATABASE_ENGINE = 'sqlite'\n...
1,753
481
gh_patches_debug_158
rasdani/github-patches
git_diff
mindsdb__mindsdb-2137
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [Bug]: PIP installation error ### Is there an existing issue for this? - [X] I have searched the existing issues ### Current Behavior Hello, using ```pip install mindsdb``` I've got this error: ``` Trac...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -6,7 +6,7 @@ exec(fp.read(), about) -with open("README.md", "r") as fh: +with open("README.md", "r", encoding="utf8") as fh: long_description = fh.read()
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -6,7 +6,7 @@\n exec(fp.read(), about)\n \n \n-with open(\"README.md\", \"r\") as fh:\n+with open(\"README.md\", \"r\", encoding=\"utf8\") as fh:\n long_description = fh.read()\n", "issue": "[Bug]: PIP installation error\n### I...
1,517
75
gh_patches_debug_20224
rasdani/github-patches
git_diff
getsentry__sentry-44899
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [Project Transfer] Request Approval Email Uses Incorrect Customer Subdomain r### Environment SaaS (https://sentry.io/) ### Version n/a ### Link [relevant transaction](https://sentry.sentry.io/d...
diff --git a/src/sentry/api/endpoints/project_transfer.py b/src/sentry/api/endpoints/project_transfer.py --- a/src/sentry/api/endpoints/project_transfer.py +++ b/src/sentry/api/endpoints/project_transfer.py @@ -13,6 +13,7 @@ from sentry.api.decorators import sudo_required from sentry.models import OrganizationMember ...
{"golden_diff": "diff --git a/src/sentry/api/endpoints/project_transfer.py b/src/sentry/api/endpoints/project_transfer.py\n--- a/src/sentry/api/endpoints/project_transfer.py\n+++ b/src/sentry/api/endpoints/project_transfer.py\n@@ -13,6 +13,7 @@\n from sentry.api.decorators import sudo_required\n from sentry.models impo...
1,548
218
gh_patches_debug_60614
rasdani/github-patches
git_diff
cloudtools__troposphere-1670
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Security Hub tags not formatted correctly Using the following code for a Security Hub resource results in tags that don't follow the structure of Security Hub Cloudformation: ``` hub = tpl.add_resource(Hu...
diff --git a/troposphere/securityhub.py b/troposphere/securityhub.py --- a/troposphere/securityhub.py +++ b/troposphere/securityhub.py @@ -8,12 +8,12 @@ from . import AWSObject -from troposphere import Tags +from .validators import json_checker class Hub(AWSObject): resource_type = "AWS::SecurityHub::Hub...
{"golden_diff": "diff --git a/troposphere/securityhub.py b/troposphere/securityhub.py\n--- a/troposphere/securityhub.py\n+++ b/troposphere/securityhub.py\n@@ -8,12 +8,12 @@\n \n \n from . import AWSObject\n-from troposphere import Tags\n+from .validators import json_checker\n \n \n class Hub(AWSObject):\n resource_...
704
116
gh_patches_debug_3933
rasdani/github-patches
git_diff
microsoft__ptvsd-1559
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- attach_socket_import tests hang waiting for "process" event (https://github.com/microsoft/ptvsd/tree/dbg_adapter_refactor) When running multiple tests with `start_method` set to `attach_socket_cmdline` or ...
diff --git a/src/ptvsd/__init__.py b/src/ptvsd/__init__.py --- a/src/ptvsd/__init__.py +++ b/src/ptvsd/__init__.py @@ -24,6 +24,14 @@ __file__ = path.abspath(__file__) del path +# Preload encodings that we're going to use to avoid import deadlocks on Python 2. +import codecs +codecs.lookup('ascii') +codecs.lookup('...
{"golden_diff": "diff --git a/src/ptvsd/__init__.py b/src/ptvsd/__init__.py\n--- a/src/ptvsd/__init__.py\n+++ b/src/ptvsd/__init__.py\n@@ -24,6 +24,14 @@\n __file__ = path.abspath(__file__)\n del path\n \n+# Preload encodings that we're going to use to avoid import deadlocks on Python 2.\n+import codecs\n+codecs.lookup...
658
163
gh_patches_debug_47811
rasdani/github-patches
git_diff
CTFd__CTFd-1921
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Stub issue for ctfcli #13 https://github.com/CTFd/ctfcli/issues/13 This needs to be resolved in CTFd most likely. --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of...
diff --git a/CTFd/plugins/dynamic_challenges/__init__.py b/CTFd/plugins/dynamic_challenges/__init__.py --- a/CTFd/plugins/dynamic_challenges/__init__.py +++ b/CTFd/plugins/dynamic_challenges/__init__.py @@ -22,7 +22,7 @@ def __init__(self, *args, **kwargs): super(DynamicChallenge, self).__init__(**kwarg...
{"golden_diff": "diff --git a/CTFd/plugins/dynamic_challenges/__init__.py b/CTFd/plugins/dynamic_challenges/__init__.py\n--- a/CTFd/plugins/dynamic_challenges/__init__.py\n+++ b/CTFd/plugins/dynamic_challenges/__init__.py\n@@ -22,7 +22,7 @@\n \n def __init__(self, *args, **kwargs):\n super(DynamicChallenge,...
1,761
125
gh_patches_debug_21182
rasdani/github-patches
git_diff
saleor__saleor-527
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- 302 Status in Shipping Method. **TD;LR** When I enter the "Shipping Address" entire as anonymous or create a new address. It makes me submit it again and again. Using c79bdbb13c399b253e3a26480d01f1cb219b470...
diff --git a/saleor/core/__init__.py b/saleor/core/__init__.py --- a/saleor/core/__init__.py +++ b/saleor/core/__init__.py @@ -2,6 +2,7 @@ from babel.numbers import get_territory_currencies from django.conf import settings +from django.core.checks import register, Tags, Warning from django_countries import countri...
{"golden_diff": "diff --git a/saleor/core/__init__.py b/saleor/core/__init__.py\n--- a/saleor/core/__init__.py\n+++ b/saleor/core/__init__.py\n@@ -2,6 +2,7 @@\n \n from babel.numbers import get_territory_currencies\n from django.conf import settings\n+from django.core.checks import register, Tags, Warning\n from django...
812
284
gh_patches_debug_5118
rasdani/github-patches
git_diff
akvo__akvo-rsr-2254
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Create a 500 page Create a (working) 500 page with a message like: > Oops something went wrong. We have been notified and will take action asap. Please check in later or contact us at xyz. RSR team --- END...
diff --git a/akvo/rsr/views/error.py b/akvo/rsr/views/error.py --- a/akvo/rsr/views/error.py +++ b/akvo/rsr/views/error.py @@ -6,8 +6,12 @@ see < http://www.gnu.org/licenses/agpl.html >. """ -from django.http import HttpResponse +from django.shortcuts import render_to_response +from django.template import Reque...
{"golden_diff": "diff --git a/akvo/rsr/views/error.py b/akvo/rsr/views/error.py\n--- a/akvo/rsr/views/error.py\n+++ b/akvo/rsr/views/error.py\n@@ -6,8 +6,12 @@\n see < http://www.gnu.org/licenses/agpl.html >.\n \"\"\"\n \n-from django.http import HttpResponse\n+from django.shortcuts import render_to_response\n+from...
439
157
gh_patches_debug_31160
rasdani/github-patches
git_diff
ibis-project__ibis-2308
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Impala pandas_interop.py DataFrameWriter.write_csv() fails with PermissionError on Windows Platforms pandas_interop.py DataFrameWriter.write_csv() fails with PermissionError on Windows Platforms due to how Py...
diff --git a/ibis/impala/pandas_interop.py b/ibis/impala/pandas_interop.py --- a/ibis/impala/pandas_interop.py +++ b/ibis/impala/pandas_interop.py @@ -13,8 +13,8 @@ # limitations under the License. import csv +import os import tempfile - from posixpath import join as pjoin import ibis.common.exceptions as com ...
{"golden_diff": "diff --git a/ibis/impala/pandas_interop.py b/ibis/impala/pandas_interop.py\n--- a/ibis/impala/pandas_interop.py\n+++ b/ibis/impala/pandas_interop.py\n@@ -13,8 +13,8 @@\n # limitations under the License.\n \n import csv\n+import os\n import tempfile\n-\n from posixpath import join as pjoin\n \n import i...
1,720
395
gh_patches_debug_4876
rasdani/github-patches
git_diff
akvo__akvo-rsr-1921
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Project editor crash for conditions without a text ## Test plan 1. Open the project editor, and click the 'Show advanced IATI fields' button 2. In the results and indicators section, add a project condition w...
diff --git a/akvo/rsr/models/project_condition.py b/akvo/rsr/models/project_condition.py --- a/akvo/rsr/models/project_condition.py +++ b/akvo/rsr/models/project_condition.py @@ -23,7 +23,7 @@ choices=codelist_choices(CONDITION_TYPE)) def __unicode__(self): - return self.text...
{"golden_diff": "diff --git a/akvo/rsr/models/project_condition.py b/akvo/rsr/models/project_condition.py\n--- a/akvo/rsr/models/project_condition.py\n+++ b/akvo/rsr/models/project_condition.py\n@@ -23,7 +23,7 @@\n choices=codelist_choices(CONDITION_TYPE))\n \n def __unicode__(self):\n-...
759
136
gh_patches_debug_3195
rasdani/github-patches
git_diff
hartwork__jawanndenn-225
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- missing rapid-json dependency for pip installing via pip3 does not also install the rapid-json dependency. missing rapid-json dependency for pip installing via pip3 does not also install the rapid-json depend...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -52,6 +52,8 @@ 'djangorestframework>=3.11.0', 'gunicorn>=20.0.4', 'gunicorn-color>=0.1.0', + 'python-dateutil>=2.8.1', + 'python-rapidjson>=1.0', ], extras_require=_extras_req...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -52,6 +52,8 @@\n 'djangorestframework>=3.11.0',\n 'gunicorn>=20.0.4',\n 'gunicorn-color>=0.1.0',\n+ 'python-dateutil>=2.8.1',\n+ 'python-rapidjson>=1.0',\n ],\n ...
1,097
111
gh_patches_debug_18134
rasdani/github-patches
git_diff
ocadotechnology__aimmo-350
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Functional Test 1 - Effect expiry We want to check that the effect can expire. This would be as follows: Place an avatar on the map in one of the cells. Place a pickup somewhere. Make a move in some directi...
diff --git a/aimmo-game/simulation/effects.py b/aimmo-game/simulation/effects.py --- a/aimmo-game/simulation/effects.py +++ b/aimmo-game/simulation/effects.py @@ -1,9 +1,10 @@ from abc import ABCMeta, abstractmethod import math - import sys +INVULNERABILITY_RESISTANCE = 1000 + class _Effect(object): __me...
{"golden_diff": "diff --git a/aimmo-game/simulation/effects.py b/aimmo-game/simulation/effects.py\n--- a/aimmo-game/simulation/effects.py\n+++ b/aimmo-game/simulation/effects.py\n@@ -1,9 +1,10 @@\n from abc import ABCMeta, abstractmethod\n \n import math\n-\n import sys\n \n+INVULNERABILITY_RESISTANCE = 1000\n+\n \n cl...
892
245
gh_patches_debug_12044
rasdani/github-patches
git_diff
chainer__chainer-5333
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- PrintHook may fail * Conditions ``` >>> chainer.print_runtime_info() Platform: Darwin-17.7.0-x86_64-i386-64bit Chainer: 5.0.0b4 NumPy: 1.16.0.dev0+591880b CuPy: Not Available ``` * Code to reproduce ...
diff --git a/chainer/function_hooks/debug_print.py b/chainer/function_hooks/debug_print.py --- a/chainer/function_hooks/debug_print.py +++ b/chainer/function_hooks/debug_print.py @@ -73,9 +73,12 @@ if out_grad is not None: self._print('output gradient') for d in out_grad: - ...
{"golden_diff": "diff --git a/chainer/function_hooks/debug_print.py b/chainer/function_hooks/debug_print.py\n--- a/chainer/function_hooks/debug_print.py\n+++ b/chainer/function_hooks/debug_print.py\n@@ -73,9 +73,12 @@\n if out_grad is not None:\n self._print('output gradient')\n for d in...
1,958
178
gh_patches_debug_18139
rasdani/github-patches
git_diff
Qiskit__qiskit-10411
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Deepcopy of control flow with standalone clbit results in invalid circuit ### Environment - **Qiskit Terra version**: 0.24.1 (but also on main) - **Python version**: 3.11 - **Operating system**: Linux ...
diff --git a/qiskit/circuit/bit.py b/qiskit/circuit/bit.py --- a/qiskit/circuit/bit.py +++ b/qiskit/circuit/bit.py @@ -13,6 +13,7 @@ """ Quantum bit and Classical bit objects. """ +import copy from qiskit.circuit.exceptions import CircuitError from qiskit.utils.deprecation import deprecate_func @@ -120,3 +121,20...
{"golden_diff": "diff --git a/qiskit/circuit/bit.py b/qiskit/circuit/bit.py\n--- a/qiskit/circuit/bit.py\n+++ b/qiskit/circuit/bit.py\n@@ -13,6 +13,7 @@\n \"\"\"\n Quantum bit and Classical bit objects.\n \"\"\"\n+import copy\n \n from qiskit.circuit.exceptions import CircuitError\n from qiskit.utils.deprecation import...
1,978
272
gh_patches_debug_4004
rasdani/github-patches
git_diff
tobymao__sqlglot-552
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- cast to map with clickhouse dialect ignores case Yet another clickhouse case sensitivity bug :) ClickHouse CLI: ``` albatross :) select cast(map('a', 1, 'b', 2) as Map(String, Int8)); SELECT CAST(...
diff --git a/sqlglot/dialects/clickhouse.py b/sqlglot/dialects/clickhouse.py --- a/sqlglot/dialects/clickhouse.py +++ b/sqlglot/dialects/clickhouse.py @@ -51,6 +51,9 @@ **Generator.TYPE_MAPPING, exp.DataType.Type.NULLABLE: "Nullable", exp.DataType.Type.DATETIME: "DateTime64", + ...
{"golden_diff": "diff --git a/sqlglot/dialects/clickhouse.py b/sqlglot/dialects/clickhouse.py\n--- a/sqlglot/dialects/clickhouse.py\n+++ b/sqlglot/dialects/clickhouse.py\n@@ -51,6 +51,9 @@\n **Generator.TYPE_MAPPING,\n exp.DataType.Type.NULLABLE: \"Nullable\",\n exp.DataType.Type.DAT...
1,156
135
gh_patches_debug_14670
rasdani/github-patches
git_diff
ipython__ipython-3669
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- AttributeError: 'BlockingKernelClient' object has no attribute 'started_channels' I have an app that is centered around IPython running in qt (https://github.com/neuropy/neuropy/blob/master/neuropy/main.py). ...
diff --git a/IPython/qt/manager.py b/IPython/qt/manager.py --- a/IPython/qt/manager.py +++ b/IPython/qt/manager.py @@ -4,7 +4,7 @@ from IPython.external.qt import QtCore # Local imports -from IPython.utils.traitlets import Bool +from IPython.utils.traitlets import Bool, DottedObjectName from IPython.kernel impor...
{"golden_diff": "diff --git a/IPython/qt/manager.py b/IPython/qt/manager.py\n--- a/IPython/qt/manager.py\n+++ b/IPython/qt/manager.py\n@@ -4,7 +4,7 @@\n from IPython.external.qt import QtCore\n \n # Local imports\n-from IPython.utils.traitlets import Bool\n+from IPython.utils.traitlets import Bool, DottedObjectName\n \...
951
177
gh_patches_debug_67296
rasdani/github-patches
git_diff
qutip__qutip-1390
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Installation of qutip shows various warnings on ubuntu 20.04.1 **Describe the bug** Installing the qutip on ubuntu 20.04.1 shows the following warnings: ``` $ sudo apt install python3-qutip … Entpacken ...
diff --git a/qutip/_mkl/spmv.py b/qutip/_mkl/spmv.py --- a/qutip/_mkl/spmv.py +++ b/qutip/_mkl/spmv.py @@ -50,7 +50,7 @@ indices = A.indices.ctypes.data_as(POINTER(c_int)) # Allocate output, using same conventions as input - if x.ndim is 1: + if x.ndim == 1: y = np.empty(m,dtype=np.comple...
{"golden_diff": "diff --git a/qutip/_mkl/spmv.py b/qutip/_mkl/spmv.py\n--- a/qutip/_mkl/spmv.py\n+++ b/qutip/_mkl/spmv.py\n@@ -50,7 +50,7 @@\n indices = A.indices.ctypes.data_as(POINTER(c_int))\n \n # Allocate output, using same conventions as input\n- if x.ndim is 1:\n+ if x.ndim == 1:\n y = ...
1,844
154
gh_patches_debug_21565
rasdani/github-patches
git_diff
OCA__server-tools-508
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Fix travis build on 9.0 branch the 9.0 branch of the project is red, with really strange errors about computed fields. There have been such errors since the merge of #469 but for some reason they were neither...
diff --git a/database_cleanup/models/purge_wizard.py b/database_cleanup/models/purge_wizard.py --- a/database_cleanup/models/purge_wizard.py +++ b/database_cleanup/models/purge_wizard.py @@ -24,8 +24,8 @@ @api.model def create(self, values): # make sure the user trying this is actually supposed to do...
{"golden_diff": "diff --git a/database_cleanup/models/purge_wizard.py b/database_cleanup/models/purge_wizard.py\n--- a/database_cleanup/models/purge_wizard.py\n+++ b/database_cleanup/models/purge_wizard.py\n@@ -24,8 +24,8 @@\n @api.model\n def create(self, values):\n # make sure the user trying this is ...
1,222
257
gh_patches_debug_5371
rasdani/github-patches
git_diff
getnikola__nikola-3511
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Incorrect time zone guessing on macOS On macOS Big Sur 11.2, we guess the full path to the zoneinfo file (instead of just the zone name). ``` $ nikola init … Time zone [private/var/db/timezone/tz/2021a....
diff --git a/nikola/packages/tzlocal/unix.py b/nikola/packages/tzlocal/unix.py --- a/nikola/packages/tzlocal/unix.py +++ b/nikola/packages/tzlocal/unix.py @@ -116,8 +116,9 @@ while start != 0: tzpath = tzpath[start:] try: - dateutil.tz.gettz(tzpath) - ret...
{"golden_diff": "diff --git a/nikola/packages/tzlocal/unix.py b/nikola/packages/tzlocal/unix.py\n--- a/nikola/packages/tzlocal/unix.py\n+++ b/nikola/packages/tzlocal/unix.py\n@@ -116,8 +116,9 @@\n while start != 0:\n tzpath = tzpath[start:]\n try:\n- dateutil.tz.gettz(tzpa...
1,730
149
gh_patches_debug_26724
rasdani/github-patches
git_diff
ivy-llc__ivy-14028
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- diag_indices_from mask_indices --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --- BEGIN FILES --- Path: `ivy/functional/frontends/j...
diff --git a/ivy/functional/frontends/jax/numpy/indexing.py b/ivy/functional/frontends/jax/numpy/indexing.py --- a/ivy/functional/frontends/jax/numpy/indexing.py +++ b/ivy/functional/frontends/jax/numpy/indexing.py @@ -1,3 +1,6 @@ +# global +import inspect + # local import ivy from ivy.functional.frontends.jax.func_...
{"golden_diff": "diff --git a/ivy/functional/frontends/jax/numpy/indexing.py b/ivy/functional/frontends/jax/numpy/indexing.py\n--- a/ivy/functional/frontends/jax/numpy/indexing.py\n+++ b/ivy/functional/frontends/jax/numpy/indexing.py\n@@ -1,3 +1,6 @@\n+# global\n+import inspect\n+\n # local\n import ivy\n from ivy.func...
767
464
gh_patches_debug_20739
rasdani/github-patches
git_diff
googleapis__python-bigquery-725
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- free(): invalid pointer Aborted error when importing from google.cloud import bigquery in python I started facing this peculiar issue while import importing BigQuery in python scripts as well as in the term...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -29,6 +29,7 @@ # 'Development Status :: 5 - Production/Stable' release_status = "Development Status :: 5 - Production/Stable" dependencies = [ + "grpcio >= 1.38.1, < 2.0dev", # https://github.com/googleapis/python-bigquery/issues/695 "google-...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -29,6 +29,7 @@\n # 'Development Status :: 5 - Production/Stable'\n release_status = \"Development Status :: 5 - Production/Stable\"\n dependencies = [\n+ \"grpcio >= 1.38.1, < 2.0dev\", # https://github.com/googleapis/python-bigqu...
1,989
322
gh_patches_debug_1501
rasdani/github-patches
git_diff
googleapis__google-cloud-python-6332
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Release 'api_core-1.6.0a2'? or 'api_core-1.5.1'? I'd like to use the changes from https://github.com/googleapis/google-cloud-python/pull/6310 in the library I'm working on. Not sure about the version numbe...
diff --git a/api_core/setup.py b/api_core/setup.py --- a/api_core/setup.py +++ b/api_core/setup.py @@ -22,7 +22,7 @@ name = 'google-api-core' description = 'Google API client core library' -version = '1.6.0a1' +version = '1.5.1' # Should be one of: # 'Development Status :: 3 - Alpha' # 'Development Status :: 4 -...
{"golden_diff": "diff --git a/api_core/setup.py b/api_core/setup.py\n--- a/api_core/setup.py\n+++ b/api_core/setup.py\n@@ -22,7 +22,7 @@\n \n name = 'google-api-core'\n description = 'Google API client core library'\n-version = '1.6.0a1'\n+version = '1.5.1'\n # Should be one of:\n # 'Development Status :: 3 - Alpha'\n ...
1,319
104
gh_patches_debug_22057
rasdani/github-patches
git_diff
facebookresearch__hydra-2713
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Hydra ray launcher requirements update # 🚀 Feature Request The requirements of `hydra-ray-launcher` are too restrictive. Please provide wider bounds. In particular, so that is compatible with the latest v...
diff --git a/plugins/hydra_ray_launcher/hydra_plugins/hydra_ray_launcher/__init__.py b/plugins/hydra_ray_launcher/hydra_plugins/hydra_ray_launcher/__init__.py --- a/plugins/hydra_ray_launcher/hydra_plugins/hydra_ray_launcher/__init__.py +++ b/plugins/hydra_ray_launcher/hydra_plugins/hydra_ray_launcher/__init__.py @@ -1...
{"golden_diff": "diff --git a/plugins/hydra_ray_launcher/hydra_plugins/hydra_ray_launcher/__init__.py b/plugins/hydra_ray_launcher/hydra_plugins/hydra_ray_launcher/__init__.py\n--- a/plugins/hydra_ray_launcher/hydra_plugins/hydra_ray_launcher/__init__.py\n+++ b/plugins/hydra_ray_launcher/hydra_plugins/hydra_ray_launche...
986
431
gh_patches_debug_1855
rasdani/github-patches
git_diff
flairNLP__flair-300
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Update torch version to 1.0.0 torch version 1.0.0 is available. Use torch version 1.0.0 in Flair. --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may co...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -12,7 +12,7 @@ packages=find_packages(exclude='test'), # same as name license='MIT', install_requires=[ - 'torch==0.4.1', + 'torch==1.0.0', 'gensim==3.4.0', 'typing==3.6.4', 'tqdm==4.26.0',
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -12,7 +12,7 @@\n packages=find_packages(exclude='test'), # same as name\n license='MIT',\n install_requires=[\n- 'torch==0.4.1',\n+ 'torch==1.0.0',\n 'gensim==3.4.0',\n 'typing==3.6.4',\n ...
618
112
gh_patches_debug_18221
rasdani/github-patches
git_diff
PrefectHQ__prefect-2686
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Google Imports are Tied Together ## Description *A clear description of the bug* I’m using the new `GCSResult` and I’m getting an import error when I don’t also specify `google-cloud-bigquery` as a dependen...
diff --git a/src/prefect/utilities/gcp.py b/src/prefect/utilities/gcp.py --- a/src/prefect/utilities/gcp.py +++ b/src/prefect/utilities/gcp.py @@ -3,7 +3,6 @@ """ import prefect -from google.cloud import bigquery, storage from google.oauth2.service_account import Credentials @@ -47,6 +46,8 @@ Returns: ...
{"golden_diff": "diff --git a/src/prefect/utilities/gcp.py b/src/prefect/utilities/gcp.py\n--- a/src/prefect/utilities/gcp.py\n+++ b/src/prefect/utilities/gcp.py\n@@ -3,7 +3,6 @@\n \"\"\"\n import prefect\n \n-from google.cloud import bigquery, storage\n from google.oauth2.service_account import Credentials\n \n \n@@ -...
1,906
188
gh_patches_debug_12930
rasdani/github-patches
git_diff
spyder-ide__spyder-5128
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Error when trying to load third-party plugins ## Description **What steps will reproduce the problem?** 1. Start sypder. 2. 3. **What is the expected output? What do you see instead?** It shows ...
diff --git a/spyder/otherplugins.py b/spyder/otherplugins.py --- a/spyder/otherplugins.py +++ b/spyder/otherplugins.py @@ -54,10 +54,16 @@ # Is this a Spyder plugin? if not name.startswith(PLUGIN_PREFIX): continue + # Ensure right type of plugin if is_io != name.sta...
{"golden_diff": "diff --git a/spyder/otherplugins.py b/spyder/otherplugins.py\n--- a/spyder/otherplugins.py\n+++ b/spyder/otherplugins.py\n@@ -54,10 +54,16 @@\n # Is this a Spyder plugin?\r\n if not name.startswith(PLUGIN_PREFIX):\r\n continue\r\n+\r\n # Ensure right type of plugin\r...
1,947
172
gh_patches_debug_7825
rasdani/github-patches
git_diff
spack__spack-4606
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- BUG: mxml / adios link error This seems to be related to the pull request https://github.com/LLNL/spack/pull/3696 that I abandoned a few months back, but which has now come back to haunt me. If I use the cur...
diff --git a/var/spack/repos/builtin/packages/mxml/package.py b/var/spack/repos/builtin/packages/mxml/package.py --- a/var/spack/repos/builtin/packages/mxml/package.py +++ b/var/spack/repos/builtin/packages/mxml/package.py @@ -48,5 +48,9 @@ return 'https://github.com/michaelrsweet/mxml/releases/download/re...
{"golden_diff": "diff --git a/var/spack/repos/builtin/packages/mxml/package.py b/var/spack/repos/builtin/packages/mxml/package.py\n--- a/var/spack/repos/builtin/packages/mxml/package.py\n+++ b/var/spack/repos/builtin/packages/mxml/package.py\n@@ -48,5 +48,9 @@\n return 'https://github.com/michaelrsweet/mxml...
1,779
184
gh_patches_debug_29724
rasdani/github-patches
git_diff
pallets__click-545
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Bash completion for MultiCommands returns subcommands twice until it stops. Python 2.7.10 broken in click >= 6 ok in click (5.1) ``` manage hello hello world world ``` --- END ISSUE --- Below are some cod...
diff --git a/click/_bashcomplete.py b/click/_bashcomplete.py --- a/click/_bashcomplete.py +++ b/click/_bashcomplete.py @@ -30,27 +30,19 @@ def resolve_ctx(cli, prog_name, args): ctx = cli.make_context(prog_name, args, resilient_parsing=True) - while ctx.args and isinstance(ctx.command, MultiCommand): - ...
{"golden_diff": "diff --git a/click/_bashcomplete.py b/click/_bashcomplete.py\n--- a/click/_bashcomplete.py\n+++ b/click/_bashcomplete.py\n@@ -30,27 +30,19 @@\n \n def resolve_ctx(cli, prog_name, args):\n ctx = cli.make_context(prog_name, args, resilient_parsing=True)\n- while ctx.args and isinstance(ctx.command...
983
478
gh_patches_debug_14200
rasdani/github-patches
git_diff
mitmproxy__mitmproxy-898
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Client Address is not displayed for flows from dumpfiles I have two clients connecting to mitmproxy now, and I'd like to see the client IP for each request in the "Detail" tab. Maybe show the server's IP too...
diff --git a/libmproxy/console/flowdetailview.py b/libmproxy/console/flowdetailview.py --- a/libmproxy/console/flowdetailview.py +++ b/libmproxy/console/flowdetailview.py @@ -20,7 +20,7 @@ req = flow.request resp = flow.response - if sc: + if sc is not None: text.append(urwid.Text([("head", "...
{"golden_diff": "diff --git a/libmproxy/console/flowdetailview.py b/libmproxy/console/flowdetailview.py\n--- a/libmproxy/console/flowdetailview.py\n+++ b/libmproxy/console/flowdetailview.py\n@@ -20,7 +20,7 @@\n req = flow.request\n resp = flow.response\n \n- if sc:\n+ if sc is not None:\n text.app...
1,522
184
gh_patches_debug_16006
rasdani/github-patches
git_diff
openvinotoolkit__datumaro-275
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- CLI help usage is misleading Recommendation of usage in cli help message is misleading. **Steps:** ``` datum -h ``` **Expected result:** Correct form for usage recommendation **Current result:** `...
diff --git a/datumaro/cli/__main__.py b/datumaro/cli/__main__.py --- a/datumaro/cli/__main__.py +++ b/datumaro/cli/__main__.py @@ -5,6 +5,7 @@ import argparse import logging as log +import os.path as osp import sys from . import contexts, commands @@ -50,9 +51,11 @@ return desc def make_parser(): - p...
{"golden_diff": "diff --git a/datumaro/cli/__main__.py b/datumaro/cli/__main__.py\n--- a/datumaro/cli/__main__.py\n+++ b/datumaro/cli/__main__.py\n@@ -5,6 +5,7 @@\n \n import argparse\n import logging as log\n+import os.path as osp\n import sys\n \n from . import contexts, commands\n@@ -50,9 +51,11 @@\n return desc...
1,699
193
gh_patches_debug_15173
rasdani/github-patches
git_diff
searxng__searxng-131
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- searx_extra/update/update_languages.py : crash on peertube engine The URL https://peer.tube/api/v1/videos/languages doesn't exist anymore: https://github.com/searxng/searxng/blob/ee83c99d2b40efaaf4f3e6635e7a...
diff --git a/searx/engines/peertube.py b/searx/engines/peertube.py --- a/searx/engines/peertube.py +++ b/searx/engines/peertube.py @@ -22,7 +22,9 @@ categories = ["videos"] paging = True base_url = "https://peer.tube" -supported_languages_url = base_url + "/api/v1/videos/languages" +supported_languages_url = ( + ...
{"golden_diff": "diff --git a/searx/engines/peertube.py b/searx/engines/peertube.py\n--- a/searx/engines/peertube.py\n+++ b/searx/engines/peertube.py\n@@ -22,7 +22,9 @@\n categories = [\"videos\"]\n paging = True\n base_url = \"https://peer.tube\"\n-supported_languages_url = base_url + \"/api/v1/videos/languages\"\n+su...
1,297
283
gh_patches_debug_12234
rasdani/github-patches
git_diff
ivy-llc__ivy-15998
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- multiply --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --- BEGIN FILES --- Path: `ivy/functional/frontends/paddle/tensor/math.py` C...
diff --git a/ivy/functional/frontends/paddle/tensor/math.py b/ivy/functional/frontends/paddle/tensor/math.py --- a/ivy/functional/frontends/paddle/tensor/math.py +++ b/ivy/functional/frontends/paddle/tensor/math.py @@ -66,6 +66,24 @@ return ivy.divide(x, y) +@with_unsupported_dtypes({"2.4.2 and below": ("float...
{"golden_diff": "diff --git a/ivy/functional/frontends/paddle/tensor/math.py b/ivy/functional/frontends/paddle/tensor/math.py\n--- a/ivy/functional/frontends/paddle/tensor/math.py\n+++ b/ivy/functional/frontends/paddle/tensor/math.py\n@@ -66,6 +66,24 @@\n return ivy.divide(x, y)\n \n \n+@with_unsupported_dtypes({\"...
1,333
316
gh_patches_debug_59756
rasdani/github-patches
git_diff
pyca__cryptography-3819
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Signer/Verifier deprecation warning has wrong stacklevel Seeing this with Cryptography 2.0: ``` .../python3.5/site-packages/cryptography/hazmat/backends/openssl/rsa.py:477: DeprecationWarning: signer and ...
diff --git a/src/cryptography/hazmat/backends/openssl/utils.py b/src/cryptography/hazmat/backends/openssl/utils.py --- a/src/cryptography/hazmat/backends/openssl/utils.py +++ b/src/cryptography/hazmat/backends/openssl/utils.py @@ -41,5 +41,5 @@ "signer and verifier have been deprecated. Please use sign " ...
{"golden_diff": "diff --git a/src/cryptography/hazmat/backends/openssl/utils.py b/src/cryptography/hazmat/backends/openssl/utils.py\n--- a/src/cryptography/hazmat/backends/openssl/utils.py\n+++ b/src/cryptography/hazmat/backends/openssl/utils.py\n@@ -41,5 +41,5 @@\n \"signer and verifier have been deprecated. P...
812
115
gh_patches_debug_23200
rasdani/github-patches
git_diff
RedHatInsights__insights-core-3248
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Update pydoc for Messages (/var/log/messages) Correct the examples: https://github.com/RedHatInsights/insights-core/blob/master/insights/parsers/messages.py#L32 --- END ISSUE --- Below are some code segment...
diff --git a/insights/parsers/messages.py b/insights/parsers/messages.py --- a/insights/parsers/messages.py +++ b/insights/parsers/messages.py @@ -30,17 +30,14 @@ This will also work around December/January crossovers. Examples: - >>> Messages.filters.append('wrapper') >>> Messages.token...
{"golden_diff": "diff --git a/insights/parsers/messages.py b/insights/parsers/messages.py\n--- a/insights/parsers/messages.py\n+++ b/insights/parsers/messages.py\n@@ -30,17 +30,14 @@\n This will also work around December/January crossovers.\n \n Examples:\n- >>> Messages.filters.append('wrapper')\n ...
958
408
gh_patches_debug_11114
rasdani/github-patches
git_diff
freedomofpress__securedrop-1890
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Tails 3.0 does not restore the original filename when uncompressing a file # Bug Tails 3.0 does not preserve the filename when extracting an archive. ## Description When extracting an archive, Tails ...
diff --git a/install_files/ansible-base/roles/tails-config/files/securedrop_init.py b/install_files/ansible-base/roles/tails-config/files/securedrop_init.py --- a/install_files/ansible-base/roles/tails-config/files/securedrop_init.py +++ b/install_files/ansible-base/roles/tails-config/files/securedrop_init.py @@ -41,6 ...
{"golden_diff": "diff --git a/install_files/ansible-base/roles/tails-config/files/securedrop_init.py b/install_files/ansible-base/roles/tails-config/files/securedrop_init.py\n--- a/install_files/ansible-base/roles/tails-config/files/securedrop_init.py\n+++ b/install_files/ansible-base/roles/tails-config/files/securedro...
890
218
gh_patches_debug_13980
rasdani/github-patches
git_diff
ocf__ocfweb-185
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- libsass>0.10.0 breaks dh-virtuaenv https://jenkins.ocf.berkeley.edu/view/ocfweb-deploy/job/ocfweb-build-deb/232/console ``` # build sass, output static files debian/ocfweb/usr/share/python/ocfweb/bin/python ...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -24,7 +24,7 @@ 'django-redis', 'django>=1.10,<1.10.999', 'gunicorn', - 'libsass<=0.10.0', # https://github.com/ocf/ocfweb/issues/128 + 'libsass', 'matplotlib', 'mistune', 'numpy', @@ -3...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -24,7 +24,7 @@\n 'django-redis',\n 'django>=1.10,<1.10.999',\n 'gunicorn',\n- 'libsass<=0.10.0', # https://github.com/ocf/ocfweb/issues/128\n+ 'libsass',\n 'matplotlib',\n 'mistun...
1,444
199
gh_patches_debug_26182
rasdani/github-patches
git_diff
scalableminds__webknossos-libs-641
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Persist log file When running the cuber, there usually is a lot of output (overflowing terminal buffers). It would be great if all of that output would be persisted in a log file as well to allow to easily sc...
diff --git a/webknossos/webknossos/utils.py b/webknossos/webknossos/utils.py --- a/webknossos/webknossos/utils.py +++ b/webknossos/webknossos/utils.py @@ -4,6 +4,7 @@ import json import logging import os +import sys import time from concurrent.futures import as_completed from concurrent.futures._base import Futur...
{"golden_diff": "diff --git a/webknossos/webknossos/utils.py b/webknossos/webknossos/utils.py\n--- a/webknossos/webknossos/utils.py\n+++ b/webknossos/webknossos/utils.py\n@@ -4,6 +4,7 @@\n import json\n import logging\n import os\n+import sys\n import time\n from concurrent.futures import as_completed\n from concurrent...
1,988
400
gh_patches_debug_41281
rasdani/github-patches
git_diff
mozilla__bugbug-310
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Make NLP dependencies optional Some dependencies are only needed in some images, we should make some dependencies optional so that they are only installed when necessary. For example, Spacy is the biggest ...
diff --git a/bugbug/nlp.py b/bugbug/nlp.py --- a/bugbug/nlp.py +++ b/bugbug/nlp.py @@ -3,17 +3,41 @@ # License, v. 2.0. If a copy of the MPL was not distributed with this file, # You can obtain one at http://mozilla.org/MPL/2.0/. +import sys from collections import defaultdict from functools import lru_cache i...
{"golden_diff": "diff --git a/bugbug/nlp.py b/bugbug/nlp.py\n--- a/bugbug/nlp.py\n+++ b/bugbug/nlp.py\n@@ -3,17 +3,41 @@\n # License, v. 2.0. If a copy of the MPL was not distributed with this file,\n # You can obtain one at http://mozilla.org/MPL/2.0/.\n \n+import sys\n from collections import defaultdict\n from funct...
1,765
865
gh_patches_debug_11621
rasdani/github-patches
git_diff
apache__airflow-12057
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Exception logging success function instead of failure https://github.com/apache/airflow/blob/fdd9b6f65b608c516b8a062b058972d9a45ec9e3/airflow/sensors/sql_sensor.py#L97 --- END ISSUE --- Below are some c...
diff --git a/airflow/sensors/sql_sensor.py b/airflow/sensors/sql_sensor.py --- a/airflow/sensors/sql_sensor.py +++ b/airflow/sensors/sql_sensor.py @@ -109,7 +109,7 @@ if self.failure(first_cell): raise AirflowException(f"Failure criteria met. self.failure({first_cell}) returned Tru...
{"golden_diff": "diff --git a/airflow/sensors/sql_sensor.py b/airflow/sensors/sql_sensor.py\n--- a/airflow/sensors/sql_sensor.py\n+++ b/airflow/sensors/sql_sensor.py\n@@ -109,7 +109,7 @@\n if self.failure(first_cell):\n raise AirflowException(f\"Failure criteria met. self.failure({fi...
1,626
151
gh_patches_debug_8494
rasdani/github-patches
git_diff
cloudtools__troposphere-1040
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Appsync ApiKey Expires needs to be an int The expires prop on the appsync ApiKey class needs to be an int otherwise the decimal place causes cloudformation to throw a `Can not deserialize value of type java.l...
diff --git a/troposphere/appsync.py b/troposphere/appsync.py --- a/troposphere/appsync.py +++ b/troposphere/appsync.py @@ -4,7 +4,7 @@ # See LICENSE file for full license. from . import AWSObject, AWSProperty -from .validators import boolean +from .validators import boolean, integer class ApiKey(AWSObject): @@...
{"golden_diff": "diff --git a/troposphere/appsync.py b/troposphere/appsync.py\n--- a/troposphere/appsync.py\n+++ b/troposphere/appsync.py\n@@ -4,7 +4,7 @@\n # See LICENSE file for full license.\n \n from . import AWSObject, AWSProperty\n-from .validators import boolean\n+from .validators import boolean, integer\n \n \n...
1,332
146
gh_patches_debug_2684
rasdani/github-patches
git_diff
CTFd__CTFd-1918
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Users in admin scoreboard show user position instead of team position In teams mode on the admin panel, users are shown with their user position on the scoreboard instead of their teams position. We should be...
diff --git a/CTFd/admin/users.py b/CTFd/admin/users.py --- a/CTFd/admin/users.py +++ b/CTFd/admin/users.py @@ -88,8 +88,8 @@ awards = user.get_awards(admin=True) # Get user properties - score = user.get_score(admin=True) - place = user.get_place(admin=True) + score = user.account.get_score(admin=Tr...
{"golden_diff": "diff --git a/CTFd/admin/users.py b/CTFd/admin/users.py\n--- a/CTFd/admin/users.py\n+++ b/CTFd/admin/users.py\n@@ -88,8 +88,8 @@\n awards = user.get_awards(admin=True)\n \n # Get user properties\n- score = user.get_score(admin=True)\n- place = user.get_place(admin=True)\n+ score = user....
1,217
120
gh_patches_debug_7313
rasdani/github-patches
git_diff
MycroftAI__mycroft-core-1195
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Calling the pause() function does not pause the playback This [pause() function](https://github.com/MycroftAI/mycroft-core/blob/a9d627c979b98053719200c6084f3b31a9a97c62/mycroft/skills/audioservice.py#L83) doe...
diff --git a/mycroft/skills/audioservice.py b/mycroft/skills/audioservice.py --- a/mycroft/skills/audioservice.py +++ b/mycroft/skills/audioservice.py @@ -72,6 +72,10 @@ data={'tracks': tracks, 'utterance': utterance})) + def stop(self): +...
{"golden_diff": "diff --git a/mycroft/skills/audioservice.py b/mycroft/skills/audioservice.py\n--- a/mycroft/skills/audioservice.py\n+++ b/mycroft/skills/audioservice.py\n@@ -72,6 +72,10 @@\n data={'tracks': tracks,\n 'utterance': utterance}))\n ...
1,302
132
gh_patches_debug_14746
rasdani/github-patches
git_diff
GoogleCloudPlatform__PerfKitBenchmarker-563
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Project id not respected when deleting disk in Cloudstack I forgot to pass project_id as an agrugment when deleting volume. --- END ISSUE --- Below are some code segments, each from a relevant file. One o...
diff --git a/perfkitbenchmarker/cloudstack/cloudstack_disk.py b/perfkitbenchmarker/cloudstack/cloudstack_disk.py --- a/perfkitbenchmarker/cloudstack/cloudstack_disk.py +++ b/perfkitbenchmarker/cloudstack/cloudstack_disk.py @@ -50,7 +50,7 @@ self.disk_offering_id = self._GetBestOfferingId(self.disk_size) asser...
{"golden_diff": "diff --git a/perfkitbenchmarker/cloudstack/cloudstack_disk.py b/perfkitbenchmarker/cloudstack/cloudstack_disk.py\n--- a/perfkitbenchmarker/cloudstack/cloudstack_disk.py\n+++ b/perfkitbenchmarker/cloudstack/cloudstack_disk.py\n@@ -50,7 +50,7 @@\n self.disk_offering_id = self._GetBestOfferingId(self....
1,415
198
gh_patches_debug_21325
rasdani/github-patches
git_diff
akvo__akvo-rsr-3020
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Incorrect mandatory validation for qualitative indicators The indicator measure for qualitative indicators is hidden, but the code checking for completion of sections doesn't ignore that field, and considers ...
diff --git a/akvo/iati/checks/fields/results.py b/akvo/iati/checks/fields/results.py --- a/akvo/iati/checks/fields/results.py +++ b/akvo/iati/checks/fields/results.py @@ -4,6 +4,8 @@ # See more details in the license.txt file located at the root folder of the Akvo RSR module. # For additional details on the GNU licen...
{"golden_diff": "diff --git a/akvo/iati/checks/fields/results.py b/akvo/iati/checks/fields/results.py\n--- a/akvo/iati/checks/fields/results.py\n+++ b/akvo/iati/checks/fields/results.py\n@@ -4,6 +4,8 @@\n # See more details in the license.txt file located at the root folder of the Akvo RSR module.\n # For additional de...
1,526
240
gh_patches_debug_16340
rasdani/github-patches
git_diff
qutip__qutip-2335
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Typos in qutip.expect()'s docstring ### Bug Description Two words in the docstring contain typos. See below. ### Code to Reproduce the Bug ```shell from qutip import expect print(expect.__doc__) `...
diff --git a/qutip/core/expect.py b/qutip/core/expect.py --- a/qutip/core/expect.py +++ b/qutip/core/expect.py @@ -16,7 +16,7 @@ Parameters ---------- oper : qobj/array-like - A single or a `list` or operators for expectation value. + A single or a `list` of operators for expectation value....
{"golden_diff": "diff --git a/qutip/core/expect.py b/qutip/core/expect.py\n--- a/qutip/core/expect.py\n+++ b/qutip/core/expect.py\n@@ -16,7 +16,7 @@\n Parameters\n ----------\n oper : qobj/array-like\n- A single or a `list` or operators for expectation value.\n+ A single or a `list` of operato...
1,644
220
gh_patches_debug_505
rasdani/github-patches
git_diff
googleapis__google-cloud-python-3693
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Increment threadsafety on BigQuery DB-API interface when httplib2 is removed From https://github.com/GoogleCloudPlatform/google-cloud-python/pull/2921/files/5b29a9e42a40f7c74ced0b7a7e9db0add52a20a1#r123596828...
diff --git a/bigquery/google/cloud/bigquery/dbapi/__init__.py b/bigquery/google/cloud/bigquery/dbapi/__init__.py --- a/bigquery/google/cloud/bigquery/dbapi/__init__.py +++ b/bigquery/google/cloud/bigquery/dbapi/__init__.py @@ -55,8 +55,8 @@ apilevel = '2.0' -# Threads may share the module, but not connections. -th...
{"golden_diff": "diff --git a/bigquery/google/cloud/bigquery/dbapi/__init__.py b/bigquery/google/cloud/bigquery/dbapi/__init__.py\n--- a/bigquery/google/cloud/bigquery/dbapi/__init__.py\n+++ b/bigquery/google/cloud/bigquery/dbapi/__init__.py\n@@ -55,8 +55,8 @@\n \n apilevel = '2.0'\n \n-# Threads may share the module, ...
1,213
130
gh_patches_debug_25995
rasdani/github-patches
git_diff
pytorch__vision-2979
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [DOC] Documentation for sigmoid focal loss ## 📚 Documentation Sigmoid focal loss was added to torchvision, but I think docs are not generated for it It was initalized in `init` as well [here](https://g...
diff --git a/torchvision/ops/focal_loss.py b/torchvision/ops/focal_loss.py --- a/torchvision/ops/focal_loss.py +++ b/torchvision/ops/focal_loss.py @@ -3,8 +3,8 @@ def sigmoid_focal_loss( - inputs, - targets, + inputs: torch.Tensor, + targets: torch.Tensor, alpha: float = 0.25, gamma: float = ...
{"golden_diff": "diff --git a/torchvision/ops/focal_loss.py b/torchvision/ops/focal_loss.py\n--- a/torchvision/ops/focal_loss.py\n+++ b/torchvision/ops/focal_loss.py\n@@ -3,8 +3,8 @@\n \n \n def sigmoid_focal_loss(\n- inputs,\n- targets,\n+ inputs: torch.Tensor,\n+ targets: torch.Tensor,\n alpha: float ...
880
301
gh_patches_debug_41570
rasdani/github-patches
git_diff
genialis__resolwe-328
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- 500 error returned when permission does not exist We should return 400 Bad request response. Failing unit test: https://github.com/genialis/resolwe/pull/309 --- END ISSUE --- Below are some code segments...
diff --git a/resolwe/permissions/utils.py b/resolwe/permissions/utils.py --- a/resolwe/permissions/utils.py +++ b/resolwe/permissions/utils.py @@ -14,6 +14,7 @@ from django.contrib.auth import get_user_model from django.contrib.auth.models import AnonymousUser, Group from django.contrib.contenttypes.models import Co...
{"golden_diff": "diff --git a/resolwe/permissions/utils.py b/resolwe/permissions/utils.py\n--- a/resolwe/permissions/utils.py\n+++ b/resolwe/permissions/utils.py\n@@ -14,6 +14,7 @@\n from django.contrib.auth import get_user_model\n from django.contrib.auth.models import AnonymousUser, Group\n from django.contrib.conten...
1,810
814
gh_patches_debug_3415
rasdani/github-patches
git_diff
pyro-ppl__numpyro-1041
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- New versions of sphinx and jinja2 break docs linting This is observed by @tcbegley in #1034 --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain ...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -39,9 +39,8 @@ extras_require={ "doc": [ "ipython", # sphinx needs this to render codes - "jinja2<3.0.0", - "nbsphinx", - "sphinx<4.0.0", + "nbsphinx>=0.8.5", + "sphinx", ...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -39,9 +39,8 @@\n extras_require={\n \"doc\": [\n \"ipython\", # sphinx needs this to render codes\n- \"jinja2<3.0.0\",\n- \"nbsphinx\",\n- \"sphinx<4.0.0\",\n+ \"nbs...
1,179
123
gh_patches_debug_15692
rasdani/github-patches
git_diff
ethereum__web3.py-1198
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Drop repeated rpc endpoints * Version: 4.6 ### What was wrong? web3.py has a few repeated endpoints, for example: `web3.version.net` and `web3.net.version` ### How can it be fixed? Deprecate the e...
diff --git a/web3/miner.py b/web3/miner.py --- a/web3/miner.py +++ b/web3/miner.py @@ -4,10 +4,6 @@ class Miner(Module): - @property - def hashrate(self): - return self.web3.manager.request_blocking("eth_hashrate", []) - def makeDAG(self, number): return self.web3.manager.request_blockin...
{"golden_diff": "diff --git a/web3/miner.py b/web3/miner.py\n--- a/web3/miner.py\n+++ b/web3/miner.py\n@@ -4,10 +4,6 @@\n \n \n class Miner(Module):\n- @property\n- def hashrate(self):\n- return self.web3.manager.request_blocking(\"eth_hashrate\", [])\n-\n def makeDAG(self, number):\n return se...
820
215
gh_patches_debug_20807
rasdani/github-patches
git_diff
google__flax-2540
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Make RNG name configurable in Dropout Currently `'dropout'` is hard-coded as an argument of `make_rng` inside `Dropout`. However, when implementing support for "recurrent dropout" in an LSTMCell or similar y...
diff --git a/flax/linen/stochastic.py b/flax/linen/stochastic.py --- a/flax/linen/stochastic.py +++ b/flax/linen/stochastic.py @@ -38,10 +38,12 @@ deterministic: if false the inputs are scaled by `1 / (1 - rate)` and masked, whereas if true, no mask is applied and the inputs are returned as is....
{"golden_diff": "diff --git a/flax/linen/stochastic.py b/flax/linen/stochastic.py\n--- a/flax/linen/stochastic.py\n+++ b/flax/linen/stochastic.py\n@@ -38,10 +38,12 @@\n deterministic: if false the inputs are scaled by `1 / (1 - rate)` and\n masked, whereas if true, no mask is applied and the inputs are re...
1,281
245
gh_patches_debug_3497
rasdani/github-patches
git_diff
ManimCommunity__manim-646
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- The config value `html_favicon' has type `PosixPath'; expected `str'. BTW when building the docs now I get ``` WARNING: The config value `html_favicon' has type `PosixPath'; expected `str'. ``` _Origina...
diff --git a/docs/source/conf.py b/docs/source/conf.py --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -80,7 +80,7 @@ html_theme_path = guzzle_sphinx_theme.html_theme_path() html_theme = "guzzle_sphinx_theme" -html_favicon = Path("_static/favicon.ico") +html_favicon = str(Path("_static/favicon.ico")) # Th...
{"golden_diff": "diff --git a/docs/source/conf.py b/docs/source/conf.py\n--- a/docs/source/conf.py\n+++ b/docs/source/conf.py\n@@ -80,7 +80,7 @@\n \n html_theme_path = guzzle_sphinx_theme.html_theme_path()\n html_theme = \"guzzle_sphinx_theme\"\n-html_favicon = Path(\"_static/favicon.ico\")\n+html_favicon = str(Path(\"...
1,408
113
gh_patches_debug_41816
rasdani/github-patches
git_diff
fonttools__fonttools-804
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [T2CharStringPen] Rounding coordinates? Currently, [T2CharStringPen](https://github.com/fonttools/fonttools/blob/fcd697a328b439165b3e9d04904eb73f065b6838/Lib/fontTools/pens/t2CharStringPen.py#L78) always roun...
diff --git a/Lib/fontTools/pens/t2CharStringPen.py b/Lib/fontTools/pens/t2CharStringPen.py --- a/Lib/fontTools/pens/t2CharStringPen.py +++ b/Lib/fontTools/pens/t2CharStringPen.py @@ -9,15 +9,6 @@ from fontTools.pens.basePen import BasePen -def roundInt(v): - return int(round(v)) - - -def roundIntPoint(point): -...
{"golden_diff": "diff --git a/Lib/fontTools/pens/t2CharStringPen.py b/Lib/fontTools/pens/t2CharStringPen.py\n--- a/Lib/fontTools/pens/t2CharStringPen.py\n+++ b/Lib/fontTools/pens/t2CharStringPen.py\n@@ -9,15 +9,6 @@\n from fontTools.pens.basePen import BasePen\n \n \n-def roundInt(v):\n- return int(round(v))\n-\n-\n...
1,708
965
gh_patches_debug_17604
rasdani/github-patches
git_diff
DataDog__dd-trace-py-4250
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Cannot call sqlite3.backup(db) on a TracedSQLite object Thanks for taking the time for reporting an issue! Before reporting an issue on dd-trace-py, please be sure to provide all necessary information. ...
diff --git a/ddtrace/contrib/sqlite3/patch.py b/ddtrace/contrib/sqlite3/patch.py --- a/ddtrace/contrib/sqlite3/patch.py +++ b/ddtrace/contrib/sqlite3/patch.py @@ -1,6 +1,7 @@ import os import sqlite3 import sqlite3.dbapi2 +import sys from ddtrace import config from ddtrace.vendor import wrapt @@ -75,3 +76,13 @@ ...
{"golden_diff": "diff --git a/ddtrace/contrib/sqlite3/patch.py b/ddtrace/contrib/sqlite3/patch.py\n--- a/ddtrace/contrib/sqlite3/patch.py\n+++ b/ddtrace/contrib/sqlite3/patch.py\n@@ -1,6 +1,7 @@\n import os\n import sqlite3\n import sqlite3.dbapi2\n+import sys\n \n from ddtrace import config\n from ddtrace.vendor impor...
1,259
307
gh_patches_debug_7048
rasdani/github-patches
git_diff
airctic__icevision-821
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Adding Non Unique Names To ClassMap Must Be Illegal Currently, `add_name` doesn't check if the added `name` is a duplicate or not. This should be illegal, as classes must be unique https://github.com/airct...
diff --git a/icevision/core/class_map.py b/icevision/core/class_map.py --- a/icevision/core/class_map.py +++ b/icevision/core/class_map.py @@ -44,7 +44,13 @@ else: raise e - def add_name(self, name) -> int: + def add_name(self, name: str) -> int: + # Raise error if trying to...
{"golden_diff": "diff --git a/icevision/core/class_map.py b/icevision/core/class_map.py\n--- a/icevision/core/class_map.py\n+++ b/icevision/core/class_map.py\n@@ -44,7 +44,13 @@\n else:\n raise e\n \n- def add_name(self, name) -> int:\n+ def add_name(self, name: str) -> int:\n+ ...
939
172
gh_patches_debug_42527
rasdani/github-patches
git_diff
conan-io__conan-center-index-2077
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [request] cpp-taskflow/2.5.0 ### Package Details * Package Name/Version: **cpp-taskflow/2.5.0** * Changelog: **https://taskflow.github.io/taskflow/release-2-5-0.html** Please note that `cpp-taskflo...
diff --git a/recipes/taskflow/all/conanfile.py b/recipes/taskflow/all/conanfile.py --- a/recipes/taskflow/all/conanfile.py +++ b/recipes/taskflow/all/conanfile.py @@ -1,8 +1,7 @@ -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration -from conans.model.version import Version import o...
{"golden_diff": "diff --git a/recipes/taskflow/all/conanfile.py b/recipes/taskflow/all/conanfile.py\n--- a/recipes/taskflow/all/conanfile.py\n+++ b/recipes/taskflow/all/conanfile.py\n@@ -1,8 +1,7 @@\n-from conans import ConanFile, tools\n-from conans.errors import ConanInvalidConfiguration\n-from conans.model.version i...
1,169
932
gh_patches_debug_3808
rasdani/github-patches
git_diff
ManimCommunity__manim-2197
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Create a test for resolution configuration ## Enhancement proposal A test for the `--resolution` configuration option. It should be placed [here](https://github.com/ManimCommunity/manim/blob/main/tests/test_...
diff --git a/manim/utils/commands.py b/manim/utils/commands.py --- a/manim/utils/commands.py +++ b/manim/utils/commands.py @@ -27,7 +27,7 @@ "stream=width,height,nb_frames,duration,avg_frame_rate,codec_name", "-print_format", "json", - path_to_video, + str(path_to_video), ]...
{"golden_diff": "diff --git a/manim/utils/commands.py b/manim/utils/commands.py\n--- a/manim/utils/commands.py\n+++ b/manim/utils/commands.py\n@@ -27,7 +27,7 @@\n \"stream=width,height,nb_frames,duration,avg_frame_rate,codec_name\",\n \"-print_format\",\n \"json\",\n- path_to_video,\n+ ...
799
119
gh_patches_debug_28244
rasdani/github-patches
git_diff
scrapy__scrapy-3383
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Contracts for FormRequest At the moment there's no way to create a contract for a callback that is passed a response from `FormRequest`. How about something simple like this (`ContractsManager.from_method`...
diff --git a/scrapy/contracts/__init__.py b/scrapy/contracts/__init__.py --- a/scrapy/contracts/__init__.py +++ b/scrapy/contracts/__init__.py @@ -49,16 +49,22 @@ def from_method(self, method, results): contracts = self.extract_contracts(method) if contracts: + request_cls = Request + ...
{"golden_diff": "diff --git a/scrapy/contracts/__init__.py b/scrapy/contracts/__init__.py\n--- a/scrapy/contracts/__init__.py\n+++ b/scrapy/contracts/__init__.py\n@@ -49,16 +49,22 @@\n def from_method(self, method, results):\n contracts = self.extract_contracts(method)\n if contracts:\n+ ...
1,796
311
gh_patches_debug_18067
rasdani/github-patches
git_diff
ivy-llc__ivy-13637
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- beta --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --- BEGIN FILES --- Path: `ivy/functional/frontends/jax/random.py` Content: ``` ...
diff --git a/ivy/functional/frontends/jax/random.py b/ivy/functional/frontends/jax/random.py --- a/ivy/functional/frontends/jax/random.py +++ b/ivy/functional/frontends/jax/random.py @@ -1,5 +1,6 @@ # local import ivy +from ivy.func_wrapper import with_unsupported_dtypes from ivy.functional.frontends.jax.func_wrappe...
{"golden_diff": "diff --git a/ivy/functional/frontends/jax/random.py b/ivy/functional/frontends/jax/random.py\n--- a/ivy/functional/frontends/jax/random.py\n+++ b/ivy/functional/frontends/jax/random.py\n@@ -1,5 +1,6 @@\n # local\n import ivy\n+from ivy.func_wrapper import with_unsupported_dtypes\n from ivy.functional.f...
526
327
gh_patches_debug_28361
rasdani/github-patches
git_diff
getsentry__sentry-41334
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- pip-compile and CUSTOM_COMPILE_COMMAND ### Environment SaaS (https://sentry.io/) ### Version _No response_ ### Steps to Reproduce JFYI https://github.com/getsentry/sentry/blob/2e36d4d3a3926e...
diff --git a/tools/freeze_requirements.py b/tools/freeze_requirements.py --- a/tools/freeze_requirements.py +++ b/tools/freeze_requirements.py @@ -1,6 +1,7 @@ from __future__ import annotations import argparse +import os from concurrent.futures import Future, ThreadPoolExecutor from os.path import abspath from s...
{"golden_diff": "diff --git a/tools/freeze_requirements.py b/tools/freeze_requirements.py\n--- a/tools/freeze_requirements.py\n+++ b/tools/freeze_requirements.py\n@@ -1,6 +1,7 @@\n from __future__ import annotations\n \n import argparse\n+import os\n from concurrent.futures import Future, ThreadPoolExecutor\n from os.p...
1,223
395
gh_patches_debug_9494
rasdani/github-patches
git_diff
quantopian__zipline-382
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Make ta-lib optional `ta-lib` is causing us many installation problems. We should thus make it optional. --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these file...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -1,6 +1,6 @@ #!/usr/bin/env python # -# Copyright 2013 Quantopian, Inc. +# Copyright 2014 Quantopian, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -71,...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -1,6 +1,6 @@\n #!/usr/bin/env python\n #\n-# Copyright 2013 Quantopian, Inc.\n+# Copyright 2014 Quantopian, Inc.\n #\n # Licensed under the Apache License, Version 2.0 (the \"License\");\n # you may not use this file except in complia...
1,011
153
gh_patches_debug_50307
rasdani/github-patches
git_diff
alltheplaces__alltheplaces-3345
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Spider konagrill is broken During the global build at 2021-06-16-14-42-20, spider **konagrill** failed with **0 features** and **24 errors**. Here's [the log](https://data.alltheplaces.xyz/runs/2021-06-16-14...
diff --git a/locations/spiders/kona_grill.py b/locations/spiders/kona_grill.py --- a/locations/spiders/kona_grill.py +++ b/locations/spiders/kona_grill.py @@ -88,6 +88,10 @@ oh = OpeningHours() for t in hours: + # Some day entries contain invalid week data, e.g. "Brunch" + # "B...
{"golden_diff": "diff --git a/locations/spiders/kona_grill.py b/locations/spiders/kona_grill.py\n--- a/locations/spiders/kona_grill.py\n+++ b/locations/spiders/kona_grill.py\n@@ -88,6 +88,10 @@\n oh = OpeningHours()\n \n for t in hours:\n+ # Some day entries contain invalid week data, e.g. \"...
2,036
164
gh_patches_debug_3571
rasdani/github-patches
git_diff
nerfstudio-project__nerfstudio-2076
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Doc Description Wrong Hello, I find python doc in [get_depth_image_from_path](https://github.com/nerfstudio-project/nerfstudio/blob/main/nerfstudio/data/utils/data_utils.py) is wrong about the return tens...
diff --git a/nerfstudio/data/utils/data_utils.py b/nerfstudio/data/utils/data_utils.py --- a/nerfstudio/data/utils/data_utils.py +++ b/nerfstudio/data/utils/data_utils.py @@ -74,7 +74,7 @@ interpolation: Depth value interpolation for resizing. Returns: - Depth image torch tensor with shape [width...
{"golden_diff": "diff --git a/nerfstudio/data/utils/data_utils.py b/nerfstudio/data/utils/data_utils.py\n--- a/nerfstudio/data/utils/data_utils.py\n+++ b/nerfstudio/data/utils/data_utils.py\n@@ -74,7 +74,7 @@\n interpolation: Depth value interpolation for resizing.\n \n Returns:\n- Depth image torch ...
1,452
128
gh_patches_debug_9412
rasdani/github-patches
git_diff
mitmproxy__mitmproxy-3099
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- allow_remote=false does not prevent remote access ##### Steps to reproduce the problem: 1. Run mitmproxy on a publicly routable host, with default configuration including `listen_host=""`, `listen_port=808...
diff --git a/mitmproxy/addons/allowremote.py b/mitmproxy/addons/allowremote.py --- a/mitmproxy/addons/allowremote.py +++ b/mitmproxy/addons/allowremote.py @@ -14,11 +14,13 @@ ) def clientconnect(self, layer): - address = layer.client_conn.address + address = ipaddress.ip_address(layer.clie...
{"golden_diff": "diff --git a/mitmproxy/addons/allowremote.py b/mitmproxy/addons/allowremote.py\n--- a/mitmproxy/addons/allowremote.py\n+++ b/mitmproxy/addons/allowremote.py\n@@ -14,11 +14,13 @@\n )\n \n def clientconnect(self, layer):\n- address = layer.client_conn.address\n+ address = ipaddr...
864
170
gh_patches_debug_10238
rasdani/github-patches
git_diff
quantumlib__Cirq-4003
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- optimized_for_sycamore fails when you measure more than 16 qubits ```python def thing(): q = cirq.LineQubit.range(17) c = cirq.Circuit(cirq.H.on_each(*q), cirq.measure(*q, key='z')) c = cg.opt...
diff --git a/cirq/optimizers/drop_negligible.py b/cirq/optimizers/drop_negligible.py --- a/cirq/optimizers/drop_negligible.py +++ b/cirq/optimizers/drop_negligible.py @@ -36,6 +36,8 @@ deletions: List[Tuple[int, ops.Operation]] = [] for moment_index, moment in enumerate(circuit): for op i...
{"golden_diff": "diff --git a/cirq/optimizers/drop_negligible.py b/cirq/optimizers/drop_negligible.py\n--- a/cirq/optimizers/drop_negligible.py\n+++ b/cirq/optimizers/drop_negligible.py\n@@ -36,6 +36,8 @@\n deletions: List[Tuple[int, ops.Operation]] = []\n for moment_index, moment in enumerate(circuit):...
1,573
163
gh_patches_debug_22077
rasdani/github-patches
git_diff
spack__spack-13605
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- pybind11: fix get_include() The `py-pybind11` package has a python module helper of the form: ```python import pybind11 as py print(py.get_include()) ``` which helps downstream, if they are not using...
diff --git a/var/spack/repos/builtin/packages/py-pybind11/package.py b/var/spack/repos/builtin/packages/py-pybind11/package.py --- a/var/spack/repos/builtin/packages/py-pybind11/package.py +++ b/var/spack/repos/builtin/packages/py-pybind11/package.py @@ -56,7 +56,27 @@ def setup_build_environment(self, env): ...
{"golden_diff": "diff --git a/var/spack/repos/builtin/packages/py-pybind11/package.py b/var/spack/repos/builtin/packages/py-pybind11/package.py\n--- a/var/spack/repos/builtin/packages/py-pybind11/package.py\n+++ b/var/spack/repos/builtin/packages/py-pybind11/package.py\n@@ -56,7 +56,27 @@\n def setup_build_environm...
1,962
347
gh_patches_debug_9405
rasdani/github-patches
git_diff
ivy-llc__ivy-17873
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- dropout1d --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --- BEGIN FILES --- Path: `ivy/functional/frontends/torch/nn/functional/dro...
diff --git a/ivy/functional/frontends/torch/nn/functional/dropout_functions.py b/ivy/functional/frontends/torch/nn/functional/dropout_functions.py --- a/ivy/functional/frontends/torch/nn/functional/dropout_functions.py +++ b/ivy/functional/frontends/torch/nn/functional/dropout_functions.py @@ -9,3 +9,11 @@ @with_unsup...
{"golden_diff": "diff --git a/ivy/functional/frontends/torch/nn/functional/dropout_functions.py b/ivy/functional/frontends/torch/nn/functional/dropout_functions.py\n--- a/ivy/functional/frontends/torch/nn/functional/dropout_functions.py\n+++ b/ivy/functional/frontends/torch/nn/functional/dropout_functions.py\n@@ -9,3 +...
390
251
gh_patches_debug_25242
rasdani/github-patches
git_diff
fedora-infra__bodhi-5479
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Updates sometimes get stuck in pending state From quick look, it seems that the composer does: 1. move from `f*-updates-candidate` to `f*-updates-testing` 2. do stuff 3. untag from `f*-updates-testing-pend...
diff --git a/bodhi-server/bodhi/server/tasks/check_signed_builds.py b/bodhi-server/bodhi/server/tasks/check_signed_builds.py --- a/bodhi-server/bodhi/server/tasks/check_signed_builds.py +++ b/bodhi-server/bodhi/server/tasks/check_signed_builds.py @@ -77,10 +77,16 @@ pending_signing_tag = update.release.pen...
{"golden_diff": "diff --git a/bodhi-server/bodhi/server/tasks/check_signed_builds.py b/bodhi-server/bodhi/server/tasks/check_signed_builds.py\n--- a/bodhi-server/bodhi/server/tasks/check_signed_builds.py\n+++ b/bodhi-server/bodhi/server/tasks/check_signed_builds.py\n@@ -77,10 +77,16 @@\n pending_signing_tag...
1,561
300
gh_patches_debug_10905
rasdani/github-patches
git_diff
saleor__saleor-1775
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Improving product variant behaviour ### Steps to reproduce the problem 1. Choose any product in dashboard 2. Remove all variants 3. Try to go to the product page in storefront ### What I expected to h...
diff --git a/saleor/product/forms.py b/saleor/product/forms.py --- a/saleor/product/forms.py +++ b/saleor/product/forms.py @@ -31,8 +31,8 @@ vi.image.image.url for vi in variant.variant_images.all()] for variant in variants.all()} self.widget.attrs['data-images'] = json.dumps(imag...
{"golden_diff": "diff --git a/saleor/product/forms.py b/saleor/product/forms.py\n--- a/saleor/product/forms.py\n+++ b/saleor/product/forms.py\n@@ -31,8 +31,8 @@\n vi.image.image.url for vi in variant.variant_images.all()]\n for variant in variants.all()}\n self.widget.attrs['data-ima...
877
156
gh_patches_debug_6255
rasdani/github-patches
git_diff
qtile__qtile-180
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- using Qtile.cmd_{info, debug} doesn't switch logging level It seems that critical, warning, and error do all work, though. --- END ISSUE --- Below are some code segments, each from a relevant file. One or ...
diff --git a/libqtile/log_utils.py b/libqtile/log_utils.py --- a/libqtile/log_utils.py +++ b/libqtile/log_utils.py @@ -43,7 +43,6 @@ def init_log(log_level=logging.WARNING, logger='qtile'): handler = logging.FileHandler( os.path.expanduser('~/.%s.log' % logger)) - handler.setLevel(logging.WARNING) ...
{"golden_diff": "diff --git a/libqtile/log_utils.py b/libqtile/log_utils.py\n--- a/libqtile/log_utils.py\n+++ b/libqtile/log_utils.py\n@@ -43,7 +43,6 @@\n def init_log(log_level=logging.WARNING, logger='qtile'):\n handler = logging.FileHandler(\n os.path.expanduser('~/.%s.log' % logger))\n- handler.setLe...
896
118
gh_patches_debug_20514
rasdani/github-patches
git_diff
liqd__a4-product-149
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- tile images on partner page are not cut to same size ![screenshot from 2017-11-28 12-12-35](https://user-images.githubusercontent.com/8178179/33316792-7b8fc848-d435-11e7-8723-8849b5804bce.png) --- END ISSU...
diff --git a/liqd_product/config/urls.py b/liqd_product/config/urls.py --- a/liqd_product/config/urls.py +++ b/liqd_product/config/urls.py @@ -16,6 +16,7 @@ from adhocracy4.reports.api import ReportViewSet from liqd_product.apps.partners.urlresolvers import partner_patterns from liqd_product.apps.users.decorators im...
{"golden_diff": "diff --git a/liqd_product/config/urls.py b/liqd_product/config/urls.py\n--- a/liqd_product/config/urls.py\n+++ b/liqd_product/config/urls.py\n@@ -16,6 +16,7 @@\n from adhocracy4.reports.api import ReportViewSet\n from liqd_product.apps.partners.urlresolvers import partner_patterns\n from liqd_product.a...
1,511
216
gh_patches_debug_30361
rasdani/github-patches
git_diff
pytorch__ignite-1771
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Patch MNIST dataset downloading to fix CI Currently, there is an issue with downloading MNIST dataset using torchvision. Let's introduce the following patch to our CI to fix it: - https://github.com/pytorch/...
diff --git a/examples/mnist/mnist_patch.py b/examples/mnist/mnist_patch.py deleted file mode 100644 --- a/examples/mnist/mnist_patch.py +++ /dev/null @@ -1,69 +0,0 @@ -"""Patch to fix MNIST download issue as described here: -- https://github.com/pytorch/ignite/issues/1737 -- https://github.com/pytorch/vision/issues/350...
{"golden_diff": "diff --git a/examples/mnist/mnist_patch.py b/examples/mnist/mnist_patch.py\ndeleted file mode 100644\n--- a/examples/mnist/mnist_patch.py\n+++ /dev/null\n@@ -1,69 +0,0 @@\n-\"\"\"Patch to fix MNIST download issue as described here:\n-- https://github.com/pytorch/ignite/issues/1737\n-- https://github.co...
1,095
600
gh_patches_debug_8885
rasdani/github-patches
git_diff
certbot__certbot-5861
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [1] Standardize how you’ll run mypy From http://blog.zulip.org/2016/10/13/static-types-in-python-oh-mypy/: Write tooling to [install](https://github.com/zulip/zulip/blob/master/tools/install-mypy) and [run...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -65,6 +65,10 @@ 'wheel', ] +dev3_extras = [ + 'mypy', +] + docs_extras = [ 'repoze.sphinx.autointerface', # autodoc_member_order = 'bysource', autodoc_default_flags, and #4686 @@ -110,6 +114,7 @@ install_requires=install_requir...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -65,6 +65,10 @@\n 'wheel',\n ]\n \n+dev3_extras = [\n+ 'mypy',\n+]\n+\n docs_extras = [\n 'repoze.sphinx.autointerface',\n # autodoc_member_order = 'bysource', autodoc_default_flags, and #4686\n@@ -110,6 +114,7 @@\n ...
1,917
151
gh_patches_debug_15872
rasdani/github-patches
git_diff
azavea__raster-vision-427
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Fill out model-defaults for tensorflow-od Currently we only have 1 model in model_defaults.json: https://github.com/azavea/raster-vision/blob/feature/api-refactor/src/rastervision/backend/model_defaults.j...
diff --git a/src/rastervision/backend/api.py b/src/rastervision/backend/api.py --- a/src/rastervision/backend/api.py +++ b/src/rastervision/backend/api.py @@ -13,6 +13,20 @@ ### TF Object Detection SSD_MOBILENET_V1_COCO = 'SSD_MOBILENET_V1_COCO' +SSD_MOBILENET_V2_COCO = 'SSD_MOBILENET_V2_COCO' +SSDLITE_MOBILENET_V2...
{"golden_diff": "diff --git a/src/rastervision/backend/api.py b/src/rastervision/backend/api.py\n--- a/src/rastervision/backend/api.py\n+++ b/src/rastervision/backend/api.py\n@@ -13,6 +13,20 @@\n \n ### TF Object Detection\n SSD_MOBILENET_V1_COCO = 'SSD_MOBILENET_V1_COCO'\n+SSD_MOBILENET_V2_COCO = 'SSD_MOBILENET_V2_COC...
545
441
gh_patches_debug_37445
rasdani/github-patches
git_diff
hpcaitech__ColossalAI-4815
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [tensor] fix some unittests [tensor] fix some unittests [tensor] fix some unittests --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs....
diff --git a/op_builder/gptq.py b/op_builder/gptq.py --- a/op_builder/gptq.py +++ b/op_builder/gptq.py @@ -1,19 +1,17 @@ -import os -import torch import re +import torch + from .builder import Builder -from .utils import append_nvcc_threads, get_cuda_cc_flag +from .utils import append_nvcc_threads -class GPTQBuil...
{"golden_diff": "diff --git a/op_builder/gptq.py b/op_builder/gptq.py\n--- a/op_builder/gptq.py\n+++ b/op_builder/gptq.py\n@@ -1,19 +1,17 @@\n-import os\n-import torch\n import re\n \n+import torch\n+\n from .builder import Builder\n-from .utils import append_nvcc_threads, get_cuda_cc_flag\n+from .utils import append_n...
809
815
gh_patches_debug_35667
rasdani/github-patches
git_diff
scrapy__scrapy-4799
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Usage of HttpCompressionMiddleware needs to be reflected in Scrapy stats ## Summary Usage of `HttpCompressionMiddleware` needs to be relfected in Scrapy stats. ## Motivation In order to estimate scrapy mem...
diff --git a/scrapy/downloadermiddlewares/httpcompression.py b/scrapy/downloadermiddlewares/httpcompression.py --- a/scrapy/downloadermiddlewares/httpcompression.py +++ b/scrapy/downloadermiddlewares/httpcompression.py @@ -1,10 +1,12 @@ import io +import warnings import zlib -from scrapy.utils.gz import gunzip +fro...
{"golden_diff": "diff --git a/scrapy/downloadermiddlewares/httpcompression.py b/scrapy/downloadermiddlewares/httpcompression.py\n--- a/scrapy/downloadermiddlewares/httpcompression.py\n+++ b/scrapy/downloadermiddlewares/httpcompression.py\n@@ -1,10 +1,12 @@\n import io\n+import warnings\n import zlib\n \n-from scrapy.ut...
1,644
471
gh_patches_debug_35340
rasdani/github-patches
git_diff
microsoft__playwright-python-86
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Update versions in README.md on Playwright roll --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --- BEGIN FILES --- Path: `build_driv...
diff --git a/build_driver.py b/build_driver.py --- a/build_driver.py +++ b/build_driver.py @@ -14,33 +14,52 @@ import gzip import os +import re import shutil import subprocess +from pathlib import Path -driver_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), "driver") -package_path = os.path.join...
{"golden_diff": "diff --git a/build_driver.py b/build_driver.py\n--- a/build_driver.py\n+++ b/build_driver.py\n@@ -14,33 +14,52 @@\n \n import gzip\n import os\n+import re\n import shutil\n import subprocess\n+from pathlib import Path\n \n-driver_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), \"driver\...
808
733
gh_patches_debug_1213
rasdani/github-patches
git_diff
scalableminds__webknossos-libs-312
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Convenience for wkcuber.api To open/create a dataset with the cool new high-level API the following code is required: ```python from wkcuber.api.Dataset import WKDataset from pathlib import Path ds1 =...
diff --git a/wkcuber/__init__.py b/wkcuber/__init__.py --- a/wkcuber/__init__.py +++ b/wkcuber/__init__.py @@ -1,4 +1,6 @@ +from .api.Dataset import WKDataset from .cubing import cubing from .downsampling import downsample_mags from .compress import compress_mag +from .mag import Mag from .metadata import write_web...
{"golden_diff": "diff --git a/wkcuber/__init__.py b/wkcuber/__init__.py\n--- a/wkcuber/__init__.py\n+++ b/wkcuber/__init__.py\n@@ -1,4 +1,6 @@\n+from .api.Dataset import WKDataset\n from .cubing import cubing\n from .downsampling import downsample_mags\n from .compress import compress_mag\n+from .mag import Mag\n from ...
499
103
gh_patches_debug_15531
rasdani/github-patches
git_diff
tensorflow__addons-2299
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Enable SSE4.2 and AVX support during build So the pip installed TF does not support these instruction sets by default, but modern-ish CPUs do. (Roughly CPUs after 2012). We could try this and see if there ...
diff --git a/configure.py b/configure.py --- a/configure.py +++ b/configure.py @@ -44,6 +44,10 @@ return platform.system() == "Windows" +def is_linux(): + return platform.system() == "Linux" + + def is_raspi_arm(): return os.uname()[4] == "armv7l" @@ -111,6 +115,10 @@ write("build --config=...
{"golden_diff": "diff --git a/configure.py b/configure.py\n--- a/configure.py\n+++ b/configure.py\n@@ -44,6 +44,10 @@\n return platform.system() == \"Windows\"\n \n \n+def is_linux():\n+ return platform.system() == \"Linux\"\n+\n+\n def is_raspi_arm():\n return os.uname()[4] == \"armv7l\"\n \n@@ -111,6 +115,...
1,804
211
gh_patches_debug_29909
rasdani/github-patches
git_diff
nf-core__tools-2031
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Bump minimum required Nextflow version ### Description of feature Latest stable release brings lots of new features that we probably want to use at module level (eg. `bin` directories). --- END ISSUE --- B...
diff --git a/nf_core/lint/readme.py b/nf_core/lint/readme.py --- a/nf_core/lint/readme.py +++ b/nf_core/lint/readme.py @@ -40,7 +40,7 @@ if "nextflow_badge" not in ignore_configs: # Check that there is a readme badge showing the minimum required version of Nextflow - # [![Nextflow](https://img.sh...
{"golden_diff": "diff --git a/nf_core/lint/readme.py b/nf_core/lint/readme.py\n--- a/nf_core/lint/readme.py\n+++ b/nf_core/lint/readme.py\n@@ -40,7 +40,7 @@\n \n if \"nextflow_badge\" not in ignore_configs:\n # Check that there is a readme badge showing the minimum required version of Nextflow\n- # [...
1,437
490
gh_patches_debug_937
rasdani/github-patches
git_diff
boto__boto-2166
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Invalid path check in euca-bundle-image The -i option uses convert_file in boto/roboto/param.py to verify that the path passed is, indeed, a file. This fails unless the path specified is a boring old file whi...
diff --git a/boto/roboto/param.py b/boto/roboto/param.py --- a/boto/roboto/param.py +++ b/boto/roboto/param.py @@ -46,7 +46,7 @@ @classmethod def convert_file(cls, param, value): - if os.path.isfile(value): + if os.path.exists(value) and not os.path.isdir(value): return value ...
{"golden_diff": "diff --git a/boto/roboto/param.py b/boto/roboto/param.py\n--- a/boto/roboto/param.py\n+++ b/boto/roboto/param.py\n@@ -46,7 +46,7 @@\n \n @classmethod\n def convert_file(cls, param, value):\n- if os.path.isfile(value):\n+ if os.path.exists(value) and not os.path.isdir(value):\n ...
1,750
102
gh_patches_debug_526
rasdani/github-patches
git_diff
Parsl__parsl-2302
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Remove parsl container bits This issue is to remind us to remove Parsl container support and update the docs as soon as the funcX executor is integrated-- we should switch to recommending container support th...
diff --git a/docker/app1/app1.py b/docker/app1/app1.py deleted file mode 100644 --- a/docker/app1/app1.py +++ /dev/null @@ -1,4 +0,0 @@ - -def predict(list_items): - """Returns the double of the items""" - return [i*2 for i in list_items] diff --git a/docker/app2/app2.py b/docker/app2/app2.py deleted file mode 10...
{"golden_diff": "diff --git a/docker/app1/app1.py b/docker/app1/app1.py\ndeleted file mode 100644\n--- a/docker/app1/app1.py\n+++ /dev/null\n@@ -1,4 +0,0 @@\n-\n-def predict(list_items):\n- \"\"\"Returns the double of the items\"\"\"\n- return [i*2 for i in list_items]\ndiff --git a/docker/app2/app2.py b/docker/a...
383
164
gh_patches_debug_1401
rasdani/github-patches
git_diff
ktbyers__netmiko-1073
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Huawei vrpv8 commit func issue After commiting changes on huawei vrpv8, cli on devices look like this: ``` [~HUAWEI]dot1x enable [*HUAWEI]snmp-agent sys-info version all Warning: SNMPv1/SNMPv2c is not se...
diff --git a/netmiko/huawei/huawei_ssh.py b/netmiko/huawei/huawei_ssh.py --- a/netmiko/huawei/huawei_ssh.py +++ b/netmiko/huawei/huawei_ssh.py @@ -115,6 +115,7 @@ strip_prompt=False, strip_command=False, delay_factor=delay_factor, + expect_string=r"]", ) ...
{"golden_diff": "diff --git a/netmiko/huawei/huawei_ssh.py b/netmiko/huawei/huawei_ssh.py\n--- a/netmiko/huawei/huawei_ssh.py\n+++ b/netmiko/huawei/huawei_ssh.py\n@@ -115,6 +115,7 @@\n strip_prompt=False,\n strip_command=False,\n delay_factor=delay_factor,\n+ expect_string...
1,987
104
gh_patches_debug_17030
rasdani/github-patches
git_diff
apache__tvm-6499
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [uTVM] Use an alternative CRC Library The 3rdparty crc library introduced in https://github.com/apache/incubator-tvm/pull/6334 has a license problem. We will need to replace it with a new impl or an alte...
diff --git a/python/tvm/micro/build.py b/python/tvm/micro/build.py --- a/python/tvm/micro/build.py +++ b/python/tvm/micro/build.py @@ -60,10 +60,7 @@ RUNTIME_LIB_SRC_DIRS = [os.path.join(CRT_ROOT_DIR, n) for n in CRT_RUNTIME_LIB_NAMES] + [ - os.path.join( - TVM_ROOT_DIR, - "3rdparty/mbed-os/target...
{"golden_diff": "diff --git a/python/tvm/micro/build.py b/python/tvm/micro/build.py\n--- a/python/tvm/micro/build.py\n+++ b/python/tvm/micro/build.py\n@@ -60,10 +60,7 @@\n \n \n RUNTIME_LIB_SRC_DIRS = [os.path.join(CRT_ROOT_DIR, n) for n in CRT_RUNTIME_LIB_NAMES] + [\n- os.path.join(\n- TVM_ROOT_DIR,\n- ...
1,832
285