problem_id stringlengths 18 22 | source stringclasses 1
value | task_type stringclasses 1
value | in_source_id stringlengths 13 58 | prompt stringlengths 1.1k 10.2k | golden_diff stringlengths 151 4.94k | verification_info stringlengths 582 21k | num_tokens int64 271 2.05k | num_tokens_diff int64 47 1.02k |
|---|---|---|---|---|---|---|---|---|
gh_patches_debug_41403 | rasdani/github-patches | git_diff | Pyomo__pyomo-498 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Appropriate behavior for activate() and deactivate() for nested disjunctions?
```
from pyomo.environ import *
m = ConcreteModel()
m.d1 = Disjunct()
m.d2 = Disjunct()
m.d1.sub1 = Disjunct()
m.d1.sub2 = D... | diff --git a/pyomo/gdp/plugins/gdp_var_mover.py b/pyomo/gdp/plugins/gdp_var_mover.py
--- a/pyomo/gdp/plugins/gdp_var_mover.py
+++ b/pyomo/gdp/plugins/gdp_var_mover.py
@@ -18,7 +18,9 @@
import textwrap
from pyomo.common.plugin import alias
from pyomo.core.base import Transformation, Block, Constraint
-from pyomo.gdp ... | {"golden_diff": "diff --git a/pyomo/gdp/plugins/gdp_var_mover.py b/pyomo/gdp/plugins/gdp_var_mover.py\n--- a/pyomo/gdp/plugins/gdp_var_mover.py\n+++ b/pyomo/gdp/plugins/gdp_var_mover.py\n@@ -18,7 +18,9 @@\n import textwrap\n from pyomo.common.plugin import alias\n from pyomo.core.base import Transformation, Block, Cons... | 1,401 | 864 |
gh_patches_debug_14547 | rasdani/github-patches | git_diff | inducer__relate-548 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
After pretend-facility, impersonate disappears from menu
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `c... | diff --git a/course/templatetags/coursetags.py b/course/templatetags/coursetags.py
--- a/course/templatetags/coursetags.py
+++ b/course/templatetags/coursetags.py
@@ -115,6 +115,28 @@
# }}}
+@register.filter(name='may_set_fake_time')
+def may_set_fake_time(user):
+ """
+ Check if a user may set fake time.
+ ... | {"golden_diff": "diff --git a/course/templatetags/coursetags.py b/course/templatetags/coursetags.py\n--- a/course/templatetags/coursetags.py\n+++ b/course/templatetags/coursetags.py\n@@ -115,6 +115,28 @@\n # }}}\n \n \n+@register.filter(name='may_set_fake_time')\n+def may_set_fake_time(user):\n+ \"\"\"\n+ Check i... | 1,503 | 290 |
gh_patches_debug_30616 | rasdani/github-patches | git_diff | rotki__rotki-897 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Changing fiat currency does not change manually tracked balances value column title
## Problem Definition
Seen in v1.4.0 by @cryptomole1
Changing the FIAT currency via the drop-down menu if the user has... | diff --git a/rotkehlchen/balances/manual.py b/rotkehlchen/balances/manual.py
--- a/rotkehlchen/balances/manual.py
+++ b/rotkehlchen/balances/manual.py
@@ -1,10 +1,11 @@
from typing import TYPE_CHECKING, Any, Dict, List, NamedTuple, Optional
from rotkehlchen.assets.asset import Asset
-from rotkehlchen.errors import ... | {"golden_diff": "diff --git a/rotkehlchen/balances/manual.py b/rotkehlchen/balances/manual.py\n--- a/rotkehlchen/balances/manual.py\n+++ b/rotkehlchen/balances/manual.py\n@@ -1,10 +1,11 @@\n from typing import TYPE_CHECKING, Any, Dict, List, NamedTuple, Optional\n \n from rotkehlchen.assets.asset import Asset\n-from ro... | 1,551 | 439 |
gh_patches_debug_29682 | rasdani/github-patches | git_diff | GeotrekCE__Geotrek-admin-990 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add requirement about projection units : should be meters
http://gis.stackexchange.com/questions/85955/how-can-i-obtain-the-unit-of-a-projection-srid
--- END ISSUE ---
Below are some code segments, each fr... | diff --git a/geotrek/common/__init__.py b/geotrek/common/__init__.py
--- a/geotrek/common/__init__.py
+++ b/geotrek/common/__init__.py
@@ -5,9 +5,11 @@
This is executed only once at startup.
"""
-from south.signals import post_migrate
+from south.signals import pre_migrate, post_migrate
from django.conf import... | {"golden_diff": "diff --git a/geotrek/common/__init__.py b/geotrek/common/__init__.py\n--- a/geotrek/common/__init__.py\n+++ b/geotrek/common/__init__.py\n@@ -5,9 +5,11 @@\n This is executed only once at startup.\n \n \"\"\"\n-from south.signals import post_migrate\n+from south.signals import pre_migrate, post_migr... | 693 | 442 |
gh_patches_debug_47980 | rasdani/github-patches | git_diff | TheAlgorithms__Python-564 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Unnecessary Loop
https://github.com/TheAlgorithms/Python/blob/4e0184a41dd3e4838da484057d25e17234353da0/dynamic_programming/matrix_chain_order.py#L12-L15
`Line 12` creates a NxN Matrix that **contains 0**.... | diff --git a/dynamic_programming/matrix_chain_order.py b/dynamic_programming/matrix_chain_order.py
--- a/dynamic_programming/matrix_chain_order.py
+++ b/dynamic_programming/matrix_chain_order.py
@@ -11,8 +11,6 @@
N=len(array)
Matrix=[[0 for x in range(N)] for x in range(N)]
Sol=[[0 for x in range(N)] for... | {"golden_diff": "diff --git a/dynamic_programming/matrix_chain_order.py b/dynamic_programming/matrix_chain_order.py\n--- a/dynamic_programming/matrix_chain_order.py\n+++ b/dynamic_programming/matrix_chain_order.py\n@@ -11,8 +11,6 @@\n N=len(array)\n Matrix=[[0 for x in range(N)] for x in range(N)]\n Sol=[[0... | 908 | 140 |
gh_patches_debug_3449 | rasdani/github-patches | git_diff | jazzband__pip-tools-608 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
README broken on PyPI (must be reStructuredText)
The [package description](https://pypi.python.org/pypi/pip-tools/) on PyPI is unreadable since PyPI expects the README in [reStructuredText](http://www.sphinx-... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -16,7 +16,7 @@
license='BSD',
author='Vincent Driessen',
author_email='me@nvie.com',
- description=__doc__,
+ description=__doc__.strip(),
long_description=read_file('README.rst'),
packages=find_packages(exclude=['tests']),... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -16,7 +16,7 @@\n license='BSD',\n author='Vincent Driessen',\n author_email='me@nvie.com',\n- description=__doc__,\n+ description=__doc__.strip(),\n long_description=read_file('README.rst'),\n packages=find_p... | 1,116 | 98 |
gh_patches_debug_7898 | rasdani/github-patches | git_diff | googleapis__python-bigquery-1889 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Extend the OTEL traces to track bytes billed and bytes processed
Extend OTEL traces to track bytes billed and bytes processed. Allowing developers to see how much data and cost was consumed as part of BigQuer... | diff --git a/google/cloud/bigquery/opentelemetry_tracing.py b/google/cloud/bigquery/opentelemetry_tracing.py
--- a/google/cloud/bigquery/opentelemetry_tracing.py
+++ b/google/cloud/bigquery/opentelemetry_tracing.py
@@ -153,4 +153,12 @@
if job_ref.num_child_jobs is not None:
job_attributes["num_child_jobs"... | {"golden_diff": "diff --git a/google/cloud/bigquery/opentelemetry_tracing.py b/google/cloud/bigquery/opentelemetry_tracing.py\n--- a/google/cloud/bigquery/opentelemetry_tracing.py\n+++ b/google/cloud/bigquery/opentelemetry_tracing.py\n@@ -153,4 +153,12 @@\n if job_ref.num_child_jobs is not None:\n job_attri... | 1,921 | 187 |
gh_patches_debug_2307 | rasdani/github-patches | git_diff | huggingface__text-generation-inference-1089 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Flash attention (v1) is broken
Defaulting window_size_left to "-1" breaks flash attention v1 since v1 only works if window_size_left is 0 (line 83).
https://github.com/huggingface/text-generation-inference... | 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
@@ -80,7 +80,7 @@
)
if HAS_FLASH_ATTN:
- if window_size_left != 0:
+ ... | {"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@@ -80,7 +80,7 @@\n )\n \n if HAS_FLASH_ATTN:\n- if wi... | 1,577 | 114 |
gh_patches_debug_15818 | rasdani/github-patches | git_diff | intel__dffml-177 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
model: scikit: setup.py needs correct entrypoints
```diff
diff --git a/model/scikit/setup.py b/model/scikit/setup.py
index 1bd6284..efbff80 100644
--- a/model/scikit/setup.py
+++ b/model/scikit/setup.py
... | diff --git a/model/scikit/setup.py b/model/scikit/setup.py
--- a/model/scikit/setup.py
+++ b/model/scikit/setup.py
@@ -53,5 +53,18 @@
],
install_requires=INSTALL_REQUIRES,
packages=find_packages(),
- entry_points={"dffml.model": [f"scikitlr = {IMPORT_NAME}.sciLR:LR"]},
+ entry_points={
+ "df... | {"golden_diff": "diff --git a/model/scikit/setup.py b/model/scikit/setup.py\n--- a/model/scikit/setup.py\n+++ b/model/scikit/setup.py\n@@ -53,5 +53,18 @@\n ],\n install_requires=INSTALL_REQUIRES,\n packages=find_packages(),\n- entry_points={\"dffml.model\": [f\"scikitlr = {IMPORT_NAME}.sciLR:LR\"]},\n+ ... | 1,062 | 317 |
gh_patches_debug_18895 | rasdani/github-patches | git_diff | scikit-hep__pyhf-1186 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
pyhf json2xml requires pyhf[contrib]
# Description
```
$ pip install pyhf[xmlio]
$ pyhf json2xml -h
ERROR:pyhf.contrib.utils:No module named 'requests'
Installation of the contrib extra is required to ... | diff --git a/src/pyhf/contrib/cli.py b/src/pyhf/contrib/cli.py
--- a/src/pyhf/contrib/cli.py
+++ b/src/pyhf/contrib/cli.py
@@ -3,8 +3,6 @@
import click
from pathlib import Path
-from . import utils
-
logging.basicConfig()
log = logging.getLogger(__name__)
@@ -22,6 +20,10 @@
$ python -m pip instal... | {"golden_diff": "diff --git a/src/pyhf/contrib/cli.py b/src/pyhf/contrib/cli.py\n--- a/src/pyhf/contrib/cli.py\n+++ b/src/pyhf/contrib/cli.py\n@@ -3,8 +3,6 @@\n import click\n from pathlib import Path\n \n-from . import utils\n-\n logging.basicConfig()\n log = logging.getLogger(__name__)\n \n@@ -22,6 +20,10 @@\n \n ... | 1,044 | 226 |
gh_patches_debug_25711 | rasdani/github-patches | git_diff | ipython__ipython-8506 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
added %matplotlib --list so backends are easily visible
linked to #8444 adding --list argument to show the available backends
--- END ISSUE ---
Below are some code segments, each from a relevant file. One ... | diff --git a/IPython/core/magics/pylab.py b/IPython/core/magics/pylab.py
--- a/IPython/core/magics/pylab.py
+++ b/IPython/core/magics/pylab.py
@@ -42,6 +42,8 @@
@skip_doctest
@line_magic
@magic_arguments.magic_arguments()
+ @magic_arguments.argument('-l', '--list', action='store_true',
+ ... | {"golden_diff": "diff --git a/IPython/core/magics/pylab.py b/IPython/core/magics/pylab.py\n--- a/IPython/core/magics/pylab.py\n+++ b/IPython/core/magics/pylab.py\n@@ -42,6 +42,8 @@\n @skip_doctest\n @line_magic\n @magic_arguments.magic_arguments()\n+ @magic_arguments.argument('-l', '--list', action='stor... | 1,806 | 361 |
gh_patches_debug_16253 | rasdani/github-patches | git_diff | mozilla__pontoon-3030 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Broken heroku deploy button
When i try to deploy pontoon on heroku, i got an infinite charge..

... | diff --git a/pontoon/base/management/commands/heroku_deploy_setup.py b/pontoon/base/management/commands/heroku_deploy_setup.py
--- a/pontoon/base/management/commands/heroku_deploy_setup.py
+++ b/pontoon/base/management/commands/heroku_deploy_setup.py
@@ -1,11 +1,11 @@
import os
-from urllib.parse import urlparse, ur... | {"golden_diff": "diff --git a/pontoon/base/management/commands/heroku_deploy_setup.py b/pontoon/base/management/commands/heroku_deploy_setup.py\n--- a/pontoon/base/management/commands/heroku_deploy_setup.py\n+++ b/pontoon/base/management/commands/heroku_deploy_setup.py\n@@ -1,11 +1,11 @@\n import os\n \n-from urllib.pa... | 600 | 214 |
gh_patches_debug_13676 | rasdani/github-patches | git_diff | pulp__pulpcore-2408 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Migration 0040_set_admin_is_staff.py is missing dependency on user model
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FI... | diff --git a/pulpcore/app/migrations/0040_set_admin_is_staff.py b/pulpcore/app/migrations/0040_set_admin_is_staff.py
--- a/pulpcore/app/migrations/0040_set_admin_is_staff.py
+++ b/pulpcore/app/migrations/0040_set_admin_is_staff.py
@@ -1,5 +1,6 @@
# Generated by Django 2.2.13 on 2020-07-01 21:29
+from django.conf imp... | {"golden_diff": "diff --git a/pulpcore/app/migrations/0040_set_admin_is_staff.py b/pulpcore/app/migrations/0040_set_admin_is_staff.py\n--- a/pulpcore/app/migrations/0040_set_admin_is_staff.py\n+++ b/pulpcore/app/migrations/0040_set_admin_is_staff.py\n@@ -1,5 +1,6 @@\n # Generated by Django 2.2.13 on 2020-07-01 21:29\n ... | 487 | 224 |
gh_patches_debug_3692 | rasdani/github-patches | git_diff | nautobot__nautobot-566 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
`nautobot.core.api.serializers.WritableNestedSerializer` docstring is incorrect and confusing
<!--
NOTE: This template is for use by maintainers only. Please do not submit
an issue using this templa... | diff --git a/nautobot/core/api/serializers.py b/nautobot/core/api/serializers.py
--- a/nautobot/core/api/serializers.py
+++ b/nautobot/core/api/serializers.py
@@ -77,7 +77,8 @@
class WritableNestedSerializer(BaseModelSerializer):
"""
- Returns a nested representation of an object on read, but accepts only a ... | {"golden_diff": "diff --git a/nautobot/core/api/serializers.py b/nautobot/core/api/serializers.py\n--- a/nautobot/core/api/serializers.py\n+++ b/nautobot/core/api/serializers.py\n@@ -77,7 +77,8 @@\n \n class WritableNestedSerializer(BaseModelSerializer):\n \"\"\"\n- Returns a nested representation of an object o... | 1,798 | 135 |
gh_patches_debug_4 | rasdani/github-patches | git_diff | horovod__horovod-1139 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Replace .step(synchronize=False) with optimizer.skip_synchronize()
NVIDIA AMP does not support passing additional flags to `optimizer.step()`, such as `optimizer.step(synchronize=False)`.
This PR switches ... | diff --git a/horovod/__init__.py b/horovod/__init__.py
--- a/horovod/__init__.py
+++ b/horovod/__init__.py
@@ -1 +1 @@
-__version__ = '0.16.3'
+__version__ = '0.16.4'
| {"golden_diff": "diff --git a/horovod/__init__.py b/horovod/__init__.py\n--- a/horovod/__init__.py\n+++ b/horovod/__init__.py\n@@ -1 +1 @@\n-__version__ = '0.16.3'\n+__version__ = '0.16.4'\n", "issue": "Replace .step(synchronize=False) with optimizer.skip_synchronize()\nNVIDIA AMP does not support passing additional fl... | 341 | 76 |
gh_patches_debug_19971 | rasdani/github-patches | git_diff | vispy__vispy-476 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Adding more documentation
Currently, we only have the API reference. There's no other documentation at the moment.
Here are a few references we could take inspiration from/copy.
- [@rougier's tutorial](http:... | diff --git a/vispy/__init__.py b/vispy/__init__.py
--- a/vispy/__init__.py
+++ b/vispy/__init__.py
@@ -8,25 +8,13 @@
Vispy
=====
-Vispy is a collaborative project that has the goal to allow more sharing
-of code between visualization projects based on OpenGL. It does this
-by providing powerful interfaces to OpenGL... | {"golden_diff": "diff --git a/vispy/__init__.py b/vispy/__init__.py\n--- a/vispy/__init__.py\n+++ b/vispy/__init__.py\n@@ -8,25 +8,13 @@\n Vispy\n =====\n \n-Vispy is a collaborative project that has the goal to allow more sharing\n-of code between visualization projects based on OpenGL. It does this\n-by providing pow... | 800 | 343 |
gh_patches_debug_11619 | rasdani/github-patches | git_diff | cloudtools__troposphere-440 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Function Role property doesn't work with string value
The following results in a TypeError for the Role property type. I don't get a TypeError if I use GetAtt for Role's type, but I need to use a string. Look... | diff --git a/troposphere/awslambda.py b/troposphere/awslambda.py
--- a/troposphere/awslambda.py
+++ b/troposphere/awslambda.py
@@ -1,4 +1,4 @@
-from . import AWSObject, AWSProperty, GetAtt
+from . import AWSObject, AWSProperty
from .validators import positive_integer
@@ -51,7 +51,7 @@
'Description': (base... | {"golden_diff": "diff --git a/troposphere/awslambda.py b/troposphere/awslambda.py\n--- a/troposphere/awslambda.py\n+++ b/troposphere/awslambda.py\n@@ -1,4 +1,4 @@\n-from . import AWSObject, AWSProperty, GetAtt\n+from . import AWSObject, AWSProperty\n from .validators import positive_integer\n \n \n@@ -51,7 +51,7 @@\n ... | 1,461 | 174 |
gh_patches_debug_27866 | rasdani/github-patches | git_diff | pyqtgraph__pyqtgraph-1247 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Segfault when exiting Command Line Usage Example
<!-- In the following, please describe your issue in detail! -->
<!-- If some of the sections do not apply, just remove them. -->
### Short description
Wh... | diff --git a/pyqtgraph/graphicsWindows.py b/pyqtgraph/graphicsWindows.py
--- a/pyqtgraph/graphicsWindows.py
+++ b/pyqtgraph/graphicsWindows.py
@@ -55,10 +55,14 @@
"""
def __init__(self, title=None, **kargs):
mkQApp()
+ self.win = QtGui.QMainWindow()
PlotWidget.__init__(self, **kargs)
... | {"golden_diff": "diff --git a/pyqtgraph/graphicsWindows.py b/pyqtgraph/graphicsWindows.py\n--- a/pyqtgraph/graphicsWindows.py\n+++ b/pyqtgraph/graphicsWindows.py\n@@ -55,10 +55,14 @@\n \"\"\"\n def __init__(self, title=None, **kargs):\n mkQApp()\n+ self.win = QtGui.QMainWindow()\n PlotWid... | 1,476 | 383 |
gh_patches_debug_8470 | rasdani/github-patches | git_diff | Kinto__kinto-338 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
kinto start fails: no module named functools32
```
kinto start
Starting subprocess with file monitor
2015-11-29 10:12:24,821 INFO [venusian][MainThread] kinto 1.9.0 starting.
Traceback (most recent call las... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -1,5 +1,6 @@
-import os
import codecs
+import os
+import sys
from setuptools import setup, find_packages
here = os.path.abspath(os.path.dirname(__file__))
@@ -21,6 +22,11 @@
'jsonschema',
]
+if sys.version_info < (3,):
+ REQUIREMENTS.exte... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -1,5 +1,6 @@\n-import os\n import codecs\n+import os\n+import sys\n from setuptools import setup, find_packages\n \n here = os.path.abspath(os.path.dirname(__file__))\n@@ -21,6 +22,11 @@\n 'jsonschema',\n ]\n \n+if sys.version_inf... | 1,956 | 150 |
gh_patches_debug_3910 | rasdani/github-patches | git_diff | DataDog__dd-trace-py-4935 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Instrumenting ambiguity: Integrate with SQLAlchemy or not when underlying psycopg2 used
<!--
Thanks for taking the time for reporting an issue!
Before reporting an issue on dd-trace-py, please be sure to ... | diff --git a/ddtrace/contrib/sqlalchemy/__init__.py b/ddtrace/contrib/sqlalchemy/__init__.py
--- a/ddtrace/contrib/sqlalchemy/__init__.py
+++ b/ddtrace/contrib/sqlalchemy/__init__.py
@@ -1,4 +1,8 @@
"""
+Enabling the SQLAlchemy integration is only necessary if there is no
+instrumentation available or enabled for the ... | {"golden_diff": "diff --git a/ddtrace/contrib/sqlalchemy/__init__.py b/ddtrace/contrib/sqlalchemy/__init__.py\n--- a/ddtrace/contrib/sqlalchemy/__init__.py\n+++ b/ddtrace/contrib/sqlalchemy/__init__.py\n@@ -1,4 +1,8 @@\n \"\"\"\n+Enabling the SQLAlchemy integration is only necessary if there is no\n+instrumentation ava... | 1,154 | 132 |
gh_patches_debug_5368 | rasdani/github-patches | git_diff | mindsdb__mindsdb-337 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add consistency check for model data object in the CI tests
We should take a snapshot of a "correct" model data object (as returned by `get_model_data()`) for the CI testing dataset and always compare the jso... | diff --git a/mindsdb/__about__.py b/mindsdb/__about__.py
--- a/mindsdb/__about__.py
+++ b/mindsdb/__about__.py
@@ -1,6 +1,6 @@
__title__ = 'MindsDB'
__package_name__ = 'mindsdb'
-__version__ = '1.7.11'
+__version__ = '1.7.12'
__description__ = "MindsDB's goal is to make it very simple for developers to use the power... | {"golden_diff": "diff --git a/mindsdb/__about__.py b/mindsdb/__about__.py\n--- a/mindsdb/__about__.py\n+++ b/mindsdb/__about__.py\n@@ -1,6 +1,6 @@\n __title__ = 'MindsDB'\n __package_name__ = 'mindsdb'\n-__version__ = '1.7.11'\n+__version__ = '1.7.12'\n __description__ = \"MindsDB's goal is to make it very simple for d... | 582 | 147 |
gh_patches_debug_20887 | rasdani/github-patches | git_diff | zulip__zulip-19155 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Make muting work for deactivated users
Even after a user deactivated, it may be helpful to hide that user's messages, avatar, etc. We should therefore make it possible to mute deactivated users.
This will ... | diff --git a/zerver/views/muting.py b/zerver/views/muting.py
--- a/zerver/views/muting.py
+++ b/zerver/views/muting.py
@@ -94,7 +94,9 @@
if user_profile.id == muted_user_id:
raise JsonableError(_("Cannot mute self"))
- muted_user = access_user_by_id(user_profile, muted_user_id, allow_bots=False, for_... | {"golden_diff": "diff --git a/zerver/views/muting.py b/zerver/views/muting.py\n--- a/zerver/views/muting.py\n+++ b/zerver/views/muting.py\n@@ -94,7 +94,9 @@\n if user_profile.id == muted_user_id:\n raise JsonableError(_(\"Cannot mute self\"))\n \n- muted_user = access_user_by_id(user_profile, muted_user_... | 1,455 | 277 |
gh_patches_debug_15617 | rasdani/github-patches | git_diff | python__peps-2826 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Decide what PEPs fall under `Topic: Packaging` and act accordingly
Right now, as originally discussed in #2096 , there seem to be two plausible interpretation of what qualifies for the `Topic: Packaging` labe... | diff --git a/pep_sphinx_extensions/pep_zero_generator/constants.py b/pep_sphinx_extensions/pep_zero_generator/constants.py
--- a/pep_sphinx_extensions/pep_zero_generator/constants.py
+++ b/pep_sphinx_extensions/pep_zero_generator/constants.py
@@ -36,10 +36,10 @@
# map of topic -> additional description
SUBINDICES_BY_... | {"golden_diff": "diff --git a/pep_sphinx_extensions/pep_zero_generator/constants.py b/pep_sphinx_extensions/pep_zero_generator/constants.py\n--- a/pep_sphinx_extensions/pep_zero_generator/constants.py\n+++ b/pep_sphinx_extensions/pep_zero_generator/constants.py\n@@ -36,10 +36,10 @@\n # map of topic -> additional descri... | 1,988 | 226 |
gh_patches_debug_5833 | rasdani/github-patches | git_diff | cupy__cupy-499 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Different behaviour of argmax
I found the behaviour of `argmax` is different between `numpy` and `cupy` if the array has `0` in its shape and `axis` argument is used. I don't know whether this behaviour is in... | diff --git a/cupy/logic/truth.py b/cupy/logic/truth.py
--- a/cupy/logic/truth.py
+++ b/cupy/logic/truth.py
@@ -1,8 +1,11 @@
+import cupy
+
+
def all(a, axis=None, out=None, keepdims=False):
- # TODO(okuta): check type
+ assert isinstance(a, cupy.ndarray)
return a.all(axis=axis, out=out, keepdims=keepdims)
... | {"golden_diff": "diff --git a/cupy/logic/truth.py b/cupy/logic/truth.py\n--- a/cupy/logic/truth.py\n+++ b/cupy/logic/truth.py\n@@ -1,8 +1,11 @@\n+import cupy\n+\n+\n def all(a, axis=None, out=None, keepdims=False):\n- # TODO(okuta): check type\n+ assert isinstance(a, cupy.ndarray)\n return a.all(axis=axis, ou... | 621 | 161 |
gh_patches_debug_42424 | rasdani/github-patches | git_diff | python-discord__bot-1452 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Delete messages when `!pypi` module is invalid
When users use the `!pypi` command with an invalid module, you currently get a response saying `"Package could not be found."`.
What I'm proposing it that af... | diff --git a/bot/exts/info/pypi.py b/bot/exts/info/pypi.py
--- a/bot/exts/info/pypi.py
+++ b/bot/exts/info/pypi.py
@@ -8,7 +8,7 @@
from discord.utils import escape_markdown
from bot.bot import Bot
-from bot.constants import Colours, NEGATIVE_REPLIES
+from bot.constants import Colours, NEGATIVE_REPLIES, RedirectOutp... | {"golden_diff": "diff --git a/bot/exts/info/pypi.py b/bot/exts/info/pypi.py\n--- a/bot/exts/info/pypi.py\n+++ b/bot/exts/info/pypi.py\n@@ -8,7 +8,7 @@\n from discord.utils import escape_markdown\n \n from bot.bot import Bot\n-from bot.constants import Colours, NEGATIVE_REPLIES\n+from bot.constants import Colours, NEGAT... | 1,219 | 924 |
gh_patches_debug_58079 | rasdani/github-patches | git_diff | secondmind-labs__trieste-140 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Ensure type information is packaged with installable
**Describe the feature you'd like**
As a user, I want to be able to type check my code that calls into trieste. It's not clear at the moment if this is cu... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -27,6 +27,9 @@
long_description_content_type="text/markdown",
url="https://github.com/secondmind-labs/trieste",
packages=find_packages(include=("trieste*",)),
+ package_data={
+ "trieste": ["py.typed"],
+ },
classifiers=[... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -27,6 +27,9 @@\n long_description_content_type=\"text/markdown\",\n url=\"https://github.com/secondmind-labs/trieste\",\n packages=find_packages(include=(\"trieste*\",)),\n+ package_data={\n+ \"trieste\": [\"py.t... | 823 | 115 |
gh_patches_debug_10804 | rasdani/github-patches | git_diff | MycroftAI__mycroft-core-2985 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add note about legal issues when using gTTS in public or commercial projects
originally opened in the OVOS plugin repo
> I've just posted an issue about potential legal issues with this API in the gTTS rep... | diff --git a/mycroft/tts/google_tts.py b/mycroft/tts/google_tts.py
--- a/mycroft/tts/google_tts.py
+++ b/mycroft/tts/google_tts.py
@@ -70,6 +70,13 @@
self._google_lang = None
super(GoogleTTS, self).__init__(lang, config, GoogleTTSValidator(
self), 'mp3')
+ LOG.warning(
+ ... | {"golden_diff": "diff --git a/mycroft/tts/google_tts.py b/mycroft/tts/google_tts.py\n--- a/mycroft/tts/google_tts.py\n+++ b/mycroft/tts/google_tts.py\n@@ -70,6 +70,13 @@\n self._google_lang = None\n super(GoogleTTS, self).__init__(lang, config, GoogleTTSValidator(\n self), 'mp3')\n+ L... | 1,991 | 195 |
gh_patches_debug_27808 | rasdani/github-patches | git_diff | sopel-irc__sopel-2069 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Support 2-pronoun sets in the pronoun module
### The problem
Setting pronouns in the pronouns module can be unintuitive because the bot accepts either a 1-pronoun "object" command (`.setpronouns she`) or ... | diff --git a/sopel/modules/pronouns.py b/sopel/modules/pronouns.py
--- a/sopel/modules/pronouns.py
+++ b/sopel/modules/pronouns.py
@@ -19,14 +19,21 @@
'ze/hir': 'ze/hir/hir/hirs/hirself',
'ze/zir': 'ze/zir/zir/zirs/zirself',
'they': 'they/them/their/theirs/themselves',
+ 'they/them': 'they/them/their/... | {"golden_diff": "diff --git a/sopel/modules/pronouns.py b/sopel/modules/pronouns.py\n--- a/sopel/modules/pronouns.py\n+++ b/sopel/modules/pronouns.py\n@@ -19,14 +19,21 @@\n 'ze/hir': 'ze/hir/hir/hirs/hirself',\n 'ze/zir': 'ze/zir/zir/zirs/zirself',\n 'they': 'they/them/their/theirs/themselves',\n+ 'they/... | 1,649 | 496 |
gh_patches_debug_21787 | rasdani/github-patches | git_diff | mozilla__pontoon-3121 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Warn on empty Fluent rich editor fields
> In addition to the bug, I believe this is a UX regression? We should show a warning that one of the values is empty when trying to save such message.
The current p... | diff --git a/pontoon/checks/libraries/pontoon_db.py b/pontoon/checks/libraries/pontoon_db.py
--- a/pontoon/checks/libraries/pontoon_db.py
+++ b/pontoon/checks/libraries/pontoon_db.py
@@ -28,20 +28,27 @@
class IsEmptyVisitor(Visitor):
def __init__(self):
- self.is_empty = True
+ self.is_empty = Fal... | {"golden_diff": "diff --git a/pontoon/checks/libraries/pontoon_db.py b/pontoon/checks/libraries/pontoon_db.py\n--- a/pontoon/checks/libraries/pontoon_db.py\n+++ b/pontoon/checks/libraries/pontoon_db.py\n@@ -28,20 +28,27 @@\n \n class IsEmptyVisitor(Visitor):\n def __init__(self):\n- self.is_empty = True\n+ ... | 1,400 | 280 |
gh_patches_debug_10412 | rasdani/github-patches | git_diff | keras-team__keras-19382 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
CenterCrop.compute_output_shape() does not consider the list compatibility
When the input is a list of tensor, CenterCrop can correctly generate the output, while` CenterCrop.compute_output_shape()` will gene... | diff --git a/keras/layers/preprocessing/center_crop.py b/keras/layers/preprocessing/center_crop.py
--- a/keras/layers/preprocessing/center_crop.py
+++ b/keras/layers/preprocessing/center_crop.py
@@ -111,6 +111,13 @@
def compute_output_shape(self, input_shape):
input_shape = list(input_shape)
+ if... | {"golden_diff": "diff --git a/keras/layers/preprocessing/center_crop.py b/keras/layers/preprocessing/center_crop.py\n--- a/keras/layers/preprocessing/center_crop.py\n+++ b/keras/layers/preprocessing/center_crop.py\n@@ -111,6 +111,13 @@\n \n def compute_output_shape(self, input_shape):\n input_shape = list(i... | 1,851 | 201 |
gh_patches_debug_6913 | rasdani/github-patches | git_diff | horovod__horovod-214 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Error on using hvd.mpi_threads_supported() error: undefined symbol: mpi_threads_supported
Error on using hvd.mpi_threads_supported()
error: undefined symbol: mpi_threads_supported
`mpi_threads_support... | diff --git a/horovod/common/__init__.py b/horovod/common/__init__.py
--- a/horovod/common/__init__.py
+++ b/horovod/common/__init__.py
@@ -107,7 +107,7 @@
Returns:
A boolean value indicating whether MPI multi-threading is supported.
"""
- mpi_threads_supported = MPI_COMMON_LIB_CTYPES.mpi_threads_sup... | {"golden_diff": "diff --git a/horovod/common/__init__.py b/horovod/common/__init__.py\n--- a/horovod/common/__init__.py\n+++ b/horovod/common/__init__.py\n@@ -107,7 +107,7 @@\n Returns:\n A boolean value indicating whether MPI multi-threading is supported.\n \"\"\"\n- mpi_threads_supported = MPI_COMMON... | 1,414 | 144 |
gh_patches_debug_32181 | rasdani/github-patches | git_diff | tensorflow__addons-1281 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Segmentation fault when using tfa.rotate in tf-nightly
**System information**
- OS Platform: Linux Ubuntu 18.04.3 LTS
- TensorFlow version: tf-nightly (2.2.0-dev20200310) installed with pip
- TensorFlow-Ad... | diff --git a/tensorflow_addons/utils/ensure_tf_install.py b/tensorflow_addons/utils/ensure_tf_install.py
--- a/tensorflow_addons/utils/ensure_tf_install.py
+++ b/tensorflow_addons/utils/ensure_tf_install.py
@@ -17,27 +17,40 @@
# Ensure TensorFlow is importable and its version is sufficiently recent. This
# needs to h... | {"golden_diff": "diff --git a/tensorflow_addons/utils/ensure_tf_install.py b/tensorflow_addons/utils/ensure_tf_install.py\n--- a/tensorflow_addons/utils/ensure_tf_install.py\n+++ b/tensorflow_addons/utils/ensure_tf_install.py\n@@ -17,27 +17,40 @@\n # Ensure TensorFlow is importable and its version is sufficiently recen... | 953 | 556 |
gh_patches_debug_11369 | rasdani/github-patches | git_diff | apluslms__a-plus-1348 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Use setUpTestData in tests
`setUp` is ran before every test method but `setUpTestData` is run only once for the whole test class. Each test method is run in a transaction and rolled back at the end, so there... | diff --git a/lib/testdata.py b/lib/testdata.py
--- a/lib/testdata.py
+++ b/lib/testdata.py
@@ -19,10 +19,12 @@
class CourseTestCase(TestCase):
- def setUp(self):
- self.setUpCourse()
- self.setUpSubmissions()
+ @classmethod
+ def setUpTestData(cls):
+ cls.setUpCourse()
+ cls.se... | {"golden_diff": "diff --git a/lib/testdata.py b/lib/testdata.py\n--- a/lib/testdata.py\n+++ b/lib/testdata.py\n@@ -19,10 +19,12 @@\n \n class CourseTestCase(TestCase):\n \n- def setUp(self):\n- self.setUpCourse()\n- self.setUpSubmissions()\n+ @classmethod\n+ def setUpTestData(cls):\n+ cls.... | 1,886 | 159 |
gh_patches_debug_1204 | rasdani/github-patches | git_diff | microsoft__playwright-python-1497 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[Question]: How to get the right BrowserType from a device name?
### Your question
I noticed that the CLI is able to figure out the right `BrowserType` to use when it is launched from the command line:
`... | diff --git a/playwright/_impl/_playwright.py b/playwright/_impl/_playwright.py
--- a/playwright/_impl/_playwright.py
+++ b/playwright/_impl/_playwright.py
@@ -81,4 +81,5 @@
"device_scale_factor": dict["deviceScaleFactor"],
"is_mobile": dict["isMobile"],
"has_touch": dict["hasTouch"],
+ ... | {"golden_diff": "diff --git a/playwright/_impl/_playwright.py b/playwright/_impl/_playwright.py\n--- a/playwright/_impl/_playwright.py\n+++ b/playwright/_impl/_playwright.py\n@@ -81,4 +81,5 @@\n \"device_scale_factor\": dict[\"deviceScaleFactor\"],\n \"is_mobile\": dict[\"isMobile\"],\n \"has_to... | 1,287 | 103 |
gh_patches_debug_11614 | rasdani/github-patches | git_diff | digitalfabrik__integreat-cms-295 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Enforce new SECRET_KEY in production environments
The server should refuse to start if the SECRET_KEY does not differ from the default value in our repository.
The importance of this issue depends on wheth... | diff --git a/backend/cms/apps.py b/backend/cms/apps.py
--- a/backend/cms/apps.py
+++ b/backend/cms/apps.py
@@ -1,8 +1,12 @@
"""
Django related class representing a config of an app
"""
+import logging
+import sys
+from django.conf import settings
from django.apps import AppConfig
+logger = logging.getLogger(__nam... | {"golden_diff": "diff --git a/backend/cms/apps.py b/backend/cms/apps.py\n--- a/backend/cms/apps.py\n+++ b/backend/cms/apps.py\n@@ -1,8 +1,12 @@\n \"\"\"\n Django related class representing a config of an app\n \"\"\"\n+import logging\n+import sys\n+from django.conf import settings\n from django.apps import AppConfig\n ... | 371 | 204 |
gh_patches_debug_1858 | rasdani/github-patches | git_diff | huggingface__accelerate-127 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Error when loading optimizer state
Thanks for this awesome product!!
When I try to load optimizer state on TPUs, I get an error, since self.device_placement is never initialized in AcceleratedOptimizer..!
... | diff --git a/src/accelerate/optimizer.py b/src/accelerate/optimizer.py
--- a/src/accelerate/optimizer.py
+++ b/src/accelerate/optimizer.py
@@ -52,6 +52,7 @@
self.optimizer = optimizer
self.scaler = scaler
self.state = AcceleratorState()
+ self.device_placement = device_placement
... | {"golden_diff": "diff --git a/src/accelerate/optimizer.py b/src/accelerate/optimizer.py\n--- a/src/accelerate/optimizer.py\n+++ b/src/accelerate/optimizer.py\n@@ -52,6 +52,7 @@\n self.optimizer = optimizer\n self.scaler = scaler\n self.state = AcceleratorState()\n+ self.device_placement =... | 1,705 | 93 |
gh_patches_debug_15427 | rasdani/github-patches | git_diff | google__jax-574 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
jax.config doesn't report command-line flags correctly
Another one from @jmgilmer and I - I don't think the jax config is parsing command line flags correctly. I don't know if this is functionally important ... | diff --git a/jax/config.py b/jax/config.py
--- a/jax/config.py
+++ b/jax/config.py
@@ -73,6 +73,8 @@
flag_type, meta_args, meta_kwargs = self.meta[name]
absl_defs[flag_type](name, val, *meta_args, **meta_kwargs)
+ app.call_after_init(lambda: self.complete_absl_config(absl_flags))
+
def complete_ab... | {"golden_diff": "diff --git a/jax/config.py b/jax/config.py\n--- a/jax/config.py\n+++ b/jax/config.py\n@@ -73,6 +73,8 @@\n flag_type, meta_args, meta_kwargs = self.meta[name]\n absl_defs[flag_type](name, val, *meta_args, **meta_kwargs)\n \n+ app.call_after_init(lambda: self.complete_absl_config(absl_flag... | 1,641 | 180 |
gh_patches_debug_15851 | rasdani/github-patches | git_diff | lk-geimfari__mimesis-875 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add pricetag support
# Feature request
## Thesis
Create a localized pricetag:
```
>>> mimesis.Business().pricetag()
"$ 12.34"
>>> mimesis.Business("de").pricetag(minimum=1000, maximum=1500)
"1.234,... | diff --git a/mimesis/providers/business.py b/mimesis/providers/business.py
--- a/mimesis/providers/business.py
+++ b/mimesis/providers/business.py
@@ -98,8 +98,19 @@
:param maximum: Min value of price.
:return: Price.
"""
- price = self.random.uniform(minimum, maximum, precision=2)
- ... | {"golden_diff": "diff --git a/mimesis/providers/business.py b/mimesis/providers/business.py\n--- a/mimesis/providers/business.py\n+++ b/mimesis/providers/business.py\n@@ -98,8 +98,19 @@\n :param maximum: Min value of price.\n :return: Price.\n \"\"\"\n- price = self.random.uniform(minimum... | 1,459 | 254 |
gh_patches_debug_26099 | rasdani/github-patches | git_diff | pytorch__ignite-1044 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
gpu_info crashes because it cannot parse "N/A"
## 🐛 Bug description
When trying to use gpu_info, it throws:
```
File "/home/blackhc/anaconda3/envs/hello-mnist/lib/python3.7/site-packages/ignite/contr... | diff --git a/ignite/contrib/metrics/gpu_info.py b/ignite/contrib/metrics/gpu_info.py
--- a/ignite/contrib/metrics/gpu_info.py
+++ b/ignite/contrib/metrics/gpu_info.py
@@ -11,6 +11,10 @@
"""Provides GPU information: a) used memory percentage, b) gpu utilization percentage values as Metric
on each iterations.
... | {"golden_diff": "diff --git a/ignite/contrib/metrics/gpu_info.py b/ignite/contrib/metrics/gpu_info.py\n--- a/ignite/contrib/metrics/gpu_info.py\n+++ b/ignite/contrib/metrics/gpu_info.py\n@@ -11,6 +11,10 @@\n \"\"\"Provides GPU information: a) used memory percentage, b) gpu utilization percentage values as Metric\n ... | 1,491 | 312 |
gh_patches_debug_30950 | rasdani/github-patches | git_diff | StackStorm__st2-2508 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
linux.wait_for_ssh action improvements
Currently `linux.wait_for_ssh` action (https://github.com/StackStorm/st2/blob/master/contrib/linux/actions/wait_for_ssh.yaml) only supports authenticating with RSA SSH k... | diff --git a/contrib/linux/actions/wait_for_ssh.py b/contrib/linux/actions/wait_for_ssh.py
--- a/contrib/linux/actions/wait_for_ssh.py
+++ b/contrib/linux/actions/wait_for_ssh.py
@@ -2,26 +2,36 @@
import time
-import paramiko
+from oslo_config import cfg
from st2actions.runners.pythonrunner import Action
+from ... | {"golden_diff": "diff --git a/contrib/linux/actions/wait_for_ssh.py b/contrib/linux/actions/wait_for_ssh.py\n--- a/contrib/linux/actions/wait_for_ssh.py\n+++ b/contrib/linux/actions/wait_for_ssh.py\n@@ -2,26 +2,36 @@\n \n import time\n \n-import paramiko\n+from oslo_config import cfg\n \n from st2actions.runners.python... | 616 | 477 |
gh_patches_debug_31670 | rasdani/github-patches | git_diff | sanic-org__sanic-2578 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Certificates not created with `mkcert` or `trustme` raise a RuntimeError
The `CertLoader` class in `sanic-org/sanic/sanic/worker/loader.py` checks the creator of the certificate. If the creator is not `mkcert... | diff --git a/sanic/worker/loader.py b/sanic/worker/loader.py
--- a/sanic/worker/loader.py
+++ b/sanic/worker/loader.py
@@ -5,18 +5,10 @@
from importlib import import_module
from pathlib import Path
-from typing import (
- TYPE_CHECKING,
- Any,
- Callable,
- Dict,
- Optional,
- Type,
- Union,
- ... | {"golden_diff": "diff --git a/sanic/worker/loader.py b/sanic/worker/loader.py\n--- a/sanic/worker/loader.py\n+++ b/sanic/worker/loader.py\n@@ -5,18 +5,10 @@\n \n from importlib import import_module\n from pathlib import Path\n-from typing import (\n- TYPE_CHECKING,\n- Any,\n- Callable,\n- Dict,\n- Option... | 1,469 | 499 |
gh_patches_debug_19003 | rasdani/github-patches | git_diff | bridgecrewio__checkov-5302 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
CKV_OPENAPI_20 incorrectly flags API keys via HTTPS
**Describe the issue**
#5253 added CKV_OPENAPI_20 with the message "Ensure that API keys are not sent over cleartext", but the [check](https://github.com... | diff --git a/checkov/openapi/checks/resource/generic/ClearTextAPIKey.py b/checkov/openapi/checks/resource/generic/ClearTextAPIKey.py
--- a/checkov/openapi/checks/resource/generic/ClearTextAPIKey.py
+++ b/checkov/openapi/checks/resource/generic/ClearTextAPIKey.py
@@ -17,6 +17,16 @@
block_type=B... | {"golden_diff": "diff --git a/checkov/openapi/checks/resource/generic/ClearTextAPIKey.py b/checkov/openapi/checks/resource/generic/ClearTextAPIKey.py\n--- a/checkov/openapi/checks/resource/generic/ClearTextAPIKey.py\n+++ b/checkov/openapi/checks/resource/generic/ClearTextAPIKey.py\n@@ -17,6 +17,16 @@\n ... | 1,242 | 273 |
gh_patches_debug_4711 | rasdani/github-patches | git_diff | scrapy__scrapy-4323 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Mac OS X, OS X → macOS
We have a few references in the documentation where we use the old name of that OS. We should update them.
--- END ISSUE ---
Below are some code segments, each from a relevant file. O... | diff --git a/scrapy/extensions/memusage.py b/scrapy/extensions/memusage.py
--- a/scrapy/extensions/memusage.py
+++ b/scrapy/extensions/memusage.py
@@ -47,7 +47,7 @@
def get_virtual_size(self):
size = self.resource.getrusage(self.resource.RUSAGE_SELF).ru_maxrss
if sys.platform != 'darwin':
- ... | {"golden_diff": "diff --git a/scrapy/extensions/memusage.py b/scrapy/extensions/memusage.py\n--- a/scrapy/extensions/memusage.py\n+++ b/scrapy/extensions/memusage.py\n@@ -47,7 +47,7 @@\n def get_virtual_size(self):\n size = self.resource.getrusage(self.resource.RUSAGE_SELF).ru_maxrss\n if sys.platfo... | 1,691 | 138 |
gh_patches_debug_20026 | rasdani/github-patches | git_diff | yt-dlp__yt-dlp-1063 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[niconico_dmc] Heartbeat failed with SOCKS5 `HTTPS?_PROXY` env
## Checklist
- [x] I'm reporting a broken site support
- [x] I've verified that I'm running yt-dlp version **2021.09.02**
- [x] I've check... | diff --git a/yt_dlp/downloader/niconico.py b/yt_dlp/downloader/niconico.py
--- a/yt_dlp/downloader/niconico.py
+++ b/yt_dlp/downloader/niconico.py
@@ -6,7 +6,7 @@
from .common import FileDownloader
from ..downloader import get_suitable_downloader
from ..extractor.niconico import NiconicoIE
-from ..compat import comp... | {"golden_diff": "diff --git a/yt_dlp/downloader/niconico.py b/yt_dlp/downloader/niconico.py\n--- a/yt_dlp/downloader/niconico.py\n+++ b/yt_dlp/downloader/niconico.py\n@@ -6,7 +6,7 @@\n from .common import FileDownloader\n from ..downloader import get_suitable_downloader\n from ..extractor.niconico import NiconicoIE\n-f... | 1,783 | 232 |
gh_patches_debug_20623 | rasdani/github-patches | git_diff | svthalia__concrexit-3068 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Expand/improve document part of event endpoint
<!--
Please add the appropriate label for what change should be made:
docs: changes to the documentation)
refactor: refactoring production code, eg. renamin... | diff --git a/website/documents/api/v2/serializers/document.py b/website/documents/api/v2/serializers/document.py
--- a/website/documents/api/v2/serializers/document.py
+++ b/website/documents/api/v2/serializers/document.py
@@ -1,10 +1,10 @@
from rest_framework.fields import SerializerMethodField
-from rest_framework.r... | {"golden_diff": "diff --git a/website/documents/api/v2/serializers/document.py b/website/documents/api/v2/serializers/document.py\n--- a/website/documents/api/v2/serializers/document.py\n+++ b/website/documents/api/v2/serializers/document.py\n@@ -1,10 +1,10 @@\n from rest_framework.fields import SerializerMethodField\n... | 608 | 251 |
gh_patches_debug_51282 | rasdani/github-patches | git_diff | open-telemetry__opentelemetry-python-636 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add a standard way to "reset" a Configuration object for testing
It is a common occurrence in tests that the global `Configuration` object needs to be "reset" between tests. This means that its attributes nee... | diff --git a/opentelemetry-api/src/opentelemetry/configuration/__init__.py b/opentelemetry-api/src/opentelemetry/configuration/__init__.py
--- a/opentelemetry-api/src/opentelemetry/configuration/__init__.py
+++ b/opentelemetry-api/src/opentelemetry/configuration/__init__.py
@@ -122,3 +122,20 @@
def __getattr__(s... | {"golden_diff": "diff --git a/opentelemetry-api/src/opentelemetry/configuration/__init__.py b/opentelemetry-api/src/opentelemetry/configuration/__init__.py\n--- a/opentelemetry-api/src/opentelemetry/configuration/__init__.py\n+++ b/opentelemetry-api/src/opentelemetry/configuration/__init__.py\n@@ -122,3 +122,20 @@\n \n... | 1,632 | 205 |
gh_patches_debug_3505 | rasdani/github-patches | git_diff | saleor__saleor-1832 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Localization of duplicate email account doesn't make sense
I saw this weird thing in post production when I was creating a customer account that was already registered.
... | diff --git a/saleor/account/forms.py b/saleor/account/forms.py
--- a/saleor/account/forms.py
+++ b/saleor/account/forms.py
@@ -70,6 +70,11 @@
class SignupForm(forms.ModelForm):
password = forms.CharField(
widget=forms.PasswordInput)
+ email = forms.EmailField(
+ error_messages={
+ 'u... | {"golden_diff": "diff --git a/saleor/account/forms.py b/saleor/account/forms.py\n--- a/saleor/account/forms.py\n+++ b/saleor/account/forms.py\n@@ -70,6 +70,11 @@\n class SignupForm(forms.ModelForm):\n password = forms.CharField(\n widget=forms.PasswordInput)\n+ email = forms.EmailField(\n+ error_m... | 1,717 | 116 |
gh_patches_debug_10163 | rasdani/github-patches | git_diff | pytorch__pytorch-2200 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
DataParallel tests are currently broken
https://github.com/pytorch/pytorch/pull/2121/commits/d69669efcfe4333c223f53249185c2e22f76ed73 has broken DataParallel tests. Now that device_ids are explicitly sent to... | diff --git a/torch/nn/parallel/data_parallel.py b/torch/nn/parallel/data_parallel.py
--- a/torch/nn/parallel/data_parallel.py
+++ b/torch/nn/parallel/data_parallel.py
@@ -100,6 +100,7 @@
inputs, module_kwargs = scatter_kwargs(inputs, module_kwargs, device_ids, dim)
if len(device_ids) == 1:
return mod... | {"golden_diff": "diff --git a/torch/nn/parallel/data_parallel.py b/torch/nn/parallel/data_parallel.py\n--- a/torch/nn/parallel/data_parallel.py\n+++ b/torch/nn/parallel/data_parallel.py\n@@ -100,6 +100,7 @@\n inputs, module_kwargs = scatter_kwargs(inputs, module_kwargs, device_ids, dim)\n if len(device_ids) == ... | 1,575 | 185 |
gh_patches_debug_34564 | rasdani/github-patches | git_diff | pyinstaller__pyinstaller-7259 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Fixes for use of pyinstaller with Django 4.x and custom management commands.
PROBLEM:
This feature aims to solve the problem of the custom app level management commands being missed out from hidden imports a... | diff --git a/PyInstaller/hooks/rthooks/pyi_rth_django.py b/PyInstaller/hooks/rthooks/pyi_rth_django.py
--- a/PyInstaller/hooks/rthooks/pyi_rth_django.py
+++ b/PyInstaller/hooks/rthooks/pyi_rth_django.py
@@ -11,54 +11,8 @@
# This Django rthook was tested with Django 1.8.3.
-import django.core.management
import dja... | {"golden_diff": "diff --git a/PyInstaller/hooks/rthooks/pyi_rth_django.py b/PyInstaller/hooks/rthooks/pyi_rth_django.py\n--- a/PyInstaller/hooks/rthooks/pyi_rth_django.py\n+++ b/PyInstaller/hooks/rthooks/pyi_rth_django.py\n@@ -11,54 +11,8 @@\n \n # This Django rthook was tested with Django 1.8.3.\n \n-import django.cor... | 1,349 | 663 |
gh_patches_debug_24655 | rasdani/github-patches | git_diff | open-telemetry__opentelemetry-python-3217 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Make entry_points behave the same across Python versions
The recently introduced `entry_points` function does not behave the same across Python versions and it is not possible to get all entry points in Pytho... | diff --git a/opentelemetry-api/src/opentelemetry/util/_importlib_metadata.py b/opentelemetry-api/src/opentelemetry/util/_importlib_metadata.py
--- a/opentelemetry-api/src/opentelemetry/util/_importlib_metadata.py
+++ b/opentelemetry-api/src/opentelemetry/util/_importlib_metadata.py
@@ -12,27 +12,18 @@
# See the Licens... | {"golden_diff": "diff --git a/opentelemetry-api/src/opentelemetry/util/_importlib_metadata.py b/opentelemetry-api/src/opentelemetry/util/_importlib_metadata.py\n--- a/opentelemetry-api/src/opentelemetry/util/_importlib_metadata.py\n+++ b/opentelemetry-api/src/opentelemetry/util/_importlib_metadata.py\n@@ -12,27 +12,18 ... | 704 | 445 |
gh_patches_debug_3318 | rasdani/github-patches | git_diff | feast-dev__feast-2753 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Unable to access data in Feast UI when deployed to remote instance
## Expected Behavior
Should be able to view registry data when launching UI with `feast ui` on remote instances (like EC2).
## Current B... | diff --git a/sdk/python/feast/ui_server.py b/sdk/python/feast/ui_server.py
--- a/sdk/python/feast/ui_server.py
+++ b/sdk/python/feast/ui_server.py
@@ -62,7 +62,7 @@
"name": "Project",
"description": "Test project",
"id": project_id,
- "re... | {"golden_diff": "diff --git a/sdk/python/feast/ui_server.py b/sdk/python/feast/ui_server.py\n--- a/sdk/python/feast/ui_server.py\n+++ b/sdk/python/feast/ui_server.py\n@@ -62,7 +62,7 @@\n \"name\": \"Project\",\n \"description\": \"Test project\",\n \"id\": pro... | 1,454 | 108 |
gh_patches_debug_24195 | rasdani/github-patches | git_diff | liqd__a4-meinberlin-2543 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
testing #2252 follow mail: mail participation ends soon
Where: Mail "participation ends soon"
* in a single module project link should go to project view and not to a module view that does not regularly ex... | diff --git a/meinberlin/apps/offlineevents/models.py b/meinberlin/apps/offlineevents/models.py
--- a/meinberlin/apps/offlineevents/models.py
+++ b/meinberlin/apps/offlineevents/models.py
@@ -3,8 +3,8 @@
from autoslug import AutoSlugField
from ckeditor_uploader.fields import RichTextUploadingField
from django.db impo... | {"golden_diff": "diff --git a/meinberlin/apps/offlineevents/models.py b/meinberlin/apps/offlineevents/models.py\n--- a/meinberlin/apps/offlineevents/models.py\n+++ b/meinberlin/apps/offlineevents/models.py\n@@ -3,8 +3,8 @@\n from autoslug import AutoSlugField\n from ckeditor_uploader.fields import RichTextUploadingFiel... | 850 | 298 |
gh_patches_debug_22114 | rasdani/github-patches | git_diff | deepchecks__deepchecks-550 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[BUG] Receiving FutureWarning for each label on Calibration Score check
**Describe the bug**
Receiving FutureWarning for each label on Calibration Score
**To Reproduce**
Run a categorical Dataset on Cali... | diff --git a/deepchecks/checks/performance/calibration_score.py b/deepchecks/checks/performance/calibration_score.py
--- a/deepchecks/checks/performance/calibration_score.py
+++ b/deepchecks/checks/performance/calibration_score.py
@@ -17,7 +17,6 @@
from deepchecks import Dataset, CheckResult, SingleDatasetBaseCheck
f... | {"golden_diff": "diff --git a/deepchecks/checks/performance/calibration_score.py b/deepchecks/checks/performance/calibration_score.py\n--- a/deepchecks/checks/performance/calibration_score.py\n+++ b/deepchecks/checks/performance/calibration_score.py\n@@ -17,7 +17,6 @@\n from deepchecks import Dataset, CheckResult, Sing... | 1,594 | 279 |
gh_patches_debug_5367 | rasdani/github-patches | git_diff | comic__grand-challenge.org-2344 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
'NoneType' object has no attribute 'values'
Sentry issue https://sentry.io/organizations/grand-challenge/issues/3127690895/?project=303639&query=is%3Aunresolved
```
slugs = {slug for viewport in mapping.v... | diff --git a/app/grandchallenge/hanging_protocols/forms.py b/app/grandchallenge/hanging_protocols/forms.py
--- a/app/grandchallenge/hanging_protocols/forms.py
+++ b/app/grandchallenge/hanging_protocols/forms.py
@@ -28,7 +28,7 @@
class ViewContentMixin:
def clean_view_content(self):
- mapping = self.cl... | {"golden_diff": "diff --git a/app/grandchallenge/hanging_protocols/forms.py b/app/grandchallenge/hanging_protocols/forms.py\n--- a/app/grandchallenge/hanging_protocols/forms.py\n+++ b/app/grandchallenge/hanging_protocols/forms.py\n@@ -28,7 +28,7 @@\n \r\n class ViewContentMixin:\r\n def clean_view_content(self):\r\... | 1,080 | 126 |
gh_patches_debug_914 | rasdani/github-patches | git_diff | wemake-services__wemake-python-styleguide-204 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Feature: ignore async function definitions from jones complexity check
Currently we only ignore `ClassDef` and `FunctionDef`: https://github.com/wemake-services/wemake-python-styleguide/blob/master/wemake_pyt... | diff --git a/wemake_python_styleguide/visitors/ast/complexity/jones.py b/wemake_python_styleguide/visitors/ast/complexity/jones.py
--- a/wemake_python_styleguide/visitors/ast/complexity/jones.py
+++ b/wemake_python_styleguide/visitors/ast/complexity/jones.py
@@ -38,6 +38,7 @@
_ignored_nodes = (
ast.Functi... | {"golden_diff": "diff --git a/wemake_python_styleguide/visitors/ast/complexity/jones.py b/wemake_python_styleguide/visitors/ast/complexity/jones.py\n--- a/wemake_python_styleguide/visitors/ast/complexity/jones.py\n+++ b/wemake_python_styleguide/visitors/ast/complexity/jones.py\n@@ -38,6 +38,7 @@\n _ignored_nodes = ... | 1,284 | 134 |
gh_patches_debug_5671 | rasdani/github-patches | git_diff | projectmesa__mesa-539 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
epstein_civil_violence box doesn't fit grid
<img width="431" alt="screen shot 2018-04-01 at 10 05 11 pm" src="https://user-images.githubusercontent.com/166734/38180219-de2decf8-35f8-11e8-8d9b-562d2fb7c58b.png... | diff --git a/examples/epstein_civil_violence/civil_violence/server.py b/examples/epstein_civil_violence/civil_violence/server.py
--- a/examples/epstein_civil_violence/civil_violence/server.py
+++ b/examples/epstein_civil_violence/civil_violence/server.py
@@ -43,6 +43,6 @@
legitimacy=.8,
... | {"golden_diff": "diff --git a/examples/epstein_civil_violence/civil_violence/server.py b/examples/epstein_civil_violence/civil_violence/server.py\n--- a/examples/epstein_civil_violence/civil_violence/server.py\n+++ b/examples/epstein_civil_violence/civil_violence/server.py\n@@ -43,6 +43,6 @@\n legit... | 863 | 193 |
gh_patches_debug_39517 | rasdani/github-patches | git_diff | strawberry-graphql__strawberry-55 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add support for interfaces
We should be able to define interfaces with strawberry, something like this:
```python
@strawberry.interface
class Node:
id: strawberry.ID
```
--- END ISSUE ---
Below... | diff --git a/strawberry/__init__.py b/strawberry/__init__.py
--- a/strawberry/__init__.py
+++ b/strawberry/__init__.py
@@ -6,4 +6,4 @@
from .mutation import mutation, subscription # noqa
from .scalars import ID # noqa
from .schema import Schema # noqa
-from .type import input, type # noqa
+from .type import inpu... | {"golden_diff": "diff --git a/strawberry/__init__.py b/strawberry/__init__.py\n--- a/strawberry/__init__.py\n+++ b/strawberry/__init__.py\n@@ -6,4 +6,4 @@\n from .mutation import mutation, subscription # noqa\n from .scalars import ID # noqa\n from .schema import Schema # noqa\n-from .type import input, type # noqa... | 1,308 | 771 |
gh_patches_debug_16 | rasdani/github-patches | git_diff | OCHA-DAP__hdx-ckan-1401 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
The MailChimp subscribe field could use a little bit more padding-left
Right now the input text is too close to the left border. It would be nice to add some padding there.
![screen shot 2014-10-01 at 10 23... | diff --git a/ckanext-hdx_theme/ckanext/hdx_theme/version.py b/ckanext-hdx_theme/ckanext/hdx_theme/version.py
--- a/ckanext-hdx_theme/ckanext/hdx_theme/version.py
+++ b/ckanext-hdx_theme/ckanext/hdx_theme/version.py
@@ -1 +1 @@
-hdx_version = 'v0.3.9'
+hdx_version = 'v0.3.10'
| {"golden_diff": "diff --git a/ckanext-hdx_theme/ckanext/hdx_theme/version.py b/ckanext-hdx_theme/ckanext/hdx_theme/version.py\n--- a/ckanext-hdx_theme/ckanext/hdx_theme/version.py\n+++ b/ckanext-hdx_theme/ckanext/hdx_theme/version.py\n@@ -1 +1 @@\n-hdx_version = 'v0.3.9'\n+hdx_version = 'v0.3.10'\n", "issue": "The Mail... | 405 | 107 |
gh_patches_debug_24750 | rasdani/github-patches | git_diff | dbt-labs__dbt-core-7636 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[CT-2479] replace all instances of set-output and node16
Details in https://github.com/dbt-labs/actions/issues/39.
### Acceptance Criteria
- [ ] Verified there are no workflows to update
_or_
- [ ] remo... | diff --git a/.github/actions/latest-wrangler/main.py b/.github/actions/latest-wrangler/main.py
--- a/.github/actions/latest-wrangler/main.py
+++ b/.github/actions/latest-wrangler/main.py
@@ -28,11 +28,12 @@
if package_request.status_code == 404:
if halt_on_missing:
sys.exit(1)
- else:
... | {"golden_diff": "diff --git a/.github/actions/latest-wrangler/main.py b/.github/actions/latest-wrangler/main.py\n--- a/.github/actions/latest-wrangler/main.py\n+++ b/.github/actions/latest-wrangler/main.py\n@@ -28,11 +28,12 @@\n if package_request.status_code == 404:\n if halt_on_missing:\n sys.... | 1,441 | 377 |
gh_patches_debug_37590 | rasdani/github-patches | git_diff | urllib3__urllib3-840 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
urllib3 attempts to use IPv6 even when IPv6 is disabled
This is an issue when running on a server without IPv6 (must be disabled because the network does not support it). Example when connecting to https://gr... | diff --git a/urllib3/util/connection.py b/urllib3/util/connection.py
--- a/urllib3/util/connection.py
+++ b/urllib3/util/connection.py
@@ -46,6 +46,8 @@
# This function is copied from socket.py in the Python 2.7 standard
# library test suite. Added to its signature is only `socket_options`.
+# One additional modifi... | {"golden_diff": "diff --git a/urllib3/util/connection.py b/urllib3/util/connection.py\n--- a/urllib3/util/connection.py\n+++ b/urllib3/util/connection.py\n@@ -46,6 +46,8 @@\n \n # This function is copied from socket.py in the Python 2.7 standard\n # library test suite. Added to its signature is only `socket_options`.\n... | 1,620 | 700 |
gh_patches_debug_57104 | rasdani/github-patches | git_diff | pyro-ppl__pyro-1704 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
make test: no attribute 'optim' error in 'examples/contrib/oed/ab_test.py'
### Issue Description
On the latest dev branch, `make test` gives the following error:
_
examples/contrib/oed/ab_test.py:12: in... | diff --git a/examples/contrib/oed/gp_bayes_opt.py b/examples/contrib/oed/gp_bayes_opt.py
--- a/examples/contrib/oed/gp_bayes_opt.py
+++ b/examples/contrib/oed/gp_bayes_opt.py
@@ -3,9 +3,9 @@
import torch.optim as optim
from torch.distributions import transform_to
-import pyro
import pyro.contrib.gp as gp
from pyr... | {"golden_diff": "diff --git a/examples/contrib/oed/gp_bayes_opt.py b/examples/contrib/oed/gp_bayes_opt.py\n--- a/examples/contrib/oed/gp_bayes_opt.py\n+++ b/examples/contrib/oed/gp_bayes_opt.py\n@@ -3,9 +3,9 @@\n import torch.optim as optim\n from torch.distributions import transform_to\n \n-import pyro\n import pyro.c... | 1,942 | 127 |
gh_patches_debug_23563 | rasdani/github-patches | git_diff | getsentry__snuba-558 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Support Redis Authentication
I'm trying to install Snuba on my Kubernetes instance alongside Sentry.
Sentry's Helm chart installs Redis with a password (It generates a secret), and there was no option for me... | diff --git a/snuba/redis.py b/snuba/redis.py
--- a/snuba/redis.py
+++ b/snuba/redis.py
@@ -37,11 +37,13 @@
redis_client = RetryingStrictRedisCluster(
startup_nodes=startup_nodes,
socket_keepalive=True,
+ password=settings.REDIS_PASSWORD,
)
else:
redis_client = StrictRedis(
... | {"golden_diff": "diff --git a/snuba/redis.py b/snuba/redis.py\n--- a/snuba/redis.py\n+++ b/snuba/redis.py\n@@ -37,11 +37,13 @@\n redis_client = RetryingStrictRedisCluster(\n startup_nodes=startup_nodes,\n socket_keepalive=True,\n+ password=settings.REDIS_PASSWORD,\n )\n else:\n redis_... | 1,698 | 324 |
gh_patches_debug_3670 | rasdani/github-patches | git_diff | wright-group__WrightTools-753 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Kit leastsq should not except BaseException
https://github.com/wright-group/WrightTools/blob/f22920579f45632b4123661d9832ff0cc1b614c4/WrightTools/kit/_leastsq.py#L74
The exception caught should be limited ... | diff --git a/WrightTools/kit/_leastsq.py b/WrightTools/kit/_leastsq.py
--- a/WrightTools/kit/_leastsq.py
+++ b/WrightTools/kit/_leastsq.py
@@ -71,7 +71,7 @@
for i in range(len(pfit_leastsq)):
try:
error.append(np.absolute(pcov[i][i]) ** 0.5)
- except BaseException:
+ ... | {"golden_diff": "diff --git a/WrightTools/kit/_leastsq.py b/WrightTools/kit/_leastsq.py\n--- a/WrightTools/kit/_leastsq.py\n+++ b/WrightTools/kit/_leastsq.py\n@@ -71,7 +71,7 @@\n for i in range(len(pfit_leastsq)):\n try:\n error.append(np.absolute(pcov[i][i]) ** 0.5)\n- ex... | 1,131 | 131 |
gh_patches_debug_20609 | rasdani/github-patches | git_diff | svthalia__concrexit-3484 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Merchandise page redesign
### Is your feature request related to a problem? Please describe.
The current merchandise page is a long list with lot's of text. Part of this problem is the board not hiding the... | diff --git a/website/merchandise/urls.py b/website/merchandise/urls.py
--- a/website/merchandise/urls.py
+++ b/website/merchandise/urls.py
@@ -15,5 +15,6 @@
path("", views.index, name="index"),
]
),
- )
+ ),
+ path("association/merchandise/<int:id>/", views.product_page, ... | {"golden_diff": "diff --git a/website/merchandise/urls.py b/website/merchandise/urls.py\n--- a/website/merchandise/urls.py\n+++ b/website/merchandise/urls.py\n@@ -15,5 +15,6 @@\n path(\"\", views.index, name=\"index\"),\n ]\n ),\n- )\n+ ),\n+ path(\"association/merchandise/<... | 660 | 315 |
gh_patches_debug_24019 | rasdani/github-patches | git_diff | nilearn__nilearn-2096 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
scipy.misc.imread() replaced by scipy.imageio.imread() in v1.2
`scipy.misc.imread()` was deprecatd in SciPy 1.0 & replaced in SciPy 1.2 by `scipy.imageio.imread()`
https://docs.scipy.org/doc/scipy-1.2.1/re... | diff --git a/examples/02_decoding/plot_haxby_stimuli.py b/examples/02_decoding/plot_haxby_stimuli.py
--- a/examples/02_decoding/plot_haxby_stimuli.py
+++ b/examples/02_decoding/plot_haxby_stimuli.py
@@ -7,7 +7,6 @@
Cortex" (Science 2001)
"""
-from scipy.misc import imread
import matplotlib.pyplot as plt
from ni... | {"golden_diff": "diff --git a/examples/02_decoding/plot_haxby_stimuli.py b/examples/02_decoding/plot_haxby_stimuli.py\n--- a/examples/02_decoding/plot_haxby_stimuli.py\n+++ b/examples/02_decoding/plot_haxby_stimuli.py\n@@ -7,7 +7,6 @@\n Cortex\" (Science 2001)\n \"\"\"\n \n-from scipy.misc import imread\n import matplo... | 708 | 413 |
gh_patches_debug_4779 | rasdani/github-patches | git_diff | zestedesavoir__zds-site-4960 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Insertion du smiley >_<
On obtient `>_<`
Solution 1 : Modifier le code ici : https://github.com/zestedesavoir/zds-site/blob/4ae0431bbf199e318dd6f2b1301ac7b6adc40198/assets/js/editor.js#L132 Vérifier... | diff --git a/zds/utils/templatetags/smileys_def.py b/zds/utils/templatetags/smileys_def.py
--- a/zds/utils/templatetags/smileys_def.py
+++ b/zds/utils/templatetags/smileys_def.py
@@ -23,7 +23,7 @@
'diable.png': (':diable:', ),
'magicien.png': (':magicien:', ),
'ninja.gif': (':ninja:', ),
- 'pinch.png'... | {"golden_diff": "diff --git a/zds/utils/templatetags/smileys_def.py b/zds/utils/templatetags/smileys_def.py\n--- a/zds/utils/templatetags/smileys_def.py\n+++ b/zds/utils/templatetags/smileys_def.py\n@@ -23,7 +23,7 @@\n 'diable.png': (':diable:', ),\n 'magicien.png': (':magicien:', ),\n 'ninja.gif': (':ninja... | 987 | 176 |
gh_patches_debug_25265 | rasdani/github-patches | git_diff | tinygrad__tinygrad-1562 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Tensor.__eq__() with two bool tensors raises error on Torch backend
This was introduced from #1493
To reproduce:
```
In [24]: (Tensor([1], dtype=dtypes.bool, device="TORCH") == Tensor([1], dtype=dtypes.b... | diff --git a/tinygrad/runtime/ops_torch.py b/tinygrad/runtime/ops_torch.py
--- a/tinygrad/runtime/ops_torch.py
+++ b/tinygrad/runtime/ops_torch.py
@@ -18,7 +18,7 @@
torch_fxn_for_op: Dict[Op, Callable] = {**base_fxn_for_op, **{
UnaryOps.NOOP: lambda x: x.contiguous(), UnaryOps.SQRT: lambda x: x.sqrt(), UnaryOps.EXP... | {"golden_diff": "diff --git a/tinygrad/runtime/ops_torch.py b/tinygrad/runtime/ops_torch.py\n--- a/tinygrad/runtime/ops_torch.py\n+++ b/tinygrad/runtime/ops_torch.py\n@@ -18,7 +18,7 @@\n torch_fxn_for_op: Dict[Op, Callable] = {**base_fxn_for_op, **{\n UnaryOps.NOOP: lambda x: x.contiguous(), UnaryOps.SQRT: lambda x: ... | 1,313 | 385 |
gh_patches_debug_32291 | rasdani/github-patches | git_diff | open-telemetry__opentelemetry-python-contrib-1253 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add more features for adding HTTP request / response headers to spans.
I already have https://github.com/open-telemetry/opentelemetry-python-contrib/pull/1172 open for this, and I'll be breaking it in to smal... | diff --git a/util/opentelemetry-util-http/src/opentelemetry/util/http/__init__.py b/util/opentelemetry-util-http/src/opentelemetry/util/http/__init__.py
--- a/util/opentelemetry-util-http/src/opentelemetry/util/http/__init__.py
+++ b/util/opentelemetry-util-http/src/opentelemetry/util/http/__init__.py
@@ -13,6 +13,7 @@... | {"golden_diff": "diff --git a/util/opentelemetry-util-http/src/opentelemetry/util/http/__init__.py b/util/opentelemetry-util-http/src/opentelemetry/util/http/__init__.py\n--- a/util/opentelemetry-util-http/src/opentelemetry/util/http/__init__.py\n+++ b/util/opentelemetry-util-http/src/opentelemetry/util/http/__init__.p... | 1,912 | 475 |
gh_patches_debug_2683 | rasdani/github-patches | git_diff | huggingface__huggingface_hub-790 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Support python=3.10
Python 3.10 has been out for a while but we seem to not test for it. What are the roadblocks for us to support 3.10 and maybe deprecate 3.6? (Many packages now support 3.8-3.10 and older v... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -69,7 +69,7 @@
"huggingface-cli=huggingface_hub.commands.huggingface_cli:main"
]
},
- python_requires=">=3.6.0",
+ python_requires=">=3.7.0",
install_requires=install_requires,
classifiers=[
"Intended A... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -69,7 +69,7 @@\n \"huggingface-cli=huggingface_hub.commands.huggingface_cli:main\"\n ]\n },\n- python_requires=\">=3.6.0\",\n+ python_requires=\">=3.7.0\",\n install_requires=install_requires,\n c... | 1,063 | 96 |
gh_patches_debug_36073 | rasdani/github-patches | git_diff | streamlink__streamlink-5711 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
plugins.wasd: service gone
### Checklist
- [X] This is a [plugin issue](https://streamlink.github.io/plugins.html) and not [a different kind of issue](https://github.com/streamlink/streamlink/issues/new/ch... | diff --git a/src/streamlink/plugins/wasd.py b/src/streamlink/plugins/wasd.py
deleted file mode 100644
--- a/src/streamlink/plugins/wasd.py
+++ /dev/null
@@ -1,87 +0,0 @@
-"""
-$description Russian live-streaming social platform.
-$url wasd.tv
-$type live
-"""
-
-import logging
-import re
-
-from streamlink.plugin impor... | {"golden_diff": "diff --git a/src/streamlink/plugins/wasd.py b/src/streamlink/plugins/wasd.py\ndeleted file mode 100644\n--- a/src/streamlink/plugins/wasd.py\n+++ /dev/null\n@@ -1,87 +0,0 @@\n-\"\"\"\n-$description Russian live-streaming social platform.\n-$url wasd.tv\n-$type live\n-\"\"\"\n-\n-import logging\n-import... | 1,658 | 742 |
gh_patches_debug_27898 | rasdani/github-patches | git_diff | pypa__pip-4046 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
pip freeze --requirement doesn't accept inline comments
- Pip version: 8.1.2
- Python version: 2.7.11
- Operating System: Mac OS X
### Description:
pip freeze --requirement doesn't accept inline comments
###... | diff --git a/pip/operations/freeze.py b/pip/operations/freeze.py
--- a/pip/operations/freeze.py
+++ b/pip/operations/freeze.py
@@ -5,6 +5,7 @@
import pip
from pip.req import InstallRequirement
+from pip.req.req_file import COMMENT_RE
from pip.utils import get_installed_distributions
from pip._vendor import pkg_re... | {"golden_diff": "diff --git a/pip/operations/freeze.py b/pip/operations/freeze.py\n--- a/pip/operations/freeze.py\n+++ b/pip/operations/freeze.py\n@@ -5,6 +5,7 @@\n \n import pip\n from pip.req import InstallRequirement\n+from pip.req.req_file import COMMENT_RE\n from pip.utils import get_installed_distributions\n from... | 1,662 | 234 |
gh_patches_debug_12666 | rasdani/github-patches | git_diff | openshift__openshift-ansible-3887 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[healthchecks] the package_version check always checks for master/node packages regardless of host group
#### Description
When running `playbooks/byo/openshift-preflight/check.yml`, the `package_version` c... | diff --git a/roles/openshift_health_checker/openshift_checks/package_version.py b/roles/openshift_health_checker/openshift_checks/package_version.py
--- a/roles/openshift_health_checker/openshift_checks/package_version.py
+++ b/roles/openshift_health_checker/openshift_checks/package_version.py
@@ -9,6 +9,13 @@
nam... | {"golden_diff": "diff --git a/roles/openshift_health_checker/openshift_checks/package_version.py b/roles/openshift_health_checker/openshift_checks/package_version.py\n--- a/roles/openshift_health_checker/openshift_checks/package_version.py\n+++ b/roles/openshift_health_checker/openshift_checks/package_version.py\n@@ -9... | 1,031 | 224 |
gh_patches_debug_20166 | rasdani/github-patches | git_diff | marshmallow-code__webargs-680 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
typing issue with __version_info__ += __parsed_version__.pre
mypy issue:
```
__version_info__ += __parsed_version__.pre
```
```
src/webargs/__init__.py:14: error: Unsupported operand types for + ... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -20,7 +20,7 @@
]
+ FRAMEWORKS,
"lint": [
- "mypy==0.910",
+ "mypy==0.930",
"flake8==4.0.1",
"flake8-bugbear==21.11.29",
"pre-commit~=2.4",
diff --git a/src/webargs/__init__.py b/src/webargs/__init__... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -20,7 +20,7 @@\n ]\n + FRAMEWORKS,\n \"lint\": [\n- \"mypy==0.910\",\n+ \"mypy==0.930\",\n \"flake8==4.0.1\",\n \"flake8-bugbear==21.11.29\",\n \"pre-commit~=2.4\",\ndiff --git a/src/w... | 1,699 | 320 |
gh_patches_debug_11347 | rasdani/github-patches | git_diff | plotly__dash-999 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[BUG] + in version string breaks fingerprint system
**Describe your context**
- replace the result of `pip list | grep dash` below
```
dash 1.5.1 ... | diff --git a/dash/fingerprint.py b/dash/fingerprint.py
--- a/dash/fingerprint.py
+++ b/dash/fingerprint.py
@@ -1,7 +1,7 @@
import re
cache_regex = re.compile(r"^v[\w-]+m[0-9a-fA-F]+$")
-
+version_clean = re.compile(r"[^\w-]")
def build_fingerprint(path, version, hash_value):
path_parts = path.split("/")
@@ ... | {"golden_diff": "diff --git a/dash/fingerprint.py b/dash/fingerprint.py\n--- a/dash/fingerprint.py\n+++ b/dash/fingerprint.py\n@@ -1,7 +1,7 @@\n import re\n \n cache_regex = re.compile(r\"^v[\\w-]+m[0-9a-fA-F]+$\")\n-\n+version_clean = re.compile(r\"[^\\w-]\")\n \n def build_fingerprint(path, version, hash_value):\n ... | 1,031 | 165 |
gh_patches_debug_175 | rasdani/github-patches | git_diff | open-mmlab__mmengine-684 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
config/utils.py haven't mmyolo

--- END ISSUE ---
Below are some co... | diff --git a/mmengine/config/utils.py b/mmengine/config/utils.py
--- a/mmengine/config/utils.py
+++ b/mmengine/config/utils.py
@@ -25,6 +25,7 @@
'mmhuman3d': 'mmhuman3d',
'mmrotate': 'mmrotate',
'mmselfsup': 'mmselfsup',
+ 'mmyolo': 'mmyolo',
}
| {"golden_diff": "diff --git a/mmengine/config/utils.py b/mmengine/config/utils.py\n--- a/mmengine/config/utils.py\n+++ b/mmengine/config/utils.py\n@@ -25,6 +25,7 @@\n 'mmhuman3d': 'mmhuman3d',\n 'mmrotate': 'mmrotate',\n 'mmselfsup': 'mmselfsup',\n+ 'mmyolo': 'mmyolo',\n }\n", "issue": "config/utils.py h... | 1,777 | 90 |
gh_patches_debug_58655 | rasdani/github-patches | git_diff | Anselmoo__spectrafit-715 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[Feature]: Add python 3.11 support
### Is there an existing issue for this?
- [X] I have searched the existing issues
### Current Missing Feature
Add python 3.11 support
### Possible Solution
_No respons... | diff --git a/spectrafit/__init__.py b/spectrafit/__init__.py
--- a/spectrafit/__init__.py
+++ b/spectrafit/__init__.py
@@ -1,2 +1,2 @@
"""SpectraFit, fast command line tool for fitting data."""
-__version__ = "0.16.6"
+__version__ = "0.16.7"
| {"golden_diff": "diff --git a/spectrafit/__init__.py b/spectrafit/__init__.py\n--- a/spectrafit/__init__.py\n+++ b/spectrafit/__init__.py\n@@ -1,2 +1,2 @@\n \"\"\"SpectraFit, fast command line tool for fitting data.\"\"\"\n-__version__ = \"0.16.6\"\n+__version__ = \"0.16.7\"\n", "issue": "[Feature]: Add python 3.11 sup... | 370 | 94 |
gh_patches_debug_2025 | rasdani/github-patches | git_diff | pre-commit__pre-commit-2836 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Alternative to stashing files for testing
Are there any plans to implement alternatives to stashing the worktree?
Ideally this would be hook/scriptable, like some 'prepare-worktree' and 'restore-worktree' ... | diff --git a/pre_commit/languages/swift.py b/pre_commit/languages/swift.py
--- a/pre_commit/languages/swift.py
+++ b/pre_commit/languages/swift.py
@@ -44,7 +44,7 @@
os.mkdir(envdir)
cmd_output_b(
'swift', 'build',
- '-C', prefix.prefix_dir,
+ '--package-path', prefix.prefix_dir,
... | {"golden_diff": "diff --git a/pre_commit/languages/swift.py b/pre_commit/languages/swift.py\n--- a/pre_commit/languages/swift.py\n+++ b/pre_commit/languages/swift.py\n@@ -44,7 +44,7 @@\n os.mkdir(envdir)\n cmd_output_b(\n 'swift', 'build',\n- '-C', prefix.prefix_dir,\n+ '--package-path', p... | 972 | 112 |
gh_patches_debug_16451 | rasdani/github-patches | git_diff | getredash__redash-602 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
API keys should be supported in the HTTP headers
Currently it seems that all API calls must include the `api_key` in the query string. Ideally the HTTP headers could also be used (e.g. `Authorization: Key XXX... | diff --git a/redash/authentication.py b/redash/authentication.py
--- a/redash/authentication.py
+++ b/redash/authentication.py
@@ -52,6 +52,7 @@
return None
+
def get_user_from_api_key(api_key, query_id):
if not api_key:
return None
@@ -67,8 +68,19 @@
return user
-def api_key_load_user_... | {"golden_diff": "diff --git a/redash/authentication.py b/redash/authentication.py\n--- a/redash/authentication.py\n+++ b/redash/authentication.py\n@@ -52,6 +52,7 @@\n \n return None\n \n+\n def get_user_from_api_key(api_key, query_id):\n if not api_key:\n return None\n@@ -67,8 +68,19 @@\n \n return ... | 1,253 | 219 |
gh_patches_debug_42802 | rasdani/github-patches | git_diff | mampfes__hacs_waste_collection_schedule-1318 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
missing file or path in source: aha_region_de.py
Hi,
I recently installed Version 1.42.0 using HACS and cant get it to run.
Changed the adress to one of the test-adresses, but same issue.
That home direc... | diff --git a/custom_components/waste_collection_schedule/waste_collection_schedule/source/aha_region_de.py b/custom_components/waste_collection_schedule/waste_collection_schedule/source/aha_region_de.py
--- a/custom_components/waste_collection_schedule/waste_collection_schedule/source/aha_region_de.py
+++ b/custom_comp... | {"golden_diff": "diff --git a/custom_components/waste_collection_schedule/waste_collection_schedule/source/aha_region_de.py b/custom_components/waste_collection_schedule/waste_collection_schedule/source/aha_region_de.py\n--- a/custom_components/waste_collection_schedule/waste_collection_schedule/source/aha_region_de.py... | 1,855 | 993 |
gh_patches_debug_30794 | rasdani/github-patches | git_diff | chainer__chainer-6991 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Support ChainerX in F.GetItem backward
`GetItemGrad` does not suport it yet.
Related: #5944
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may conta... | diff --git a/chainer/functions/array/get_item.py b/chainer/functions/array/get_item.py
--- a/chainer/functions/array/get_item.py
+++ b/chainer/functions/array/get_item.py
@@ -56,19 +56,23 @@
self._in_shape = in_shape
def forward(self, inputs):
+ slices = tuple([
+ backend.from_chx(s) i... | {"golden_diff": "diff --git a/chainer/functions/array/get_item.py b/chainer/functions/array/get_item.py\n--- a/chainer/functions/array/get_item.py\n+++ b/chainer/functions/array/get_item.py\n@@ -56,19 +56,23 @@\n self._in_shape = in_shape\n \n def forward(self, inputs):\n+ slices = tuple([\n+ ... | 1,876 | 393 |
gh_patches_debug_2814 | rasdani/github-patches | git_diff | dotkom__onlineweb4-496 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Make offline archive look more like event archive
Same as #481. This is mainly about the filtering section.
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these f... | diff --git a/apps/api/v0/article.py b/apps/api/v0/article.py
--- a/apps/api/v0/article.py
+++ b/apps/api/v0/article.py
@@ -17,7 +17,7 @@
class ArticleResource(ModelResource):
- author = fields.ToOneField(UserResource, 'created_by')
+ author = fields.ToOneField(UserResource, 'created_by', full=True)
... | {"golden_diff": "diff --git a/apps/api/v0/article.py b/apps/api/v0/article.py\n--- a/apps/api/v0/article.py\n+++ b/apps/api/v0/article.py\n@@ -17,7 +17,7 @@\n \n \n class ArticleResource(ModelResource):\n- author = fields.ToOneField(UserResource, 'created_by')\n+ author = fields.ToOneField(UserResource, 'created_... | 1,473 | 115 |
gh_patches_debug_14108 | rasdani/github-patches | git_diff | wright-group__WrightTools-726 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Group is not defined in collection
https://github.com/wright-group/WrightTools/blob/ca056aa600f341501a99d2ea4d11f7d74047bc26/WrightTools/_open.py#L48
Statement will cause an attribute error. Not tested cur... | diff --git a/WrightTools/_open.py b/WrightTools/_open.py
--- a/WrightTools/_open.py
+++ b/WrightTools/_open.py
@@ -10,6 +10,7 @@
from . import collection as wt_collection
from . import data as wt_data
+from . import _group as wt_group
# --- define ---------------------------------------------------------------... | {"golden_diff": "diff --git a/WrightTools/_open.py b/WrightTools/_open.py\n--- a/WrightTools/_open.py\n+++ b/WrightTools/_open.py\n@@ -10,6 +10,7 @@\n \n from . import collection as wt_collection\n from . import data as wt_data\n+from . import _group as wt_group\n \n \n # --- define ------------------------------------... | 703 | 160 |
gh_patches_debug_14577 | rasdani/github-patches | git_diff | urllib3__urllib3-2289 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Deprecate NTLMConnectionPool in 1.26.x
As was mentioned in https://github.com/urllib3/urllib3/pull/2278#issuecomment-864414599 and https://github.com/urllib3/urllib3/pull/2278#issuecomment-864450016 we're mov... | diff --git a/src/urllib3/contrib/ntlmpool.py b/src/urllib3/contrib/ntlmpool.py
--- a/src/urllib3/contrib/ntlmpool.py
+++ b/src/urllib3/contrib/ntlmpool.py
@@ -5,6 +5,7 @@
"""
from __future__ import absolute_import
+import warnings
from logging import getLogger
from ntlm import ntlm
@@ -12,6 +13,14 @@
from .. i... | {"golden_diff": "diff --git a/src/urllib3/contrib/ntlmpool.py b/src/urllib3/contrib/ntlmpool.py\n--- a/src/urllib3/contrib/ntlmpool.py\n+++ b/src/urllib3/contrib/ntlmpool.py\n@@ -5,6 +5,7 @@\n \"\"\"\n from __future__ import absolute_import\n \n+import warnings\n from logging import getLogger\n \n from ntlm import ntlm... | 1,816 | 241 |
gh_patches_debug_10228 | rasdani/github-patches | git_diff | fedora-infra__bodhi-1520 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
alembic/versions/9241378c92ab_convert_the_builds_table_to_be_.py uses server default
The ```alembic/versions/9241378c92ab_convert_the_builds_table_to_be_.py``` migration uses a server default, which is not al... | diff --git a/alembic/versions/9241378c92ab_convert_the_builds_table_to_be_.py b/alembic/versions/9241378c92ab_convert_the_builds_table_to_be_.py
--- a/alembic/versions/9241378c92ab_convert_the_builds_table_to_be_.py
+++ b/alembic/versions/9241378c92ab_convert_the_builds_table_to_be_.py
@@ -15,9 +15,11 @@
def upgrade... | {"golden_diff": "diff --git a/alembic/versions/9241378c92ab_convert_the_builds_table_to_be_.py b/alembic/versions/9241378c92ab_convert_the_builds_table_to_be_.py\n--- a/alembic/versions/9241378c92ab_convert_the_builds_table_to_be_.py\n+++ b/alembic/versions/9241378c92ab_convert_the_builds_table_to_be_.py\n@@ -15,9 +15,... | 1,902 | 294 |
gh_patches_debug_5168 | rasdani/github-patches | git_diff | ivy-llc__ivy-13695 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
poisson
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `ivy/functional/frontends/jax/random.py`
Content:
`... | diff --git a/ivy/functional/frontends/jax/random.py b/ivy/functional/frontends/jax/random.py
--- a/ivy/functional/frontends/jax/random.py
+++ b/ivy/functional/frontends/jax/random.py
@@ -62,3 +62,14 @@
seed = _get_seed(key)
alpha = ivy.astype(alpha, dtype)
return ivy.dirichlet(alpha, size=shape, dtype=dt... | {"golden_diff": "diff --git a/ivy/functional/frontends/jax/random.py b/ivy/functional/frontends/jax/random.py\n--- a/ivy/functional/frontends/jax/random.py\n+++ b/ivy/functional/frontends/jax/random.py\n@@ -62,3 +62,14 @@\n seed = _get_seed(key)\n alpha = ivy.astype(alpha, dtype)\n return ivy.dirichlet(alph... | 880 | 207 |
gh_patches_debug_41621 | rasdani/github-patches | git_diff | watchdogpolska__feder-328 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Eksport w CSV EmailLog
Wprowadziliśmy w ```feder.letters.logs``` statystyki dostarczania wiadomości. Należy wprowadzić zestawienie wszystkich danych z EmailLog dla danego monitoringu, aby można było zrobić s... | diff --git a/feder/letters/logs/urls.py b/feder/letters/logs/urls.py
--- a/feder/letters/logs/urls.py
+++ b/feder/letters/logs/urls.py
@@ -11,6 +11,8 @@
name="list"),
url(_(r'^monitoring-(?P<monitoring_pk>[\d-]+)$'), views.EmailLogMonitoringListView.as_view(),
name="list"),
+ url(_(r'^monitori... | {"golden_diff": "diff --git a/feder/letters/logs/urls.py b/feder/letters/logs/urls.py\n--- a/feder/letters/logs/urls.py\n+++ b/feder/letters/logs/urls.py\n@@ -11,6 +11,8 @@\n name=\"list\"),\n url(_(r'^monitoring-(?P<monitoring_pk>[\\d-]+)$'), views.EmailLogMonitoringListView.as_view(),\n name=\"lis... | 1,156 | 860 |
gh_patches_debug_14332 | rasdani/github-patches | git_diff | scikit-hep__pyhf-638 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Automate deployment to PyPI
# Description
According to @lukasheinrich, the current workflow for deploying to PyPI is:
```
git checkout master
git pull
bumpversion patch
git commit
git push origin m... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -50,8 +50,8 @@
def _is_test_pypi():
"""
- Determine if the Travis CI environment has TESTPYPI_UPLOAD defined and
- set to true (c.f. .travis.yml)
+ Determine if the CI environment has IS_TESTPYPI defined and
+ set to true (c.f. .githu... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -50,8 +50,8 @@\n \n def _is_test_pypi():\n \"\"\"\n- Determine if the Travis CI environment has TESTPYPI_UPLOAD defined and\n- set to true (c.f. .travis.yml)\n+ Determine if the CI environment has IS_TESTPYPI defined and\... | 1,573 | 194 |
gh_patches_debug_59597 | rasdani/github-patches | git_diff | googleapis__python-bigquery-587 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
loosen opentelemetry dependencies
See Spanner PR: https://github.com/googleapis/python-spanner/pull/298
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files ... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -53,9 +53,9 @@
"bignumeric_type": ["pyarrow >= 3.0.0, < 4.0dev"],
"tqdm": ["tqdm >= 4.7.4, <5.0.0dev"],
"opentelemetry": [
- "opentelemetry-api==0.11b0",
- "opentelemetry-sdk==0.11b0",
- "opentelemetry-instrumentation=... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -53,9 +53,9 @@\n \"bignumeric_type\": [\"pyarrow >= 3.0.0, < 4.0dev\"],\n \"tqdm\": [\"tqdm >= 4.7.4, <5.0.0dev\"],\n \"opentelemetry\": [\n- \"opentelemetry-api==0.11b0\",\n- \"opentelemetry-sdk==0.11b0\",\n... | 1,740 | 190 |
gh_patches_debug_14536 | rasdani/github-patches | git_diff | mozmeao__snippets-service-864 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Filter by release channel on ASRSnippets raises an error
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `s... | diff --git a/snippets/base/admin/filters.py b/snippets/base/admin/filters.py
--- a/snippets/base/admin/filters.py
+++ b/snippets/base/admin/filters.py
@@ -3,6 +3,8 @@
from django.contrib import admin
from django.utils.encoding import force_text
+from snippets.base.managers import SnippetQuerySet
+
class Modified... | {"golden_diff": "diff --git a/snippets/base/admin/filters.py b/snippets/base/admin/filters.py\n--- a/snippets/base/admin/filters.py\n+++ b/snippets/base/admin/filters.py\n@@ -3,6 +3,8 @@\n from django.contrib import admin\n from django.utils.encoding import force_text\n \n+from snippets.base.managers import SnippetQuer... | 890 | 181 |
gh_patches_debug_21120 | rasdani/github-patches | git_diff | chainer__chainer-242 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add type check to NonparameterizedLinear function
Related to #123
--- 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/chainer/functions/nonparameterized_linear.py b/chainer/functions/nonparameterized_linear.py
--- a/chainer/functions/nonparameterized_linear.py
+++ b/chainer/functions/nonparameterized_linear.py
@@ -1,6 +1,9 @@
+import numpy
+
from chainer import cuda
from chainer import function
from chainer.functions i... | {"golden_diff": "diff --git a/chainer/functions/nonparameterized_linear.py b/chainer/functions/nonparameterized_linear.py\n--- a/chainer/functions/nonparameterized_linear.py\n+++ b/chainer/functions/nonparameterized_linear.py\n@@ -1,6 +1,9 @@\n+import numpy\n+\n from chainer import cuda\n from chainer import function\n... | 705 | 330 |
gh_patches_debug_63158 | rasdani/github-patches | git_diff | dotkom__onlineweb4-2101 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Users should be able to edit expired 'careeropportunity' from Dashboard
## What kind of an issue is this?
- Feature request
## What is the expected behaviour?
You should be able to click to edit from t... | diff --git a/apps/careeropportunity/dashboard/views.py b/apps/careeropportunity/dashboard/views.py
--- a/apps/careeropportunity/dashboard/views.py
+++ b/apps/careeropportunity/dashboard/views.py
@@ -27,7 +27,7 @@
cops = CareerOpportunity.objects.all()
context['cops'] = cops.filter(end__gte=timezone.now()).ord... | {"golden_diff": "diff --git a/apps/careeropportunity/dashboard/views.py b/apps/careeropportunity/dashboard/views.py\n--- a/apps/careeropportunity/dashboard/views.py\n+++ b/apps/careeropportunity/dashboard/views.py\n@@ -27,7 +27,7 @@\n cops = CareerOpportunity.objects.all()\n context['cops'] = cops.filter(end__g... | 1,174 | 135 |
gh_patches_debug_12009 | rasdani/github-patches | git_diff | Netflix__lemur-111 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Duplicate Plugins Listed
Plugins are duplicated in the authority dropdown.
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN ... | diff --git a/lemur/common/managers.py b/lemur/common/managers.py
--- a/lemur/common/managers.py
+++ b/lemur/common/managers.py
@@ -22,7 +22,8 @@
def add(self, class_path):
self.cache = None
- self.class_list.append(class_path)
+ if class_path not in self.class_list:
+ self.class... | {"golden_diff": "diff --git a/lemur/common/managers.py b/lemur/common/managers.py\n--- a/lemur/common/managers.py\n+++ b/lemur/common/managers.py\n@@ -22,7 +22,8 @@\n \n def add(self, class_path):\n self.cache = None\n- self.class_list.append(class_path)\n+ if class_path not in self.class_list... | 1,901 | 199 |
gh_patches_debug_12142 | rasdani/github-patches | git_diff | safe-global__safe-config-service-90 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Use different namespace and endpoint name for `/safe-apps`
The endpoint `/api/v1/safe-apps` is currently under the `v1` namespace and `safe-apps` endpoint name.
To align it better with the future endpoints... | diff --git a/src/config/urls.py b/src/config/urls.py
--- a/src/config/urls.py
+++ b/src/config/urls.py
@@ -11,7 +11,7 @@
)
urlpatterns = [
- path("api/v1/", include("safe_apps.urls", namespace="v1")),
+ path("api/v1/", include("safe_apps.urls", namespace="safe-apps")),
path("api/v1/", include("chains.url... | {"golden_diff": "diff --git a/src/config/urls.py b/src/config/urls.py\n--- a/src/config/urls.py\n+++ b/src/config/urls.py\n@@ -11,7 +11,7 @@\n )\n \n urlpatterns = [\n- path(\"api/v1/\", include(\"safe_apps.urls\", namespace=\"v1\")),\n+ path(\"api/v1/\", include(\"safe_apps.urls\", namespace=\"safe-apps\")),\n ... | 699 | 228 |
gh_patches_debug_41061 | rasdani/github-patches | git_diff | streamlink__streamlink-3019 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[bug] BTV plugin needs updating
## Bug Report
- [x] This is a bug report and I have read the contribution guidelines.
### Description
The location of the BTV livestream has moved to https://btvplus.bg/... | diff --git a/src/streamlink/plugins/btv.py b/src/streamlink/plugins/btv.py
--- a/src/streamlink/plugins/btv.py
+++ b/src/streamlink/plugins/btv.py
@@ -1,38 +1,30 @@
-from __future__ import print_function
+import argparse
+import logging
import re
-from streamlink import PluginError
-from streamlink.plugin import Plu... | {"golden_diff": "diff --git a/src/streamlink/plugins/btv.py b/src/streamlink/plugins/btv.py\n--- a/src/streamlink/plugins/btv.py\n+++ b/src/streamlink/plugins/btv.py\n@@ -1,38 +1,30 @@\n-from __future__ import print_function\n+import argparse\n+import logging\n import re\n \n-from streamlink import PluginError\n-from s... | 1,231 | 890 |
gh_patches_debug_27700 | rasdani/github-patches | git_diff | streamlink__streamlink-5742 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
plugins.atresplayer: Error -3 while decompressing data: incorrect header check
### Checklist
- [X] This is a [plugin issue](https://streamlink.github.io/plugins.html) and not [a different kind of issue](http... | diff --git a/src/streamlink/plugins/atresplayer.py b/src/streamlink/plugins/atresplayer.py
--- a/src/streamlink/plugins/atresplayer.py
+++ b/src/streamlink/plugins/atresplayer.py
@@ -23,7 +23,7 @@
))
class AtresPlayer(Plugin):
_channels_api_url = "https://api.atresplayer.com/client/v1/info/channels"
- _player... | {"golden_diff": "diff --git a/src/streamlink/plugins/atresplayer.py b/src/streamlink/plugins/atresplayer.py\n--- a/src/streamlink/plugins/atresplayer.py\n+++ b/src/streamlink/plugins/atresplayer.py\n@@ -23,7 +23,7 @@\n ))\n class AtresPlayer(Plugin):\n _channels_api_url = \"https://api.atresplayer.com/client/v1/inf... | 1,898 | 310 |
gh_patches_debug_17070 | rasdani/github-patches | git_diff | xonsh__xonsh-341 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
xonsh dies if the prompt raises an exception
If a function in the prompt raises an exception, it kills xonsh. I would expect the error to be displayed, but not kill the shell.
--- END ISSUE ---
Below are ... | diff --git a/xonsh/base_shell.py b/xonsh/base_shell.py
--- a/xonsh/base_shell.py
+++ b/xonsh/base_shell.py
@@ -102,12 +102,19 @@
"""Obtains the current prompt string."""
if self.need_more_lines:
if self.mlprompt is None:
- self.mlprompt = multiline_prompt()
+ ... | {"golden_diff": "diff --git a/xonsh/base_shell.py b/xonsh/base_shell.py\n--- a/xonsh/base_shell.py\n+++ b/xonsh/base_shell.py\n@@ -102,12 +102,19 @@\n \"\"\"Obtains the current prompt string.\"\"\"\n if self.need_more_lines:\n if self.mlprompt is None:\n- self.mlprompt = multi... | 1,480 | 217 |
gh_patches_debug_36944 | rasdani/github-patches | git_diff | paperless-ngx__paperless-ngx-903 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[BUG] Password reset after docker container restarted
*Copy from old repository*: https://github.com/jonaswinkler/paperless-ng/issues/1511
**Describe the bug**
I deployed Paperless-NG in TrueNAS via the T... | diff --git a/src/documents/management/commands/manage_superuser.py b/src/documents/management/commands/manage_superuser.py
--- a/src/documents/management/commands/manage_superuser.py
+++ b/src/documents/management/commands/manage_superuser.py
@@ -11,7 +11,14 @@
class Command(BaseCommand):
help = """
- Cr... | {"golden_diff": "diff --git a/src/documents/management/commands/manage_superuser.py b/src/documents/management/commands/manage_superuser.py\n--- a/src/documents/management/commands/manage_superuser.py\n+++ b/src/documents/management/commands/manage_superuser.py\n@@ -11,7 +11,14 @@\n class Command(BaseCommand):\n \n ... | 960 | 658 |
gh_patches_debug_9140 | rasdani/github-patches | git_diff | Lightning-AI__torchmetrics-1155 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
notation typo in Cosine Similarity docs
## 📚 Documentation
There is a typo in the notation for the [pairwise_cosine_similarity](https://torchmetrics.readthedocs.io/en/stable/pairwise/cosine_similarity.ht... | diff --git a/src/torchmetrics/functional/pairwise/cosine.py b/src/torchmetrics/functional/pairwise/cosine.py
--- a/src/torchmetrics/functional/pairwise/cosine.py
+++ b/src/torchmetrics/functional/pairwise/cosine.py
@@ -54,7 +54,7 @@
.. math::
s_{cos}(x,y) = \frac{<x,y>}{||x|| \cdot ||y||}
- ... | {"golden_diff": "diff --git a/src/torchmetrics/functional/pairwise/cosine.py b/src/torchmetrics/functional/pairwise/cosine.py\n--- a/src/torchmetrics/functional/pairwise/cosine.py\n+++ b/src/torchmetrics/functional/pairwise/cosine.py\n@@ -54,7 +54,7 @@\n \n .. math::\n s_{cos}(x,y) = \\frac{<x,y>}{||x|| \\c... | 1,564 | 259 |
gh_patches_debug_27323 | rasdani/github-patches | git_diff | mindsdb__lightwood-168 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Construct comperhensive test suite to evaluate predictions with missing column
We should have a test suite to evaluate prediction accuracy with missing column.
This should take the form of:
Given `M` co... | diff --git a/docs/examples/learn_to_classify.py b/docs/examples/learn_to_classify.py
--- a/docs/examples/learn_to_classify.py
+++ b/docs/examples/learn_to_classify.py
@@ -34,14 +34,18 @@
predictor.learn(from_data=data_train, callback_on_iter=iter_function, eval_every_x_epochs=200)
predictor.save('/tmp/ltcrl.p... | {"golden_diff": "diff --git a/docs/examples/learn_to_classify.py b/docs/examples/learn_to_classify.py\n--- a/docs/examples/learn_to_classify.py\n+++ b/docs/examples/learn_to_classify.py\n@@ -34,14 +34,18 @@\n predictor.learn(from_data=data_train, callback_on_iter=iter_function, eval_every_x_epochs=200)\n predic... | 1,076 | 333 |
gh_patches_debug_35750 | rasdani/github-patches | git_diff | chainer__chainer-1663 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Test N-dimensional convolution link for dtypes of FP16 and FP64
Follows #1279 and #1556.
Since #1295 is now merged to master, we can add test for dtypes of FP16 and FP64 to N-dimensional convolution **LINK**... | diff --git a/chainer/links/connection/convolution_nd.py b/chainer/links/connection/convolution_nd.py
--- a/chainer/links/connection/convolution_nd.py
+++ b/chainer/links/connection/convolution_nd.py
@@ -22,16 +22,11 @@
``pad=p`` and ``pad=(p, p, ..., p)`` are equivalent.
initialW: Value used to in... | {"golden_diff": "diff --git a/chainer/links/connection/convolution_nd.py b/chainer/links/connection/convolution_nd.py\n--- a/chainer/links/connection/convolution_nd.py\n+++ b/chainer/links/connection/convolution_nd.py\n@@ -22,16 +22,11 @@\n ``pad=p`` and ``pad=(p, p, ..., p)`` are equivalent.\n init... | 1,358 | 548 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.