problem_id stringlengths 18 22 | source stringclasses 1
value | task_type stringclasses 1
value | in_source_id stringlengths 13 58 | prompt stringlengths 1.1k 25.4k | golden_diff stringlengths 145 5.13k | verification_info stringlengths 582 39.1k | num_tokens int64 271 4.1k | num_tokens_diff int64 47 1.02k |
|---|---|---|---|---|---|---|---|---|
gh_patches_debug_13438 | rasdani/github-patches | git_diff | alltheplaces__alltheplaces-3307 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Spider vetco is broken
During the global build at 2021-09-01-14-42-16, spider **vetco** failed with **0 features** and **24644 errors**.
Here's [the log](https://data.alltheplaces.xyz/runs/2021-09-01-14-42-1... | diff --git a/locations/spiders/vetco_clinic.py b/locations/spiders/vetco_clinic.py
--- a/locations/spiders/vetco_clinic.py
+++ b/locations/spiders/vetco_clinic.py
@@ -38,7 +38,7 @@
if clinics:
for stores in clinics:
body = stores['label']
- address =... | {"golden_diff": "diff --git a/locations/spiders/vetco_clinic.py b/locations/spiders/vetco_clinic.py\n--- a/locations/spiders/vetco_clinic.py\n+++ b/locations/spiders/vetco_clinic.py\n@@ -38,7 +38,7 @@\n if clinics:\n for stores in clinics:\n body = stores['label']\n- ... | 1,108 | 173 |
gh_patches_debug_8249 | rasdani/github-patches | git_diff | holoviz__panel-2611 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Change fast theme button color back to white
After upgrading to Panel 0.12.0 the fast theme button switched to the red color

header_neutral_color = param.String(default="#ffffff")
- header_accent_base_color = param.St... | {"golden_diff": "diff --git a/panel/template/fast/theme.py b/panel/template/fast/theme.py\n--- a/panel/template/fast/theme.py\n+++ b/panel/template/fast/theme.py\n@@ -45,7 +45,7 @@\n \n header_background = param.String(default=\"#00aa41\")\n header_neutral_color = param.String(default=\"#ffffff\")\n- header_... | 2,704 | 142 |
gh_patches_debug_40056 | rasdani/github-patches | git_diff | arviz-devs__arviz-1074 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Bokeh hover tooltip
We need to implement better default hover settings.
https://docs.bokeh.org/en/1.4.0/docs/reference/models/tools.html#bokeh.models.tools.HoverTool
--- END ISSUE ---
Below are some code... | diff --git a/arviz/plots/backends/bokeh/pairplot.py b/arviz/plots/backends/bokeh/pairplot.py
--- a/arviz/plots/backends/bokeh/pairplot.py
+++ b/arviz/plots/backends/bokeh/pairplot.py
@@ -39,6 +39,13 @@
}
dpi = backend_kwargs.pop("dpi")
if numvars == 2:
+ if kind == "scatter":
+ tooltips... | {"golden_diff": "diff --git a/arviz/plots/backends/bokeh/pairplot.py b/arviz/plots/backends/bokeh/pairplot.py\n--- a/arviz/plots/backends/bokeh/pairplot.py\n+++ b/arviz/plots/backends/bokeh/pairplot.py\n@@ -39,6 +39,13 @@\n }\n dpi = backend_kwargs.pop(\"dpi\")\n if numvars == 2:\n+ if kind == \"scat... | 2,565 | 827 |
gh_patches_debug_40783 | rasdani/github-patches | git_diff | iterative__dvc-4848 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
dvc version: show external cache and remotes being used
This would have made my life easier when investigating https://github.com/iterative/dvc/pull/4570.
Another question to ask is that `dvc version` can ... | diff --git a/dvc/info.py b/dvc/info.py
--- a/dvc/info.py
+++ b/dvc/info.py
@@ -8,7 +8,7 @@
from dvc.repo import Repo
from dvc.scm.base import SCMError
from dvc.system import System
-from dvc.tree import TREES
+from dvc.tree import TREES, get_tree_cls, get_tree_config
from dvc.utils import error_link
from dvc.utils... | {"golden_diff": "diff --git a/dvc/info.py b/dvc/info.py\n--- a/dvc/info.py\n+++ b/dvc/info.py\n@@ -8,7 +8,7 @@\n from dvc.repo import Repo\n from dvc.scm.base import SCMError\n from dvc.system import System\n-from dvc.tree import TREES\n+from dvc.tree import TREES, get_tree_cls, get_tree_config\n from dvc.utils import ... | 2,368 | 809 |
gh_patches_debug_51335 | rasdani/github-patches | git_diff | beetbox__beets-1650 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
plexupdate plugin crashed
Every time after import plexupdate plugin crashed with this error:
```
Traceback (most recent call last):
File "/usr/local/bin/beet", line 9, in <module>
load_entry_point('bee... | diff --git a/beetsplug/plexupdate.py b/beetsplug/plexupdate.py
--- a/beetsplug/plexupdate.py
+++ b/beetsplug/plexupdate.py
@@ -28,7 +28,7 @@
r = requests.get(url)
# Parse xml tree and extract music section key.
- tree = ET.fromstring(r.text)
+ tree = ET.fromstring(r.content)
for child in tree.fin... | {"golden_diff": "diff --git a/beetsplug/plexupdate.py b/beetsplug/plexupdate.py\n--- a/beetsplug/plexupdate.py\n+++ b/beetsplug/plexupdate.py\n@@ -28,7 +28,7 @@\n r = requests.get(url)\n \n # Parse xml tree and extract music section key.\n- tree = ET.fromstring(r.text)\n+ tree = ET.fromstring(r.content)\n... | 1,528 | 118 |
gh_patches_debug_34669 | rasdani/github-patches | git_diff | PlasmaPy__PlasmaPy-125 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Raise ImportError when installing/importing with old versions of Python, Astropy, & NumPy
We decided that PlasmaPy will only be supported for:
- Python version > 3.6
- Astropy version > 2.0
- NumPy version... | diff --git a/plasmapy/__init__.py b/plasmapy/__init__.py
--- a/plasmapy/__init__.py
+++ b/plasmapy/__init__.py
@@ -5,16 +5,81 @@
author as __author__,
)
-from .classes import Plasma
-from . import classes
-from . import constants
-from . import atomic
-from . import math
-from . import physics
-from . import ut... | {"golden_diff": "diff --git a/plasmapy/__init__.py b/plasmapy/__init__.py\n--- a/plasmapy/__init__.py\n+++ b/plasmapy/__init__.py\n@@ -5,16 +5,81 @@\n author as __author__,\n )\n \n-from .classes import Plasma\n-from . import classes\n-from . import constants\n-from . import atomic\n-from . import math\n-from . imp... | 656 | 720 |
gh_patches_debug_36409 | rasdani/github-patches | git_diff | streamlit__streamlit-682 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Streamlit 0.49.0 on Windows + Python 3.8 fails to execute (Tornado error)
# Summary
Streamlit fails to execute on Windows under Python 3.8 due to a bug in Tornado. The version of Tornado pinned in streamlit... | diff --git a/lib/streamlit/bootstrap.py b/lib/streamlit/bootstrap.py
--- a/lib/streamlit/bootstrap.py
+++ b/lib/streamlit/bootstrap.py
@@ -23,6 +23,7 @@
from streamlit import config
from streamlit import net_util
from streamlit import url_util
+from streamlit import env_util
from streamlit import util
from streaml... | {"golden_diff": "diff --git a/lib/streamlit/bootstrap.py b/lib/streamlit/bootstrap.py\n--- a/lib/streamlit/bootstrap.py\n+++ b/lib/streamlit/bootstrap.py\n@@ -23,6 +23,7 @@\n from streamlit import config\n from streamlit import net_util\n from streamlit import url_util\n+from streamlit import env_util\n from streamlit ... | 2,706 | 584 |
gh_patches_debug_60412 | rasdani/github-patches | git_diff | coala__coala-4215 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Support neovim (`nvim`) as an editor
```
[WARNING][14:15:54] The editor "nvim" is unknown to coala. Files won't be opened at the correct positions and other quirks might occur. Consider opening an issue at h... | diff --git a/coalib/results/result_actions/OpenEditorAction.py b/coalib/results/result_actions/OpenEditorAction.py
--- a/coalib/results/result_actions/OpenEditorAction.py
+++ b/coalib/results/result_actions/OpenEditorAction.py
@@ -39,6 +39,10 @@
'file_arg_template': '{filename} +{line}',
'gui': False
... | {"golden_diff": "diff --git a/coalib/results/result_actions/OpenEditorAction.py b/coalib/results/result_actions/OpenEditorAction.py\n--- a/coalib/results/result_actions/OpenEditorAction.py\n+++ b/coalib/results/result_actions/OpenEditorAction.py\n@@ -39,6 +39,10 @@\n 'file_arg_template': '{filename} +{line}',\n... | 2,350 | 144 |
gh_patches_debug_15290 | rasdani/github-patches | git_diff | Zeroto521__my-data-toolkit-390 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
DOC: shorten package path
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `dtoolkit/geoaccessor/register.py... | diff --git a/dtoolkit/geoaccessor/accessor.py b/dtoolkit/geoaccessor/accessor.py
--- a/dtoolkit/geoaccessor/accessor.py
+++ b/dtoolkit/geoaccessor/accessor.py
@@ -31,8 +31,8 @@
--------
register_geoseries_accessor
register_geodataframe_accessor
- dtoolkit.geoaccessor.register.register_geoseries_method... | {"golden_diff": "diff --git a/dtoolkit/geoaccessor/accessor.py b/dtoolkit/geoaccessor/accessor.py\n--- a/dtoolkit/geoaccessor/accessor.py\n+++ b/dtoolkit/geoaccessor/accessor.py\n@@ -31,8 +31,8 @@\n --------\n register_geoseries_accessor\n register_geodataframe_accessor\n- dtoolkit.geoaccessor.register.r... | 2,182 | 284 |
gh_patches_debug_4229 | rasdani/github-patches | git_diff | twisted__twisted-11816 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
twisted.web.pages.errorPage docstring has a typo
> Use [IResource.putChild()](https://docs.twisted.org/en/stable/api/twisted.web.resource.IResource.html#putChild) override specific path.
Should be:
> Us... | diff --git a/src/twisted/web/pages.py b/src/twisted/web/pages.py
--- a/src/twisted/web/pages.py
+++ b/src/twisted/web/pages.py
@@ -83,7 +83,7 @@
useful for rendering simple error pages.
The resource dynamically handles all paths below it. Use
- L{IResource.putChild()} override specific path.
+ L{IReso... | {"golden_diff": "diff --git a/src/twisted/web/pages.py b/src/twisted/web/pages.py\n--- a/src/twisted/web/pages.py\n+++ b/src/twisted/web/pages.py\n@@ -83,7 +83,7 @@\n useful for rendering simple error pages.\n \n The resource dynamically handles all paths below it. Use\n- L{IResource.putChild()} override spe... | 1,605 | 122 |
gh_patches_debug_40353 | rasdani/github-patches | git_diff | open-telemetry__opentelemetry-python-contrib-1758 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Only collect `db.statement` if there is sanitization
Spec https://github.com/open-telemetry/opentelemetry-specification/pull/3127
- [ ] [aiopg](https://github.com/open-telemetry/opentelemetry-python-contrib/... | diff --git a/instrumentation/opentelemetry-instrumentation-elasticsearch/src/opentelemetry/instrumentation/elasticsearch/__init__.py b/instrumentation/opentelemetry-instrumentation-elasticsearch/src/opentelemetry/instrumentation/elasticsearch/__init__.py
--- a/instrumentation/opentelemetry-instrumentation-elasticsearch... | {"golden_diff": "diff --git a/instrumentation/opentelemetry-instrumentation-elasticsearch/src/opentelemetry/instrumentation/elasticsearch/__init__.py b/instrumentation/opentelemetry-instrumentation-elasticsearch/src/opentelemetry/instrumentation/elasticsearch/__init__.py\n--- a/instrumentation/opentelemetry-instrumenta... | 3,713 | 662 |
gh_patches_debug_12855 | rasdani/github-patches | git_diff | fossasia__open-event-server-6858 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Server crashing on order PATCH
```
KeyError: 'mytickets_url'
(16 additional frame(s) were not displayed)
...
File "flask_rest_jsonapi/decorators.py", line 56, in wrapper
return func(*args, **kwargs... | diff --git a/app/api/helpers/system_mails.py b/app/api/helpers/system_mails.py
--- a/app/api/helpers/system_mails.py
+++ b/app/api/helpers/system_mails.py
@@ -190,7 +190,7 @@
u"<br/>Your order has been processed successfully."
+ u"<br/> Your tickets & invoice have been enclosed."
... | {"golden_diff": "diff --git a/app/api/helpers/system_mails.py b/app/api/helpers/system_mails.py\n--- a/app/api/helpers/system_mails.py\n+++ b/app/api/helpers/system_mails.py\n@@ -190,7 +190,7 @@\n u\"<br/>Your order has been processed successfully.\"\n + u\"<br/> Your tickets & invoice have been... | 4,026 | 191 |
gh_patches_debug_38939 | rasdani/github-patches | git_diff | AlexsLemonade__refinebio-3363 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Clean up AWS Batch job definition list
### Problem or idea
The Batch job definition section contains 100+ pages of jobs (~2500 items). They haven't been cleaned up properly during deploy process for a whil... | diff --git a/infrastructure/delete_batch_job_queue.py b/infrastructure/delete_batch_job_queue.py
--- a/infrastructure/delete_batch_job_queue.py
+++ b/infrastructure/delete_batch_job_queue.py
@@ -2,19 +2,22 @@
from time import sleep
import boto3
+from botocore.exceptions import ClientError
-AWS_REGION = os.environ... | {"golden_diff": "diff --git a/infrastructure/delete_batch_job_queue.py b/infrastructure/delete_batch_job_queue.py\n--- a/infrastructure/delete_batch_job_queue.py\n+++ b/infrastructure/delete_batch_job_queue.py\n@@ -2,19 +2,22 @@\n from time import sleep\n \n import boto3\n+from botocore.exceptions import ClientError\n ... | 958 | 786 |
gh_patches_debug_10043 | rasdani/github-patches | git_diff | nautobot__nautobot-877 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Migrate user, social auth, and system settings from Django Admin to be first-class citizens in UI/API
### Proposed Functionality
Before the launch of Nautobot, there was significant work to migrate functi... | diff --git a/nautobot/core/admin.py b/nautobot/core/admin.py
--- a/nautobot/core/admin.py
+++ b/nautobot/core/admin.py
@@ -1,5 +1,6 @@
from django.conf import settings
from django.contrib.admin import site as admin_site
+from social_django.models import Association, Nonce, UserSocialAuth
from taggit.models import Ta... | {"golden_diff": "diff --git a/nautobot/core/admin.py b/nautobot/core/admin.py\n--- a/nautobot/core/admin.py\n+++ b/nautobot/core/admin.py\n@@ -1,5 +1,6 @@\n from django.conf import settings\n from django.contrib.admin import site as admin_site\n+from social_django.models import Association, Nonce, UserSocialAuth\n from... | 680 | 153 |
gh_patches_debug_6459 | rasdani/github-patches | git_diff | holoviz__panel-5490 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
--autoreload does not work in Panel 1.2.2
Run this code with `panel serve --autoreload tmp.py` and change the end to 2 the
``` python
# tmp.py
import panel as pn
pn.widgets.IntSlider(end=1).servable(... | diff --git a/panel/io/callbacks.py b/panel/io/callbacks.py
--- a/panel/io/callbacks.py
+++ b/panel/io/callbacks.py
@@ -84,7 +84,7 @@
with set_curdoc(self._doc):
if self.running:
self.counter += 1
- if self.counter > self.count:
+ i... | {"golden_diff": "diff --git a/panel/io/callbacks.py b/panel/io/callbacks.py\n--- a/panel/io/callbacks.py\n+++ b/panel/io/callbacks.py\n@@ -84,7 +84,7 @@\n with set_curdoc(self._doc):\n if self.running:\n self.counter += 1\n- if self.counter > self.count... | 2,374 | 113 |
gh_patches_debug_4919 | rasdani/github-patches | git_diff | bokeh__bokeh-1361 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Cannot style minor ticks
Axis objects do not have minor tick properties.
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FI... | diff --git a/bokeh/models/axes.py b/bokeh/models/axes.py
--- a/bokeh/models/axes.py
+++ b/bokeh/models/axes.py
@@ -27,11 +27,15 @@
major_label_props = Include(TextProps)
axis_props = Include(LineProps)
- major_tick_props = Include(LineProps)
+ major_tick_props = Include(LineProps)
major_tick_in... | {"golden_diff": "diff --git a/bokeh/models/axes.py b/bokeh/models/axes.py\n--- a/bokeh/models/axes.py\n+++ b/bokeh/models/axes.py\n@@ -27,11 +27,15 @@\n major_label_props = Include(TextProps)\n \n axis_props = Include(LineProps)\n- major_tick_props = Include(LineProps)\n \n+ major_tick_props = Include(Lin... | 1,017 | 143 |
gh_patches_debug_14499 | rasdani/github-patches | git_diff | optuna__optuna-3545 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Show warning message by `GridSearchSampler` whose `CategoricalDistribution` contains unsupported typed values, not raising `ValueError`
### Motivation
The grid search sampler has a strict type rule for its s... | diff --git a/optuna/samplers/_grid.py b/optuna/samplers/_grid.py
--- a/optuna/samplers/_grid.py
+++ b/optuna/samplers/_grid.py
@@ -211,11 +211,12 @@
if param_value is None or isinstance(param_value, (str, int, float, bool)):
return
- raise ValueError(
+ message = (
"{}... | {"golden_diff": "diff --git a/optuna/samplers/_grid.py b/optuna/samplers/_grid.py\n--- a/optuna/samplers/_grid.py\n+++ b/optuna/samplers/_grid.py\n@@ -211,11 +211,12 @@\n if param_value is None or isinstance(param_value, (str, int, float, bool)):\n return\n \n- raise ValueError(\n+ mes... | 3,545 | 195 |
gh_patches_debug_14570 | rasdani/github-patches | git_diff | freedomofpress__securedrop-2491 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
localization: various problems
# Bug
## Description
This issue is to collect the various localization problems found before the 0.4.4 release and after the **string freeze**
They should be fixed in a... | diff --git a/securedrop/source_app/forms.py b/securedrop/source_app/forms.py
--- a/securedrop/source_app/forms.py
+++ b/securedrop/source_app/forms.py
@@ -11,7 +11,7 @@
InputRequired(message=gettext('This field is required.')),
Length(1, Source.MAX_CODENAME_LEN,
message=gettext('Field ... | {"golden_diff": "diff --git a/securedrop/source_app/forms.py b/securedrop/source_app/forms.py\n--- a/securedrop/source_app/forms.py\n+++ b/securedrop/source_app/forms.py\n@@ -11,7 +11,7 @@\n InputRequired(message=gettext('This field is required.')),\n Length(1, Source.MAX_CODENAME_LEN,\n ... | 513 | 169 |
gh_patches_debug_64451 | rasdani/github-patches | git_diff | bokeh__bokeh-9477 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[BUG] Non-daemon worker thread prevents gunicorn from shutting down cleanly.
#### ALL software version info (bokeh, python, notebook, OS, browser, any other relevant packages)
bokeh HEAD e605297
gunicorn (v... | diff --git a/examples/howto/server_embed/flask_gunicorn_embed.py b/examples/howto/server_embed/flask_gunicorn_embed.py
--- a/examples/howto/server_embed/flask_gunicorn_embed.py
+++ b/examples/howto/server_embed/flask_gunicorn_embed.py
@@ -78,4 +78,6 @@
server.start()
server.io_loop.start()
-Thread(target=bk... | {"golden_diff": "diff --git a/examples/howto/server_embed/flask_gunicorn_embed.py b/examples/howto/server_embed/flask_gunicorn_embed.py\n--- a/examples/howto/server_embed/flask_gunicorn_embed.py\n+++ b/examples/howto/server_embed/flask_gunicorn_embed.py\n@@ -78,4 +78,6 @@\n server.start()\n server.io_loop.start... | 3,126 | 105 |
gh_patches_debug_43357 | rasdani/github-patches | git_diff | streamlink__streamlink-4840 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
plugins.rtve: ZTNR.translate() runs endlessly
### Checklist
- [X] This is a plugin issue and not a different kind of issue
- [X] [I have read the contribution guidelines](https://github.com/streamlink/stream... | diff --git a/src/streamlink/plugins/rtve.py b/src/streamlink/plugins/rtve.py
--- a/src/streamlink/plugins/rtve.py
+++ b/src/streamlink/plugins/rtve.py
@@ -12,7 +12,7 @@
from typing import Iterator, Sequence, Tuple
from urllib.parse import urlparse
-from streamlink.plugin import Plugin, pluginargument, pluginmatcher... | {"golden_diff": "diff --git a/src/streamlink/plugins/rtve.py b/src/streamlink/plugins/rtve.py\n--- a/src/streamlink/plugins/rtve.py\n+++ b/src/streamlink/plugins/rtve.py\n@@ -12,7 +12,7 @@\n from typing import Iterator, Sequence, Tuple\n from urllib.parse import urlparse\n \n-from streamlink.plugin import Plugin, plugi... | 2,782 | 877 |
gh_patches_debug_41609 | rasdani/github-patches | git_diff | getnikola__nikola-1292 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
render fails if the theme has a code.css
The `conf.py` says:
```
# Color scheme to be used for code blocks. If your theme provides
# "assets/css/code.css" this is ignored.
```
I've [provided one](https:/... | diff --git a/nikola/plugins/task/copy_assets.py b/nikola/plugins/task/copy_assets.py
--- a/nikola/plugins/task/copy_assets.py
+++ b/nikola/plugins/task/copy_assets.py
@@ -45,15 +45,21 @@
kw = {
"themes": self.site.THEMES,
+ "files_folders": self.site.config['FILES_FOLDERS'],
... | {"golden_diff": "diff --git a/nikola/plugins/task/copy_assets.py b/nikola/plugins/task/copy_assets.py\n--- a/nikola/plugins/task/copy_assets.py\n+++ b/nikola/plugins/task/copy_assets.py\n@@ -45,15 +45,21 @@\n \n kw = {\n \"themes\": self.site.THEMES,\n+ \"files_folders\": self.site.config... | 1,425 | 689 |
gh_patches_debug_35953 | rasdani/github-patches | git_diff | azavea__raster-vision-272 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
More efficient chipping strategy
In `make_training_chips` for object detection, we create a chip for each object. This means that in a crowded area (like a parking lot), we create many chips that only vary sl... | diff --git a/src/rastervision/label_stores/utils.py b/src/rastervision/label_stores/utils.py
--- a/src/rastervision/label_stores/utils.py
+++ b/src/rastervision/label_stores/utils.py
@@ -26,4 +26,6 @@
properties['class_id'] = class_id
properties['class_name'] = class_name
+ fe... | {"golden_diff": "diff --git a/src/rastervision/label_stores/utils.py b/src/rastervision/label_stores/utils.py\n--- a/src/rastervision/label_stores/utils.py\n+++ b/src/rastervision/label_stores/utils.py\n@@ -26,4 +26,6 @@\n properties['class_id'] = class_id\n properties['class_name'] = cl... | 3,822 | 671 |
gh_patches_debug_2437 | rasdani/github-patches | git_diff | urllib3__urllib3-2843 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
flaky and pytest-memray incompatible
### Subject
```
______________________________________________________________________________________________________ TestHTTPProxyManager.test_forwarding_proxy_reque... | diff --git a/noxfile.py b/noxfile.py
--- a/noxfile.py
+++ b/noxfile.py
@@ -56,7 +56,6 @@
"-ra",
f"--color={'yes' if 'GITHUB_ACTIONS' in os.environ else 'auto'}",
"--tb=native",
- "--no-success-flaky-report",
"--durations=10",
"--strict-config",
"--strict-mark... | {"golden_diff": "diff --git a/noxfile.py b/noxfile.py\n--- a/noxfile.py\n+++ b/noxfile.py\n@@ -56,7 +56,6 @@\n \"-ra\",\n f\"--color={'yes' if 'GITHUB_ACTIONS' in os.environ else 'auto'}\",\n \"--tb=native\",\n- \"--no-success-flaky-report\",\n \"--durations=10\",\n \"--st... | 3,214 | 99 |
gh_patches_debug_34527 | rasdani/github-patches | git_diff | mampfes__hacs_waste_collection_schedule-1694 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[Bug]: source 'City of Karlsruhe' stopped working
### I Have A Problem With:
A specific source
### What's Your Problem
Release 1.44.0:
Due to changes on the website the source '**City of Karlsruhe**' (nam... | diff --git a/custom_components/waste_collection_schedule/waste_collection_schedule/source/karlsruhe_de.py b/custom_components/waste_collection_schedule/waste_collection_schedule/source/karlsruhe_de.py
--- a/custom_components/waste_collection_schedule/waste_collection_schedule/source/karlsruhe_de.py
+++ b/custom_compone... | {"golden_diff": "diff --git a/custom_components/waste_collection_schedule/waste_collection_schedule/source/karlsruhe_de.py b/custom_components/waste_collection_schedule/waste_collection_schedule/source/karlsruhe_de.py\n--- a/custom_components/waste_collection_schedule/waste_collection_schedule/source/karlsruhe_de.py\n+... | 1,364 | 546 |
gh_patches_debug_10893 | rasdani/github-patches | git_diff | conan-io__conan-4888 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Remote lookup in offline mode
Hello,
Following up the small issue that I had during my demo at swampUP:
I was trying to create a package for which I had every build requirement recipe already exported ... | diff --git a/conans/client/graph/graph_binaries.py b/conans/client/graph/graph_binaries.py
--- a/conans/client/graph/graph_binaries.py
+++ b/conans/client/graph/graph_binaries.py
@@ -121,6 +121,9 @@
remote_info, pref = self._remote_manager.get_package_info(pref, remote)
except NotF... | {"golden_diff": "diff --git a/conans/client/graph/graph_binaries.py b/conans/client/graph/graph_binaries.py\n--- a/conans/client/graph/graph_binaries.py\n+++ b/conans/client/graph/graph_binaries.py\n@@ -121,6 +121,9 @@\n remote_info, pref = self._remote_manager.get_package_info(pref, remote)\n ... | 2,877 | 140 |
gh_patches_debug_28800 | rasdani/github-patches | git_diff | quantumlib__Cirq-1674 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Improve error message if on_each gets a list
When you do `cirq.H.on_each([q0, q1])` instead of the unpacked version `cirq.H.on_each(q0, q1)` for some qubits `q0` and `q1`, the error message you get is **Gate... | diff --git a/cirq/ops/gate_features.py b/cirq/ops/gate_features.py
--- a/cirq/ops/gate_features.py
+++ b/cirq/ops/gate_features.py
@@ -18,8 +18,10 @@
"""
import abc
+import collections
+from typing import Union, Iterable, Any, List
-from cirq.ops import op_tree, raw_types
+from cirq.ops import raw_types
clas... | {"golden_diff": "diff --git a/cirq/ops/gate_features.py b/cirq/ops/gate_features.py\n--- a/cirq/ops/gate_features.py\n+++ b/cirq/ops/gate_features.py\n@@ -18,8 +18,10 @@\n \"\"\"\n \n import abc\n+import collections\n+from typing import Union, Iterable, Any, List\n \n-from cirq.ops import op_tree, raw_types\n+from cirq... | 984 | 411 |
gh_patches_debug_39718 | rasdani/github-patches | git_diff | prowler-cloud__prowler-2291 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[Bug]: backup_plans_exist and backup_reportplans_exist trigger in regions where not backups exist
### Steps to Reproduce
The mentioned checks are triggered even if no backups are present or configured.
### ... | diff --git a/prowler/providers/aws/services/backup/backup_plans_exist/backup_plans_exist.py b/prowler/providers/aws/services/backup/backup_plans_exist/backup_plans_exist.py
--- a/prowler/providers/aws/services/backup/backup_plans_exist/backup_plans_exist.py
+++ b/prowler/providers/aws/services/backup/backup_plans_exist... | {"golden_diff": "diff --git a/prowler/providers/aws/services/backup/backup_plans_exist/backup_plans_exist.py b/prowler/providers/aws/services/backup/backup_plans_exist/backup_plans_exist.py\n--- a/prowler/providers/aws/services/backup/backup_plans_exist/backup_plans_exist.py\n+++ b/prowler/providers/aws/services/backup... | 1,274 | 915 |
gh_patches_debug_19093 | rasdani/github-patches | git_diff | weecology__retriever-287 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
download command should probably fail when specified path does not exist
A datsaet can be downloaded to a specific path with the function `download` while specifying the -p argument. For example `retriever do... | diff --git a/engines/download_only.py b/engines/download_only.py
--- a/engines/download_only.py
+++ b/engines/download_only.py
@@ -51,7 +51,18 @@
print("Keeping existing copy.")
else:
print("Copying %s from %s" % (file_name_nopath, file_path))
- ... | {"golden_diff": "diff --git a/engines/download_only.py b/engines/download_only.py\n--- a/engines/download_only.py\n+++ b/engines/download_only.py\n@@ -51,7 +51,18 @@\n print(\"Keeping existing copy.\")\n else:\n print(\"Copying %s from %s\" % (file_name_nopath, fi... | 1,322 | 231 |
gh_patches_debug_12065 | rasdani/github-patches | git_diff | tinygrad__tinygrad-65 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
EOFError: Ran out of input
When running example and solving "Can't import fetch from utils" issue, this one comes up:
:
mask = np.zeros_like(like).reshape(-1)
@@ -12,7 +13,7 @@
def fetch(url):
import requests, os, hashlib, tempfile
... | {"golden_diff": "diff --git a/tinygrad/utils.py b/tinygrad/utils.py\n--- a/tinygrad/utils.py\n+++ b/tinygrad/utils.py\n@@ -1,4 +1,5 @@\n import numpy as np\n+import os\n \n def mask_like(like, mask_inx, mask_value = 1.0):\n mask = np.zeros_like(like).reshape(-1)\n@@ -12,7 +13,7 @@\n def fetch(url):\n import request... | 830 | 176 |
gh_patches_debug_20502 | rasdani/github-patches | git_diff | cloudtools__troposphere-1205 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add 'PermissionsBoundary' properties to AWS::IAM::Role and AWS::IAM::User
This property has been released on November 9 by AWS.
https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/ReleaseHistory.h... | diff --git a/troposphere/iam.py b/troposphere/iam.py
--- a/troposphere/iam.py
+++ b/troposphere/iam.py
@@ -79,6 +79,7 @@
'ManagedPolicyArns': ([basestring], False),
'MaxSessionDuration': (integer, False),
'Path': (iam_path, False),
+ 'PermissionsBoundary': (basestring, False),
... | {"golden_diff": "diff --git a/troposphere/iam.py b/troposphere/iam.py\n--- a/troposphere/iam.py\n+++ b/troposphere/iam.py\n@@ -79,6 +79,7 @@\n 'ManagedPolicyArns': ([basestring], False),\n 'MaxSessionDuration': (integer, False),\n 'Path': (iam_path, False),\n+ 'PermissionsBoundary': (base... | 1,541 | 256 |
gh_patches_debug_26528 | rasdani/github-patches | git_diff | ESMCI__cime-1048 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Missing f19_g16_r01 high resolution river flow grid
Between cime5.2.0-alpha.9 and cime5.2.0-alpha.20 the config_grids file format was changed, and one grid needed for CLM testing was removed. The change to ad... | diff --git a/utils/python/CIME/BuildTools/configure.py b/utils/python/CIME/BuildTools/configure.py
--- a/utils/python/CIME/BuildTools/configure.py
+++ b/utils/python/CIME/BuildTools/configure.py
@@ -49,16 +49,20 @@
def _copy_depends_files(machine_name, machines_dir, output_dir, compiler):
"""
Copy any system... | {"golden_diff": "diff --git a/utils/python/CIME/BuildTools/configure.py b/utils/python/CIME/BuildTools/configure.py\n--- a/utils/python/CIME/BuildTools/configure.py\n+++ b/utils/python/CIME/BuildTools/configure.py\n@@ -49,16 +49,20 @@\n def _copy_depends_files(machine_name, machines_dir, output_dir, compiler):\n \"... | 1,787 | 427 |
gh_patches_debug_19916 | rasdani/github-patches | git_diff | weecology__retriever-1121 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add a description field(s) to setup.py
This populates the description on PYPI:
https://packaging.python.org/tutorials/distributing-packages/#description
--- END ISSUE ---
Below are some code segments, ea... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -29,6 +29,7 @@
def clean_version(v):
return parse_version(v).__repr__().lstrip("<Version('").rstrip("')>")
+
includes = [
'xlrd',
'future',
@@ -52,6 +53,10 @@
setup(name='retriever',
version=clean_version(... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -29,6 +29,7 @@\n def clean_version(v):\n return parse_version(v).__repr__().lstrip(\"<Version('\").rstrip(\"')>\")\n \n+\n includes = [\n 'xlrd',\n 'future',\n@@ -52,6 +53,10 @@\n setup(name='retrieve... | 1,372 | 217 |
gh_patches_debug_37237 | rasdani/github-patches | git_diff | Parsl__parsl-1075 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Condor provider has a hard-coded `cmd_timeout`.
This timeout should be configurable and probably default to something much longer.
https://github.com/Parsl/parsl/blob/1d8c9e35752274af6ae2ce2f07107474ece45... | diff --git a/parsl/providers/condor/condor.py b/parsl/providers/condor/condor.py
--- a/parsl/providers/condor/condor.py
+++ b/parsl/providers/condor/condor.py
@@ -60,6 +60,8 @@
launcher : Launcher
Launcher for this provider. Possible launchers include
:class:`~parsl.launchers.SingleNodeLauncher` ... | {"golden_diff": "diff --git a/parsl/providers/condor/condor.py b/parsl/providers/condor/condor.py\n--- a/parsl/providers/condor/condor.py\n+++ b/parsl/providers/condor/condor.py\n@@ -60,6 +60,8 @@\n launcher : Launcher\n Launcher for this provider. Possible launchers include\n :class:`~parsl.launche... | 3,584 | 494 |
gh_patches_debug_51313 | rasdani/github-patches | git_diff | scikit-image__scikit-image-5128 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
filters.farid missing from skimage.filters documentation
## Description
The `filters.farid{,_h,_v}` functions are missing from the [`skimage.filters` documentation](https://scikit-image.org/docs/dev/api/sk... | diff --git a/skimage/filters/__init__.py b/skimage/filters/__init__.py
--- a/skimage/filters/__init__.py
+++ b/skimage/filters/__init__.py
@@ -43,6 +43,9 @@
'roberts_pos_diag',
'roberts_neg_diag',
'laplace',
+ 'farid',
+ 'farid_h',
+ 'farid_v',
... | {"golden_diff": "diff --git a/skimage/filters/__init__.py b/skimage/filters/__init__.py\n--- a/skimage/filters/__init__.py\n+++ b/skimage/filters/__init__.py\n@@ -43,6 +43,9 @@\n 'roberts_pos_diag',\n 'roberts_neg_diag',\n 'laplace',\n+ 'farid',\n+ 'farid_h',\n+ ... | 978 | 117 |
gh_patches_debug_43025 | rasdani/github-patches | git_diff | azavea__raster-vision-641 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Include per-scene metrics in eval.json
It would be useful to see metrics for each scene in addition to metrics averaged over all scenes.
--- END ISSUE ---
Below are some code segments, each from a relevant... | diff --git a/rastervision/evaluation/classification_evaluation.py b/rastervision/evaluation/classification_evaluation.py
--- a/rastervision/evaluation/classification_evaluation.py
+++ b/rastervision/evaluation/classification_evaluation.py
@@ -1,4 +1,5 @@
from abc import (ABC, abstractmethod)
+import copy
import jso... | {"golden_diff": "diff --git a/rastervision/evaluation/classification_evaluation.py b/rastervision/evaluation/classification_evaluation.py\n--- a/rastervision/evaluation/classification_evaluation.py\n+++ b/rastervision/evaluation/classification_evaluation.py\n@@ -1,4 +1,5 @@\n from abc import (ABC, abstractmethod)\n+imp... | 1,990 | 778 |
gh_patches_debug_23538 | rasdani/github-patches | git_diff | sql-machine-learning__elasticdl-1884 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
The first worker may crash in ALLREDUCE mode
When the worker is the only running worker pod, `_get_peer_set` will get an empty peer set.
Then consensus_init_kwars will set "known_addr_list" as empty.
This ... | diff --git a/elasticdl/python/collective_ops/communicator.py b/elasticdl/python/collective_ops/communicator.py
--- a/elasticdl/python/collective_ops/communicator.py
+++ b/elasticdl/python/collective_ops/communicator.py
@@ -23,17 +23,18 @@
class CollectiveCommunicator(object):
def __init__(self, service_name=None)... | {"golden_diff": "diff --git a/elasticdl/python/collective_ops/communicator.py b/elasticdl/python/collective_ops/communicator.py\n--- a/elasticdl/python/collective_ops/communicator.py\n+++ b/elasticdl/python/collective_ops/communicator.py\n@@ -23,17 +23,18 @@\n class CollectiveCommunicator(object):\n def __init__(se... | 2,041 | 248 |
gh_patches_debug_53980 | rasdani/github-patches | git_diff | scikit-hep__pyhf-2135 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Matplotlib broken in Pyodide demo in docs
In the docs https://pyhf.readthedocs.io/en/v0.7.0/, the Pyodide example is broken for me:
```pytb
------------------------------------------------------------------... | diff --git a/docs/generate_jupyterlite_iframe.py b/docs/generate_jupyterlite_iframe.py
--- a/docs/generate_jupyterlite_iframe.py
+++ b/docs/generate_jupyterlite_iframe.py
@@ -4,7 +4,7 @@
def main():
code = """\
import piplite
-await piplite.install(["pyhf==0.7.0"])
+await piplite.install(["pyhf==0.7.0", "matplot... | {"golden_diff": "diff --git a/docs/generate_jupyterlite_iframe.py b/docs/generate_jupyterlite_iframe.py\n--- a/docs/generate_jupyterlite_iframe.py\n+++ b/docs/generate_jupyterlite_iframe.py\n@@ -4,7 +4,7 @@\n def main():\n code = \"\"\"\\\n import piplite\n-await piplite.install([\"pyhf==0.7.0\"])\n+await piplite.i... | 1,352 | 120 |
gh_patches_debug_22217 | rasdani/github-patches | git_diff | OCA__bank-payment-107 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Test fails with Odoo, not OCB
https://travis-ci.org/OCA/bank-payment/builds/47806067
File "/home/travis/build/OCA/bank-payment/account_direct_debit/models/account_invoice.py", line 140, in __ init __
invoic... | diff --git a/account_direct_debit/models/account_invoice.py b/account_direct_debit/models/account_invoice.py
--- a/account_direct_debit/models/account_invoice.py
+++ b/account_direct_debit/models/account_invoice.py
@@ -126,7 +126,7 @@
class AccountInvoice(orm.Model):
_inherit = "account.invoice"
- def __init... | {"golden_diff": "diff --git a/account_direct_debit/models/account_invoice.py b/account_direct_debit/models/account_invoice.py\n--- a/account_direct_debit/models/account_invoice.py\n+++ b/account_direct_debit/models/account_invoice.py\n@@ -126,7 +126,7 @@\n class AccountInvoice(orm.Model):\n _inherit = \"account.inv... | 2,216 | 246 |
gh_patches_debug_20110 | rasdani/github-patches | git_diff | pytorch__ignite-2639 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Code formatting issue with latest flake8
https://github.com/pytorch/ignite/runs/7781175697?check_suite_focus=true#step:11:84
```
Collecting flake8
Downloading flake8-5.0.4-py2.py3-none-any.whl (61 kB... | diff --git a/ignite/metrics/psnr.py b/ignite/metrics/psnr.py
--- a/ignite/metrics/psnr.py
+++ b/ignite/metrics/psnr.py
@@ -9,7 +9,8 @@
class PSNR(Metric):
- r"""Computes average `Peak signal-to-noise ratio (PSNR) <https://en.wikipedia.org/wiki/Peak_signal-to-noise_ratio>`_.
+ r"""Computes average
+ `Peak ... | {"golden_diff": "diff --git a/ignite/metrics/psnr.py b/ignite/metrics/psnr.py\n--- a/ignite/metrics/psnr.py\n+++ b/ignite/metrics/psnr.py\n@@ -9,7 +9,8 @@\n \n \n class PSNR(Metric):\n- r\"\"\"Computes average `Peak signal-to-noise ratio (PSNR) <https://en.wikipedia.org/wiki/Peak_signal-to-noise_ratio>`_.\n+ r\"\... | 1,906 | 305 |
gh_patches_debug_14337 | rasdani/github-patches | git_diff | horovod__horovod-3830 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Spark tests fail with AttributeError: 'pyarrow.lib.Schema' object has no attribute 'to_arrow_schema'
Spark tests fail with
```
Traceback (most recent call last):
File "/horovod/examples/spark/pytorch/p... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -167,7 +167,7 @@
mxnet_require_list = ['mxnet>=1.4.1']
pyspark_require_list = ['pyspark>=2.3.2;python_version<"3.8"',
'pyspark>=3.0.0;python_version>="3.8"']
-spark_require_list = ['numpy', 'petastorm>=0.12.0', 'pyarrow>=0.15.0... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -167,7 +167,7 @@\n mxnet_require_list = ['mxnet>=1.4.1']\n pyspark_require_list = ['pyspark>=2.3.2;python_version<\"3.8\"',\n 'pyspark>=3.0.0;python_version>=\"3.8\"']\n-spark_require_list = ['numpy', 'petastor... | 4,050 | 270 |
gh_patches_debug_36049 | rasdani/github-patches | git_diff | mozilla__pontoon-2716 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Pretranslated Fluent string has the ID translated or modified
It happened for at least two strings.
```
remember-pw-link = Remember your password? Sign in
```
Became
```
Remember-pw-link = Ricordi... | diff --git a/pontoon/pretranslation/pretranslate.py b/pontoon/pretranslation/pretranslate.py
--- a/pontoon/pretranslation/pretranslate.py
+++ b/pontoon/pretranslation/pretranslate.py
@@ -18,6 +18,7 @@
get_reconstructed_message,
)
+UNTRANSLATABLE_KEY = "AIzaSyDX3R5Y1kxh_8lJ4OAO"
serializer = FluentSerializer(... | {"golden_diff": "diff --git a/pontoon/pretranslation/pretranslate.py b/pontoon/pretranslation/pretranslate.py\n--- a/pontoon/pretranslation/pretranslate.py\n+++ b/pontoon/pretranslation/pretranslate.py\n@@ -18,6 +18,7 @@\n get_reconstructed_message,\n )\n \n+UNTRANSLATABLE_KEY = \"AIzaSyDX3R5Y1kxh_8lJ4OAO\"\n \n se... | 1,374 | 467 |
gh_patches_debug_21595 | rasdani/github-patches | git_diff | matrix-org__synapse-3927 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
run_as_background_process doesn't catch & log exceptions
(plus if it does raise in a loopingcall, we throw away the exception)
--- END ISSUE ---
Below are some code segments, each from a relevant file. One... | diff --git a/synapse/metrics/background_process_metrics.py b/synapse/metrics/background_process_metrics.py
--- a/synapse/metrics/background_process_metrics.py
+++ b/synapse/metrics/background_process_metrics.py
@@ -13,6 +13,7 @@
# See the License for the specific language governing permissions and
# limitations under... | {"golden_diff": "diff --git a/synapse/metrics/background_process_metrics.py b/synapse/metrics/background_process_metrics.py\n--- a/synapse/metrics/background_process_metrics.py\n+++ b/synapse/metrics/background_process_metrics.py\n@@ -13,6 +13,7 @@\n # See the License for the specific language governing permissions and... | 2,252 | 207 |
gh_patches_debug_21192 | rasdani/github-patches | git_diff | bokeh__bokeh-7000 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Incomplete docs re embedding when using data tables
Hi, I banged my head a bit trying to use `components` to render tables and failing while `file_html` would work well.
Turns out we now need to include:
`... | diff --git a/bokeh/embed/standalone.py b/bokeh/embed/standalone.py
--- a/bokeh/embed/standalone.py
+++ b/bokeh/embed/standalone.py
@@ -109,9 +109,25 @@
An example can be found in examples/embed/embed_multiple.py
- .. note::
- The returned components assume that BokehJS resources are
- **alread... | {"golden_diff": "diff --git a/bokeh/embed/standalone.py b/bokeh/embed/standalone.py\n--- a/bokeh/embed/standalone.py\n+++ b/bokeh/embed/standalone.py\n@@ -109,9 +109,25 @@\n \n An example can be found in examples/embed/embed_multiple.py\n \n- .. note::\n- The returned components assume that BokehJS resour... | 3,938 | 391 |
gh_patches_debug_38587 | rasdani/github-patches | git_diff | CiviWiki__OpenCiviWiki-1232 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Refactor function-based view to class-based
### Idea summary
Rewrite function-based view to class-based and add docstring
### Further details
In the accounts app's view, there is a function-based view call... | diff --git a/project/accounts/urls/urls.py b/project/accounts/urls/urls.py
--- a/project/accounts/urls/urls.py
+++ b/project/accounts/urls/urls.py
@@ -9,7 +9,7 @@
PasswordResetConfirmView,
PasswordResetCompleteView,
ProfileSetupView,
- user_profile,
+ UserProfileView,
)
urlpatterns = [
@@ -22,7... | {"golden_diff": "diff --git a/project/accounts/urls/urls.py b/project/accounts/urls/urls.py\n--- a/project/accounts/urls/urls.py\n+++ b/project/accounts/urls/urls.py\n@@ -9,7 +9,7 @@\n PasswordResetConfirmView,\n PasswordResetCompleteView,\n ProfileSetupView,\n- user_profile,\n+ UserProfileView,\n )\n... | 2,843 | 527 |
gh_patches_debug_22239 | rasdani/github-patches | git_diff | dotkom__onlineweb4-2359 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Atendee list bug when adding or removing users
<!-- If this is a security issue or information leakage (having access to something you (probably) shouldn't), please send an email rather than opening a public ... | diff --git a/apps/events/dashboard/utils.py b/apps/events/dashboard/utils.py
--- a/apps/events/dashboard/utils.py
+++ b/apps/events/dashboard/utils.py
@@ -65,7 +65,9 @@
'id': a.id,
'first_name': a.user.first_name,
'last_name': a.user.last_name,
+ 'year_of_study': a.user... | {"golden_diff": "diff --git a/apps/events/dashboard/utils.py b/apps/events/dashboard/utils.py\n--- a/apps/events/dashboard/utils.py\n+++ b/apps/events/dashboard/utils.py\n@@ -65,7 +65,9 @@\n 'id': a.id,\n 'first_name': a.user.first_name,\n 'last_name': a.user.last_name,\n+ ... | 2,006 | 247 |
gh_patches_debug_34954 | rasdani/github-patches | git_diff | deepchecks__deepchecks-807 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[BUG] Calling `save_as_html` can raise an error if the label column is imbalanced and has the type `np.bool_`
**Describe the bug**
The error comes from this chart (section "Train Test Label Drift"):
![image... | diff --git a/deepchecks/utils/dataframes.py b/deepchecks/utils/dataframes.py
--- a/deepchecks/utils/dataframes.py
+++ b/deepchecks/utils/dataframes.py
@@ -10,13 +10,37 @@
#
"""Contain functions for handling dataframes in checks."""
import typing as t
+
import pandas as pd
+import numpy as np
+
from deepchecks.util... | {"golden_diff": "diff --git a/deepchecks/utils/dataframes.py b/deepchecks/utils/dataframes.py\n--- a/deepchecks/utils/dataframes.py\n+++ b/deepchecks/utils/dataframes.py\n@@ -10,13 +10,37 @@\n #\n \"\"\"Contain functions for handling dataframes in checks.\"\"\"\n import typing as t\n+\n import pandas as pd\n+import num... | 4,018 | 526 |
gh_patches_debug_26033 | rasdani/github-patches | git_diff | cowrie__cowrie-1237 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
`ls -l` user/group names need justification
`ls -l` does not properly pad the user/group names
**To Reproduce**
Steps to reproduce the behaviour:
1. ssh into a cowrie instance
2. `ls -l` on a directory ... | diff --git a/src/cowrie/commands/ls.py b/src/cowrie/commands/ls.py
--- a/src/cowrie/commands/ls.py
+++ b/src/cowrie/commands/ls.py
@@ -112,9 +112,17 @@
def do_ls_l(self, path):
files = self.get_dir_files(path)
- largest = 0
+ filesize_str_extent = 0
if len(files):
- lar... | {"golden_diff": "diff --git a/src/cowrie/commands/ls.py b/src/cowrie/commands/ls.py\n--- a/src/cowrie/commands/ls.py\n+++ b/src/cowrie/commands/ls.py\n@@ -112,9 +112,17 @@\n def do_ls_l(self, path):\n files = self.get_dir_files(path)\n \n- largest = 0\n+ filesize_str_extent = 0\n if le... | 2,268 | 416 |
gh_patches_debug_9897 | rasdani/github-patches | git_diff | freedomofpress__securedrop-4931 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[1.1.0-rc4] "Unable to create virtualenv. Check network settings and try again"
(Tested on a Tails 3.16 Admin Workstation by checking out 1.1.0-rc4 tag, without updating my servers.)
As expected, running `... | diff --git a/admin/bootstrap.py b/admin/bootstrap.py
--- a/admin/bootstrap.py
+++ b/admin/bootstrap.py
@@ -64,12 +64,12 @@
def is_tails():
try:
id = subprocess.check_output('lsb_release --id --short',
- shell=True).strip()
+ shell=Tr... | {"golden_diff": "diff --git a/admin/bootstrap.py b/admin/bootstrap.py\n--- a/admin/bootstrap.py\n+++ b/admin/bootstrap.py\n@@ -64,12 +64,12 @@\n def is_tails():\n try:\n id = subprocess.check_output('lsb_release --id --short',\n- shell=True).strip()\n+ ... | 3,284 | 152 |
gh_patches_debug_2042 | rasdani/github-patches | git_diff | aws__aws-cli-357 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
pip install awscli fails
I tried `pip install awscli` from https://github.com/aws/aws-cli/blob/develop/README.rst and failed:
http://sprunge.us/NfbW
/home/hendry/.pip/pip.log = http://ix.io/7SC
Hilarious h... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -11,7 +11,7 @@
'six>=1.1.0',
'colorama==0.2.5',
'docutils>=0.10',
- 'rsa==3.1.1']
+ 'rsa==3.1.2']
if sys.version_info[:2] == (2, 6):
# For python2.6 we have to require argparse since it... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -11,7 +11,7 @@\n 'six>=1.1.0',\n 'colorama==0.2.5',\n 'docutils>=0.10',\n- 'rsa==3.1.1']\n+ 'rsa==3.1.2']\n \n if sys.version_info[:2] == (2, 6):\n # For python2.6 we have ... | 1,043 | 115 |
gh_patches_debug_7073 | rasdani/github-patches | git_diff | pre-commit__pre-commit-287 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Make pre-commit consider a hook as "failed" if it modifies files and still (incorrectly?) exits 0
This would allow us to ditch autopep8-wrapper and support a bunch of hooks which refused to be scriptable (yap... | diff --git a/pre_commit/commands/run.py b/pre_commit/commands/run.py
--- a/pre_commit/commands/run.py
+++ b/pre_commit/commands/run.py
@@ -85,7 +85,13 @@
write(get_hook_message(_hook_msg_start(hook, args.verbose), end_len=6))
sys.stdout.flush()
+ diff_before = cmd_output('git', 'diff', retcode=None)
... | {"golden_diff": "diff --git a/pre_commit/commands/run.py b/pre_commit/commands/run.py\n--- a/pre_commit/commands/run.py\n+++ b/pre_commit/commands/run.py\n@@ -85,7 +85,13 @@\n write(get_hook_message(_hook_msg_start(hook, args.verbose), end_len=6))\n sys.stdout.flush()\n \n+ diff_before = cmd_output('git', 'd... | 2,230 | 168 |
gh_patches_debug_8933 | rasdani/github-patches | git_diff | akvo__akvo-rsr-1945 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Public projects filter in REST API not working correctly
## Test plan
All projects (and other objects) should be displayed in the REST API.
## Issue description
As a quick fix, just display all projects (pu... | diff --git a/akvo/rest/viewsets.py b/akvo/rest/viewsets.py
--- a/akvo/rest/viewsets.py
+++ b/akvo/rest/viewsets.py
@@ -23,11 +23,3 @@
permission_classes = (DjangoObjectPermissions, )
filter_backends = (filters.DjangoFilterBackend, filters.OrderingFilter, )
ordering_fields = '__all__'
-
- def get_query... | {"golden_diff": "diff --git a/akvo/rest/viewsets.py b/akvo/rest/viewsets.py\n--- a/akvo/rest/viewsets.py\n+++ b/akvo/rest/viewsets.py\n@@ -23,11 +23,3 @@\n permission_classes = (DjangoObjectPermissions, )\n filter_backends = (filters.DjangoFilterBackend, filters.OrderingFilter, )\n ordering_fields = '__all_... | 658 | 167 |
gh_patches_debug_15907 | rasdani/github-patches | git_diff | pwr-Solaar__Solaar-2286 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
PNG icons installed as scalable icons
The 1.1.11 pre-releases install various PNG icons in `/usr/share/icons/hicolor/scalable/apps/`, but the `scalable` hierarchy is reserved for scalable (SVG) icons.
--- EN... | diff --git a/lib/solaar/ui/icons.py b/lib/solaar/ui/icons.py
--- a/lib/solaar/ui/icons.py
+++ b/lib/solaar/ui/icons.py
@@ -101,7 +101,7 @@
def lux(level=None):
if level is None or level < 0:
return 'light_unknown'
- return 'light_%03d' % (20 * ((level + 50) // 100))
+ return 'solaar-light_%03d' % (... | {"golden_diff": "diff --git a/lib/solaar/ui/icons.py b/lib/solaar/ui/icons.py\n--- a/lib/solaar/ui/icons.py\n+++ b/lib/solaar/ui/icons.py\n@@ -101,7 +101,7 @@\n def lux(level=None):\n if level is None or level < 0:\n return 'light_unknown'\n- return 'light_%03d' % (20 * ((level + 50) // 100))\n+ retur... | 3,287 | 288 |
gh_patches_debug_725 | rasdani/github-patches | git_diff | rasterio__rasterio-1477 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Python crashes while building overviews
After performing the below code Python crashes:
```python
import rasterio
from rasterio.enums import Resampling
factors = [2, 4, 8, 16, 32, 64, 128, 256, 512, 1... | diff --git a/rasterio/errors.py b/rasterio/errors.py
--- a/rasterio/errors.py
+++ b/rasterio/errors.py
@@ -98,3 +98,7 @@
class UnsupportedOperation(RasterioError):
"""Raised when reading from a file opened in 'w' mode"""
+
+
+class OverviewCreationError(RasterioError):
+ """Raised when creation of an overvie... | {"golden_diff": "diff --git a/rasterio/errors.py b/rasterio/errors.py\n--- a/rasterio/errors.py\n+++ b/rasterio/errors.py\n@@ -98,3 +98,7 @@\n \n class UnsupportedOperation(RasterioError):\n \"\"\"Raised when reading from a file opened in 'w' mode\"\"\"\n+\n+\n+class OverviewCreationError(RasterioError):\n+ \"\"... | 1,939 | 91 |
gh_patches_debug_28841 | rasdani/github-patches | git_diff | ManimCommunity__manim-2567 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Renderer only uses one rendering mode for all Scenes in a file
## Description of bug / unexpected behavior
<!-- Add a clear and concise description of the problem you encountered. -->
When running `manim ... | diff --git a/manim/cli/render/commands.py b/manim/cli/render/commands.py
--- a/manim/cli/render/commands.py
+++ b/manim/cli/render/commands.py
@@ -16,6 +16,7 @@
import requests
from ... import __version__, config, console, error_console, logger
+from ..._config import tempconfig
from ...constants import EPILOG
fr... | {"golden_diff": "diff --git a/manim/cli/render/commands.py b/manim/cli/render/commands.py\n--- a/manim/cli/render/commands.py\n+++ b/manim/cli/render/commands.py\n@@ -16,6 +16,7 @@\n import requests\n \n from ... import __version__, config, console, error_console, logger\n+from ..._config import tempconfig\n from ...co... | 2,211 | 283 |
gh_patches_debug_22804 | rasdani/github-patches | git_diff | pypi__warehouse-4184 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Expose project_urls in JSON API
https://packaging.python.org/tutorials/distributing-packages/#project-urls
Related to #3798 / #3820
I realized project_urls is not currently exposed by the JSON API. I pr... | diff --git a/warehouse/legacy/api/json.py b/warehouse/legacy/api/json.py
--- a/warehouse/legacy/api/json.py
+++ b/warehouse/legacy/api/json.py
@@ -10,6 +10,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.
+from collections import OrderedDict
+
from pyramid... | {"golden_diff": "diff --git a/warehouse/legacy/api/json.py b/warehouse/legacy/api/json.py\n--- a/warehouse/legacy/api/json.py\n+++ b/warehouse/legacy/api/json.py\n@@ -10,6 +10,8 @@\n # See the License for the specific language governing permissions and\n # limitations under the License.\n \n+from collections import Ord... | 2,332 | 224 |
gh_patches_debug_8018 | rasdani/github-patches | git_diff | kymatio__kymatio-289 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
DOC 3D benchmarks
Currently none are listed in the user's guide. We should probably include something here.
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these fi... | diff --git a/kymatio/scattering2d/scattering2d.py b/kymatio/scattering2d/scattering2d.py
--- a/kymatio/scattering2d/scattering2d.py
+++ b/kymatio/scattering2d/scattering2d.py
@@ -34,9 +34,9 @@
Example
-------
# 1) Define a Scattering object as:
- s = Scattering2D(J, M, N)
+ s = Scatteri... | {"golden_diff": "diff --git a/kymatio/scattering2d/scattering2d.py b/kymatio/scattering2d/scattering2d.py\n--- a/kymatio/scattering2d/scattering2d.py\n+++ b/kymatio/scattering2d/scattering2d.py\n@@ -34,9 +34,9 @@\n Example\n -------\n # 1) Define a Scattering object as:\n- s = Scattering2D(J, M, ... | 3,090 | 203 |
gh_patches_debug_31934 | rasdani/github-patches | git_diff | mlflow__mlflow-1800 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[BUG] HdfsArtifactRepository list_artifacts recursively lists all items under directory
Thank you for submitting an issue. Please refer to our [issue policy](https://www.github.com/mlflow/mlflow/blob/master/I... | diff --git a/mlflow/store/hdfs_artifact_repo.py b/mlflow/store/hdfs_artifact_repo.py
--- a/mlflow/store/hdfs_artifact_repo.py
+++ b/mlflow/store/hdfs_artifact_repo.py
@@ -74,17 +74,21 @@
:param path: Relative source path. Possible subdirectory existing under
hdfs:/some/path/run_... | {"golden_diff": "diff --git a/mlflow/store/hdfs_artifact_repo.py b/mlflow/store/hdfs_artifact_repo.py\n--- a/mlflow/store/hdfs_artifact_repo.py\n+++ b/mlflow/store/hdfs_artifact_repo.py\n@@ -74,17 +74,21 @@\n \n :param path: Relative source path. Possible subdirectory existing under\n ... | 3,160 | 474 |
gh_patches_debug_13127 | rasdani/github-patches | git_diff | GoogleCloudPlatform__PerfKitBenchmarker-680 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
silo benchmark fails behind proxy
From @mateusz-blaszkowski in #475:
> silo - failed with Clone of 'git://github.com/kohler/masstree-beta.git' into submodule path 'masstree' failed. I run the test behind th... | diff --git a/perfkitbenchmarker/linux_packages/silo.py b/perfkitbenchmarker/linux_packages/silo.py
--- a/perfkitbenchmarker/linux_packages/silo.py
+++ b/perfkitbenchmarker/linux_packages/silo.py
@@ -33,6 +33,9 @@
vm.RemoteCommand('git clone {0} {1}'.format(GIT_REPO, SILO_DIR))
vm.RemoteCommand('cd {0} && git chec... | {"golden_diff": "diff --git a/perfkitbenchmarker/linux_packages/silo.py b/perfkitbenchmarker/linux_packages/silo.py\n--- a/perfkitbenchmarker/linux_packages/silo.py\n+++ b/perfkitbenchmarker/linux_packages/silo.py\n@@ -33,6 +33,9 @@\n vm.RemoteCommand('git clone {0} {1}'.format(GIT_REPO, SILO_DIR))\n vm.RemoteComma... | 1,051 | 206 |
gh_patches_debug_9322 | rasdani/github-patches | git_diff | cobbler__cobbler-3507 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
cobbler import rsync fails from mounted ISO media with SELinux enabled with return code 23
### Describe the bug
When you mount an ISO image - the permissions of the mounted files are read only:
```
# ls ... | diff --git a/cobbler/actions/importer.py b/cobbler/actions/importer.py
--- a/cobbler/actions/importer.py
+++ b/cobbler/actions/importer.py
@@ -106,7 +106,8 @@
spacer = ""
if not mirror_url.startswith("rsync://") and not mirror_url.startswith("/"):
spacer = ' -e "ssh" '
- rsync_cmd ... | {"golden_diff": "diff --git a/cobbler/actions/importer.py b/cobbler/actions/importer.py\n--- a/cobbler/actions/importer.py\n+++ b/cobbler/actions/importer.py\n@@ -106,7 +106,8 @@\n spacer = \"\"\n if not mirror_url.startswith(\"rsync://\") and not mirror_url.startswith(\"/\"):\n spacer = ' -... | 3,761 | 168 |
gh_patches_debug_791 | rasdani/github-patches | git_diff | mlcommons__GaNDLF-753 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
All training is failing with a `timm` error
**Describe the bug**
Unable to train on current master.
**To Reproduce**
Steps to reproduce the behavior:
1. Try to start any segmentation training.
2. See e... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -110,7 +110,7 @@
"pydicom",
"onnx",
"torchinfo==1.7.0",
- "segmentation-models-pytorch==0.3.2",
+ "segmentation-models-pytorch==0.3.3",
"ACSConv==0.1.1",
"docker",
"dicom-anonymizer",
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -110,7 +110,7 @@\n \"pydicom\",\n \"onnx\",\n \"torchinfo==1.7.0\",\n- \"segmentation-models-pytorch==0.3.2\",\n+ \"segmentation-models-pytorch==0.3.3\",\n \"ACSConv==0.1.1\",\n \"docker\",\n \"dicom-anon... | 3,064 | 113 |
gh_patches_debug_27124 | rasdani/github-patches | git_diff | chainer__chainer-6807 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
F.mean_absolute_error numerically unstable with float16 arrays
In #5053, float16 support has been enabled for [F.mean_absolute_error](https://github.com/chainer/chainer/blob/master/chainer/functions/loss/mean... | diff --git a/chainer/functions/loss/mean_absolute_error.py b/chainer/functions/loss/mean_absolute_error.py
--- a/chainer/functions/loss/mean_absolute_error.py
+++ b/chainer/functions/loss/mean_absolute_error.py
@@ -6,6 +6,15 @@
from chainer.utils import type_check
+def _get_intermediate_dtype(dtype):
+ # Return... | {"golden_diff": "diff --git a/chainer/functions/loss/mean_absolute_error.py b/chainer/functions/loss/mean_absolute_error.py\n--- a/chainer/functions/loss/mean_absolute_error.py\n+++ b/chainer/functions/loss/mean_absolute_error.py\n@@ -6,6 +6,15 @@\n from chainer.utils import type_check\n \n \n+def _get_intermediate_dty... | 2,017 | 413 |
gh_patches_debug_32491 | rasdani/github-patches | git_diff | openai__gym-1573 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Support wrapper transformations to VecEnv
@tristandeleu @pzhokhov @christopherhesse It might be rather convenient for the user experience to provide a list of wrapper transformations for the atomic environmen... | diff --git a/gym/vector/__init__.py b/gym/vector/__init__.py
--- a/gym/vector/__init__.py
+++ b/gym/vector/__init__.py
@@ -1,10 +1,15 @@
+try:
+ from collections.abc import Iterable
+except ImportError:
+ Iterable = (tuple, list)
+
from gym.vector.async_vector_env import AsyncVectorEnv
from gym.vector.sync_vect... | {"golden_diff": "diff --git a/gym/vector/__init__.py b/gym/vector/__init__.py\n--- a/gym/vector/__init__.py\n+++ b/gym/vector/__init__.py\n@@ -1,10 +1,15 @@\n+try:\n+ from collections.abc import Iterable\n+except ImportError:\n+ Iterable = (tuple, list)\n+\n from gym.vector.async_vector_env import AsyncVectorEnv\... | 938 | 449 |
gh_patches_debug_24975 | rasdani/github-patches | git_diff | streamlit__streamlit-7033 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Using help param causes use_container_width to be ignored with st.button for version 1.18
### Checklist
- [X] I have searched the [existing issues](https://github.com/streamlit/streamlit/issues) for simila... | diff --git a/e2e/scripts/st_button.py b/e2e/scripts/st_button.py
--- a/e2e/scripts/st_button.py
+++ b/e2e/scripts/st_button.py
@@ -51,7 +51,11 @@
i5 = st.button("button 4", type="primary", disabled=True)
st.write("value 4:", i5)
-st.button("button 5", use_container_width=True)
+st.button("button 5 - containerWidth"... | {"golden_diff": "diff --git a/e2e/scripts/st_button.py b/e2e/scripts/st_button.py\n--- a/e2e/scripts/st_button.py\n+++ b/e2e/scripts/st_button.py\n@@ -51,7 +51,11 @@\n i5 = st.button(\"button 4\", type=\"primary\", disabled=True)\n st.write(\"value 4:\", i5)\n \n-st.button(\"button 5\", use_container_width=True)\n+st.b... | 2,151 | 477 |
gh_patches_debug_17234 | rasdani/github-patches | git_diff | Lightning-Universe__lightning-flash-1164 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
TabularForecastingData must include predict_data_frame
## 📚 Documentation
The [NBEATS tutorial](https://lightning-flash.readthedocs.io/en/stable/notebooks/flash_tutorials/electricity_forecasting.html) use... | diff --git a/docs/source/conf.py b/docs/source/conf.py
--- a/docs/source/conf.py
+++ b/docs/source/conf.py
@@ -28,7 +28,7 @@
_SHOULD_COPY_NOTEBOOKS = True
try:
- from helpers import HelperCLI
+ from assistant import AssistantCLI
except Exception:
_SHOULD_COPY_NOTEBOOKS = False
warnings.warn("To bui... | {"golden_diff": "diff --git a/docs/source/conf.py b/docs/source/conf.py\n--- a/docs/source/conf.py\n+++ b/docs/source/conf.py\n@@ -28,7 +28,7 @@\n _SHOULD_COPY_NOTEBOOKS = True\n \n try:\n- from helpers import HelperCLI\n+ from assistant import AssistantCLI\n except Exception:\n _SHOULD_COPY_NOTEBOOKS = False... | 3,585 | 208 |
gh_patches_debug_33159 | rasdani/github-patches | git_diff | kubeflow__pipelines-6054 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[v2compat] re-evaluate execution custom properties schema
* [ ] rename task execution `task_name` to `display_name`?
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of... | diff --git a/sdk/python/kfp/compiler/_default_transformers.py b/sdk/python/kfp/compiler/_default_transformers.py
--- a/sdk/python/kfp/compiler/_default_transformers.py
+++ b/sdk/python/kfp/compiler/_default_transformers.py
@@ -41,6 +41,11 @@
value_from=k8s_client.V1EnvVarSource(
... | {"golden_diff": "diff --git a/sdk/python/kfp/compiler/_default_transformers.py b/sdk/python/kfp/compiler/_default_transformers.py\n--- a/sdk/python/kfp/compiler/_default_transformers.py\n+++ b/sdk/python/kfp/compiler/_default_transformers.py\n@@ -41,6 +41,11 @@\n value_from=k8s_client.V1EnvVar... | 3,107 | 530 |
gh_patches_debug_12946 | rasdani/github-patches | git_diff | awslabs__gluonts-1884 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
DeepAR with NegativeBinomial cannot generate values above 1e6
## Description
A DeepAR model with NegativeBinomial output distribution cannot generate values significantly above 1e6.
## To Reproduce
I att... | diff --git a/src/gluonts/mx/distribution/neg_binomial.py b/src/gluonts/mx/distribution/neg_binomial.py
--- a/src/gluonts/mx/distribution/neg_binomial.py
+++ b/src/gluonts/mx/distribution/neg_binomial.py
@@ -87,13 +87,9 @@
) -> Tensor:
def s(mu: Tensor, alpha: Tensor) -> Tensor:
F = self.F
- ... | {"golden_diff": "diff --git a/src/gluonts/mx/distribution/neg_binomial.py b/src/gluonts/mx/distribution/neg_binomial.py\n--- a/src/gluonts/mx/distribution/neg_binomial.py\n+++ b/src/gluonts/mx/distribution/neg_binomial.py\n@@ -87,13 +87,9 @@\n ) -> Tensor:\n def s(mu: Tensor, alpha: Tensor) -> Tensor:\n ... | 1,978 | 247 |
gh_patches_debug_16813 | rasdani/github-patches | git_diff | nautobot__nautobot-5593 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Plugins not loaded with Gunicorn
### Environment
* Nautobot version (Docker tag too if applicable): 2.2.1
* Python version: 3.11
* Database platform, version: psql
* Middleware(s):
### Steps to R... | diff --git a/nautobot/core/wsgi.py b/nautobot/core/wsgi.py
--- a/nautobot/core/wsgi.py
+++ b/nautobot/core/wsgi.py
@@ -1,11 +1,18 @@
import logging
-import os
from django.core import cache
from django.core.wsgi import get_wsgi_application
from django.db import connections
-os.environ["DJANGO_SETTINGS_MODULE"] =... | {"golden_diff": "diff --git a/nautobot/core/wsgi.py b/nautobot/core/wsgi.py\n--- a/nautobot/core/wsgi.py\n+++ b/nautobot/core/wsgi.py\n@@ -1,11 +1,18 @@\n import logging\n-import os\n \n from django.core import cache\n from django.core.wsgi import get_wsgi_application\n from django.db import connections\n \n-os.environ... | 779 | 239 |
gh_patches_debug_22558 | rasdani/github-patches | git_diff | sublimelsp__LSP-925 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Forced-break in hover popup can break syntax highlighting
Using: OSX / typescript-language-server
Line-break, that LSP forces in the popup, can cause syntax highlighting to break. For example, if breaking ... | diff --git a/plugin/hover.py b/plugin/hover.py
--- a/plugin/hover.py
+++ b/plugin/hover.py
@@ -3,7 +3,6 @@
import sublime_plugin
import webbrowser
import os
-import textwrap
from html import escape
from .code_actions import actions_manager, run_code_action_or_command
from .code_actions import CodeActionOrCommand
... | {"golden_diff": "diff --git a/plugin/hover.py b/plugin/hover.py\n--- a/plugin/hover.py\n+++ b/plugin/hover.py\n@@ -3,7 +3,6 @@\n import sublime_plugin\n import webbrowser\n import os\n-import textwrap\n from html import escape\n from .code_actions import actions_manager, run_code_action_or_command\n from .code_actions ... | 3,507 | 243 |
gh_patches_debug_41200 | rasdani/github-patches | git_diff | mindee__doctr-107 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[Models] Add SAR teacher forçing during training (decoder)
Teacher forçing (feeding the LSTM decoder of SAR with ground-truth characters during training) is not implemented, and it should really improve perfo... | diff --git a/doctr/models/recognition/sar.py b/doctr/models/recognition/sar.py
--- a/doctr/models/recognition/sar.py
+++ b/doctr/models/recognition/sar.py
@@ -89,7 +89,6 @@
attention_units: number of hidden attention units
num_decoder_layers: number of LSTM layers to stack
-
"""
def __init... | {"golden_diff": "diff --git a/doctr/models/recognition/sar.py b/doctr/models/recognition/sar.py\n--- a/doctr/models/recognition/sar.py\n+++ b/doctr/models/recognition/sar.py\n@@ -89,7 +89,6 @@\n attention_units: number of hidden attention units\n num_decoder_layers: number of LSTM layers to stack\n \n-\... | 3,895 | 702 |
gh_patches_debug_3475 | rasdani/github-patches | git_diff | ckan__ckan-7033 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
IConfigurer plugin load order
**CKAN version**
(all)
**Describe the bug**
`update_config` runs through all IConfigurer plugins from first to last calling `plugin.update_config`. The pattern for other int... | diff --git a/ckan/config/environment.py b/ckan/config/environment.py
--- a/ckan/config/environment.py
+++ b/ckan/config/environment.py
@@ -115,7 +115,7 @@
webassets_init()
- for plugin in p.PluginImplementations(p.IConfigurer):
+ for plugin in reversed(list(p.PluginImplementations(p.IConfigurer))):
... | {"golden_diff": "diff --git a/ckan/config/environment.py b/ckan/config/environment.py\n--- a/ckan/config/environment.py\n+++ b/ckan/config/environment.py\n@@ -115,7 +115,7 @@\n \n webassets_init()\n \n- for plugin in p.PluginImplementations(p.IConfigurer):\n+ for plugin in reversed(list(p.PluginImplementation... | 2,865 | 113 |
gh_patches_debug_12067 | rasdani/github-patches | git_diff | sktime__sktime-1453 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[BUG] sktime.datatypes._panel._examples raises pandas.core.common.SettingWithCopyError
**Describe the bug**
Attempting to install [tsai](https://pypi.org/project/tsai/) as an upstream package also installs t... | diff --git a/sktime/datatypes/_panel/_examples.py b/sktime/datatypes/_panel/_examples.py
--- a/sktime/datatypes/_panel/_examples.py
+++ b/sktime/datatypes/_panel/_examples.py
@@ -64,12 +64,13 @@
cols = [f"var_{i}" for i in range(2)]
X = pd.DataFrame(columns=cols, index=[0, 1, 2])
-X.iloc[0][0] = pd.Series([1, 2, 3]... | {"golden_diff": "diff --git a/sktime/datatypes/_panel/_examples.py b/sktime/datatypes/_panel/_examples.py\n--- a/sktime/datatypes/_panel/_examples.py\n+++ b/sktime/datatypes/_panel/_examples.py\n@@ -64,12 +64,13 @@\n \n cols = [f\"var_{i}\" for i in range(2)]\n X = pd.DataFrame(columns=cols, index=[0, 1, 2])\n-X.iloc[0... | 1,755 | 355 |
gh_patches_debug_319 | rasdani/github-patches | git_diff | pwr-Solaar__Solaar-730 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
better identification of Solaar versions
`git describe` produces
0.9.2-339-g39791be
Instead it should produce something based on 1.0.1
`git describe --tags` produces
1.0.1-58-g39791be
which is much bette... | diff --git a/lib/solaar/__init__.py b/lib/solaar/__init__.py
--- a/lib/solaar/__init__.py
+++ b/lib/solaar/__init__.py
@@ -19,5 +19,5 @@
from __future__ import absolute_import, division, print_function, unicode_literals
-__version__ = '1.0.1'
+__version__ = '1.0.2-rc1'
NAME = 'Solaar'
| {"golden_diff": "diff --git a/lib/solaar/__init__.py b/lib/solaar/__init__.py\n--- a/lib/solaar/__init__.py\n+++ b/lib/solaar/__init__.py\n@@ -19,5 +19,5 @@\n \n from __future__ import absolute_import, division, print_function, unicode_literals\n \n-__version__ = '1.0.1'\n+__version__ = '1.0.2-rc1'\n NAME = 'Solaar'\n"... | 632 | 107 |
gh_patches_debug_9857 | rasdani/github-patches | git_diff | saulpw__visidata-2160 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[parquet] can't load parquet directory anymore: `IsADirectoryError`
**Small description**
Hi @saulpw @anjakefala @takacsd - it seems that forcing opening the path as file with `.open()` - introduced with #... | diff --git a/visidata/loaders/parquet.py b/visidata/loaders/parquet.py
--- a/visidata/loaders/parquet.py
+++ b/visidata/loaders/parquet.py
@@ -23,8 +23,11 @@
pq = vd.importExternal("pyarrow.parquet", "pyarrow")
from visidata.loaders.arrow import arrow_to_vdtype
- with self.source.open('rb') a... | {"golden_diff": "diff --git a/visidata/loaders/parquet.py b/visidata/loaders/parquet.py\n--- a/visidata/loaders/parquet.py\n+++ b/visidata/loaders/parquet.py\n@@ -23,8 +23,11 @@\n pq = vd.importExternal(\"pyarrow.parquet\", \"pyarrow\")\n from visidata.loaders.arrow import arrow_to_vdtype\n \n- w... | 1,415 | 182 |
gh_patches_debug_33730 | rasdani/github-patches | git_diff | sonic-net__sonic-mgmt-1253 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Docker shell module failed in the latest sonic-mgmt
<!--
If you are reporting a new issue, make sure that we do not have any duplicates
already open. You can ensure this by searching the issue list for this... | diff --git a/ansible/shell_plugins/docker.py b/ansible/shell_plugins/docker.py
--- a/ansible/shell_plugins/docker.py
+++ b/ansible/shell_plugins/docker.py
@@ -1,6 +1,17 @@
from __future__ import (absolute_import, division)
__metaclass__ = type
+DOCUMENTATION = '''
+name: docker
+plugin_type: shell
+short_descriptio... | {"golden_diff": "diff --git a/ansible/shell_plugins/docker.py b/ansible/shell_plugins/docker.py\n--- a/ansible/shell_plugins/docker.py\n+++ b/ansible/shell_plugins/docker.py\n@@ -1,6 +1,17 @@\n from __future__ import (absolute_import, division)\n __metaclass__ = type\n \n+DOCUMENTATION = '''\n+name: docker\n+plugin_typ... | 2,503 | 590 |
gh_patches_debug_22540 | rasdani/github-patches | git_diff | Kinto__kinto-1087 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Port Kinto for Pyramid 1.8
Pyramid 1.8 is breaking a number of things:
- BasicAuth authn policy
- pserve http_port config.
Right now it is still an alpha release but it gets installed on time to time.
... | diff --git a/kinto/core/__init__.py b/kinto/core/__init__.py
--- a/kinto/core/__init__.py
+++ b/kinto/core/__init__.py
@@ -20,7 +20,6 @@
# Module version, as defined in PEP-0396.
__version__ = pkg_resources.get_distribution('kinto').version # FIXME?
-
DEFAULT_SETTINGS = {
'backoff': None,
'batch_max_req... | {"golden_diff": "diff --git a/kinto/core/__init__.py b/kinto/core/__init__.py\n--- a/kinto/core/__init__.py\n+++ b/kinto/core/__init__.py\n@@ -20,7 +20,6 @@\n # Module version, as defined in PEP-0396.\n __version__ = pkg_resources.get_distribution('kinto').version # FIXME?\n \n-\n DEFAULT_SETTINGS = {\n 'backoff':... | 3,580 | 309 |
gh_patches_debug_43483 | rasdani/github-patches | git_diff | OpenCTI-Platform__connectors-2071 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
ESET connector causing runaway Redis memory consumption despite REDIS__TRIMMING=1000000
## Description
When enabling the `external-import/eset` connector with defaults (from `external-import/eset/docker-co... | diff --git a/external-import/eset/src/eset.py b/external-import/eset/src/eset.py
--- a/external-import/eset/src/eset.py
+++ b/external-import/eset/src/eset.py
@@ -11,7 +11,13 @@
import stix2
import yaml
from dateutil.parser import parse
-from pycti import OpenCTIConnectorHelper, Report, get_config_variable
+from pyc... | {"golden_diff": "diff --git a/external-import/eset/src/eset.py b/external-import/eset/src/eset.py\n--- a/external-import/eset/src/eset.py\n+++ b/external-import/eset/src/eset.py\n@@ -11,7 +11,13 @@\n import stix2\n import yaml\n from dateutil.parser import parse\n-from pycti import OpenCTIConnectorHelper, Report, get_c... | 4,005 | 833 |
gh_patches_debug_40687 | rasdani/github-patches | git_diff | facebookresearch__hydra-1545 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Support multirun partial failure in Nevergrad sweeper
Context here: https://github.com/facebookresearch/hydra/issues/1377
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or ... | diff --git a/plugins/hydra_nevergrad_sweeper/example/my_app.py b/plugins/hydra_nevergrad_sweeper/example/my_app.py
--- a/plugins/hydra_nevergrad_sweeper/example/my_app.py
+++ b/plugins/hydra_nevergrad_sweeper/example/my_app.py
@@ -21,6 +21,8 @@
log.info(
f"dummy_training(dropout={do:.3f}, lr={cfg.lr:.3f},... | {"golden_diff": "diff --git a/plugins/hydra_nevergrad_sweeper/example/my_app.py b/plugins/hydra_nevergrad_sweeper/example/my_app.py\n--- a/plugins/hydra_nevergrad_sweeper/example/my_app.py\n+++ b/plugins/hydra_nevergrad_sweeper/example/my_app.py\n@@ -21,6 +21,8 @@\n log.info(\n f\"dummy_training(dropout={do... | 3,404 | 930 |
gh_patches_debug_31784 | rasdani/github-patches | git_diff | opentensor__bittensor-1231 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
new_hotkey is listed twice under 'btcli --help' menu
new_hotkey is listed twice under 'btcli --help' menu
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these file... | diff --git a/bittensor/_cli/__init__.py b/bittensor/_cli/__init__.py
--- a/bittensor/_cli/__init__.py
+++ b/bittensor/_cli/__init__.py
@@ -59,11 +59,10 @@
return naka_CLI(config=config)
else:
return cli_impl.CLI( config = config)
-
- @staticmethod
- def config(args: List[str]... | {"golden_diff": "diff --git a/bittensor/_cli/__init__.py b/bittensor/_cli/__init__.py\n--- a/bittensor/_cli/__init__.py\n+++ b/bittensor/_cli/__init__.py\n@@ -59,11 +59,10 @@\n return naka_CLI(config=config)\n else:\n return cli_impl.CLI( config = config)\n-\n- @staticmethod \n- ... | 2,249 | 425 |
gh_patches_debug_17528 | rasdani/github-patches | git_diff | allegro__ralph-3222 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Table 'ralph_ng.transitions_transition' doesn't exist
when I follow the document to setup a develop environment, I met the error" default: django.db.utils.ProgrammingError: (1146, "Table 'ralph_ng.transitions... | diff --git a/src/ralph/lib/transitions/checks.py b/src/ralph/lib/transitions/checks.py
--- a/src/ralph/lib/transitions/checks.py
+++ b/src/ralph/lib/transitions/checks.py
@@ -1,9 +1,14 @@
+import logging
+
from django.core.checks import Error
-from django.db.utils import OperationalError
+from django.db.utils import D... | {"golden_diff": "diff --git a/src/ralph/lib/transitions/checks.py b/src/ralph/lib/transitions/checks.py\n--- a/src/ralph/lib/transitions/checks.py\n+++ b/src/ralph/lib/transitions/checks.py\n@@ -1,9 +1,14 @@\n+import logging\n+\n from django.core.checks import Error\n-from django.db.utils import OperationalError\n+from... | 926 | 202 |
gh_patches_debug_33816 | rasdani/github-patches | git_diff | marshmallow-code__webargs-464 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
RFC: Only accept delimited string in DelimitedList
`DelimitedList` accepts either a list or a delimited string (e.g. "foo,bar,baz").
I'd like to make it more strict by only accepting a delimited list. Rath... | diff --git a/src/webargs/fields.py b/src/webargs/fields.py
--- a/src/webargs/fields.py
+++ b/src/webargs/fields.py
@@ -44,37 +44,35 @@
class DelimitedList(ma.fields.List):
- """Same as `marshmallow.fields.List`, except can load from either a list or
- a delimited string (e.g. "foo,bar,baz").
+ """A field ... | {"golden_diff": "diff --git a/src/webargs/fields.py b/src/webargs/fields.py\n--- a/src/webargs/fields.py\n+++ b/src/webargs/fields.py\n@@ -44,37 +44,35 @@\n \n \n class DelimitedList(ma.fields.List):\n- \"\"\"Same as `marshmallow.fields.List`, except can load from either a list or\n- a delimited string (e.g. \"fo... | 1,162 | 565 |
gh_patches_debug_16085 | rasdani/github-patches | git_diff | mathesar-foundation__mathesar-508 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Create canonical ordering for tables and return it by default
## Problem
<!-- Please provide a clear and concise description of the problem that this feature request is designed to solve.-->
We should have ... | diff --git a/db/records.py b/db/records.py
--- a/db/records.py
+++ b/db/records.py
@@ -72,6 +72,17 @@
field, in addition to an 'value' field if appropriate.
See: https://github.com/centerofci/sqlalchemy-filters#filters-format
"""
+ if not order_by:
+ # Set default or... | {"golden_diff": "diff --git a/db/records.py b/db/records.py\n--- a/db/records.py\n+++ b/db/records.py\n@@ -72,6 +72,17 @@\n field, in addition to an 'value' field if appropriate.\n See: https://github.com/centerofci/sqlalchemy-filters#filters-format\n \"\"\"\n+ if not order_by... | 3,167 | 218 |
gh_patches_debug_49452 | rasdani/github-patches | git_diff | wagtail__wagtail-840 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Paginator and search pagination expect different parameters for page
The Paginator (as in `django.core.paginator`) used pretty much everywhere uses `page` as the query parameter. The search view, however, [ex... | diff --git a/wagtail/wagtailsearch/views/frontend.py b/wagtail/wagtailsearch/views/frontend.py
--- a/wagtail/wagtailsearch/views/frontend.py
+++ b/wagtail/wagtailsearch/views/frontend.py
@@ -37,7 +37,7 @@
# Get query string and page from GET paramters
query_string = request.GET.get('q', '')
- page = requ... | {"golden_diff": "diff --git a/wagtail/wagtailsearch/views/frontend.py b/wagtail/wagtailsearch/views/frontend.py\n--- a/wagtail/wagtailsearch/views/frontend.py\n+++ b/wagtail/wagtailsearch/views/frontend.py\n@@ -37,7 +37,7 @@\n \n # Get query string and page from GET paramters\n query_string = request.GET.get('q... | 1,166 | 131 |
gh_patches_debug_10307 | rasdani/github-patches | git_diff | getnikola__nikola-2238 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
deploy crashes with state system
Will investigate later.
``` pytb
Traceback (most recent call last):
File "/home/kwpolska/virtualenvs/nikola-py3/lib/python3.5/site-packages/doit/doit_cmd.py", line 168, in ... | diff --git a/nikola/state.py b/nikola/state.py
--- a/nikola/state.py
+++ b/nikola/state.py
@@ -78,6 +78,11 @@
def _save(self):
dname = os.path.dirname(self._path)
with tempfile.NamedTemporaryFile(dir=dname, delete=False) as outf:
+ # TODO replace with encoding='utf-8' and mode 'w+' in ... | {"golden_diff": "diff --git a/nikola/state.py b/nikola/state.py\n--- a/nikola/state.py\n+++ b/nikola/state.py\n@@ -78,6 +78,11 @@\n def _save(self):\n dname = os.path.dirname(self._path)\n with tempfile.NamedTemporaryFile(dir=dname, delete=False) as outf:\n+ # TODO replace with encoding='... | 1,407 | 180 |
gh_patches_debug_29916 | rasdani/github-patches | git_diff | chainer__chainer-4738 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
F.bilinear requires huge GPU memory
The following code results `cupy.cuda.memory.OutOfMemoryError: out of memory to allocate 18014398509481984 bytes (total 18014399785863168 bytes)`
```
import chainer
impo... | diff --git a/chainer/functions/connection/bilinear.py b/chainer/functions/connection/bilinear.py
--- a/chainer/functions/connection/bilinear.py
+++ b/chainer/functions/connection/bilinear.py
@@ -80,7 +80,19 @@
W = inputs[2]
xp = cuda.get_array_module(*inputs)
- y = xp.einsum('ij,ik,jkl->il', ... | {"golden_diff": "diff --git a/chainer/functions/connection/bilinear.py b/chainer/functions/connection/bilinear.py\n--- a/chainer/functions/connection/bilinear.py\n+++ b/chainer/functions/connection/bilinear.py\n@@ -80,7 +80,19 @@\n W = inputs[2]\n \n xp = cuda.get_array_module(*inputs)\n- y = xp.... | 3,764 | 746 |
gh_patches_debug_40992 | rasdani/github-patches | git_diff | modin-project__modin-2701 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Implement usecols parameter for read_csv with OmniSci backend
**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. What kind of performan... | diff --git a/modin/experimental/engines/omnisci_on_ray/io.py b/modin/experimental/engines/omnisci_on_ray/io.py
--- a/modin/experimental/engines/omnisci_on_ray/io.py
+++ b/modin/experimental/engines/omnisci_on_ray/io.py
@@ -19,6 +19,9 @@
from pyarrow.csv import read_csv, ParseOptions, ConvertOptions, ReadOptions
impor... | {"golden_diff": "diff --git a/modin/experimental/engines/omnisci_on_ray/io.py b/modin/experimental/engines/omnisci_on_ray/io.py\n--- a/modin/experimental/engines/omnisci_on_ray/io.py\n+++ b/modin/experimental/engines/omnisci_on_ray/io.py\n@@ -19,6 +19,9 @@\n from pyarrow.csv import read_csv, ParseOptions, ConvertOption... | 2,469 | 790 |
gh_patches_debug_21053 | rasdani/github-patches | git_diff | zestedesavoir__zds-site-6083 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
API: filtrer les notifications par `is_read`
**Description du besoin**
Pour les besoins de l'extension, il serait intéressant de pouvoir filtrer les notifications (URL `/api/notifications`) selon leur prop... | diff --git a/zds/notification/api/views.py b/zds/notification/api/views.py
--- a/zds/notification/api/views.py
+++ b/zds/notification/api/views.py
@@ -84,6 +84,9 @@
- name: subscription_type
description: Filters by subscription type.
paramType: query
+ - name: is_re... | {"golden_diff": "diff --git a/zds/notification/api/views.py b/zds/notification/api/views.py\n--- a/zds/notification/api/views.py\n+++ b/zds/notification/api/views.py\n@@ -84,6 +84,9 @@\n - name: subscription_type\n description: Filters by subscription type.\n paramType: query\n+ ... | 1,503 | 225 |
gh_patches_debug_16446 | rasdani/github-patches | git_diff | mitmproxy__mitmproxy-2207 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Handle print() statements for inline scripts
print() statements in inline scripts should be suppressed, and produce into ctx.log.warn() calls instead.
--- END ISSUE ---
Below are some code segments, each ... | diff --git a/mitmproxy/addons/script.py b/mitmproxy/addons/script.py
--- a/mitmproxy/addons/script.py
+++ b/mitmproxy/addons/script.py
@@ -65,14 +65,28 @@
return tb
+class StreamLog:
+ """
+ A class for redirecting output using contextlib.
+ """
+ def __init__(self, log):
+ self.log ... | {"golden_diff": "diff --git a/mitmproxy/addons/script.py b/mitmproxy/addons/script.py\n--- a/mitmproxy/addons/script.py\n+++ b/mitmproxy/addons/script.py\n@@ -65,14 +65,28 @@\n return tb\n \n \n+class StreamLog:\n+ \"\"\"\n+ A class for redirecting output using contextlib.\n+ \"\"\"\n+ def __ini... | 2,957 | 232 |
gh_patches_debug_43858 | rasdani/github-patches | git_diff | litestar-org__litestar-3293 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Bug: route not recognized in schemas for specific types
### Description
Currently some parameters types don't show in the docs. It seems `int` works fine, while `str` and `uuid` don't.
This is silent, no ... | diff --git a/litestar/_openapi/path_item.py b/litestar/_openapi/path_item.py
--- a/litestar/_openapi/path_item.py
+++ b/litestar/_openapi/path_item.py
@@ -1,5 +1,6 @@
from __future__ import annotations
+import dataclasses
from inspect import cleandoc
from typing import TYPE_CHECKING
@@ -8,6 +9,7 @@
from litesta... | {"golden_diff": "diff --git a/litestar/_openapi/path_item.py b/litestar/_openapi/path_item.py\n--- a/litestar/_openapi/path_item.py\n+++ b/litestar/_openapi/path_item.py\n@@ -1,5 +1,6 @@\n from __future__ import annotations\n \n+import dataclasses\n from inspect import cleandoc\n from typing import TYPE_CHECKING\n \n@@... | 3,144 | 1,022 |
gh_patches_debug_21633 | rasdani/github-patches | git_diff | PyGithub__PyGithub-2439 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
v1.58.0 TypeError: create_jwt() got an unexpected keyword argument 'expiration'
The `expiration` keyword argument was removed in v1.58.0. The interface defined in GithubIntegration.pyi is no longer accurate. ... | diff --git a/github/GithubIntegration.py b/github/GithubIntegration.py
--- a/github/GithubIntegration.py
+++ b/github/GithubIntegration.py
@@ -90,17 +90,23 @@
completed=True,
)
- def create_jwt(self):
+ def create_jwt(self, expiration=None):
"""
Create a signed JWT
... | {"golden_diff": "diff --git a/github/GithubIntegration.py b/github/GithubIntegration.py\n--- a/github/GithubIntegration.py\n+++ b/github/GithubIntegration.py\n@@ -90,17 +90,23 @@\n completed=True,\n )\n \n- def create_jwt(self):\n+ def create_jwt(self, expiration=None):\n \"\"\"\n ... | 2,422 | 250 |
gh_patches_debug_8845 | rasdani/github-patches | git_diff | safe-global__safe-config-service-14 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Include provider info in the serialized response of `GET /safe-apps/`
The `/safe-apps` endpoint should include data about the provider if any
--- END ISSUE ---
Below are some code segments, each from a rele... | diff --git a/src/safe_apps/serializers.py b/src/safe_apps/serializers.py
--- a/src/safe_apps/serializers.py
+++ b/src/safe_apps/serializers.py
@@ -1,9 +1,17 @@
from rest_framework import serializers
-from .models import SafeApp
+from .models import SafeApp, Provider
+
+
+class ProviderSerializer(serializers.ModelSer... | {"golden_diff": "diff --git a/src/safe_apps/serializers.py b/src/safe_apps/serializers.py\n--- a/src/safe_apps/serializers.py\n+++ b/src/safe_apps/serializers.py\n@@ -1,9 +1,17 @@\n from rest_framework import serializers\n \n-from .models import SafeApp\n+from .models import SafeApp, Provider\n+\n+\n+class ProviderSeri... | 359 | 180 |
gh_patches_debug_29629 | rasdani/github-patches | git_diff | aio-libs__aiohttp-4556 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
GET Requests to link-local IPv6 addresses don't work on Python 3.7+
🐞 **Describe the bug**
The aiohttp resolver loses information related to linklocal IPv6 addresses on Python 3.7+ due to a changes in the r... | diff --git a/aiohttp/resolver.py b/aiohttp/resolver.py
--- a/aiohttp/resolver.py
+++ b/aiohttp/resolver.py
@@ -31,11 +31,23 @@
hosts = []
for family, _, proto, _, address in infos:
- hosts.append(
- {'hostname': host,
- 'host': address[0], 'port': address[1]... | {"golden_diff": "diff --git a/aiohttp/resolver.py b/aiohttp/resolver.py\n--- a/aiohttp/resolver.py\n+++ b/aiohttp/resolver.py\n@@ -31,11 +31,23 @@\n \n hosts = []\n for family, _, proto, _, address in infos:\n- hosts.append(\n- {'hostname': host,\n- 'host': addr... | 1,683 | 458 |
gh_patches_debug_4277 | rasdani/github-patches | git_diff | python-telegram-bot__python-telegram-bot-1086 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
send_photo file from disk doesn't seem to work on python2
### Steps to reproduce
1. https://github.com/python-telegram-bot/python-telegram-bot/wiki/Code-snippets#post-an-image-file-from-disk
2. I'm using... | diff --git a/telegram/files/inputfile.py b/telegram/files/inputfile.py
--- a/telegram/files/inputfile.py
+++ b/telegram/files/inputfile.py
@@ -86,6 +86,10 @@
else:
self.mimetype = DEFAULT_MIME_TYPE
+ if sys.version_info < (3,):
+ if isinstance(self.filename, uni... | {"golden_diff": "diff --git a/telegram/files/inputfile.py b/telegram/files/inputfile.py\n--- a/telegram/files/inputfile.py\n+++ b/telegram/files/inputfile.py\n@@ -86,6 +86,10 @@\n else:\n self.mimetype = DEFAULT_MIME_TYPE\n \n+ if sys.version_info < (3,):\n+ if isin... | 2,652 | 134 |
gh_patches_debug_29472 | rasdani/github-patches | git_diff | mathesar-foundation__mathesar-353 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Undesirable record grouping behaviours
## Description
Record grouping has a set of behaviours, that are not desirable.
* It considers order_by, which leads to formation of incorrect query on the backend, if... | diff --git a/db/records.py b/db/records.py
--- a/db/records.py
+++ b/db/records.py
@@ -96,10 +96,8 @@
if field_name not in table.c:
raise GroupFieldNotFound(f"Group field {field} not found in {table}.")
- group_by = _create_col_objects(table, group_by)
query = (
- select(*group_by... | {"golden_diff": "diff --git a/db/records.py b/db/records.py\n--- a/db/records.py\n+++ b/db/records.py\n@@ -96,10 +96,8 @@\n if field_name not in table.c:\n raise GroupFieldNotFound(f\"Group field {field} not found in {table}.\")\n \n- group_by = _create_col_objects(table, group_by)\n query = ... | 3,701 | 399 |
gh_patches_debug_22504 | rasdani/github-patches | git_diff | wright-group__WrightTools-360 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Windows Tempfile Error
On Windows, tempfiles attempted to be opened using h5py cause errors.
I do not have the error message in front of me at present, but I believe it was a 'file already exists' flavor o... | diff --git a/WrightTools/_base.py b/WrightTools/_base.py
--- a/WrightTools/_base.py
+++ b/WrightTools/_base.py
@@ -5,6 +5,7 @@
import shutil
+import os
import weakref
import tempfile
import posixpath
@@ -74,8 +75,8 @@
if edit_local and filepath is None:
raise Exception # TODO: better exce... | {"golden_diff": "diff --git a/WrightTools/_base.py b/WrightTools/_base.py\n--- a/WrightTools/_base.py\n+++ b/WrightTools/_base.py\n@@ -5,6 +5,7 @@\n \n \n import shutil\n+import os\n import weakref\n import tempfile\n import posixpath\n@@ -74,8 +75,8 @@\n if edit_local and filepath is None:\n raise ... | 1,615 | 247 |
gh_patches_debug_25508 | rasdani/github-patches | git_diff | strawberry-graphql__strawberry-728 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
UploadFile causes ASGI application's exception when it is in debug mode
Apparently when we use the ASGI application in debug mode, it cannot print the value of variables if they are not JSON serializable.
... | diff --git a/strawberry/utils/debug.py b/strawberry/utils/debug.py
--- a/strawberry/utils/debug.py
+++ b/strawberry/utils/debug.py
@@ -1,6 +1,7 @@
import datetime
import json
-import typing
+from json import JSONEncoder
+from typing import Any, Dict
from pygments import highlight, lexers
from pygments.formatters ... | {"golden_diff": "diff --git a/strawberry/utils/debug.py b/strawberry/utils/debug.py\n--- a/strawberry/utils/debug.py\n+++ b/strawberry/utils/debug.py\n@@ -1,6 +1,7 @@\n import datetime\n import json\n-import typing\n+from json import JSONEncoder\n+from typing import Any, Dict\n \n from pygments import highlight, lexers... | 683 | 317 |
gh_patches_debug_4565 | rasdani/github-patches | git_diff | pypa__setuptools-1591 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Impossible to install packages with setuptools v.40.6.x, if six isn't installed
Upgrade pip and setuptools to latest versions
```
oleg$ pip install --upgrade pip setuptools
Collecting pip
Using cached... | diff --git a/setuptools/command/upload.py b/setuptools/command/upload.py
--- a/setuptools/command/upload.py
+++ b/setuptools/command/upload.py
@@ -12,9 +12,9 @@
from distutils.errors import DistutilsError
-from six.moves.urllib.request import urlopen, Request
-from six.moves.urllib.error import HTTPError
-from six... | {"golden_diff": "diff --git a/setuptools/command/upload.py b/setuptools/command/upload.py\n--- a/setuptools/command/upload.py\n+++ b/setuptools/command/upload.py\n@@ -12,9 +12,9 @@\n \n from distutils.errors import DistutilsError\n \n-from six.moves.urllib.request import urlopen, Request\n-from six.moves.urllib.error i... | 3,633 | 135 |
gh_patches_debug_33721 | rasdani/github-patches | git_diff | docker__docker-py-1178 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Support create network EnableIPv6 and Labels options
Check the remote API:
https://docs.docker.com/engine/reference/api/docker_remote_api_v1.23/#create-a-network
There are two missing JSON parameters:
```
... | diff --git a/docker/api/network.py b/docker/api/network.py
--- a/docker/api/network.py
+++ b/docker/api/network.py
@@ -22,7 +22,8 @@
@minimum_version('1.21')
def create_network(self, name, driver=None, options=None, ipam=None,
- check_duplicate=None, internal=False):
+ ... | {"golden_diff": "diff --git a/docker/api/network.py b/docker/api/network.py\n--- a/docker/api/network.py\n+++ b/docker/api/network.py\n@@ -22,7 +22,8 @@\n \n @minimum_version('1.21')\n def create_network(self, name, driver=None, options=None, ipam=None,\n- check_duplicate=None, internal=Fa... | 1,142 | 480 |
gh_patches_debug_10767 | rasdani/github-patches | git_diff | horovod__horovod-853 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
'float' object has no attribute 'detach' in pytorch imagenet example.
I ran the [pytorch imagenet example](https://github.com/horovod/horovod/blob/master/examples/pytorch_imagenet_resnet50.py) but got an erro... | diff --git a/examples/pytorch_imagenet_resnet50.py b/examples/pytorch_imagenet_resnet50.py
--- a/examples/pytorch_imagenet_resnet50.py
+++ b/examples/pytorch_imagenet_resnet50.py
@@ -176,7 +176,7 @@
output = model(data_batch)
train_accuracy.update(accuracy(output, target_batch))
... | {"golden_diff": "diff --git a/examples/pytorch_imagenet_resnet50.py b/examples/pytorch_imagenet_resnet50.py\n--- a/examples/pytorch_imagenet_resnet50.py\n+++ b/examples/pytorch_imagenet_resnet50.py\n@@ -176,7 +176,7 @@\n output = model(data_batch)\n train_accuracy.update(accuracy(output,... | 3,843 | 142 |
gh_patches_debug_30024 | rasdani/github-patches | git_diff | vispy__vispy-2144 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add ability to pass "fpos" as a parameter to the ColorFilter
Hi all,
I am currently trying to use the ```ColorFilter``` (https://github.com/vispy/vispy/blob/main/vispy/visuals/filters/color.py) in a project ... | diff --git a/vispy/visuals/filters/color.py b/vispy/visuals/filters/color.py
--- a/vispy/visuals/filters/color.py
+++ b/vispy/visuals/filters/color.py
@@ -60,8 +60,8 @@
}
"""
- def __init__(self, level=2., width=2.0, antialias=1.0, color='black'):
- super(IsolineFilter, self).__init__(fcode=se... | {"golden_diff": "diff --git a/vispy/visuals/filters/color.py b/vispy/visuals/filters/color.py\n--- a/vispy/visuals/filters/color.py\n+++ b/vispy/visuals/filters/color.py\n@@ -60,8 +60,8 @@\n }\n \"\"\"\n \n- def __init__(self, level=2., width=2.0, antialias=1.0, color='black'):\n- super(IsolineFil... | 2,233 | 567 |
gh_patches_debug_40239 | rasdani/github-patches | git_diff | freedomofpress__securedrop-4914 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
securedrop-admin (setup) fails in Tails 4.0-rc1
## Description
Running `./securedrop-admin setup` in tails 4.0-rc1 (upgraded from 3.16) returns the following error:
```
INFO: Virtualenv already exists,... | diff --git a/admin/bootstrap.py b/admin/bootstrap.py
--- a/admin/bootstrap.py
+++ b/admin/bootstrap.py
@@ -20,6 +20,7 @@
import argparse
import logging
import os
+import shutil
import subprocess
import sys
@@ -68,13 +69,48 @@
id = None
# dirty hack to unreliably detect Tails 4.0~beta2
- if id ... | {"golden_diff": "diff --git a/admin/bootstrap.py b/admin/bootstrap.py\n--- a/admin/bootstrap.py\n+++ b/admin/bootstrap.py\n@@ -20,6 +20,7 @@\n import argparse\n import logging\n import os\n+import shutil\n import subprocess\n import sys\n \n@@ -68,13 +69,48 @@\n id = None\n \n # dirty hack to unreliably det... | 3,572 | 881 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.