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_14876 | rasdani/github-patches | git_diff | pyca__cryptography-2445 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
cryptography.x509.Name implements __eq__ but not __hash__
--- 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/src/cryptography/x509/name.py b/src/cryptography/x509/name.py
--- a/src/cryptography/x509/name.py
+++ b/src/cryptography/x509/name.py
@@ -40,6 +40,9 @@
def __ne__(self, other):
return not self == other
+ def __hash__(self):
+ return hash((self.oid, self.value))
+
def __repr__... | {"golden_diff": "diff --git a/src/cryptography/x509/name.py b/src/cryptography/x509/name.py\n--- a/src/cryptography/x509/name.py\n+++ b/src/cryptography/x509/name.py\n@@ -40,6 +40,9 @@\n def __ne__(self, other):\n return not self == other\n \n+ def __hash__(self):\n+ return hash((self.oid, self.va... | 845 | 215 |
gh_patches_debug_19283 | rasdani/github-patches | git_diff | conda__conda-1735 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Race condition for root environment detection
Periodically, when two conda processes are running at the same time, it is possible to see a race condition on determining whether the root environment is writabl... | diff --git a/conda/utils.py b/conda/utils.py
--- a/conda/utils.py
+++ b/conda/utils.py
@@ -5,8 +5,10 @@
import hashlib
import collections
from functools import partial
-from os.path import abspath, isdir, join
+from os.path import abspath, isdir
import os
+import tempfile
+
log = logging.getLogger(__name__)
std... | {"golden_diff": "diff --git a/conda/utils.py b/conda/utils.py\n--- a/conda/utils.py\n+++ b/conda/utils.py\n@@ -5,8 +5,10 @@\n import hashlib\n import collections\n from functools import partial\n-from os.path import abspath, isdir, join\n+from os.path import abspath, isdir\n import os\n+import tempfile\n+\n \n log = lo... | 2,003 | 261 |
gh_patches_debug_33670 | rasdani/github-patches | git_diff | getredash__redash-1792 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Alert notifications fail (sometime) with a SQLAlchemy error
### Issue Summary
After migrating to 1.0.1 alerts are notified only sporadically to Slack (I cannot pinpoint exactly the conditions in which it h... | diff --git a/redash/destinations/email.py b/redash/destinations/email.py
--- a/redash/destinations/email.py
+++ b/redash/destinations/email.py
@@ -40,16 +40,15 @@
logging.debug("Notifying: %s", recipients)
try:
- with app.app_context():
- alert_name = alert.name.encode('utf... | {"golden_diff": "diff --git a/redash/destinations/email.py b/redash/destinations/email.py\n--- a/redash/destinations/email.py\n+++ b/redash/destinations/email.py\n@@ -40,16 +40,15 @@\n logging.debug(\"Notifying: %s\", recipients)\n \n try:\n- with app.app_context():\n- alert_na... | 1,901 | 503 |
gh_patches_debug_31457 | rasdani/github-patches | git_diff | mozmeao__snippets-service-1206 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Create Freq Capping Goals for Jobs
Create Global Frequency Capping goals for Jobs (introduced in #1034).
Goals:
- Total impressions
- Total clicks and button clicks (combined)
- Total blocks
A `J... | diff --git a/snippets/base/management/commands/update_jobs.py b/snippets/base/management/commands/update_jobs.py
--- a/snippets/base/management/commands/update_jobs.py
+++ b/snippets/base/management/commands/update_jobs.py
@@ -1,4 +1,4 @@
-from datetime import datetime
+from datetime import datetime, timedelta
from ... | {"golden_diff": "diff --git a/snippets/base/management/commands/update_jobs.py b/snippets/base/management/commands/update_jobs.py\n--- a/snippets/base/management/commands/update_jobs.py\n+++ b/snippets/base/management/commands/update_jobs.py\n@@ -1,4 +1,4 @@\n-from datetime import datetime\n+from datetime import dateti... | 1,176 | 440 |
gh_patches_debug_10443 | rasdani/github-patches | git_diff | conan-io__conan-4096 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Conan Server 1.10 is broken
#### Description
Hi!
I'm trying to start conan server but seems like is broken.
$ conan_server
> Traceback (most recent call last):
> File "/opt/miniconda3/bin/con... | diff --git a/conans/server/server_launcher.py b/conans/server/server_launcher.py
--- a/conans/server/server_launcher.py
+++ b/conans/server/server_launcher.py
@@ -44,7 +44,7 @@
self.ra = ConanServer(server_config.port, credentials_manager, updown_auth_manager,
authorizer, authent... | {"golden_diff": "diff --git a/conans/server/server_launcher.py b/conans/server/server_launcher.py\n--- a/conans/server/server_launcher.py\n+++ b/conans/server/server_launcher.py\n@@ -44,7 +44,7 @@\n self.ra = ConanServer(server_config.port, credentials_manager, updown_auth_manager,\n ... | 1,259 | 125 |
gh_patches_debug_9464 | rasdani/github-patches | git_diff | Mailu__Mailu-1358 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add ability to specify SMTP port
Some relayed domains may live on machines that accept SMTP on a nonstandard port, e.g., port 2525. This would allow users to relay for domains by appending `:port` to the host... | diff --git a/core/admin/mailu/internal/views/postfix.py b/core/admin/mailu/internal/views/postfix.py
--- a/core/admin/mailu/internal/views/postfix.py
+++ b/core/admin/mailu/internal/views/postfix.py
@@ -36,7 +36,11 @@
return flask.abort(404)
localpart, domain_name = models.Email.resolve_domain(email)
... | {"golden_diff": "diff --git a/core/admin/mailu/internal/views/postfix.py b/core/admin/mailu/internal/views/postfix.py\n--- a/core/admin/mailu/internal/views/postfix.py\n+++ b/core/admin/mailu/internal/views/postfix.py\n@@ -36,7 +36,11 @@\n return flask.abort(404)\n localpart, domain_name = models.Email.reso... | 1,101 | 197 |
gh_patches_debug_27614 | rasdani/github-patches | git_diff | plone__Products.CMFPlone-2326 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Some Errors cannot render their exceptions during the creation of portal
This is a follow-up for #2203.
A exception of the following type cannot rendered in Plone 5.2:
```
ValueError
Traceback (inne... | diff --git a/Products/CMFPlone/browser/exceptions.py b/Products/CMFPlone/browser/exceptions.py
--- a/Products/CMFPlone/browser/exceptions.py
+++ b/Products/CMFPlone/browser/exceptions.py
@@ -3,7 +3,6 @@
from Products.Five import BrowserView
from Products.Five.browser.pagetemplatefile import ViewPageTemplateFile
from... | {"golden_diff": "diff --git a/Products/CMFPlone/browser/exceptions.py b/Products/CMFPlone/browser/exceptions.py\n--- a/Products/CMFPlone/browser/exceptions.py\n+++ b/Products/CMFPlone/browser/exceptions.py\n@@ -3,7 +3,6 @@\n from Products.Five import BrowserView\n from Products.Five.browser.pagetemplatefile import View... | 1,185 | 352 |
gh_patches_debug_2405 | rasdani/github-patches | git_diff | googleapis__google-api-python-client-1221 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Published package is missing discovery files in discovery_cache
Many thanks to the @wyk9787 for noticing this and reaching out.
All calls to `discovery.build()` using `2.0.0` fail with "unknown api name or... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -60,7 +60,7 @@
install_requires=install_requires,
python_requires=">=3.6",
packages=packages,
- package_data={},
+ package_data={"googleapiclient": ["discovery_cache/documents/*.json"]},
license="Apache 2.0",
keywords="goog... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -60,7 +60,7 @@\n install_requires=install_requires,\n python_requires=\">=3.6\",\n packages=packages,\n- package_data={},\n+ package_data={\"googleapiclient\": [\"discovery_cache/documents/*.json\"]},\n license=\... | 1,245 | 97 |
gh_patches_debug_9729 | rasdani/github-patches | git_diff | gratipay__gratipay.com-1494 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
can't stay logged in
from @amaltson via [Twitter](https://twitter.com/amaltson/status/332678066985893889):
> trying to log in with GitHub, each time I go to my account page, I get logged out..
--- END ISS... | diff --git a/gittip/security/authentication.py b/gittip/security/authentication.py
--- a/gittip/security/authentication.py
+++ b/gittip/security/authentication.py
@@ -3,6 +3,7 @@
import rfc822
import time
+import gittip
from aspen import Response
from gittip.security import csrf
from gittip.security.user import ... | {"golden_diff": "diff --git a/gittip/security/authentication.py b/gittip/security/authentication.py\n--- a/gittip/security/authentication.py\n+++ b/gittip/security/authentication.py\n@@ -3,6 +3,7 @@\n import rfc822\n import time\n \n+import gittip\n from aspen import Response\n from gittip.security import csrf\n from g... | 1,434 | 160 |
gh_patches_debug_31388 | rasdani/github-patches | git_diff | conan-io__conan-3100 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Issues with proxies
I've started Conan server in my organization's local network. For external sites (like github) proxy must be used, but not for computers in local network.
So, I have there env variables:
... | diff --git a/conans/client/rest/conan_requester.py b/conans/client/rest/conan_requester.py
--- a/conans/client/rest/conan_requester.py
+++ b/conans/client/rest/conan_requester.py
@@ -9,7 +9,7 @@
def __init__(self, requester, client_cache, timeout):
self.proxies = client_cache.conan_config.proxies or {}
... | {"golden_diff": "diff --git a/conans/client/rest/conan_requester.py b/conans/client/rest/conan_requester.py\n--- a/conans/client/rest/conan_requester.py\n+++ b/conans/client/rest/conan_requester.py\n@@ -9,7 +9,7 @@\n def __init__(self, requester, client_cache, timeout):\n self.proxies = client_cache.conan_c... | 1,259 | 507 |
gh_patches_debug_1142 | rasdani/github-patches | git_diff | nipy__nipype-2852 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
nipype/conftest.py should be excluded from API documentation
### Summary
The auto-generated API docs include `conftest.py`, which has a fixture. Pytest has turned calling a fixture directly into an error, ... | diff --git a/tools/build_interface_docs.py b/tools/build_interface_docs.py
--- a/tools/build_interface_docs.py
+++ b/tools/build_interface_docs.py
@@ -41,6 +41,7 @@
'\.pipeline\.s3_node_wrapper$',
'\.testing',
'\.scripts',
+ '\.conftest',
]
docwriter.class_skip_patterns += [
... | {"golden_diff": "diff --git a/tools/build_interface_docs.py b/tools/build_interface_docs.py\n--- a/tools/build_interface_docs.py\n+++ b/tools/build_interface_docs.py\n@@ -41,6 +41,7 @@\n '\\.pipeline\\.s3_node_wrapper$',\n '\\.testing',\n '\\.scripts',\n+ '\\.conftest',\n ]\n docw... | 915 | 89 |
gh_patches_debug_32346 | rasdani/github-patches | git_diff | pwndbg__pwndbg-1800 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Fix Arch Linux tests
The Arch Linux tests are failing due to new versions of pip needing to use the `--break-system-packages` flag to install packages globally. We should update the CI to use a virtualenv her... | diff --git a/gdbinit.py b/gdbinit.py
--- a/gdbinit.py
+++ b/gdbinit.py
@@ -2,6 +2,7 @@
import glob
import locale
import os
+import site
import sys
import time
from glob import glob
@@ -30,6 +31,14 @@
site_pkgs_path = glob(os.path.join(venv_path, "lib/*/site-packages"))[0]
+# add virtualenv's site-packages to... | {"golden_diff": "diff --git a/gdbinit.py b/gdbinit.py\n--- a/gdbinit.py\n+++ b/gdbinit.py\n@@ -2,6 +2,7 @@\n import glob\n import locale\n import os\n+import site\n import sys\n import time\n from glob import glob\n@@ -30,6 +31,14 @@\n \n site_pkgs_path = glob(os.path.join(venv_path, \"lib/*/site-packages\"))[0]\n \n+#... | 1,523 | 479 |
gh_patches_debug_13716 | rasdani/github-patches | git_diff | facebookresearch__ParlAI-340 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Return type ambiguous when extracting image features
The return type of the extracted image features (if the features file is present or not) is different. If the file is present then it returns a numpy.ndarr... | diff --git a/parlai/core/image_featurizers.py b/parlai/core/image_featurizers.py
--- a/parlai/core/image_featurizers.py
+++ b/parlai/core/image_featurizers.py
@@ -74,7 +74,6 @@
self.netCNN.cuda()
def save(self, feature, path):
- feature = feature.cpu().data.numpy()
np.save(path, feature)... | {"golden_diff": "diff --git a/parlai/core/image_featurizers.py b/parlai/core/image_featurizers.py\n--- a/parlai/core/image_featurizers.py\n+++ b/parlai/core/image_featurizers.py\n@@ -74,7 +74,6 @@\n self.netCNN.cuda()\n \n def save(self, feature, path):\n- feature = feature.cpu().data.numpy()\n ... | 1,979 | 175 |
gh_patches_debug_13533 | rasdani/github-patches | git_diff | pre-commit__pre-commit-306 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Improve error message when attempting to run non-existent hook
Hook id in `/.pre-commit-config.yaml` doesn't exist in the included repository
(From https://github.com/pre-commit/pre-commit-hooks/issues/37)
... | diff --git a/pre_commit/repository.py b/pre_commit/repository.py
--- a/pre_commit/repository.py
+++ b/pre_commit/repository.py
@@ -61,7 +61,16 @@
@cached_property
def hooks(self):
- # TODO: merging in manifest dicts is a smell imo
+ for hook in self.repo_config['hooks']:
+ if hook['... | {"golden_diff": "diff --git a/pre_commit/repository.py b/pre_commit/repository.py\n--- a/pre_commit/repository.py\n+++ b/pre_commit/repository.py\n@@ -61,7 +61,16 @@\n \n @cached_property\n def hooks(self):\n- # TODO: merging in manifest dicts is a smell imo\n+ for hook in self.repo_config['hooks'... | 1,687 | 205 |
gh_patches_debug_36673 | rasdani/github-patches | git_diff | translate__pootle-3883 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
list_language no longer has an idea of a changeid
We dropped change_id concept with 2.7.0 and now we have the idea of `revision`. Previously I could get a list of active languages since a `change_id` using `... | diff --git a/pootle/apps/pootle_app/management/commands/list_languages.py b/pootle/apps/pootle_app/management/commands/list_languages.py
--- a/pootle/apps/pootle_app/management/commands/list_languages.py
+++ b/pootle/apps/pootle_app/management/commands/list_languages.py
@@ -19,6 +19,9 @@
option_list = NoArgsComman... | {"golden_diff": "diff --git a/pootle/apps/pootle_app/management/commands/list_languages.py b/pootle/apps/pootle_app/management/commands/list_languages.py\n--- a/pootle/apps/pootle_app/management/commands/list_languages.py\n+++ b/pootle/apps/pootle_app/management/commands/list_languages.py\n@@ -19,6 +19,9 @@\n optio... | 1,040 | 627 |
gh_patches_debug_42065 | rasdani/github-patches | git_diff | liqd__a4-opin-690 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Remove clash between adhocracy4 library names
- prevents override of global var if same library name is used from
different bundles
fixes #687
--- END ISSUE ---
Below are some code segments, each ... | diff --git a/euth/maps/fields.py b/euth/maps/fields.py
--- a/euth/maps/fields.py
+++ b/euth/maps/fields.py
@@ -1,17 +1,22 @@
+from django.core import validators as django_validators
from django.utils.translation import ugettext_lazy as _
from jsonfield.fields import JSONField, JSONFormField
-from .validators import... | {"golden_diff": "diff --git a/euth/maps/fields.py b/euth/maps/fields.py\n--- a/euth/maps/fields.py\n+++ b/euth/maps/fields.py\n@@ -1,17 +1,22 @@\n+from django.core import validators as django_validators\n from django.utils.translation import ugettext_lazy as _\n from jsonfield.fields import JSONField, JSONFormField\n \... | 1,132 | 947 |
gh_patches_debug_24312 | rasdani/github-patches | git_diff | mozilla__bugbug-864 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add an option to the bug_classifier script to classify a specific bug
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES... | diff --git a/scripts/bug_classifier.py b/scripts/bug_classifier.py
--- a/scripts/bug_classifier.py
+++ b/scripts/bug_classifier.py
@@ -17,7 +17,7 @@
logger = getLogger(__name__)
-def classify_bugs(model_name, classifier):
+def classify_bugs(model_name, classifier, bug_id):
if classifier != "default":
... | {"golden_diff": "diff --git a/scripts/bug_classifier.py b/scripts/bug_classifier.py\n--- a/scripts/bug_classifier.py\n+++ b/scripts/bug_classifier.py\n@@ -17,7 +17,7 @@\n logger = getLogger(__name__)\n \n \n-def classify_bugs(model_name, classifier):\n+def classify_bugs(model_name, classifier, bug_id):\n if classif... | 1,064 | 311 |
gh_patches_debug_25031 | rasdani/github-patches | git_diff | mampfes__hacs_waste_collection_schedule-223 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
CalendarEventDevice is deprecated
Hi there,
Latest HA beta `core-2022.5.0` shows this within the logs:
```
CalendarEventDevice is deprecated, modify WasteCollectionCalendar to extend CalendarEntity
```
... | diff --git a/custom_components/waste_collection_schedule/calendar.py b/custom_components/waste_collection_schedule/calendar.py
--- a/custom_components/waste_collection_schedule/calendar.py
+++ b/custom_components/waste_collection_schedule/calendar.py
@@ -3,7 +3,7 @@
import logging
from datetime import timedelta
-fr... | {"golden_diff": "diff --git a/custom_components/waste_collection_schedule/calendar.py b/custom_components/waste_collection_schedule/calendar.py\n--- a/custom_components/waste_collection_schedule/calendar.py\n+++ b/custom_components/waste_collection_schedule/calendar.py\n@@ -3,7 +3,7 @@\n import logging\n from datetime ... | 924 | 295 |
gh_patches_debug_17685 | rasdani/github-patches | git_diff | DataDog__dd-trace-py-3906 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
mypy invalid syntax error with python 2
### Which version of dd-trace-py are you using?
v1.2.0
### Which version of pip are you using?
22.1.2
### Which version of the libraries are you using?
`... | diff --git a/ddtrace/contrib/redis/patch.py b/ddtrace/contrib/redis/patch.py
--- a/ddtrace/contrib/redis/patch.py
+++ b/ddtrace/contrib/redis/patch.py
@@ -1,4 +1,5 @@
import redis
+from six import PY3
from ddtrace import config
from ddtrace.vendor import wrapt
@@ -36,7 +37,8 @@
_w("redis", "Redis.pipeline... | {"golden_diff": "diff --git a/ddtrace/contrib/redis/patch.py b/ddtrace/contrib/redis/patch.py\n--- a/ddtrace/contrib/redis/patch.py\n+++ b/ddtrace/contrib/redis/patch.py\n@@ -1,4 +1,5 @@\n import redis\n+from six import PY3\n \n from ddtrace import config\n from ddtrace.vendor import wrapt\n@@ -36,7 +37,8 @@\n ... | 1,564 | 213 |
gh_patches_debug_23956 | rasdani/github-patches | git_diff | xorbitsai__inference-407 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
BUG: Asking to pad but the tokenizer does not have a padding token
### Describe the bug
When using Llama-2 PyTorch model for embedding creation, there's an issue:
----> 1 model.create_embedding("Once upon... | diff --git a/xinference/model/llm/pytorch/llama_2.py b/xinference/model/llm/pytorch/llama_2.py
--- a/xinference/model/llm/pytorch/llama_2.py
+++ b/xinference/model/llm/pytorch/llama_2.py
@@ -39,6 +39,9 @@
def _load_model(self, kwargs: dict):
model, tokenizer = super()._load_model(kwargs)
+ # Llam... | {"golden_diff": "diff --git a/xinference/model/llm/pytorch/llama_2.py b/xinference/model/llm/pytorch/llama_2.py\n--- a/xinference/model/llm/pytorch/llama_2.py\n+++ b/xinference/model/llm/pytorch/llama_2.py\n@@ -39,6 +39,9 @@\n \n def _load_model(self, kwargs: dict):\n model, tokenizer = super()._load_model(... | 1,433 | 394 |
gh_patches_debug_9221 | rasdani/github-patches | git_diff | pre-commit__pre-commit-2030 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
multiple mutable rev warnings issued on `autoupdate`
when running `pre-commit autoupdate` I get 2 warnings per mutable rev, when I expected 0 see #974
```sh
~/projects/pytest-cov pre-commit-autoupdate... | diff --git a/pre_commit/commands/migrate_config.py b/pre_commit/commands/migrate_config.py
--- a/pre_commit/commands/migrate_config.py
+++ b/pre_commit/commands/migrate_config.py
@@ -3,7 +3,6 @@
import yaml
-from pre_commit.clientlib import load_config
from pre_commit.util import yaml_load
@@ -40,9 +39,6 @@
... | {"golden_diff": "diff --git a/pre_commit/commands/migrate_config.py b/pre_commit/commands/migrate_config.py\n--- a/pre_commit/commands/migrate_config.py\n+++ b/pre_commit/commands/migrate_config.py\n@@ -3,7 +3,6 @@\n \n import yaml\n \n-from pre_commit.clientlib import load_config\n from pre_commit.util import yaml_loa... | 1,430 | 146 |
gh_patches_debug_7821 | rasdani/github-patches | git_diff | open-telemetry__opentelemetry-python-contrib-1324 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
AsyncPG Instrumentation Span Names are too long when using query string
**Is your feature request related to a problem?**
Not a problem per se however, the `asyncpg` instrumentation uses sets span names as t... | diff --git a/instrumentation/opentelemetry-instrumentation-asyncpg/src/opentelemetry/instrumentation/asyncpg/__init__.py b/instrumentation/opentelemetry-instrumentation-asyncpg/src/opentelemetry/instrumentation/asyncpg/__init__.py
--- a/instrumentation/opentelemetry-instrumentation-asyncpg/src/opentelemetry/instrumenta... | {"golden_diff": "diff --git a/instrumentation/opentelemetry-instrumentation-asyncpg/src/opentelemetry/instrumentation/asyncpg/__init__.py b/instrumentation/opentelemetry-instrumentation-asyncpg/src/opentelemetry/instrumentation/asyncpg/__init__.py\n--- a/instrumentation/opentelemetry-instrumentation-asyncpg/src/opentel... | 1,980 | 211 |
gh_patches_debug_26064 | rasdani/github-patches | git_diff | holoviz__holoviews-671 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Dependencies missing
Hi,
I think that the holoviews pip package does not correctly state its dependencies. These are packages that holoviews complained about not finding when I tried importing it:
- jinja2
... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -13,7 +13,7 @@
# Notebook dependencies of IPython 3
extras_require['notebook-dependencies'] = ['ipython', 'pyzmq', 'jinja2', 'tornado',
- 'jsonschema', 'ipython', 'pygments']
+ ... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -13,7 +13,7 @@\n \n # Notebook dependencies of IPython 3\n extras_require['notebook-dependencies'] = ['ipython', 'pyzmq', 'jinja2', 'tornado',\n- 'jsonschema', 'ipython', 'pygments']\n+ ... | 1,559 | 362 |
gh_patches_debug_14663 | rasdani/github-patches | git_diff | pytorch__text-1889 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Error running unit tests when building with setup.py install
## 🐛 Bug
**Describe the bug** A clear and concise description of what the bug is.
When building with python setup.py install, running pytest f... | diff --git a/tools/setup_helpers/extension.py b/tools/setup_helpers/extension.py
--- a/tools/setup_helpers/extension.py
+++ b/tools/setup_helpers/extension.py
@@ -21,6 +21,10 @@
_ROOT_DIR = _THIS_DIR.parent.parent.resolve()
+def _get_cxx11_abi():
+ return "-D_GLIBCXX_USE_CXX11_ABI=" + str(int(torch.compiled_wit... | {"golden_diff": "diff --git a/tools/setup_helpers/extension.py b/tools/setup_helpers/extension.py\n--- a/tools/setup_helpers/extension.py\n+++ b/tools/setup_helpers/extension.py\n@@ -21,6 +21,10 @@\n _ROOT_DIR = _THIS_DIR.parent.parent.resolve()\n \n \n+def _get_cxx11_abi():\n+ return \"-D_GLIBCXX_USE_CXX11_ABI=\" +... | 1,957 | 209 |
gh_patches_debug_38918 | rasdani/github-patches | git_diff | scrapy__scrapy-1933 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Scrapy 1.1.0 RC3 - exception thrown with invalid ssl certificate
Hello,
I am crawling sometimes websites with an invalid ssl certificate. For example, Scrapy 1.1.0 RC3 fails to open when I do:
> scrapy shel... | diff --git a/scrapy/core/downloader/contextfactory.py b/scrapy/core/downloader/contextfactory.py
--- a/scrapy/core/downloader/contextfactory.py
+++ b/scrapy/core/downloader/contextfactory.py
@@ -6,11 +6,16 @@
from zope.interface.declarations import implementer
# the following should be available from Twiste... | {"golden_diff": "diff --git a/scrapy/core/downloader/contextfactory.py b/scrapy/core/downloader/contextfactory.py\n--- a/scrapy/core/downloader/contextfactory.py\n+++ b/scrapy/core/downloader/contextfactory.py\n@@ -6,11 +6,16 @@\n from zope.interface.declarations import implementer\n \n # the following should b... | 1,799 | 758 |
gh_patches_debug_6961 | rasdani/github-patches | git_diff | nextcloud__appstore-186 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Email confirmation email should be improved
I couldn't find the text for the email, so I suspect it's from some library.
Here is the content:
---
Hello from **apps.nextcloud.com**!
You're receiving this e... | diff --git a/nextcloudappstore/core/management/commands/setupsocial.py b/nextcloudappstore/core/management/commands/setupsocial.py
--- a/nextcloudappstore/core/management/commands/setupsocial.py
+++ b/nextcloudappstore/core/management/commands/setupsocial.py
@@ -21,7 +21,7 @@
# set up site which is required fo... | {"golden_diff": "diff --git a/nextcloudappstore/core/management/commands/setupsocial.py b/nextcloudappstore/core/management/commands/setupsocial.py\n--- a/nextcloudappstore/core/management/commands/setupsocial.py\n+++ b/nextcloudappstore/core/management/commands/setupsocial.py\n@@ -21,7 +21,7 @@\n # set up site... | 764 | 154 |
gh_patches_debug_23246 | rasdani/github-patches | git_diff | docarray__docarray-85 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
fix(hashing): ignore casting to float
Fixes #83
```python
>>> x = Document(text="float test 2.56")
>>> x.get_vocabulary()
Counter({'float': 1, 'test': 1, '2': 1, '56': 1})
```
--- END ISSUE ---
Belo... | diff --git a/docarray/document/mixins/featurehash.py b/docarray/document/mixins/featurehash.py
--- a/docarray/document/mixins/featurehash.py
+++ b/docarray/document/mixins/featurehash.py
@@ -64,22 +64,24 @@
def _any_hash(v):
- try:
- return int(v) # parse int parameter
- except ValueError:
+ if no... | {"golden_diff": "diff --git a/docarray/document/mixins/featurehash.py b/docarray/document/mixins/featurehash.py\n--- a/docarray/document/mixins/featurehash.py\n+++ b/docarray/document/mixins/featurehash.py\n@@ -64,22 +64,24 @@\n \n \n def _any_hash(v):\n- try:\n- return int(v) # parse int parameter\n- exc... | 1,186 | 434 |
gh_patches_debug_29060 | rasdani/github-patches | git_diff | falconry__falcon-1399 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Tox (including Travis) not testing cythonized variants
As described in ``README.rst``, Falcon can be cythonized for ~20% performance gain (or actually even more). Installing Falcon from *sdist* into an enviro... | diff --git a/falcon/cmd/print_routes.py b/falcon/cmd/print_routes.py
--- a/falcon/cmd/print_routes.py
+++ b/falcon/cmd/print_routes.py
@@ -58,13 +58,19 @@
else:
real_func = func
- source_file = inspect.getsourcefile(real_func)
-
- ... | {"golden_diff": "diff --git a/falcon/cmd/print_routes.py b/falcon/cmd/print_routes.py\n--- a/falcon/cmd/print_routes.py\n+++ b/falcon/cmd/print_routes.py\n@@ -58,13 +58,19 @@\n else:\n real_func = func\n \n- source_file = inspect.getsourcefile(r... | 1,585 | 336 |
gh_patches_debug_10000 | rasdani/github-patches | git_diff | kubeflow__pipelines-5290 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[Bug] KeyValueStore fails to check the cached data with new data
Typo bug.
```
def store_value_bytes(self, key: str, data: bytes) -> str:
...
if cache_value_file_path.exists():
old_da... | diff --git a/sdk/python/kfp/components/_key_value_store.py b/sdk/python/kfp/components/_key_value_store.py
--- a/sdk/python/kfp/components/_key_value_store.py
+++ b/sdk/python/kfp/components/_key_value_store.py
@@ -31,7 +31,7 @@
'"{}" != new key "{}"'.format(cache_key_file_path, old_key, key)
... | {"golden_diff": "diff --git a/sdk/python/kfp/components/_key_value_store.py b/sdk/python/kfp/components/_key_value_store.py\n--- a/sdk/python/kfp/components/_key_value_store.py\n+++ b/sdk/python/kfp/components/_key_value_store.py\n@@ -31,7 +31,7 @@\n '\"{}\" != new key \"{}\"'.format(cache_key_file_... | 1,034 | 144 |
gh_patches_debug_56902 | rasdani/github-patches | git_diff | NVIDIA__NVFlare-172 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Error in aggregating models
I'm using NVFlare 2.0.6 and torchvision ResNet-50 model for training. The FL system (consisting 4 clients) had completed the training for the first round but when aggregating into ... | diff --git a/nvflare/app_common/shareablegenerators/full_model_shareable_generator.py b/nvflare/app_common/shareablegenerators/full_model_shareable_generator.py
--- a/nvflare/app_common/shareablegenerators/full_model_shareable_generator.py
+++ b/nvflare/app_common/shareablegenerators/full_model_shareable_generator.py
@... | {"golden_diff": "diff --git a/nvflare/app_common/shareablegenerators/full_model_shareable_generator.py b/nvflare/app_common/shareablegenerators/full_model_shareable_generator.py\n--- a/nvflare/app_common/shareablegenerators/full_model_shareable_generator.py\n+++ b/nvflare/app_common/shareablegenerators/full_model_share... | 1,784 | 164 |
gh_patches_debug_29566 | rasdani/github-patches | git_diff | mathesar-foundation__mathesar-2361 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Saving existing explorations is broken: UIQuery names need to be unique
## Description
https://github.com/centerofci/mathesar/pull/2315 modified query names to be unique per schema.
It does not ignore the c... | diff --git a/mathesar/api/serializers/queries.py b/mathesar/api/serializers/queries.py
--- a/mathesar/api/serializers/queries.py
+++ b/mathesar/api/serializers/queries.py
@@ -1,5 +1,7 @@
from django.core.exceptions import ValidationError
from django.urls import reverse
+from django.db.models import Q
+
from rest_acc... | {"golden_diff": "diff --git a/mathesar/api/serializers/queries.py b/mathesar/api/serializers/queries.py\n--- a/mathesar/api/serializers/queries.py\n+++ b/mathesar/api/serializers/queries.py\n@@ -1,5 +1,7 @@\n from django.core.exceptions import ValidationError\n from django.urls import reverse\n+from django.db.models im... | 1,222 | 389 |
gh_patches_debug_4230 | rasdani/github-patches | git_diff | numba__numba-873 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
PR #856 introduced regression in macro expansion of more than one block
PR #856 caused macro expansion to effectively cease after performing macro expansion in one block, due to the logic in `numba/macro.py`:... | diff --git a/numba/macro.py b/numba/macro.py
--- a/numba/macro.py
+++ b/numba/macro.py
@@ -29,7 +29,8 @@
expanded = False
for blk in blocks.values():
module_getattr_folding(constants, blk)
- expanded = expanded or expand_macros_in_block(constants, blk)
+ block_expanded = expand_macros_i... | {"golden_diff": "diff --git a/numba/macro.py b/numba/macro.py\n--- a/numba/macro.py\n+++ b/numba/macro.py\n@@ -29,7 +29,8 @@\n expanded = False\n for blk in blocks.values():\n module_getattr_folding(constants, blk)\n- expanded = expanded or expand_macros_in_block(constants, blk)\n+ block_e... | 1,742 | 122 |
gh_patches_debug_7749 | rasdani/github-patches | git_diff | cloudtools__troposphere-1696 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
implement AWS::Synthetics changes from May 14, 2020 update
--- 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/troposphere/synthetics.py b/troposphere/synthetics.py
--- a/troposphere/synthetics.py
+++ b/troposphere/synthetics.py
@@ -47,7 +47,7 @@
'ExecutionRoleArn': (basestring, True),
'FailureRetentionPeriod': (integer, False),
'Name': (basestring, True),
- 'RunConfig': (RunConfig... | {"golden_diff": "diff --git a/troposphere/synthetics.py b/troposphere/synthetics.py\n--- a/troposphere/synthetics.py\n+++ b/troposphere/synthetics.py\n@@ -47,7 +47,7 @@\n 'ExecutionRoleArn': (basestring, True),\n 'FailureRetentionPeriod': (integer, False),\n 'Name': (basestring, True),\n- ... | 793 | 144 |
gh_patches_debug_38141 | rasdani/github-patches | git_diff | apache__tvm-2921 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[TEST][TENSORFLOW] Cache the Downloaded File
So far the model files used in the TF end to end tests re-download the file in each test run.
This causes the test execution to be slow. Eventually, the test ser... | diff --git a/python/tvm/contrib/download.py b/python/tvm/contrib/download.py
--- a/python/tvm/contrib/download.py
+++ b/python/tvm/contrib/download.py
@@ -5,8 +5,10 @@
import os
import sys
import time
+import uuid
+import shutil
-def download(url, path, overwrite=False, size_compare=False, verbose=1):
+def downloa... | {"golden_diff": "diff --git a/python/tvm/contrib/download.py b/python/tvm/contrib/download.py\n--- a/python/tvm/contrib/download.py\n+++ b/python/tvm/contrib/download.py\n@@ -5,8 +5,10 @@\n import os\n import sys\n import time\n+import uuid\n+import shutil\n \n-def download(url, path, overwrite=False, size_compare=Fals... | 1,086 | 803 |
gh_patches_debug_1585 | rasdani/github-patches | git_diff | scipy__scipy-10447 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Build adds the user folder inside the code base
After building the SciPy on Windows 10, the base folder has a copy of the following folder
```
C:\Users\<user>\Documents\GitHub\scipy\Users\<user>\AppData\L... | diff --git a/scipy/fft/_pocketfft/setup.py b/scipy/fft/_pocketfft/setup.py
--- a/scipy/fft/_pocketfft/setup.py
+++ b/scipy/fft/_pocketfft/setup.py
@@ -13,7 +13,7 @@
f.write(code)
try:
- compiler.compile([fname], extra_postargs=flags)
+ compiler.compile([fname], output_dir=t... | {"golden_diff": "diff --git a/scipy/fft/_pocketfft/setup.py b/scipy/fft/_pocketfft/setup.py\n--- a/scipy/fft/_pocketfft/setup.py\n+++ b/scipy/fft/_pocketfft/setup.py\n@@ -13,7 +13,7 @@\n f.write(code)\n \n try:\n- compiler.compile([fname], extra_postargs=flags)\n+ compiler.comp... | 1,269 | 117 |
gh_patches_debug_15992 | rasdani/github-patches | git_diff | pymodbus-dev__pymodbus-1339 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Can't run pymodbus.simulator --help
<!--
Before opening a new issue, make sure you do the following:
* check that your issue isn't already filed: https://github.com/pymodbus-dev/pymodbus/issues
*... | diff --git a/pymodbus/server/simulator/main.py b/pymodbus/server/simulator/main.py
--- a/pymodbus/server/simulator/main.py
+++ b/pymodbus/server/simulator/main.py
@@ -47,10 +47,6 @@
from pymodbus.server.simulator.http_server import ModbusSimulatorServer
-async def run():
- """Run simulator."""
-
-
def get_comm... | {"golden_diff": "diff --git a/pymodbus/server/simulator/main.py b/pymodbus/server/simulator/main.py\n--- a/pymodbus/server/simulator/main.py\n+++ b/pymodbus/server/simulator/main.py\n@@ -47,10 +47,6 @@\n from pymodbus.server.simulator.http_server import ModbusSimulatorServer\n \n \n-async def run():\n- \"\"\"Run sim... | 1,738 | 208 |
gh_patches_debug_31074 | rasdani/github-patches | git_diff | docker__docker-py-1957 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
ERROR: Cannot locate specified Dockerfile
I'm not sure if this is a Docker Compose bug or docker-py bug, but this used to work:
`docker-compose.yml`:
```yaml
version: '3.5'
services:
php:
buil... | diff --git a/docker/utils/build.py b/docker/utils/build.py
--- a/docker/utils/build.py
+++ b/docker/utils/build.py
@@ -31,18 +31,21 @@
if dockerfile is None:
dockerfile = 'Dockerfile'
+ def split_path(p):
+ return [pt for pt in re.split(_SEP, p) if pt and pt != '.']
+
def normalize(p):
... | {"golden_diff": "diff --git a/docker/utils/build.py b/docker/utils/build.py\n--- a/docker/utils/build.py\n+++ b/docker/utils/build.py\n@@ -31,18 +31,21 @@\n if dockerfile is None:\n dockerfile = 'Dockerfile'\n \n+ def split_path(p):\n+ return [pt for pt in re.split(_SEP, p) if pt and pt != '.']\n+... | 1,867 | 362 |
gh_patches_debug_650 | rasdani/github-patches | git_diff | pex-tool__pex-1942 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Release 2.1.109
On the docket:
+ [x] pex does not support musllinux wheels #1933
+ [x] Empty string PEX_PATH="" env var causes CWD (.) to be added bootstrapped pex_path #1936
--- END ISSUE ---
Below are s... | diff --git a/pex/version.py b/pex/version.py
--- a/pex/version.py
+++ b/pex/version.py
@@ -1,4 +1,4 @@
# Copyright 2015 Pants project contributors (see CONTRIBUTORS.md).
# Licensed under the Apache License, Version 2.0 (see LICENSE).
-__version__ = "2.1.108"
+__version__ = "2.1.109"
| {"golden_diff": "diff --git a/pex/version.py b/pex/version.py\n--- a/pex/version.py\n+++ b/pex/version.py\n@@ -1,4 +1,4 @@\n # Copyright 2015 Pants project contributors (see CONTRIBUTORS.md).\n # Licensed under the Apache License, Version 2.0 (see LICENSE).\n \n-__version__ = \"2.1.108\"\n+__version__ = \"2.1.109\"\n",... | 374 | 98 |
gh_patches_debug_25401 | rasdani/github-patches | git_diff | GeotrekCE__Geotrek-admin-1307 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Infrastructure list is filtered on "Ouvrage" by default
J'ai créé des points d'aménagements (8 au total), cependant la plupart ne s'affichent pas (ni dans la liste, ni sur la carte)...

+ f... | {"golden_diff": "diff --git a/geotrek/infrastructure/filters.py b/geotrek/infrastructure/filters.py\n--- a/geotrek/infrastructure/filters.py\n+++ b/geotrek/infrastructure/filters.py\n@@ -20,6 +20,11 @@\n field = self.form.fields['type']\n field.queryset = field.queryset.exclude(type=INFRASTRUCTURE_TYPES... | 905 | 332 |
gh_patches_debug_11644 | rasdani/github-patches | git_diff | pyqtgraph__pyqtgraph-954 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[CI-fail] GLScatterPlotItem failing on Windows Builds
```
Traceback (most recent call last):
File "c:\hostedtoolcache\windows\python\3.7.3\x64\lib\site-packages\OpenGL\latebind.py", line 41, in __call__... | diff --git a/pyqtgraph/opengl/glInfo.py b/pyqtgraph/opengl/glInfo.py
--- a/pyqtgraph/opengl/glInfo.py
+++ b/pyqtgraph/opengl/glInfo.py
@@ -6,10 +6,10 @@
def __init__(self):
QtOpenGL.QGLWidget.__init__(self)
self.makeCurrent()
- print("GL version:" + glGetString(GL_VERSION))
+ print(... | {"golden_diff": "diff --git a/pyqtgraph/opengl/glInfo.py b/pyqtgraph/opengl/glInfo.py\n--- a/pyqtgraph/opengl/glInfo.py\n+++ b/pyqtgraph/opengl/glInfo.py\n@@ -6,10 +6,10 @@\n def __init__(self):\n QtOpenGL.QGLWidget.__init__(self)\n self.makeCurrent()\n- print(\"GL version:\" + glGetString(GL... | 1,431 | 199 |
gh_patches_debug_27636 | rasdani/github-patches | git_diff | graspologic-org__graspologic-829 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[BUG] Inaccurracy in how to use autokmeans
## Expected Behavior
https://github.com/microsoft/graspologic/blob/10de2bf17b972decbab318568154af226dcd71fa/graspologic/cluster/kclust.py#L16
This line is fals... | diff --git a/graspologic/cluster/kclust.py b/graspologic/cluster/kclust.py
--- a/graspologic/cluster/kclust.py
+++ b/graspologic/cluster/kclust.py
@@ -18,13 +18,15 @@
"""
KMeans Cluster.
- It computes all possible models from one component to
- ``max_clusters``. The best model is given by the lowest s... | {"golden_diff": "diff --git a/graspologic/cluster/kclust.py b/graspologic/cluster/kclust.py\n--- a/graspologic/cluster/kclust.py\n+++ b/graspologic/cluster/kclust.py\n@@ -18,13 +18,15 @@\n \"\"\"\n KMeans Cluster.\n \n- It computes all possible models from one component to\n- ``max_clusters``. The best mo... | 1,561 | 402 |
gh_patches_debug_3066 | rasdani/github-patches | git_diff | searx__searx-200 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
bing_news can't parse other languages date
When searching for french article, the time is noted as "Il y a 5 minutes", and so, doesn't match for the regex `"^[0-9]+ minute(s|) ago$"`.
Do you see a way to int... | diff --git a/searx/engines/bing_news.py b/searx/engines/bing_news.py
--- a/searx/engines/bing_news.py
+++ b/searx/engines/bing_news.py
@@ -39,8 +39,7 @@
query=urlencode({'q': query, 'setmkt': language}),
offset=offset)
- params['cookies']['SRCHHPGUSR'] = \
- 'NEWWND=0&NRSLT=-1&SRCHLANG=' +... | {"golden_diff": "diff --git a/searx/engines/bing_news.py b/searx/engines/bing_news.py\n--- a/searx/engines/bing_news.py\n+++ b/searx/engines/bing_news.py\n@@ -39,8 +39,7 @@\n query=urlencode({'q': query, 'setmkt': language}),\n offset=offset)\n \n- params['cookies']['SRCHHPGUSR'] = \\\n- 'NEWW... | 1,400 | 158 |
gh_patches_debug_3814 | rasdani/github-patches | git_diff | cookiecutter__cookiecutter-573 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Problem with --checkout reclone
The message should ask me about recloning `/Users/audreyr/.cookiecutters/cookiecutter-pypackage`, not `/Users/audreyr/.cookiecutters`.
```
$ cookiecutter https://github.com/el... | diff --git a/cookiecutter/vcs.py b/cookiecutter/vcs.py
--- a/cookiecutter/vcs.py
+++ b/cookiecutter/vcs.py
@@ -103,6 +103,7 @@
msg = "'{0}' is not installed.".format(repo_type)
raise VCSNotInstalled(msg)
+ repo_url = repo_url.rstrip('/')
tail = os.path.split(repo_url)[1]
if repo_type ==... | {"golden_diff": "diff --git a/cookiecutter/vcs.py b/cookiecutter/vcs.py\n--- a/cookiecutter/vcs.py\n+++ b/cookiecutter/vcs.py\n@@ -103,6 +103,7 @@\n msg = \"'{0}' is not installed.\".format(repo_type)\n raise VCSNotInstalled(msg)\n \n+ repo_url = repo_url.rstrip('/')\n tail = os.path.split(repo_u... | 1,512 | 121 |
gh_patches_debug_22116 | rasdani/github-patches | git_diff | pyload__pyload-1381 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
uplea plugin (still) broken
Hi again,
sorry but inspite of #1369 and #1375, uplea is still not working; now it's back with downloading the HTML download page...
24 26.04.2015 23:29:20 INFO Download finis... | 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.08"
+ __version__ = "0.10"
... | {"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.08... | 1,086 | 402 |
gh_patches_debug_42531 | rasdani/github-patches | git_diff | plone__Products.CMFPlone-1763 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
CSS bundles generation breaks background images relative urls
This is a bug related to PR #1300.
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may co... | diff --git a/Products/CMFPlone/resources/browser/combine.py b/Products/CMFPlone/resources/browser/combine.py
--- a/Products/CMFPlone/resources/browser/combine.py
+++ b/Products/CMFPlone/resources/browser/combine.py
@@ -1,18 +1,20 @@
-from zExceptions import NotFound
from Acquisition import aq_base
from datetime impor... | {"golden_diff": "diff --git a/Products/CMFPlone/resources/browser/combine.py b/Products/CMFPlone/resources/browser/combine.py\n--- a/Products/CMFPlone/resources/browser/combine.py\n+++ b/Products/CMFPlone/resources/browser/combine.py\n@@ -1,18 +1,20 @@\n-from zExceptions import NotFound\n from Acquisition import aq_bas... | 1,424 | 755 |
gh_patches_debug_658 | rasdani/github-patches | git_diff | pex-tool__pex-2258 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Release 2.1.148
On the docket:
+ [x] The Pex CLI should warn when it creates a PEX zip that requires zip64. #2247
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of t... | diff --git a/pex/version.py b/pex/version.py
--- a/pex/version.py
+++ b/pex/version.py
@@ -1,4 +1,4 @@
# Copyright 2015 Pants project contributors (see CONTRIBUTORS.md).
# Licensed under the Apache License, Version 2.0 (see LICENSE).
-__version__ = "2.1.147"
+__version__ = "2.1.148"
| {"golden_diff": "diff --git a/pex/version.py b/pex/version.py\n--- a/pex/version.py\n+++ b/pex/version.py\n@@ -1,4 +1,4 @@\n # Copyright 2015 Pants project contributors (see CONTRIBUTORS.md).\n # Licensed under the Apache License, Version 2.0 (see LICENSE).\n \n-__version__ = \"2.1.147\"\n+__version__ = \"2.1.148\"\n",... | 352 | 98 |
gh_patches_debug_2942 | rasdani/github-patches | git_diff | docker__docker-py-3004 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
installing latest 5.0.3 on windows machines is still using pywin32==227 but not pywin32==301
[Bump pywin32 from 227 to 301 ]( https://github.com/docker/docker-py/commit/e0d186d754693feb7d27c2352e455c5febb4a5c... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -16,7 +16,7 @@
extras_require = {
# win32 APIs if on Windows (required for npipe support)
- ':sys_platform == "win32"': 'pywin32==227',
+ ':sys_platform == "win32"': 'pywin32>=304',
# If using docker-py over TLS, highly recommend thi... | {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -16,7 +16,7 @@\n \n extras_require = {\n # win32 APIs if on Windows (required for npipe support)\n- ':sys_platform == \"win32\"': 'pywin32==227',\n+ ':sys_platform == \"win32\"': 'pywin32>=304',\n \n # If using docker-py... | 1,459 | 122 |
gh_patches_debug_12597 | rasdani/github-patches | git_diff | sublimelsp__LSP-1110 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Double requests for documentHighlight
I've noticed that setting a cursor on some symbol makes the `documentHighlight` underline blink once.
Checked logs and saw the request being made twice on each cursor ... | diff --git a/plugin/highlights.py b/plugin/highlights.py
--- a/plugin/highlights.py
+++ b/plugin/highlights.py
@@ -43,9 +43,11 @@
current_point = self.view.sel()[0].begin()
except IndexError:
return
- self._stored_point = current_point
self._clear_r... | {"golden_diff": "diff --git a/plugin/highlights.py b/plugin/highlights.py\n--- a/plugin/highlights.py\n+++ b/plugin/highlights.py\n@@ -43,9 +43,11 @@\n current_point = self.view.sel()[0].begin()\n except IndexError:\n return\n- self._stored_point = current_point\n ... | 1,543 | 174 |
gh_patches_debug_15724 | rasdani/github-patches | git_diff | pyscript__pyscript-1902 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
js_modules not behaving like in Polyscript
### Checklist
- [X] I added a descriptive title
- [X] I searched for other issues and couldn't find a solution or duplication
- [X] I already searched in Google and... | diff --git a/pyscript.core/src/stdlib/pyscript/magic_js.py b/pyscript.core/src/stdlib/pyscript/magic_js.py
--- a/pyscript.core/src/stdlib/pyscript/magic_js.py
+++ b/pyscript.core/src/stdlib/pyscript/magic_js.py
@@ -1,9 +1,28 @@
+import sys
+
import js as globalThis
from polyscript import js_modules
from pyscript.uti... | {"golden_diff": "diff --git a/pyscript.core/src/stdlib/pyscript/magic_js.py b/pyscript.core/src/stdlib/pyscript/magic_js.py\n--- a/pyscript.core/src/stdlib/pyscript/magic_js.py\n+++ b/pyscript.core/src/stdlib/pyscript/magic_js.py\n@@ -1,9 +1,28 @@\n+import sys\n+\n import js as globalThis\n from polyscript import js_mo... | 753 | 283 |
gh_patches_debug_5283 | rasdani/github-patches | git_diff | azavea__raster-vision-469 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Move to using master in azavea/models
We've been using a branch of azavea/models, which can cause confusion.
Before release, merge the `upgrade-sept-2018` branch into the main branch and update our insta... | diff --git a/rastervision/runner/command_dag.py b/rastervision/runner/command_dag.py
--- a/rastervision/runner/command_dag.py
+++ b/rastervision/runner/command_dag.py
@@ -45,7 +45,7 @@
with click.progressbar(
unsolved_sources,
- label='Ensuring input files exists '... | {"golden_diff": "diff --git a/rastervision/runner/command_dag.py b/rastervision/runner/command_dag.py\n--- a/rastervision/runner/command_dag.py\n+++ b/rastervision/runner/command_dag.py\n@@ -45,7 +45,7 @@\n \n with click.progressbar(\n unsolved_sources,\n- label='Ensur... | 1,670 | 125 |
gh_patches_debug_1363 | rasdani/github-patches | git_diff | ManageIQ__integration_tests-7728 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
cfme.log only showing on first test in a run.
cfme.log link only appears on the first test from a selection but shows all logs from all tests in that run. Expected to have a separate log link for each test sp... | diff --git a/artifactor/plugins/logger.py b/artifactor/plugins/logger.py
--- a/artifactor/plugins/logger.py
+++ b/artifactor/plugins/logger.py
@@ -26,7 +26,7 @@
self.handler = None
def close(self):
- if self.handle is not None:
+ if self.handler is not None:
... | {"golden_diff": "diff --git a/artifactor/plugins/logger.py b/artifactor/plugins/logger.py\n--- a/artifactor/plugins/logger.py\n+++ b/artifactor/plugins/logger.py\n@@ -26,7 +26,7 @@\n self.handler = None\n \n def close(self):\n- if self.handle is not None:\n+ if self.handler is ... | 1,257 | 88 |
gh_patches_debug_613 | rasdani/github-patches | git_diff | pex-tool__pex-1314 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Release 2.1.38
On the docket:
+ [ ] PEX direct requirement metadata for resolves via Pip is incorrect. #1311
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these ... | diff --git a/pex/version.py b/pex/version.py
--- a/pex/version.py
+++ b/pex/version.py
@@ -1,4 +1,4 @@
# Copyright 2015 Pants project contributors (see CONTRIBUTORS.md).
# Licensed under the Apache License, Version 2.0 (see LICENSE).
-__version__ = "2.1.37"
+__version__ = "2.1.38"
| {"golden_diff": "diff --git a/pex/version.py b/pex/version.py\n--- a/pex/version.py\n+++ b/pex/version.py\n@@ -1,4 +1,4 @@\n # Copyright 2015 Pants project contributors (see CONTRIBUTORS.md).\n # Licensed under the Apache License, Version 2.0 (see LICENSE).\n \n-__version__ = \"2.1.37\"\n+__version__ = \"2.1.38\"\n", "... | 342 | 96 |
gh_patches_debug_8086 | rasdani/github-patches | git_diff | lutris__lutris-1904 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Higher resolution icons are still saved in 32x32 directory
Despite Lutris bumping its icon size to 128x128 (currently it's still 64x64 as bump to 128x128 hasn't been deployed yet), it still saves the icons in... | diff --git a/lutris/settings.py b/lutris/settings.py
--- a/lutris/settings.py
+++ b/lutris/settings.py
@@ -23,7 +23,7 @@
TMP_PATH = os.path.join(CACHE_DIR, "tmp")
BANNER_PATH = os.path.join(DATA_DIR, "banners")
COVERART_PATH = os.path.join(DATA_DIR, "coverart")
-ICON_PATH = os.path.join(GLib.get_user_data_dir(), "ic... | {"golden_diff": "diff --git a/lutris/settings.py b/lutris/settings.py\n--- a/lutris/settings.py\n+++ b/lutris/settings.py\n@@ -23,7 +23,7 @@\n TMP_PATH = os.path.join(CACHE_DIR, \"tmp\")\n BANNER_PATH = os.path.join(DATA_DIR, \"banners\")\n COVERART_PATH = os.path.join(DATA_DIR, \"coverart\")\n-ICON_PATH = os.path.join... | 859 | 180 |
gh_patches_debug_3319 | rasdani/github-patches | git_diff | spack__spack-3825 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
`scorep` does not work on Darwin
The Score-P package requires a case-sensitive file system. This is described in the install notes, and I confirmed with the developers. I suggest to disable Score-P on Darwin ... | diff --git a/var/spack/repos/builtin/packages/scorep/package.py b/var/spack/repos/builtin/packages/scorep/package.py
--- a/var/spack/repos/builtin/packages/scorep/package.py
+++ b/var/spack/repos/builtin/packages/scorep/package.py
@@ -65,6 +65,11 @@
variant('shmem', default=False, description='Enable shmem traci... | {"golden_diff": "diff --git a/var/spack/repos/builtin/packages/scorep/package.py b/var/spack/repos/builtin/packages/scorep/package.py\n--- a/var/spack/repos/builtin/packages/scorep/package.py\n+++ b/var/spack/repos/builtin/packages/scorep/package.py\n@@ -65,6 +65,11 @@\n \n variant('shmem', default=False, descripti... | 1,552 | 156 |
gh_patches_debug_29093 | rasdani/github-patches | git_diff | TheAlgorithms__Python-1093 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
decimal_to_binary() should return identical values as bin()
https://github.com/TheAlgorithms/Python/blob/7b267e5e4f8ccb72dd58fcf0057642fd62a36bdf/conversions/decimal_to_binary.py#L4
Please change __decimal... | diff --git a/conversions/decimal_to_binary.py b/conversions/decimal_to_binary.py
--- a/conversions/decimal_to_binary.py
+++ b/conversions/decimal_to_binary.py
@@ -2,24 +2,57 @@
def decimal_to_binary(num):
- """Convert a Decimal Number to a Binary Number."""
+
+ """
+ Convert a Integer Decimal Number t... | {"golden_diff": "diff --git a/conversions/decimal_to_binary.py b/conversions/decimal_to_binary.py\n--- a/conversions/decimal_to_binary.py\n+++ b/conversions/decimal_to_binary.py\n@@ -2,24 +2,57 @@\n \n \n def decimal_to_binary(num):\n- \"\"\"Convert a Decimal Number to a Binary Number.\"\"\"\n+\n+ \"\"\"\n+ ... | 609 | 628 |
gh_patches_debug_1651 | rasdani/github-patches | git_diff | deeppavlov__DeepPavlov-76 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
What is "'Chainer' object has no attribute 'infer'
2018-03-04 14:09:23,638 (util.py:64 WorkerThread2) ERROR - TeleBot: "AttributeError occurred, args=("'Chainer' object has no attribute 'infer'",)
Traceback ... | diff --git a/telegram_utils/telegram_ui.py b/telegram_utils/telegram_ui.py
--- a/telegram_utils/telegram_ui.py
+++ b/telegram_utils/telegram_ui.py
@@ -45,7 +45,7 @@
chat_id = message.chat.id
context = message.text
- pred = model.infer(context)
+ pred = model(context)
reply_mes... | {"golden_diff": "diff --git a/telegram_utils/telegram_ui.py b/telegram_utils/telegram_ui.py\n--- a/telegram_utils/telegram_ui.py\n+++ b/telegram_utils/telegram_ui.py\n@@ -45,7 +45,7 @@\n chat_id = message.chat.id\n context = message.text\n \n- pred = model.infer(context)\n+ pred = model(co... | 1,541 | 99 |
gh_patches_debug_14730 | rasdani/github-patches | git_diff | scrapy__scrapy-4775 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Document link extractor usage outside CrawlSpider rules
https://docs.scrapy.org/en/latest/topics/link-extractors.html mentions that link extractors may be used outside `CrawlSpider`, but it does not go into d... | diff --git a/scrapy/link.py b/scrapy/link.py
--- a/scrapy/link.py
+++ b/scrapy/link.py
@@ -7,7 +7,22 @@
class Link:
- """Link objects represent an extracted link by the LinkExtractor."""
+ """Link objects represent an extracted link by the LinkExtractor.
+
+ Using the anchor tag sample below to illustrate... | {"golden_diff": "diff --git a/scrapy/link.py b/scrapy/link.py\n--- a/scrapy/link.py\n+++ b/scrapy/link.py\n@@ -7,7 +7,22 @@\n \n \n class Link:\n- \"\"\"Link objects represent an extracted link by the LinkExtractor.\"\"\"\n+ \"\"\"Link objects represent an extracted link by the LinkExtractor.\n+\n+ Using the a... | 690 | 262 |
gh_patches_debug_38824 | rasdani/github-patches | git_diff | liqd__a4-opin-399 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Use Generic Relation everywhere where generic fks are used
--- 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/euth/documents/models.py b/euth/documents/models.py
--- a/euth/documents/models.py
+++ b/euth/documents/models.py
@@ -1,5 +1,5 @@
from ckeditor.fields import RichTextField
-from django.contrib.contenttypes.models import ContentType
+from django.contrib.contenttypes.fields import GenericRelation
from djan... | {"golden_diff": "diff --git a/euth/documents/models.py b/euth/documents/models.py\n--- a/euth/documents/models.py\n+++ b/euth/documents/models.py\n@@ -1,5 +1,5 @@\n from ckeditor.fields import RichTextField\n-from django.contrib.contenttypes.models import ContentType\n+from django.contrib.contenttypes.fields import Gen... | 1,624 | 603 |
gh_patches_debug_22070 | rasdani/github-patches | git_diff | akvo__akvo-rsr-2290 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Invite existing users gives an IntegrityError
See http://sentry.support.akvo-ops.org/rsr/live/group/797/.
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these fil... | diff --git a/akvo/rest/views/employment.py b/akvo/rest/views/employment.py
--- a/akvo/rest/views/employment.py
+++ b/akvo/rest/views/employment.py
@@ -6,10 +6,12 @@
"""
from django.contrib.auth.models import Group
+from django.db import IntegrityError
from rest_framework.decorators import api_view, permission_clas... | {"golden_diff": "diff --git a/akvo/rest/views/employment.py b/akvo/rest/views/employment.py\n--- a/akvo/rest/views/employment.py\n+++ b/akvo/rest/views/employment.py\n@@ -6,10 +6,12 @@\n \"\"\"\n \n from django.contrib.auth.models import Group\n+from django.db import IntegrityError\n from rest_framework.decorators impo... | 737 | 231 |
gh_patches_debug_3886 | rasdani/github-patches | git_diff | nilearn__nilearn-1169 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Dropping scikit-learn dependency < 0.14.1
It makes easier to set base for decoder object in nilearn which actually requires lot of backports for versions. #1148
I don't have great justifications though. Let... | diff --git a/nilearn/version.py b/nilearn/version.py
--- a/nilearn/version.py
+++ b/nilearn/version.py
@@ -39,7 +39,7 @@
'required_at_installation': True,
'install_info': _NILEARN_INSTALL_MSG}),
('sklearn', {
- 'min_version': '0.13',
+ 'min_version': '0.14.1',
'required_at_... | {"golden_diff": "diff --git a/nilearn/version.py b/nilearn/version.py\n--- a/nilearn/version.py\n+++ b/nilearn/version.py\n@@ -39,7 +39,7 @@\n 'required_at_installation': True,\n 'install_info': _NILEARN_INSTALL_MSG}),\n ('sklearn', {\n- 'min_version': '0.13',\n+ 'min_version': '0.14.1... | 1,468 | 125 |
gh_patches_debug_19787 | rasdani/github-patches | git_diff | digitalfabrik__integreat-cms-538 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Pages endpoint: skip pages if parent is not visible
If a parent page in the page tree is in any state that makes it invisible in the API, we do not want the children to appear in the pages endpoint. This shou... | diff --git a/src/api/v3/pages.py b/src/api/v3/pages.py
--- a/src/api/v3/pages.py
+++ b/src/api/v3/pages.py
@@ -36,10 +36,20 @@
def pages(request, region_slug, language_code):
region = Region.get_current_region(request)
result = []
- for page in region.pages.all():
+ for page in region.pages.filter(arch... | {"golden_diff": "diff --git a/src/api/v3/pages.py b/src/api/v3/pages.py\n--- a/src/api/v3/pages.py\n+++ b/src/api/v3/pages.py\n@@ -36,10 +36,20 @@\n def pages(request, region_slug, language_code):\n region = Region.get_current_region(request)\n result = []\n- for page in region.pages.all():\n+ for page in... | 764 | 237 |
gh_patches_debug_15390 | rasdani/github-patches | git_diff | pyodide__pyodide-1138 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Nested attribute access in JS->Python type conversion
Currently the following code fails,
```js
>>> from js import window
>>> window.URL.createObjectURL
Error: Traceback (most recent call last):
File "... | diff --git a/src/pyodide-py/pyodide/_core.py b/src/pyodide-py/pyodide/_core.py
--- a/src/pyodide-py/pyodide/_core.py
+++ b/src/pyodide-py/pyodide/_core.py
@@ -2,7 +2,7 @@
import platform
if platform.system() == "Emscripten":
- from _pyodide_core import JsProxy, JsBoundMethod, JsException
+ from _pyodide_core ... | {"golden_diff": "diff --git a/src/pyodide-py/pyodide/_core.py b/src/pyodide-py/pyodide/_core.py\n--- a/src/pyodide-py/pyodide/_core.py\n+++ b/src/pyodide-py/pyodide/_core.py\n@@ -2,7 +2,7 @@\n import platform\n \n if platform.system() == \"Emscripten\":\n- from _pyodide_core import JsProxy, JsBoundMethod, JsExceptio... | 811 | 235 |
gh_patches_debug_5221 | rasdani/github-patches | git_diff | saulpw__visidata-1011 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
vds: cannot export sheets containing a date column
**Small description**
It's not possible to save a sheet to a .vds file if said sheet contains a date column.
This results in the error below.
**Expect... | diff --git a/visidata/loaders/vds.py b/visidata/loaders/vds.py
--- a/visidata/loaders/vds.py
+++ b/visidata/loaders/vds.py
@@ -29,7 +29,7 @@
with Progress(gerund='saving'):
for row in vs.iterdispvals(*vs.visibleCols, format=False):
d = {col.name:val for col, val in row... | {"golden_diff": "diff --git a/visidata/loaders/vds.py b/visidata/loaders/vds.py\n--- a/visidata/loaders/vds.py\n+++ b/visidata/loaders/vds.py\n@@ -29,7 +29,7 @@\n with Progress(gerund='saving'):\n for row in vs.iterdispvals(*vs.visibleCols, format=False):\n d = {col.name:... | 1,750 | 129 |
gh_patches_debug_33630 | rasdani/github-patches | git_diff | wagtail__wagtail-1150 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Possibly incorrect hook names?
Going through the docs, I see two rather unusual hook names: `construct_wagtail_edit_bird` and `construct_whitelister_element_rules`.
The first seems like a placeholder name t... | diff --git a/wagtail/wagtailadmin/views/userbar.py b/wagtail/wagtailadmin/views/userbar.py
--- a/wagtail/wagtailadmin/views/userbar.py
+++ b/wagtail/wagtailadmin/views/userbar.py
@@ -1,3 +1,5 @@
+import warnings
+
from django.shortcuts import render
from django.contrib.auth.decorators import permission_required
@@ ... | {"golden_diff": "diff --git a/wagtail/wagtailadmin/views/userbar.py b/wagtail/wagtailadmin/views/userbar.py\n--- a/wagtail/wagtailadmin/views/userbar.py\n+++ b/wagtail/wagtailadmin/views/userbar.py\n@@ -1,3 +1,5 @@\n+import warnings\n+\n from django.shortcuts import render\n from django.contrib.auth.decorators import p... | 1,182 | 514 |
gh_patches_debug_39227 | rasdani/github-patches | git_diff | scikit-image__scikit-image-3930 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Use astropy instead of pyfits to read FITS images
pyfits is not currently installable on 3.5, and it looks like AstroPy is more actively maintained.
--- END ISSUE ---
Below are some code segments, each from... | diff --git a/skimage/io/_plugins/fits_plugin.py b/skimage/io/_plugins/fits_plugin.py
--- a/skimage/io/_plugins/fits_plugin.py
+++ b/skimage/io/_plugins/fits_plugin.py
@@ -3,15 +3,12 @@
import skimage.io as io
try:
- from astropy.io import fits as pyfits
+ from astropy.io import fits
except ImportError:
- ... | {"golden_diff": "diff --git a/skimage/io/_plugins/fits_plugin.py b/skimage/io/_plugins/fits_plugin.py\n--- a/skimage/io/_plugins/fits_plugin.py\n+++ b/skimage/io/_plugins/fits_plugin.py\n@@ -3,15 +3,12 @@\n import skimage.io as io\n \n try:\n- from astropy.io import fits as pyfits\n+ from astropy.io import fits\n... | 1,741 | 688 |
gh_patches_debug_34926 | rasdani/github-patches | git_diff | Project-MONAI__MONAI-3770 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Clarify the `num_workers` in `ThreadDataLoader`
**Is your feature request related to a problem? Please describe.**
When I was introducing GPU transforms and the associated `ThreadDataLoader` to users, got se... | diff --git a/monai/data/thread_buffer.py b/monai/data/thread_buffer.py
--- a/monai/data/thread_buffer.py
+++ b/monai/data/thread_buffer.py
@@ -89,6 +89,12 @@
on the same batch will still produce good training with minimal short-term overfitting while allowing a slow batch
generation process more time to produ... | {"golden_diff": "diff --git a/monai/data/thread_buffer.py b/monai/data/thread_buffer.py\n--- a/monai/data/thread_buffer.py\n+++ b/monai/data/thread_buffer.py\n@@ -89,6 +89,12 @@\n on the same batch will still produce good training with minimal short-term overfitting while allowing a slow batch\n generation proc... | 1,873 | 562 |
gh_patches_debug_6496 | rasdani/github-patches | git_diff | interlegis__sapl-3150 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Períodos de parlamentares sumiram
## Comportamento Esperado
Devem aparecer todos os períodos dos parlamentares, correspondentes às legislaturas.
## Comportamento Atual
Aparecem apenas da 6ª legislatura à... | diff --git a/sapl/api/pagination.py b/sapl/api/pagination.py
--- a/sapl/api/pagination.py
+++ b/sapl/api/pagination.py
@@ -8,6 +8,11 @@
page_size_query_param = 'page_size'
max_page_size = 50
+ def paginate_queryset(self, queryset, request, view=None):
+ if request.query_params.get('get_all', False... | {"golden_diff": "diff --git a/sapl/api/pagination.py b/sapl/api/pagination.py\n--- a/sapl/api/pagination.py\n+++ b/sapl/api/pagination.py\n@@ -8,6 +8,11 @@\n page_size_query_param = 'page_size'\n max_page_size = 50\n \n+ def paginate_queryset(self, queryset, request, view=None):\n+ if request.query_pa... | 807 | 142 |
gh_patches_debug_20590 | rasdani/github-patches | git_diff | e-valuation__EvaP-795 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Remove passwords from error messages
EvaP sends error messages to the admins when a server error occurs. Post data sent to the page where the error occurred will be included in the message, but passwords must... | diff --git a/evap/evaluation/views.py b/evap/evaluation/views.py
--- a/evap/evaluation/views.py
+++ b/evap/evaluation/views.py
@@ -10,6 +10,7 @@
from django.utils.translation import ugettext as _
from django.core.urlresolvers import resolve, Resolver404
from django.views.decorators.http import require_POST
+from dja... | {"golden_diff": "diff --git a/evap/evaluation/views.py b/evap/evaluation/views.py\n--- a/evap/evaluation/views.py\n+++ b/evap/evaluation/views.py\n@@ -10,6 +10,7 @@\n from django.utils.translation import ugettext as _\n from django.core.urlresolvers import resolve, Resolver404\n from django.views.decorators.http import... | 1,637 | 201 |
gh_patches_debug_6190 | rasdani/github-patches | git_diff | microsoft__torchgeo-626 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Update README
Before blog: update verbiage and add pics from blog/paper.
After blog: add link to blog.
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files... | diff --git a/torchgeo/__init__.py b/torchgeo/__init__.py
--- a/torchgeo/__init__.py
+++ b/torchgeo/__init__.py
@@ -1,7 +1,7 @@
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.
-"""TorchGeo: datasets, transforms, and models for geospatial data.
+"""TorchGeo: datasets, sam... | {"golden_diff": "diff --git a/torchgeo/__init__.py b/torchgeo/__init__.py\n--- a/torchgeo/__init__.py\n+++ b/torchgeo/__init__.py\n@@ -1,7 +1,7 @@\n # Copyright (c) Microsoft Corporation. All rights reserved.\n # Licensed under the MIT License.\n \n-\"\"\"TorchGeo: datasets, transforms, and models for geospatial data.\... | 432 | 145 |
gh_patches_debug_34052 | rasdani/github-patches | git_diff | ckan__ckan-5750 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Purging deleted packages does not delete associated filestore/datastore resources
**CKAN version**
2.9
**Describe the bug**
After deleting and purging dataset packages, the associated datastore/filestore... | diff --git a/ckanext/datastore/cli.py b/ckanext/datastore/cli.py
--- a/ckanext/datastore/cli.py
+++ b/ckanext/datastore/cli.py
@@ -7,6 +7,7 @@
from ckan.model import parse_db_config
from ckan.common import config
+import ckan.logic as logic
import ckanext.datastore as datastore_module
from ckanext.datastore.bac... | {"golden_diff": "diff --git a/ckanext/datastore/cli.py b/ckanext/datastore/cli.py\n--- a/ckanext/datastore/cli.py\n+++ b/ckanext/datastore/cli.py\n@@ -7,6 +7,7 @@\n \n from ckan.model import parse_db_config\n from ckan.common import config\n+import ckan.logic as logic\n \n import ckanext.datastore as datastore_module\n... | 1,465 | 664 |
gh_patches_debug_19386 | rasdani/github-patches | git_diff | OCHA-DAP__hdx-ckan-1747 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Ebola Page: make millions and % smaller
About half the current height looks right.

--- END ISSU... | diff --git a/ckanext-hdx_crisis/ckanext/hdx_crisis/controllers/crisis_controller.py b/ckanext-hdx_crisis/ckanext/hdx_crisis/controllers/crisis_controller.py
--- a/ckanext-hdx_crisis/ckanext/hdx_crisis/controllers/crisis_controller.py
+++ b/ckanext-hdx_crisis/ckanext/hdx_crisis/controllers/crisis_controller.py
@@ -94,12... | {"golden_diff": "diff --git a/ckanext-hdx_crisis/ckanext/hdx_crisis/controllers/crisis_controller.py b/ckanext-hdx_crisis/ckanext/hdx_crisis/controllers/crisis_controller.py\n--- a/ckanext-hdx_crisis/ckanext/hdx_crisis/controllers/crisis_controller.py\n+++ b/ckanext-hdx_crisis/ckanext/hdx_crisis/controllers/crisis_cont... | 1,634 | 306 |
gh_patches_debug_26743 | rasdani/github-patches | git_diff | sktime__sktime-533 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[BUG] plot_series inconsistent date/time index
**Describe the bug**
<!--
A clear and concise description of what the bug is.
-->
**To Reproduce**
```python
y = load_airline()
y = y[:48]
fh=np.ara... | diff --git a/sktime/utils/plotting/__init__.py b/sktime/utils/plotting/__init__.py
--- a/sktime/utils/plotting/__init__.py
+++ b/sktime/utils/plotting/__init__.py
@@ -5,8 +5,6 @@
__all__ = ["plot_series"]
__author__ = ["Markus Löning"]
-import warnings
-
import numpy as np
from sktime.utils.check_imports import... | {"golden_diff": "diff --git a/sktime/utils/plotting/__init__.py b/sktime/utils/plotting/__init__.py\n--- a/sktime/utils/plotting/__init__.py\n+++ b/sktime/utils/plotting/__init__.py\n@@ -5,8 +5,6 @@\n __all__ = [\"plot_series\"]\n __author__ = [\"Markus L\u00f6ning\"]\n \n-import warnings\n-\n import numpy as np\n \n f... | 1,990 | 379 |
gh_patches_debug_18214 | rasdani/github-patches | git_diff | python-poetry__poetry-1954 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
command to check lock file
<!-- Checked checkbox should look like this: [x] -->
- [X] I have searched the [issues](https://github.com/sdispater/poetry/issues) of this repo and believe that this is not a dupl... | diff --git a/poetry/console/commands/lock.py b/poetry/console/commands/lock.py
--- a/poetry/console/commands/lock.py
+++ b/poetry/console/commands/lock.py
@@ -12,6 +12,12 @@
option(
"no-update", None, "Do not update locked versions, only refresh lock file."
),
+ option(
+ ... | {"golden_diff": "diff --git a/poetry/console/commands/lock.py b/poetry/console/commands/lock.py\n--- a/poetry/console/commands/lock.py\n+++ b/poetry/console/commands/lock.py\n@@ -12,6 +12,12 @@\n option(\n \"no-update\", None, \"Do not update locked versions, only refresh lock file.\"\n ),\n... | 666 | 243 |
gh_patches_debug_39342 | rasdani/github-patches | git_diff | conan-io__conan-5564 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
VS generator not exporting for <Lib> tag in vcxproj
Need to add Conan-handled lib to be referenced in .vcxproj in <Lib> tags. Conan VS-generator is exporting only in <Link> tag.
--- END ISSUE ---
Below a... | diff --git a/conans/client/generators/visualstudio.py b/conans/client/generators/visualstudio.py
--- a/conans/client/generators/visualstudio.py
+++ b/conans/client/generators/visualstudio.py
@@ -19,8 +19,12 @@
</Project>'''
properties_template = ''' <PropertyGroup Label="ConanVariables"{condition}>
- <Conan... | {"golden_diff": "diff --git a/conans/client/generators/visualstudio.py b/conans/client/generators/visualstudio.py\n--- a/conans/client/generators/visualstudio.py\n+++ b/conans/client/generators/visualstudio.py\n@@ -19,8 +19,12 @@\n </Project>'''\n \n properties_template = ''' <PropertyGroup Label=\"ConanVariables\... | 1,558 | 725 |
gh_patches_debug_9185 | rasdani/github-patches | git_diff | fidals__shopelectro-729 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
502 error on category pages
We can reproduce it with code below.
Seems it's connected with https://github.com/fidals/shopelectro/issues/648, but it's not checked yet
```
import requests
BASE = 'http... | diff --git a/shopelectro/celery.py b/shopelectro/celery.py
--- a/shopelectro/celery.py
+++ b/shopelectro/celery.py
@@ -83,11 +83,11 @@
task_default_queue='default',
task_default_exchange='default',
task_default_routing_key='default',
- task_ignore_result=True,
- worker_pool_restarts=1000,
+ work... | {"golden_diff": "diff --git a/shopelectro/celery.py b/shopelectro/celery.py\n--- a/shopelectro/celery.py\n+++ b/shopelectro/celery.py\n@@ -83,11 +83,11 @@\n task_default_queue='default',\n task_default_exchange='default',\n task_default_routing_key='default',\n- task_ignore_result=True,\n- worker_pool... | 1,484 | 167 |
gh_patches_debug_5657 | rasdani/github-patches | git_diff | chainer__chainer-254 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
`split_axis` fails when it splits the last axis of an array on py3
This code causes an error.
```
>>> x=chainer.Variable(chainer.cuda.to_gpu(numpy.array([1,2,3], numpy.float32)))
>>> chainer.functions.split_... | diff --git a/chainer/functions/split_axis.py b/chainer/functions/split_axis.py
--- a/chainer/functions/split_axis.py
+++ b/chainer/functions/split_axis.py
@@ -57,7 +57,7 @@
def forward_gpu(self, x):
xshape = x[0].shape
self.cdimx = xshape[self.axis]
- self.rdim = numpy.prod(xshape[self.axi... | {"golden_diff": "diff --git a/chainer/functions/split_axis.py b/chainer/functions/split_axis.py\n--- a/chainer/functions/split_axis.py\n+++ b/chainer/functions/split_axis.py\n@@ -57,7 +57,7 @@\n def forward_gpu(self, x):\n xshape = x[0].shape\n self.cdimx = xshape[self.axis]\n- self.rdim = nu... | 1,846 | 138 |
gh_patches_debug_13030 | rasdani/github-patches | git_diff | microsoft__AzureTRE-395 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Application Insights configuration for processor function broken
The `createNewWorkspace` function monitoring blade indicates that Application Insights integration is not enabled.

logger.addHandler(logging.StreamHandler()) # For logging into console
- a... | {"golden_diff": "diff --git a/processor_function/shared/logging.py b/processor_function/shared/logging.py\n--- a/processor_function/shared/logging.py\n+++ b/processor_function/shared/logging.py\n@@ -18,10 +18,10 @@\n \"\"\"\n logger = logging.getLogger()\n logger.addHandler(logging.StreamHandler()) # For l... | 932 | 181 |
gh_patches_debug_22772 | rasdani/github-patches | git_diff | nilearn__nilearn-559 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Doc does not build
Am I the only one?
```
Exception occurred:
File "/home/aa013911/work/nilearn/doc/sphinxext/sphinxgallery/docs_resolv.py", line 348, in embed_code_links
gallery_dir = os.path.join(app... | diff --git a/doc/sphinxext/sphinxgallery/__init__.py b/doc/sphinxext/sphinxgallery/__init__.py
--- a/doc/sphinxext/sphinxgallery/__init__.py
+++ b/doc/sphinxext/sphinxgallery/__init__.py
@@ -1,7 +1,7 @@
"""Sphinx Gallery
"""
import os
-__version__ = '0.0.8'
+__version__ = '0.0.9-dev'
def path_static():
"""Re... | {"golden_diff": "diff --git a/doc/sphinxext/sphinxgallery/__init__.py b/doc/sphinxext/sphinxgallery/__init__.py\n--- a/doc/sphinxext/sphinxgallery/__init__.py\n+++ b/doc/sphinxext/sphinxgallery/__init__.py\n@@ -1,7 +1,7 @@\n \"\"\"Sphinx Gallery\n \"\"\"\n import os\n-__version__ = '0.0.8'\n+__version__ = '0.0.9-dev'\n... | 1,504 | 312 |
gh_patches_debug_22829 | rasdani/github-patches | git_diff | pyodide__pyodide-891 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
JsProxy does not handle Error correctly
Example:
```python
from js import Error
e = Error.new("Hi")
raise e
```
Raises: `TypeError: exceptions must derive from BaseException`.
This came up in https://g... | diff --git a/src/pyodide-py/pyodide/__init__.py b/src/pyodide-py/pyodide/__init__.py
--- a/src/pyodide-py/pyodide/__init__.py
+++ b/src/pyodide-py/pyodide/__init__.py
@@ -1,6 +1,13 @@
-from ._base import open_url, eval_code, find_imports, as_nested_list
+from ._base import open_url, eval_code, find_imports, as_nested_l... | {"golden_diff": "diff --git a/src/pyodide-py/pyodide/__init__.py b/src/pyodide-py/pyodide/__init__.py\n--- a/src/pyodide-py/pyodide/__init__.py\n+++ b/src/pyodide-py/pyodide/__init__.py\n@@ -1,6 +1,13 @@\n-from ._base import open_url, eval_code, find_imports, as_nested_list\n+from ._base import open_url, eval_code, fin... | 1,422 | 429 |
gh_patches_debug_20992 | rasdani/github-patches | git_diff | fossasia__open-event-server-4997 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Minor bug in export orders as CSV task
**Describe the bug**
Minor bug in exporting orders as CSV. Trying to decode string which throws a type error:
```python
if order.user and order.... | diff --git a/app/api/helpers/csv_jobs_util.py b/app/api/helpers/csv_jobs_util.py
--- a/app/api/helpers/csv_jobs_util.py
+++ b/app/api/helpers/csv_jobs_util.py
@@ -9,11 +9,11 @@
str(order.status) if order.status else '', str(order.paid_via) if order.paid_via else '',
str(ord... | {"golden_diff": "diff --git a/app/api/helpers/csv_jobs_util.py b/app/api/helpers/csv_jobs_util.py\n--- a/app/api/helpers/csv_jobs_util.py\n+++ b/app/api/helpers/csv_jobs_util.py\n@@ -9,11 +9,11 @@\n str(order.status) if order.status else '', str(order.paid_via) if order.paid_via else '',\n ... | 767 | 219 |
gh_patches_debug_56926 | rasdani/github-patches | git_diff | kivy__python-for-android-615 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
OpenSSL 1.0.2e outdated (replaced by 1.0.2f)
A new version has been published today. The recipe no longer can download version 1.0.2e.
Does `disable-solver.patch` still apply?
--- END ISSUE ---
Below are ... | diff --git a/pythonforandroid/recipes/openssl/__init__.py b/pythonforandroid/recipes/openssl/__init__.py
--- a/pythonforandroid/recipes/openssl/__init__.py
+++ b/pythonforandroid/recipes/openssl/__init__.py
@@ -5,7 +5,7 @@
class OpenSSLRecipe(Recipe):
- version = '1.0.2e'
+ version = '1.0.2f'
url = 'htt... | {"golden_diff": "diff --git a/pythonforandroid/recipes/openssl/__init__.py b/pythonforandroid/recipes/openssl/__init__.py\n--- a/pythonforandroid/recipes/openssl/__init__.py\n+++ b/pythonforandroid/recipes/openssl/__init__.py\n@@ -5,7 +5,7 @@\n \n \n class OpenSSLRecipe(Recipe):\n- version = '1.0.2e'\n+ version =... | 1,001 | 125 |
gh_patches_debug_520 | rasdani/github-patches | git_diff | googleapis__google-api-python-client-303 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Suggest use of httplib2 v0.9.2 in readme if using python > 3
Python3.x implementations of the client, passes bytestring to httplib2 header encoding method. Httplib2 < 0.9.2 does not support this.
Documentat... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -63,7 +63,7 @@
]
install_requires = [
- 'httplib2>=0.8,<1dev',
+ 'httplib2>=0.9.2,<1dev',
'oauth2client>=1.5.0,<5.0.0dev',
'six>=1.6.1,<2dev',
'uritemplate>=3.0.0,<4dev',
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -63,7 +63,7 @@\n ]\n \n install_requires = [\n- 'httplib2>=0.8,<1dev',\n+ 'httplib2>=0.9.2,<1dev',\n 'oauth2client>=1.5.0,<5.0.0dev',\n 'six>=1.6.1,<2dev',\n 'uritemplate>=3.0.0,<4dev',\n", "issue": "Suggest use of h... | 1,374 | 115 |
gh_patches_debug_504 | rasdani/github-patches | git_diff | beetbox__beets-3702 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
"the" plugin uses incorrect regex
### Problem
Running this command:
```sh
~ ❯ beet move artist:trance -p
Moving 40 items.
M:\TET - Travailleur En Trance\[2008] Cobra Coded Escalation\01-01 - Cobra Re... | diff --git a/beetsplug/the.py b/beetsplug/the.py
--- a/beetsplug/the.py
+++ b/beetsplug/the.py
@@ -23,7 +23,7 @@
__author__ = 'baobab@heresiarch.info'
__version__ = '1.1'
-PATTERN_THE = u'^[the]{3}\\s'
+PATTERN_THE = u'^the\\s'
PATTERN_A = u'^[a][n]?\\s'
FORMAT = u'{0}, {1}'
| {"golden_diff": "diff --git a/beetsplug/the.py b/beetsplug/the.py\n--- a/beetsplug/the.py\n+++ b/beetsplug/the.py\n@@ -23,7 +23,7 @@\n __author__ = 'baobab@heresiarch.info'\n __version__ = '1.1'\n \n-PATTERN_THE = u'^[the]{3}\\\\s'\n+PATTERN_THE = u'^the\\\\s'\n PATTERN_A = u'^[a][n]?\\\\s'\n FORMAT = u'{0}, {1}'\n", "... | 1,454 | 115 |
gh_patches_debug_777 | rasdani/github-patches | git_diff | getmoto__moto-1840 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Cryptography Package has a Security Vulnerability
Discovered using pipenv's security check feature that there's a vulnerability in the cryptography package versions<2.3.
> Checking installed package sa... | diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -10,7 +10,7 @@
"boto>=2.36.0",
"boto3>=1.6.16,<1.8",
"botocore>=1.9.16,<1.11",
- "cryptography>=2.0.0",
+ "cryptography>=2.3.0",
"requests>=2.5",
"xmltodict",
"six>1.9",
| {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -10,7 +10,7 @@\n \"boto>=2.36.0\",\n \"boto3>=1.6.16,<1.8\",\n \"botocore>=1.9.16,<1.11\",\n- \"cryptography>=2.0.0\",\n+ \"cryptography>=2.3.0\",\n \"requests>=2.5\",\n \"xmltodict\",\n \"six>1.9\",\n", ... | 1,170 | 125 |
gh_patches_debug_49499 | rasdani/github-patches | git_diff | pex-tool__pex-1896 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Release 2.1.104
On the docket:
+ [x] Pull in Pip fixes. #1805
+ [x] pex fails to overwrite zipapp pex with loose pex #1879
+ [x] Make lock update sensitive to artifacts. #1887
+ [x] PEXBuilder is not rob... | diff --git a/pex/version.py b/pex/version.py
--- a/pex/version.py
+++ b/pex/version.py
@@ -1,4 +1,4 @@
# Copyright 2015 Pants project contributors (see CONTRIBUTORS.md).
# Licensed under the Apache License, Version 2.0 (see LICENSE).
-__version__ = "2.1.103"
+__version__ = "2.1.104"
| {"golden_diff": "diff --git a/pex/version.py b/pex/version.py\n--- a/pex/version.py\n+++ b/pex/version.py\n@@ -1,4 +1,4 @@\n # Copyright 2015 Pants project contributors (see CONTRIBUTORS.md).\n # Licensed under the Apache License, Version 2.0 (see LICENSE).\n \n-__version__ = \"2.1.103\"\n+__version__ = \"2.1.104\"\n",... | 403 | 98 |
gh_patches_debug_2793 | rasdani/github-patches | git_diff | kornia__kornia-579 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Backslash not showing in equation for Tversky Loss
## 📚 Documentation
The backslashs in the denominator of the Tversky loss equation is not rendered correctly with MathJax. As shown in this screenshot it ... | diff --git a/kornia/losses/tversky.py b/kornia/losses/tversky.py
--- a/kornia/losses/tversky.py
+++ b/kornia/losses/tversky.py
@@ -61,7 +61,7 @@
.. math::
\text{S}(P, G, \alpha; \beta) =
- \frac{|PG|}{|PG| + \alpha |P \ G| + \beta |G \ P|}
+ \frac{|PG|}{|PG| + \alpha |P \setminus G| + ... | {"golden_diff": "diff --git a/kornia/losses/tversky.py b/kornia/losses/tversky.py\n--- a/kornia/losses/tversky.py\n+++ b/kornia/losses/tversky.py\n@@ -61,7 +61,7 @@\n .. math::\n \n \\text{S}(P, G, \\alpha; \\beta) =\n- \\frac{|PG|}{|PG| + \\alpha |P \\ G| + \\beta |G \\ P|}\n+ \\frac{|PG|... | 1,677 | 169 |
gh_patches_debug_18960 | rasdani/github-patches | git_diff | wagtail__wagtail-9119 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Locked pages report renders all users in "locked_by" filter
### Issue Summary
Currently, the select-field for the "locked_by" filter on the "Locked pages"-report renders all users unfiltered from the user ... | diff --git a/wagtail/admin/views/reports/locked_pages.py b/wagtail/admin/views/reports/locked_pages.py
--- a/wagtail/admin/views/reports/locked_pages.py
+++ b/wagtail/admin/views/reports/locked_pages.py
@@ -2,6 +2,7 @@
import django_filters
from django.conf import settings
+from django.contrib.auth import get_user_... | {"golden_diff": "diff --git a/wagtail/admin/views/reports/locked_pages.py b/wagtail/admin/views/reports/locked_pages.py\n--- a/wagtail/admin/views/reports/locked_pages.py\n+++ b/wagtail/admin/views/reports/locked_pages.py\n@@ -2,6 +2,7 @@\n \n import django_filters\n from django.conf import settings\n+from django.contr... | 1,186 | 236 |
gh_patches_debug_207 | rasdani/github-patches | git_diff | chainer__chainer-239 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Add type check to Identity Function
Related to #123
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `chaine... | diff --git a/chainer/functions/identity.py b/chainer/functions/identity.py
--- a/chainer/functions/identity.py
+++ b/chainer/functions/identity.py
@@ -5,6 +5,9 @@
"""Identity function."""
+ def check_type_forward(self, in_types):
+ pass
+
def forward(self, xs):
return xs
| {"golden_diff": "diff --git a/chainer/functions/identity.py b/chainer/functions/identity.py\n--- a/chainer/functions/identity.py\n+++ b/chainer/functions/identity.py\n@@ -5,6 +5,9 @@\n \n \"\"\"Identity function.\"\"\"\n \n+ def check_type_forward(self, in_types):\n+ pass\n+\n def forward(self, xs):\n... | 369 | 80 |
gh_patches_debug_4580 | rasdani/github-patches | git_diff | pypa__pip-5136 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Name normalization issue in 10.0.0b1 yields false-positive installation warnings
* Pip version: 10.0.0b1
* Python version: 2.7.14
* Operating system: Linux
### Description:
The new pip check mode used... | diff --git a/src/pip/_internal/operations/check.py b/src/pip/_internal/operations/check.py
--- a/src/pip/_internal/operations/check.py
+++ b/src/pip/_internal/operations/check.py
@@ -99,4 +99,5 @@
# Modify it as installing requirement_set would (assuming no errors)
for inst_req in to_install:
dist = ... | {"golden_diff": "diff --git a/src/pip/_internal/operations/check.py b/src/pip/_internal/operations/check.py\n--- a/src/pip/_internal/operations/check.py\n+++ b/src/pip/_internal/operations/check.py\n@@ -99,4 +99,5 @@\n # Modify it as installing requirement_set would (assuming no errors)\n for inst_req in to_ins... | 1,939 | 136 |
gh_patches_debug_4138 | rasdani/github-patches | git_diff | google__turbinia-793 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
path_spec.parent is None exception
```
FsstatTask Task failed with exception: ['NoneType' object has no attribute 'type_indicator']
Traceback (most recent call last):
File "/usr/local/lib/python3.6/dist-... | diff --git a/turbinia/processors/partitions.py b/turbinia/processors/partitions.py
--- a/turbinia/processors/partitions.py
+++ b/turbinia/processors/partitions.py
@@ -64,6 +64,10 @@
String representing the type of encryption, or None.
"""
encryption_type = None
+
+ if not path_spec.HasParent():
+ return ... | {"golden_diff": "diff --git a/turbinia/processors/partitions.py b/turbinia/processors/partitions.py\n--- a/turbinia/processors/partitions.py\n+++ b/turbinia/processors/partitions.py\n@@ -64,6 +64,10 @@\n String representing the type of encryption, or None.\n \"\"\"\n encryption_type = None\n+\n+ if not path_sp... | 1,753 | 127 |
gh_patches_debug_10351 | rasdani/github-patches | git_diff | liqd__a4-meinberlin-3993 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
In Bplans required field (start-date & end-date) for publication is not marked as such
**URL:** https://meinberlin-dev.liqd.net/dashboard/projects/sabinas-bebauungsplan/bplan/
**user:** A Bplan initiator
**... | diff --git a/meinberlin/apps/bplan/forms.py b/meinberlin/apps/bplan/forms.py
--- a/meinberlin/apps/bplan/forms.py
+++ b/meinberlin/apps/bplan/forms.py
@@ -28,7 +28,8 @@
'tile_image_copyright', 'is_archived', 'office_worker_email',
'start_date', 'end_date']
required_for_pro... | {"golden_diff": "diff --git a/meinberlin/apps/bplan/forms.py b/meinberlin/apps/bplan/forms.py\n--- a/meinberlin/apps/bplan/forms.py\n+++ b/meinberlin/apps/bplan/forms.py\n@@ -28,7 +28,8 @@\n 'tile_image_copyright', 'is_archived', 'office_worker_email',\n 'start_date', 'end_date']\n ... | 814 | 149 |
gh_patches_debug_12785 | rasdani/github-patches | git_diff | learningequality__kolibri-8076 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Catch ValueError during network discovery for when JSON parsing fails
<!--
Instructions:
* Fill out the sections below, replace …'s with information about your issue
* Use the 'preview' function above th... | diff --git a/kolibri/core/discovery/utils/network/client.py b/kolibri/core/discovery/utils/network/client.py
--- a/kolibri/core/discovery/utils/network/client.py
+++ b/kolibri/core/discovery/utils/network/client.py
@@ -55,6 +55,10 @@
return response.url.rstrip("/").replace("api/public/info", "")
... | {"golden_diff": "diff --git a/kolibri/core/discovery/utils/network/client.py b/kolibri/core/discovery/utils/network/client.py\n--- a/kolibri/core/discovery/utils/network/client.py\n+++ b/kolibri/core/discovery/utils/network/client.py\n@@ -55,6 +55,10 @@\n return response.url.rstrip(\"/\").replace(\"... | 1,421 | 160 |
gh_patches_debug_12113 | rasdani/github-patches | git_diff | DataDog__dd-trace-py-1465 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
gRPC server interceptor raises AttributeError
When a gRPC service is not found, the Datadog interceptor raises an AttributeError:
```
ERROR grpc._server:_server.py:732 Exception servicing handler: 'Non... | diff --git a/ddtrace/contrib/grpc/server_interceptor.py b/ddtrace/contrib/grpc/server_interceptor.py
--- a/ddtrace/contrib/grpc/server_interceptor.py
+++ b/ddtrace/contrib/grpc/server_interceptor.py
@@ -18,7 +18,15 @@
return continuation(handler_call_details)
rpc_method_handler = continuation(ha... | {"golden_diff": "diff --git a/ddtrace/contrib/grpc/server_interceptor.py b/ddtrace/contrib/grpc/server_interceptor.py\n--- a/ddtrace/contrib/grpc/server_interceptor.py\n+++ b/ddtrace/contrib/grpc/server_interceptor.py\n@@ -18,7 +18,15 @@\n return continuation(handler_call_details)\n \n rpc_method_ha... | 1,914 | 188 |
gh_patches_debug_18834 | rasdani/github-patches | git_diff | alltheplaces__alltheplaces-3308 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Spider kopps is broken
During the global build at 2021-06-16-14-42-20, spider **kopps** failed with **0 features** and **1 errors**.
Here's [the log](https://data.alltheplaces.xyz/runs/2021-06-16-14-42-20/lo... | diff --git a/locations/spiders/kopps.py b/locations/spiders/kopps.py
--- a/locations/spiders/kopps.py
+++ b/locations/spiders/kopps.py
@@ -26,8 +26,9 @@
osm_days = []
if len(days) == 2:
for day in days:
- osm_day = DAY_MAPPING[day.strip()]
- ... | {"golden_diff": "diff --git a/locations/spiders/kopps.py b/locations/spiders/kopps.py\n--- a/locations/spiders/kopps.py\n+++ b/locations/spiders/kopps.py\n@@ -26,8 +26,9 @@\n osm_days = []\n if len(days) == 2:\n for day in days:\n- osm_day = DAY_MAPPING[day.str... | 1,588 | 228 |
gh_patches_debug_12705 | rasdani/github-patches | git_diff | Lightning-Universe__lightning-bolts-315 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
add caching for used dataset
## 🚀 Feature
atm for each CI run the datasets are downloaded (seems so as I observed som downloading failers)
### Motivation
Speed-up runs and avoids random connection f... | diff --git a/pl_bolts/models/mnist_module.py b/pl_bolts/models/mnist_module.py
--- a/pl_bolts/models/mnist_module.py
+++ b/pl_bolts/models/mnist_module.py
@@ -1,4 +1,3 @@
-import os
from argparse import ArgumentParser
from warnings import warn
@@ -70,7 +69,7 @@
return loader
def test_dataloader(self... | {"golden_diff": "diff --git a/pl_bolts/models/mnist_module.py b/pl_bolts/models/mnist_module.py\n--- a/pl_bolts/models/mnist_module.py\n+++ b/pl_bolts/models/mnist_module.py\n@@ -1,4 +1,3 @@\n-import os\n from argparse import ArgumentParser\n from warnings import warn\n \n@@ -70,7 +69,7 @@\n return loader\n \n ... | 1,415 | 169 |
gh_patches_debug_5031 | rasdani/github-patches | git_diff | svthalia__concrexit-2190 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Visual quirk in the login failure message
### Describe the bug
When you fail to log in on desktop (or probably any wider screen) the message saying this shows up on the left and the login fields are offset t... | diff --git a/website/thaliawebsite/templatetags/alert.py b/website/thaliawebsite/templatetags/alert.py
--- a/website/thaliawebsite/templatetags/alert.py
+++ b/website/thaliawebsite/templatetags/alert.py
@@ -6,7 +6,7 @@
@register.inclusion_tag("includes/alert.html")
def alert(alert_type="info", message=None, dismissib... | {"golden_diff": "diff --git a/website/thaliawebsite/templatetags/alert.py b/website/thaliawebsite/templatetags/alert.py\n--- a/website/thaliawebsite/templatetags/alert.py\n+++ b/website/thaliawebsite/templatetags/alert.py\n@@ -6,7 +6,7 @@\n @register.inclusion_tag(\"includes/alert.html\")\n def alert(alert_type=\"info\... | 621 | 144 |
gh_patches_debug_31883 | rasdani/github-patches | git_diff | sql-machine-learning__elasticdl-1385 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[PS-1] RPC service `push_model` implementation
--- END ISSUE ---
Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `elasticdl/p... | diff --git a/elasticdl/python/ps/parameters.py b/elasticdl/python/ps/parameters.py
--- a/elasticdl/python/ps/parameters.py
+++ b/elasticdl/python/ps/parameters.py
@@ -18,6 +18,7 @@
"""
def __init__(self):
+ self.version = 0
self.init_status = False
self.non_embedding_params = {}
... | {"golden_diff": "diff --git a/elasticdl/python/ps/parameters.py b/elasticdl/python/ps/parameters.py\n--- a/elasticdl/python/ps/parameters.py\n+++ b/elasticdl/python/ps/parameters.py\n@@ -18,6 +18,7 @@\n \"\"\"\n \n def __init__(self):\n+ self.version = 0\n self.init_status = False\n self.... | 1,160 | 413 |
gh_patches_debug_6 | rasdani/github-patches | git_diff | cookiecutter__cookiecutter-1273 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
PEP257 docstrings for file "./docs/__init__.py"
Cover `./docs/__init__.py` file with docstrings and follow [PEP257](https://www.python.org/dev/peps/pep-0257/). We use [pydocstyle](https://pypi.org/project/pyd... | diff --git a/docs/__init__.py b/docs/__init__.py
--- a/docs/__init__.py
+++ b/docs/__init__.py
@@ -0,0 +1,3 @@
+# -*- coding: utf-8 -*-
+
+"""Main package for docs."""
| {"golden_diff": "diff --git a/docs/__init__.py b/docs/__init__.py\n--- a/docs/__init__.py\n+++ b/docs/__init__.py\n@@ -0,0 +1,3 @@\n+# -*- coding: utf-8 -*-\n+\n+\"\"\"Main package for docs.\"\"\"\n", "issue": "PEP257 docstrings for file \"./docs/__init__.py\"\nCover `./docs/__init__.py` file with docstrings and follow... | 376 | 58 |
gh_patches_debug_17994 | rasdani/github-patches | git_diff | alltheplaces__alltheplaces-6938 | We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
Anthropologie spider produces transposed coordinates
https://www.alltheplaces.xyz/map/#7.69/-75.171/39.95

if ctypes.pythonapi.PyCapsule_IsValid(dltensor, _c_str_dltensor):
ptr = ctypes... | {"golden_diff": "diff --git a/python/tvm/_ffi/_ctypes/ndarray.py b/python/tvm/_ffi/_ctypes/ndarray.py\n--- a/python/tvm/_ffi/_ctypes/ndarray.py\n+++ b/python/tvm/_ffi/_ctypes/ndarray.py\n@@ -24,6 +24,8 @@\n dltensor = ctypes.py_object(dltensor)\n if ctypes.pythonapi.PyCapsule_IsValid(dltensor, _c_str_dltensor):... | 1,663 | 347 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.