problem_id
stringlengths
18
22
source
stringclasses
1 value
task_type
stringclasses
1 value
in_source_id
stringlengths
13
58
prompt
stringlengths
1.1k
25.4k
golden_diff
stringlengths
145
5.13k
verification_info
stringlengths
582
39.1k
num_tokens
int64
271
4.1k
num_tokens_diff
int64
47
1.02k
gh_patches_debug_67407
rasdani/github-patches
git_diff
mitmproxy__mitmproxy-1711
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- pathoc does not accept `:pa,f` to pause forever at end of message ##### Steps to reproduce the problem: `pathoc www.example.com 'get:/:pa,f'` ##### What is the expected behavior? Send request, but pause for...
diff --git a/pathod/language/writer.py b/pathod/language/writer.py --- a/pathod/language/writer.py +++ b/pathod/language/writer.py @@ -57,7 +57,9 @@ while actions: a = actions.pop() if a[1] == "pause": - time.sleep(a[2]) + time.sleep( + ...
{"golden_diff": "diff --git a/pathod/language/writer.py b/pathod/language/writer.py\n--- a/pathod/language/writer.py\n+++ b/pathod/language/writer.py\n@@ -57,7 +57,9 @@\n while actions:\n a = actions.pop()\n if a[1] == \"pause\":\n- time.sleep(a[2])\n+ time....
1,613
126
gh_patches_debug_10220
rasdani/github-patches
git_diff
open-telemetry__opentelemetry-python-391
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Missing ABC for Metric [Missing ABC](https://github.com/open-telemetry/opentelemetry-python/blob/master/opentelemetry-api/src/opentelemetry/metrics/__init__.py#L90) for `Metric` seems strange to me. I guess...
diff --git a/opentelemetry-api/src/opentelemetry/metrics/__init__.py b/opentelemetry-api/src/opentelemetry/metrics/__init__.py --- a/opentelemetry-api/src/opentelemetry/metrics/__init__.py +++ b/opentelemetry-api/src/opentelemetry/metrics/__init__.py @@ -87,13 +87,14 @@ """ -class Metric: +class Metric(abc.ABC...
{"golden_diff": "diff --git a/opentelemetry-api/src/opentelemetry/metrics/__init__.py b/opentelemetry-api/src/opentelemetry/metrics/__init__.py\n--- a/opentelemetry-api/src/opentelemetry/metrics/__init__.py\n+++ b/opentelemetry-api/src/opentelemetry/metrics/__init__.py\n@@ -87,13 +87,14 @@\n \"\"\"\n \n \n-class Me...
3,693
169
gh_patches_debug_16454
rasdani/github-patches
git_diff
huggingface__text-generation-inference-1414
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Local Install: No rule to make target 'install-flash-attention-v2' ### System Info **Release:** v1.3.4, main branch **Target**: x86_64-unknown-linux-gnu **Cargo version**: 1.70.0 **Commit sha**: 630800e...
diff --git a/server/text_generation_server/utils/flash_attn.py b/server/text_generation_server/utils/flash_attn.py --- a/server/text_generation_server/utils/flash_attn.py +++ b/server/text_generation_server/utils/flash_attn.py @@ -23,10 +23,15 @@ try: import flash_attn_2_cuda except ImportError: + ...
{"golden_diff": "diff --git a/server/text_generation_server/utils/flash_attn.py b/server/text_generation_server/utils/flash_attn.py\n--- a/server/text_generation_server/utils/flash_attn.py\n+++ b/server/text_generation_server/utils/flash_attn.py\n@@ -23,10 +23,15 @@\n try:\n import flash_attn_2_cuda\n e...
2,914
230
gh_patches_debug_22811
rasdani/github-patches
git_diff
goauthentik__authentik-9441
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Redis (Unix) Socket? **Describe your question/** Is it possible to run an authentik docker container (server and worker) with a redis unix socket rather than tcp? Directly overwriting redis variables via us...
diff --git a/lifecycle/wait_for_db.py b/lifecycle/wait_for_db.py --- a/lifecycle/wait_for_db.py +++ b/lifecycle/wait_for_db.py @@ -3,7 +3,6 @@ import authentik. This is done by the dockerfile.""" from sys import exit as sysexit from time import sleep -from urllib.parse import quote_plus from psycopg import Operat...
{"golden_diff": "diff --git a/lifecycle/wait_for_db.py b/lifecycle/wait_for_db.py\n--- a/lifecycle/wait_for_db.py\n+++ b/lifecycle/wait_for_db.py\n@@ -3,7 +3,6 @@\n import authentik. This is done by the dockerfile.\"\"\"\n from sys import exit as sysexit\n from time import sleep\n-from urllib.parse import quote_plus\n ...
2,257
266
gh_patches_debug_6997
rasdani/github-patches
git_diff
mkdocs__mkdocs-1878
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Theme files override docs_dir files on Windows As investigated and discussed in https://github.com/squidfunk/mkdocs-material/issues/1282, custom files in docs_dir are overriden by theme files. For example...
diff --git a/mkdocs/structure/files.py b/mkdocs/structure/files.py --- a/mkdocs/structure/files.py +++ b/mkdocs/structure/files.py @@ -75,6 +75,7 @@ return True for path in env.list_templates(filter_func=filter): # Theme files do not override docs_dir files + path = os.path...
{"golden_diff": "diff --git a/mkdocs/structure/files.py b/mkdocs/structure/files.py\n--- a/mkdocs/structure/files.py\n+++ b/mkdocs/structure/files.py\n@@ -75,6 +75,7 @@\n return True\n for path in env.list_templates(filter_func=filter):\n # Theme files do not override docs_dir files\n+ ...
3,522
117
gh_patches_debug_8792
rasdani/github-patches
git_diff
rasterio__rasterio-401
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- rio-merge ignores --driver Due to a [typo](https://github.com/mapbox/rasterio/blob/master/rasterio/rio/merge.py#L90): ``` python kwargs['driver'] == driver ``` Instead of: ``` python kwargs['driver'] = dr...
diff --git a/rasterio/rio/merge.py b/rasterio/rio/merge.py --- a/rasterio/rio/merge.py +++ b/rasterio/rio/merge.py @@ -87,7 +87,7 @@ output_width = int(math.ceil((bounds[2]-bounds[0])/res[0])) output_height = int(math.ceil((bounds[3]-bounds[1])/res[1])) - kwargs['drive...
{"golden_diff": "diff --git a/rasterio/rio/merge.py b/rasterio/rio/merge.py\n--- a/rasterio/rio/merge.py\n+++ b/rasterio/rio/merge.py\n@@ -87,7 +87,7 @@\n output_width = int(math.ceil((bounds[2]-bounds[0])/res[0]))\n output_height = int(math.ceil((bounds[3]-bounds[1])/res[1]))\n \n- ...
2,252
142
gh_patches_debug_18789
rasdani/github-patches
git_diff
numpy__numpy-14207
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Wrong capitalization on bitgenerator MT19937 Wrong capitalization of MT19937 in default argument values of functions in numpy.random._pickle.py ### Reproducing code example: ```python import numpy as n...
diff --git a/numpy/random/_pickle.py b/numpy/random/_pickle.py --- a/numpy/random/_pickle.py +++ b/numpy/random/_pickle.py @@ -13,7 +13,7 @@ } -def __generator_ctor(bit_generator_name='mt19937'): +def __generator_ctor(bit_generator_name='MT19937'): """ Pickling helper function that retur...
{"golden_diff": "diff --git a/numpy/random/_pickle.py b/numpy/random/_pickle.py\n--- a/numpy/random/_pickle.py\n+++ b/numpy/random/_pickle.py\n@@ -13,7 +13,7 @@\n }\n \n \n-def __generator_ctor(bit_generator_name='mt19937'):\n+def __generator_ctor(bit_generator_name='MT19937'):\n \"\"\"\n Pickl...
1,124
228
gh_patches_debug_10624
rasdani/github-patches
git_diff
mlcommons__GaNDLF-429
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Add an error check for compute dimensions not supported by GaNDLF ### > I think the error message is caused by the yaml file. My input image size is 128 x 128 . > **> this is error mesage :** `(venv_...
diff --git a/GANDLF/models/modelBase.py b/GANDLF/models/modelBase.py --- a/GANDLF/models/modelBase.py +++ b/GANDLF/models/modelBase.py @@ -78,6 +78,13 @@ self.GlobalAvgPool = GlobalAveragePooling3D self.Norm = self.get_norm_type(self.norm_type.lower(), self.n_dimensions) + else: + ...
{"golden_diff": "diff --git a/GANDLF/models/modelBase.py b/GANDLF/models/modelBase.py\n--- a/GANDLF/models/modelBase.py\n+++ b/GANDLF/models/modelBase.py\n@@ -78,6 +78,13 @@\n self.GlobalAvgPool = GlobalAveragePooling3D\n self.Norm = self.get_norm_type(self.norm_type.lower(), self.n_dimensions)\...
2,511
157
gh_patches_debug_23308
rasdani/github-patches
git_diff
pyro-ppl__numpyro-912
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- ZeroDivisionError when running SVI with num_steps < 20 Reproducible code ```python import jax import numpyro def model(): pass def guide(): pass svi = numpyro.infer.SVI(model, guide, num...
diff --git a/numpyro/infer/svi.py b/numpyro/infer/svi.py --- a/numpyro/infer/svi.py +++ b/numpyro/infer/svi.py @@ -176,15 +176,15 @@ if progress_bar: losses = [] with tqdm.trange(1, num_steps + 1) as t: - batch = num_steps // 20 + batch = max(num_steps //...
{"golden_diff": "diff --git a/numpyro/infer/svi.py b/numpyro/infer/svi.py\n--- a/numpyro/infer/svi.py\n+++ b/numpyro/infer/svi.py\n@@ -176,15 +176,15 @@\n if progress_bar:\n losses = []\n with tqdm.trange(1, num_steps + 1) as t:\n- batch = num_steps // 20\n+ ...
3,145
254
gh_patches_debug_25352
rasdani/github-patches
git_diff
OpenCTI-Platform__connectors-975
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [VXVault] Connector imports garbage data (HTML tags and blank events) ## Description The VXVault connector is importing garbage data as indicators and observables, including events like `<pre>`, </pre>` an...
diff --git a/external-import/vxvault/src/vxvault.py b/external-import/vxvault/src/vxvault.py --- a/external-import/vxvault/src/vxvault.py +++ b/external-import/vxvault/src/vxvault.py @@ -1,4 +1,5 @@ import os +import re import ssl import sys import time @@ -7,6 +8,7 @@ import certifi import yaml + from pycti i...
{"golden_diff": "diff --git a/external-import/vxvault/src/vxvault.py b/external-import/vxvault/src/vxvault.py\n--- a/external-import/vxvault/src/vxvault.py\n+++ b/external-import/vxvault/src/vxvault.py\n@@ -1,4 +1,5 @@\n import os\n+import re\n import ssl\n import sys\n import time\n@@ -7,6 +8,7 @@\n \n import certifi\...
2,340
248
gh_patches_debug_31177
rasdani/github-patches
git_diff
pypi__warehouse-9341
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Reset password doesn't work if user doesn't have verified/primary email address. **Describe the bug** Password reset is not working. I get the email, follow the link, enter the password twice, submit the f...
diff --git a/warehouse/admin/views/users.py b/warehouse/admin/views/users.py --- a/warehouse/admin/views/users.py +++ b/warehouse/admin/views/users.py @@ -14,6 +14,7 @@ import wtforms import wtforms.fields.html5 +import wtforms.validators from paginate_sqlalchemy import SqlalchemyOrmPage as SQLAlchemyORMPage fr...
{"golden_diff": "diff --git a/warehouse/admin/views/users.py b/warehouse/admin/views/users.py\n--- a/warehouse/admin/views/users.py\n+++ b/warehouse/admin/views/users.py\n@@ -14,6 +14,7 @@\n \n import wtforms\n import wtforms.fields.html5\n+import wtforms.validators\n \n from paginate_sqlalchemy import SqlalchemyOrmPag...
2,899
386
gh_patches_debug_4272
rasdani/github-patches
git_diff
akvo__akvo-rsr-3260
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Remove scrollbars when they are not necessary The home page shows a scroll bar even when there is nothing to scroll ![image](https://user-images.githubusercontent.com/315678/41148811-6578191a-6af9-11e8-846...
diff --git a/akvo/rest/views/organisation.py b/akvo/rest/views/organisation.py --- a/akvo/rest/views/organisation.py +++ b/akvo/rest/views/organisation.py @@ -106,7 +106,7 @@ # Get related objects of page at once response = { - 'project_count': all_organisations.count(), + 'project_count': org...
{"golden_diff": "diff --git a/akvo/rest/views/organisation.py b/akvo/rest/views/organisation.py\n--- a/akvo/rest/views/organisation.py\n+++ b/akvo/rest/views/organisation.py\n@@ -106,7 +106,7 @@\n \n # Get related objects of page at once\n response = {\n- 'project_count': all_organisations.count(),\n+ ...
1,967
121
gh_patches_debug_23524
rasdani/github-patches
git_diff
pypa__setuptools-2316
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Reconsidering distutils replacement strategy I first expressed concerns about the fact that `distutils` needs to be imported *after* `setuptools` in [this post](https://github.com/pypa/setuptools/pull/2143#is...
diff --git a/_distutils_hack/__init__.py b/_distutils_hack/__init__.py --- a/_distutils_hack/__init__.py +++ b/_distutils_hack/__init__.py @@ -16,9 +16,12 @@ # https://foss.heptapod.net/pypy/pypy/-/blob/be829135bc0d758997b3566062999ee8b23872b4/lib-python/3/site.py#L250 return warnings.warn( - ...
{"golden_diff": "diff --git a/_distutils_hack/__init__.py b/_distutils_hack/__init__.py\n--- a/_distutils_hack/__init__.py\n+++ b/_distutils_hack/__init__.py\n@@ -16,9 +16,12 @@\n # https://foss.heptapod.net/pypy/pypy/-/blob/be829135bc0d758997b3566062999ee8b23872b4/lib-python/3/site.py#L250\n return\n ...
1,916
360
gh_patches_debug_17513
rasdani/github-patches
git_diff
bentoml__BentoML-337
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Failing to create and API on Windows **Describe the bug** Failing to create an api on windows , `bentoml serve {saved_path}` **To Reproduce** Steps to reproduce the behavior: 1. Failing with an error...
diff --git a/bentoml/cli/__init__.py b/bentoml/cli/__init__.py --- a/bentoml/cli/__init__.py +++ b/bentoml/cli/__init__.py @@ -33,7 +33,6 @@ load_bento_service_metadata, ) from bentoml.server import BentoAPIServer, get_docs -from bentoml.server.gunicorn_server import GunicornBentoServer from bentoml.cli.click_u...
{"golden_diff": "diff --git a/bentoml/cli/__init__.py b/bentoml/cli/__init__.py\n--- a/bentoml/cli/__init__.py\n+++ b/bentoml/cli/__init__.py\n@@ -33,7 +33,6 @@\n load_bento_service_metadata,\n )\n from bentoml.server import BentoAPIServer, get_docs\n-from bentoml.server.gunicorn_server import GunicornBentoServer\n...
3,823
211
gh_patches_debug_2666
rasdani/github-patches
git_diff
netbox-community__netbox-14935
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Typo in DataSourceBulkEditForm ### Deployment Type Self-hosted ### NetBox Version v3.7.1 ### Python Version 3.8 ### Steps to Reproduce "lavel" is defined as "Enforce unique space", but I think the corr...
diff --git a/netbox/core/forms/bulk_edit.py b/netbox/core/forms/bulk_edit.py --- a/netbox/core/forms/bulk_edit.py +++ b/netbox/core/forms/bulk_edit.py @@ -21,7 +21,7 @@ enabled = forms.NullBooleanField( required=False, widget=BulkEditNullBooleanSelect(), - label=_('Enforce unique space') +...
{"golden_diff": "diff --git a/netbox/core/forms/bulk_edit.py b/netbox/core/forms/bulk_edit.py\n--- a/netbox/core/forms/bulk_edit.py\n+++ b/netbox/core/forms/bulk_edit.py\n@@ -21,7 +21,7 @@\n enabled = forms.NullBooleanField(\n required=False,\n widget=BulkEditNullBooleanSelect(),\n- label=_('...
922
105
gh_patches_debug_32942
rasdani/github-patches
git_diff
genialis__resolwe-316
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Data.create returns bad message when missing ADD permission on collection If a user tries to run a process inside a collection, but doesn't have `ADD` permission, the api returns `{"detail":"Not found."}` --...
diff --git a/resolwe/flow/views/data.py b/resolwe/flow/views/data.py --- a/resolwe/flow/views/data.py +++ b/resolwe/flow/views/data.py @@ -51,10 +51,14 @@ status=status.HTTP_400_BAD_REQUEST) if not request.user.has_perm('add_collection', obj=collection): - ...
{"golden_diff": "diff --git a/resolwe/flow/views/data.py b/resolwe/flow/views/data.py\n--- a/resolwe/flow/views/data.py\n+++ b/resolwe/flow/views/data.py\n@@ -51,10 +51,14 @@\n status=status.HTTP_400_BAD_REQUEST)\n \n if not request.user.has_perm('add_collection', obj=collect...
2,689
439
gh_patches_debug_63309
rasdani/github-patches
git_diff
scikit-hep__pyhf-924
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Remove cloudpickle constraints when updating to TensorFlow Probability v0.11 # Description Once TensorFlow Probability `v0.11.0` is released there will no longer be the need for PR #915, and so that should...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -3,8 +3,7 @@ extras_require = { 'tensorflow': [ 'tensorflow~=2.0', - 'tensorflow-probability~=0.8', - 'cloudpickle!=1.5.0', # TODO: Temp patch until tfp v0.11 + 'tensorflow-probability~=0.10', # TODO: Temp patch unti...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -3,8 +3,7 @@\n extras_require = {\n 'tensorflow': [\n 'tensorflow~=2.0',\n- 'tensorflow-probability~=0.8',\n- 'cloudpickle!=1.5.0', # TODO: Temp patch until tfp v0.11\n+ 'tensorflow-probability~=0.10'...
1,018
162
gh_patches_debug_29296
rasdani/github-patches
git_diff
ethereum__consensus-specs-1156
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Use custom types for container definitions This is the "successor" to #695 which was recently closed for staleness. I'm intending to address this alongside a rewrite of #917. --- END ISSUE --- Below are som...
diff --git a/scripts/build_spec.py b/scripts/build_spec.py --- a/scripts/build_spec.py +++ b/scripts/build_spec.py @@ -130,9 +130,10 @@ """ Given all the objects that constitute a spec, combine them into a single pyfile. """ - new_type_definitions = \ - '\n'.join(['''%s = NewType('%s', %s)''' %...
{"golden_diff": "diff --git a/scripts/build_spec.py b/scripts/build_spec.py\n--- a/scripts/build_spec.py\n+++ b/scripts/build_spec.py\n@@ -130,9 +130,10 @@\n \"\"\"\n Given all the objects that constitute a spec, combine them into a single pyfile.\n \"\"\"\n- new_type_definitions = \\\n- '\\n'.joi...
3,348
476
gh_patches_debug_1435
rasdani/github-patches
git_diff
keras-team__keras-1039
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- keras.utils.visualize_util line 9: if type(model) == Sequential Global name Sequential is not defined line 25 elif type(model) == Graph: Global name Graph is not defined --- END ISSUE --- Below are some co...
diff --git a/keras/utils/visualize_util.py b/keras/utils/visualize_util.py --- a/keras/utils/visualize_util.py +++ b/keras/utils/visualize_util.py @@ -1,7 +1,7 @@ import pydot # old pydot will not work with python3, must use one # that works with python3 such as pydot2 or pydot - +from keras.models import Sequential...
{"golden_diff": "diff --git a/keras/utils/visualize_util.py b/keras/utils/visualize_util.py\n--- a/keras/utils/visualize_util.py\n+++ b/keras/utils/visualize_util.py\n@@ -1,7 +1,7 @@\n import pydot\n # old pydot will not work with python3, must use one\n # that works with python3 such as pydot2 or pydot\n-\n+from keras...
733
112
gh_patches_debug_25466
rasdani/github-patches
git_diff
sublimelsp__LSP-1865
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Unwanted splitting on dot of the setting keys **Describe the bug** In LSP-yaml, the user can specify schema mapping like so: ``` yaml.schemas: { "https://json.schemastore.org/composer": "/*" } `...
diff --git a/plugin/core/collections.py b/plugin/core/collections.py --- a/plugin/core/collections.py +++ b/plugin/core/collections.py @@ -135,13 +135,10 @@ """ Overwrite and/or add new key-value pairs to the collection. - :param d: The overriding dictionary. Can contain nested dictio...
{"golden_diff": "diff --git a/plugin/core/collections.py b/plugin/core/collections.py\n--- a/plugin/core/collections.py\n+++ b/plugin/core/collections.py\n@@ -135,13 +135,10 @@\n \"\"\"\n Overwrite and/or add new key-value pairs to the collection.\n \n- :param d: The overriding dictionary...
2,074
323
gh_patches_debug_6143
rasdani/github-patches
git_diff
getsentry__sentry-python-2371
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- KeyError 'https,http' in async handling 1.31.0 ### How do you use Sentry? Self-hosted/on-premise ### Version 1.31.0 ### Steps to Reproduce I'm running sentry and uvicorn. We also have django-channels. On...
diff --git a/sentry_sdk/integrations/_asgi_common.py b/sentry_sdk/integrations/_asgi_common.py --- a/sentry_sdk/integrations/_asgi_common.py +++ b/sentry_sdk/integrations/_asgi_common.py @@ -43,7 +43,7 @@ if server is not None: host, port = server - default_port = {"http": 80, "https": 443, "ws":...
{"golden_diff": "diff --git a/sentry_sdk/integrations/_asgi_common.py b/sentry_sdk/integrations/_asgi_common.py\n--- a/sentry_sdk/integrations/_asgi_common.py\n+++ b/sentry_sdk/integrations/_asgi_common.py\n@@ -43,7 +43,7 @@\n \n if server is not None:\n host, port = server\n- default_port = {\"http\...
1,878
204
gh_patches_debug_19457
rasdani/github-patches
git_diff
yt-project__yt-3955
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- BUG: yt crashes on startup if the config file is invalid toml @cphyc originally noted this problem in #3831 ```bash echo "! this is invalid" > yt.toml python -c "import yt" ``` fails with the backtrace ...
diff --git a/yt/utilities/configure.py b/yt/utilities/configure.py --- a/yt/utilities/configure.py +++ b/yt/utilities/configure.py @@ -1,4 +1,5 @@ import os +import warnings from typing import Callable, List # TODO: import tomllib from the standard library instead in Python >= 3.11 @@ -83,10 +84,16 @@ ...
{"golden_diff": "diff --git a/yt/utilities/configure.py b/yt/utilities/configure.py\n--- a/yt/utilities/configure.py\n+++ b/yt/utilities/configure.py\n@@ -1,4 +1,5 @@\n import os\n+import warnings\n from typing import Callable, List\n \n # TODO: import tomllib from the standard library instead in Python >= 3.11\n@@ -83...
2,360
257
gh_patches_debug_13968
rasdani/github-patches
git_diff
Kinto__kinto-367
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- kinto init should install postgresql dependencies --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --- BEGIN FILES --- Path: `kinto/__...
diff --git a/kinto/__main__.py b/kinto/__main__.py --- a/kinto/__main__.py +++ b/kinto/__main__.py @@ -2,6 +2,8 @@ import argparse import os import sys + +import pip from six.moves import input from cliquet.scripts import cliquet from pyramid.scripts import pserve @@ -65,6 +67,13 @@ init(config_file, b...
{"golden_diff": "diff --git a/kinto/__main__.py b/kinto/__main__.py\n--- a/kinto/__main__.py\n+++ b/kinto/__main__.py\n@@ -2,6 +2,8 @@\n import argparse\n import os\n import sys\n+\n+import pip\n from six.moves import input\n from cliquet.scripts import cliquet\n from pyramid.scripts import pserve\n@@ -65,6 +67,13 @@\n...
907
183
gh_patches_debug_35134
rasdani/github-patches
git_diff
urllib3__urllib3-1036
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Differentiate socks5h from socks5 and socks4a from socks4 when handling proxy string In a proxy string, socks5h:// and socks4a:// mean that the hostname is resolved by the SOCKS server. socks5:// and socks4...
diff --git a/dummyserver/testcase.py b/dummyserver/testcase.py --- a/dummyserver/testcase.py +++ b/dummyserver/testcase.py @@ -1,4 +1,4 @@ -import unittest +import sys import socket import threading from nose.plugins.skip import SkipTest @@ -13,6 +13,11 @@ from dummyserver.handlers import TestingApp from dummyserv...
{"golden_diff": "diff --git a/dummyserver/testcase.py b/dummyserver/testcase.py\n--- a/dummyserver/testcase.py\n+++ b/dummyserver/testcase.py\n@@ -1,4 +1,4 @@\n-import unittest\n+import sys\n import socket\n import threading\n from nose.plugins.skip import SkipTest\n@@ -13,6 +13,11 @@\n from dummyserver.handlers import...
3,966
503
gh_patches_debug_5332
rasdani/github-patches
git_diff
feast-dev__feast-2111
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Feast setup script returns "'charmap' codec can't decode byte" on Windows ## Expected Behavior `pip install -e "sdk/python[ci]"` must succeed and install feast package in editable mode. ## Current Behav...
diff --git a/sdk/python/setup.py b/sdk/python/setup.py --- a/sdk/python/setup.py +++ b/sdk/python/setup.py @@ -126,7 +126,7 @@ # README file from Feast repo root directory README_FILE = os.path.join(repo_root, "README.md") -with open(README_FILE, "r") as f: +with open(README_FILE, "r", encoding="utf8") as f: L...
{"golden_diff": "diff --git a/sdk/python/setup.py b/sdk/python/setup.py\n--- a/sdk/python/setup.py\n+++ b/sdk/python/setup.py\n@@ -126,7 +126,7 @@\n \n # README file from Feast repo root directory\n README_FILE = os.path.join(repo_root, \"README.md\")\n-with open(README_FILE, \"r\") as f:\n+with open(README_FILE, \"r\"...
3,975
126
gh_patches_debug_355
rasdani/github-patches
git_diff
AnalogJ__lexicon-479
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- GoDaddy provider should recognize domaincontrol.com as its nameserver For the auto provider, it should recognize that domains managed by GoDaddy often have nameservers under the *.domaincontrol.com namespace....
diff --git a/lexicon/providers/godaddy.py b/lexicon/providers/godaddy.py --- a/lexicon/providers/godaddy.py +++ b/lexicon/providers/godaddy.py @@ -13,7 +13,7 @@ LOGGER = logging.getLogger(__name__) -NAMESERVER_DOMAINS = ['godaddy.com'] +NAMESERVER_DOMAINS = ['godaddy.com', 'domaincontrol.com'] def provider_pa...
{"golden_diff": "diff --git a/lexicon/providers/godaddy.py b/lexicon/providers/godaddy.py\n--- a/lexicon/providers/godaddy.py\n+++ b/lexicon/providers/godaddy.py\n@@ -13,7 +13,7 @@\n \n LOGGER = logging.getLogger(__name__)\n \n-NAMESERVER_DOMAINS = ['godaddy.com']\n+NAMESERVER_DOMAINS = ['godaddy.com', 'domaincontrol.c...
3,860
99
gh_patches_debug_7672
rasdani/github-patches
git_diff
googleapis__python-bigquery-948
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Expand the list of dependencies to run pre-release tests against Context: https://github.com/googleapis/python-bigquery/issues/885 BigQuery Python client implicitly depended on `pytz` - this dependency was...
diff --git a/noxfile.py b/noxfile.py --- a/noxfile.py +++ b/noxfile.py @@ -214,7 +214,15 @@ session.install( "--extra-index-url", "https://pypi.fury.io/arrow-nightlies/", "--pre", "pyarrow" ) - session.install("--pre", "grpcio", "pandas") + session.install( + "--pre", + "google-ap...
{"golden_diff": "diff --git a/noxfile.py b/noxfile.py\n--- a/noxfile.py\n+++ b/noxfile.py\n@@ -214,7 +214,15 @@\n session.install(\n \"--extra-index-url\", \"https://pypi.fury.io/arrow-nightlies/\", \"--pre\", \"pyarrow\"\n )\n- session.install(\"--pre\", \"grpcio\", \"pandas\")\n+ session.install...
4,005
165
gh_patches_debug_33610
rasdani/github-patches
git_diff
litestar-org__litestar-183
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- `from starlite import *` broken if `testing` extra not installed This is only an issue on main, not in any release. When I want to try a library out, I'll install it into a fresh env, run python repl and d...
diff --git a/starlite/__init__.py b/starlite/__init__.py --- a/starlite/__init__.py +++ b/starlite/__init__.py @@ -1,4 +1,4 @@ -from typing import TYPE_CHECKING, Any +from typing import Any from starlite.datastructures import File, Redirect, State, Stream, Template @@ -57,10 +57,6 @@ from .routes import BaseRoute...
{"golden_diff": "diff --git a/starlite/__init__.py b/starlite/__init__.py\n--- a/starlite/__init__.py\n+++ b/starlite/__init__.py\n@@ -1,4 +1,4 @@\n-from typing import TYPE_CHECKING, Any\n+from typing import Any\n \n from starlite.datastructures import File, Redirect, State, Stream, Template\n \n@@ -57,10 +57,6 @@\n fr...
1,510
471
gh_patches_debug_29079
rasdani/github-patches
git_diff
pulp__pulpcore-133
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Cleanup old publications - general cleanup **Is your feature request related to a problem? Please describe.** We do a lot of different new repos and publications - and also delete them after certain time. N...
diff --git a/pulpcore/app/serializers/publication.py b/pulpcore/app/serializers/publication.py --- a/pulpcore/app/serializers/publication.py +++ b/pulpcore/app/serializers/publication.py @@ -92,6 +92,22 @@ class BaseDistributionSerializer(MasterModelSerializer): + """ + The Serializer for the BaseDistributio...
{"golden_diff": "diff --git a/pulpcore/app/serializers/publication.py b/pulpcore/app/serializers/publication.py\n--- a/pulpcore/app/serializers/publication.py\n+++ b/pulpcore/app/serializers/publication.py\n@@ -92,6 +92,22 @@\n \n \n class BaseDistributionSerializer(MasterModelSerializer):\n+ \"\"\"\n+ The Serial...
2,357
362
gh_patches_debug_14782
rasdani/github-patches
git_diff
Textualize__textual-1359
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Validators and watchers should run hand-in-hand When `init=True` in a `reactive` attribute, the `watch_` method for that attribute run, but the `validate_` method does not. This seems rather confusing and we ...
diff --git a/src/textual/reactive.py b/src/textual/reactive.py --- a/src/textual/reactive.py +++ b/src/textual/reactive.py @@ -177,8 +177,8 @@ validate_function = getattr(obj, f"validate_{name}", None) # Check if this is the first time setting the value first_set = getattr(obj, f"__first_set_...
{"golden_diff": "diff --git a/src/textual/reactive.py b/src/textual/reactive.py\n--- a/src/textual/reactive.py\n+++ b/src/textual/reactive.py\n@@ -177,8 +177,8 @@\n validate_function = getattr(obj, f\"validate_{name}\", None)\n # Check if this is the first time setting the value\n first_set = ge...
4,020
174
gh_patches_debug_38574
rasdani/github-patches
git_diff
electricitymaps__electricitymaps-contrib-1305
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- CL-SIC parser returns wrong datetime CL-SIC parser returns datetime of 0018 instead of 2018, as illustrated below: `datetime: 0018-02-18 (06:43:00.000) CET` `production: {"unknown":0,"coal":2206.6,"hydro"...
diff --git a/parsers/lib/quality.py b/parsers/lib/quality.py --- a/parsers/lib/quality.py +++ b/parsers/lib/quality.py @@ -8,11 +8,26 @@ pass +def validate_reasonable_time(item, k): + data_time = arrow.get(item['datetime']) + if data_time.year < 2000: + raise ValidationError("Data from %s can't be...
{"golden_diff": "diff --git a/parsers/lib/quality.py b/parsers/lib/quality.py\n--- a/parsers/lib/quality.py\n+++ b/parsers/lib/quality.py\n@@ -8,11 +8,26 @@\n pass\n \n \n+def validate_reasonable_time(item, k):\n+ data_time = arrow.get(item['datetime'])\n+ if data_time.year < 2000:\n+ raise ValidationE...
1,277
670
gh_patches_debug_1852
rasdani/github-patches
git_diff
jazzband__pip-tools-488
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Providing a source file which does not have an extension writes to a .txt file in current dir If you happen to use an extensionless filename as a source of requirements in, pip-compile will deduce the wrong o...
diff --git a/piptools/scripts/compile.py b/piptools/scripts/compile.py --- a/piptools/scripts/compile.py +++ b/piptools/scripts/compile.py @@ -92,7 +92,7 @@ if output_file: dst_file = output_file else: - base_name, _, _ = src_files[0].rpartition('.') + base_name = src_files[0].rsplit('....
{"golden_diff": "diff --git a/piptools/scripts/compile.py b/piptools/scripts/compile.py\n--- a/piptools/scripts/compile.py\n+++ b/piptools/scripts/compile.py\n@@ -92,7 +92,7 @@\n if output_file:\n dst_file = output_file\n else:\n- base_name, _, _ = src_files[0].rpartition('.')\n+ base_name...
3,558
119
gh_patches_debug_10762
rasdani/github-patches
git_diff
open-telemetry__opentelemetry-python-contrib-363
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- opentelemetry-instrumentation-grpc fails if client channel is used as a context manager **Describe your environment** Verified on python 3.8.6 with opentelemetry 0.17b0 **Steps to reproduce** Use a g...
diff --git a/instrumentation/opentelemetry-instrumentation-grpc/src/opentelemetry/instrumentation/grpc/grpcext/_interceptor.py b/instrumentation/opentelemetry-instrumentation-grpc/src/opentelemetry/instrumentation/grpc/grpcext/_interceptor.py --- a/instrumentation/opentelemetry-instrumentation-grpc/src/opentelemetry/in...
{"golden_diff": "diff --git a/instrumentation/opentelemetry-instrumentation-grpc/src/opentelemetry/instrumentation/grpc/grpcext/_interceptor.py b/instrumentation/opentelemetry-instrumentation-grpc/src/opentelemetry/instrumentation/grpc/grpcext/_interceptor.py\n--- a/instrumentation/opentelemetry-instrumentation-grpc/sr...
3,457
208
gh_patches_debug_10020
rasdani/github-patches
git_diff
onnx__sklearn-onnx-440
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- SelectFromModel converted model with threshold such that no features selected give error SelectFromModel model in Scikit with threshold such that no features are selected returns an array of shape (M, 0), whe...
diff --git a/skl2onnx/operator_converters/feature_selection.py b/skl2onnx/operator_converters/feature_selection.py --- a/skl2onnx/operator_converters/feature_selection.py +++ b/skl2onnx/operator_converters/feature_selection.py @@ -14,6 +14,11 @@ op = operator.raw_operator # Get indices of the features selecte...
{"golden_diff": "diff --git a/skl2onnx/operator_converters/feature_selection.py b/skl2onnx/operator_converters/feature_selection.py\n--- a/skl2onnx/operator_converters/feature_selection.py\n+++ b/skl2onnx/operator_converters/feature_selection.py\n@@ -14,6 +14,11 @@\n op = operator.raw_operator\n # Get indices o...
954
174
gh_patches_debug_42030
rasdani/github-patches
git_diff
ManageIQ__integration_tests-3352
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Check if we have fallback if no trackerbot URL specified We had some issues htat people with no trackerbot URL in config were not able to run test: - Investigate what is happening - Add fallback (do not check...
diff --git a/fixtures/provider.py b/fixtures/provider.py --- a/fixtures/provider.py +++ b/fixtures/provider.py @@ -9,6 +9,7 @@ """ import pytest +import six from fixtures.artifactor_plugin import art_client, get_test_idents from fixtures.templateloader import TEMPLATES @@ -41,7 +42,7 @@ try: provi...
{"golden_diff": "diff --git a/fixtures/provider.py b/fixtures/provider.py\n--- a/fixtures/provider.py\n+++ b/fixtures/provider.py\n@@ -9,6 +9,7 @@\n \n \"\"\"\n import pytest\n+import six\n \n from fixtures.artifactor_plugin import art_client, get_test_idents\n from fixtures.templateloader import TEMPLATES\n@@ -41,7 +4...
1,679
756
gh_patches_debug_23580
rasdani/github-patches
git_diff
mitmproxy__mitmproxy-3516
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Confusing confdir argument My tests are messy cause I used mitmproxy and mitmdump, both of them in 4.0.1 and 4.0.3 and now I mixed all cases. At some point, I think I had an error saying that --confdir was...
diff --git a/mitmproxy/tools/_main.py b/mitmproxy/tools/_main.py --- a/mitmproxy/tools/_main.py +++ b/mitmproxy/tools/_main.py @@ -87,7 +87,7 @@ arg_check.check() sys.exit(1) try: - opts.confdir = args.confdir + opts.set(*args.setoptions, defer=True) optmanager.load_paths( ...
{"golden_diff": "diff --git a/mitmproxy/tools/_main.py b/mitmproxy/tools/_main.py\n--- a/mitmproxy/tools/_main.py\n+++ b/mitmproxy/tools/_main.py\n@@ -87,7 +87,7 @@\n arg_check.check()\n sys.exit(1)\n try:\n- opts.confdir = args.confdir\n+ opts.set(*args.setoptions, defer=True)\n ...
3,608
306
gh_patches_debug_15965
rasdani/github-patches
git_diff
mozilla__bugbug-121
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Add 'priority' feature In bugbug/bug_features.py --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --- BEGIN FILES --- Path: `bugbug/mod...
diff --git a/bugbug/bug_features.py b/bugbug/bug_features.py --- a/bugbug/bug_features.py +++ b/bugbug/bug_features.py @@ -162,6 +162,11 @@ return sum((commit['types'] for commit in bug['commits']), []) +class priority(object): + def __call__(self, bug): + return bug['priority'] + + def cleanup_...
{"golden_diff": "diff --git a/bugbug/bug_features.py b/bugbug/bug_features.py\n--- a/bugbug/bug_features.py\n+++ b/bugbug/bug_features.py\n@@ -162,6 +162,11 @@\n return sum((commit['types'] for commit in bug['commits']), [])\n \n \n+class priority(object):\n+ def __call__(self, bug):\n+ return bug['pr...
3,646
228
gh_patches_debug_19773
rasdani/github-patches
git_diff
akvo__akvo-rsr-4044
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Ensure UP app only lists projects that user has access --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --- BEGIN FILES --- Path: `akv...
diff --git a/akvo/rsr/views/account.py b/akvo/rsr/views/account.py --- a/akvo/rsr/views/account.py +++ b/akvo/rsr/views/account.py @@ -244,7 +244,7 @@ api_key_element.text = ApiKey.objects.get_or_create(user=user)[0].key # Published and editable projects - projects = orgs.all_projects().published() + ...
{"golden_diff": "diff --git a/akvo/rsr/views/account.py b/akvo/rsr/views/account.py\n--- a/akvo/rsr/views/account.py\n+++ b/akvo/rsr/views/account.py\n@@ -244,7 +244,7 @@\n api_key_element.text = ApiKey.objects.get_or_create(user=user)[0].key\n \n # Published and editable projects\n- projects = orgs.all_proj...
3,536
225
gh_patches_debug_12100
rasdani/github-patches
git_diff
piskvorky__gensim-681
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- KeyError: Popping a non-existing value from `_keywords` OS X 10.11.1 Python 2.7.10 gensim 0.12.4 To reproduce this in Python shell: ``` >>> import gensim.summarization >>> t = "Victor S. Sage Compare Sage 5...
diff --git a/gensim/summarization/keywords.py b/gensim/summarization/keywords.py --- a/gensim/summarization/keywords.py +++ b/gensim/summarization/keywords.py @@ -164,7 +164,7 @@ result.append(word) # appends last word if keyword and doesn't iterate for j in xrange(i + 1, len_text): ...
{"golden_diff": "diff --git a/gensim/summarization/keywords.py b/gensim/summarization/keywords.py\n--- a/gensim/summarization/keywords.py\n+++ b/gensim/summarization/keywords.py\n@@ -164,7 +164,7 @@\n result.append(word) # appends last word if keyword and doesn't iterate\n for j in xrange(...
3,314
165
gh_patches_debug_14978
rasdani/github-patches
git_diff
archlinux__archinstall-2241
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [Solved] broken intramfs, black screen Broken initramfs after clean install with encryption, kde desktop and propretary nvidia drivers. 1. Loads grub 2. Decrypt drive 3. Loads initramfs 4. Black screen wi...
diff --git a/archinstall/lib/hardware.py b/archinstall/lib/hardware.py --- a/archinstall/lib/hardware.py +++ b/archinstall/lib/hardware.py @@ -42,6 +42,7 @@ LibvaMesaDriver = 'libva-mesa-driver' Mesa = "mesa" Nvidia = 'nvidia' + NvidiaDKMS = 'nvidia-dkms' NvidiaOpen = 'nvidia-open' VulkanIntel = 'vulkan-intel...
{"golden_diff": "diff --git a/archinstall/lib/hardware.py b/archinstall/lib/hardware.py\n--- a/archinstall/lib/hardware.py\n+++ b/archinstall/lib/hardware.py\n@@ -42,6 +42,7 @@\n \tLibvaMesaDriver = 'libva-mesa-driver'\n \tMesa = \"mesa\"\n \tNvidia = 'nvidia'\n+\tNvidiaDKMS = 'nvidia-dkms'\n \tNvidiaOpen = 'nvidia-ope...
3,296
220
gh_patches_debug_39439
rasdani/github-patches
git_diff
digitalfabrik__integreat-cms-474
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Development server not starting when GVZ API not reachable ### Describe the Bug <!-- A clear and concise description of what the bug is. --> When the [GVZ API](http://gvz.integreat-app.de/api/search/expect_...
diff --git a/src/backend/settings.py b/src/backend/settings.py --- a/src/backend/settings.py +++ b/src/backend/settings.py @@ -197,7 +197,9 @@ "loggers": { "django": {"handlers": ["console"], "level": "WARN", "propagate": True,}, "api": {"handlers": ["console"], "level": "INFO", "propagate": True...
{"golden_diff": "diff --git a/src/backend/settings.py b/src/backend/settings.py\n--- a/src/backend/settings.py\n+++ b/src/backend/settings.py\n@@ -197,7 +197,9 @@\n \"loggers\": {\n \"django\": {\"handlers\": [\"console\"], \"level\": \"WARN\", \"propagate\": True,},\n \"api\": {\"handlers\": [\"con...
3,521
749
gh_patches_debug_12356
rasdani/github-patches
git_diff
mathesar-foundation__mathesar-2514
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- UX and frontend implementation for upgrades ### Notes - [Current Figma design](https://www.figma.com/file/xHb5oIqye3fnXtb2heRH34/Styling?node-id=3804%3A28864&t=HyNupYmgZ9PqjEGr-0) - [Issue with user flow](h...
diff --git a/mathesar/urls.py b/mathesar/urls.py --- a/mathesar/urls.py +++ b/mathesar/urls.py @@ -41,7 +41,7 @@ path('administration/', views.admin_home, name='admin_home'), path('administration/users/', views.admin_home, name='admin_users_home'), path('administration/users/<user_id>/', views.admin_home...
{"golden_diff": "diff --git a/mathesar/urls.py b/mathesar/urls.py\n--- a/mathesar/urls.py\n+++ b/mathesar/urls.py\n@@ -41,7 +41,7 @@\n path('administration/', views.admin_home, name='admin_home'),\n path('administration/users/', views.admin_home, name='admin_users_home'),\n path('administration/users/<user_...
1,186
165
gh_patches_debug_19852
rasdani/github-patches
git_diff
open-mmlab__mmcv-256
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Bug: Deadlock 'fix' introduced deadlock. Since https://github.com/open-mmlab/mmcv/pull/252 is merged my mmdetection code hangs after evaluation. After reverting the specific commit `git revert c203419f57c2e25...
diff --git a/mmcv/runner/hooks/logger/text.py b/mmcv/runner/hooks/logger/text.py --- a/mmcv/runner/hooks/logger/text.py +++ b/mmcv/runner/hooks/logger/text.py @@ -98,16 +98,13 @@ log_dict['iter'] = runner.inner_iter + 1 # only record lr of the first param group log_dict['lr'] = runner.current...
{"golden_diff": "diff --git a/mmcv/runner/hooks/logger/text.py b/mmcv/runner/hooks/logger/text.py\n--- a/mmcv/runner/hooks/logger/text.py\n+++ b/mmcv/runner/hooks/logger/text.py\n@@ -98,16 +98,13 @@\n log_dict['iter'] = runner.inner_iter + 1\n # only record lr of the first param group\n log_dict...
1,664
237
gh_patches_debug_15503
rasdani/github-patches
git_diff
ytdl-org__youtube-dl-16157
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- ERROR: Unable to extract video data ## Please follow the guide below - You will be asked some questions and requested to provide some information, please read them **carefully** and answer honestly - Put ...
diff --git a/youtube_dl/extractor/fxnetworks.py b/youtube_dl/extractor/fxnetworks.py --- a/youtube_dl/extractor/fxnetworks.py +++ b/youtube_dl/extractor/fxnetworks.py @@ -41,7 +41,7 @@ if 'The content you are trying to access is not available in your region.' in webpage: self.raise_geo_restricted(...
{"golden_diff": "diff --git a/youtube_dl/extractor/fxnetworks.py b/youtube_dl/extractor/fxnetworks.py\n--- a/youtube_dl/extractor/fxnetworks.py\n+++ b/youtube_dl/extractor/fxnetworks.py\n@@ -41,7 +41,7 @@\n if 'The content you are trying to access is not available in your region.' in webpage:\n self...
2,551
220
gh_patches_debug_4706
rasdani/github-patches
git_diff
sherlock-project__sherlock-2109
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- SHERLOCK// ERROR "string indices must be integers, not 'str' " como puedo solucionar este error que me sale al querer usar sherlock, no se como solucionarlo la verdad --- END ISSUE --- Below are some code ...
diff --git a/sherlock/sites.py b/sherlock/sites.py --- a/sherlock/sites.py +++ b/sherlock/sites.py @@ -177,6 +177,8 @@ raise ValueError( f"Problem parsing json contents at '{data_file_path}': Missing attribute {error}." ) + except TypeError as error: + ...
{"golden_diff": "diff --git a/sherlock/sites.py b/sherlock/sites.py\n--- a/sherlock/sites.py\n+++ b/sherlock/sites.py\n@@ -177,6 +177,8 @@\n raise ValueError(\n f\"Problem parsing json contents at '{data_file_path}': Missing attribute {error}.\"\n )\n+ exc...
2,462
114
gh_patches_debug_28686
rasdani/github-patches
git_diff
fossasia__open-event-server-4019
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Method to insert session-speaker relationship missing **I'm submitting a ...** (check one with "x") - [x] bug report - [ ] feature request - [ ] support request => Please do not submit support requests he...
diff --git a/app/api/speakers.py b/app/api/speakers.py --- a/app/api/speakers.py +++ b/app/api/speakers.py @@ -116,6 +116,9 @@ :param view_kwargs: :return: """ + if view_kwargs.get('session_id'): + session = safe_query(self, Session, 'id', view_kwargs['session_id'], 'session...
{"golden_diff": "diff --git a/app/api/speakers.py b/app/api/speakers.py\n--- a/app/api/speakers.py\n+++ b/app/api/speakers.py\n@@ -116,6 +116,9 @@\n :param view_kwargs:\n :return:\n \"\"\"\n+ if view_kwargs.get('session_id'):\n+ session = safe_query(self, Session, 'id', view_kw...
2,111
340
gh_patches_debug_30038
rasdani/github-patches
git_diff
frappe__frappe-21064
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [Proposal] Add Parameters to Webhook Request URL We use webhooks to connect erpnext to other apps and systems. Most REST-Apis contain some ids in their URL. Even Frappe does (`/api/resource/{{doctype}}/{{d...
diff --git a/frappe/integrations/doctype/webhook/webhook.py b/frappe/integrations/doctype/webhook/webhook.py --- a/frappe/integrations/doctype/webhook/webhook.py +++ b/frappe/integrations/doctype/webhook/webhook.py @@ -115,29 +115,34 @@ webhook: Webhook = frappe.get_doc("Webhook", webhook.get("name")) headers = get...
{"golden_diff": "diff --git a/frappe/integrations/doctype/webhook/webhook.py b/frappe/integrations/doctype/webhook/webhook.py\n--- a/frappe/integrations/doctype/webhook/webhook.py\n+++ b/frappe/integrations/doctype/webhook/webhook.py\n@@ -115,29 +115,34 @@\n \twebhook: Webhook = frappe.get_doc(\"Webhook\", webhook.get(...
2,405
450
gh_patches_debug_21010
rasdani/github-patches
git_diff
aws-cloudformation__cfn-lint-3169
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Condition Specified but with no condition passes linting but fails deploy ### CloudFormation Lint Version 0.83.1 ### What operating system are you using? mac/ubuntu ### Describe the bug in a cf...
diff --git a/src/cfnlint/rules/conditions/Configuration.py b/src/cfnlint/rules/conditions/Configuration.py --- a/src/cfnlint/rules/conditions/Configuration.py +++ b/src/cfnlint/rules/conditions/Configuration.py @@ -26,8 +26,10 @@ def match(self, cfn): matches = [] - conditions = cfn.template.get(...
{"golden_diff": "diff --git a/src/cfnlint/rules/conditions/Configuration.py b/src/cfnlint/rules/conditions/Configuration.py\n--- a/src/cfnlint/rules/conditions/Configuration.py\n+++ b/src/cfnlint/rules/conditions/Configuration.py\n@@ -26,8 +26,10 @@\n def match(self, cfn):\n matches = []\n \n- condit...
897
230
gh_patches_debug_43642
rasdani/github-patches
git_diff
lightly-ai__lightly-701
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- _lightly_cli is missing it's return statement as a side effect `train_model_and_embed_images` is not working as expected. --- END ISSUE --- Below are some code segments, each from a relevant file. One or mo...
diff --git a/lightly/cli/embed_cli.py b/lightly/cli/embed_cli.py --- a/lightly/cli/embed_cli.py +++ b/lightly/cli/embed_cli.py @@ -9,8 +9,10 @@ # All Rights Reserved import os +from typing import Union, Tuple, List import hydra +import numpy as np import torch import torchvision from torch.utils.hipify.hipify...
{"golden_diff": "diff --git a/lightly/cli/embed_cli.py b/lightly/cli/embed_cli.py\n--- a/lightly/cli/embed_cli.py\n+++ b/lightly/cli/embed_cli.py\n@@ -9,8 +9,10 @@\n # All Rights Reserved\n \n import os\n+from typing import Union, Tuple, List\n \n import hydra\n+import numpy as np\n import torch\n import torchvision\n ...
3,468
964
gh_patches_debug_632
rasdani/github-patches
git_diff
pex-tool__pex-2245
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Release 2.1.147 On the docket: + [x] pex does not use .pip/pip.conf to resolve packages #336 / #838 --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files m...
diff --git a/pex/version.py b/pex/version.py --- a/pex/version.py +++ b/pex/version.py @@ -1,4 +1,4 @@ # Copyright 2015 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). -__version__ = "2.1.146" +__version__ = "2.1.147"
{"golden_diff": "diff --git a/pex/version.py b/pex/version.py\n--- a/pex/version.py\n+++ b/pex/version.py\n@@ -1,4 +1,4 @@\n # Copyright 2015 Pants project contributors (see CONTRIBUTORS.md).\n # Licensed under the Apache License, Version 2.0 (see LICENSE).\n \n-__version__ = \"2.1.146\"\n+__version__ = \"2.1.147\"\n",...
351
98
gh_patches_debug_2936
rasdani/github-patches
git_diff
bookwyrm-social__bookwyrm-2387
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Internal Server Errors (e.g. on delete of user) **Describe the bug** Internal server error for some actions. I have set up a dockerless installation and am able to access the application and the admin pages...
diff --git a/bookwyrm/views/admin/reports.py b/bookwyrm/views/admin/reports.py --- a/bookwyrm/views/admin/reports.py +++ b/bookwyrm/views/admin/reports.py @@ -128,7 +128,7 @@ form.errors["password"] = ["Invalid password"] data = {"user": user, "group_form": forms.UserGroupForm(), "form": form} - return T...
{"golden_diff": "diff --git a/bookwyrm/views/admin/reports.py b/bookwyrm/views/admin/reports.py\n--- a/bookwyrm/views/admin/reports.py\n+++ b/bookwyrm/views/admin/reports.py\n@@ -128,7 +128,7 @@\n form.errors[\"password\"] = [\"Invalid password\"]\n \n data = {\"user\": user, \"group_form\": forms.UserGroupForm...
2,067
127
gh_patches_debug_12622
rasdani/github-patches
git_diff
googleapis__google-cloud-python-4754
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- BigQuery: SchemaField cannot load resource with missing `mode` property The [mode property](https://cloud.google.com/bigquery/docs/reference/rest/v2/tables#schema.fields.mode) is optional in the REST API, but...
diff --git a/bigquery/google/cloud/bigquery/schema.py b/bigquery/google/cloud/bigquery/schema.py --- a/bigquery/google/cloud/bigquery/schema.py +++ b/bigquery/google/cloud/bigquery/schema.py @@ -56,10 +56,13 @@ google.cloud.biquery.schema.SchemaField: The ``SchemaField`` object. "...
{"golden_diff": "diff --git a/bigquery/google/cloud/bigquery/schema.py b/bigquery/google/cloud/bigquery/schema.py\n--- a/bigquery/google/cloud/bigquery/schema.py\n+++ b/bigquery/google/cloud/bigquery/schema.py\n@@ -56,10 +56,13 @@\n google.cloud.biquery.schema.SchemaField:\n The ``SchemaFiel...
2,384
191
gh_patches_debug_26000
rasdani/github-patches
git_diff
oppia__oppia-17178
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [BUG]: Quiz does not automatically move to next question on input ### Describe the bug I was taking a lesson on decimal place values and when I input a correct answer, I get a message that _"Note: When y...
diff --git a/extensions/interactions/ItemSelectionInput/ItemSelectionInput.py b/extensions/interactions/ItemSelectionInput/ItemSelectionInput.py --- a/extensions/interactions/ItemSelectionInput/ItemSelectionInput.py +++ b/extensions/interactions/ItemSelectionInput/ItemSelectionInput.py @@ -39,9 +39,8 @@ # Radio bu...
{"golden_diff": "diff --git a/extensions/interactions/ItemSelectionInput/ItemSelectionInput.py b/extensions/interactions/ItemSelectionInput/ItemSelectionInput.py\n--- a/extensions/interactions/ItemSelectionInput/ItemSelectionInput.py\n+++ b/extensions/interactions/ItemSelectionInput/ItemSelectionInput.py\n@@ -39,9 +39,...
2,890
374
gh_patches_debug_8057
rasdani/github-patches
git_diff
dmlc__dgl-1478
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Loading dataset PROTEINS leads to IndexError ## 🐛 Bug <!-- A clear and concise description of what the bug is. --> When loading dataset PROTEINS using function `LegacyTUDataset()`, raise `IndexError: too...
diff --git a/python/dgl/data/tu.py b/python/dgl/data/tu.py --- a/python/dgl/data/tu.py +++ b/python/dgl/data/tu.py @@ -75,6 +75,8 @@ try: DS_node_attr = np.loadtxt( self._file_path("node_attributes"), delimiter=",") + if DS_node_attr.ndim == 1: + DS_node_...
{"golden_diff": "diff --git a/python/dgl/data/tu.py b/python/dgl/data/tu.py\n--- a/python/dgl/data/tu.py\n+++ b/python/dgl/data/tu.py\n@@ -75,6 +75,8 @@\n try:\n DS_node_attr = np.loadtxt(\n self._file_path(\"node_attributes\"), delimiter=\",\")\n+ if DS_node_attr.ndim == ...
3,583
143
gh_patches_debug_24048
rasdani/github-patches
git_diff
translate__pootle-5595
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Directory hashes are not expired when directories are added/removed if you add or remove a directory it should expire hashes on all parents and related - ie /projects/x directories --- END ISSUE --- Below a...
diff --git a/pootle/apps/pootle_revision/receivers.py b/pootle/apps/pootle_revision/receivers.py --- a/pootle/apps/pootle_revision/receivers.py +++ b/pootle/apps/pootle_revision/receivers.py @@ -6,10 +6,11 @@ # or later license. See the LICENSE file for a copy of the license and the # AUTHORS file for copyright and a...
{"golden_diff": "diff --git a/pootle/apps/pootle_revision/receivers.py b/pootle/apps/pootle_revision/receivers.py\n--- a/pootle/apps/pootle_revision/receivers.py\n+++ b/pootle/apps/pootle_revision/receivers.py\n@@ -6,10 +6,11 @@\n # or later license. See the LICENSE file for a copy of the license and the\n # AUTHORS fi...
495
319
gh_patches_debug_43900
rasdani/github-patches
git_diff
ansible__awx-8348
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- collection module tower_inventory_source_update should have "name" instead of "inventory_source" <!-- Issues are for **concrete, actionable bugs and feature requests** only - if you're just asking for debuggi...
diff --git a/awx_collection/plugins/modules/tower_inventory_source_update.py b/awx_collection/plugins/modules/tower_inventory_source_update.py --- a/awx_collection/plugins/modules/tower_inventory_source_update.py +++ b/awx_collection/plugins/modules/tower_inventory_source_update.py @@ -22,14 +22,16 @@ - Update Ans...
{"golden_diff": "diff --git a/awx_collection/plugins/modules/tower_inventory_source_update.py b/awx_collection/plugins/modules/tower_inventory_source_update.py\n--- a/awx_collection/plugins/modules/tower_inventory_source_update.py\n+++ b/awx_collection/plugins/modules/tower_inventory_source_update.py\n@@ -22,14 +22,16 ...
1,812
834
gh_patches_debug_6433
rasdani/github-patches
git_diff
scikit-image__scikit-image-5971
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- bug: imsave cannot detect right extension of pathlib imsave cannot detect right extension of pathlib ```python from pathlib import Path from skimage import io filename = Path("out.jpg") io.imsave(...
diff --git a/skimage/io/_io.py b/skimage/io/_io.py --- a/skimage/io/_io.py +++ b/skimage/io/_io.py @@ -128,6 +128,8 @@ and largest file size (default 75). This is only available when using the PIL and imageio plugins. """ + if isinstance(fname, pathlib.Path): + fname = str(fname.resolve()) ...
{"golden_diff": "diff --git a/skimage/io/_io.py b/skimage/io/_io.py\n--- a/skimage/io/_io.py\n+++ b/skimage/io/_io.py\n@@ -128,6 +128,8 @@\n and largest file size (default 75). This is only available when using\n the PIL and imageio plugins.\n \"\"\"\n+ if isinstance(fname, pathlib.Path):\n+ fnam...
2,409
135
gh_patches_debug_30833
rasdani/github-patches
git_diff
numpy__numpy-13083
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Failed to compile scipy with Anaconda gfortran. <!-- Please describe the issue in detail here, and fill in the fields below --> The compilation fails with an error and prints a command it is trying to exec...
diff --git a/numpy/distutils/fcompiler/environment.py b/numpy/distutils/fcompiler/environment.py --- a/numpy/distutils/fcompiler/environment.py +++ b/numpy/distutils/fcompiler/environment.py @@ -51,13 +51,16 @@ def _get_var(self, name, conf_desc): hook, envvar, confvar, convert, append = conf_desc + ...
{"golden_diff": "diff --git a/numpy/distutils/fcompiler/environment.py b/numpy/distutils/fcompiler/environment.py\n--- a/numpy/distutils/fcompiler/environment.py\n+++ b/numpy/distutils/fcompiler/environment.py\n@@ -51,13 +51,16 @@\n \n def _get_var(self, name, conf_desc):\n hook, envvar, confvar, convert, a...
1,899
365
gh_patches_debug_24492
rasdani/github-patches
git_diff
scikit-hep__pyhf-186
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Updated setup.py for pytorch > 0.4 dependency # Description I had 0.3.1 for Torch and that caused issues with some of the doctesting as the distributions did not have `cdf` methods. I forced an upgrade pyt...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -9,7 +9,7 @@ packages = find_packages(), include_package_data = True, install_requires = [ - 'numpy>=1.14.3', + 'numpy<=1.14.5,>=1.14.3', # required by tensorflow, mxnet, and us 'scipy' ], extras_require = { @@ -17,10 +17,18 @@...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -9,7 +9,7 @@\n packages = find_packages(),\n include_package_data = True,\n install_requires = [\n- 'numpy>=1.14.3',\n+ 'numpy<=1.14.5,>=1.14.3', # required by tensorflow, mxnet, and us\n 'scipy'\n ],\n extras_req...
722
415
gh_patches_debug_31962
rasdani/github-patches
git_diff
dbt-labs__dbt-core-1086
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- handle exceptions that occur inside of jinja ## Issue ### Issue description Given sql with invalid jinja like: ``` {{ config( materialized = "table", schema = 'custom_schema' -- render this in...
diff --git a/dbt/clients/jinja.py b/dbt/clients/jinja.py --- a/dbt/clients/jinja.py +++ b/dbt/clients/jinja.py @@ -195,9 +195,8 @@ """ This class sets up the parser to capture macros. """ - def __init__(self, hint=None, obj=None, name=None, - exc=None): - ...
{"golden_diff": "diff --git a/dbt/clients/jinja.py b/dbt/clients/jinja.py\n--- a/dbt/clients/jinja.py\n+++ b/dbt/clients/jinja.py\n@@ -195,9 +195,8 @@\n \"\"\"\n This class sets up the parser to capture macros.\n \"\"\"\n- def __init__(self, hint=None, obj=None, name=None,\n- ...
3,594
440
gh_patches_debug_24803
rasdani/github-patches
git_diff
facebookresearch__hydra-135
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Error when using strict mode and multirun Modifying the `6_sweep` example to have `@hydra.main(config_path="conf/config.yaml", strict=True)` causes this error: ```python3 6_sweep(master*)$ python3 experim...
diff --git a/plugins/submitit/hydra_plugins/submitit/submitit_launcher.py b/plugins/submitit/hydra_plugins/submitit/submitit_launcher.py --- a/plugins/submitit/hydra_plugins/submitit/submitit_launcher.py +++ b/plugins/submitit/hydra_plugins/submitit/submitit_launcher.py @@ -60,11 +60,14 @@ ) def launch(...
{"golden_diff": "diff --git a/plugins/submitit/hydra_plugins/submitit/submitit_launcher.py b/plugins/submitit/hydra_plugins/submitit/submitit_launcher.py\n--- a/plugins/submitit/hydra_plugins/submitit/submitit_launcher.py\n+++ b/plugins/submitit/hydra_plugins/submitit/submitit_launcher.py\n@@ -60,11 +60,14 @@\n ...
1,801
317
gh_patches_debug_40617
rasdani/github-patches
git_diff
rasterio__rasterio-290
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Read default of masked=None breaks for some nodatavals Back in #71, there was some controversy over the decision to have RasterReader.read's default operation as `masked=None`, which is both the slowest and m...
diff --git a/rasterio/rio/merge.py b/rasterio/rio/merge.py --- a/rasterio/rio/merge.py +++ b/rasterio/rio/merge.py @@ -92,10 +92,16 @@ kwargs['width'] = output_width kwargs['height'] = output_height + logger.debug("Kwargs: %r", kwargs) + logger.debug("bo...
{"golden_diff": "diff --git a/rasterio/rio/merge.py b/rasterio/rio/merge.py\n--- a/rasterio/rio/merge.py\n+++ b/rasterio/rio/merge.py\n@@ -92,10 +92,16 @@\n kwargs['width'] = output_width\n kwargs['height'] = output_height\n \n+ logger.debug(\"Kwargs: %r\", kwargs)\n+ ...
2,260
769
gh_patches_debug_29392
rasdani/github-patches
git_diff
goauthentik__authentik-7588
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- User write stages do not trigger a Model Updated event when writing to an existing user **Describe the bug** User write stages do not trigger a "Model updated" event when the user is existing if the stage is...
diff --git a/authentik/events/middleware.py b/authentik/events/middleware.py --- a/authentik/events/middleware.py +++ b/authentik/events/middleware.py @@ -93,21 +93,30 @@ of models""" get_response: Callable[[HttpRequest], HttpResponse] + anonymous_user: User = None def __init__(self, get_response:...
{"golden_diff": "diff --git a/authentik/events/middleware.py b/authentik/events/middleware.py\n--- a/authentik/events/middleware.py\n+++ b/authentik/events/middleware.py\n@@ -93,21 +93,30 @@\n of models\"\"\"\n \n get_response: Callable[[HttpRequest], HttpResponse]\n+ anonymous_user: User = None\n \n def...
2,413
401
gh_patches_debug_6542
rasdani/github-patches
git_diff
dbt-labs__dbt-core-3071
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Update to use new version of Hologram As an extension of https://github.com/fishtown-analytics/hologram/issues/40 -- support Mashumaro in Hologram -- makes changes to pull in version 0.0.13 of Hologram. ---...
diff --git a/core/setup.py b/core/setup.py --- a/core/setup.py +++ b/core/setup.py @@ -70,7 +70,7 @@ 'json-rpc>=1.12,<2', 'werkzeug>=0.15,<2.0', 'dataclasses==0.6;python_version<"3.7"', - # 'hologram==0.0.12', # must be updated prior to release + 'hologram==0.0.13', 'lo...
{"golden_diff": "diff --git a/core/setup.py b/core/setup.py\n--- a/core/setup.py\n+++ b/core/setup.py\n@@ -70,7 +70,7 @@\n 'json-rpc>=1.12,<2',\n 'werkzeug>=0.15,<2.0',\n 'dataclasses==0.6;python_version<\"3.7\"',\n- # 'hologram==0.0.12', # must be updated prior to release\n+ 'holo...
1,296
159
gh_patches_debug_35137
rasdani/github-patches
git_diff
LibraryOfCongress__concordia-354
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- MetricsModelMixin is missing from several models --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --- BEGIN FILES --- Path: `concordia...
diff --git a/concordia/models.py b/concordia/models.py --- a/concordia/models.py +++ b/concordia/models.py @@ -84,7 +84,7 @@ return reverse("transcriptions:campaign", args=(self.slug,)) -class Project(models.Model): +class Project(MetricsModelMixin("project"), models.Model): objects = PublicationManag...
{"golden_diff": "diff --git a/concordia/models.py b/concordia/models.py\n--- a/concordia/models.py\n+++ b/concordia/models.py\n@@ -84,7 +84,7 @@\n return reverse(\"transcriptions:campaign\", args=(self.slug,))\n \n \n-class Project(models.Model):\n+class Project(MetricsModelMixin(\"project\"), models.Model):\n ...
2,628
435
gh_patches_debug_25528
rasdani/github-patches
git_diff
scrapy__scrapy-2464
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- String value for order of Scrapy component If Scrapy component order is defined as a string, it leads to undefined behaviour on Python 2 and to the following errors on Python 3: ``` File "/usr/local/lib/pyt...
diff --git a/scrapy/utils/conf.py b/scrapy/utils/conf.py --- a/scrapy/utils/conf.py +++ b/scrapy/utils/conf.py @@ -1,5 +1,6 @@ import os import sys +import numbers from operator import itemgetter import six @@ -34,6 +35,13 @@ _check_components(compdict) return {convert(k): v for k, v in ...
{"golden_diff": "diff --git a/scrapy/utils/conf.py b/scrapy/utils/conf.py\n--- a/scrapy/utils/conf.py\n+++ b/scrapy/utils/conf.py\n@@ -1,5 +1,6 @@\n import os\n import sys\n+import numbers\n from operator import itemgetter\n \n import six\n@@ -34,6 +35,13 @@\n _check_components(compdict)\n retur...
1,544
285
gh_patches_debug_860
rasdani/github-patches
git_diff
modin-project__modin-2173
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [OmniSci] Add float32 dtype support Looks like our calcite serializer doesn't support float32 type. --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may ...
diff --git a/modin/experimental/engines/omnisci_on_ray/frame/calcite_serializer.py b/modin/experimental/engines/omnisci_on_ray/frame/calcite_serializer.py --- a/modin/experimental/engines/omnisci_on_ray/frame/calcite_serializer.py +++ b/modin/experimental/engines/omnisci_on_ray/frame/calcite_serializer.py @@ -41,6 +41,...
{"golden_diff": "diff --git a/modin/experimental/engines/omnisci_on_ray/frame/calcite_serializer.py b/modin/experimental/engines/omnisci_on_ray/frame/calcite_serializer.py\n--- a/modin/experimental/engines/omnisci_on_ray/frame/calcite_serializer.py\n+++ b/modin/experimental/engines/omnisci_on_ray/frame/calcite_serializ...
2,219
147
gh_patches_debug_7393
rasdani/github-patches
git_diff
ivy-llc__ivy-19179
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- column_stack --- 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/numpy/manipulati...
diff --git a/ivy/functional/frontends/jax/numpy/manipulations.py b/ivy/functional/frontends/jax/numpy/manipulations.py --- a/ivy/functional/frontends/jax/numpy/manipulations.py +++ b/ivy/functional/frontends/jax/numpy/manipulations.py @@ -270,6 +270,16 @@ return ivy.concat(tup, axis=0) +@to_ivy_arrays_and_back...
{"golden_diff": "diff --git a/ivy/functional/frontends/jax/numpy/manipulations.py b/ivy/functional/frontends/jax/numpy/manipulations.py\n--- a/ivy/functional/frontends/jax/numpy/manipulations.py\n+++ b/ivy/functional/frontends/jax/numpy/manipulations.py\n@@ -270,6 +270,16 @@\n return ivy.concat(tup, axis=0)\n \n \n...
3,575
226
gh_patches_debug_32161
rasdani/github-patches
git_diff
sublimelsp__LSP-937
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Keep using trigger characters, or start using selectors? For some reason the final `commit_completion` command re-triggers the completion panel "forever". I need to `esc` to hide it. ![Animation](https://u...
diff --git a/plugin/completion.py b/plugin/completion.py --- a/plugin/completion.py +++ b/plugin/completion.py @@ -171,29 +171,15 @@ # This is to make ST match with labels that have a weird prefix like a space character. self.view.settings().set("auto_complete_preserve_order", "none") - d...
{"golden_diff": "diff --git a/plugin/completion.py b/plugin/completion.py\n--- a/plugin/completion.py\n+++ b/plugin/completion.py\n@@ -171,29 +171,15 @@\n # This is to make ST match with labels that have a weird prefix like a space character.\n self.view.settings().set(\"auto_complete_preserve_o...
3,529
452
gh_patches_debug_20102
rasdani/github-patches
git_diff
Lightning-AI__torchmetrics-533
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- pit bug: the device and type of preds and target may not the same with the results returned by metric_func ## 🐛 Bug the device and type of preds and target may not the same with the results returned by me...
diff --git a/torchmetrics/functional/audio/pit.py b/torchmetrics/functional/audio/pit.py --- a/torchmetrics/functional/audio/pit.py +++ b/torchmetrics/functional/audio/pit.py @@ -151,10 +151,17 @@ # calculate the metric matrix batch_size, spk_num = target.shape[0:2] - metric_mtx = torch.empty((batch_size...
{"golden_diff": "diff --git a/torchmetrics/functional/audio/pit.py b/torchmetrics/functional/audio/pit.py\n--- a/torchmetrics/functional/audio/pit.py\n+++ b/torchmetrics/functional/audio/pit.py\n@@ -151,10 +151,17 @@\n \n # calculate the metric matrix\n batch_size, spk_num = target.shape[0:2]\n- metric_mtx =...
3,176
362
gh_patches_debug_26341
rasdani/github-patches
git_diff
freqtrade__freqtrade-1896
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- --help produces traceback Seems I broke it somehow. `python3 freqtrade hyperopt --help` produces traceback ``` Fatal exception! Traceback (most recent call last): File "/home/user/freqtrade-wrk/git...
diff --git a/freqtrade/main.py b/freqtrade/main.py --- a/freqtrade/main.py +++ b/freqtrade/main.py @@ -12,7 +12,7 @@ # flake8: noqa E402 import logging from argparse import Namespace -from typing import List +from typing import Any, List from freqtrade import OperationalException from freqtrade.arguments import ...
{"golden_diff": "diff --git a/freqtrade/main.py b/freqtrade/main.py\n--- a/freqtrade/main.py\n+++ b/freqtrade/main.py\n@@ -12,7 +12,7 @@\n # flake8: noqa E402\n import logging\n from argparse import Namespace\n-from typing import List\n+from typing import Any, List\n \n from freqtrade import OperationalException\n from...
1,410
280
gh_patches_debug_31268
rasdani/github-patches
git_diff
kornia__kornia-2131
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Weird behavior of LongestMaxSize ### Describe the bug Hello me again, I might be doing something wrong with the way I use kornia augmentations, please let me know if it is the case. I was expecting `...
diff --git a/kornia/augmentation/random_generator/_2d/resize.py b/kornia/augmentation/random_generator/_2d/resize.py --- a/kornia/augmentation/random_generator/_2d/resize.py +++ b/kornia/augmentation/random_generator/_2d/resize.py @@ -66,25 +66,27 @@ if isinstance(self.output_size, int): aspect_...
{"golden_diff": "diff --git a/kornia/augmentation/random_generator/_2d/resize.py b/kornia/augmentation/random_generator/_2d/resize.py\n--- a/kornia/augmentation/random_generator/_2d/resize.py\n+++ b/kornia/augmentation/random_generator/_2d/resize.py\n@@ -66,25 +66,27 @@\n \n if isinstance(self.output_size, int)...
1,824
543
gh_patches_debug_39944
rasdani/github-patches
git_diff
cobbler__cobbler-2919
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Security: Stabalize the MongoDB serializer ### Describe the bug This is the upstream bug report for SUSE/spacewalk#16737 which is a mirror issue of an internal Bugzilla issue. Copied from the Bugzilla c...
diff --git a/cobbler/modules/serializers/mongodb.py b/cobbler/modules/serializers/mongodb.py --- a/cobbler/modules/serializers/mongodb.py +++ b/cobbler/modules/serializers/mongodb.py @@ -21,7 +21,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA """ - +import configparser +import pat...
{"golden_diff": "diff --git a/cobbler/modules/serializers/mongodb.py b/cobbler/modules/serializers/mongodb.py\n--- a/cobbler/modules/serializers/mongodb.py\n+++ b/cobbler/modules/serializers/mongodb.py\n@@ -21,7 +21,8 @@\n Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA\n 02110-1301 USA\n \"\"\"\n-\n+imp...
1,931
715
gh_patches_debug_42727
rasdani/github-patches
git_diff
getmoto__moto-2330
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Add trusted hosts / networks to Server mode Currently (Java) AWS API can only work with Moto from the local network (if it starts with "192.168.X.X") or if the request is coming from the same host as the serv...
diff --git a/moto/server.py b/moto/server.py --- a/moto/server.py +++ b/moto/server.py @@ -58,9 +58,7 @@ if re.match(url_base, 'http://%s' % host): return backend_name - raise RuntimeError('Invalid host: "%s"' % host) - - def infer_service_region(self, environ): + de...
{"golden_diff": "diff --git a/moto/server.py b/moto/server.py\n--- a/moto/server.py\n+++ b/moto/server.py\n@@ -58,9 +58,7 @@\n if re.match(url_base, 'http://%s' % host):\n return backend_name\n \n- raise RuntimeError('Invalid host: \"%s\"' % host)\n-\n- def infer_service_re...
3,005
832
gh_patches_debug_37710
rasdani/github-patches
git_diff
localstack__localstack-4575
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- bug: State Machine references don't get resolved properly ### Is there an existing issue for this? - [X] I have searched the existing issues ### Current Behavior Lambda refs get lost ### Expected Behavior...
diff --git a/localstack/services/cloudformation/models/stepfunctions.py b/localstack/services/cloudformation/models/stepfunctions.py --- a/localstack/services/cloudformation/models/stepfunctions.py +++ b/localstack/services/cloudformation/models/stepfunctions.py @@ -1,3 +1,6 @@ +import re +from typing import Dict + fr...
{"golden_diff": "diff --git a/localstack/services/cloudformation/models/stepfunctions.py b/localstack/services/cloudformation/models/stepfunctions.py\n--- a/localstack/services/cloudformation/models/stepfunctions.py\n+++ b/localstack/services/cloudformation/models/stepfunctions.py\n@@ -1,3 +1,6 @@\n+import re\n+from ty...
1,533
654
gh_patches_debug_32187
rasdani/github-patches
git_diff
beeware__toga-1307
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Toga slider widget in android has 1 fewer tick counts than in Windows **Describe the bug** The toga.Slider widget when defined with range=(2,20), tick_count=19 instantiates a slider in Windows which has 19 t...
diff --git a/src/android/toga_android/widgets/slider.py b/src/android/toga_android/widgets/slider.py --- a/src/android/toga_android/widgets/slider.py +++ b/src/android/toga_android/widgets/slider.py @@ -35,26 +35,37 @@ def get_value(self): minimum, maximum = self.interface.range - n_steps = self....
{"golden_diff": "diff --git a/src/android/toga_android/widgets/slider.py b/src/android/toga_android/widgets/slider.py\n--- a/src/android/toga_android/widgets/slider.py\n+++ b/src/android/toga_android/widgets/slider.py\n@@ -35,26 +35,37 @@\n \n def get_value(self):\n minimum, maximum = self.interface.range\n...
3,087
552
gh_patches_debug_19491
rasdani/github-patches
git_diff
sunpy__sunpy-5493
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Fix CROTA keyword in EUI maps Currently EUI maps have a `CROTA` keyword, which by the FITS standard should really be a `CROTA2` keyword. This results in the warning ```python /home/docs/checkouts/readthedoc...
diff --git a/sunpy/map/sources/solo.py b/sunpy/map/sources/solo.py --- a/sunpy/map/sources/solo.py +++ b/sunpy/map/sources/solo.py @@ -5,6 +5,7 @@ from astropy.coordinates import CartesianRepresentation from astropy.visualization import ImageNormalize, LinearStretch +from sunpy import log from sunpy.coordinates im...
{"golden_diff": "diff --git a/sunpy/map/sources/solo.py b/sunpy/map/sources/solo.py\n--- a/sunpy/map/sources/solo.py\n+++ b/sunpy/map/sources/solo.py\n@@ -5,6 +5,7 @@\n from astropy.coordinates import CartesianRepresentation\n from astropy.visualization import ImageNormalize, LinearStretch\n \n+from sunpy import log\n ...
1,344
233
gh_patches_debug_10058
rasdani/github-patches
git_diff
docker__docker-py-1972
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Build context (.tar) is not prepared properly Hey, This morning I've updated to version `3.1.1` however, using this version i'm getting wired error from docker-engine build: ``` ERROR: Error processing t...
diff --git a/docker/utils/build.py b/docker/utils/build.py --- a/docker/utils/build.py +++ b/docker/utils/build.py @@ -93,7 +93,7 @@ # Whether this file is implicitely included / excluded. matched = default if hit is None else hit sub = list(filter(lambda p: p[1], sub)) - if os.path.is...
{"golden_diff": "diff --git a/docker/utils/build.py b/docker/utils/build.py\n--- a/docker/utils/build.py\n+++ b/docker/utils/build.py\n@@ -93,7 +93,7 @@\n # Whether this file is implicitely included / excluded.\n matched = default if hit is None else hit\n sub = list(filter(lambda p: p[1], sub))...
1,713
139
gh_patches_debug_742
rasdani/github-patches
git_diff
streamlink__streamlink-3952
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Add lxml dependency ### Checklist - [X] This is a feature request and not a different kind of issue - [X] [I have read the contribution guidelines](https://github.com/streamlink/streamlink/blob/master/CONTRI...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -12,6 +12,7 @@ deps = [ "requests>=2.26.0,<3.0", "isodate", + "lxml>=4.6.3", "websocket-client>=0.58.0", # Support for SOCKS proxies "PySocks!=1.5.7,>=1.5.6",
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -12,6 +12,7 @@\n deps = [\n \"requests>=2.26.0,<3.0\",\n \"isodate\",\n+ \"lxml>=4.6.3\",\n \"websocket-client>=0.58.0\",\n # Support for SOCKS proxies\n \"PySocks!=1.5.7,>=1.5.6\",\n", "issue": "Add lxml depend...
2,015
106
gh_patches_debug_5701
rasdani/github-patches
git_diff
getpelican__pelican-3094
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- A dead link on PyPI for the contributions and feedback I just stumbled upon [Pelican's page in PyPI](https://pypi.org/project/pelican/) and found that the l[ink for the contributions and feedback](https://pyp...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -25,6 +25,13 @@ README = open('README.rst', encoding='utf-8').read() CHANGELOG = open('docs/changelog.rst', encoding='utf-8').read() +# Relative links in the README must be converted to absolute URL's +# so that they render correctly on PyPI. +README...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -25,6 +25,13 @@\n README = open('README.rst', encoding='utf-8').read()\n CHANGELOG = open('docs/changelog.rst', encoding='utf-8').read()\n \n+# Relative links in the README must be converted to absolute URL's\n+# so that they render c...
1,194
143
gh_patches_debug_29680
rasdani/github-patches
git_diff
ARM-DOE__ACT-664
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- act.utils.decode_present_weather classification tables * ACT version: 1.4.2 * Python version: 3.9.16 * Operating System: Windows 10 ### Description I was working on decoding the FD70 present weather c...
diff --git a/act/utils/inst_utils.py b/act/utils/inst_utils.py --- a/act/utils/inst_utils.py +++ b/act/utils/inst_utils.py @@ -6,8 +6,8 @@ def decode_present_weather(ds, variable=None, decoded_name=None): """ - This function is to decode codes reported from automatic weather stations suchas the PWD22. - T...
{"golden_diff": "diff --git a/act/utils/inst_utils.py b/act/utils/inst_utils.py\n--- a/act/utils/inst_utils.py\n+++ b/act/utils/inst_utils.py\n@@ -6,8 +6,8 @@\n \n def decode_present_weather(ds, variable=None, decoded_name=None):\n \"\"\"\n- This function is to decode codes reported from automatic weather statio...
2,379
450
gh_patches_debug_5379
rasdani/github-patches
git_diff
cltk__cltk-399
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Compile Poeti d’Italia for CLTK http://www.mqdq.it/mqdq/poetiditalia/indice_autori_alfa.jsp?scelta=AZ&path=metri_opere --- END ISSUE --- Below are some code segments, each from a relevant file. One or more...
diff --git a/cltk/corpus/latin/corpora.py b/cltk/corpus/latin/corpora.py --- a/cltk/corpus/latin/corpora.py +++ b/cltk/corpus/latin/corpora.py @@ -88,5 +88,9 @@ {'location': 'remote', 'type': 'text', 'name': 'latin_text_corpus_grammaticorum_latinorum', - 'origin': 'https://github.com/cltk/latin_te...
{"golden_diff": "diff --git a/cltk/corpus/latin/corpora.py b/cltk/corpus/latin/corpora.py\n--- a/cltk/corpus/latin/corpora.py\n+++ b/cltk/corpus/latin/corpora.py\n@@ -88,5 +88,9 @@\n {'location': 'remote',\n 'type': 'text',\n 'name': 'latin_text_corpus_grammaticorum_latinorum',\n- 'origin': 'https://...
1,409
201
gh_patches_debug_9824
rasdani/github-patches
git_diff
coala__coala-1585
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- DefaultArgParser: Fix spelling mistake Change analaysis on line 30 to analysis --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --- BE...
diff --git a/coalib/parsing/DefaultArgParser.py b/coalib/parsing/DefaultArgParser.py --- a/coalib/parsing/DefaultArgParser.py +++ b/coalib/parsing/DefaultArgParser.py @@ -27,7 +27,7 @@ prog="coala", description="coala is a simple COde AnaLysis Application. Its goal " "is to make s...
{"golden_diff": "diff --git a/coalib/parsing/DefaultArgParser.py b/coalib/parsing/DefaultArgParser.py\n--- a/coalib/parsing/DefaultArgParser.py\n+++ b/coalib/parsing/DefaultArgParser.py\n@@ -27,7 +27,7 @@\n prog=\"coala\",\n description=\"coala is a simple COde AnaLysis Application. Its goal \"\n ...
1,880
154
gh_patches_debug_18951
rasdani/github-patches
git_diff
ansible__ansible-23067
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- win_domain_controller: documentation error in examples '_pass' should be '_password' <!--- Verify first that your issue/request is not already reported on GitHub. Also test if the latest release, and master...
diff --git a/lib/ansible/modules/windows/win_domain_controller.py b/lib/ansible/modules/windows/win_domain_controller.py --- a/lib/ansible/modules/windows/win_domain_controller.py +++ b/lib/ansible/modules/windows/win_domain_controller.py @@ -75,8 +75,8 @@ - win_domain_controller: dns_domain_name: ansible.vag...
{"golden_diff": "diff --git a/lib/ansible/modules/windows/win_domain_controller.py b/lib/ansible/modules/windows/win_domain_controller.py\n--- a/lib/ansible/modules/windows/win_domain_controller.py\n+++ b/lib/ansible/modules/windows/win_domain_controller.py\n@@ -75,8 +75,8 @@\n - win_domain_controller:\n dns_do...
1,812
246
gh_patches_debug_7897
rasdani/github-patches
git_diff
nautobot__nautobot-2640
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- wrong link from circuit types to circuit <!-- NOTE: IF YOUR ISSUE DOES NOT FOLLOW THIS TEMPLATE, IT WILL BE CLOSED. This form is only for reporting reproducible bugs. If you need assistance w...
diff --git a/nautobot/circuits/tables.py b/nautobot/circuits/tables.py --- a/nautobot/circuits/tables.py +++ b/nautobot/circuits/tables.py @@ -12,10 +12,13 @@ from .models import Circuit, CircuitType, Provider, ProviderNetwork CIRCUIT_TERMINATION_PARENT = """ +{% load helpers %} {% if value.provider_network %} -<a...
{"golden_diff": "diff --git a/nautobot/circuits/tables.py b/nautobot/circuits/tables.py\n--- a/nautobot/circuits/tables.py\n+++ b/nautobot/circuits/tables.py\n@@ -12,10 +12,13 @@\n from .models import Circuit, CircuitType, Provider, ProviderNetwork\n \n CIRCUIT_TERMINATION_PARENT = \"\"\"\n+{% load helpers %}\n {% if v...
1,767
168
gh_patches_debug_4998
rasdani/github-patches
git_diff
bookwyrm-social__bookwyrm-611
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Expand book data task is re-setting default editions it should not. --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --- BEGIN FILES --...
diff --git a/bookwyrm/connectors/abstract_connector.py b/bookwyrm/connectors/abstract_connector.py --- a/bookwyrm/connectors/abstract_connector.py +++ b/bookwyrm/connectors/abstract_connector.py @@ -145,8 +145,9 @@ edition.connector = self.connector edition.save() - work.default_edition = edi...
{"golden_diff": "diff --git a/bookwyrm/connectors/abstract_connector.py b/bookwyrm/connectors/abstract_connector.py\n--- a/bookwyrm/connectors/abstract_connector.py\n+++ b/bookwyrm/connectors/abstract_connector.py\n@@ -145,8 +145,9 @@\n edition.connector = self.connector\n edition.save()\n \n- wo...
2,863
133
gh_patches_debug_608
rasdani/github-patches
git_diff
pex-tool__pex-1482
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Release 2.1.51 On the docket: + [ ] UnicodeDecodeError when packaging after upgrading to v2.1.46 #1479 --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these file...
diff --git a/pex/version.py b/pex/version.py --- a/pex/version.py +++ b/pex/version.py @@ -1,4 +1,4 @@ # Copyright 2015 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). -__version__ = "2.1.50" +__version__ = "2.1.51"
{"golden_diff": "diff --git a/pex/version.py b/pex/version.py\n--- a/pex/version.py\n+++ b/pex/version.py\n@@ -1,4 +1,4 @@\n # Copyright 2015 Pants project contributors (see CONTRIBUTORS.md).\n # Licensed under the Apache License, Version 2.0 (see LICENSE).\n \n-__version__ = \"2.1.50\"\n+__version__ = \"2.1.51\"\n", "...
346
96
gh_patches_debug_22877
rasdani/github-patches
git_diff
kornia__kornia-2514
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Fix a Bug in `kornia.augmentation.RandomRain` ### Describe the bug When applying `[kornia.augmentation.RandomRain](https://kornia.readthedocs.io/en/latest/augmentation.module.html#kornia.augmentation.Ran...
diff --git a/kornia/augmentation/_2d/intensity/random_rain.py b/kornia/augmentation/_2d/intensity/random_rain.py --- a/kornia/augmentation/_2d/intensity/random_rain.py +++ b/kornia/augmentation/_2d/intensity/random_rain.py @@ -63,7 +63,7 @@ bool(torch.all(torch.abs(params['drop_width_factor']) <= image.sha...
{"golden_diff": "diff --git a/kornia/augmentation/_2d/intensity/random_rain.py b/kornia/augmentation/_2d/intensity/random_rain.py\n--- a/kornia/augmentation/_2d/intensity/random_rain.py\n+++ b/kornia/augmentation/_2d/intensity/random_rain.py\n@@ -63,7 +63,7 @@\n bool(torch.all(torch.abs(params['drop_width_f...
2,136
307
gh_patches_debug_3021
rasdani/github-patches
git_diff
mindsdb__mindsdb-1576
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Add new method to count number of rows for MySQL datasources :electric_plug: :1234: When MindsDB creates a new MySQL datasource we get information for row counts by fetching all datasources. The problem here...
diff --git a/mindsdb/integrations/mysql/mysql.py b/mindsdb/integrations/mysql/mysql.py --- a/mindsdb/integrations/mysql/mysql.py +++ b/mindsdb/integrations/mysql/mysql.py @@ -190,3 +190,10 @@ drop table if exists {self.mindsdb_database}.{self._escape_table_name(name)}; """ self._query(q) ...
{"golden_diff": "diff --git a/mindsdb/integrations/mysql/mysql.py b/mindsdb/integrations/mysql/mysql.py\n--- a/mindsdb/integrations/mysql/mysql.py\n+++ b/mindsdb/integrations/mysql/mysql.py\n@@ -190,3 +190,10 @@\n drop table if exists {self.mindsdb_database}.{self._escape_table_name(name)};\n \"\"\"...
2,505
144
gh_patches_debug_8859
rasdani/github-patches
git_diff
angr__angr-2453
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Error being raised while exploring ls This error is being thrown after a simple exploration: ``` Traceback (most recent call last): File "try.py", line 5, in <module> sm.explore() File "/home...
diff --git a/angr/procedures/linux_kernel/iovec.py b/angr/procedures/linux_kernel/iovec.py --- a/angr/procedures/linux_kernel/iovec.py +++ b/angr/procedures/linux_kernel/iovec.py @@ -17,7 +17,7 @@ iovcnt = self.state.solver.eval(iovcnt) res = 0 for element in self.state.mem[iovec].struct.iove...
{"golden_diff": "diff --git a/angr/procedures/linux_kernel/iovec.py b/angr/procedures/linux_kernel/iovec.py\n--- a/angr/procedures/linux_kernel/iovec.py\n+++ b/angr/procedures/linux_kernel/iovec.py\n@@ -17,7 +17,7 @@\n iovcnt = self.state.solver.eval(iovcnt)\n res = 0\n for element in self.state...
2,814
176
gh_patches_debug_13431
rasdani/github-patches
git_diff
comic__grand-challenge.org-1755
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- CSV export fails on converting uuid to json Problematic JSON structure in https://grand-challenge.org/api/v1/cases/images/redacted_uuid/?format=csv ``` {"pk":"redacted_uuid","name":"redacted.png","study":...
diff --git a/app/grandchallenge/core/renderers.py b/app/grandchallenge/core/renderers.py --- a/app/grandchallenge/core/renderers.py +++ b/app/grandchallenge/core/renderers.py @@ -1,5 +1,7 @@ import json +from rest_framework.settings import api_settings +from rest_framework.utils.encoders import JSONEncoder from res...
{"golden_diff": "diff --git a/app/grandchallenge/core/renderers.py b/app/grandchallenge/core/renderers.py\n--- a/app/grandchallenge/core/renderers.py\n+++ b/app/grandchallenge/core/renderers.py\n@@ -1,5 +1,7 @@\n import json\n \n+from rest_framework.settings import api_settings\n+from rest_framework.utils.encoders impo...
887
180
gh_patches_debug_494
rasdani/github-patches
git_diff
OpenNMT__OpenNMT-py-1455
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Queue full error - Multi-GPU 1M custom dataset ``` Traceback (most recent call last): File "/opt/conda/envs/learn-dev/lib/python3.7/multiprocessing/process.py", line 297, in _bootstrap self.run() ...
diff --git a/train.py b/train.py --- a/train.py +++ b/train.py @@ -124,7 +124,7 @@ # hack to dodge unpicklable `dict_keys` b.fields = list(b.fields) - q.put(b, False) + q.put(b) b = next_batch(device_id)
{"golden_diff": "diff --git a/train.py b/train.py\n--- a/train.py\n+++ b/train.py\n@@ -124,7 +124,7 @@\n \n # hack to dodge unpicklable `dict_keys`\n b.fields = list(b.fields)\n- q.put(b, False)\n+ q.put(b)\n b = next_batch(device_id)\n", "issue": "Queue full error - Multi-GPU 1M c...
2,965
78
gh_patches_debug_27459
rasdani/github-patches
git_diff
NVIDIA__apex-590
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- SyncBatchNorm doesn't support 2 dimensions input? Hi, I'm facing the issue that the program crash when the input for SyncBatchNorm is two dimensions. Here's the code: ```python import torch import apex ...
diff --git a/apex/parallel/optimized_sync_batchnorm.py b/apex/parallel/optimized_sync_batchnorm.py --- a/apex/parallel/optimized_sync_batchnorm.py +++ b/apex/parallel/optimized_sync_batchnorm.py @@ -71,7 +71,7 @@ # if input.dim() == 2, we switch to channel_last for efficient memory accessing channel_l...
{"golden_diff": "diff --git a/apex/parallel/optimized_sync_batchnorm.py b/apex/parallel/optimized_sync_batchnorm.py\n--- a/apex/parallel/optimized_sync_batchnorm.py\n+++ b/apex/parallel/optimized_sync_batchnorm.py\n@@ -71,7 +71,7 @@\n # if input.dim() == 2, we switch to channel_last for efficient memory accessi...
1,869
349
gh_patches_debug_23483
rasdani/github-patches
git_diff
getredash__redash-3088
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Access current user id/details from Python data source First of all, thanks to the authors and contributors for a very interesting and promising tool. ### Question: Is it possible to access current user ...
diff --git a/redash/query_runner/python.py b/redash/query_runner/python.py --- a/redash/query_runner/python.py +++ b/redash/query_runner/python.py @@ -211,10 +211,15 @@ return json_loads(query.latest_query_data.data) + def get_current_user(self): + return self._current_user.to_dict() + def t...
{"golden_diff": "diff --git a/redash/query_runner/python.py b/redash/query_runner/python.py\n--- a/redash/query_runner/python.py\n+++ b/redash/query_runner/python.py\n@@ -211,10 +211,15 @@\n \n return json_loads(query.latest_query_data.data)\n \n+ def get_current_user(self):\n+ return self._current_us...
3,223
231
gh_patches_debug_25801
rasdani/github-patches
git_diff
akvo__akvo-rsr-3421
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Results framework loads very slowly for projects with lot of indicator dimensions --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. ---...
diff --git a/akvo/rest/pagination.py b/akvo/rest/pagination.py --- a/akvo/rest/pagination.py +++ b/akvo/rest/pagination.py @@ -8,12 +8,18 @@ from rest_framework.response import Response -class LimitSizePageNumberPagination(pagination.PageNumberPagination): +class StandardSizePageNumberPagination(pagination.PageNum...
{"golden_diff": "diff --git a/akvo/rest/pagination.py b/akvo/rest/pagination.py\n--- a/akvo/rest/pagination.py\n+++ b/akvo/rest/pagination.py\n@@ -8,12 +8,18 @@\n from rest_framework.response import Response\n \n \n-class LimitSizePageNumberPagination(pagination.PageNumberPagination):\n+class StandardSizePageNumberPagi...
752
336
gh_patches_debug_317
rasdani/github-patches
git_diff
jazzband__pip-tools-1871
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Convert the README from rst to md <!--- Describe the changes here. ---> This PR converts the documentation from README.rst to README.md Related: https://github.com/jazzband/pip-tools/issues/1856 ##### Cont...
diff --git a/docs/conf.py b/docs/conf.py --- a/docs/conf.py +++ b/docs/conf.py @@ -52,3 +52,4 @@ # ------------------------------------------------------------------------- default_role = "any" nitpicky = True +suppress_warnings = ["myst.xref_missing"]
{"golden_diff": "diff --git a/docs/conf.py b/docs/conf.py\n--- a/docs/conf.py\n+++ b/docs/conf.py\n@@ -52,3 +52,4 @@\n # -------------------------------------------------------------------------\n default_role = \"any\"\n nitpicky = True\n+suppress_warnings = [\"myst.xref_missing\"]\n", "issue": "Convert the README fro...
841
61
gh_patches_debug_40399
rasdani/github-patches
git_diff
SeldonIO__MLServer-233
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Support MLflow current protocol As a follow-up to #167, it would be interesting to explore adding a custom endpoint to the `mlserver-mlflow` runtime which supports [MLflow's existing API](https://www.mlflow.o...
diff --git a/runtimes/mlflow/mlserver_mlflow/runtime.py b/runtimes/mlflow/mlserver_mlflow/runtime.py --- a/runtimes/mlflow/mlserver_mlflow/runtime.py +++ b/runtimes/mlflow/mlserver_mlflow/runtime.py @@ -1,9 +1,29 @@ import mlflow +from io import StringIO +from fastapi import Request, Response + +from mlflow.exceptio...
{"golden_diff": "diff --git a/runtimes/mlflow/mlserver_mlflow/runtime.py b/runtimes/mlflow/mlserver_mlflow/runtime.py\n--- a/runtimes/mlflow/mlserver_mlflow/runtime.py\n+++ b/runtimes/mlflow/mlserver_mlflow/runtime.py\n@@ -1,9 +1,29 @@\n import mlflow\n \n+from io import StringIO\n+from fastapi import Request, Response...
655
873
gh_patches_debug_38605
rasdani/github-patches
git_diff
gratipay__gratipay.com-3616
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- add 2.0 payments to history pages @ehmatthes at https://github.com/gratipay/gratipay.com/issues/3446#issuecomment-103163666: > I made an account for introtopython.org last week, and it was one of the teams t...
diff --git a/gratipay/utils/history.py b/gratipay/utils/history.py --- a/gratipay/utils/history.py +++ b/gratipay/utils/history.py @@ -75,6 +75,12 @@ WHERE participant=%(username)s AND extract(year from timestamp) = %(year)s """, locals(), back_as=dict) + payments = db.all(""" + SEL...
{"golden_diff": "diff --git a/gratipay/utils/history.py b/gratipay/utils/history.py\n--- a/gratipay/utils/history.py\n+++ b/gratipay/utils/history.py\n@@ -75,6 +75,12 @@\n WHERE participant=%(username)s\n AND extract(year from timestamp) = %(year)s\n \"\"\", locals(), back_as=dict)\n+ payment...
2,722
660
gh_patches_debug_20942
rasdani/github-patches
git_diff
Project-MONAI__MONAI-3873
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Enhance `ContrastiveLoss` to avoid warning Call ContrastiveLoss will see a warning message: ``` To copy construct from a tensor, it is recommended to use sourceTensor.clone().detach() or sourceTensor.clone(...
diff --git a/monai/losses/contrastive.py b/monai/losses/contrastive.py --- a/monai/losses/contrastive.py +++ b/monai/losses/contrastive.py @@ -65,14 +65,13 @@ if target.shape != input.shape: raise ValueError(f"ground truth has differing shape ({target.shape}) from input ({input.shape})") - ...
{"golden_diff": "diff --git a/monai/losses/contrastive.py b/monai/losses/contrastive.py\n--- a/monai/losses/contrastive.py\n+++ b/monai/losses/contrastive.py\n@@ -65,14 +65,13 @@\n if target.shape != input.shape:\n raise ValueError(f\"ground truth has differing shape ({target.shape}) from input ({in...
1,414
270
gh_patches_debug_41944
rasdani/github-patches
git_diff
wagtail__wagtail-11666
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Inconsistent use of model verbose_name in permissions UI ### Issue Summary The object permissions UI doesn't show a model's [`verbose_name`](https://docs.djangoproject.com/en/4.2/ref/models/options/#verbos...
diff --git a/wagtail/users/templatetags/wagtailusers_tags.py b/wagtail/users/templatetags/wagtailusers_tags.py --- a/wagtail/users/templatetags/wagtailusers_tags.py +++ b/wagtail/users/templatetags/wagtailusers_tags.py @@ -2,6 +2,9 @@ from collections import defaultdict from django import template +from django.cont...
{"golden_diff": "diff --git a/wagtail/users/templatetags/wagtailusers_tags.py b/wagtail/users/templatetags/wagtailusers_tags.py\n--- a/wagtail/users/templatetags/wagtailusers_tags.py\n+++ b/wagtail/users/templatetags/wagtailusers_tags.py\n@@ -2,6 +2,9 @@\n from collections import defaultdict\n \n from django import tem...
2,632
827