problem_id stringlengths 18 21 | source stringclasses 1
value | task_type stringclasses 1
value | in_source_id stringlengths 13 54 | prompt stringlengths 1.28k 64.2k | golden_diff stringlengths 166 811 | verification_info stringlengths 604 118k |
|---|---|---|---|---|---|---|
gh_patches_debug_200 | rasdani/github-patches | git_diff | DjangoGirls__djangogirls-153 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Error when there is more than one form for a page

--- END ISSUE -... | diff --git a/applications/views.py b/applications/views.py
--- a/applications/views.py
+++ b/applications/views.py
@@ -24,7 +24,7 @@
)
try:
- form_obj = Form.objects.get(page=page)
+ form_obj = Form.objects.filter(page=page).first()
except Form.DoesNotExist:
return redirect('... | {"golden_diff": "diff --git a/applications/views.py b/applications/views.py\n--- a/applications/views.py\n+++ b/applications/views.py\n@@ -24,7 +24,7 @@\n )\n \n try:\n- form_obj = Form.objects.get(page=page)\n+ form_obj = Form.objects.filter(page=page).first()\n except Form.DoesNotExist:\... |
gh_patches_debug_201 | rasdani/github-patches | git_diff | django-json-api__django-rest-framework-json-api-937 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Release needed for Django 3.2 Update
Hello,
I see that there was a change to allow Django 3.2, but no new release has happened. This is preventing us from upgrading, could we get a new version released?
... | diff --git a/rest_framework_json_api/__init__.py b/rest_framework_json_api/__init__.py
--- a/rest_framework_json_api/__init__.py
+++ b/rest_framework_json_api/__init__.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
__title__ = "djangorestframework-jsonapi"
-__version__ = "4.1.0"
+__version__ = "4.2.0"
__author__ = ""
... | {"golden_diff": "diff --git a/rest_framework_json_api/__init__.py b/rest_framework_json_api/__init__.py\n--- a/rest_framework_json_api/__init__.py\n+++ b/rest_framework_json_api/__init__.py\n@@ -1,7 +1,7 @@\n # -*- coding: utf-8 -*-\n \n __title__ = \"djangorestframework-jsonapi\"\n-__version__ = \"4.1.0\"\n+__version_... |
gh_patches_debug_202 | rasdani/github-patches | git_diff | django-json-api__django-rest-framework-json-api-383 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
release 2.3.0?
It's in the changelog but it hasn't been released. Would you mind cutting a release for pypi? In particular the `Added nested included serializer support for remapped relations` is something we... | diff --git a/rest_framework_json_api/__init__.py b/rest_framework_json_api/__init__.py
--- a/rest_framework_json_api/__init__.py
+++ b/rest_framework_json_api/__init__.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
__title__ = 'djangorestframework-jsonapi'
-__version__ = '2.2.0'
+__version__ = '2.3.0'
__author__ = ''
... | {"golden_diff": "diff --git a/rest_framework_json_api/__init__.py b/rest_framework_json_api/__init__.py\n--- a/rest_framework_json_api/__init__.py\n+++ b/rest_framework_json_api/__init__.py\n@@ -1,7 +1,7 @@\n # -*- coding: utf-8 -*-\n \n __title__ = 'djangorestframework-jsonapi'\n-__version__ = '2.2.0'\n+__version__ = ... |
gh_patches_debug_203 | rasdani/github-patches | git_diff | netket__netket-817 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
AbstractVariationalDriver.py bug in updating step_count

I think this error can be fixed eithe... | diff --git a/netket/driver/abstract_variational_driver.py b/netket/driver/abstract_variational_driver.py
--- a/netket/driver/abstract_variational_driver.py
+++ b/netket/driver/abstract_variational_driver.py
@@ -112,7 +112,7 @@
count is set to 0.
"""
self.state.reset()
- self.step_count... | {"golden_diff": "diff --git a/netket/driver/abstract_variational_driver.py b/netket/driver/abstract_variational_driver.py\n--- a/netket/driver/abstract_variational_driver.py\n+++ b/netket/driver/abstract_variational_driver.py\n@@ -112,7 +112,7 @@\n count is set to 0.\n \"\"\"\n self.state.reset(... |
gh_patches_debug_204 | rasdani/github-patches | git_diff | spotify__luigi-1372 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add method to S3Target to get back path
With an `S3Target(path)`, we can load data into S3 at the specified path. It would be useful if we could also get back the path at which the target is pointing to so it... | diff --git a/luigi/s3.py b/luigi/s3.py
--- a/luigi/s3.py
+++ b/luigi/s3.py
@@ -501,6 +501,7 @@
if format is None:
format = get_default_format()
+ self.path = path
self.format = format
self.fs = client or S3Client()
| {"golden_diff": "diff --git a/luigi/s3.py b/luigi/s3.py\n--- a/luigi/s3.py\n+++ b/luigi/s3.py\n@@ -501,6 +501,7 @@\n if format is None:\n format = get_default_format()\n \n+ self.path = path\n self.format = format\n self.fs = client or S3Client()\n", "issue": "Add method to S3... |
gh_patches_debug_205 | rasdani/github-patches | git_diff | vllm-project__vllm-3129 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[v0.3.3] Release Tracker
**ETA**: Feb 29th - Mar 1st
## Major changes
* StarCoder2 support
* Performance optimization and LoRA support for Gemma
* Performance optimization for MoE kernel
* 2/3/8-bit ... | diff --git a/vllm/__init__.py b/vllm/__init__.py
--- a/vllm/__init__.py
+++ b/vllm/__init__.py
@@ -8,7 +8,7 @@
from vllm.outputs import CompletionOutput, RequestOutput
from vllm.sampling_params import SamplingParams
-__version__ = "0.3.2"
+__version__ = "0.3.3"
__all__ = [
"LLM",
| {"golden_diff": "diff --git a/vllm/__init__.py b/vllm/__init__.py\n--- a/vllm/__init__.py\n+++ b/vllm/__init__.py\n@@ -8,7 +8,7 @@\n from vllm.outputs import CompletionOutput, RequestOutput\n from vllm.sampling_params import SamplingParams\n \n-__version__ = \"0.3.2\"\n+__version__ = \"0.3.3\"\n \n __all__ = [\n \"... |
gh_patches_debug_206 | rasdani/github-patches | git_diff | vllm-project__vllm-2887 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[v0.3.1] Release Tracker
**ETA**: Feb 14-16 th
## Major changes
TBD
## PRs to be merged before the release
- [x] #2855
- [x] #2845
- [x] ~~#2514~~
- [x] Ensure memory release when `LLM` class... | diff --git a/vllm/__init__.py b/vllm/__init__.py
--- a/vllm/__init__.py
+++ b/vllm/__init__.py
@@ -8,7 +8,7 @@
from vllm.outputs import CompletionOutput, RequestOutput
from vllm.sampling_params import SamplingParams
-__version__ = "0.3.0"
+__version__ = "0.3.1"
__all__ = [
"LLM",
| {"golden_diff": "diff --git a/vllm/__init__.py b/vllm/__init__.py\n--- a/vllm/__init__.py\n+++ b/vllm/__init__.py\n@@ -8,7 +8,7 @@\n from vllm.outputs import CompletionOutput, RequestOutput\n from vllm.sampling_params import SamplingParams\n \n-__version__ = \"0.3.0\"\n+__version__ = \"0.3.1\"\n \n __all__ = [\n \"... |
gh_patches_debug_207 | rasdani/github-patches | git_diff | Gallopsled__pwntools-1252 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
'from pwn import *' fails when one of the command line args is a Base64 string (or has more than one equal sign)
The argument parsing functionality invoked by `from pwn import *` causes an error when one of t... | diff --git a/pwnlib/args.py b/pwnlib/args.py
--- a/pwnlib/args.py
+++ b/pwnlib/args.py
@@ -194,7 +194,7 @@
value = 'True'
if '=' in arg:
- arg, value = arg.split('=')
+ arg, value = arg.split('=', 1)
if arg in hooks:
sys.argv.remove(orig)
| {"golden_diff": "diff --git a/pwnlib/args.py b/pwnlib/args.py\n--- a/pwnlib/args.py\n+++ b/pwnlib/args.py\n@@ -194,7 +194,7 @@\n value = 'True'\n \n if '=' in arg:\n- arg, value = arg.split('=')\n+ arg, value = arg.split('=', 1)\n \n if arg in hooks:\n sys.argv.... |
gh_patches_debug_208 | rasdani/github-patches | git_diff | arviz-devs__arviz-1192 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Import fails when run using a Bokeh server
**Description of bug**
The import of `arviz` errors when running with a [Bokeh server](https://docs.bokeh.org/en/latest/docs/user_guide/server.html).
The resulti... | diff --git a/arviz/plots/backends/__init__.py b/arviz/plots/backends/__init__.py
--- a/arviz/plots/backends/__init__.py
+++ b/arviz/plots/backends/__init__.py
@@ -192,6 +192,8 @@
except ImportError:
doc = "Failed to import function {} from {}".format(function, lib)
+ if not isinstance(doc, str):
+ ... | {"golden_diff": "diff --git a/arviz/plots/backends/__init__.py b/arviz/plots/backends/__init__.py\n--- a/arviz/plots/backends/__init__.py\n+++ b/arviz/plots/backends/__init__.py\n@@ -192,6 +192,8 @@\n except ImportError:\n doc = \"Failed to import function {} from {}\".format(function, lib)\n \n+ if not ... |
gh_patches_debug_209 | rasdani/github-patches | git_diff | AUTOMATIC1111__stable-diffusion-webui-10635 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[Bug]: h11._util.LocalProtocolError: Can't send data when our state is ERROR
### Is there an existing issue for this?
- [X] I have searched the existing issues and checked the recent builds/commits
### ... | diff --git a/modules/api/api.py b/modules/api/api.py
--- a/modules/api/api.py
+++ b/modules/api/api.py
@@ -682,4 +682,4 @@
def launch(self, server_name, port):
self.app.include_router(self.router)
- uvicorn.run(self.app, host=server_name, port=port)
+ uvicorn.run(self.app, host=server_name... | {"golden_diff": "diff --git a/modules/api/api.py b/modules/api/api.py\n--- a/modules/api/api.py\n+++ b/modules/api/api.py\n@@ -682,4 +682,4 @@\n \n def launch(self, server_name, port):\n self.app.include_router(self.router)\n- uvicorn.run(self.app, host=server_name, port=port)\n+ uvicorn.run(s... |
gh_patches_debug_210 | rasdani/github-patches | git_diff | sunpy__sunpy-2906 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Pip installing sunpy dev fails
With `ci-helpers` I run into this issue for both travis/linux and appveyor:
Please have a look and open a PR in `ci-helpers` with the suggested fix for the case of `SUNPY_VER... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -15,6 +15,9 @@
import builtins # noqa
import itertools
+# Fix for https://github.com/pypa/pip/issues/6163
+sys.path.insert(0, os.path.dirname(__file__))
+
try:
from configparser import ConfigParser
except ImportError:
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -15,6 +15,9 @@\n import builtins # noqa\n import itertools\n \n+# Fix for https://github.com/pypa/pip/issues/6163\n+sys.path.insert(0, os.path.dirname(__file__))\n+\n try:\n from configparser import ConfigParser\n except ImportEr... |
gh_patches_debug_211 | rasdani/github-patches | git_diff | django-wiki__django-wiki-762 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Installation of 0.2.3 using pip seems to be missing a file
specifically the glyphicons font from bootstrap, located at: `/wiki/static/wiki/bootstrap/fonts/glyphicons-halflings-regular.woff2` within the reposi... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -37,7 +37,7 @@
"Django>=1.8,<2.0",
"bleach>=1.5,<2",
"Pillow",
- "django-nyt>=1.0b1",
+ "django-nyt>=1.0b1,<1.1",
"six",
"django-mptt>=0.8.6,<0.9",
"django-sekizai>=0.10",
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -37,7 +37,7 @@\n \"Django>=1.8,<2.0\",\n \"bleach>=1.5,<2\",\n \"Pillow\",\n- \"django-nyt>=1.0b1\",\n+ \"django-nyt>=1.0b1,<1.1\",\n \"six\",\n \"django-mptt>=0.8.6,<0.9\",\n \"django-sekizai>=0.10\",\n"... |
gh_patches_debug_212 | rasdani/github-patches | git_diff | facebookresearch__hydra-279 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[Bug] Documentation inconsistency for `utils.get_original_cwd`
# 🐛 Bug
The tutorial for working directories has a few commands for setting the working directory [see here](https://cli.dev/docs/tutorial/wo... | diff --git a/hydra/__init__.py b/hydra/__init__.py
--- a/hydra/__init__.py
+++ b/hydra/__init__.py
@@ -4,6 +4,6 @@
from .main import main
# Source of truth for Hydra's version
-__version__ = "0.10.0"
+__version__ = "0.11.0-pre1"
__all__ = ["__version__", "MissingConfigException", "main", "utils"]
| {"golden_diff": "diff --git a/hydra/__init__.py b/hydra/__init__.py\n--- a/hydra/__init__.py\n+++ b/hydra/__init__.py\n@@ -4,6 +4,6 @@\n from .main import main\n \n # Source of truth for Hydra's version\n-__version__ = \"0.10.0\"\n+__version__ = \"0.11.0-pre1\"\n \n __all__ = [\"__version__\", \"MissingConfigException\... |
gh_patches_debug_213 | rasdani/github-patches | git_diff | Gallopsled__pwntools-1129 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Unable to create a shell shellcraft for MIPS
The problem is as follows:
```py
>>> from pwnlib.shellcraft import mips
>>> mips.sh()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>... | diff --git a/pwnlib/shellcraft/registers.py b/pwnlib/shellcraft/registers.py
--- a/pwnlib/shellcraft/registers.py
+++ b/pwnlib/shellcraft/registers.py
@@ -211,7 +211,7 @@
'arm': arm,
'thumb': arm,
'aarch64': aarch64,
- 'mips': mips,
+ 'mips': list(mips),
'powerpc': powe... | {"golden_diff": "diff --git a/pwnlib/shellcraft/registers.py b/pwnlib/shellcraft/registers.py\n--- a/pwnlib/shellcraft/registers.py\n+++ b/pwnlib/shellcraft/registers.py\n@@ -211,7 +211,7 @@\n 'arm': arm,\n 'thumb': arm,\n 'aarch64': aarch64,\n- 'mips': mips,\n+ 'mips': list(mips),... |
gh_patches_debug_214 | rasdani/github-patches | git_diff | elastic__apm-agent-python-1149 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
AttributeError: 'Config' object has no attribute 'start_stop_order'
# Error
We started seeing this traceback via Sentry coming from the elasticapm agent with the Django integration after upgrading from 6.1.3... | diff --git a/elasticapm/conf/__init__.py b/elasticapm/conf/__init__.py
--- a/elasticapm/conf/__init__.py
+++ b/elasticapm/conf/__init__.py
@@ -647,6 +647,7 @@
"transport",
"_update_thread",
"pid",
+ "start_stop_order",
)
def __init__(self, config_object, version, transport=... | {"golden_diff": "diff --git a/elasticapm/conf/__init__.py b/elasticapm/conf/__init__.py\n--- a/elasticapm/conf/__init__.py\n+++ b/elasticapm/conf/__init__.py\n@@ -647,6 +647,7 @@\n \"transport\",\n \"_update_thread\",\n \"pid\",\n+ \"start_stop_order\",\n )\n \n def __init__(self,... |
gh_patches_debug_215 | rasdani/github-patches | git_diff | facebookresearch__xformers-151 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Follow up on #141 with a proper unit test
# 🐛 Bug
Make sure that #141 cannot happen anymore, add a small unit test to guard parity
Follow up on #141 with a proper unit test
# 🐛 Bug
Make sure that #141 c... | diff --git a/xformers/triton/softmax.py b/xformers/triton/softmax.py
--- a/xformers/triton/softmax.py
+++ b/xformers/triton/softmax.py
@@ -200,7 +200,7 @@
_triton_registered_warnings = True
if mask is not None:
- x += mask
+ x = x + mask
if log:
return torch.log_softmax(x, ... | {"golden_diff": "diff --git a/xformers/triton/softmax.py b/xformers/triton/softmax.py\n--- a/xformers/triton/softmax.py\n+++ b/xformers/triton/softmax.py\n@@ -200,7 +200,7 @@\n _triton_registered_warnings = True\n \n if mask is not None:\n- x += mask\n+ x = x + mask\n \n if log:\n ... |
gh_patches_debug_216 | rasdani/github-patches | git_diff | pypi__warehouse-7741 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add Russian translation
The Russian Translation is at [100% on Weblate](https://hosted.weblate.org/languages/ru/pypa/) so I think it should be added to the localization footer.
--- END ISSUE ---
Below are s... | diff --git a/warehouse/i18n/__init__.py b/warehouse/i18n/__init__.py
--- a/warehouse/i18n/__init__.py
+++ b/warehouse/i18n/__init__.py
@@ -31,6 +31,7 @@
"el": "Ελληνικά", # Greek
"de": "Deutsch", # German
"zh_Hans": "简体中文", # Simplified Chinese
+ "ru": "Русский", # Russian
}
LOCALE_ATTR = "_LO... | {"golden_diff": "diff --git a/warehouse/i18n/__init__.py b/warehouse/i18n/__init__.py\n--- a/warehouse/i18n/__init__.py\n+++ b/warehouse/i18n/__init__.py\n@@ -31,6 +31,7 @@\n \"el\": \"\u0395\u03bb\u03bb\u03b7\u03bd\u03b9\u03ba\u03ac\", # Greek\n \"de\": \"Deutsch\", # German\n \"zh_Hans\": \"\u7b80\u4f53... |
gh_patches_debug_217 | rasdani/github-patches | git_diff | getpelican__pelican-905 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
pelican-quickstart: error with accented characters
Hello,
I've got a problem with pelican-quickstart, when I put accented characters in answers.
Here is the output I got :
> Who will be the author of this... | diff --git a/pelican/tools/pelican_quickstart.py b/pelican/tools/pelican_quickstart.py
--- a/pelican/tools/pelican_quickstart.py
+++ b/pelican/tools/pelican_quickstart.py
@@ -37,8 +37,7 @@
if six.PY3:
r = input(prompt)
else:
- # FIXME: why use this with @decoding_strings?
- r = raw_inpu... | {"golden_diff": "diff --git a/pelican/tools/pelican_quickstart.py b/pelican/tools/pelican_quickstart.py\n--- a/pelican/tools/pelican_quickstart.py\n+++ b/pelican/tools/pelican_quickstart.py\n@@ -37,8 +37,7 @@\n if six.PY3:\n r = input(prompt)\n else:\n- # FIXME: why use this with @decoding_string... |
gh_patches_debug_218 | rasdani/github-patches | git_diff | searxng__searxng-299 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Bug: openstreetmap engine
**Version of SearXNG, commit number if you are using on master branch and stipulate if you forked SearXNG**
Repository: https://github.com/searxng/searxng
Branch: master
Version: ... | diff --git a/searx/engines/openstreetmap.py b/searx/engines/openstreetmap.py
--- a/searx/engines/openstreetmap.py
+++ b/searx/engines/openstreetmap.py
@@ -439,3 +439,8 @@
if labels is None:
return None
return get_label(labels, lang)
+
+
+def init(_):
+ import searx.engines.wikidata # pyli... | {"golden_diff": "diff --git a/searx/engines/openstreetmap.py b/searx/engines/openstreetmap.py\n--- a/searx/engines/openstreetmap.py\n+++ b/searx/engines/openstreetmap.py\n@@ -439,3 +439,8 @@\n if labels is None:\n return None\n return get_label(labels, lang)\n+\n+\n+def init(_):\n+ import sea... |
gh_patches_debug_219 | rasdani/github-patches | git_diff | googleapis__google-api-python-client-1030 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
googleapiclient.discovery.build fails with module 'six.moves' has no attribute 'collections_abc' since version 1.12.0
#### Environment details
- OS type and version: 18.04.1-Ubuntu
- Python version: P... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -42,7 +42,7 @@
"google-auth>=1.16.0",
"google-auth-httplib2>=0.0.3",
"google-api-core>=1.21.0,<2dev",
- "six>=1.6.1,<2dev",
+ "six>=1.13.0,<2dev",
"uritemplate>=3.0.0,<4dev",
]
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -42,7 +42,7 @@\n \"google-auth>=1.16.0\",\n \"google-auth-httplib2>=0.0.3\",\n \"google-api-core>=1.21.0,<2dev\",\n- \"six>=1.6.1,<2dev\",\n+ \"six>=1.13.0,<2dev\",\n \"uritemplate>=3.0.0,<4dev\",\n ]\n", "issue"... |
gh_patches_debug_220 | rasdani/github-patches | git_diff | pypi__warehouse-3600 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Set samesite=lax on session cookies
This is a strong defense-in-depth mechanism for protecting against CSRF. It's currently only respected by Chrome, but Firefox will add it as well.
Update webob to 1.8.0
Th... | diff --git a/warehouse/sessions.py b/warehouse/sessions.py
--- a/warehouse/sessions.py
+++ b/warehouse/sessions.py
@@ -263,6 +263,7 @@
max_age=self.max_age,
httponly=True,
secure=request.scheme == "https",
+ samesite=b"lax"
)
| {"golden_diff": "diff --git a/warehouse/sessions.py b/warehouse/sessions.py\n--- a/warehouse/sessions.py\n+++ b/warehouse/sessions.py\n@@ -263,6 +263,7 @@\n max_age=self.max_age,\n httponly=True,\n secure=request.scheme == \"https\",\n+ samesite=b\"lax\"\n ... |
gh_patches_debug_221 | rasdani/github-patches | git_diff | conda__conda-2472 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
When no condarc is found "no path!" is printed
Why was https://github.com/conda/conda/blob/master/conda/config.py#L115 added?
Is this a debug statement which never got removed?
--- END ISSUE ---
Below are ... | diff --git a/conda/config.py b/conda/config.py
--- a/conda/config.py
+++ b/conda/config.py
@@ -113,7 +113,6 @@
def load_condarc(path):
if not path or not isfile(path):
- print("no path!")
return {}
with open(path) as f:
return yaml_load(f) or {}
| {"golden_diff": "diff --git a/conda/config.py b/conda/config.py\n--- a/conda/config.py\n+++ b/conda/config.py\n@@ -113,7 +113,6 @@\n \n def load_condarc(path):\n if not path or not isfile(path):\n- print(\"no path!\")\n return {}\n with open(path) as f:\n return yaml_load(f) or {}\n", "is... |
gh_patches_debug_222 | rasdani/github-patches | git_diff | urllib3__urllib3-1028 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add unit test for RECENT_DATE
I've got a feeling this value could be easily forgotten to be updated over time. Could we perhaps add a unit test that will fail if it gets to be too far away from the current da... | diff --git a/urllib3/connection.py b/urllib3/connection.py
--- a/urllib3/connection.py
+++ b/urllib3/connection.py
@@ -56,7 +56,10 @@
'https': 443,
}
-RECENT_DATE = datetime.date(2014, 1, 1)
+# When updating RECENT_DATE, move it to
+# within two years of the current date, and no
+# earlier than 6 months ago.
+R... | {"golden_diff": "diff --git a/urllib3/connection.py b/urllib3/connection.py\n--- a/urllib3/connection.py\n+++ b/urllib3/connection.py\n@@ -56,7 +56,10 @@\n 'https': 443,\n }\n \n-RECENT_DATE = datetime.date(2014, 1, 1)\n+# When updating RECENT_DATE, move it to\n+# within two years of the current date, and no\n+# ea... |
gh_patches_debug_223 | rasdani/github-patches | git_diff | conda__conda-build-4062 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
conda build calls `sys.exit` when downloading the source
<!--
Thanks for opening an issue! A few things to keep in mind:
- This issue tracker is for issues with or enhancements for conda-build.
Anacond... | diff --git a/conda_build/source.py b/conda_build/source.py
--- a/conda_build/source.py
+++ b/conda_build/source.py
@@ -612,7 +612,7 @@
exception = None
if not isfile(path):
- sys.exit('Error: no such patch: %s' % path)
+ raise RuntimeError('Error: no such patch: %s' % path)
if config.ve... | {"golden_diff": "diff --git a/conda_build/source.py b/conda_build/source.py\n--- a/conda_build/source.py\n+++ b/conda_build/source.py\n@@ -612,7 +612,7 @@\n \n exception = None\n if not isfile(path):\n- sys.exit('Error: no such patch: %s' % path)\n+ raise RuntimeError('Error: no such patch: %s' % ... |
gh_patches_debug_224 | rasdani/github-patches | git_diff | python-discord__site-758 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Missing API response for `last_applied` field
The added `last_applied` attribute in #751 currently is not in the API response.
--- END ISSUE ---
Below are some code segments, each from a relevant file. One ... | diff --git a/pydis_site/apps/api/serializers.py b/pydis_site/apps/api/serializers.py
--- a/pydis_site/apps/api/serializers.py
+++ b/pydis_site/apps/api/serializers.py
@@ -176,6 +176,7 @@
fields = (
'id',
'inserted_at',
+ 'last_applied',
'expires_at',
... | {"golden_diff": "diff --git a/pydis_site/apps/api/serializers.py b/pydis_site/apps/api/serializers.py\n--- a/pydis_site/apps/api/serializers.py\n+++ b/pydis_site/apps/api/serializers.py\n@@ -176,6 +176,7 @@\n fields = (\n 'id',\n 'inserted_at',\n+ 'last_applied',\n ... |
gh_patches_debug_225 | rasdani/github-patches | git_diff | OBOFoundry__OBOFoundry.github.io-1378 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Implement schema for usages
Issue #1179 asks to add usage information to the ontology detail pages. Before we can do that, we need to standardize that information. #1008 points out that there are different fo... | diff --git a/util/validate-metadata.py b/util/validate-metadata.py
--- a/util/validate-metadata.py
+++ b/util/validate-metadata.py
@@ -79,7 +79,7 @@
with open(file, 'r') as s:
schema = json.load(s)
except Exception as e:
- print('Unable to load %s: %s' % (f, str(e)))
+ print('Unable to load %s: %s'... | {"golden_diff": "diff --git a/util/validate-metadata.py b/util/validate-metadata.py\n--- a/util/validate-metadata.py\n+++ b/util/validate-metadata.py\n@@ -79,7 +79,7 @@\n with open(file, 'r') as s:\n schema = json.load(s)\n except Exception as e:\n- print('Unable to load %s: %s' % (f, str(e)))\n+ prin... |
gh_patches_debug_226 | rasdani/github-patches | git_diff | mars-project__mars-126 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Implement __array__ protocol for Tensor
**Is your feature request related to a problem? Please describe.**
By now, Mars tensor does not implement `__array__` protocol, so if `numpy.asarray` is called, will... | diff --git a/mars/tensor/core.py b/mars/tensor/core.py
--- a/mars/tensor/core.py
+++ b/mars/tensor/core.py
@@ -546,6 +546,9 @@
self._data = set_imag(self._data, new_imag).data
+ def __array__(self, dtype=None):
+ return np.asarray(self.execute(), dtype=dtype)
+
class SparseTensor(Tensor):
... | {"golden_diff": "diff --git a/mars/tensor/core.py b/mars/tensor/core.py\n--- a/mars/tensor/core.py\n+++ b/mars/tensor/core.py\n@@ -546,6 +546,9 @@\n \n self._data = set_imag(self._data, new_imag).data\n \n+ def __array__(self, dtype=None):\n+ return np.asarray(self.execute(), dtype=dtype)\n+\n \n clas... |
gh_patches_debug_227 | rasdani/github-patches | git_diff | ivy-llc__ivy-16291 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
mish
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `ivy/functional/frontends/paddle/nn/functional/activat... | diff --git a/ivy/functional/frontends/paddle/nn/functional/activation.py b/ivy/functional/frontends/paddle/nn/functional/activation.py
--- a/ivy/functional/frontends/paddle/nn/functional/activation.py
+++ b/ivy/functional/frontends/paddle/nn/functional/activation.py
@@ -191,3 +191,9 @@
ret = ivy.relu(x)
ivy.i... | {"golden_diff": "diff --git a/ivy/functional/frontends/paddle/nn/functional/activation.py b/ivy/functional/frontends/paddle/nn/functional/activation.py\n--- a/ivy/functional/frontends/paddle/nn/functional/activation.py\n+++ b/ivy/functional/frontends/paddle/nn/functional/activation.py\n@@ -191,3 +191,9 @@\n ret = i... |
gh_patches_debug_228 | rasdani/github-patches | git_diff | paperless-ngx__paperless-ngx-2371 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[Bug] Websockets do not respect subpath
### Discussed in https://github.com/paperless-ngx/paperless-ngx/discussions/2236
<div type='discussions-op-text'>
<sup>Originally posted by **davidgiga1993** Dece... | diff --git a/src/paperless/urls.py b/src/paperless/urls.py
--- a/src/paperless/urls.py
+++ b/src/paperless/urls.py
@@ -154,7 +154,7 @@
websocket_urlpatterns = [
- re_path(r"ws/status/$", StatusConsumer.as_asgi()),
+ path(settings.BASE_URL.lstrip("/") + "ws/status/", StatusConsumer.as_asgi()),
]
# Text in... | {"golden_diff": "diff --git a/src/paperless/urls.py b/src/paperless/urls.py\n--- a/src/paperless/urls.py\n+++ b/src/paperless/urls.py\n@@ -154,7 +154,7 @@\n \n \n websocket_urlpatterns = [\n- re_path(r\"ws/status/$\", StatusConsumer.as_asgi()),\n+ path(settings.BASE_URL.lstrip(\"/\") + \"ws/status/\", StatusConsu... |
gh_patches_debug_229 | rasdani/github-patches | git_diff | marshmallow-code__webargs-385 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Fix compatibility with Falcon 2.0
Tests are currently failing when Falcon 2.0.0 is installed.
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contai... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -14,7 +14,7 @@
"tornado>=4.5.2",
"pyramid>=1.9.1",
"webapp2>=3.0.0b1",
- "falcon>=1.4.0",
+ "falcon>=1.4.0,<2.0",
'aiohttp>=3.0.0; python_version >= "3.5"',
]
EXTRAS_REQUIRE = {
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -14,7 +14,7 @@\n \"tornado>=4.5.2\",\n \"pyramid>=1.9.1\",\n \"webapp2>=3.0.0b1\",\n- \"falcon>=1.4.0\",\n+ \"falcon>=1.4.0,<2.0\",\n 'aiohttp>=3.0.0; python_version >= \"3.5\"',\n ]\n EXTRAS_REQUIRE = {\n", "iss... |
gh_patches_debug_230 | rasdani/github-patches | git_diff | AnalogJ__lexicon-164 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Namecheap support not optional
Unlike route53 or softlayer and unlike what setup.py suggests, the namecheap provider is not optional in 2.1.17.
--- END ISSUE ---
Below are some code segments, each from a re... | diff --git a/lexicon/providers/namecheap.py b/lexicon/providers/namecheap.py
--- a/lexicon/providers/namecheap.py
+++ b/lexicon/providers/namecheap.py
@@ -3,10 +3,14 @@
import logging
-import namecheap
from .base import Provider as BaseProvider
+try:
+ import namecheap #optional dep
+except ImportError:
+ ... | {"golden_diff": "diff --git a/lexicon/providers/namecheap.py b/lexicon/providers/namecheap.py\n--- a/lexicon/providers/namecheap.py\n+++ b/lexicon/providers/namecheap.py\n@@ -3,10 +3,14 @@\n \n import logging\n \n-import namecheap\n \n from .base import Provider as BaseProvider\n \n+try:\n+ import namecheap #optiona... |
gh_patches_debug_231 | rasdani/github-patches | git_diff | ivy-llc__ivy-19479 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
__lshift__
--- 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/numpy/ndarray/ndarray.... | diff --git a/ivy/functional/frontends/numpy/ndarray/ndarray.py b/ivy/functional/frontends/numpy/ndarray/ndarray.py
--- a/ivy/functional/frontends/numpy/ndarray/ndarray.py
+++ b/ivy/functional/frontends/numpy/ndarray/ndarray.py
@@ -557,3 +557,6 @@
def __rshift__(self, value, /):
return ivy.bitwise_right_... | {"golden_diff": "diff --git a/ivy/functional/frontends/numpy/ndarray/ndarray.py b/ivy/functional/frontends/numpy/ndarray/ndarray.py\n--- a/ivy/functional/frontends/numpy/ndarray/ndarray.py\n+++ b/ivy/functional/frontends/numpy/ndarray/ndarray.py\n@@ -557,3 +557,6 @@\n \n def __rshift__(self, value, /):\n re... |
gh_patches_debug_232 | rasdani/github-patches | git_diff | facebookresearch__CompilerGym-364 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Required license headers missing
## 🐛 Bug
```
https://github.com/facebookresearch/CompilerGym/blob/development/www/demo_api.py:
The first 16 lines of 'www/demo_api.py' do not contain the patterns:
(Fa... | diff --git a/www/www.py b/www/www.py
--- a/www/www.py
+++ b/www/www.py
@@ -1,3 +1,7 @@
+# Copyright (c) Facebook, Inc. and its affiliates.
+#
+# This source code is licensed under the MIT license found in the
+# LICENSE file in the root directory of this source tree.
"""A CompilerGym API and web frontend.
This expo... | {"golden_diff": "diff --git a/www/www.py b/www/www.py\n--- a/www/www.py\n+++ b/www/www.py\n@@ -1,3 +1,7 @@\n+# Copyright (c) Facebook, Inc. and its affiliates.\n+#\n+# This source code is licensed under the MIT license found in the\n+# LICENSE file in the root directory of this source tree.\n \"\"\"A CompilerGym API an... |
gh_patches_debug_233 | rasdani/github-patches | git_diff | ibis-project__ibis-8929 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
bug: RisingWave race condition (?) where table returns before data is loaded
### What happened?
wanted to show off using RisingWave, and first needed to load in some data. separate issue that `to_pyarrow()` ... | diff --git a/ibis/backends/risingwave/__init__.py b/ibis/backends/risingwave/__init__.py
--- a/ibis/backends/risingwave/__init__.py
+++ b/ibis/backends/risingwave/__init__.py
@@ -119,6 +119,7 @@
with self.begin() as cur:
cur.execute("SET TIMEZONE = UTC")
+ cur.execute("SET RW_IMPLICIT... | {"golden_diff": "diff --git a/ibis/backends/risingwave/__init__.py b/ibis/backends/risingwave/__init__.py\n--- a/ibis/backends/risingwave/__init__.py\n+++ b/ibis/backends/risingwave/__init__.py\n@@ -119,6 +119,7 @@\n \n with self.begin() as cur:\n cur.execute(\"SET TIMEZONE = UTC\")\n+ cu... |
gh_patches_debug_234 | rasdani/github-patches | git_diff | pymodbus-dev__pymodbus-411 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Use pycryptodome instead of pycrypto.
<!--
Please use the Pymodbus gitter channel at https://gitter.im/pymodbus_dev/Lobby or Stack Overflow(tag [pymodbus](https://stackoverflow.com/questions/tagged/pymodbus)... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -85,7 +85,6 @@
'twisted': [
'twisted >= 12.2.0',
'pyasn1 >= 0.1.4',
- 'pycrypto >= 2.6'
],
'tornado': [
'tornado >= 4.5.3'
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -85,7 +85,6 @@\n 'twisted': [\n 'twisted >= 12.2.0',\n 'pyasn1 >= 0.1.4',\n- 'pycrypto >= 2.6'\n ],\n 'tornado': [\n 'tornado >= 4.5.3'\n", "issue": "Use pycryptod... |
gh_patches_debug_235 | rasdani/github-patches | git_diff | psychopy__psychopy-3812 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Feature request: Report the component name and routine of disabled components in Alert 4305
PsychoPy reports [an alert](https://psychopy.org/alerts/4305.html) when a component in the experiment is disabled. H... | diff --git a/psychopy/alerts/alerttools.py b/psychopy/alerts/alerttools.py
--- a/psychopy/alerts/alerttools.py
+++ b/psychopy/alerts/alerttools.py
@@ -260,7 +260,7 @@
return
if component.params['disabled'].val:
- alert(4305, component)
+ alert(4305, component, strFields={'name': component.... | {"golden_diff": "diff --git a/psychopy/alerts/alerttools.py b/psychopy/alerts/alerttools.py\n--- a/psychopy/alerts/alerttools.py\n+++ b/psychopy/alerts/alerttools.py\n@@ -260,7 +260,7 @@\n return\n \n if component.params['disabled'].val:\n- alert(4305, component)\n+ alert(4305, component, strF... |
gh_patches_debug_236 | rasdani/github-patches | git_diff | cython__cython-4942 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[BUG] Annotated attributes of cclass are not supporting pointers
<!--
**PLEASE READ THIS FIRST:**
- Do not use the bug and feature tracker for support requests. Use the `cython-users` mailing list instead.
... | diff --git a/docs/examples/tutorial/clibraries/queue.py b/docs/examples/tutorial/clibraries/queue.py
--- a/docs/examples/tutorial/clibraries/queue.py
+++ b/docs/examples/tutorial/clibraries/queue.py
@@ -2,7 +2,7 @@
@cython.cclass
class Queue:
- _c_queue = cython.declare(cython.pointer(cqueue.Queue))
+ _c_queu... | {"golden_diff": "diff --git a/docs/examples/tutorial/clibraries/queue.py b/docs/examples/tutorial/clibraries/queue.py\n--- a/docs/examples/tutorial/clibraries/queue.py\n+++ b/docs/examples/tutorial/clibraries/queue.py\n@@ -2,7 +2,7 @@\n \n @cython.cclass\n class Queue:\n- _c_queue = cython.declare(cython.pointer(cqu... |
gh_patches_debug_237 | rasdani/github-patches | git_diff | kornia__kornia-1861 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Bugs when using RandomRGBShift
### Describe the bug
When running RandomRGBShift augmentation on gpus I came across this error
```
File "/usr/local/lib/python3.8/dist-packages/kornia/augmentation/_2d... | diff --git a/kornia/enhance/shift_rgb.py b/kornia/enhance/shift_rgb.py
--- a/kornia/enhance/shift_rgb.py
+++ b/kornia/enhance/shift_rgb.py
@@ -14,6 +14,6 @@
shifts = [r_shift, g_shift, b_shift]
- shifted = (image + torch.Tensor(shifts).view(1, 3, 1, 1).to(image)).clamp_(min=0, max=1)
+ shifted = (image +... | {"golden_diff": "diff --git a/kornia/enhance/shift_rgb.py b/kornia/enhance/shift_rgb.py\n--- a/kornia/enhance/shift_rgb.py\n+++ b/kornia/enhance/shift_rgb.py\n@@ -14,6 +14,6 @@\n \n shifts = [r_shift, g_shift, b_shift]\n \n- shifted = (image + torch.Tensor(shifts).view(1, 3, 1, 1).to(image)).clamp_(min=0, max=1)... |
gh_patches_debug_238 | rasdani/github-patches | git_diff | mkdocs__mkdocs-1329 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Provide length of TableOfContents
Currently, you can only iter over `TableOfContents`. I would like to know the length of it.
--- END ISSUE ---
Below are some code segments, each from a relevant file. One o... | diff --git a/mkdocs/toc.py b/mkdocs/toc.py
--- a/mkdocs/toc.py
+++ b/mkdocs/toc.py
@@ -32,6 +32,9 @@
def __iter__(self):
return iter(self.items)
+ def __len__(self):
+ return len(self.items)
+
def __str__(self):
return ''.join([str(item) for item in self])
| {"golden_diff": "diff --git a/mkdocs/toc.py b/mkdocs/toc.py\n--- a/mkdocs/toc.py\n+++ b/mkdocs/toc.py\n@@ -32,6 +32,9 @@\n def __iter__(self):\n return iter(self.items)\n \n+ def __len__(self):\n+ return len(self.items)\n+\n def __str__(self):\n return ''.join([str(item) for item in se... |
gh_patches_debug_239 | rasdani/github-patches | git_diff | ManimCommunity__manim-1296 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Nondeterministic build failures in `Tex('The horse does not eat cucumber salad.')`
## Description of bug / unexpected behavior
<!-- Add a clear and concise description of the problem you encountered. -->
... | diff --git a/manim/utils/tex.py b/manim/utils/tex.py
--- a/manim/utils/tex.py
+++ b/manim/utils/tex.py
@@ -48,6 +48,7 @@
\usepackage[english]{babel}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
+\usepackage{lmodern}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{dsfont}
| {"golden_diff": "diff --git a/manim/utils/tex.py b/manim/utils/tex.py\n--- a/manim/utils/tex.py\n+++ b/manim/utils/tex.py\n@@ -48,6 +48,7 @@\n \\usepackage[english]{babel}\n \\usepackage[utf8]{inputenc}\n \\usepackage[T1]{fontenc}\n+\\usepackage{lmodern}\n \\usepackage{amsmath}\n \\usepackage{amssymb}\n \\usepackage{ds... |
gh_patches_debug_240 | rasdani/github-patches | git_diff | holoviz__panel-4047 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Make it easy and useful to use the VideoStream
I've never seen any showcases of the `VideoStream` in Panel. As Panel can update relatively quickly via Tornado and websockets it should be the best data app fra... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -191,7 +191,8 @@
'python-graphviz',
'xgboost',
'ipyvuetify',
- 'reacton'
+ 'reacton',
+ 'scikit-image',
],
'tests': _tests,
'recommended': _recommended,
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -191,7 +191,8 @@\n 'python-graphviz',\n 'xgboost',\n 'ipyvuetify',\n- 'reacton'\n+ 'reacton',\n+ 'scikit-image',\n ],\n 'tests': _tests,\n 'recommended': _recommended,\n", "issu... |
gh_patches_debug_241 | rasdani/github-patches | git_diff | pydantic__pydantic-2170 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
KeyError when having same Inner Class name in different Outer Class
### Checks
* [x] I added a descriptive title to this issue
* [x] I have searched (google, github) for similar issues and couldn't find a... | diff --git a/pydantic/schema.py b/pydantic/schema.py
--- a/pydantic/schema.py
+++ b/pydantic/schema.py
@@ -404,7 +404,7 @@
def get_long_model_name(model: TypeModelOrEnum) -> str:
- return f'{model.__module__}__{model.__name__}'.replace('.', '__')
+ return f'{model.__module__}__{model.__qualname__}'.replace('... | {"golden_diff": "diff --git a/pydantic/schema.py b/pydantic/schema.py\n--- a/pydantic/schema.py\n+++ b/pydantic/schema.py\n@@ -404,7 +404,7 @@\n \n \n def get_long_model_name(model: TypeModelOrEnum) -> str:\n- return f'{model.__module__}__{model.__name__}'.replace('.', '__')\n+ return f'{model.__module__}__{model... |
gh_patches_debug_242 | rasdani/github-patches | git_diff | talonhub__community-978 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
please map both comma and coma to , for now in keys.py
coma being recognized instead of comma comes up a lot for conformer b-series
I think for now we should bind both comma and coma as , in keys.py
and rev... | diff --git a/code/keys.py b/code/keys.py
--- a/code/keys.py
+++ b/code/keys.py
@@ -132,6 +132,8 @@
"back tick": "`",
"grave": "`",
"comma": ",",
+ # Workaround for issue with conformer b-series; see #946
+ "coma": ",",
"period": ".",
"full stop": ".",
"semicolon": ";",
| {"golden_diff": "diff --git a/code/keys.py b/code/keys.py\n--- a/code/keys.py\n+++ b/code/keys.py\n@@ -132,6 +132,8 @@\n \"back tick\": \"`\",\n \"grave\": \"`\",\n \"comma\": \",\",\n+ # Workaround for issue with conformer b-series; see #946\n+ \"coma\": \",\",\n \"period\": \".\",\n \"full s... |
gh_patches_debug_243 | rasdani/github-patches | git_diff | PaddlePaddle__models-2832 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
icnet 存在的几个问题
[icnet](https://github.com/PaddlePaddle/models/tree/develop/PaddleCV/icnet)里存在诸多问题:
1.文档有误,--model_path="./cnkpnt/100"应该是--model_path="./chkpnt/100"
2.训练时没有输出中间过程信息,仅在最后输出几个loss信息
3.文档中给的预训练模... | diff --git a/PaddleCV/icnet/train.py b/PaddleCV/icnet/train.py
--- a/PaddleCV/icnet/train.py
+++ b/PaddleCV/icnet/train.py
@@ -35,9 +35,11 @@
LAMBDA3 = 1.0
LEARNING_RATE = 0.003
POWER = 0.9
-LOG_PERIOD = 100
-CHECKPOINT_PERIOD = 100
-TOTAL_STEP = 100
+LOG_PERIOD = 1
+CHECKPOINT_PERIOD = 1000
+TOTAL_STEP = 60000
+if ... | {"golden_diff": "diff --git a/PaddleCV/icnet/train.py b/PaddleCV/icnet/train.py\n--- a/PaddleCV/icnet/train.py\n+++ b/PaddleCV/icnet/train.py\n@@ -35,9 +35,11 @@\n LAMBDA3 = 1.0\n LEARNING_RATE = 0.003\n POWER = 0.9\n-LOG_PERIOD = 100\n-CHECKPOINT_PERIOD = 100\n-TOTAL_STEP = 100\n+LOG_PERIOD = 1\n+CHECKPOINT_PERIOD = 1... |
gh_patches_debug_244 | rasdani/github-patches | git_diff | googleapis__google-cloud-python-3745 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Explicitly depend on setuptools
Context: #3295
We should explicitly depend on a minimum version of setuptools to get around problems installing our packages if setuptools is too old.
--- END ISSUE ---
Be... | diff --git a/core/setup.py b/core/setup.py
--- a/core/setup.py
+++ b/core/setup.py
@@ -55,6 +55,7 @@
'protobuf >= 3.0.0',
'google-auth >= 0.4.0, < 2.0.0dev',
'requests >= 2.4.0, < 3.0.0dev',
+ 'setuptools >= 34.0.0',
'six',
'tenacity >= 4.0.0, <5.0.0dev'
]
| {"golden_diff": "diff --git a/core/setup.py b/core/setup.py\n--- a/core/setup.py\n+++ b/core/setup.py\n@@ -55,6 +55,7 @@\n 'protobuf >= 3.0.0',\n 'google-auth >= 0.4.0, < 2.0.0dev',\n 'requests >= 2.4.0, < 3.0.0dev',\n+ 'setuptools >= 34.0.0',\n 'six',\n 'tenacity >= 4.0.0, <5.0.0dev'\n ]\n", "is... |
gh_patches_debug_245 | rasdani/github-patches | git_diff | dotkom__onlineweb4-1699 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
attendees_not_paid property is plain wrong
It returns all attendees who have paid instead. It is only used for sending out emails afaik.
https://github.com/dotKom/onlineweb4/blob/2347446f5bb66d202b7adecc9433... | diff --git a/apps/events/models.py b/apps/events/models.py
--- a/apps/events/models.py
+++ b/apps/events/models.py
@@ -449,7 +449,7 @@
@property
def attendees_not_paid(self):
- return [a for a in self.attendees_qs if a.paid]
+ return list(self.attendees.filter(paid=False))
@property
... | {"golden_diff": "diff --git a/apps/events/models.py b/apps/events/models.py\n--- a/apps/events/models.py\n+++ b/apps/events/models.py\n@@ -449,7 +449,7 @@\n \n @property\n def attendees_not_paid(self):\n- return [a for a in self.attendees_qs if a.paid]\n+ return list(self.attendees.filter(paid=Fal... |
gh_patches_debug_246 | rasdani/github-patches | git_diff | sonic-net__sonic-utilities-1117 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[consutil] show/connect command failed due to global name 'ConfigDBConnector' is not defined
<!--
If you are reporting a new issue, make sure that we do not have any duplicates
already open. You can ensure ... | diff --git a/consutil/lib.py b/consutil/lib.py
--- a/consutil/lib.py
+++ b/consutil/lib.py
@@ -10,6 +10,7 @@
import re
import subprocess
import sys
+ from swsssdk import ConfigDBConnector
except ImportError as e:
raise ImportError("%s - required module not found" % str(e))
| {"golden_diff": "diff --git a/consutil/lib.py b/consutil/lib.py\n--- a/consutil/lib.py\n+++ b/consutil/lib.py\n@@ -10,6 +10,7 @@\n import re\n import subprocess\n import sys\n+ from swsssdk import ConfigDBConnector\n except ImportError as e:\n raise ImportError(\"%s - required module not found\" % st... |
gh_patches_debug_247 | rasdani/github-patches | git_diff | pypa__cibuildwheel-1065 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[Docs] Example may accidentally be encouraging users to write invalid `pyproject.toml` files
### Description
Hi guys, first of all thank you for the amazing project (always good to remember).
While I wa... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -4,6 +4,7 @@
"docs": [
"mkdocs-include-markdown-plugin==2.8.0",
"mkdocs==1.0.4",
+ "jinja2==3.0.3",
"pymdown-extensions",
"mkdocs-macros-plugin",
],
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -4,6 +4,7 @@\n \"docs\": [\n \"mkdocs-include-markdown-plugin==2.8.0\",\n \"mkdocs==1.0.4\",\n+ \"jinja2==3.0.3\",\n \"pymdown-extensions\",\n \"mkdocs-macros-plugin\",\n ],\n", "issue": ... |
gh_patches_debug_248 | rasdani/github-patches | git_diff | cupy__cupy-6208 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Edge cases of compatibility in `numpy.eye()`
These are discovered when running hypothesis-based Array API tests. For now I am just documenting these discoveries. I do not know if they are something we'd like ... | diff --git a/cupy/_creation/basic.py b/cupy/_creation/basic.py
--- a/cupy/_creation/basic.py
+++ b/cupy/_creation/basic.py
@@ -110,7 +110,9 @@
"""
if M is None:
M = N
- ret = zeros((N, M), dtype, order=order)
+ ret = zeros((N, M), dtype=dtype, order=order)
+ if k <= -N or k >= M:
+ re... | {"golden_diff": "diff --git a/cupy/_creation/basic.py b/cupy/_creation/basic.py\n--- a/cupy/_creation/basic.py\n+++ b/cupy/_creation/basic.py\n@@ -110,7 +110,9 @@\n \"\"\"\n if M is None:\n M = N\n- ret = zeros((N, M), dtype, order=order)\n+ ret = zeros((N, M), dtype=dtype, order=order)\n+ if k... |
gh_patches_debug_249 | rasdani/github-patches | git_diff | inventree__InvenTree-1544 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[BUG] invoke: too many arguments
When running any invoke-command in an WSL-Enviroment I get the following error:
`/bin/bash: line 0: cd: too many arguments`
--- END ISSUE ---
Below are some code segments, ... | diff --git a/tasks.py b/tasks.py
--- a/tasks.py
+++ b/tasks.py
@@ -65,7 +65,7 @@
cmd - django command to run
"""
- c.run('cd {path} && python3 manage.py {cmd}'.format(
+ c.run('cd "{path}" && python3 manage.py {cmd}'.format(
path=managePyDir(),
cmd=cmd
), pty=pty)
| {"golden_diff": "diff --git a/tasks.py b/tasks.py\n--- a/tasks.py\n+++ b/tasks.py\n@@ -65,7 +65,7 @@\n cmd - django command to run\n \"\"\"\n \n- c.run('cd {path} && python3 manage.py {cmd}'.format(\n+ c.run('cd \"{path}\" && python3 manage.py {cmd}'.format(\n path=managePyDir(),\n cmd... |
gh_patches_debug_250 | rasdani/github-patches | git_diff | Pycord-Development__pycord-1381 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
`ScheduledEvent` object has not attribute `_image`
### Summary
Title explains it
### Reproduction Steps
i used jishaku `jsk py _ctx.guild.scheduled_events[0].cover`
### Minimal Reproducible Code
_No re... | diff --git a/discord/scheduled_events.py b/discord/scheduled_events.py
--- a/discord/scheduled_events.py
+++ b/discord/scheduled_events.py
@@ -255,7 +255,7 @@
return Asset._from_scheduled_event_cover(
self._state,
self.id,
- self._image,
+ self._cover,
)... | {"golden_diff": "diff --git a/discord/scheduled_events.py b/discord/scheduled_events.py\n--- a/discord/scheduled_events.py\n+++ b/discord/scheduled_events.py\n@@ -255,7 +255,7 @@\n return Asset._from_scheduled_event_cover(\n self._state,\n self.id,\n- self._image,\n+ ... |
gh_patches_debug_251 | rasdani/github-patches | git_diff | flask-admin__flask-admin-1408 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Leaflet JS Errors on examples.flask-admin.org
To reproduce, go here: http://examples.flask-admin.org/geo/admin/multipoint/edit/?url=%2Fgeo%2Fadmin%2Fmultipoint%2F&id=1
and click the "edit layers" icon (above... | diff --git a/examples/geo_alchemy/config.py b/examples/geo_alchemy/config.py
--- a/examples/geo_alchemy/config.py
+++ b/examples/geo_alchemy/config.py
@@ -7,4 +7,8 @@
# credentials for loading map tiles from mapbox
MAPBOX_MAP_ID = '...'
-MAPBOX_ACCESS_TOKEN = '...'
\ No newline at end of file
+MAPBOX_ACCESS_TOKEN =... | {"golden_diff": "diff --git a/examples/geo_alchemy/config.py b/examples/geo_alchemy/config.py\n--- a/examples/geo_alchemy/config.py\n+++ b/examples/geo_alchemy/config.py\n@@ -7,4 +7,8 @@\n \n # credentials for loading map tiles from mapbox\n MAPBOX_MAP_ID = '...'\n-MAPBOX_ACCESS_TOKEN = '...'\n\\ No newline at end of f... |
gh_patches_debug_252 | rasdani/github-patches | git_diff | feast-dev__feast-3280 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Minimal Python version on PyPI seems to be too low
## Expected Behavior
From what I can understand, the minimal version of Python to run Feast is 3.8; that's what I would expect on the PyPI page.
## Cu... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -43,7 +43,7 @@
DESCRIPTION = "Python SDK for Feast"
URL = "https://github.com/feast-dev/feast"
AUTHOR = "Feast"
-REQUIRES_PYTHON = ">=3.7.0"
+REQUIRES_PYTHON = ">=3.8.0"
REQUIRED = [
"click>=7.0.0,<9.0.0",
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -43,7 +43,7 @@\n DESCRIPTION = \"Python SDK for Feast\"\n URL = \"https://github.com/feast-dev/feast\"\n AUTHOR = \"Feast\"\n-REQUIRES_PYTHON = \">=3.7.0\"\n+REQUIRES_PYTHON = \">=3.8.0\"\n \n REQUIRED = [\n \"click>=7.0.0,<9.0.0\... |
gh_patches_debug_253 | rasdani/github-patches | git_diff | pytorch__TensorRT-376 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
🐛 [Bug] Memory leak in ConversionCtx::SerializeEngine()
## Bug Description
Using `trtorch::CompileGraph` many times will increase memory usage.
## To Reproduce
[Source code](https://github.com/SakodaSh... | diff --git a/py/trtorch/_compiler.py b/py/trtorch/_compiler.py
--- a/py/trtorch/_compiler.py
+++ b/py/trtorch/_compiler.py
@@ -157,5 +157,6 @@
build_info = "TRTorch Version: " + str(__version__) + '\n' + build_info
return build_info
+
def set_device(gpu_id):
trtorch._C.set_device(gpu_id)
| {"golden_diff": "diff --git a/py/trtorch/_compiler.py b/py/trtorch/_compiler.py\n--- a/py/trtorch/_compiler.py\n+++ b/py/trtorch/_compiler.py\n@@ -157,5 +157,6 @@\n build_info = \"TRTorch Version: \" + str(__version__) + '\\n' + build_info\n return build_info\n \n+\n def set_device(gpu_id):\n trtorch._C.set... |
gh_patches_debug_254 | rasdani/github-patches | git_diff | cookiecutter__cookiecutter-1562 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
prompt.read_user_dict() is broken due to click upgrade from 7.1.2 to 8.0.0
* Cookiecutter version: 1.7.3
* Template project url: -
* Python version: 3.9.5
* Operating System: macOS Catalina 10.15.7
### ... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -10,7 +10,7 @@
requirements = [
'binaryornot>=0.4.4',
'Jinja2>=2.7,<4.0.0',
- 'click>=7.0',
+ 'click>=7.0,<8.0.0',
'pyyaml>=5.3.1',
'jinja2-time>=0.2.0',
'python-slugify>=4.0.0',
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -10,7 +10,7 @@\n requirements = [\n 'binaryornot>=0.4.4',\n 'Jinja2>=2.7,<4.0.0',\n- 'click>=7.0',\n+ 'click>=7.0,<8.0.0',\n 'pyyaml>=5.3.1',\n 'jinja2-time>=0.2.0',\n 'python-slugify>=4.0.0',\n", "issue": "p... |
gh_patches_debug_255 | rasdani/github-patches | git_diff | OpenEnergyPlatform__oeplatform-605 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add OEO Steering Committee Subpage
The OEO Steering Committee needs its own web page, which should be a sub page of the OEP. Please create such a sub page @jh-RLI . I think it makes sense to link it somewhere... | diff --git a/ontology/urls.py b/ontology/urls.py
--- a/ontology/urls.py
+++ b/ontology/urls.py
@@ -7,4 +7,7 @@
urlpatterns = [
url(r"^$", TemplateView.as_view(template_name="ontology/about.html")),
+ url(r"^ontology/oeo-steering-committee$",
+ TemplateView.as_view(template_name="ontology/oeo-steering-... | {"golden_diff": "diff --git a/ontology/urls.py b/ontology/urls.py\n--- a/ontology/urls.py\n+++ b/ontology/urls.py\n@@ -7,4 +7,7 @@\n \n urlpatterns = [\n url(r\"^$\", TemplateView.as_view(template_name=\"ontology/about.html\")),\n+ url(r\"^ontology/oeo-steering-committee$\",\n+ TemplateView.as_view(templa... |
gh_patches_debug_256 | rasdani/github-patches | git_diff | cocotb__cocotb-797 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Use sphinxcontrib-trio to document coroutines
It looks like https://sphinxcontrib-trio.readthedocs.io/ could help autodoc'ing our coroutines nicer.
--- END ISSUE ---
Below are some code segments, each from... | diff --git a/documentation/source/conf.py b/documentation/source/conf.py
--- a/documentation/source/conf.py
+++ b/documentation/source/conf.py
@@ -41,6 +41,7 @@
'sphinx.ext.napoleon',
'sphinx.ext.intersphinx',
'cairosvgconverter',
+ 'sphinxcontrib_trio',
]
intersphinx_mapping = {'https://docs.... | {"golden_diff": "diff --git a/documentation/source/conf.py b/documentation/source/conf.py\n--- a/documentation/source/conf.py\n+++ b/documentation/source/conf.py\n@@ -41,6 +41,7 @@\n 'sphinx.ext.napoleon',\n 'sphinx.ext.intersphinx',\n 'cairosvgconverter',\n+ 'sphinxcontrib_trio',\n ]\n \n intersphin... |
gh_patches_debug_257 | rasdani/github-patches | git_diff | google__jax-1807 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
ImportError: ..... ____chkstk_darwin
Hi folks,
Wondering if someone can please help with this import error on a fresh install.
Background: Recently started a new conda environment with a couple of basics... | diff --git a/build/build.py b/build/build.py
--- a/build/build.py
+++ b/build/build.py
@@ -176,6 +176,7 @@
# Sets the default Apple platform to macOS.
build --apple_platform_type=macos
+build --macos_minimum_os=10.9
# Make Bazel print out all options from rc files.
build --announce_rc
| {"golden_diff": "diff --git a/build/build.py b/build/build.py\n--- a/build/build.py\n+++ b/build/build.py\n@@ -176,6 +176,7 @@\n \n # Sets the default Apple platform to macOS.\n build --apple_platform_type=macos\n+build --macos_minimum_os=10.9\n \n # Make Bazel print out all options from rc files.\n build --announce_rc... |
gh_patches_debug_258 | rasdani/github-patches | git_diff | cltk__cltk-575 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Double-check code and data for new French PR
This issue is for @nat1881 to follow up on her large PR #571 for Old and Middle French.
Natasha, I would like you to do the following steps, to be certain that ... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -36,7 +36,7 @@
name='cltk',
packages=find_packages(),
url='https://github.com/cltk/cltk',
- version='0.1.63',
+ version='0.1.64',
zip_safe=True,
test_suite='cltk.tests.test_cltk',
)
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -36,7 +36,7 @@\n name='cltk',\n packages=find_packages(),\n url='https://github.com/cltk/cltk',\n- version='0.1.63',\n+ version='0.1.64',\n zip_safe=True,\n test_suite='cltk.tests.test_cltk',\n )\n", "issue":... |
gh_patches_debug_259 | rasdani/github-patches | git_diff | sopel-irc__sopel-949 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Problem in (at least) Wikipedia module: possibly Unicode related
Hi,
observe the following use case:
https://en.wikipedia.org/wiki/Hir%C5%8D_Onoda
@willie_5.4.1 KeyError: u'extract' (file "/usr/local/... | diff --git a/sopel/modules/wikipedia.py b/sopel/modules/wikipedia.py
--- a/sopel/modules/wikipedia.py
+++ b/sopel/modules/wikipedia.py
@@ -15,7 +15,8 @@
import sys
if sys.version_info.major < 3:
- from urlparse import unquote
+ from urlparse import unquote as _unquote
+ unquote = lambda s: _unquote(s.encod... | {"golden_diff": "diff --git a/sopel/modules/wikipedia.py b/sopel/modules/wikipedia.py\n--- a/sopel/modules/wikipedia.py\n+++ b/sopel/modules/wikipedia.py\n@@ -15,7 +15,8 @@\n \n import sys\n if sys.version_info.major < 3:\n- from urlparse import unquote\n+ from urlparse import unquote as _unquote\n+ unquote = ... |
gh_patches_debug_260 | rasdani/github-patches | git_diff | scrapy__scrapy-5754 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Silence the `filelock` logger
After we started using `tldextract` we sometimes get log messages from `filelock` with the DEBUG level, it makes sense to silence them like we do for some other libraries in http... | diff --git a/scrapy/utils/log.py b/scrapy/utils/log.py
--- a/scrapy/utils/log.py
+++ b/scrapy/utils/log.py
@@ -46,6 +46,9 @@
'version': 1,
'disable_existing_loggers': False,
'loggers': {
+ 'filelock': {
+ 'level': 'ERROR',
+ },
'hpack': {
'level': 'ERROR',
... | {"golden_diff": "diff --git a/scrapy/utils/log.py b/scrapy/utils/log.py\n--- a/scrapy/utils/log.py\n+++ b/scrapy/utils/log.py\n@@ -46,6 +46,9 @@\n 'version': 1,\n 'disable_existing_loggers': False,\n 'loggers': {\n+ 'filelock': {\n+ 'level': 'ERROR',\n+ },\n 'hpack': {\n ... |
gh_patches_debug_261 | rasdani/github-patches | git_diff | sopel-irc__sopel-493 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[chanlogs] Missing copyright header
@singingwolfboy could you add the copyright header to comply with the [EFL](https://github.com/embolalia/willie/blob/master/COPYING)? Below is the required lay-out:
```
# ... | diff --git a/willie/modules/chanlogs.py b/willie/modules/chanlogs.py
--- a/willie/modules/chanlogs.py
+++ b/willie/modules/chanlogs.py
@@ -1,6 +1,11 @@
-#coding: utf8
+# coding=utf-8
"""
-Channel logger
+chanlogs.py - Willie Channel Logger module
+Copyright 2014, David Baumgold <david@davidbaumgold.com>
+
+Licensed un... | {"golden_diff": "diff --git a/willie/modules/chanlogs.py b/willie/modules/chanlogs.py\n--- a/willie/modules/chanlogs.py\n+++ b/willie/modules/chanlogs.py\n@@ -1,6 +1,11 @@\n-#coding: utf8\n+# coding=utf-8\n \"\"\"\n-Channel logger\n+chanlogs.py - Willie Channel Logger module\n+Copyright 2014, David Baumgold <david@davi... |
gh_patches_debug_262 | rasdani/github-patches | git_diff | pypi__warehouse-1454 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[WIP] Show Author and Maintainer in Project detail view
Refs #1060
@dstufft I need some input regarding the implementation of email validation. How do you want to have this implemented? Should I use a self ... | diff --git a/warehouse/packaging/models.py b/warehouse/packaging/models.py
--- a/warehouse/packaging/models.py
+++ b/warehouse/packaging/models.py
@@ -342,7 +342,9 @@
@property
def has_meta(self):
- return any([self.keywords])
+ return any([self.keywords,
+ self.author, self... | {"golden_diff": "diff --git a/warehouse/packaging/models.py b/warehouse/packaging/models.py\n--- a/warehouse/packaging/models.py\n+++ b/warehouse/packaging/models.py\n@@ -342,7 +342,9 @@\n \n @property\n def has_meta(self):\n- return any([self.keywords])\n+ return any([self.keywords,\n+ ... |
gh_patches_debug_263 | rasdani/github-patches | git_diff | ivy-llc__ivy-17901 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
fmin
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `ivy/functional/frontends/paddle/tensor/math.py`
Conte... | diff --git a/ivy/functional/frontends/paddle/tensor/math.py b/ivy/functional/frontends/paddle/tensor/math.py
--- a/ivy/functional/frontends/paddle/tensor/math.py
+++ b/ivy/functional/frontends/paddle/tensor/math.py
@@ -232,3 +232,9 @@
@to_ivy_arrays_and_back
def reciprocal(x, name=None):
return ivy.reciprocal(x)... | {"golden_diff": "diff --git a/ivy/functional/frontends/paddle/tensor/math.py b/ivy/functional/frontends/paddle/tensor/math.py\n--- a/ivy/functional/frontends/paddle/tensor/math.py\n+++ b/ivy/functional/frontends/paddle/tensor/math.py\n@@ -232,3 +232,9 @@\n @to_ivy_arrays_and_back\n def reciprocal(x, name=None):\n r... |
gh_patches_debug_264 | rasdani/github-patches | git_diff | celery__celery-6866 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Celery inspect output JSON serialization is broken
# Checklist
- [ ] I have verified that the issue exists against the `master` branch of Celery.
- [ ] This has already been asked to the [discussion group](... | diff --git a/celery/bin/control.py b/celery/bin/control.py
--- a/celery/bin/control.py
+++ b/celery/bin/control.py
@@ -144,6 +144,8 @@
if json:
ctx.obj.echo(dumps(replies))
+ return
+
nodecount = len(replies)
if not ctx.obj.quiet:
ctx.obj.echo('\n{} {} online.'.format(
| {"golden_diff": "diff --git a/celery/bin/control.py b/celery/bin/control.py\n--- a/celery/bin/control.py\n+++ b/celery/bin/control.py\n@@ -144,6 +144,8 @@\n \n if json:\n ctx.obj.echo(dumps(replies))\n+ return\n+\n nodecount = len(replies)\n if not ctx.obj.quiet:\n ctx.obj.echo('\\n{}... |
gh_patches_debug_265 | rasdani/github-patches | git_diff | secdev__scapy-1402 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
man page spelling error
intances should be instances.
It would be nice if this wasn't gz compressed in the source, otherwise I'd have done a pull request.
--- END ISSUE ---
Below are some code segments, ... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -63,7 +63,7 @@
'scapy/tools',
],
scripts=SCRIPTS,
- data_files=[('share/man/man1', ["doc/scapy.1.gz"])],
+ data_files=[('share/man/man1', ["doc/scapy.1"])],
package_data={
'scapy': ['VERSION'],
},
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -63,7 +63,7 @@\n 'scapy/tools',\n ],\n scripts=SCRIPTS,\n- data_files=[('share/man/man1', [\"doc/scapy.1.gz\"])],\n+ data_files=[('share/man/man1', [\"doc/scapy.1\"])],\n package_data={\n 'scapy': ['V... |
gh_patches_debug_266 | rasdani/github-patches | git_diff | evennia__evennia-2900 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[BUG - Develop] Log rotation infinite-loops
#### Describe the bug
My log file reached the maximum size and when trying to rotate, it hits an infinite loop.
https://github.com/evennia/evennia/blob/3992f37d... | diff --git a/evennia/utils/logger.py b/evennia/utils/logger.py
--- a/evennia/utils/logger.py
+++ b/evennia/utils/logger.py
@@ -351,7 +351,7 @@
def rotate(self):
try:
- self.rotate()
+ super().rotate()
except Exception:
log_trace(f"Could not rotate the log file... | {"golden_diff": "diff --git a/evennia/utils/logger.py b/evennia/utils/logger.py\n--- a/evennia/utils/logger.py\n+++ b/evennia/utils/logger.py\n@@ -351,7 +351,7 @@\n \n def rotate(self):\n try:\n- self.rotate()\n+ super().rotate()\n except Exception:\n log_trace(f\"C... |
gh_patches_debug_267 | rasdani/github-patches | git_diff | opsdroid__opsdroid-169 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
arrow dep missing
Fresh install of ubuntu 16.04
```
$ sudo apt update && sudo apt install python3-pip
...
$ pip3 install opsdroid
...
$ opsdroid
Traceback (most recent call last):
File "/home/ubun... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -10,9 +10,10 @@
'modules.*', 'docs', 'docs.*'])
REQUIRES = [
- 'pyyaml>=3.11,<4',
- 'aiohttp>=1.2.0,<2',
- 'pycron>=0.40',
+ 'arrow==0.10.0',
+ 'aiohttp==2.1.0',
+ 'pycron==0.40',
+ 'pyyaml==3.12... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -10,9 +10,10 @@\n 'modules.*', 'docs', 'docs.*'])\n \n REQUIRES = [\n- 'pyyaml>=3.11,<4',\n- 'aiohttp>=1.2.0,<2',\n- 'pycron>=0.40',\n+ 'arrow==0.10.0',\n+ 'aiohttp==2.1.0',\n+ 'pycr... |
gh_patches_debug_268 | rasdani/github-patches | git_diff | nltk__nltk-1219 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Translation metrics in Python 2.7
The [CI Server](https://nltk.ci.cloudbees.com/job/nltk/TOXENV=py27-jenkins,jdk=jdk8latestOnlineInstall/lastCompletedBuild/testReport/) reports test failures for `nltk.transl... | diff --git a/nltk/translate/ribes_score.py b/nltk/translate/ribes_score.py
--- a/nltk/translate/ribes_score.py
+++ b/nltk/translate/ribes_score.py
@@ -6,7 +6,7 @@
# URL: <http://nltk.org/>
# For license information, see LICENSE.TXT
""" RIBES score implementation """
-
+from __future__ import division
from itertools... | {"golden_diff": "diff --git a/nltk/translate/ribes_score.py b/nltk/translate/ribes_score.py\n--- a/nltk/translate/ribes_score.py\n+++ b/nltk/translate/ribes_score.py\n@@ -6,7 +6,7 @@\n # URL: <http://nltk.org/>\n # For license information, see LICENSE.TXT\n \"\"\" RIBES score implementation \"\"\"\n-\n+from __future__ ... |
gh_patches_debug_269 | rasdani/github-patches | git_diff | jupyterhub__zero-to-jupyterhub-k8s-373 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
build.py corrupts yaml
## Description
I ran into an issue with entries in values.yaml file after using the build.py script. My `extraVolume` entries were corrupted.
## Reproduction
```yaml
# create th... | diff --git a/build.py b/build.py
--- a/build.py
+++ b/build.py
@@ -9,7 +9,7 @@
# use safe roundtrip yaml loader
yaml = YAML(typ='rt')
-yaml.indent(offset=2)
+yaml.indent(mapping=2, offset=2, sequence=4)
def last_modified_commit(*paths, **kwargs):
return subprocess.check_output([
| {"golden_diff": "diff --git a/build.py b/build.py\n--- a/build.py\n+++ b/build.py\n@@ -9,7 +9,7 @@\n \n # use safe roundtrip yaml loader\n yaml = YAML(typ='rt')\n-yaml.indent(offset=2)\n+yaml.indent(mapping=2, offset=2, sequence=4)\n \n def last_modified_commit(*paths, **kwargs):\n return subprocess.check_output([\... |
gh_patches_debug_270 | rasdani/github-patches | git_diff | arviz-devs__arviz-1403 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Error plotting a single variable with plot_density and bokeh backend
**Describe the bug**
Over in ArviZ.jl, we use the Julia equivalent to the below snippet to test Bokeh integration for `plot_density`. It w... | diff --git a/arviz/plots/backends/bokeh/densityplot.py b/arviz/plots/backends/bokeh/densityplot.py
--- a/arviz/plots/backends/bokeh/densityplot.py
+++ b/arviz/plots/backends/bokeh/densityplot.py
@@ -63,7 +63,7 @@
rows,
cols,
figsize=figsize,
- squeeze=True,
+ ... | {"golden_diff": "diff --git a/arviz/plots/backends/bokeh/densityplot.py b/arviz/plots/backends/bokeh/densityplot.py\n--- a/arviz/plots/backends/bokeh/densityplot.py\n+++ b/arviz/plots/backends/bokeh/densityplot.py\n@@ -63,7 +63,7 @@\n rows,\n cols,\n figsize=figsize,\n- sq... |
gh_patches_debug_271 | rasdani/github-patches | git_diff | pytorch__ignite-773 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
progress bar output seems to be off
Soi I am using the Progressbar from the contrib module for indicating progress in the training loop. Currently the batch size is 1 for an exemplary dataset of 16 samples.
... | diff --git a/ignite/contrib/handlers/tqdm_logger.py b/ignite/contrib/handlers/tqdm_logger.py
--- a/ignite/contrib/handlers/tqdm_logger.py
+++ b/ignite/contrib/handlers/tqdm_logger.py
@@ -119,6 +119,7 @@
total=pbar_total,
leave=self.persist,
bar_format=self.bar_format,
+ ... | {"golden_diff": "diff --git a/ignite/contrib/handlers/tqdm_logger.py b/ignite/contrib/handlers/tqdm_logger.py\n--- a/ignite/contrib/handlers/tqdm_logger.py\n+++ b/ignite/contrib/handlers/tqdm_logger.py\n@@ -119,6 +119,7 @@\n total=pbar_total,\n leave=self.persist,\n bar_format=self.b... |
gh_patches_debug_272 | rasdani/github-patches | git_diff | scikit-hep__pyhf-1283 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Change question asking queue to focus on GitHub Discussions over Stack Overflow
# Description
We currently direct users with application questions to the `pyhf` Stack Overflow tag, but should start directi... | diff --git a/docs/conf.py b/docs/conf.py
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -77,7 +77,7 @@
'uproot': ('https://uproot.readthedocs.io/en/latest/', None),
}
-# Github repo
+# GitHub repo
issues_github_path = 'scikit-hep/pyhf'
# Generate the API documentation when building
| {"golden_diff": "diff --git a/docs/conf.py b/docs/conf.py\n--- a/docs/conf.py\n+++ b/docs/conf.py\n@@ -77,7 +77,7 @@\n 'uproot': ('https://uproot.readthedocs.io/en/latest/', None),\n }\n \n-# Github repo\n+# GitHub repo\n issues_github_path = 'scikit-hep/pyhf'\n \n # Generate the API documentation when building\n",... |
gh_patches_debug_273 | rasdani/github-patches | git_diff | huggingface__trl-154 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Error with official examples
Hi, I am running the official example script on t5 using sentiment as reward function, and after 97 iterations the following error is raised:
```
╭───────────────────── Traceb... | diff --git a/trl/trainer/ppo_trainer.py b/trl/trainer/ppo_trainer.py
--- a/trl/trainer/ppo_trainer.py
+++ b/trl/trainer/ppo_trainer.py
@@ -309,6 +309,7 @@
batch_size=self.config.batch_size,
collate_fn=data_collator,
shuffle=True,
+ drop_last=True,
)
re... | {"golden_diff": "diff --git a/trl/trainer/ppo_trainer.py b/trl/trainer/ppo_trainer.py\n--- a/trl/trainer/ppo_trainer.py\n+++ b/trl/trainer/ppo_trainer.py\n@@ -309,6 +309,7 @@\n batch_size=self.config.batch_size,\n collate_fn=data_collator,\n shuffle=True,\n+ drop_last=True... |
gh_patches_debug_274 | rasdani/github-patches | git_diff | google__flax-270 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
`typing._ClassVar` cannot be accessed in the iPython shell – dataclasses package seems to mess up on Python 3.7
### Problem you have encountered:
I just installed flax and tried to import it from the iPyth... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -30,7 +30,7 @@
"numpy>=1.12",
"jax>=0.1.59",
"matplotlib", # only needed for tensorboard export
- "dataclasses", # will only install on py3.6
+ "dataclasses;python_version<'3.7'", # will only install on py3.6
"msgpack",
]
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -30,7 +30,7 @@\n \"numpy>=1.12\",\n \"jax>=0.1.59\",\n \"matplotlib\", # only needed for tensorboard export\n- \"dataclasses\", # will only install on py3.6\n+ \"dataclasses;python_version<'3.7'\", # will only inst... |
gh_patches_debug_275 | rasdani/github-patches | git_diff | fossasia__open-event-server-2599 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Import not working on Kubernetes deployment
The file upload for import is not working on Kubernetes deployment. (but works locally and on heroku)
--- END ISSUE ---
Below are some code segments, each fro... | diff --git a/app/helpers/storage.py b/app/helpers/storage.py
--- a/app/helpers/storage.py
+++ b/app/helpers/storage.py
@@ -199,7 +199,7 @@
k.set_acl(acl)
gs_url = 'https://storage.googleapis.com/%s/' % bucket_name
if sent == size:
- return gs_url + key
+ return gs_url + k.key
return Fa... | {"golden_diff": "diff --git a/app/helpers/storage.py b/app/helpers/storage.py\n--- a/app/helpers/storage.py\n+++ b/app/helpers/storage.py\n@@ -199,7 +199,7 @@\n k.set_acl(acl)\n gs_url = 'https://storage.googleapis.com/%s/' % bucket_name\n if sent == size:\n- return gs_url + key\n+ return gs_u... |
gh_patches_debug_276 | rasdani/github-patches | git_diff | kivy__python-for-android-615 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
OpenSSL 1.0.2e outdated (replaced by 1.0.2f)
A new version has been published today. The recipe no longer can download version 1.0.2e.
Does `disable-solver.patch` still apply?
--- END ISSUE ---
Below are ... | diff --git a/pythonforandroid/recipes/openssl/__init__.py b/pythonforandroid/recipes/openssl/__init__.py
--- a/pythonforandroid/recipes/openssl/__init__.py
+++ b/pythonforandroid/recipes/openssl/__init__.py
@@ -5,7 +5,7 @@
class OpenSSLRecipe(Recipe):
- version = '1.0.2e'
+ version = '1.0.2f'
url = 'htt... | {"golden_diff": "diff --git a/pythonforandroid/recipes/openssl/__init__.py b/pythonforandroid/recipes/openssl/__init__.py\n--- a/pythonforandroid/recipes/openssl/__init__.py\n+++ b/pythonforandroid/recipes/openssl/__init__.py\n@@ -5,7 +5,7 @@\n \n \n class OpenSSLRecipe(Recipe):\n- version = '1.0.2e'\n+ version =... |
gh_patches_debug_277 | rasdani/github-patches | git_diff | chainer__chainer-5463 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
CaffeFunction ignores pad_w from Convolution
# Problem description
Trying to import inception from [Caffe model](https://github.com/soeaver/caffe-model/tree/master/cls) fails.
1. download and unzip file... | diff --git a/chainer/links/caffe/caffe_function.py b/chainer/links/caffe/caffe_function.py
--- a/chainer/links/caffe/caffe_function.py
+++ b/chainer/links/caffe/caffe_function.py
@@ -547,7 +547,7 @@
def _get_pad(param):
- if param.pad_h > 0:
+ if param.pad_h > 0 or param.pad_w > 0:
return param.pad_... | {"golden_diff": "diff --git a/chainer/links/caffe/caffe_function.py b/chainer/links/caffe/caffe_function.py\n--- a/chainer/links/caffe/caffe_function.py\n+++ b/chainer/links/caffe/caffe_function.py\n@@ -547,7 +547,7 @@\n \n \n def _get_pad(param):\n- if param.pad_h > 0:\n+ if param.pad_h > 0 or param.pad_w > 0:\n... |
gh_patches_debug_278 | rasdani/github-patches | git_diff | kivy__kivy-5627 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
No module named kivy.setupconfig
Hi,
When installing Kivy 1.9.1 as a dependency of one of my packages I get the error
`ImportError: No module named 'kivy.setupconfig`.
My setup.py file looks like this and i... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -1019,6 +1019,7 @@
],
package_dir={'kivy': 'kivy'},
package_data={'kivy': [
+ 'setupconfig.py'
'*.pxd',
'*.pxi',
'core/text/*.pxd',
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -1019,6 +1019,7 @@\n ],\n package_dir={'kivy': 'kivy'},\n package_data={'kivy': [\n+ 'setupconfig.py'\n '*.pxd',\n '*.pxi',\n 'core/text/*.pxd',\n", "issue": "No m... |
gh_patches_debug_279 | rasdani/github-patches | git_diff | DDMAL__CantusDB-1043 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Admin Area: Hide "Volpiano notes" and "Volpiano interval" fields
We currently display these fields in the admin area, but they are only for internal use. Instead, we should hide these fields (i.e., exclude, i... | diff --git a/django/cantusdb_project/main_app/admin.py b/django/cantusdb_project/main_app/admin.py
--- a/django/cantusdb_project/main_app/admin.py
+++ b/django/cantusdb_project/main_app/admin.py
@@ -76,6 +76,8 @@
"is_last_chant_in_feast",
"visible_status",
"date",
+ "volpiano_notes",
+... | {"golden_diff": "diff --git a/django/cantusdb_project/main_app/admin.py b/django/cantusdb_project/main_app/admin.py\n--- a/django/cantusdb_project/main_app/admin.py\n+++ b/django/cantusdb_project/main_app/admin.py\n@@ -76,6 +76,8 @@\n \"is_last_chant_in_feast\",\n \"visible_status\",\n \"date\",... |
gh_patches_debug_280 | rasdani/github-patches | git_diff | streamlit__streamlit-7257 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Changing start_time of st.video() doesn't work for the same video
### Checklist
- [X] I have searched the [existing issues](https://github.com/streamlit/streamlit/issues) for similar issues.
- [X] I added... | diff --git a/e2e/scripts/st_video.py b/e2e/scripts/st_video.py
--- a/e2e/scripts/st_video.py
+++ b/e2e/scripts/st_video.py
@@ -19,3 +19,7 @@
url = "https://www.w3schools.com/html/mov_bbb.mp4"
file = requests.get(url).content
st.video(file)
+
+# Test start time with widget
+timestamp = st.number_input("Start Time (in... | {"golden_diff": "diff --git a/e2e/scripts/st_video.py b/e2e/scripts/st_video.py\n--- a/e2e/scripts/st_video.py\n+++ b/e2e/scripts/st_video.py\n@@ -19,3 +19,7 @@\n url = \"https://www.w3schools.com/html/mov_bbb.mp4\"\n file = requests.get(url).content\n st.video(file)\n+\n+# Test start time with widget\n+timestamp = st.... |
gh_patches_debug_281 | rasdani/github-patches | git_diff | aio-libs__aiohttp-7245 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Websocket client send wrong Connection header
### Describe the bug
In websocket standard , the `Connection` header shoule be `Upgrade`, but we send a `upgrade` .
It's a lowercase word.
### To Reproduce
c... | diff --git a/aiohttp/client.py b/aiohttp/client.py
--- a/aiohttp/client.py
+++ b/aiohttp/client.py
@@ -772,7 +772,7 @@
default_headers = {
hdrs.UPGRADE: "websocket",
- hdrs.CONNECTION: "upgrade",
+ hdrs.CONNECTION: "Upgrade",
hdrs.SEC_WEBSOCKET_VERSION: "13",
... | {"golden_diff": "diff --git a/aiohttp/client.py b/aiohttp/client.py\n--- a/aiohttp/client.py\n+++ b/aiohttp/client.py\n@@ -772,7 +772,7 @@\n \n default_headers = {\n hdrs.UPGRADE: \"websocket\",\n- hdrs.CONNECTION: \"upgrade\",\n+ hdrs.CONNECTION: \"Upgrade\",\n hdr... |
gh_patches_debug_282 | rasdani/github-patches | git_diff | python__mypy-11823 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Regression in mypy 0.930: Cannot override writable attribute "__module__" with a final one
**Bug Report**
The following code is reported as error by mypy 0.930 (Python 3.8). It seems correct, and was consi... | diff --git a/mypy/semanal_enum.py b/mypy/semanal_enum.py
--- a/mypy/semanal_enum.py
+++ b/mypy/semanal_enum.py
@@ -21,6 +21,8 @@
))
ENUM_SPECIAL_PROPS: Final = frozenset((
'name', 'value', '_name_', '_value_', '_order_', '__order__',
+ # Also attributes from `object`:
+ '__module__', '__annotations__', '__... | {"golden_diff": "diff --git a/mypy/semanal_enum.py b/mypy/semanal_enum.py\n--- a/mypy/semanal_enum.py\n+++ b/mypy/semanal_enum.py\n@@ -21,6 +21,8 @@\n ))\n ENUM_SPECIAL_PROPS: Final = frozenset((\n 'name', 'value', '_name_', '_value_', '_order_', '__order__',\n+ # Also attributes from `object`:\n+ '__module__... |
gh_patches_debug_283 | rasdani/github-patches | git_diff | psf__black-3276 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Bump pypa/cibuildwheel from 2.8.1 to 2.9.0
Bumps [pypa/cibuildwheel](https://github.com/pypa/cibuildwheel) from 2.8.1 to 2.9.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://... | diff --git a/src/black/files.py b/src/black/files.py
--- a/src/black/files.py
+++ b/src/black/files.py
@@ -26,7 +26,8 @@
import tomllib
except ImportError:
# Help users on older alphas
- import tomli as tomllib
+ if not TYPE_CHECKING:
+ import tomli as tomllib
else:
... | {"golden_diff": "diff --git a/src/black/files.py b/src/black/files.py\n--- a/src/black/files.py\n+++ b/src/black/files.py\n@@ -26,7 +26,8 @@\n import tomllib\n except ImportError:\n # Help users on older alphas\n- import tomli as tomllib\n+ if not TYPE_CHECKING:\n+ import to... |
gh_patches_debug_284 | rasdani/github-patches | git_diff | gratipay__gratipay.com-1975 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
/about/stats.json is broken
[stats.json](https://www.gittip.com/about/stats.json) is broken, I guess because of commit https://github.com/gittip/www.gittip.com/commit/892b1c28d127a18858032c88bd3d065cae973c34 ... | diff --git a/configure-aspen.py b/configure-aspen.py
--- a/configure-aspen.py
+++ b/configure-aspen.py
@@ -26,7 +26,6 @@
website.renderer_default = "jinja2"
-website.default_renderers_by_media_type['application/json'] = 'stdlib_format'
website.renderer_factories['jinja2'].Renderer.global_context = {
'range... | {"golden_diff": "diff --git a/configure-aspen.py b/configure-aspen.py\n--- a/configure-aspen.py\n+++ b/configure-aspen.py\n@@ -26,7 +26,6 @@\n \n \n website.renderer_default = \"jinja2\"\n-website.default_renderers_by_media_type['application/json'] = 'stdlib_format'\n \n website.renderer_factories['jinja2'].Renderer.gl... |
gh_patches_debug_285 | rasdani/github-patches | git_diff | kivy__kivy-5951 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
enchant - ImportError: No module named 'enchant'
<!--
The issue tracker is a tool to address bugs.
Please use the #kivy IRC channel on freenode or Stack Overflow for
support questions, more information at ... | diff --git a/kivy/core/spelling/spelling_enchant.py b/kivy/core/spelling/spelling_enchant.py
--- a/kivy/core/spelling/spelling_enchant.py
+++ b/kivy/core/spelling/spelling_enchant.py
@@ -1,5 +1,11 @@
'''
-Enchant Spelling: Implements spelling backend based on enchant.
+Enchant Spelling
+================
+
+Implementat... | {"golden_diff": "diff --git a/kivy/core/spelling/spelling_enchant.py b/kivy/core/spelling/spelling_enchant.py\n--- a/kivy/core/spelling/spelling_enchant.py\n+++ b/kivy/core/spelling/spelling_enchant.py\n@@ -1,5 +1,11 @@\n '''\n-Enchant Spelling: Implements spelling backend based on enchant.\n+Enchant Spelling\n+=======... |
gh_patches_debug_286 | rasdani/github-patches | git_diff | Cloud-CV__EvalAI-697 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Set default renderer to JSONRenderer in DRF backend
For reference: http://www.django-rest-framework.org/api-guide/renderers/#setting-the-renderers
--- END ISSUE ---
Below are some code segments, each from a... | diff --git a/settings/common.py b/settings/common.py
--- a/settings/common.py
+++ b/settings/common.py
@@ -163,7 +163,10 @@
'DEFAULT_THROTTLE_RATES': {
'anon': '100/minute',
'user': '100/minute'
- }
+ },
+ 'DEFAULT_RENDERER_CLASSES': (
+ 'rest_framework.renderers.JSONRenderer',
+ ... | {"golden_diff": "diff --git a/settings/common.py b/settings/common.py\n--- a/settings/common.py\n+++ b/settings/common.py\n@@ -163,7 +163,10 @@\n 'DEFAULT_THROTTLE_RATES': {\n 'anon': '100/minute',\n 'user': '100/minute'\n- }\n+ },\n+ 'DEFAULT_RENDERER_CLASSES': (\n+ 'rest_framework.... |
gh_patches_debug_287 | rasdani/github-patches | git_diff | deis__deis-2001 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
underscores in app names cause logger to fail
I setup a new cluster from master. I tried stop and start but I still see the logger going into the "failed" state.
$ fleetctl journal deis-logger
-- Logs begi... | diff --git a/controller/scheduler/coreos.py b/controller/scheduler/coreos.py
--- a/controller/scheduler/coreos.py
+++ b/controller/scheduler/coreos.py
@@ -11,7 +11,7 @@
MATCH = re.compile(
- '(?P<app>[a-z0-9-]+)_?(?P<version>v[0-9]+)?\.?(?P<c_type>[a-z]+)?.(?P<c_num>[0-9]+)')
+ '(?P<app>[a-z0-9-]+)_?(?P<vers... | {"golden_diff": "diff --git a/controller/scheduler/coreos.py b/controller/scheduler/coreos.py\n--- a/controller/scheduler/coreos.py\n+++ b/controller/scheduler/coreos.py\n@@ -11,7 +11,7 @@\n \n \n MATCH = re.compile(\n- '(?P<app>[a-z0-9-]+)_?(?P<version>v[0-9]+)?\\.?(?P<c_type>[a-z]+)?.(?P<c_num>[0-9]+)')\n+ '(?P... |
gh_patches_debug_288 | rasdani/github-patches | git_diff | getredash__redash-3877 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
API Key authentication should take precedence over cookies
Currently when you're logged in as a user, you can't use embeds or shared dashboards for which you do not have access -- even if you provide the API ... | diff --git a/redash/authentication/__init__.py b/redash/authentication/__init__.py
--- a/redash/authentication/__init__.py
+++ b/redash/authentication/__init__.py
@@ -41,6 +41,10 @@
@login_manager.user_loader
def load_user(user_id_with_identity):
+ user = api_key_load_user_from_request(request)
+ if user:
+ ... | {"golden_diff": "diff --git a/redash/authentication/__init__.py b/redash/authentication/__init__.py\n--- a/redash/authentication/__init__.py\n+++ b/redash/authentication/__init__.py\n@@ -41,6 +41,10 @@\n \n @login_manager.user_loader\n def load_user(user_id_with_identity):\n+ user = api_key_load_user_from_request(re... |
gh_patches_debug_289 | rasdani/github-patches | git_diff | readthedocs__readthedocs.org-5470 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Build List Screen Performance Issue
While working on #5464, I discovered a performance issue on the [build list screen](http://readthedocs.org/projects/requests/builds/).
There appears to be a couple dupli... | diff --git a/readthedocs/builds/views.py b/readthedocs/builds/views.py
--- a/readthedocs/builds/views.py
+++ b/readthedocs/builds/views.py
@@ -41,7 +41,7 @@
queryset = Build.objects.public(
user=self.request.user,
project=self.project,
- )
+ ).select_related('project', '... | {"golden_diff": "diff --git a/readthedocs/builds/views.py b/readthedocs/builds/views.py\n--- a/readthedocs/builds/views.py\n+++ b/readthedocs/builds/views.py\n@@ -41,7 +41,7 @@\n queryset = Build.objects.public(\n user=self.request.user,\n project=self.project,\n- )\n+ ).se... |
gh_patches_debug_290 | rasdani/github-patches | git_diff | redis__redis-py-2254 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
v4.3.3 continues to contain backwards incompatible change to ``redis.lock.Lock``
Hey this is a continuation of #2209.
The API change made in https://github.com/redis/redis-py/pull/2210/files does not resto... | diff --git a/redis/lock.py b/redis/lock.py
--- a/redis/lock.py
+++ b/redis/lock.py
@@ -169,7 +169,6 @@
def acquire(
self,
- *,
sleep: Optional[Number] = None,
blocking: Optional[bool] = None,
blocking_timeout: Optional[Number] = None,
| {"golden_diff": "diff --git a/redis/lock.py b/redis/lock.py\n--- a/redis/lock.py\n+++ b/redis/lock.py\n@@ -169,7 +169,6 @@\n \n def acquire(\n self,\n- *,\n sleep: Optional[Number] = None,\n blocking: Optional[bool] = None,\n blocking_timeout: Optional[Number] = None,\n", "iss... |
gh_patches_debug_291 | rasdani/github-patches | git_diff | buildbot__buildbot-1214 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
New web plugin idea: a health indicator
This ticket is a migrated Trac ticket [2966](http://trac.buildbot.net/ticket/2966)
People contributed to the original ticket: `benoit.allard@...`, @tardyp, @rutsky, @u... | diff --git a/pkg/setup.py b/pkg/setup.py
--- a/pkg/setup.py
+++ b/pkg/setup.py
@@ -19,7 +19,7 @@
import buildbot_pkg
setup(
- name='buildbot_pkg',
+ name='buildbot-pkg',
version=buildbot_pkg.getVersion("."),
description='Buildbot packaging tools',
author=u'Pierre Tardy',
| {"golden_diff": "diff --git a/pkg/setup.py b/pkg/setup.py\n--- a/pkg/setup.py\n+++ b/pkg/setup.py\n@@ -19,7 +19,7 @@\n import buildbot_pkg\n \n setup(\n- name='buildbot_pkg',\n+ name='buildbot-pkg',\n version=buildbot_pkg.getVersion(\".\"),\n description='Buildbot packaging tools',\n author=u'Pierre T... |
gh_patches_debug_292 | rasdani/github-patches | git_diff | DistrictDataLabs__yellowbrick-904 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Overhaul unittest and fixtures
Remove dependency on `unittest.TestCase` by replacing assertions with `assert` statements. This also involves using `pytest.raises` and `pytest.skip` decorators.
Use PyTest ... | diff --git a/yellowbrick/features/rfecv.py b/yellowbrick/features/rfecv.py
--- a/yellowbrick/features/rfecv.py
+++ b/yellowbrick/features/rfecv.py
@@ -171,7 +171,7 @@
else:
step = int(self.step)
- if step < 0:
+ if step <= 0:
raise YellowbrickValueError("step must be >... | {"golden_diff": "diff --git a/yellowbrick/features/rfecv.py b/yellowbrick/features/rfecv.py\n--- a/yellowbrick/features/rfecv.py\n+++ b/yellowbrick/features/rfecv.py\n@@ -171,7 +171,7 @@\n else:\n step = int(self.step)\n \n- if step < 0:\n+ if step <= 0:\n raise Yellowbrick... |
gh_patches_debug_293 | rasdani/github-patches | git_diff | OpenNMT__OpenNMT-tf-577 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Bug in "onmt-ark-to-records" code
I have found a small bug in the code line referenced below. It causes the script to terminate with a `TypeError: data type not understood`. Just for the sake of completeness,... | diff --git a/opennmt/bin/ark_to_records.py b/opennmt/bin/ark_to_records.py
--- a/opennmt/bin/ark_to_records.py
+++ b/opennmt/bin/ark_to_records.py
@@ -43,7 +43,7 @@
if end:
break
- return idx, np.asarray(vector, dtype=tf.float32)
+ return idx, np.asarray(vector, dtype=np.float32)
def consume_next_tex... | {"golden_diff": "diff --git a/opennmt/bin/ark_to_records.py b/opennmt/bin/ark_to_records.py\n--- a/opennmt/bin/ark_to_records.py\n+++ b/opennmt/bin/ark_to_records.py\n@@ -43,7 +43,7 @@\n if end:\n break\n \n- return idx, np.asarray(vector, dtype=tf.float32)\n+ return idx, np.asarray(vector, dtype=np.float32... |
gh_patches_debug_294 | rasdani/github-patches | git_diff | getredash__redash-3421 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
When creating a visualisation after running a query the query results are deleted
We are testing the latest stable version of redash (6.0.0+b10818 (7fa66654)
Found a regression when creating a new visualizat... | diff --git a/redash/handlers/queries.py b/redash/handlers/queries.py
--- a/redash/handlers/queries.py
+++ b/redash/handlers/queries.py
@@ -228,7 +228,7 @@
'object_type': 'query'
})
- return QuerySerializer(query).serialize()
+ return QuerySerializer(query, with_visualizations=True)... | {"golden_diff": "diff --git a/redash/handlers/queries.py b/redash/handlers/queries.py\n--- a/redash/handlers/queries.py\n+++ b/redash/handlers/queries.py\n@@ -228,7 +228,7 @@\n 'object_type': 'query'\n })\n \n- return QuerySerializer(query).serialize()\n+ return QuerySerializer(query, ... |
gh_patches_debug_295 | rasdani/github-patches | git_diff | arviz-devs__arviz-1962 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
from_pystan puts log likelihood and posterior predictions in posterior data
## Short Description
I would like to convert a posterior sample from a PyStan `stan.fit.Fit` object to an `az.InferenceData` obje... | diff --git a/arviz/data/io_pystan.py b/arviz/data/io_pystan.py
--- a/arviz/data/io_pystan.py
+++ b/arviz/data/io_pystan.py
@@ -809,6 +809,8 @@
data = OrderedDict()
for var in variables:
+ if var in ignore:
+ continue
if var in data:
continue
dtype = dt... | {"golden_diff": "diff --git a/arviz/data/io_pystan.py b/arviz/data/io_pystan.py\n--- a/arviz/data/io_pystan.py\n+++ b/arviz/data/io_pystan.py\n@@ -809,6 +809,8 @@\n data = OrderedDict()\r\n \r\n for var in variables:\r\n+ if var in ignore:\r\n+ continue\r\n if var in data:\r\n ... |
gh_patches_debug_296 | rasdani/github-patches | git_diff | TheAlgorithms__Python-11276 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Global variable should not using in class method
### Repository commit
9caf4784aada17dc75348f77cc8c356df503c0f3
### Python version (python --version)
python3.11
### Dependencies version (pip freeze)
#nop... | diff --git a/data_structures/binary_tree/segment_tree.py b/data_structures/binary_tree/segment_tree.py
--- a/data_structures/binary_tree/segment_tree.py
+++ b/data_structures/binary_tree/segment_tree.py
@@ -98,7 +98,7 @@
def show_data(self):
show_list = []
- for i in range(1, N + 1):
+ for... | {"golden_diff": "diff --git a/data_structures/binary_tree/segment_tree.py b/data_structures/binary_tree/segment_tree.py\n--- a/data_structures/binary_tree/segment_tree.py\n+++ b/data_structures/binary_tree/segment_tree.py\n@@ -98,7 +98,7 @@\n \n def show_data(self):\n show_list = []\n- for i in range... |
gh_patches_debug_297 | rasdani/github-patches | git_diff | typeddjango__django-stubs-1326 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Next release planning (1.13.2)
I'd like to make a new django-stubs release soonish.
I think this is a blocker:
* #1311
~~I don't know how to unlock mypy 0.991 support other than to disable testing wi... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -36,7 +36,7 @@
setup(
name="django-stubs",
- version="1.13.1",
+ version="1.13.2",
description="Mypy stubs for Django",
long_description=readme,
long_description_content_type="text/markdown",
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -36,7 +36,7 @@\n \n setup(\n name=\"django-stubs\",\n- version=\"1.13.1\",\n+ version=\"1.13.2\",\n description=\"Mypy stubs for Django\",\n long_description=readme,\n long_description_content_type=\"text/markdow... |
gh_patches_debug_298 | rasdani/github-patches | git_diff | pytorch__vision-8164 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Bug in `datasets.kitti.Kitti`: `expanduser` operation not performed for `root` parameter
### **🐛 Describe the bug**
When initializing the `torchvision.datasets.kitti.Kitti` class from the torchvision projec... | diff --git a/torchvision/datasets/kitti.py b/torchvision/datasets/kitti.py
--- a/torchvision/datasets/kitti.py
+++ b/torchvision/datasets/kitti.py
@@ -66,7 +66,6 @@
)
self.images = []
self.targets = []
- self.root = root
self.train = train
self._location = "training" ... | {"golden_diff": "diff --git a/torchvision/datasets/kitti.py b/torchvision/datasets/kitti.py\n--- a/torchvision/datasets/kitti.py\n+++ b/torchvision/datasets/kitti.py\n@@ -66,7 +66,6 @@\n )\n self.images = []\n self.targets = []\n- self.root = root\n self.train = train\n se... |
gh_patches_debug_299 | rasdani/github-patches | git_diff | pypi__warehouse-3130 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Change "Edit" to "Manage" in "Your Projects"
Change the button/link text "Edit" to "Manage" in "Your Projects".
From IRC conversation with @alanbato, @ewdurbin and @nlhkabu .
~~~
<EWDurbin> I think per... | diff --git a/warehouse/packaging/views.py b/warehouse/packaging/views.py
--- a/warehouse/packaging/views.py
+++ b/warehouse/packaging/views.py
@@ -132,7 +132,7 @@
@view_config(
route_name="includes.edit-project-button",
- renderer="includes/edit-project-button.html",
+ renderer="includes/manage-project-bu... | {"golden_diff": "diff --git a/warehouse/packaging/views.py b/warehouse/packaging/views.py\n--- a/warehouse/packaging/views.py\n+++ b/warehouse/packaging/views.py\n@@ -132,7 +132,7 @@\n \n @view_config(\n route_name=\"includes.edit-project-button\",\n- renderer=\"includes/edit-project-button.html\",\n+ rendere... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.