problem_id stringlengths 18 22 | source stringclasses 1
value | task_type stringclasses 1
value | in_source_id stringlengths 13 58 | prompt stringlengths 1.1k 10.2k | golden_diff stringlengths 151 4.94k | verification_info stringlengths 582 21k | num_tokens int64 271 2.05k | num_tokens_diff int64 47 1.02k |
|---|---|---|---|---|---|---|---|---|
gh_patches_debug_24535 | rasdani/github-patches | git_diff | nvaccess__nvda-14588 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
in tabbed notepad when switching between tabs nvda should announce some way to differentiate between tabs
### Steps to reproduce:
download the new tabbed notepad.
now using the menu create a new tab
now ... | diff --git a/source/appModules/notepad.py b/source/appModules/notepad.py
--- a/source/appModules/notepad.py
+++ b/source/appModules/notepad.py
@@ -10,13 +10,38 @@
from comtypes import COMError
import appModuleHandler
import api
+import braille
+import controlTypes
+import eventHandler
+import speech
import UIAHandl... | {"golden_diff": "diff --git a/source/appModules/notepad.py b/source/appModules/notepad.py\n--- a/source/appModules/notepad.py\n+++ b/source/appModules/notepad.py\n@@ -10,13 +10,38 @@\n from comtypes import COMError\n import appModuleHandler\n import api\n+import braille\n+import controlTypes\n+import eventHandler\n+imp... | 1,524 | 364 |
gh_patches_debug_11669 | rasdani/github-patches | git_diff | scikit-hep__pyhf-960 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Documentation: meaning of value for return_fitted_val=True
# Description
In this code snippet from the documentation
```python
>>> pyhf.infer.mle.fixed_poi_fit(test_poi, data, model, return_fitted_val... | diff --git a/src/pyhf/infer/mle.py b/src/pyhf/infer/mle.py
--- a/src/pyhf/infer/mle.py
+++ b/src/pyhf/infer/mle.py
@@ -22,6 +22,10 @@
"""
Run a unconstrained maximum likelihood fit.
+ .. note::
+
+ :func:`twice_nll` is the objective function.
+
Example:
>>> import pyhf
>>> p... | {"golden_diff": "diff --git a/src/pyhf/infer/mle.py b/src/pyhf/infer/mle.py\n--- a/src/pyhf/infer/mle.py\n+++ b/src/pyhf/infer/mle.py\n@@ -22,6 +22,10 @@\n \"\"\"\n Run a unconstrained maximum likelihood fit.\n \n+ .. note::\n+\n+ :func:`twice_nll` is the objective function.\n+\n Example:\n ... | 1,645 | 178 |
gh_patches_debug_33534 | rasdani/github-patches | git_diff | mampfes__hacs_waste_collection_schedule-1673 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[Feature]: paper dates are not in the complete date-file
### I propose a feature for:
Sources
### Describe your wanted feature
Hi,
right now I saw that the homepage "https://www.geoport-nwm.de/de/ab... | diff --git a/custom_components/waste_collection_schedule/waste_collection_schedule/source/geoport_nwm_de.py b/custom_components/waste_collection_schedule/waste_collection_schedule/source/geoport_nwm_de.py
--- a/custom_components/waste_collection_schedule/waste_collection_schedule/source/geoport_nwm_de.py
+++ b/custom_c... | {"golden_diff": "diff --git a/custom_components/waste_collection_schedule/waste_collection_schedule/source/geoport_nwm_de.py b/custom_components/waste_collection_schedule/waste_collection_schedule/source/geoport_nwm_de.py\n--- a/custom_components/waste_collection_schedule/waste_collection_schedule/source/geoport_nwm_de... | 1,104 | 590 |
gh_patches_debug_19205 | rasdani/github-patches | git_diff | strawberry-graphql__strawberry-2205 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Move non-core dependencies to dedicated groups
@la4de has made a very useful playground for Strawberry, available (for now) here -> https://la4de.github.io/strawberry-playground/
Unfortunately some of the ... | diff --git a/strawberry/utils/debug.py b/strawberry/utils/debug.py
--- a/strawberry/utils/debug.py
+++ b/strawberry/utils/debug.py
@@ -3,11 +3,6 @@
from json import JSONEncoder
from typing import Any, Dict, Optional
-from pygments import highlight, lexers
-from pygments.formatters import Terminal256Formatter
-
-fro... | {"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@@ -3,11 +3,6 @@\n from json import JSONEncoder\n from typing import Any, Dict, Optional\n \n-from pygments import highlight, lexers\n-from pygments.formatters import Te... | 763 | 258 |
gh_patches_debug_478 | rasdani/github-patches | git_diff | fossasia__open-event-server-7579 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
test_multiple_heads is not raising the expected error
**Describe the bug**
<!-- A clear and concise description of what the bug is. -->
On having multiple heads, the travis build fails with error -
```
er... | diff --git a/migrations/versions/rev-2021-01-07-05:19:49-3b29ea38f0cb_.py b/migrations/versions/rev-2021-01-07-05:19:49-3b29ea38f0cb_.py
--- a/migrations/versions/rev-2021-01-07-05:19:49-3b29ea38f0cb_.py
+++ b/migrations/versions/rev-2021-01-07-05:19:49-3b29ea38f0cb_.py
@@ -13,7 +13,7 @@
# revision identifiers, used... | {"golden_diff": "diff --git a/migrations/versions/rev-2021-01-07-05:19:49-3b29ea38f0cb_.py b/migrations/versions/rev-2021-01-07-05:19:49-3b29ea38f0cb_.py\n--- a/migrations/versions/rev-2021-01-07-05:19:49-3b29ea38f0cb_.py\n+++ b/migrations/versions/rev-2021-01-07-05:19:49-3b29ea38f0cb_.py\n@@ -13,7 +13,7 @@\n \n # revi... | 778 | 243 |
gh_patches_debug_6175 | rasdani/github-patches | git_diff | google__fuzzbench-148 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[reports] Data.csv.gz don't need to contain id column
It has these columns because data.csv.gz contains data from a join query of snapshots on trials.
time_started and time_ended are from trials but they are... | diff --git a/analysis/queries.py b/analysis/queries.py
--- a/analysis/queries.py
+++ b/analysis/queries.py
@@ -26,4 +26,8 @@
sqlalchemy.orm.joinedload('trial')).filter(
models.Snapshot.trial.has(
models.Trial.experiment.in_(experiment_names)))
- return pd.read_sql_query(snapsho... | {"golden_diff": "diff --git a/analysis/queries.py b/analysis/queries.py\n--- a/analysis/queries.py\n+++ b/analysis/queries.py\n@@ -26,4 +26,8 @@\n sqlalchemy.orm.joinedload('trial')).filter(\n models.Snapshot.trial.has(\n models.Trial.experiment.in_(experiment_names)))\n- return p... | 620 | 150 |
gh_patches_debug_24520 | rasdani/github-patches | git_diff | scikit-image__scikit-image-4945 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
measure.label speed
This is triggered by [this Stackoverflow question](https://stackoverflow.com/questions/62804953/performance-differences-between-bwlabeln-on-matlab-and-skimage-measure-label-on/62842582#628... | diff --git a/skimage/measure/_label.py b/skimage/measure/_label.py
--- a/skimage/measure/_label.py
+++ b/skimage/measure/_label.py
@@ -1,6 +1,34 @@
+from scipy import ndimage
from ._ccomp import label_cython as clabel
+def _label_bool(image, background=None, return_num=False, connectivity=None):
+ """Faster imp... | {"golden_diff": "diff --git a/skimage/measure/_label.py b/skimage/measure/_label.py\n--- a/skimage/measure/_label.py\n+++ b/skimage/measure/_label.py\n@@ -1,6 +1,34 @@\n+from scipy import ndimage\n from ._ccomp import label_cython as clabel\n \n \n+def _label_bool(image, background=None, return_num=False, connectivity=... | 1,342 | 410 |
gh_patches_debug_26316 | rasdani/github-patches | git_diff | scikit-hep__pyhf-424 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Pin optional dependencies at the minor release level
# Description
To avoid having our prior releases break like `v0.0.15` did in Issue #396 it would be good to pin our optional dependencies at the minor r... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -12,18 +12,13 @@
extras_require = {
'tensorflow': [
- 'tensorflow>=1.12.0',
- 'tensorflow-probability>=0.5.0',
+ 'tensorflow~=1.13',
+ 'tensorflow-probability~=0.5',
'numpy<=1.14.5,>=1.14.0', # Lower of 1.14.... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -12,18 +12,13 @@\n \n extras_require = {\n 'tensorflow': [\n- 'tensorflow>=1.12.0',\n- 'tensorflow-probability>=0.5.0',\n+ 'tensorflow~=1.13',\n+ 'tensorflow-probability~=0.5',\n 'numpy<=1.14.5,... | 1,473 | 492 |
gh_patches_debug_17442 | rasdani/github-patches | git_diff | spacetelescope__jwql-857 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add code to manage.py to create necessesary symlinks to run web app locally
In order to run the JWQL web app locally, one must create symbolic links to the `outputs`, `thumbnails`, `preview_images`, and `fil... | diff --git a/jwql/website/manage.py b/jwql/website/manage.py
--- a/jwql/website/manage.py
+++ b/jwql/website/manage.py
@@ -36,10 +36,25 @@
import os
import sys
+from jwql.utils.utils import get_config
+
if __name__ == "__main__":
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "jwql_proj.settings")
+ d... | {"golden_diff": "diff --git a/jwql/website/manage.py b/jwql/website/manage.py\n--- a/jwql/website/manage.py\n+++ b/jwql/website/manage.py\n@@ -36,10 +36,25 @@\n import os\n import sys\n \n+from jwql.utils.utils import get_config\n+\n if __name__ == \"__main__\":\n \n os.environ.setdefault(\"DJANGO_SETTINGS_MODULE\"... | 900 | 255 |
gh_patches_debug_20691 | rasdani/github-patches | git_diff | ephios-dev__ephios-525 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Select2 on disposition view shows error alert
Closing the select2 field in the disposition view without selecting an entry (e.g. by typing something into the field an then clicking somewhere outside the field... | diff --git a/ephios/core/context.py b/ephios/core/context.py
--- a/ephios/core/context.py
+++ b/ephios/core/context.py
@@ -1,7 +1,6 @@
import importlib
from django.conf import settings
-from django.templatetags.static import static
from django.utils.translation import get_language
from ephios.core.models import... | {"golden_diff": "diff --git a/ephios/core/context.py b/ephios/core/context.py\n--- a/ephios/core/context.py\n+++ b/ephios/core/context.py\n@@ -1,7 +1,6 @@\n import importlib\n \n from django.conf import settings\n-from django.templatetags.static import static\n from django.utils.translation import get_language\n \n fro... | 617 | 232 |
gh_patches_debug_26734 | rasdani/github-patches | git_diff | kivy__kivy-4268 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
kivy/examples/android/takepicture/ fails on Android
Example cloned form GIT build with:
buildozer android debug
deployed to Android 4.4.4 crashes, from adb logcat output teh following lines seem to be relevan... | diff --git a/examples/android/takepicture/main.py b/examples/android/takepicture/main.py
--- a/examples/android/takepicture/main.py
+++ b/examples/android/takepicture/main.py
@@ -23,7 +23,7 @@
from kivy.app import App
from os.path import exists
from jnius import autoclass, cast
-from android import activity
+from an... | {"golden_diff": "diff --git a/examples/android/takepicture/main.py b/examples/android/takepicture/main.py\n--- a/examples/android/takepicture/main.py\n+++ b/examples/android/takepicture/main.py\n@@ -23,7 +23,7 @@\n from kivy.app import App\n from os.path import exists\n from jnius import autoclass, cast\n-from android ... | 1,194 | 286 |
gh_patches_debug_15821 | rasdani/github-patches | git_diff | crytic__slither-387 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
ABIEncoderV2 flagged as solidity version
The following Solidity code is flagged as being different solidity versions:
```sol
pragma solidity 0.5.12;
pragma experimental ABIEncoderV2;
```
Outputs:
... | diff --git a/slither/core/declarations/pragma_directive.py b/slither/core/declarations/pragma_directive.py
--- a/slither/core/declarations/pragma_directive.py
+++ b/slither/core/declarations/pragma_directive.py
@@ -21,5 +21,11 @@
def name(self):
return self.version
+ @property
+ def is_solidity_ve... | {"golden_diff": "diff --git a/slither/core/declarations/pragma_directive.py b/slither/core/declarations/pragma_directive.py\n--- a/slither/core/declarations/pragma_directive.py\n+++ b/slither/core/declarations/pragma_directive.py\n@@ -21,5 +21,11 @@\n def name(self):\n return self.version\n \n+ @property... | 999 | 294 |
gh_patches_debug_6765 | rasdani/github-patches | git_diff | conda-forge__conda-smithy-971 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Fix linter error on missing target_platform
Invoking `conda smithy recipe-lint` on the [conda-forge/go1.4-feedstock/meta.yaml](
https://github.com/conda-forge/go1.4-bootstrap-feedstock/blob/master/recipe/met... | diff --git a/conda_smithy/utils.py b/conda_smithy/utils.py
--- a/conda_smithy/utils.py
+++ b/conda_smithy/utils.py
@@ -44,6 +44,7 @@
defaultdict(lambda : ''),
datetime=datetime,
time=time,
+ target_... | {"golden_diff": "diff --git a/conda_smithy/utils.py b/conda_smithy/utils.py\n--- a/conda_smithy/utils.py\n+++ b/conda_smithy/utils.py\n@@ -44,6 +44,7 @@\n defaultdict(lambda : ''),\n datetime=datetime,\n time=time,\n+ ... | 1,181 | 104 |
gh_patches_debug_2928 | rasdani/github-patches | git_diff | ray-project__ray-3621 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[modin] Importing Modin before Ray can sometimes cause ImportError
### Describe the problem
<!-- Describe the problem clearly here. -->
When running Modin with Ray installed from source, I am sometimes ru... | diff --git a/python/ray/__init__.py b/python/ray/__init__.py
--- a/python/ray/__init__.py
+++ b/python/ray/__init__.py
@@ -47,7 +47,7 @@
raise
modin_path = os.path.join(os.path.abspath(os.path.dirname(__file__)), "modin")
-sys.path.insert(0, modin_path)
+sys.path.append(modin_path)
from ray.raylet import Obj... | {"golden_diff": "diff --git a/python/ray/__init__.py b/python/ray/__init__.py\n--- a/python/ray/__init__.py\n+++ b/python/ray/__init__.py\n@@ -47,7 +47,7 @@\n raise\n \n modin_path = os.path.join(os.path.abspath(os.path.dirname(__file__)), \"modin\")\n-sys.path.insert(0, modin_path)\n+sys.path.append(modin_path)\n ... | 1,639 | 131 |
gh_patches_debug_35781 | rasdani/github-patches | git_diff | sunpy__sunpy-5114 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Update "Masking out the solar disk" example to use maputils function
Example: https://docs.sunpy.org/en/stable/generated/gallery/computer_vision_techniques/mask_disk.html
Update to use `sunpy.map.coordinat... | diff --git a/examples/computer_vision_techniques/mask_disk.py b/examples/computer_vision_techniques/mask_disk.py
--- a/examples/computer_vision_techniques/mask_disk.py
+++ b/examples/computer_vision_techniques/mask_disk.py
@@ -6,12 +6,10 @@
How to mask out all emission from the solar disk.
"""
import matplotlib.pypl... | {"golden_diff": "diff --git a/examples/computer_vision_techniques/mask_disk.py b/examples/computer_vision_techniques/mask_disk.py\n--- a/examples/computer_vision_techniques/mask_disk.py\n+++ b/examples/computer_vision_techniques/mask_disk.py\n@@ -6,12 +6,10 @@\n How to mask out all emission from the solar disk.\n \"\"\... | 744 | 513 |
gh_patches_debug_7803 | rasdani/github-patches | git_diff | weecology__retriever-712 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add Python 3 to setup.py
We need to note in the setup.py that Python 3 is supported.
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
-... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -72,7 +72,8 @@
classifiers=['Intended Audience :: Science/Research',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python',
- 'Programming Language :: Python :: 2', ],
... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -72,7 +72,8 @@\n classifiers=['Intended Audience :: Science/Research',\n 'License :: OSI Approved :: MIT License',\n 'Programming Language :: Python',\n- 'Programming Langu... | 1,459 | 111 |
gh_patches_debug_38826 | rasdani/github-patches | git_diff | sparcs-kaist__otlplus-979 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[CHORE] 졸업플래너 신규 model의 serialize결과 캐싱
## 동기
**Is your feature request related to a problem? Please describe.**
OTL의 주요 모델에는 캐시가 구현되어 있으나 졸업플래너에서 새로 생성된 model은 아직 캐싱이 적용되어 있지 않습니다.
베타 출시 때는 우선 임시로 그대로 ... | diff --git a/apps/graduation/models.py b/apps/graduation/models.py
--- a/apps/graduation/models.py
+++ b/apps/graduation/models.py
@@ -1,4 +1,5 @@
from django.db import models
+from django.core.cache import cache
from apps.subject.models import Department
@@ -26,7 +27,15 @@
class Meta:
unique_togeth... | {"golden_diff": "diff --git a/apps/graduation/models.py b/apps/graduation/models.py\n--- a/apps/graduation/models.py\n+++ b/apps/graduation/models.py\n@@ -1,4 +1,5 @@\n from django.db import models\n+from django.core.cache import cache\n \n from apps.subject.models import Department\n \n@@ -26,7 +27,15 @@\n class M... | 1,590 | 648 |
gh_patches_debug_4968 | rasdani/github-patches | git_diff | dbt-labs__dbt-core-2649 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
dbt clean regression
### Describe the bug
In dbt 0.16.1 `dbt clean` fails without a profile:
```bash
(dbt) dbt$ dbt --version
installed version: 0.16.1
latest version: 0.17.0
Your version of dbt... | diff --git a/core/dbt/task/clean.py b/core/dbt/task/clean.py
--- a/core/dbt/task/clean.py
+++ b/core/dbt/task/clean.py
@@ -2,11 +2,13 @@
import os
import shutil
-from dbt.task.base import ConfiguredTask
+from dbt.task.base import BaseTask
from dbt.logger import GLOBAL_LOGGER as logger
+from dbt.config import Unset... | {"golden_diff": "diff --git a/core/dbt/task/clean.py b/core/dbt/task/clean.py\n--- a/core/dbt/task/clean.py\n+++ b/core/dbt/task/clean.py\n@@ -2,11 +2,13 @@\n import os\n import shutil\n \n-from dbt.task.base import ConfiguredTask\n+from dbt.task.base import BaseTask\n from dbt.logger import GLOBAL_LOGGER as logger\n+f... | 1,358 | 142 |
gh_patches_debug_2478 | rasdani/github-patches | git_diff | svthalia__concrexit-1767 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Delete tpay payment if order is modified
### Summary
Right now it is possible to order a pizza, pay it with tpay, change the order to a pizza with a different price, and the payment will not match the order ... | diff --git a/website/pizzas/views.py b/website/pizzas/views.py
--- a/website/pizzas/views.py
+++ b/website/pizzas/views.py
@@ -67,6 +67,6 @@
obj = FoodOrder(food_event=event, member=request.member)
obj.product = product
if obj.payment:
- delete_payment(obj.payment)
+ ... | {"golden_diff": "diff --git a/website/pizzas/views.py b/website/pizzas/views.py\n--- a/website/pizzas/views.py\n+++ b/website/pizzas/views.py\n@@ -67,6 +67,6 @@\n obj = FoodOrder(food_event=event, member=request.member)\n obj.product = product\n if obj.payment:\n- delete_payment(o... | 1,068 | 97 |
gh_patches_debug_12655 | rasdani/github-patches | git_diff | deis__deis-3535 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Error with `deis certs:remove`
Getting the following error when trying to remove a cert.
```
$ deis certs:remove '*.brandfolder.com'
Removing *.brandfolder.com... 405 METHOD NOT ALLOWED
Detail:
Method 'DELET... | diff --git a/controller/api/urls.py b/controller/api/urls.py
--- a/controller/api/urls.py
+++ b/controller/api/urls.py
@@ -82,7 +82,7 @@
views.AdminPermsViewSet.as_view({'delete': 'destroy'})),
url(r'^admin/perms/?',
views.AdminPermsViewSet.as_view({'get': 'list', 'post': 'create'})),
- url(r'... | {"golden_diff": "diff --git a/controller/api/urls.py b/controller/api/urls.py\n--- a/controller/api/urls.py\n+++ b/controller/api/urls.py\n@@ -82,7 +82,7 @@\n views.AdminPermsViewSet.as_view({'delete': 'destroy'})),\n url(r'^admin/perms/?',\n views.AdminPermsViewSet.as_view({'get': 'list', 'post': '... | 1,699 | 189 |
gh_patches_debug_11545 | rasdani/github-patches | git_diff | lisa-lab__pylearn2-1300 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
test_video.test_spatiotemporal_cubes is randomly failing
The test `utils.tests.test_video.test_spatiotemporal_cubes` seems to be randomly failing on some Travis builds. Both @jych and @daemonmaker have experi... | diff --git a/pylearn2/utils/video.py b/pylearn2/utils/video.py
--- a/pylearn2/utils/video.py
+++ b/pylearn2/utils/video.py
@@ -131,8 +131,8 @@
# fall within frame.
last_row = video_height - patch_height
last_col = video_width - patch_width
- row = numpy.random.random_integers(0, last_r... | {"golden_diff": "diff --git a/pylearn2/utils/video.py b/pylearn2/utils/video.py\n--- a/pylearn2/utils/video.py\n+++ b/pylearn2/utils/video.py\n@@ -131,8 +131,8 @@\n # fall within frame.\n last_row = video_height - patch_height\n last_col = video_width - patch_width\n- row = numpy.random.r... | 1,937 | 171 |
gh_patches_debug_36019 | rasdani/github-patches | git_diff | pytorch__TensorRT-905 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
✨[Feature] Enable debug logging with a context
**Is your feature request related to a problem? Please describe.**
<!--A clear and concise description of what the problem is. Ex. I'm always frustrated when [... | diff --git a/py/torch_tensorrt/logging.py b/py/torch_tensorrt/logging.py
--- a/py/torch_tensorrt/logging.py
+++ b/py/torch_tensorrt/logging.py
@@ -96,3 +96,113 @@
msg (str): Actual message text
"""
_log(Level._to_internal_level(level), msg)
+
+ InternalError = LogLevel.INTERNAL_ERROR
+ Error = ... | {"golden_diff": "diff --git a/py/torch_tensorrt/logging.py b/py/torch_tensorrt/logging.py\n--- a/py/torch_tensorrt/logging.py\n+++ b/py/torch_tensorrt/logging.py\n@@ -96,3 +96,113 @@\n msg (str): Actual message text\n \"\"\"\n _log(Level._to_internal_level(level), msg)\n+\n+ InternalError = LogLevel.... | 1,330 | 816 |
gh_patches_debug_20562 | rasdani/github-patches | git_diff | pantsbuild__pants-13464 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
pants package does not build missing docker images if previous build was cached.
**Describe the bug**
Pant's caching of build targets does not take into consideration that the final target does not exist.
... | diff --git a/src/python/pants/backend/docker/util_rules/docker_binary.py b/src/python/pants/backend/docker/util_rules/docker_binary.py
--- a/src/python/pants/backend/docker/util_rules/docker_binary.py
+++ b/src/python/pants/backend/docker/util_rules/docker_binary.py
@@ -15,6 +15,7 @@
BinaryPaths,
BinaryPathTe... | {"golden_diff": "diff --git a/src/python/pants/backend/docker/util_rules/docker_binary.py b/src/python/pants/backend/docker/util_rules/docker_binary.py\n--- a/src/python/pants/backend/docker/util_rules/docker_binary.py\n+++ b/src/python/pants/backend/docker/util_rules/docker_binary.py\n@@ -15,6 +15,7 @@\n BinaryPat... | 1,400 | 245 |
gh_patches_debug_33920 | rasdani/github-patches | git_diff | googleapis__google-cloud-python-5988 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Please cut a release of Cloud Asset
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `asset/setup.py`
Conten... | diff --git a/asset/setup.py b/asset/setup.py
--- a/asset/setup.py
+++ b/asset/setup.py
@@ -17,27 +17,38 @@
import setuptools
+# Package metadata.
+
name = 'google-cloud-cloudasset'
description = 'Cloud Asset API API client library'
version = '0.1.0'
-release_status = '3 - Alpha'
+# Should be one of:
+# 'Develop... | {"golden_diff": "diff --git a/asset/setup.py b/asset/setup.py\n--- a/asset/setup.py\n+++ b/asset/setup.py\n@@ -17,27 +17,38 @@\n \n import setuptools\n \n+# Package metadata.\n+\n name = 'google-cloud-cloudasset'\n description = 'Cloud Asset API API client library'\n version = '0.1.0'\n-release_status = '3 - Alpha'\n+#... | 966 | 444 |
gh_patches_debug_6963 | rasdani/github-patches | git_diff | Lightning-AI__pytorch-lightning-1193 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Wandb logger doesn't upload saved model checkpoint for final epoch
## 🐛 Bug
When training a model on the TPU and using the wandb logger, the checkpoint for the last epoch trained doesn't get uploaded to w... | diff --git a/pytorch_lightning/loggers/wandb.py b/pytorch_lightning/loggers/wandb.py
--- a/pytorch_lightning/loggers/wandb.py
+++ b/pytorch_lightning/loggers/wandb.py
@@ -101,14 +101,6 @@
metrics['global_step'] = step
self.experiment.log(metrics)
- @rank_zero_only
- def finalize(self, stat... | {"golden_diff": "diff --git a/pytorch_lightning/loggers/wandb.py b/pytorch_lightning/loggers/wandb.py\n--- a/pytorch_lightning/loggers/wandb.py\n+++ b/pytorch_lightning/loggers/wandb.py\n@@ -101,14 +101,6 @@\n metrics['global_step'] = step\n self.experiment.log(metrics)\n \n- @rank_zero_only\n- ... | 1,522 | 168 |
gh_patches_debug_35487 | rasdani/github-patches | git_diff | alltheplaces__alltheplaces-3129 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Spider jiffylube is broken
During the global build at 2021-09-01-14-42-16, spider **jiffylube** failed with **0 features** and **49 errors**.
Here's [the log](https://data.alltheplaces.xyz/runs/2021-09-01-14... | diff --git a/locations/spiders/jiffylube.py b/locations/spiders/jiffylube.py
--- a/locations/spiders/jiffylube.py
+++ b/locations/spiders/jiffylube.py
@@ -29,30 +29,27 @@
name = "jiffylube"
item_attributes = {'brand': "Jiffy Lube"}
allowed_domains = ["www.jiffylube.com"]
+ start_urls = (
+ 'htt... | {"golden_diff": "diff --git a/locations/spiders/jiffylube.py b/locations/spiders/jiffylube.py\n--- a/locations/spiders/jiffylube.py\n+++ b/locations/spiders/jiffylube.py\n@@ -29,30 +29,27 @@\n name = \"jiffylube\"\n item_attributes = {'brand': \"Jiffy Lube\"}\n allowed_domains = [\"www.jiffylube.com\"]\n+ ... | 1,318 | 586 |
gh_patches_debug_31028 | rasdani/github-patches | git_diff | pretix__pretix-346 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Log old email when changing an order's email address
… because otherwise it's completely lost.
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may conta... | diff --git a/src/pretix/control/logdisplay.py b/src/pretix/control/logdisplay.py
--- a/src/pretix/control/logdisplay.py
+++ b/src/pretix/control/logdisplay.py
@@ -59,7 +59,6 @@
'pretix.event.order.invoice.regenerated': _('The invoice has been regenerated.'),
'pretix.event.order.invoice.reissued': _('T... | {"golden_diff": "diff --git a/src/pretix/control/logdisplay.py b/src/pretix/control/logdisplay.py\n--- a/src/pretix/control/logdisplay.py\n+++ b/src/pretix/control/logdisplay.py\n@@ -59,7 +59,6 @@\n 'pretix.event.order.invoice.regenerated': _('The invoice has been regenerated.'),\n 'pretix.event.order.i... | 1,634 | 348 |
gh_patches_debug_58561 | rasdani/github-patches | git_diff | codespell-project__codespell-86 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
codespell.py does nothng if [fileN] is not specified
Previously running `codespell` without file parameter starts the check. Now `codespell.py` does nothing. The behavior should stay the same as before - if f... | diff --git a/bin/codespell.py b/bin/codespell.py
--- a/bin/codespell.py
+++ b/bin/codespell.py
@@ -4,4 +4,4 @@
if __name__ == '__main__':
import codespell_lib
- sys.exit(codespell_lib.main(*sys.argv))
+ sys.exit(codespell_lib.main(*sys.argv[1:]))
| {"golden_diff": "diff --git a/bin/codespell.py b/bin/codespell.py\n--- a/bin/codespell.py\n+++ b/bin/codespell.py\n@@ -4,4 +4,4 @@\n \n if __name__ == '__main__':\n import codespell_lib\n- sys.exit(codespell_lib.main(*sys.argv))\n+ sys.exit(codespell_lib.main(*sys.argv[1:]))\n", "issue": "codespell.py does no... | 372 | 86 |
gh_patches_debug_6744 | rasdani/github-patches | git_diff | bridgecrewio__checkov-3626 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
CKV_DOCKER_10 mistakes quoted absolute paths for relative paths
**Describe the issue**
CKV_DOCKER_10 mistakes quoted absolute paths for relative paths.
**Examples**
```
cat << EOF > Dockerfile
FROM alp... | diff --git a/checkov/dockerfile/checks/WorkdirIsAbsolute.py b/checkov/dockerfile/checks/WorkdirIsAbsolute.py
--- a/checkov/dockerfile/checks/WorkdirIsAbsolute.py
+++ b/checkov/dockerfile/checks/WorkdirIsAbsolute.py
@@ -5,7 +5,7 @@
from checkov.common.models.enums import CheckCategories, CheckResult
from checkov.docke... | {"golden_diff": "diff --git a/checkov/dockerfile/checks/WorkdirIsAbsolute.py b/checkov/dockerfile/checks/WorkdirIsAbsolute.py\n--- a/checkov/dockerfile/checks/WorkdirIsAbsolute.py\n+++ b/checkov/dockerfile/checks/WorkdirIsAbsolute.py\n@@ -5,7 +5,7 @@\n from checkov.common.models.enums import CheckCategories, CheckResul... | 810 | 210 |
gh_patches_debug_2508 | rasdani/github-patches | git_diff | coala__coala-6088 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Small typo in coalib/output/printers/LogPrinter.py
Should read responsibility instead of reponsibility.
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these file... | diff --git a/coalib/output/printers/LogPrinter.py b/coalib/output/printers/LogPrinter.py
--- a/coalib/output/printers/LogPrinter.py
+++ b/coalib/output/printers/LogPrinter.py
@@ -85,7 +85,7 @@
def log_message(self, log_message, **kwargs):
"""
- It is your reponsibility to implement this method, i... | {"golden_diff": "diff --git a/coalib/output/printers/LogPrinter.py b/coalib/output/printers/LogPrinter.py\n--- a/coalib/output/printers/LogPrinter.py\n+++ b/coalib/output/printers/LogPrinter.py\n@@ -85,7 +85,7 @@\n \n def log_message(self, log_message, **kwargs):\n \"\"\"\n- It is your reponsibility ... | 1,759 | 124 |
gh_patches_debug_32576 | rasdani/github-patches | git_diff | Kinto__kinto-1735 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Kinto onboarding experience (part 2)
These is a followup from #1733 with random feedback with onboarding when trying to use the [accounts plugin](http://docs.kinto-storage.org/en/stable/api/1.x/accounts.html)... | diff --git a/kinto/plugins/accounts/__init__.py b/kinto/plugins/accounts/__init__.py
--- a/kinto/plugins/accounts/__init__.py
+++ b/kinto/plugins/accounts/__init__.py
@@ -1,9 +1,13 @@
+import re
+
from kinto.authorization import PERMISSIONS_INHERITANCE_TREE
from pyramid.exceptions import ConfigurationError
ACCOUNT... | {"golden_diff": "diff --git a/kinto/plugins/accounts/__init__.py b/kinto/plugins/accounts/__init__.py\n--- a/kinto/plugins/accounts/__init__.py\n+++ b/kinto/plugins/accounts/__init__.py\n@@ -1,9 +1,13 @@\n+import re\n+\n from kinto.authorization import PERMISSIONS_INHERITANCE_TREE\n from pyramid.exceptions import Confi... | 1,343 | 529 |
gh_patches_debug_22977 | rasdani/github-patches | git_diff | digitalfabrik__integreat-cms-410 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Improve documentation of cms.apps (CmsConfig)
Explain what cms.apps is doing, what CmsConfig is for and add docstrings of the following format:
```
"""
[Summary]
:param [ParamName]: [ParamDescription], ... | diff --git a/src/cms/apps.py b/src/cms/apps.py
--- a/src/cms/apps.py
+++ b/src/cms/apps.py
@@ -1,6 +1,3 @@
-"""
-Django related class representing a config of an app
-"""
import logging
import sys
from django.conf import settings
@@ -10,12 +7,23 @@
class CmsConfig(AppConfig):
"""
- Class inheriting the dj... | {"golden_diff": "diff --git a/src/cms/apps.py b/src/cms/apps.py\n--- a/src/cms/apps.py\n+++ b/src/cms/apps.py\n@@ -1,6 +1,3 @@\n-\"\"\"\n-Django related class representing a config of an app\n-\"\"\"\n import logging\n import sys\n from django.conf import settings\n@@ -10,12 +7,23 @@\n \n class CmsConfig(AppConfig):\n ... | 542 | 312 |
gh_patches_debug_19895 | rasdani/github-patches | git_diff | mathesar-foundation__mathesar-57 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Schema getter should return public, but not mathesar_types
**Describe the bug**
<!-- A clear and concise description of what the bug is. -->
If a user wants to create a table the `public` schema, they can... | diff --git a/db/schemas.py b/db/schemas.py
--- a/db/schemas.py
+++ b/db/schemas.py
@@ -1,24 +1,28 @@
from sqlalchemy.schema import CreateSchema
from sqlalchemy import inspect
+from db import types
-def get_all_schemas(engine):
- inspector = inspect(engine)
+TYPES_SCHEMA = types.base.SCHEMA
+
+
+def get_mathesa... | {"golden_diff": "diff --git a/db/schemas.py b/db/schemas.py\n--- a/db/schemas.py\n+++ b/db/schemas.py\n@@ -1,24 +1,28 @@\n from sqlalchemy.schema import CreateSchema\n from sqlalchemy import inspect\n \n+from db import types\n \n-def get_all_schemas(engine):\n- inspector = inspect(engine)\n+TYPES_SCHEMA = types.base... | 626 | 248 |
gh_patches_debug_25834 | rasdani/github-patches | git_diff | fedora-infra__bodhi-2899 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Delete bodhi.server.views.admin
Bodhi has a strange view that tells admin users what their username and principals are, but does not allow non-admin users to use it:
https://github.com/fedora-infra/bodhi/b... | diff --git a/bodhi/server/views/admin.py b/bodhi/server/views/admin.py
deleted file mode 100644
--- a/bodhi/server/views/admin.py
+++ /dev/null
@@ -1,47 +0,0 @@
-# Copyright © 2014-2017 Red Hat, Inc. and others
-#
-# This file is part of Bodhi.
-#
-# This program is free software; you can redistribute it and/or
-# modi... | {"golden_diff": "diff --git a/bodhi/server/views/admin.py b/bodhi/server/views/admin.py\ndeleted file mode 100644\n--- a/bodhi/server/views/admin.py\n+++ /dev/null\n@@ -1,47 +0,0 @@\n-# Copyright \u00a9 2014-2017 Red Hat, Inc. and others\n-#\n-# This file is part of Bodhi.\n-#\n-# This program is free software; you can... | 897 | 479 |
gh_patches_debug_67390 | rasdani/github-patches | git_diff | goauthentik__authentik-4675 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Proxy Provider not working
Hello
Please help me, I updated the authentik server to 23.1.2, it worked perfectly until now, now the Proxy Provider is not working because of the following error
this is in... | diff --git a/authentik/core/tasks.py b/authentik/core/tasks.py
--- a/authentik/core/tasks.py
+++ b/authentik/core/tasks.py
@@ -43,6 +43,7 @@
amount = 0
for session in AuthenticatedSession.objects.all():
cache_key = f"{KEY_PREFIX}{session.session_key}"
+ value = None
try:
... | {"golden_diff": "diff --git a/authentik/core/tasks.py b/authentik/core/tasks.py\n--- a/authentik/core/tasks.py\n+++ b/authentik/core/tasks.py\n@@ -43,6 +43,7 @@\n amount = 0\n for session in AuthenticatedSession.objects.all():\n cache_key = f\"{KEY_PREFIX}{session.session_key}\"\n+ value = None\n... | 1,184 | 104 |
gh_patches_debug_37428 | rasdani/github-patches | git_diff | spack__spack-15179 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Remove 'spack bootstrap' from the commands
As a Spack maintainer I want to remove the `spack bootstrap` command (outdated since #14062) so that I could reduce the amount of boilerplate code in the project.
... | diff --git a/lib/spack/spack/cmd/bootstrap.py b/lib/spack/spack/cmd/bootstrap.py
deleted file mode 100644
--- a/lib/spack/spack/cmd/bootstrap.py
+++ /dev/null
@@ -1,80 +0,0 @@
-# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other
-# Spack Project Developers. See the top-level COPYRIGHT file for det... | {"golden_diff": "diff --git a/lib/spack/spack/cmd/bootstrap.py b/lib/spack/spack/cmd/bootstrap.py\ndeleted file mode 100644\n--- a/lib/spack/spack/cmd/bootstrap.py\n+++ /dev/null\n@@ -1,80 +0,0 @@\n-# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other\n-# Spack Project Developers. See the top-level... | 1,270 | 811 |
gh_patches_debug_29186 | rasdani/github-patches | git_diff | meltano__meltano-6368 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
`meltano lock` -> variant 'original' is not known to Meltano
I'm getting the following error when I'm trying to run a `meltano lock --all` on [the squared project](https://github.com/meltano/squared/blob/4d01... | diff --git a/src/meltano/cli/lock.py b/src/meltano/cli/lock.py
--- a/src/meltano/cli/lock.py
+++ b/src/meltano/cli/lock.py
@@ -64,14 +64,12 @@
tracker.track_command_event(CliEvent.aborted)
raise CliError("Exactly one of --all or plugin name must be specified.")
- with plugins_service.use_preferre... | {"golden_diff": "diff --git a/src/meltano/cli/lock.py b/src/meltano/cli/lock.py\n--- a/src/meltano/cli/lock.py\n+++ b/src/meltano/cli/lock.py\n@@ -64,14 +64,12 @@\n tracker.track_command_event(CliEvent.aborted)\n raise CliError(\"Exactly one of --all or plugin name must be specified.\")\n \n- with pl... | 1,860 | 371 |
gh_patches_debug_27279 | rasdani/github-patches | git_diff | Pylons__pyramid-2618 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
pcreate -s shows wrong link to tutorials
after a
```
pcreate -s alchemy scaffold-alchemy
```
I see a link to tutorials, but this link is a 404:
```
Tutorials: http://docs.pylonsproject.org/projects/pyram... | diff --git a/pyramid/scaffolds/__init__.py b/pyramid/scaffolds/__init__.py
--- a/pyramid/scaffolds/__init__.py
+++ b/pyramid/scaffolds/__init__.py
@@ -35,11 +35,10 @@
msg = dedent(
"""
%(separator)s
- Tutorials: http://docs.pylonsproject.org/projects/pyramid_tutorials
- ... | {"golden_diff": "diff --git a/pyramid/scaffolds/__init__.py b/pyramid/scaffolds/__init__.py\n--- a/pyramid/scaffolds/__init__.py\n+++ b/pyramid/scaffolds/__init__.py\n@@ -35,11 +35,10 @@\n msg = dedent(\n \"\"\"\n %(separator)s\n- Tutorials: http://docs.pylonsproject.org/proje... | 979 | 398 |
gh_patches_debug_13808 | rasdani/github-patches | git_diff | lisa-lab__pylearn2-1503 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[bug] print_monitor_cv.py model not iterable
I've tried `print_monitor_cv.py model.pkl` but I've got
```
Traceback (most recent call last):
File "~/pylearn2/pylearn2/scripts/print_monitor_cv.py", line 84, ... | diff --git a/pylearn2/scripts/print_monitor_cv.py b/pylearn2/scripts/print_monitor_cv.py
--- a/pylearn2/scripts/print_monitor_cv.py
+++ b/pylearn2/scripts/print_monitor_cv.py
@@ -13,6 +13,7 @@
__maintainer__ = "Steven Kearnes"
import argparse
+from collections import Iterable
import numpy as np
from pylearn2.ut... | {"golden_diff": "diff --git a/pylearn2/scripts/print_monitor_cv.py b/pylearn2/scripts/print_monitor_cv.py\n--- a/pylearn2/scripts/print_monitor_cv.py\n+++ b/pylearn2/scripts/print_monitor_cv.py\n@@ -13,6 +13,7 @@\n __maintainer__ = \"Steven Kearnes\"\n \n import argparse\n+from collections import Iterable\n import nump... | 1,342 | 169 |
gh_patches_debug_53754 | rasdani/github-patches | git_diff | pypa__pipenv-1662 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
ImportError: No module named shutil_get_terminal_size
Describe the issue briefly here.
```
$ pipenv run python
Creating a virtualenv for this project…
Using /usr/bin/python (2.7.14) to create virtualenv... | diff --git a/pipenv/pew/__main__.py b/pipenv/pew/__main__.py
--- a/pipenv/pew/__main__.py
+++ b/pipenv/pew/__main__.py
@@ -1,4 +1,13 @@
from pipenv.patched import pew
+import os
+import sys
+
+pipenv_root = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
+pipenv_vendor = os.sep.join([pipenv_root, 'vendor']... | {"golden_diff": "diff --git a/pipenv/pew/__main__.py b/pipenv/pew/__main__.py\n--- a/pipenv/pew/__main__.py\n+++ b/pipenv/pew/__main__.py\n@@ -1,4 +1,13 @@\n from pipenv.patched import pew\n+import os\n+import sys\n+\n+pipenv_root = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))\n+pipenv_vendor = os.sep.jo... | 1,963 | 170 |
gh_patches_debug_31149 | rasdani/github-patches | git_diff | alltheplaces__alltheplaces-2636 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Spider papa_johns is broken
During the global build at 2021-08-18-14-42-26, spider **papa_johns** failed with **3199 features** and **1 errors**.
Here's [the log](https://data.alltheplaces.xyz/runs/2021-08-1... | diff --git a/locations/spiders/papa_johns.py b/locations/spiders/papa_johns.py
--- a/locations/spiders/papa_johns.py
+++ b/locations/spiders/papa_johns.py
@@ -5,14 +5,20 @@
from locations.items import GeojsonPointItem
from locations.hours import OpeningHours
-day_map = {'MONDAY': 'Mo', 'TUESDAY': 'Tu', 'WEDNESDAY':... | {"golden_diff": "diff --git a/locations/spiders/papa_johns.py b/locations/spiders/papa_johns.py\n--- a/locations/spiders/papa_johns.py\n+++ b/locations/spiders/papa_johns.py\n@@ -5,14 +5,20 @@\n from locations.items import GeojsonPointItem\n from locations.hours import OpeningHours\n \n-day_map = {'MONDAY': 'Mo', 'TUES... | 1,880 | 533 |
gh_patches_debug_2375 | rasdani/github-patches | git_diff | lutris__lutris-559 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Lutris shortcuts broken
See: https://forums.lutris.net/t/desktop-shortcut-not-work-for-any-game/456
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may ... | diff --git a/lutris/util/resources.py b/lutris/util/resources.py
--- a/lutris/util/resources.py
+++ b/lutris/util/resources.py
@@ -107,6 +107,8 @@
game_slug = parsed_url.path
if not game_slug:
return False
+ if game_slug.startswith('lutris:'):
+ game_slug = game_slug[7:]
revision = Non... | {"golden_diff": "diff --git a/lutris/util/resources.py b/lutris/util/resources.py\n--- a/lutris/util/resources.py\n+++ b/lutris/util/resources.py\n@@ -107,6 +107,8 @@\n game_slug = parsed_url.path\n if not game_slug:\n return False\n+ if game_slug.startswith('lutris:'):\n+ game_slug = game_slu... | 1,383 | 111 |
gh_patches_debug_53951 | rasdani/github-patches | git_diff | aws-cloudformation__cfn-lint-985 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
cfn-lint is failing because of `pkg_resources.ContextualVersionConflict: (jsonschema 2.6.0)`.
*cfn-lint version: (`0.21.6`)*
*Description of issue.*
cfn-lint(python2) requires jsonschema 2.6.0 but aws-sa... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -78,7 +78,7 @@
'requests>=2.15.0',
'aws-sam-translator>=1.10.0',
'jsonpatch',
- 'jsonschema~=2.6',
+ 'jsonschema~=3.0',
'pathlib2>=2.3.0;python_version<"3.4"',
'setuptools',
],
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -78,7 +78,7 @@\n 'requests>=2.15.0',\n 'aws-sam-translator>=1.10.0',\n 'jsonpatch',\n- 'jsonschema~=2.6',\n+ 'jsonschema~=3.0',\n 'pathlib2>=2.3.0;python_version<\"3.4\"',\n 'setup... | 1,673 | 109 |
gh_patches_debug_31925 | rasdani/github-patches | git_diff | ipython__ipython-2198 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Unknown option `no-edit` in git-mpr
This one is mostly for @Carreau: I just tried git mpr again, and this is what I got. Does it actually work for you on linux? This is on a linux 12.04 box with git 1.7.9.5.... | diff --git a/tools/git-mpr.py b/tools/git-mpr.py
--- a/tools/git-mpr.py
+++ b/tools/git-mpr.py
@@ -6,6 +6,7 @@
"""
from __future__ import print_function
+import io, os
import argparse
from subprocess import check_call, CalledProcessError
@@ -24,7 +25,7 @@
"""
# Delete the branch first
try :
- ... | {"golden_diff": "diff --git a/tools/git-mpr.py b/tools/git-mpr.py\n--- a/tools/git-mpr.py\n+++ b/tools/git-mpr.py\n@@ -6,6 +6,7 @@\n \"\"\"\n from __future__ import print_function\n \n+import io, os\n import argparse\n from subprocess import check_call, CalledProcessError\n \n@@ -24,7 +25,7 @@\n \"\"\"\n # Dele... | 1,887 | 397 |
gh_patches_debug_9578 | rasdani/github-patches | git_diff | lutris__lutris-3623 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
0.5.9 Gamescope should default to fullscreen
Currently it defaults to a Gamescope window when the game is launched.
The Gamescope documentation states that the argument `-f` needs to be passed for the wind... | diff --git a/lutris/runner_interpreter.py b/lutris/runner_interpreter.py
--- a/lutris/runner_interpreter.py
+++ b/lutris/runner_interpreter.py
@@ -107,7 +107,7 @@
def get_gamescope_args(launch_arguments, system_config):
"""Insert gamescope at the start of the launch arguments"""
- launch_arguments.insert(0, ... | {"golden_diff": "diff --git a/lutris/runner_interpreter.py b/lutris/runner_interpreter.py\n--- a/lutris/runner_interpreter.py\n+++ b/lutris/runner_interpreter.py\n@@ -107,7 +107,7 @@\n \n def get_gamescope_args(launch_arguments, system_config):\n \"\"\"Insert gamescope at the start of the launch arguments\"\"\"\n- ... | 1,924 | 148 |
gh_patches_debug_10736 | rasdani/github-patches | git_diff | pytorch__ignite-612 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
BaseWeightsScalarHandler has side effects on random number generation
### Problem
BaseWeightsScalarHandler uses `torch.rand` to test the reduction function that is passed as an argument.
This is very confu... | diff --git a/ignite/contrib/handlers/base_logger.py b/ignite/contrib/handlers/base_logger.py
--- a/ignite/contrib/handlers/base_logger.py
+++ b/ignite/contrib/handlers/base_logger.py
@@ -142,8 +142,8 @@
def _is_0D_tensor(t):
return isinstance(t, torch.Tensor) and t.ndimension() == 0
- # T... | {"golden_diff": "diff --git a/ignite/contrib/handlers/base_logger.py b/ignite/contrib/handlers/base_logger.py\n--- a/ignite/contrib/handlers/base_logger.py\n+++ b/ignite/contrib/handlers/base_logger.py\n@@ -142,8 +142,8 @@\n def _is_0D_tensor(t):\n return isinstance(t, torch.Tensor) and t.ndimension... | 1,986 | 181 |
gh_patches_debug_37325 | rasdani/github-patches | git_diff | pallets__werkzeug-1790 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
deprecate posixemulation
It's called out as "not a public interface" in the docstring, and looks like it was only there to support `contrib.sessions`, which has moved to `secure-cookie` now. Move it there if ... | diff --git a/src/werkzeug/posixemulation.py b/src/werkzeug/posixemulation.py
deleted file mode 100644
--- a/src/werkzeug/posixemulation.py
+++ /dev/null
@@ -1,103 +0,0 @@
-"""A ``rename`` function that follows POSIX semantics. If the target
-file already exists it will be replaced without asking.
-
-This is not a publi... | {"golden_diff": "diff --git a/src/werkzeug/posixemulation.py b/src/werkzeug/posixemulation.py\ndeleted file mode 100644\n--- a/src/werkzeug/posixemulation.py\n+++ /dev/null\n@@ -1,103 +0,0 @@\n-\"\"\"A ``rename`` function that follows POSIX semantics. If the target\n-file already exists it will be replaced without aski... | 1,235 | 852 |
gh_patches_debug_24098 | rasdani/github-patches | git_diff | encode__uvicorn-666 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
color codes in windows console not escaped
Fixes https://github.com/tiangolo/fastapi/issues/815 that should have been reported upstream
There are many ways to handle the case obviously, I choose to use cli... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -34,21 +34,28 @@
]
-env_marker = (
+env_marker_cpython = (
"sys_platform != 'win32'"
" and sys_platform != 'cygwin'"
" and platform_python_implementation != 'PyPy'"
)
-requirements = [
+env_marker_win = "sys_platform == 'win32'... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -34,21 +34,28 @@\n ]\n \n \n-env_marker = (\n+env_marker_cpython = (\n \"sys_platform != 'win32'\"\n \" and sys_platform != 'cygwin'\"\n \" and platform_python_implementation != 'PyPy'\"\n )\n \n-requirements = [\n+env... | 1,166 | 387 |
gh_patches_debug_51634 | rasdani/github-patches | git_diff | akvo__akvo-rsr-2576 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
non-EUTF search results appearing (estimate: 8)
Created via Reamaze:
Link: https://akvoo.reamaze.com/admin/conversations/rsr-release-3-dot-22-chisinau-is-out
Assignee: Unassigned
Message:
Hi RSR Team,... | diff --git a/akvo/rest/views/typeahead.py b/akvo/rest/views/typeahead.py
--- a/akvo/rest/views/typeahead.py
+++ b/akvo/rest/views/typeahead.py
@@ -40,7 +40,8 @@
@api_view(['GET'])
def typeahead_organisation(request):
- organisations = Organisation.objects.all()
+ page = request.rsr_page
+ organisations = p... | {"golden_diff": "diff --git a/akvo/rest/views/typeahead.py b/akvo/rest/views/typeahead.py\n--- a/akvo/rest/views/typeahead.py\n+++ b/akvo/rest/views/typeahead.py\n@@ -40,7 +40,8 @@\n \n @api_view(['GET'])\n def typeahead_organisation(request):\n- organisations = Organisation.objects.all()\n+ page = request.rsr_pa... | 1,630 | 130 |
gh_patches_debug_31755 | rasdani/github-patches | git_diff | alltheplaces__alltheplaces-299 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Whidbey Coffee
http://www.whidbeycoffee.com/pages/locations
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: ... | diff --git a/locations/spiders/whidbeycoffee.py b/locations/spiders/whidbeycoffee.py
--- a/locations/spiders/whidbeycoffee.py
+++ b/locations/spiders/whidbeycoffee.py
@@ -76,7 +76,6 @@
else:
day = re.findall(r"^[^( |:)]+" ,li)[0]
times = li.replace(day , "")[1:]
- p... | {"golden_diff": "diff --git a/locations/spiders/whidbeycoffee.py b/locations/spiders/whidbeycoffee.py\n--- a/locations/spiders/whidbeycoffee.py\n+++ b/locations/spiders/whidbeycoffee.py\n@@ -76,7 +76,6 @@\n else:\n day = re.findall(r\"^[^( |:)]+\" ,li)[0]\n times = li.replace(day... | 1,517 | 372 |
gh_patches_debug_4162 | rasdani/github-patches | git_diff | pwndbg__pwndbg-693 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
qemu local_path bug
### Description
It seems like some commands e.g. plt, got tries to use ELF file's content as path.
### Steps to reproduce
```
$ qemu-arm -g 23946 ./target
$ gdb-multiarch ./targ... | diff --git a/pwndbg/file.py b/pwndbg/file.py
--- a/pwndbg/file.py
+++ b/pwndbg/file.py
@@ -33,7 +33,7 @@
local_path = path
if pwndbg.qemu.root() and recurse:
- return get(os.path.join(pwndbg.qemu.binfmt_root, path), 0)
+ return os.path.join(pwndbg.qemu.binfmt_root, path)
elif pwndbg.remot... | {"golden_diff": "diff --git a/pwndbg/file.py b/pwndbg/file.py\n--- a/pwndbg/file.py\n+++ b/pwndbg/file.py\n@@ -33,7 +33,7 @@\n local_path = path\n \n if pwndbg.qemu.root() and recurse:\n- return get(os.path.join(pwndbg.qemu.binfmt_root, path), 0)\n+ return os.path.join(pwndbg.qemu.binfmt_root, pat... | 1,941 | 134 |
gh_patches_debug_17389 | rasdani/github-patches | git_diff | googleapis__python-bigquery-1357 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
tqdm deprecation warning
#### Environment details
- OS type and version: Ubuntu 20.04 LTS
- Python version: 3.8.10
- pip version: 22.0.3
- `google-cloud-bigquery` version: 2.34.0
#### Steps t... | diff --git a/google/cloud/bigquery/_tqdm_helpers.py b/google/cloud/bigquery/_tqdm_helpers.py
--- a/google/cloud/bigquery/_tqdm_helpers.py
+++ b/google/cloud/bigquery/_tqdm_helpers.py
@@ -22,6 +22,7 @@
try:
import tqdm # type: ignore
+
except ImportError: # pragma: NO COVER
tqdm = None
@@ -48,7 +49,7 @... | {"golden_diff": "diff --git a/google/cloud/bigquery/_tqdm_helpers.py b/google/cloud/bigquery/_tqdm_helpers.py\n--- a/google/cloud/bigquery/_tqdm_helpers.py\n+++ b/google/cloud/bigquery/_tqdm_helpers.py\n@@ -22,6 +22,7 @@\n \n try:\n import tqdm # type: ignore\n+\n except ImportError: # pragma: NO COVER\n tqdm... | 1,797 | 227 |
gh_patches_debug_5651 | rasdani/github-patches | git_diff | projectmesa__mesa-2049 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
JupyterViz: the default grid space drawer doesn't scale to large size
**Describe the bug**
<!-- A clear and concise description the bug -->
Here is Schelling space for 60x60:
![2023-07-24-102909_468x350_sc... | diff --git a/mesa/experimental/components/matplotlib.py b/mesa/experimental/components/matplotlib.py
--- a/mesa/experimental/components/matplotlib.py
+++ b/mesa/experimental/components/matplotlib.py
@@ -48,6 +48,9 @@
if "color" in data:
c.append(data["color"])
out ... | {"golden_diff": "diff --git a/mesa/experimental/components/matplotlib.py b/mesa/experimental/components/matplotlib.py\n--- a/mesa/experimental/components/matplotlib.py\n+++ b/mesa/experimental/components/matplotlib.py\n@@ -48,6 +48,9 @@\n if \"color\" in data:\n c.append(data... | 1,739 | 160 |
gh_patches_debug_32679 | rasdani/github-patches | git_diff | alltheplaces__alltheplaces-1879 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Spider rei is broken
During the global build at 2021-05-26-14-42-23, spider **rei** failed with **0 features** and **0 errors**.
Here's [the log](https://data.alltheplaces.xyz/runs/2021-05-26-14-42-23/logs/r... | diff --git a/locations/spiders/rei.py b/locations/spiders/rei.py
--- a/locations/spiders/rei.py
+++ b/locations/spiders/rei.py
@@ -33,28 +33,34 @@
def fix_opening_hours(self, opening_hours):
return ";".join(map(self.format_days, opening_hours))
-
def parse_store(self, response):
... | {"golden_diff": "diff --git a/locations/spiders/rei.py b/locations/spiders/rei.py\n--- a/locations/spiders/rei.py\n+++ b/locations/spiders/rei.py\n@@ -33,28 +33,34 @@\n \n def fix_opening_hours(self, opening_hours):\n return \";\".join(map(self.format_days, opening_hours))\n- \n \n def parse_stor... | 1,034 | 534 |
gh_patches_debug_32247 | rasdani/github-patches | git_diff | translate__pootle-6687 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
sync_stores/update_stores
For 2.9.0 we're making Pootle FS the main path into Pootle, but `sync_stores` and `update_stores` are kept for backward compatibility.
But we have situations where Pootle FS can't... | diff --git a/pootle/apps/pootle_app/management/commands/sync_stores.py b/pootle/apps/pootle_app/management/commands/sync_stores.py
--- a/pootle/apps/pootle_app/management/commands/sync_stores.py
+++ b/pootle/apps/pootle_app/management/commands/sync_stores.py
@@ -6,6 +6,7 @@
# or later license. See the LICENSE file for... | {"golden_diff": "diff --git a/pootle/apps/pootle_app/management/commands/sync_stores.py b/pootle/apps/pootle_app/management/commands/sync_stores.py\n--- a/pootle/apps/pootle_app/management/commands/sync_stores.py\n+++ b/pootle/apps/pootle_app/management/commands/sync_stores.py\n@@ -6,6 +6,7 @@\n # or later license. See... | 934 | 423 |
gh_patches_debug_216 | rasdani/github-patches | git_diff | mlcommons__GaNDLF-744 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Make `black` version static
**Is your feature request related to a problem? Please describe.**
Different versions of black behave differently WRT linting, which creates issues, such as PRs having linting cha... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -76,7 +76,7 @@
requirements = [
"torch==1.13.1",
- "black",
+ "black==23.11.0",
"numpy==1.25.0",
"scipy",
"SimpleITK!=2.0.*",
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -76,7 +76,7 @@\n \n requirements = [\n \"torch==1.13.1\",\n- \"black\",\n+ \"black==23.11.0\",\n \"numpy==1.25.0\",\n \"scipy\",\n \"SimpleITK!=2.0.*\",\n", "issue": "Make `black` version static\n**Is your featur... | 1,990 | 92 |
gh_patches_debug_22419 | rasdani/github-patches | git_diff | fedora-infra__bodhi-2473 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
rss-feeds should have more speaking titles
eg.: https://bodhi.fedoraproject.org/rss/updates/?releases=F24
the feed is named "updates"
maybe it should be renamed to "Fedora XX Released Updates" where XX woul... | diff --git a/bodhi/server/renderers.py b/bodhi/server/renderers.py
--- a/bodhi/server/renderers.py
+++ b/bodhi/server/renderers.py
@@ -56,17 +56,29 @@
if 'updates' in data:
key = 'updates'
+ feed_title = 'Released updates'
elif 'users' in data:
key = 'users'
+ ... | {"golden_diff": "diff --git a/bodhi/server/renderers.py b/bodhi/server/renderers.py\n--- a/bodhi/server/renderers.py\n+++ b/bodhi/server/renderers.py\n@@ -56,17 +56,29 @@\n \n if 'updates' in data:\n key = 'updates'\n+ feed_title = 'Released updates'\n elif 'users' in data:\n ... | 1,768 | 288 |
gh_patches_debug_26169 | rasdani/github-patches | git_diff | bookwyrm-social__bookwyrm-2491 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Pre-set user's timezone
**Is your feature request related to a problem? Please describe.**
I signed up and saw you can set a timezone. It was set to UTC by default.
**Describe the solution you'd like**
J... | diff --git a/bookwyrm/views/landing/register.py b/bookwyrm/views/landing/register.py
--- a/bookwyrm/views/landing/register.py
+++ b/bookwyrm/views/landing/register.py
@@ -1,4 +1,5 @@
""" class views for login/register views """
+import pytz
from django.contrib.auth import login
from django.core.exceptions import Per... | {"golden_diff": "diff --git a/bookwyrm/views/landing/register.py b/bookwyrm/views/landing/register.py\n--- a/bookwyrm/views/landing/register.py\n+++ b/bookwyrm/views/landing/register.py\n@@ -1,4 +1,5 @@\n \"\"\" class views for login/register views \"\"\"\n+import pytz\n from django.contrib.auth import login\n from dja... | 1,781 | 261 |
gh_patches_debug_7659 | rasdani/github-patches | git_diff | wagtail__wagtail-7702 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Wagtail 2.15 Bulk Publish for Inherited Page
Found a bug? Please fill out the sections below. 👍
### Issue Summary
Assume we have two classes:
class A(Page):
name = models.CharField(max_length=255)
... | diff --git a/wagtail/admin/views/pages/bulk_actions/publish.py b/wagtail/admin/views/pages/bulk_actions/publish.py
--- a/wagtail/admin/views/pages/bulk_actions/publish.py
+++ b/wagtail/admin/views/pages/bulk_actions/publish.py
@@ -34,6 +34,7 @@
def execute_action(cls, objects, include_descendants=False, user=None,... | {"golden_diff": "diff --git a/wagtail/admin/views/pages/bulk_actions/publish.py b/wagtail/admin/views/pages/bulk_actions/publish.py\n--- a/wagtail/admin/views/pages/bulk_actions/publish.py\n+++ b/wagtail/admin/views/pages/bulk_actions/publish.py\n@@ -34,6 +34,7 @@\n def execute_action(cls, objects, include_descenda... | 1,316 | 143 |
gh_patches_debug_27468 | rasdani/github-patches | git_diff | bookwyrm-social__bookwyrm-1071 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Additional data fields for author
It would be nice if authors had "pseudonym" or "AKA" fields.
This would allow you to find works by the same author written under different pseudonyms.
--- END ISSUE ---... | diff --git a/bookwyrm/views/author.py b/bookwyrm/views/author.py
--- a/bookwyrm/views/author.py
+++ b/bookwyrm/views/author.py
@@ -29,7 +29,7 @@
"author": author,
"books": [b.default_edition for b in books],
}
- return TemplateResponse(request, "author.html", data)
+ ret... | {"golden_diff": "diff --git a/bookwyrm/views/author.py b/bookwyrm/views/author.py\n--- a/bookwyrm/views/author.py\n+++ b/bookwyrm/views/author.py\n@@ -29,7 +29,7 @@\n \"author\": author,\n \"books\": [b.default_edition for b in books],\n }\n- return TemplateResponse(request, \"aut... | 870 | 311 |
gh_patches_debug_8198 | rasdani/github-patches | git_diff | searx__searx-175 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Startpage engine doesn't support russian queries
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `searx/e... | diff --git a/searx/engines/startpage.py b/searx/engines/startpage.py
--- a/searx/engines/startpage.py
+++ b/searx/engines/startpage.py
@@ -10,7 +10,6 @@
#
# @todo paging
-from urllib import urlencode
from lxml import html
from cgi import escape
import re
@@ -38,7 +37,6 @@
# do search-request
def request... | {"golden_diff": "diff --git a/searx/engines/startpage.py b/searx/engines/startpage.py\n--- a/searx/engines/startpage.py\n+++ b/searx/engines/startpage.py\n@@ -10,7 +10,6 @@\n #\n # @todo paging\n \n-from urllib import urlencode\n from lxml import html\n from cgi import escape\n import re\n@@ -38,7 +37,6 @@\n # d... | 1,020 | 158 |
gh_patches_debug_26195 | rasdani/github-patches | git_diff | mirumee__ariadne-166 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add extension support to make_executable_schema issue #95
This addresses issue #95
I have ported the logic from graphql-tools [buildSchemaFromTypeDefs](https://github.com/apollographql/graphql-tools/blob/... | diff --git a/ariadne/executable_schema.py b/ariadne/executable_schema.py
--- a/ariadne/executable_schema.py
+++ b/ariadne/executable_schema.py
@@ -1,6 +1,6 @@
from typing import List, Union
-from graphql import GraphQLSchema, build_schema
+from graphql import DocumentNode, GraphQLSchema, build_ast_schema, extend_sch... | {"golden_diff": "diff --git a/ariadne/executable_schema.py b/ariadne/executable_schema.py\n--- a/ariadne/executable_schema.py\n+++ b/ariadne/executable_schema.py\n@@ -1,6 +1,6 @@\n from typing import List, Union\n \n-from graphql import GraphQLSchema, build_schema\n+from graphql import DocumentNode, GraphQLSchema, buil... | 601 | 376 |
gh_patches_debug_39994 | rasdani/github-patches | git_diff | mne-tools__mne-bids-254 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[MRG] Add fetch function for eeg_matchingpennies dataset
Instead of adding a matchingpennies fetcher to the mne-study-template, I thought it could be a nice addition to mne-bids.
We can then easily import ... | diff --git a/examples/rename_brainvision_files.py b/examples/rename_brainvision_files.py
--- a/examples/rename_brainvision_files.py
+++ b/examples/rename_brainvision_files.py
@@ -30,36 +30,42 @@
###############################################################################
# We are importing everything we need for... | {"golden_diff": "diff --git a/examples/rename_brainvision_files.py b/examples/rename_brainvision_files.py\n--- a/examples/rename_brainvision_files.py\n+++ b/examples/rename_brainvision_files.py\n@@ -30,36 +30,42 @@\n \n ###############################################################################\n # We are importing... | 1,446 | 723 |
gh_patches_debug_44550 | rasdani/github-patches | git_diff | chainer__chainer-4345 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
extensions.ParameterStatistics cannot work with default parameter in GPU mode
`extensions.ParameterStatistics` raise error in GPU mode at `numpy.count_nonzero` or `numpy.percentile` at https://github.com/chai... | diff --git a/chainer/training/extensions/parameter_statistics.py b/chainer/training/extensions/parameter_statistics.py
--- a/chainer/training/extensions/parameter_statistics.py
+++ b/chainer/training/extensions/parameter_statistics.py
@@ -1,6 +1,8 @@
import numpy
import six
+import chainer
+from chainer.backends im... | {"golden_diff": "diff --git a/chainer/training/extensions/parameter_statistics.py b/chainer/training/extensions/parameter_statistics.py\n--- a/chainer/training/extensions/parameter_statistics.py\n+++ b/chainer/training/extensions/parameter_statistics.py\n@@ -1,6 +1,8 @@\n import numpy\n import six\n \n+import chainer\n... | 1,850 | 904 |
gh_patches_debug_21149 | rasdani/github-patches | git_diff | airctic__icevision-1010 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add YOLOX backbones
Add small, large, and xlarge backbones to the YOLOX model
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGI... | diff --git a/icevision/models/mmdet/models/yolox/backbones/resnet_fpn.py b/icevision/models/mmdet/models/yolox/backbones/resnet_fpn.py
--- a/icevision/models/mmdet/models/yolox/backbones/resnet_fpn.py
+++ b/icevision/models/mmdet/models/yolox/backbones/resnet_fpn.py
@@ -1,5 +1,8 @@
__all__ = [
"yolox_tiny_8x8",
+... | {"golden_diff": "diff --git a/icevision/models/mmdet/models/yolox/backbones/resnet_fpn.py b/icevision/models/mmdet/models/yolox/backbones/resnet_fpn.py\n--- a/icevision/models/mmdet/models/yolox/backbones/resnet_fpn.py\n+++ b/icevision/models/mmdet/models/yolox/backbones/resnet_fpn.py\n@@ -1,5 +1,8 @@\n __all__ = [\n ... | 566 | 609 |
gh_patches_debug_57766 | rasdani/github-patches | git_diff | openstates__openstates-scrapers-2289 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
InsecureRequestWarning log spam
Scrape logs for https sites are spammed with this INFO-level message on every HTTPS request:
```
/opt/openstates/venv-pupa/lib/python3.5/site-packages/urllib3/connectionpool.... | diff --git a/openstates/__init__.py b/openstates/__init__.py
--- a/openstates/__init__.py
+++ b/openstates/__init__.py
@@ -0,0 +1,4 @@
+import urllib3
+
+# Quell InsecureRequestWarning: Unverified HTTPS request warnings
+urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning)
| {"golden_diff": "diff --git a/openstates/__init__.py b/openstates/__init__.py\n--- a/openstates/__init__.py\n+++ b/openstates/__init__.py\n@@ -0,0 +1,4 @@\n+import urllib3\n+\n+# Quell InsecureRequestWarning: Unverified HTTPS request warnings\n+urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning)\n", "is... | 463 | 81 |
gh_patches_debug_18730 | rasdani/github-patches | git_diff | microsoft__botbuilder-python-1671 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[Dialogs] InputHint is hardcoded for AttachmentPrompt as expecting_input
## Version
4.12.0
## Describe the bug
In the [AttachmentPrompt](https://github.com/microsoft/botbuilder-python/blame/main/librarie... | diff --git a/libraries/botbuilder-dialogs/botbuilder/dialogs/prompts/attachment_prompt.py b/libraries/botbuilder-dialogs/botbuilder/dialogs/prompts/attachment_prompt.py
--- a/libraries/botbuilder-dialogs/botbuilder/dialogs/prompts/attachment_prompt.py
+++ b/libraries/botbuilder-dialogs/botbuilder/dialogs/prompts/attach... | {"golden_diff": "diff --git a/libraries/botbuilder-dialogs/botbuilder/dialogs/prompts/attachment_prompt.py b/libraries/botbuilder-dialogs/botbuilder/dialogs/prompts/attachment_prompt.py\n--- a/libraries/botbuilder-dialogs/botbuilder/dialogs/prompts/attachment_prompt.py\n+++ b/libraries/botbuilder-dialogs/botbuilder/dia... | 1,340 | 225 |
gh_patches_debug_5994 | rasdani/github-patches | git_diff | matrix-org__synapse-5930 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add a m.id_access_token flag to unstable_features
For https://github.com/matrix-org/synapse/issues/5786#issuecomment-523879040
--- END ISSUE ---
Below are some code segments, each from a relevant file. One ... | diff --git a/synapse/rest/client/versions.py b/synapse/rest/client/versions.py
--- a/synapse/rest/client/versions.py
+++ b/synapse/rest/client/versions.py
@@ -44,7 +44,12 @@
"r0.5.0",
],
# as per MSC1497:
- "unstable_features": {"m.lazy_load_members"... | {"golden_diff": "diff --git a/synapse/rest/client/versions.py b/synapse/rest/client/versions.py\n--- a/synapse/rest/client/versions.py\n+++ b/synapse/rest/client/versions.py\n@@ -44,7 +44,12 @@\n \"r0.5.0\",\n ],\n # as per MSC1497:\n- \"unstable_featur... | 844 | 164 |
gh_patches_debug_43915 | rasdani/github-patches | git_diff | OCA__server-tools-260 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[8.0] base_report_auto_create_qweb - it does not create qweb views
Tested on runbot.
When creating a new report it seems that it does not create the views. So you can not configure a new one.
--- END ISSUE... | diff --git a/base_report_auto_create_qweb/__openerp__.py b/base_report_auto_create_qweb/__openerp__.py
--- a/base_report_auto_create_qweb/__openerp__.py
+++ b/base_report_auto_create_qweb/__openerp__.py
@@ -22,12 +22,17 @@
"depends": [
"report",
],
+ "external_dependencies": {
+ "python": [... | {"golden_diff": "diff --git a/base_report_auto_create_qweb/__openerp__.py b/base_report_auto_create_qweb/__openerp__.py\n--- a/base_report_auto_create_qweb/__openerp__.py\n+++ b/base_report_auto_create_qweb/__openerp__.py\n@@ -22,12 +22,17 @@\n \"depends\": [\n \"report\",\n ],\n+ \"external_dependen... | 1,946 | 981 |
gh_patches_debug_37939 | rasdani/github-patches | git_diff | scrapy__scrapy-1220 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Improve structure of Scrapy settings documentation
#515 got me thinking that some Scrapy settings are missed because they aren't documented in the main settings page (`docs/topics/settings.rst`).
One approac... | diff --git a/docs/_ext/scrapydocs.py b/docs/_ext/scrapydocs.py
--- a/docs/_ext/scrapydocs.py
+++ b/docs/_ext/scrapydocs.py
@@ -1,5 +1,82 @@
from docutils.parsers.rst.roles import set_classes
from docutils import nodes
+from sphinx.util.compat import Directive
+from sphinx.util.nodes import make_refnode
+from operator... | {"golden_diff": "diff --git a/docs/_ext/scrapydocs.py b/docs/_ext/scrapydocs.py\n--- a/docs/_ext/scrapydocs.py\n+++ b/docs/_ext/scrapydocs.py\n@@ -1,5 +1,82 @@\n from docutils.parsers.rst.roles import set_classes\n from docutils import nodes\n+from sphinx.util.compat import Directive\n+from sphinx.util.nodes import mak... | 1,084 | 830 |
gh_patches_debug_39348 | rasdani/github-patches | git_diff | alltheplaces__alltheplaces-8364 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Problems with Spiders built on YextSpider
I've noticed a few of the spiders whose results I was using in my OSM tool have recently stopped returning any results, including five_guys_de_es_fr_gb.py , matalan_g... | diff --git a/locations/spiders/tropical_smoothie_cafe_us.py b/locations/spiders/tropical_smoothie_cafe_us.py
--- a/locations/spiders/tropical_smoothie_cafe_us.py
+++ b/locations/spiders/tropical_smoothie_cafe_us.py
@@ -1,24 +1,21 @@
-from locations.categories import Extras, PaymentMethods, apply_yes_no
-from locations.... | {"golden_diff": "diff --git a/locations/spiders/tropical_smoothie_cafe_us.py b/locations/spiders/tropical_smoothie_cafe_us.py\n--- a/locations/spiders/tropical_smoothie_cafe_us.py\n+++ b/locations/spiders/tropical_smoothie_cafe_us.py\n@@ -1,24 +1,21 @@\n-from locations.categories import Extras, PaymentMethods, apply_ye... | 1,748 | 931 |
gh_patches_debug_8426 | rasdani/github-patches | git_diff | Zeroto521__my-data-toolkit-822 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
BUG: `DataFrame.to_geoframe` will ignore GeoDataFrame type
```python
>>> import dtoolkit.geoaccessor
>>> import geopandas as gpd
>>> from shapely import Point
>>> df = gpd.GeoDataFrame(
... {
... ... | diff --git a/dtoolkit/geoaccessor/dataframe/to_geoframe.py b/dtoolkit/geoaccessor/dataframe/to_geoframe.py
--- a/dtoolkit/geoaccessor/dataframe/to_geoframe.py
+++ b/dtoolkit/geoaccessor/dataframe/to_geoframe.py
@@ -101,15 +101,6 @@
- Prime Meridian: Greenwich
"""
- return (
- gpd.GeoDataFrame(
- ... | {"golden_diff": "diff --git a/dtoolkit/geoaccessor/dataframe/to_geoframe.py b/dtoolkit/geoaccessor/dataframe/to_geoframe.py\n--- a/dtoolkit/geoaccessor/dataframe/to_geoframe.py\n+++ b/dtoolkit/geoaccessor/dataframe/to_geoframe.py\n@@ -101,15 +101,6 @@\n - Prime Meridian: Greenwich\n \"\"\"\n \n- return (\n- ... | 1,769 | 241 |
gh_patches_debug_31033 | rasdani/github-patches | git_diff | zulip__zulip-12240 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add delimiter between paragraphs and bullets in open graph descriptions
Split from #12178
> I think we might want to make consider making bulleted lists have some sort of delimeter between the bullets (se... | diff --git a/zerver/lib/html_to_text.py b/zerver/lib/html_to_text.py
--- a/zerver/lib/html_to_text.py
+++ b/zerver/lib/html_to_text.py
@@ -1,4 +1,4 @@
-from typing import List, Optional
+from typing import Dict, Optional
from bs4 import BeautifulSoup
from django.http import HttpRequest
@@ -6,7 +6,7 @@
from zerve... | {"golden_diff": "diff --git a/zerver/lib/html_to_text.py b/zerver/lib/html_to_text.py\n--- a/zerver/lib/html_to_text.py\n+++ b/zerver/lib/html_to_text.py\n@@ -1,4 +1,4 @@\n-from typing import List, Optional\n+from typing import Dict, Optional\n \n from bs4 import BeautifulSoup\n from django.http import HttpRequest\n@@ ... | 948 | 468 |
gh_patches_debug_33800 | rasdani/github-patches | git_diff | Qiskit__qiskit-7426 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
SuzukiTrotter class should not accept odd orders
### Environment
- **Qiskit Terra version**:
- **Python version**:
- **Operating system**:
It applies to all environments.
### What is happening?
The S... | diff --git a/qiskit/synthesis/evolution/suzuki_trotter.py b/qiskit/synthesis/evolution/suzuki_trotter.py
--- a/qiskit/synthesis/evolution/suzuki_trotter.py
+++ b/qiskit/synthesis/evolution/suzuki_trotter.py
@@ -13,7 +13,10 @@
"""The Suzuki-Trotter product formula."""
from typing import Callable, Optional, Union
+
+... | {"golden_diff": "diff --git a/qiskit/synthesis/evolution/suzuki_trotter.py b/qiskit/synthesis/evolution/suzuki_trotter.py\n--- a/qiskit/synthesis/evolution/suzuki_trotter.py\n+++ b/qiskit/synthesis/evolution/suzuki_trotter.py\n@@ -13,7 +13,10 @@\n \"\"\"The Suzuki-Trotter product formula.\"\"\"\n \n from typing import ... | 2,041 | 484 |
gh_patches_debug_21057 | rasdani/github-patches | git_diff | networktocode__ntc-templates-1682 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Need to raise custom exception
https://github.com/networktocode/ntc-templates/blob/923f9afe679f549d14079c4ec962cc913f784550/ntc_templates/parse.py#L38
Currently `parse_output` raises a generic `Exception`;... | diff --git a/ntc_templates/parse.py b/ntc_templates/parse.py
--- a/ntc_templates/parse.py
+++ b/ntc_templates/parse.py
@@ -12,6 +12,10 @@
HAS_CLITABLE = False
+class ParsingException(Exception):
+ """Error that is raised when TextFSM hits an `Error` state."""
+
+
def _get_template_dir():
template_dir ... | {"golden_diff": "diff --git a/ntc_templates/parse.py b/ntc_templates/parse.py\n--- a/ntc_templates/parse.py\n+++ b/ntc_templates/parse.py\n@@ -12,6 +12,10 @@\n HAS_CLITABLE = False\n \n \n+class ParsingException(Exception):\n+ \"\"\"Error that is raised when TextFSM hits an `Error` state.\"\"\"\n+\n+\n def _get_... | 1,017 | 267 |
gh_patches_debug_22541 | rasdani/github-patches | git_diff | Kinto__kinto-1817 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Per collection caching using dot separator
Per collection caching can be configured in settings using `_` as separator:
```ini
kinto.bid_cid_record_cache_expires_seconds = 60
```
Since `_` is valid char... | diff --git a/kinto/views/records.py b/kinto/views/records.py
--- a/kinto/views/records.py
+++ b/kinto/views/records.py
@@ -104,12 +104,16 @@
cache_expires = self._collection.get('cache_expires')
if cache_expires is None:
- by_bucket = '{}_record_cache_expires_seconds'.format(self.bucket_i... | {"golden_diff": "diff --git a/kinto/views/records.py b/kinto/views/records.py\n--- a/kinto/views/records.py\n+++ b/kinto/views/records.py\n@@ -104,12 +104,16 @@\n \n cache_expires = self._collection.get('cache_expires')\n if cache_expires is None:\n- by_bucket = '{}_record_cache_expires_secon... | 1,473 | 289 |
gh_patches_debug_17085 | rasdani/github-patches | git_diff | OpenMined__PySyft-122 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Implement Default sum Functionality for Base Tensor Type
**User Story A:** As a Data Scientist using Syft's Base Tensor type, I want to leverage a default method for computing operations on a Tensor of arbitr... | diff --git a/syft/tensor.py b/syft/tensor.py
--- a/syft/tensor.py
+++ b/syft/tensor.py
@@ -8,7 +8,7 @@
class TensorBase(object):
"""
- A base tensor class that perform basic element-wise operation such as
+ A base tensor class that perform basic element-wise operation such as
addition, subtraction, ... | {"golden_diff": "diff --git a/syft/tensor.py b/syft/tensor.py\n--- a/syft/tensor.py\n+++ b/syft/tensor.py\n@@ -8,7 +8,7 @@\n \n class TensorBase(object):\n \"\"\"\n- A base tensor class that perform basic element-wise operation such as \n+ A base tensor class that perform basic element-wise operation such as\... | 1,174 | 238 |
gh_patches_debug_29223 | rasdani/github-patches | git_diff | great-expectations__great_expectations-6876 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Use cleaner solution for non-truncating division in python 2
Prefer `from __future__ import division` to `1.*x/y`
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of th... | diff --git a/great_expectations/expectations/core/expect_column_values_to_not_match_like_pattern.py b/great_expectations/expectations/core/expect_column_values_to_not_match_like_pattern.py
--- a/great_expectations/expectations/core/expect_column_values_to_not_match_like_pattern.py
+++ b/great_expectations/expectations/... | {"golden_diff": "diff --git a/great_expectations/expectations/core/expect_column_values_to_not_match_like_pattern.py b/great_expectations/expectations/core/expect_column_values_to_not_match_like_pattern.py\n--- a/great_expectations/expectations/core/expect_column_values_to_not_match_like_pattern.py\n+++ b/great_expecta... | 1,787 | 370 |
gh_patches_debug_52459 | rasdani/github-patches | git_diff | iterative__dvc-1749 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
cache: dir option is not working correctly
version: `0.32.1`
-----
It raises an error when using the command:
```bash
❯ dvc cache dir
Error: unexpected error - 'NoneType' object has no attribute 'sta... | diff --git a/dvc/command/cache.py b/dvc/command/cache.py
--- a/dvc/command/cache.py
+++ b/dvc/command/cache.py
@@ -53,7 +53,6 @@
)
cache_dir_parser.add_argument(
"value",
- nargs="?",
default=None,
help="Path to cache directory. Relative paths are resolved relative "
... | {"golden_diff": "diff --git a/dvc/command/cache.py b/dvc/command/cache.py\n--- a/dvc/command/cache.py\n+++ b/dvc/command/cache.py\n@@ -53,7 +53,6 @@\n )\n cache_dir_parser.add_argument(\n \"value\",\n- nargs=\"?\",\n default=None,\n help=\"Path to cache directory. Relative paths a... | 839 | 94 |
gh_patches_debug_33428 | rasdani/github-patches | git_diff | litestar-org__litestar-3418 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Bug: minijinja import too early on FlashPlugin
### Description
error is:
```
❯ python main.py
Traceback (most recent call last):
File "/home/lotso/.cache/pypoetry/virtualenvs/tt-n-gxmD69-py3.12/lib/py... | diff --git a/litestar/plugins/flash.py b/litestar/plugins/flash.py
--- a/litestar/plugins/flash.py
+++ b/litestar/plugins/flash.py
@@ -1,16 +1,22 @@
"""Plugin for creating and retrieving flash messages."""
+from __future__ import annotations
+
from dataclasses import dataclass
-from typing import Any, Mapping
+from... | {"golden_diff": "diff --git a/litestar/plugins/flash.py b/litestar/plugins/flash.py\n--- a/litestar/plugins/flash.py\n+++ b/litestar/plugins/flash.py\n@@ -1,16 +1,22 @@\n \"\"\"Plugin for creating and retrieving flash messages.\"\"\"\n \n+from __future__ import annotations\n+\n from dataclasses import dataclass\n-from ... | 1,731 | 484 |
gh_patches_debug_38506 | rasdani/github-patches | git_diff | pre-commit__pre-commit-1572 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
faster check for docker running
currently this is how pre-commit checks if docker is available:
https://github.com/pre-commit/pre-commit/blob/9a5461db24beeee9960423b853cfbfbaefb6cc7a/pre_commit/languages/d... | diff --git a/pre_commit/languages/docker.py b/pre_commit/languages/docker.py
--- a/pre_commit/languages/docker.py
+++ b/pre_commit/languages/docker.py
@@ -7,9 +7,7 @@
from pre_commit.hook import Hook
from pre_commit.languages import helpers
from pre_commit.prefix import Prefix
-from pre_commit.util import CalledProc... | {"golden_diff": "diff --git a/pre_commit/languages/docker.py b/pre_commit/languages/docker.py\n--- a/pre_commit/languages/docker.py\n+++ b/pre_commit/languages/docker.py\n@@ -7,9 +7,7 @@\n from pre_commit.hook import Hook\n from pre_commit.languages import helpers\n from pre_commit.prefix import Prefix\n-from pre_commi... | 1,815 | 582 |
gh_patches_debug_7169 | rasdani/github-patches | git_diff | google__osv.dev-447 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Clarify max query limit on bulk query endpoint
Looks like there's [a limit to the number of queries](https://github.com/google/osv/blob/168a6b2c593d4fac2defbc8546e634256cdfa5b0/gcp/api/server.py#L92-L94) that... | diff --git a/gcp/api/osv_service_v1_pb2_grpc.py b/gcp/api/osv_service_v1_pb2_grpc.py
--- a/gcp/api/osv_service_v1_pb2_grpc.py
+++ b/gcp/api/osv_service_v1_pb2_grpc.py
@@ -54,6 +54,7 @@
def QueryAffectedBatch(self, request, context):
"""Query vulnerabilities (batched) for given package versions and commi... | {"golden_diff": "diff --git a/gcp/api/osv_service_v1_pb2_grpc.py b/gcp/api/osv_service_v1_pb2_grpc.py\n--- a/gcp/api/osv_service_v1_pb2_grpc.py\n+++ b/gcp/api/osv_service_v1_pb2_grpc.py\n@@ -54,6 +54,7 @@\n \n def QueryAffectedBatch(self, request, context):\n \"\"\"Query vulnerabilities (batched) for given ... | 1,948 | 148 |
gh_patches_debug_1976 | rasdani/github-patches | git_diff | spotify__luigi-1809 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Terminal Width affects Lock identification under Centos 6.5
The luigi.lock.getpcmd function will return a shorter command line if the terminal is smaller in width. This can result in locks being misidentified... | diff --git a/luigi/lock.py b/luigi/lock.py
--- a/luigi/lock.py
+++ b/luigi/lock.py
@@ -42,7 +42,7 @@
_, val = lines
return val
else:
- cmd = 'ps -xo pid,args'
+ cmd = 'ps x -wwo pid,args'
with os.popen(cmd, 'r') as p:
# Skip the column titles
... | {"golden_diff": "diff --git a/luigi/lock.py b/luigi/lock.py\n--- a/luigi/lock.py\n+++ b/luigi/lock.py\n@@ -42,7 +42,7 @@\n _, val = lines\n return val\n else:\n- cmd = 'ps -xo pid,args'\n+ cmd = 'ps x -wwo pid,args'\n with os.popen(cmd, 'r') as p:\n ... | 1,641 | 109 |
gh_patches_debug_3084 | rasdani/github-patches | git_diff | coala__coala-bears-2837 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
PySafetyBear: Add asciinema
Content of file on Bear will perform it's action also have to shown in asciinema.
difficulty/newcomer
--- END ISSUE ---
Below are some code segments, each from a relevant fil... | diff --git a/bears/python/requirements/PySafetyBear.py b/bears/python/requirements/PySafetyBear.py
--- a/bears/python/requirements/PySafetyBear.py
+++ b/bears/python/requirements/PySafetyBear.py
@@ -64,6 +64,7 @@
AUTHORS_EMAILS = {'bence@underyx.me'}
LICENSE = 'AGPL'
CAN_DETECT = {'Security'}
+ ASCIIN... | {"golden_diff": "diff --git a/bears/python/requirements/PySafetyBear.py b/bears/python/requirements/PySafetyBear.py\n--- a/bears/python/requirements/PySafetyBear.py\n+++ b/bears/python/requirements/PySafetyBear.py\n@@ -64,6 +64,7 @@\n AUTHORS_EMAILS = {'bence@underyx.me'}\n LICENSE = 'AGPL'\n CAN_DETECT = {... | 1,704 | 137 |
gh_patches_debug_13759 | rasdani/github-patches | git_diff | svthalia__concrexit-1721 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Groups miss description in API v2
### Describe the bug
The `description` field is missing in the `activemembers/groups` serializers.
### How to reproduce
Look at swagger.
### Expected behaviour
An e... | diff --git a/website/activemembers/api/v2/serializers/member_group.py b/website/activemembers/api/v2/serializers/member_group.py
--- a/website/activemembers/api/v2/serializers/member_group.py
+++ b/website/activemembers/api/v2/serializers/member_group.py
@@ -24,6 +24,7 @@
"pk",
"name",
... | {"golden_diff": "diff --git a/website/activemembers/api/v2/serializers/member_group.py b/website/activemembers/api/v2/serializers/member_group.py\n--- a/website/activemembers/api/v2/serializers/member_group.py\n+++ b/website/activemembers/api/v2/serializers/member_group.py\n@@ -24,6 +24,7 @@\n \"pk\",\n ... | 864 | 217 |
gh_patches_debug_28950 | rasdani/github-patches | git_diff | Gallopsled__pwntools-234 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add a rst file for useragents.
There is no rst file for the useragents module, so there is no documentation on readthedocs either.
Found in #211.
--- END ISSUE ---
Below are some code segments, each from ... | diff --git a/pwnlib/useragents.py b/pwnlib/useragents.py
--- a/pwnlib/useragents.py
+++ b/pwnlib/useragents.py
@@ -1,5 +1,5 @@
"""
-Database of 22,000 user agent strings
+Database of >22,000 user agent strings
"""
__all__ = ['getall', 'random']
@@ -52,6 +52,6 @@
>>> import random as randommod
>>> randomm... | {"golden_diff": "diff --git a/pwnlib/useragents.py b/pwnlib/useragents.py\n--- a/pwnlib/useragents.py\n+++ b/pwnlib/useragents.py\n@@ -1,5 +1,5 @@\n \"\"\"\n-Database of 22,000 user agent strings\n+Database of >22,000 user agent strings\n \"\"\"\n __all__ = ['getall', 'random']\n \n@@ -52,6 +52,6 @@\n >>> import ra... | 1,791 | 528 |
gh_patches_debug_18156 | rasdani/github-patches | git_diff | electricitymaps__electricitymaps-contrib-1486 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
US-IPC is occasionally missing a key
```
Traceback (most recent call last):
File "/home/feeder/lib/fetch_data.py", line 130, in launch_parsers
**parser_kwargs)
File "/home/electricitymap/parsers/U... | diff --git a/parsers/US_IPC.py b/parsers/US_IPC.py
--- a/parsers/US_IPC.py
+++ b/parsers/US_IPC.py
@@ -12,7 +12,7 @@
# https://docs.idahopower.com/pdfs/AboutUs/PlanningForFuture/irp/IRP.pdf
# Renewable energy (PURPA) is likely bought with credits from outside the Utility
-# area and not supplied to customers. For t... | {"golden_diff": "diff --git a/parsers/US_IPC.py b/parsers/US_IPC.py\n--- a/parsers/US_IPC.py\n+++ b/parsers/US_IPC.py\n@@ -12,7 +12,7 @@\n # https://docs.idahopower.com/pdfs/AboutUs/PlanningForFuture/irp/IRP.pdf\n \n # Renewable energy (PURPA) is likely bought with credits from outside the Utility\n-# area and not supp... | 1,821 | 224 |
gh_patches_debug_40663 | rasdani/github-patches | git_diff | rasterio__rasterio-1782 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Automatic computation of zoom levels for rio overwiew
Since GDAL 2.3 in gdaladdo it is [possible](https://www.gdal.org/gdaladdo.html) to omit the list of overview factors. But it looks like `rio overwiew` doe... | diff --git a/rasterio/rio/overview.py b/rasterio/rio/overview.py
--- a/rasterio/rio/overview.py
+++ b/rasterio/rio/overview.py
@@ -19,19 +19,52 @@
base, exp_range = value.split('^')
exp_min, exp_max = (int(v) for v in exp_range.split('..'))
value = [pow(int(base), k) f... | {"golden_diff": "diff --git a/rasterio/rio/overview.py b/rasterio/rio/overview.py\n--- a/rasterio/rio/overview.py\n+++ b/rasterio/rio/overview.py\n@@ -19,19 +19,52 @@\n base, exp_range = value.split('^')\n exp_min, exp_max = (int(v) for v in exp_range.split('..'))\n value... | 1,360 | 815 |
gh_patches_debug_26092 | rasdani/github-patches | git_diff | twisted__twisted-11749 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Remove check for PR links to issue IDs
> If this is a pain there are 2 options:
It does just seem to be the most common type of misconfiguration, which I bump into on almost every code review or su... | diff --git a/.github/scripts/check-pr-text.py b/.github/scripts/check-pr-text.py
deleted file mode 100644
--- a/.github/scripts/check-pr-text.py
+++ /dev/null
@@ -1,64 +0,0 @@
-#
-# This script is designed to be called by the GHA workflow.
-#
-# It is designed to check that the PR text complies to our dev standards.
-#... | {"golden_diff": "diff --git a/.github/scripts/check-pr-text.py b/.github/scripts/check-pr-text.py\ndeleted file mode 100644\n--- a/.github/scripts/check-pr-text.py\n+++ /dev/null\n@@ -1,64 +0,0 @@\n-#\n-# This script is designed to be called by the GHA workflow.\n-#\n-# It is designed to check that the PR text complies... | 964 | 549 |
gh_patches_debug_7789 | rasdani/github-patches | git_diff | deepchecks__deepchecks-645 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[TYPO] Label ambiguity explanation
Current explanation: "Each row in the table shows an example of a data sample and the it's observed labels as a found in the dataset."
--- END ISSUE ---
Below are some cod... | diff --git a/deepchecks/checks/integrity/label_ambiguity.py b/deepchecks/checks/integrity/label_ambiguity.py
--- a/deepchecks/checks/integrity/label_ambiguity.py
+++ b/deepchecks/checks/integrity/label_ambiguity.py
@@ -98,7 +98,7 @@
display = display.set_index(ambiguous_label_name)
explanation = ('E... | {"golden_diff": "diff --git a/deepchecks/checks/integrity/label_ambiguity.py b/deepchecks/checks/integrity/label_ambiguity.py\n--- a/deepchecks/checks/integrity/label_ambiguity.py\n+++ b/deepchecks/checks/integrity/label_ambiguity.py\n@@ -98,7 +98,7 @@\n display = display.set_index(ambiguous_label_name)\n \n ... | 1,596 | 160 |
gh_patches_debug_58533 | rasdani/github-patches | git_diff | shuup__shuup-1665 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add option to remove coupon code from basket
There isn't option to remove coupon code from basket. Should likely be done with basket command at basket view [this](https://github.com/shuup/shuup/blob/master/sh... | diff --git a/shuup/front/basket/commands.py b/shuup/front/basket/commands.py
--- a/shuup/front/basket/commands.py
+++ b/shuup/front/basket/commands.py
@@ -7,5 +7,5 @@
# LICENSE file in the root directory of this source tree.
from shuup.core.basket.commands import ( # noqa
handle_add, handle_add_campaign_code, h... | {"golden_diff": "diff --git a/shuup/front/basket/commands.py b/shuup/front/basket/commands.py\n--- a/shuup/front/basket/commands.py\n+++ b/shuup/front/basket/commands.py\n@@ -7,5 +7,5 @@\n # LICENSE file in the root directory of this source tree.\n from shuup.core.basket.commands import ( # noqa\n handle_add, hand... | 452 | 122 |
gh_patches_debug_15667 | rasdani/github-patches | git_diff | pyload__pyload-1375 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Uplea plugin out of date (#1348 closed but still not working)
Hi,
now pyload reports failure, logs show:
26 25.04.2015 12:19:27 WARNING Download failed: ****\* | Missing HOSTER_DOMAIN
25 25.04.2015 12:19:27 I... | diff --git a/module/plugins/hoster/UpleaCom.py b/module/plugins/hoster/UpleaCom.py
--- a/module/plugins/hoster/UpleaCom.py
+++ b/module/plugins/hoster/UpleaCom.py
@@ -10,7 +10,7 @@
class UpleaCom(XFSHoster):
__name__ = "UpleaCom"
__type__ = "hoster"
- __version__ = "0.07"
+ __version__ = "0.08"
... | {"golden_diff": "diff --git a/module/plugins/hoster/UpleaCom.py b/module/plugins/hoster/UpleaCom.py\n--- a/module/plugins/hoster/UpleaCom.py\n+++ b/module/plugins/hoster/UpleaCom.py\n@@ -10,7 +10,7 @@\n class UpleaCom(XFSHoster):\n __name__ = \"UpleaCom\"\n __type__ = \"hoster\"\n- __version__ = \"0.07... | 1,038 | 244 |
gh_patches_debug_12607 | rasdani/github-patches | git_diff | chainer__chainer-285 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
A confusing error occurs when GPU and CPU arrays are mixed on `numerical_grad`
In this case, unreadable error occurs. We nee to check if arrays are not mixed.
--- END ISSUE ---
Below are some code segments... | diff --git a/chainer/gradient_check.py b/chainer/gradient_check.py
--- a/chainer/gradient_check.py
+++ b/chainer/gradient_check.py
@@ -73,9 +73,18 @@
"""
assert eps > 0
- if any(isinstance(x, cuda.GPUArray) for x in inputs):
+ inputs = tuple(inputs)
+ grad_outputs = tuple(grad_outputs)
+ gpu = a... | {"golden_diff": "diff --git a/chainer/gradient_check.py b/chainer/gradient_check.py\n--- a/chainer/gradient_check.py\n+++ b/chainer/gradient_check.py\n@@ -73,9 +73,18 @@\n \n \"\"\"\n assert eps > 0\n- if any(isinstance(x, cuda.GPUArray) for x in inputs):\n+ inputs = tuple(inputs)\n+ grad_outputs = tup... | 1,312 | 240 |
gh_patches_debug_21649 | rasdani/github-patches | git_diff | carpentries__amy-1439 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Membership edit fails due to form errors
The error is due to missing `comment` field in `MembershipForm`.
`MembershipForm.save()` should be placed in `MembershipCreateForm`, because that's where `comment` ... | diff --git a/amy/fiscal/forms.py b/amy/fiscal/forms.py
--- a/amy/fiscal/forms.py
+++ b/amy/fiscal/forms.py
@@ -92,16 +92,6 @@
'additional_instructor_training_seats',
]
- def save(self, *args, **kwargs):
- res = super().save(*args, **kwargs)
-
- create_comment_signal.send(sender=... | {"golden_diff": "diff --git a/amy/fiscal/forms.py b/amy/fiscal/forms.py\n--- a/amy/fiscal/forms.py\n+++ b/amy/fiscal/forms.py\n@@ -92,16 +92,6 @@\n 'additional_instructor_training_seats',\n ]\n \n- def save(self, *args, **kwargs):\n- res = super().save(*args, **kwargs)\n-\n- create_... | 1,531 | 250 |
gh_patches_debug_41912 | rasdani/github-patches | git_diff | conan-io__conan-center-index-6181 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[package] xerces-c/3.2.3: xmlch-type should be a package option
<!--
Please don't forget to update the issue title.
Include all applicable information to help us reproduce your problem.
-->
### Pac... | diff --git a/recipes/xerces-c/all/conanfile.py b/recipes/xerces-c/all/conanfile.py
--- a/recipes/xerces-c/all/conanfile.py
+++ b/recipes/xerces-c/all/conanfile.py
@@ -5,7 +5,9 @@
class XercesCConan(ConanFile):
name = "xerces-c"
- description = "Xerces-C++ is a validating XML parser written in a portable subs... | {"golden_diff": "diff --git a/recipes/xerces-c/all/conanfile.py b/recipes/xerces-c/all/conanfile.py\n--- a/recipes/xerces-c/all/conanfile.py\n+++ b/recipes/xerces-c/all/conanfile.py\n@@ -5,7 +5,9 @@\n \n class XercesCConan(ConanFile):\n name = \"xerces-c\"\n- description = \"Xerces-C++ is a validating XML parser... | 1,885 | 915 |
gh_patches_debug_59228 | rasdani/github-patches | git_diff | scikit-hep__awkward-1835 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Awkward v2 mixins not propagated upwards
### Version of Awkward Array
2.0.0rc1
### Description and code to reproduce
Coffea tests with awkwardv2 fail with: `E AttributeError: module 'awkward.behavi... | diff --git a/src/awkward/__init__.py b/src/awkward/__init__.py
--- a/src/awkward/__init__.py
+++ b/src/awkward/__init__.py
@@ -39,8 +39,8 @@
# behaviors
import awkward.behaviors.categorical
-import awkward.behaviors.mixins
import awkward.behaviors.string
+from awkward.behaviors.mixins import mixin_class, mixin_cla... | {"golden_diff": "diff --git a/src/awkward/__init__.py b/src/awkward/__init__.py\n--- a/src/awkward/__init__.py\n+++ b/src/awkward/__init__.py\n@@ -39,8 +39,8 @@\n \n # behaviors\n import awkward.behaviors.categorical\n-import awkward.behaviors.mixins\n import awkward.behaviors.string\n+from awkward.behaviors.mixins imp... | 831 | 115 |
gh_patches_debug_32164 | rasdani/github-patches | git_diff | quantumlib__Cirq-3644 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Sweepable is actually a recursive type
The current type signature of Sweepable is
```
Sweepable = Union[Dict[str, float], ParamResolver, Sweep, Iterable[
Union[Dict[str, float], ParamResolver, Sweep]],... | diff --git a/cirq/study/sweepable.py b/cirq/study/sweepable.py
--- a/cirq/study/sweepable.py
+++ b/cirq/study/sweepable.py
@@ -16,17 +16,27 @@
from typing import Dict, Iterable, Iterator, List, Sequence, Union, cast
import warnings
+from typing_extensions import Protocol
from cirq._doc import document
from cirq... | {"golden_diff": "diff --git a/cirq/study/sweepable.py b/cirq/study/sweepable.py\n--- a/cirq/study/sweepable.py\n+++ b/cirq/study/sweepable.py\n@@ -16,17 +16,27 @@\n \n from typing import Dict, Iterable, Iterator, List, Sequence, Union, cast\n import warnings\n+from typing_extensions import Protocol\n \n from cirq._doc ... | 1,581 | 478 |
gh_patches_debug_20631 | rasdani/github-patches | git_diff | facebookresearch__xformers-401 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Make optional Triton requirement more robust
# 🐛 Bug
Triton is currently an optional dependency, see
https://github.com/facebookresearch/xformers/blob/51dd1192620271598ba71bb1351c1c5508720b31/xformers/__... | diff --git a/xformers/__init__.py b/xformers/__init__.py
--- a/xformers/__init__.py
+++ b/xformers/__init__.py
@@ -75,9 +75,9 @@
if _is_triton_available:
try:
from xformers.triton.softmax import softmax as triton_softmax # noqa
- except ImportError as e:
+ except (ImportError, AttributeError) as e... | {"golden_diff": "diff --git a/xformers/__init__.py b/xformers/__init__.py\n--- a/xformers/__init__.py\n+++ b/xformers/__init__.py\n@@ -75,9 +75,9 @@\n if _is_triton_available:\n try:\n from xformers.triton.softmax import softmax as triton_softmax # noqa\n- except ImportError as e:\n+ except (ImportEr... | 1,264 | 266 |
gh_patches_debug_24131 | rasdani/github-patches | git_diff | pypa__setuptools-958 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
bootstrap script cannot be executed without setuptools already installed
The `bootstrap.py` script cannot be used to bootstrap from an environment without setuptools. The script imports `pip` which requires ... | diff --git a/bootstrap.py b/bootstrap.py
--- a/bootstrap.py
+++ b/bootstrap.py
@@ -7,6 +7,7 @@
from __future__ import unicode_literals
+import argparse
import os
import io
import re
@@ -17,7 +18,6 @@
import textwrap
import subprocess
-import pip
minimal_egg_info = textwrap.dedent("""
[distutils.comm... | {"golden_diff": "diff --git a/bootstrap.py b/bootstrap.py\n--- a/bootstrap.py\n+++ b/bootstrap.py\n@@ -7,6 +7,7 @@\n \n from __future__ import unicode_literals\n \n+import argparse\n import os\n import io\n import re\n@@ -17,7 +18,6 @@\n import textwrap\n import subprocess\n \n-import pip\n \n minimal_egg_info = textwr... | 1,120 | 276 |
gh_patches_debug_28624 | rasdani/github-patches | git_diff | pytorch__vision-7500 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
AttributeError: '_OpNamespace' 'torchvision' object has no attribute 'roi_align'
Hi, I'm getting the following error while running the e2e tests in Torch-MLIR. I'm trying to get a small reproducible for the ... | diff --git a/torchvision/_meta_registrations.py b/torchvision/_meta_registrations.py
--- a/torchvision/_meta_registrations.py
+++ b/torchvision/_meta_registrations.py
@@ -1,3 +1,5 @@
+import functools
+
import torch
import torch.library
@@ -6,20 +8,22 @@
from torch._prims_common import check
-_meta_lib = torch... | {"golden_diff": "diff --git a/torchvision/_meta_registrations.py b/torchvision/_meta_registrations.py\n--- a/torchvision/_meta_registrations.py\n+++ b/torchvision/_meta_registrations.py\n@@ -1,3 +1,5 @@\n+import functools\n+\n import torch\n import torch.library\n \n@@ -6,20 +8,22 @@\n \n from torch._prims_common impor... | 1,488 | 389 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.