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_14398
rasdani/github-patches
git_diff
akvo__akvo-rsr-3803
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- /related_project/ issue Attempted to POST the following data: {"relation":"1","project":"8012","related_iati_id":"23232"} The response is 400: `related_project: ["This field is required."]` However, w...
diff --git a/akvo/rest/serializers/related_project.py b/akvo/rest/serializers/related_project.py --- a/akvo/rest/serializers/related_project.py +++ b/akvo/rest/serializers/related_project.py @@ -5,7 +5,7 @@ # For additional details on the GNU license please see < http://www.gnu.org/licenses/agpl.html >. -from akvo...
{"golden_diff": "diff --git a/akvo/rest/serializers/related_project.py b/akvo/rest/serializers/related_project.py\n--- a/akvo/rest/serializers/related_project.py\n+++ b/akvo/rest/serializers/related_project.py\n@@ -5,7 +5,7 @@\n # For additional details on the GNU license please see < http://www.gnu.org/licenses/agpl.h...
651
193
gh_patches_debug_15838
rasdani/github-patches
git_diff
wagtail__wagtail-4730
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- AppRegistryNotReady("Apps aren't loaded yet.") ### After updating wagtail from 2.1 to 2.2 I get an AppRegistryNotReady error when migrating. Removing **from .sitemap_generator import Sitemap** from **wagt...
diff --git a/wagtail/contrib/sitemaps/sitemap_generator.py b/wagtail/contrib/sitemaps/sitemap_generator.py --- a/wagtail/contrib/sitemaps/sitemap_generator.py +++ b/wagtail/contrib/sitemaps/sitemap_generator.py @@ -2,7 +2,6 @@ from django.contrib.sitemaps import Sitemap as DjangoSitemap -from wagtail.core.models i...
{"golden_diff": "diff --git a/wagtail/contrib/sitemaps/sitemap_generator.py b/wagtail/contrib/sitemaps/sitemap_generator.py\n--- a/wagtail/contrib/sitemaps/sitemap_generator.py\n+++ b/wagtail/contrib/sitemaps/sitemap_generator.py\n@@ -2,7 +2,6 @@\n \n from django.contrib.sitemaps import Sitemap as DjangoSitemap\n \n-fr...
920
188
gh_patches_debug_14105
rasdani/github-patches
git_diff
interactions-py__interactions.py-1169
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [BUG] Cannot pop from Cache during dispatch. ### Describe the bug. When running functions leading to delete events, for example `channel.purge` the cache encounters a KeyError and kills the whole Process. ...
diff --git a/interactions/utils/dict_caches.py b/interactions/utils/dict_caches.py --- a/interactions/utils/dict_caches.py +++ b/interactions/utils/dict_caches.py @@ -1,6 +1,8 @@ from collections import OrderedDict from typing import Generic, TypeVar +from .missing import MISSING + __all__ = ("FIFODict", "LRUDict"...
{"golden_diff": "diff --git a/interactions/utils/dict_caches.py b/interactions/utils/dict_caches.py\n--- a/interactions/utils/dict_caches.py\n+++ b/interactions/utils/dict_caches.py\n@@ -1,6 +1,8 @@\n from collections import OrderedDict\n from typing import Generic, TypeVar\n \n+from .missing import MISSING\n+\n __all_...
1,579
216
gh_patches_debug_9077
rasdani/github-patches
git_diff
keras-team__keras-nlp-760
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Simplify docstring example of `TokenAndPositionEmbedding` The current [docstring example](https://github.com/keras-team/keras-nlp/blob/3a951a9f5442b77a0c474bb8b61406f65c7ef924/keras_nlp/layers/token_and_posit...
diff --git a/keras_nlp/layers/token_and_position_embedding.py b/keras_nlp/layers/token_and_position_embedding.py --- a/keras_nlp/layers/token_and_position_embedding.py +++ b/keras_nlp/layers/token_and_position_embedding.py @@ -47,14 +47,11 @@ Examples: ```python - seq_length = 50 - vocab_size = 5000 -...
{"golden_diff": "diff --git a/keras_nlp/layers/token_and_position_embedding.py b/keras_nlp/layers/token_and_position_embedding.py\n--- a/keras_nlp/layers/token_and_position_embedding.py\n+++ b/keras_nlp/layers/token_and_position_embedding.py\n@@ -47,14 +47,11 @@\n \n Examples:\n ```python\n- seq_length = 50\...
1,810
221
gh_patches_debug_21734
rasdani/github-patches
git_diff
marshmallow-code__webargs-99
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Refactor tests The tests can be DRY'd up significantly. I suggest the following: - [ ] Implement the same HTTP API across all the supported frameworks - [ ] Use webtest to test endpoints; create a base test c...
diff --git a/tasks.py b/tasks.py --- a/tasks.py +++ b/tasks.py @@ -17,7 +17,7 @@ args.extend(['--cov=webargs', '--cov-report=term', '--cov-report=html']) if sys.version_info < (3, 4, 1): - args.append('--ignore={0}'.format(os.path.join('tests', 'test_aiohttp'))) + args.append('--ignore={0}...
{"golden_diff": "diff --git a/tasks.py b/tasks.py\n--- a/tasks.py\n+++ b/tasks.py\n@@ -17,7 +17,7 @@\n args.extend(['--cov=webargs', '--cov-report=term', '--cov-report=html'])\n \n if sys.version_info < (3, 4, 1):\n- args.append('--ignore={0}'.format(os.path.join('tests', 'test_aiohttp')))\n+ ...
1,201
275
gh_patches_debug_12492
rasdani/github-patches
git_diff
TheAlgorithms__Python-9161
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- issue with permute_recursive ### What would you like to share? Your code looks mostly correct, but there's one issue in the `permute_recursive` function due to the modification of the `nums` list. Lists in P...
diff --git a/data_structures/arrays/permutations.py b/data_structures/arrays/permutations.py --- a/data_structures/arrays/permutations.py +++ b/data_structures/arrays/permutations.py @@ -10,7 +10,7 @@ return [[]] for _ in range(len(nums)): n = nums.pop(0) - permutations = permute_recursive...
{"golden_diff": "diff --git a/data_structures/arrays/permutations.py b/data_structures/arrays/permutations.py\n--- a/data_structures/arrays/permutations.py\n+++ b/data_structures/arrays/permutations.py\n@@ -10,7 +10,7 @@\n return [[]]\n for _ in range(len(nums)):\n n = nums.pop(0)\n- permutat...
1,078
187
gh_patches_debug_7516
rasdani/github-patches
git_diff
pre-commit__pre-commit-624
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- commit-msg stage does not work Everything works as expected when running just `pre-commit install`, then hooks work. But when running `pre-commit install -t commit-msg` `IOError` happens, since template coul...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -29,11 +29,7 @@ packages=find_packages(exclude=('tests*', 'testing*')), package_data={ 'pre_commit': [ - 'resources/hook-tmpl', - 'resources/pre-push-tmpl', - 'resources/rbenv.tar.gz', - 'res...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -29,11 +29,7 @@\n packages=find_packages(exclude=('tests*', 'testing*')),\n package_data={\n 'pre_commit': [\n- 'resources/hook-tmpl',\n- 'resources/pre-push-tmpl',\n- 'resources/rbenv....
1,223
130
gh_patches_debug_3561
rasdani/github-patches
git_diff
deepchecks__deepchecks-1101
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [BUG] some randomness occurring in tabular sample **Describe the bug** The results are not the same even when setting random states **To Reproduce** Run model error / performance report a couple of times...
diff --git a/docs/source/tutorials/tabular/plot_quickstart_in_5_minutes.py b/docs/source/tutorials/tabular/plot_quickstart_in_5_minutes.py --- a/docs/source/tutorials/tabular/plot_quickstart_in_5_minutes.py +++ b/docs/source/tutorials/tabular/plot_quickstart_in_5_minutes.py @@ -43,7 +43,7 @@ df_train, df_test = train_...
{"golden_diff": "diff --git a/docs/source/tutorials/tabular/plot_quickstart_in_5_minutes.py b/docs/source/tutorials/tabular/plot_quickstart_in_5_minutes.py\n--- a/docs/source/tutorials/tabular/plot_quickstart_in_5_minutes.py\n+++ b/docs/source/tutorials/tabular/plot_quickstart_in_5_minutes.py\n@@ -43,7 +43,7 @@\n df_tr...
1,794
157
gh_patches_debug_14064
rasdani/github-patches
git_diff
Lightning-AI__pytorch-lightning-2255
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- CPU/GPU Template ## 🐛 Bug The GPU or CPU template do not run currently on master after changes including the setup hook. ``` python -m pl_examples.basic_examples.gpu_template --gpus 4 --distribut...
diff --git a/pl_examples/basic_examples/gpu_template.py b/pl_examples/basic_examples/gpu_template.py --- a/pl_examples/basic_examples/gpu_template.py +++ b/pl_examples/basic_examples/gpu_template.py @@ -23,7 +23,7 @@ # ------------------------ # 1 INIT LIGHTNING MODEL # ------------------------ - mode...
{"golden_diff": "diff --git a/pl_examples/basic_examples/gpu_template.py b/pl_examples/basic_examples/gpu_template.py\n--- a/pl_examples/basic_examples/gpu_template.py\n+++ b/pl_examples/basic_examples/gpu_template.py\n@@ -23,7 +23,7 @@\n # ------------------------\n # 1 INIT LIGHTNING MODEL\n # -----------...
1,831
186
gh_patches_debug_37403
rasdani/github-patches
git_diff
streamlink__streamlink-1670
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [plugin issue] plugin.vidio.com / can't handle stream URLs anymore - [x] This is a bug report. - [ ] This is a feature request. - [ ] This is a plugin (improvement) request. - [ ] I have read the contribut...
diff --git a/src/streamlink/plugins/vidio.py b/src/streamlink/plugins/vidio.py --- a/src/streamlink/plugins/vidio.py +++ b/src/streamlink/plugins/vidio.py @@ -1,36 +1,61 @@ -''' +""" Plugin for vidio.com - https://www.vidio.com/live/5075-dw-tv-stream - https://www.vidio.com/watch/766861-5-rekor-fantastis-zidane-bers...
{"golden_diff": "diff --git a/src/streamlink/plugins/vidio.py b/src/streamlink/plugins/vidio.py\n--- a/src/streamlink/plugins/vidio.py\n+++ b/src/streamlink/plugins/vidio.py\n@@ -1,36 +1,61 @@\n-'''\n+\"\"\"\n Plugin for vidio.com\n - https://www.vidio.com/live/5075-dw-tv-stream\n - https://www.vidio.com/watch/766861-5...
961
835
gh_patches_debug_7782
rasdani/github-patches
git_diff
microsoft__ptvsd-818
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- test_path_names_uppercase_enabled fails ``` 2018-09-18T18:50:20.6706273Z ====================================================================== 2018-09-18T18:50:20.6706627Z FAIL [0.001s]: test_path_names_up...
diff --git a/ptvsd/pathutils.py b/ptvsd/pathutils.py --- a/ptvsd/pathutils.py +++ b/ptvsd/pathutils.py @@ -56,7 +56,8 @@ dir_names = os.listdir(os.getcwd()) fragments = list(filter( lambda x: x.upper() == path_fragment1, dir_names)) - fragments += list(d for...
{"golden_diff": "diff --git a/ptvsd/pathutils.py b/ptvsd/pathutils.py\n--- a/ptvsd/pathutils.py\n+++ b/ptvsd/pathutils.py\n@@ -56,7 +56,8 @@\n dir_names = os.listdir(os.getcwd())\n fragments = list(filter(\n lambda x: x.upper() == path_fragment1, dir_names))\n- ...
1,332
147
gh_patches_debug_8485
rasdani/github-patches
git_diff
SigmaHQ__sigma-1026
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Error while pushing sigma to misp using sigma2misp script (venv) hydra@Kaushals-MacBook-Air session2/sigma (master %) » tools/sigma2misp @misp.conf --insecure --same-event --info "Test Event" -r rules/windows...
diff --git a/tools/sigma/sigma2misp.py b/tools/sigma/sigma2misp.py --- a/tools/sigma/sigma2misp.py +++ b/tools/sigma/sigma2misp.py @@ -5,13 +5,13 @@ import pathlib import urllib3 urllib3.disable_warnings() -from pymisp import PyMISP +from pymisp import PyMISP, MISPEvent def create_new_event(args, misp): if h...
{"golden_diff": "diff --git a/tools/sigma/sigma2misp.py b/tools/sigma/sigma2misp.py\n--- a/tools/sigma/sigma2misp.py\n+++ b/tools/sigma/sigma2misp.py\n@@ -5,13 +5,13 @@\n import pathlib\n import urllib3\n urllib3.disable_warnings()\n-from pymisp import PyMISP\n+from pymisp import PyMISP, MISPEvent\n \n def create_new_e...
1,269
164
gh_patches_debug_5382
rasdani/github-patches
git_diff
DataDog__dd-trace-py-1268
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- ddtrace not working with new aiobotocore library ### Which version of dd-trace-py are you using? 0.34.0 ### Which version of the libraries are you using? ``` aiobotocore==0.12.0 aiohttp==3.6.2 aio...
diff --git a/ddtrace/contrib/aiobotocore/patch.py b/ddtrace/contrib/aiobotocore/patch.py --- a/ddtrace/contrib/aiobotocore/patch.py +++ b/ddtrace/contrib/aiobotocore/patch.py @@ -3,7 +3,11 @@ from ddtrace import config import aiobotocore.client -from aiobotocore.endpoint import ClientResponseContentProxy +try: + ...
{"golden_diff": "diff --git a/ddtrace/contrib/aiobotocore/patch.py b/ddtrace/contrib/aiobotocore/patch.py\n--- a/ddtrace/contrib/aiobotocore/patch.py\n+++ b/ddtrace/contrib/aiobotocore/patch.py\n@@ -3,7 +3,11 @@\n from ddtrace import config\n import aiobotocore.client\n \n-from aiobotocore.endpoint import ClientRespons...
1,938
172
gh_patches_debug_39363
rasdani/github-patches
git_diff
deepset-ai__haystack-6564
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- feat: Add embed_meta_fields support to rankers like in Haystack v1 **Is your feature request related to a problem? Please describe.** We have found that `embed_meta_fields` greatly improves ranking when meta...
diff --git a/haystack/components/rankers/transformers_similarity.py b/haystack/components/rankers/transformers_similarity.py --- a/haystack/components/rankers/transformers_similarity.py +++ b/haystack/components/rankers/transformers_similarity.py @@ -40,6 +40,8 @@ device: str = "cpu", token: Union[boo...
{"golden_diff": "diff --git a/haystack/components/rankers/transformers_similarity.py b/haystack/components/rankers/transformers_similarity.py\n--- a/haystack/components/rankers/transformers_similarity.py\n+++ b/haystack/components/rankers/transformers_similarity.py\n@@ -40,6 +40,8 @@\n device: str = \"cpu\",\n ...
1,824
601
gh_patches_debug_13449
rasdani/github-patches
git_diff
cloudtools__troposphere-178
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Cloudwatch Alarm Threshold Type The parameter type 'Threshold' within Cloudwatch Alarms is currently of type 'integer' whereas the AWS documentations notes this should be a String. http://docs.aws.amazon.com...
diff --git a/troposphere/cloudwatch.py b/troposphere/cloudwatch.py --- a/troposphere/cloudwatch.py +++ b/troposphere/cloudwatch.py @@ -4,7 +4,7 @@ # See LICENSE file for full license. from . import AWSObject, AWSProperty, Ref -from .validators import integer, positive_integer, boolean +from .validators import posit...
{"golden_diff": "diff --git a/troposphere/cloudwatch.py b/troposphere/cloudwatch.py\n--- a/troposphere/cloudwatch.py\n+++ b/troposphere/cloudwatch.py\n@@ -4,7 +4,7 @@\n # See LICENSE file for full license.\n \n from . import AWSObject, AWSProperty, Ref\n-from .validators import integer, positive_integer, boolean\n+from...
763
173
gh_patches_debug_14449
rasdani/github-patches
git_diff
scrapy__scrapy-602
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Allow sending HTML emails with scrapy.mail.MailSender I've patched this locally by changing the `send` method: ``` def send(self, to, subject, body, cc=None, attachs=(), mime='text/plain', _callback=None): ...
diff --git a/scrapy/mail.py b/scrapy/mail.py --- a/scrapy/mail.py +++ b/scrapy/mail.py @@ -35,11 +35,11 @@ settings['MAIL_PASS'], settings.getint('MAIL_PORT'), settings.getbool('MAIL_TLS'), settings.getbool('MAIL_SSL')) - def send(self, to, subject, body, cc=None, attachs=(), _callback=No...
{"golden_diff": "diff --git a/scrapy/mail.py b/scrapy/mail.py\n--- a/scrapy/mail.py\n+++ b/scrapy/mail.py\n@@ -35,11 +35,11 @@\n settings['MAIL_PASS'], settings.getint('MAIL_PORT'),\n settings.getbool('MAIL_TLS'), settings.getbool('MAIL_SSL'))\n \n- def send(self, to, subject, body, cc=None, ...
1,690
206
gh_patches_debug_27014
rasdani/github-patches
git_diff
chainer__chainer-1106
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- BatchNormalization does not switch the current GPU automatically As reported in the forum, the current implementation of BatchNormalization link does not switch the current GPU appropriately during computing ...
diff --git a/chainer/links/normalization/batch_normalization.py b/chainer/links/normalization/batch_normalization.py --- a/chainer/links/normalization/batch_normalization.py +++ b/chainer/links/normalization/batch_normalization.py @@ -1,5 +1,6 @@ import numpy +from chainer import cuda from chainer.functions.normali...
{"golden_diff": "diff --git a/chainer/links/normalization/batch_normalization.py b/chainer/links/normalization/batch_normalization.py\n--- a/chainer/links/normalization/batch_normalization.py\n+++ b/chainer/links/normalization/batch_normalization.py\n@@ -1,5 +1,6 @@\n import numpy\n \n+from chainer import cuda\n from c...
1,770
397
gh_patches_debug_31987
rasdani/github-patches
git_diff
vas3k__vas3k.club-142
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Визуализировать результаты батлов <img width="1113" alt="image" src="https://user-images.githubusercontent.com/19980512/81127819-1f135780-8f48-11ea-83bc-7c56e6e849e4.png"> Было бы круто как-то визуализиров...
diff --git a/posts/templatetags/battle.py b/posts/templatetags/battle.py --- a/posts/templatetags/battle.py +++ b/posts/templatetags/battle.py @@ -3,7 +3,6 @@ register = template.Library() - battle_stats_template = loader.get_template("posts/widgets/battle_stats.html") @@ -20,6 +19,7 @@ total_votes_a =...
{"golden_diff": "diff --git a/posts/templatetags/battle.py b/posts/templatetags/battle.py\n--- a/posts/templatetags/battle.py\n+++ b/posts/templatetags/battle.py\n@@ -3,7 +3,6 @@\n \n register = template.Library()\n \n-\n battle_stats_template = loader.get_template(\"posts/widgets/battle_stats.html\")\n \n \n@@ -20,6 +...
767
508
gh_patches_debug_2773
rasdani/github-patches
git_diff
Netflix__lemur-3166
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- DNS Providers list doesn't show type In the DNS Providers list, there is a column for the provider type, but it's always empty. Looking at the code, and the API requests, the issue seems to be with the dn...
diff --git a/lemur/dns_providers/schemas.py b/lemur/dns_providers/schemas.py --- a/lemur/dns_providers/schemas.py +++ b/lemur/dns_providers/schemas.py @@ -8,7 +8,7 @@ __envelope__ = False id = fields.Integer() name = fields.String() - providerType = fields.String() + provider_type = fields.String()...
{"golden_diff": "diff --git a/lemur/dns_providers/schemas.py b/lemur/dns_providers/schemas.py\n--- a/lemur/dns_providers/schemas.py\n+++ b/lemur/dns_providers/schemas.py\n@@ -8,7 +8,7 @@\n __envelope__ = False\n id = fields.Integer()\n name = fields.String()\n- providerType = fields.String()\n+ provid...
641
117
gh_patches_debug_26623
rasdani/github-patches
git_diff
e-valuation__EvaP-1291
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Django 2.1 upgrade https://docs.djangoproject.com/en/2.1/releases/2.1/ There is a guide for upgrading: https://docs.djangoproject.com/en/2.1/howto/upgrade-version/ Basically * Read the release notes *...
diff --git a/evap/evaluation/migrations/0062_replace_textanswer_id_with_uuid.py b/evap/evaluation/migrations/0062_replace_textanswer_id_with_uuid.py --- a/evap/evaluation/migrations/0062_replace_textanswer_id_with_uuid.py +++ b/evap/evaluation/migrations/0062_replace_textanswer_id_with_uuid.py @@ -33,13 +33,12 @@ ...
{"golden_diff": "diff --git a/evap/evaluation/migrations/0062_replace_textanswer_id_with_uuid.py b/evap/evaluation/migrations/0062_replace_textanswer_id_with_uuid.py\n--- a/evap/evaluation/migrations/0062_replace_textanswer_id_with_uuid.py\n+++ b/evap/evaluation/migrations/0062_replace_textanswer_id_with_uuid.py\n@@ -3...
968
398
gh_patches_debug_2234
rasdani/github-patches
git_diff
redis__redis-py-2674
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Canceling async Redis command leaves connection open, in unsafe state for future commands **Version**: 4.5.3 **Platform**: Python 3.8 on Ubuntu / Generic **Description**: Canceling async Redis comman...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -8,7 +8,7 @@ long_description_content_type="text/markdown", keywords=["Redis", "key-value store", "database"], license="MIT", - version="4.5.3", + version="4.5.4", packages=find_packages( include=[ "redis",...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -8,7 +8,7 @@\n long_description_content_type=\"text/markdown\",\n keywords=[\"Redis\", \"key-value store\", \"database\"],\n license=\"MIT\",\n- version=\"4.5.3\",\n+ version=\"4.5.4\",\n packages=find_packages(\...
1,644
90
gh_patches_debug_3335
rasdani/github-patches
git_diff
mkdocs__mkdocs-413
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- `mkdocs new` will overwrite an existing index.md file without warning. If you run the command: `mkdocs new /path/to/dir` and `/path/to/dir/docs/index.md` already exists it will be replaced with out placeholde...
diff --git a/mkdocs/new.py b/mkdocs/new.py --- a/mkdocs/new.py +++ b/mkdocs/new.py @@ -45,6 +45,9 @@ print('Writing config file: %s' % config_path) open(config_path, 'w').write(config_text) + if os.path.exists(index_path): + return + print('Writing initial docs: %s' % index_path) if not ...
{"golden_diff": "diff --git a/mkdocs/new.py b/mkdocs/new.py\n--- a/mkdocs/new.py\n+++ b/mkdocs/new.py\n@@ -45,6 +45,9 @@\n print('Writing config file: %s' % config_path)\n open(config_path, 'w').write(config_text)\n \n+ if os.path.exists(index_path):\n+ return\n+\n print('Writing initial docs: %s'...
763
114
gh_patches_debug_25234
rasdani/github-patches
git_diff
cupy__cupy-1947
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- `cupy.allclose` does not support comparison of complex-number arrays As title. The reason is that in this line of the ufunc helper https://github.com/cupy/cupy/blob/bb99716ffee178368ec71c875ace0553053cadc2/...
diff --git a/cupy/logic/comparison.py b/cupy/logic/comparison.py --- a/cupy/logic/comparison.py +++ b/cupy/logic/comparison.py @@ -1,3 +1,6 @@ +import numpy + +import cupy from cupy import core @@ -16,6 +19,24 @@ ''' ) +# Note that in cupy/core/include/cupy/complex.cuh, we already got isfinite and +# isnan...
{"golden_diff": "diff --git a/cupy/logic/comparison.py b/cupy/logic/comparison.py\n--- a/cupy/logic/comparison.py\n+++ b/cupy/logic/comparison.py\n@@ -1,3 +1,6 @@\n+import numpy\n+\n+import cupy\n from cupy import core\n \n \n@@ -16,6 +19,24 @@\n '''\n )\n \n+# Note that in cupy/core/include/cupy/complex.cuh, we al...
1,309
484
gh_patches_debug_5142
rasdani/github-patches
git_diff
microsoft__qlib-1246
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Misleading Error "Please install necessary libs for CatBoostModel." ## 🐛 Bug Description Qlib does not require the installation of packages like `CatBoostModel` But the output looks a little misleading...
diff --git a/qlib/contrib/model/__init__.py b/qlib/contrib/model/__init__.py --- a/qlib/contrib/model/__init__.py +++ b/qlib/contrib/model/__init__.py @@ -4,7 +4,7 @@ from .catboost_model import CatBoostModel except ModuleNotFoundError: CatBoostModel = None - print("Please install necessary libs for CatBo...
{"golden_diff": "diff --git a/qlib/contrib/model/__init__.py b/qlib/contrib/model/__init__.py\n--- a/qlib/contrib/model/__init__.py\n+++ b/qlib/contrib/model/__init__.py\n@@ -4,7 +4,7 @@\n from .catboost_model import CatBoostModel\n except ModuleNotFoundError:\n CatBoostModel = None\n- print(\"Please install...
934
147
gh_patches_debug_41207
rasdani/github-patches
git_diff
svthalia__concrexit-2399
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Add sales order API ### Describe the solution you'd like - An api endpoint `api/v2/sales/order/<uuid>/` that returns the order information that is shown on the website when you pay for the url from a qr code...
diff --git a/website/sales/api/v2/urls.py b/website/sales/api/v2/urls.py --- a/website/sales/api/v2/urls.py +++ b/website/sales/api/v2/urls.py @@ -1,6 +1,7 @@ from django.urls import path from sales.api.v2.views import ( + OrderClaimView, UserShiftListView, UserShiftDetailView, UserOrderListView, ...
{"golden_diff": "diff --git a/website/sales/api/v2/urls.py b/website/sales/api/v2/urls.py\n--- a/website/sales/api/v2/urls.py\n+++ b/website/sales/api/v2/urls.py\n@@ -1,6 +1,7 @@\n from django.urls import path\n \n from sales.api.v2.views import (\n+ OrderClaimView,\n UserShiftListView,\n UserShiftDetailView...
1,681
844
gh_patches_debug_37530
rasdani/github-patches
git_diff
keras-team__autokeras-286
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Add a class to generate an MLP <!--- Please label your issue with `new_task_module`. --> ### Suggested Name <!--- --> MlpGenerator ### Task Description <!--- A clear and concise description of th...
diff --git a/autokeras/constant.py b/autokeras/constant.py --- a/autokeras/constant.py +++ b/autokeras/constant.py @@ -18,9 +18,12 @@ DENSE_DROPOUT_RATE = 0.5 CONV_DROPOUT_RATE = 0.25 + MLP_DROPOUT_RATE = 0.25 CONV_BLOCK_DISTANCE = 2 DENSE_BLOCK_DISTANCE = 1 MODEL_LEN = 3 + MLP_MODEL_LE...
{"golden_diff": "diff --git a/autokeras/constant.py b/autokeras/constant.py\n--- a/autokeras/constant.py\n+++ b/autokeras/constant.py\n@@ -18,9 +18,12 @@\n \n DENSE_DROPOUT_RATE = 0.5\n CONV_DROPOUT_RATE = 0.25\n+ MLP_DROPOUT_RATE = 0.25\n CONV_BLOCK_DISTANCE = 2\n DENSE_BLOCK_DISTANCE = 1\n MODE...
1,322
766
gh_patches_debug_9892
rasdani/github-patches
git_diff
docker__docker-py-2795
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- version requirements for cryptography should be consistent Hi It seems that version requirements for cryptography in setup.py and requirements.txt are not consistent In setup.py, it is cryptography>=1.3.4 ...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -27,7 +27,7 @@ # https://github.com/pypa/pip/issues/4391). Once that's fixed, instead of # installing the extra dependencies, install the following instead: # 'requests[security] >= 2.5.2, != 2.11.0, != 2.12.2' - 'tls': ['pyOpenSSL>=17...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -27,7 +27,7 @@\n # https://github.com/pypa/pip/issues/4391). Once that's fixed, instead of\n # installing the extra dependencies, install the following instead:\n # 'requests[security] >= 2.5.2, != 2.11.0, != 2.12.2'\n- ...
1,260
205
gh_patches_debug_3267
rasdani/github-patches
git_diff
cupy__cupy-4711
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Python 3.9 support - CI - cupy-release-tools --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --- BEGIN FILES --- Path: `setup.py` Con...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -133,6 +133,7 @@ Programming Language :: Python :: 3.6 Programming Language :: Python :: 3.7 Programming Language :: Python :: 3.8 +Programming Language :: Python :: 3.9 Programming Language :: Python :: 3 :: Only Programming Language :: Cython Top...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -133,6 +133,7 @@\n Programming Language :: Python :: 3.6\n Programming Language :: Python :: 3.7\n Programming Language :: Python :: 3.8\n+Programming Language :: Python :: 3.9\n Programming Language :: Python :: 3 :: Only\n Programmi...
1,944
96
gh_patches_debug_56080
rasdani/github-patches
git_diff
hpcaitech__ColossalAI-3107
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [BUG]: typing miss of kwargs ### 🐛 Describe the bug When I tried to train prompts with opt model, the following error was occurred. ``` Traceback (most recent call last): File "/home/xxx/workspace/Co...
diff --git a/applications/ChatGPT/chatgpt/models/opt/opt_critic.py b/applications/ChatGPT/chatgpt/models/opt/opt_critic.py --- a/applications/ChatGPT/chatgpt/models/opt/opt_critic.py +++ b/applications/ChatGPT/chatgpt/models/opt/opt_critic.py @@ -25,7 +25,7 @@ checkpoint: bool = False, ...
{"golden_diff": "diff --git a/applications/ChatGPT/chatgpt/models/opt/opt_critic.py b/applications/ChatGPT/chatgpt/models/opt/opt_critic.py\n--- a/applications/ChatGPT/chatgpt/models/opt/opt_critic.py\n+++ b/applications/ChatGPT/chatgpt/models/opt/opt_critic.py\n@@ -25,7 +25,7 @@\n checkpoint: bool = F...
864
154
gh_patches_debug_9664
rasdani/github-patches
git_diff
conda__conda-build-2271
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Set target in package section [feature request] ## Problem Currently the only way to change the target platform is using the built in way of handling variants. This involves including an additional file `c...
diff --git a/conda_build/tarcheck.py b/conda_build/tarcheck.py --- a/conda_build/tarcheck.py +++ b/conda_build/tarcheck.py @@ -82,7 +82,7 @@ def correct_subdir(self): info = json.loads(self.t.extractfile('info/index.json').read().decode('utf-8')) - assert info['subdir'] in [self.config.host_subdi...
{"golden_diff": "diff --git a/conda_build/tarcheck.py b/conda_build/tarcheck.py\n--- a/conda_build/tarcheck.py\n+++ b/conda_build/tarcheck.py\n@@ -82,7 +82,7 @@\n \n def correct_subdir(self):\n info = json.loads(self.t.extractfile('info/index.json').read().decode('utf-8'))\n- assert info['subdir'] in...
1,480
167
gh_patches_debug_21519
rasdani/github-patches
git_diff
google__flax-596
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- QoL: better print for FrozenDict The best way I'm aware of to get an overview of model shape is via `jax.tree_map(jnp.shape, params)`. FrozenDicts have no concept of pretty printing the way dicts do, so large...
diff --git a/flax/core/frozen_dict.py b/flax/core/frozen_dict.py --- a/flax/core/frozen_dict.py +++ b/flax/core/frozen_dict.py @@ -24,6 +24,14 @@ V = TypeVar('V') +def _indent(x, num_spaces): + indent_str = ' ' * num_spaces + lines = x.split('\n') + assert lines[-1] == '' + # skip the final line because it's e...
{"golden_diff": "diff --git a/flax/core/frozen_dict.py b/flax/core/frozen_dict.py\n--- a/flax/core/frozen_dict.py\n+++ b/flax/core/frozen_dict.py\n@@ -24,6 +24,14 @@\n V = TypeVar('V')\n \n \n+def _indent(x, num_spaces):\n+ indent_str = ' ' * num_spaces\n+ lines = x.split('\\n')\n+ assert lines[-1] == ''\n+ # skip ...
1,746
361
gh_patches_debug_11172
rasdani/github-patches
git_diff
RedHatInsights__insights-core-2464
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Enhance parser "satellite_installer_configurations" As a default, the file "/etc/foreman-installer/custom-hiera.yaml" is empty, it means customers haven't done any tuning, it shouldn't be skipped. --- END IS...
diff --git a/insights/parsers/satellite_installer_configurations.py b/insights/parsers/satellite_installer_configurations.py --- a/insights/parsers/satellite_installer_configurations.py +++ b/insights/parsers/satellite_installer_configurations.py @@ -12,6 +12,7 @@ from insights import parser, YAMLParser from insigh...
{"golden_diff": "diff --git a/insights/parsers/satellite_installer_configurations.py b/insights/parsers/satellite_installer_configurations.py\n--- a/insights/parsers/satellite_installer_configurations.py\n+++ b/insights/parsers/satellite_installer_configurations.py\n@@ -12,6 +12,7 @@\n \n from insights import parser, Y...
529
190
gh_patches_debug_14651
rasdani/github-patches
git_diff
pfnet__pytorch-pfn-extras-763
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Adding pytest in an MPI environment There are some functions that run in a distributed environment that have not been fully verified, so some pytests will be run in MPI to verify them. https://github.com/p...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -16,27 +16,6 @@ license="MIT License", install_requires=["numpy", "packaging", "torch", "typing-extensions>=3.10"], extras_require={ - "test": [ - "pytest", - "onnxruntime", - "torchvision", - ...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -16,27 +16,6 @@\n license=\"MIT License\",\n install_requires=[\"numpy\", \"packaging\", \"torch\", \"typing-extensions>=3.10\"],\n extras_require={\n- \"test\": [\n- \"pytest\",\n- \"onnxrunti...
778
243
gh_patches_debug_21746
rasdani/github-patches
git_diff
explosion__spaCy-3389
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [feature request] Factory default for extension attributes ## Feature description As usual with Python, mutable defaults are a big no-no for extension attributes, since they are shared by all instances, whic...
diff --git a/spacy/tokens/underscore.py b/spacy/tokens/underscore.py --- a/spacy/tokens/underscore.py +++ b/spacy/tokens/underscore.py @@ -2,11 +2,13 @@ from __future__ import unicode_literals import functools +import copy from ..errors import Errors class Underscore(object): + mutable_types = (dict, lis...
{"golden_diff": "diff --git a/spacy/tokens/underscore.py b/spacy/tokens/underscore.py\n--- a/spacy/tokens/underscore.py\n+++ b/spacy/tokens/underscore.py\n@@ -2,11 +2,13 @@\n from __future__ import unicode_literals\n \n import functools\n+import copy\n \n from ..errors import Errors\n \n \n class Underscore(object):\n+...
1,527
264
gh_patches_debug_33005
rasdani/github-patches
git_diff
weecology__retriever-378
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- v1.6.0 will break if download scripts are added to version.txt in master We have now done this twice (see #180 and #199). In v1.6.0 `__init__.py` line 16: `MASTER = True`. This results in the retriever alway...
diff --git a/scripts/MammalSuperTree.py b/scripts/MammalSuperTree.py --- a/scripts/MammalSuperTree.py +++ b/scripts/MammalSuperTree.py @@ -1,9 +1,22 @@ #retriever -from retriever.lib.templates import DownloadOnlyTemplate - -SCRIPT = DownloadOnlyTemplate(name="Mammal Super Tree", - shortnam...
{"golden_diff": "diff --git a/scripts/MammalSuperTree.py b/scripts/MammalSuperTree.py\n--- a/scripts/MammalSuperTree.py\n+++ b/scripts/MammalSuperTree.py\n@@ -1,9 +1,22 @@\n #retriever\n-from retriever.lib.templates import DownloadOnlyTemplate\n-\n-SCRIPT = DownloadOnlyTemplate(name=\"Mammal Super Tree\",\n- ...
775
959
gh_patches_debug_5038
rasdani/github-patches
git_diff
scikit-hep__pyhf-1105
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- pyhf contrib download fails gracelessly with invalid URL # Description calling `pyhf contrib download` (just to see what it does) fails pretty violently. hould we make itt a bit nicer @matthewfeickert ? ...
diff --git a/src/pyhf/cli/contrib.py b/src/pyhf/cli/contrib.py --- a/src/pyhf/cli/contrib.py +++ b/src/pyhf/cli/contrib.py @@ -25,8 +25,8 @@ @cli.command() -@click.argument("archive-url", default="-") -@click.argument("output-directory", default="-") +@click.argument("archive-url") +@click.argument("output-directo...
{"golden_diff": "diff --git a/src/pyhf/cli/contrib.py b/src/pyhf/cli/contrib.py\n--- a/src/pyhf/cli/contrib.py\n+++ b/src/pyhf/cli/contrib.py\n@@ -25,8 +25,8 @@\n \n \n @cli.command()\n-@click.argument(\"archive-url\", default=\"-\")\n-@click.argument(\"output-directory\", default=\"-\")\n+@click.argument(\"archive-url...
1,447
139
gh_patches_debug_11587
rasdani/github-patches
git_diff
saulpw__visidata-967
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- no loader for url scheme: postgresql **Small description** When attempting to start visidata with ``` vd postgresql:///localdb ``` it fails with ``` Error: no loader for url scheme: postgresql ``` ...
diff --git a/visidata/loaders/postgres.py b/visidata/loaders/postgres.py --- a/visidata/loaders/postgres.py +++ b/visidata/loaders/postgres.py @@ -1,6 +1,6 @@ from visidata import * -__all__ = ['openurl_postgres', 'openurl_rds', 'PgTable', 'PgTablesSheet'] +__all__ = ['openurl_postgres', 'openurl_postgresql', 'openu...
{"golden_diff": "diff --git a/visidata/loaders/postgres.py b/visidata/loaders/postgres.py\n--- a/visidata/loaders/postgres.py\n+++ b/visidata/loaders/postgres.py\n@@ -1,6 +1,6 @@\n from visidata import *\n \n-__all__ = ['openurl_postgres', 'openurl_rds', 'PgTable', 'PgTablesSheet']\n+__all__ = ['openurl_postgres', 'ope...
1,578
196
gh_patches_debug_37490
rasdani/github-patches
git_diff
getsentry__sentry-62640
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Convert digest notifications to use block kit Convert the `DigestNotificationMessageBuilder` (code [here](https://github.com/getsentry/sentry/blob/master/src/sentry/integrations/slack/message_builder/notifica...
diff --git a/src/sentry/integrations/slack/message_builder/notifications/digest.py b/src/sentry/integrations/slack/message_builder/notifications/digest.py --- a/src/sentry/integrations/slack/message_builder/notifications/digest.py +++ b/src/sentry/integrations/slack/message_builder/notifications/digest.py @@ -2,9 +2,10...
{"golden_diff": "diff --git a/src/sentry/integrations/slack/message_builder/notifications/digest.py b/src/sentry/integrations/slack/message_builder/notifications/digest.py\n--- a/src/sentry/integrations/slack/message_builder/notifications/digest.py\n+++ b/src/sentry/integrations/slack/message_builder/notifications/dige...
688
547
gh_patches_debug_14648
rasdani/github-patches
git_diff
Kinto__kinto-1003
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- GET on /v1/admin returns 404 The expected address for built-in admin plugin is `/v1/admin/`. But if you forget the trailing slash and type `/v1/admin` you get a 404. I think it would be better to raise a 307....
diff --git a/kinto/plugins/admin/__init__.py b/kinto/plugins/admin/__init__.py --- a/kinto/plugins/admin/__init__.py +++ b/kinto/plugins/admin/__init__.py @@ -1,4 +1,5 @@ from pyramid.static import static_view +from pyramid.httpexceptions import HTTPTemporaryRedirect def includeme(config): @@ -15,3 +16,10 @@ ...
{"golden_diff": "diff --git a/kinto/plugins/admin/__init__.py b/kinto/plugins/admin/__init__.py\n--- a/kinto/plugins/admin/__init__.py\n+++ b/kinto/plugins/admin/__init__.py\n@@ -1,4 +1,5 @@\n from pyramid.static import static_view\n+from pyramid.httpexceptions import HTTPTemporaryRedirect\n \n \n def includeme(config)...
678
198
gh_patches_debug_61588
rasdani/github-patches
git_diff
scikit-image__scikit-image-1660
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Document negative `sigma` values in `filters.gaussian_filter` are clipped to zero. Negative sigma values have no effect; they are clipped to zero. This should be documented. --- END ISSUE --- Below are som...
diff --git a/skimage/filters/_gaussian.py b/skimage/filters/_gaussian.py --- a/skimage/filters/_gaussian.py +++ b/skimage/filters/_gaussian.py @@ -93,6 +93,8 @@ "3D image with last dimension of length 3.") warnings.warn(RuntimeWarning(msg)) multichannel = True + if np.any(np.asarray...
{"golden_diff": "diff --git a/skimage/filters/_gaussian.py b/skimage/filters/_gaussian.py\n--- a/skimage/filters/_gaussian.py\n+++ b/skimage/filters/_gaussian.py\n@@ -93,6 +93,8 @@\n \"3D image with last dimension of length 3.\")\n warnings.warn(RuntimeWarning(msg))\n multichannel = True\...
1,717
140
gh_patches_debug_27760
rasdani/github-patches
git_diff
microsoft__playwright-python-191
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Internal docs are published on the gh pages instead of the official API We should remove everything that is not relevant to the end user! Docs: https://microsoft.github.io/playwright-python/sync_api.html --...
diff --git a/playwright/__init__.py b/playwright/__init__.py --- a/playwright/__init__.py +++ b/playwright/__init__.py @@ -11,6 +11,13 @@ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. +...
{"golden_diff": "diff --git a/playwright/__init__.py b/playwright/__init__.py\n--- a/playwright/__init__.py\n+++ b/playwright/__init__.py\n@@ -11,6 +11,13 @@\n # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n # See the License for the specific language governing permissions and\n # limitatio...
602
467
gh_patches_debug_6610
rasdani/github-patches
git_diff
alltheplaces__alltheplaces-3338
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Spider scooters_coffee is broken During the global build at 2021-06-23-14-42-18, spider **scooters_coffee** failed with **324 features** and **1 errors**. Here's [the log](https://data.alltheplaces.xyz/runs/...
diff --git a/locations/spiders/scooters_coffee.py b/locations/spiders/scooters_coffee.py --- a/locations/spiders/scooters_coffee.py +++ b/locations/spiders/scooters_coffee.py @@ -35,6 +35,7 @@ if open_close == 'C': continue else: + open_close = open_close.replac...
{"golden_diff": "diff --git a/locations/spiders/scooters_coffee.py b/locations/spiders/scooters_coffee.py\n--- a/locations/spiders/scooters_coffee.py\n+++ b/locations/spiders/scooters_coffee.py\n@@ -35,6 +35,7 @@\n if open_close == 'C':\n continue\n else:\n+ open_c...
1,199
132
gh_patches_debug_5979
rasdani/github-patches
git_diff
getnikola__nikola-1994
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- nikola no longer has all-nocdn.* I started using `nikola` today for a gallery. The generated pages make reference to `all-nocdn.css` and `all-nocdn.js`, but they're not (longer?) part of `nikola`'s code: ```...
diff --git a/nikola/plugins/task/bundles.py b/nikola/plugins/task/bundles.py --- a/nikola/plugins/task/bundles.py +++ b/nikola/plugins/task/bundles.py @@ -52,6 +52,7 @@ utils.req_missing(['webassets'], 'USE_BUNDLES', optional=True) self.logger.warn('Setting USE_BUNDLES to False.') ...
{"golden_diff": "diff --git a/nikola/plugins/task/bundles.py b/nikola/plugins/task/bundles.py\n--- a/nikola/plugins/task/bundles.py\n+++ b/nikola/plugins/task/bundles.py\n@@ -52,6 +52,7 @@\n utils.req_missing(['webassets'], 'USE_BUNDLES', optional=True)\n self.logger.warn('Setting USE_BUNDLES to...
2,043
131
gh_patches_debug_40591
rasdani/github-patches
git_diff
hpcaitech__ColossalAI-4802
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [tensor] fix some unittests [tensor] fix some unittests [tensor] fix some unittests --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs....
diff --git a/colossalai/inference/tensor_parallel/policies/llama.py b/colossalai/inference/tensor_parallel/policies/llama.py --- a/colossalai/inference/tensor_parallel/policies/llama.py +++ b/colossalai/inference/tensor_parallel/policies/llama.py @@ -3,8 +3,8 @@ import torch from transformers.models.llama.modeling_ll...
{"golden_diff": "diff --git a/colossalai/inference/tensor_parallel/policies/llama.py b/colossalai/inference/tensor_parallel/policies/llama.py\n--- a/colossalai/inference/tensor_parallel/policies/llama.py\n+++ b/colossalai/inference/tensor_parallel/policies/llama.py\n@@ -3,8 +3,8 @@\n import torch\n from transformers.mo...
1,546
548
gh_patches_debug_47928
rasdani/github-patches
git_diff
uccser__cs-unplugged-862
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Only prepend www for production website It should not be used for development website. --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs....
diff --git a/csunplugged/config/settings/production.py b/csunplugged/config/settings/production.py --- a/csunplugged/config/settings/production.py +++ b/csunplugged/config/settings/production.py @@ -23,7 +23,10 @@ # URL Configuration # ------------------------------------------------------------------------------ -...
{"golden_diff": "diff --git a/csunplugged/config/settings/production.py b/csunplugged/config/settings/production.py\n--- a/csunplugged/config/settings/production.py\n+++ b/csunplugged/config/settings/production.py\n@@ -23,7 +23,10 @@\n \n # URL Configuration\n # ---------------------------------------------------------...
1,026
129
gh_patches_debug_6831
rasdani/github-patches
git_diff
wagtail__wagtail-6104
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Typo in wagtail/core/middleware.py warning The second line of the warning in `wagtail/core/middleware.py` should read: ` 'Please update your code to use Site.find_for_request(request) in place of reques...
diff --git a/wagtail/core/middleware.py b/wagtail/core/middleware.py --- a/wagtail/core/middleware.py +++ b/wagtail/core/middleware.py @@ -7,7 +7,7 @@ warnings.warn( 'wagtail.core.middleware.SiteMiddleware and the use of request.site is deprecated. ' - 'Please update your code to use Site.get_for_request(req...
{"golden_diff": "diff --git a/wagtail/core/middleware.py b/wagtail/core/middleware.py\n--- a/wagtail/core/middleware.py\n+++ b/wagtail/core/middleware.py\n@@ -7,7 +7,7 @@\n \n warnings.warn(\n 'wagtail.core.middleware.SiteMiddleware and the use of request.site is deprecated. '\n- 'Please update your code to use ...
562
145
gh_patches_debug_15848
rasdani/github-patches
git_diff
mampfes__hacs_waste_collection_schedule-1588
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [Bug]: date time issue ### I Have A Problem With: The integration in general ### What's Your Problem Used to work. No change in cfg. At some point, after an upgrade… Integration fails while starting. See...
diff --git a/custom_components/waste_collection_schedule/waste_collection_schedule/source/stavanger_no.py b/custom_components/waste_collection_schedule/waste_collection_schedule/source/stavanger_no.py --- a/custom_components/waste_collection_schedule/waste_collection_schedule/source/stavanger_no.py +++ b/custom_compone...
{"golden_diff": "diff --git a/custom_components/waste_collection_schedule/waste_collection_schedule/source/stavanger_no.py b/custom_components/waste_collection_schedule/waste_collection_schedule/source/stavanger_no.py\n--- a/custom_components/waste_collection_schedule/waste_collection_schedule/source/stavanger_no.py\n+...
1,601
230
gh_patches_debug_30563
rasdani/github-patches
git_diff
scikit-hep__pyhf-1176
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Add axis labels to pyhf.contrib.viz.brazil.plot_results # Description We know that the axis labels for [`pyhf.contrib.viz.brazil.plot_results`](https://github.com/scikit-hep/pyhf/blob/28fdfe95a3a4846ba70a9...
diff --git a/src/pyhf/contrib/viz/brazil.py b/src/pyhf/contrib/viz/brazil.py --- a/src/pyhf/contrib/viz/brazil.py +++ b/src/pyhf/contrib/viz/brazil.py @@ -3,7 +3,37 @@ def plot_results(ax, mutests, tests, test_size=0.05): - """Plot a series of hypothesis tests for various POI values.""" + """ + Plot a ser...
{"golden_diff": "diff --git a/src/pyhf/contrib/viz/brazil.py b/src/pyhf/contrib/viz/brazil.py\n--- a/src/pyhf/contrib/viz/brazil.py\n+++ b/src/pyhf/contrib/viz/brazil.py\n@@ -3,7 +3,37 @@\n \n \n def plot_results(ax, mutests, tests, test_size=0.05):\n- \"\"\"Plot a series of hypothesis tests for various POI values.\...
659
618
gh_patches_debug_64571
rasdani/github-patches
git_diff
cocotb__cocotb-1145
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Packaging: Add python_requires to manifest Define our Python version requirements in our package manifest, as described here: https://packaging.python.org/guides/distributing-packages-using-setuptools/#python...
diff --git a/setup.py b/setup.py old mode 100644 new mode 100755 --- a/setup.py +++ b/setup.py @@ -55,6 +55,7 @@ author='Chris Higgs, Stuart Hodgson', author_email='cocotb@potentialventures.com', install_requires=[], + python_requires='>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*', packages...
{"golden_diff": "diff --git a/setup.py b/setup.py\nold mode 100644\nnew mode 100755\n--- a/setup.py\n+++ b/setup.py\n@@ -55,6 +55,7 @@\n author='Chris Higgs, Stuart Hodgson',\n author_email='cocotb@potentialventures.com',\n install_requires=[],\n+ python_requires='>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3....
1,111
145
gh_patches_debug_24079
rasdani/github-patches
git_diff
TheAlgorithms__Python-9005
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- improvement to insertion_sort algorithm ### Feature description I was about to make a PR to improve the implementation of [insertion_sort algorithm](https://github.com/TheAlgorithms/Python/blob/master/sort...
diff --git a/sorts/insertion_sort.py b/sorts/insertion_sort.py --- a/sorts/insertion_sort.py +++ b/sorts/insertion_sort.py @@ -13,8 +13,19 @@ python3 insertion_sort.py """ +from collections.abc import MutableSequence +from typing import Any, Protocol, TypeVar -def insertion_sort(collection: list) -> list: + +clas...
{"golden_diff": "diff --git a/sorts/insertion_sort.py b/sorts/insertion_sort.py\n--- a/sorts/insertion_sort.py\n+++ b/sorts/insertion_sort.py\n@@ -13,8 +13,19 @@\n python3 insertion_sort.py\n \"\"\"\n \n+from collections.abc import MutableSequence\n+from typing import Any, Protocol, TypeVar\n \n-def insertion_sort(coll...
1,427
353
gh_patches_debug_893
rasdani/github-patches
git_diff
Lightning-Universe__lightning-flash-665
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- ImageEmbedder default behavior is not a flattened output ## 🐛 Bug I discovered this issue while testing PR #655. If you run the [Image Embedding README example code](https://github.com/PyTorchLightning/li...
diff --git a/flash_examples/integrations/fiftyone/image_embedding.py b/flash_examples/integrations/fiftyone/image_embedding.py --- a/flash_examples/integrations/fiftyone/image_embedding.py +++ b/flash_examples/integrations/fiftyone/image_embedding.py @@ -28,7 +28,7 @@ ) # 3 Load model -embedder = ImageEmbedder(back...
{"golden_diff": "diff --git a/flash_examples/integrations/fiftyone/image_embedding.py b/flash_examples/integrations/fiftyone/image_embedding.py\n--- a/flash_examples/integrations/fiftyone/image_embedding.py\n+++ b/flash_examples/integrations/fiftyone/image_embedding.py\n@@ -28,7 +28,7 @@\n )\n \n # 3 Load model\n-embed...
1,537
134
gh_patches_debug_15994
rasdani/github-patches
git_diff
falconry__falcon-1588
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- WebDAV methods not supported Falcon defines supported HTTP methods in `falcon/constants.py`: supported are "usual" `HTTP_METHODS` and, in addition to that, `WEBDAV_METHODS`. However, only WebDAV versioning ex...
diff --git a/falcon/constants.py b/falcon/constants.py --- a/falcon/constants.py +++ b/falcon/constants.py @@ -13,12 +13,19 @@ 'TRACE', ] -# RFC 3253 methods +# RFC 2518 and 4918 methods WEBDAV_METHODS = [ 'CHECKIN', 'CHECKOUT', + 'COPY', + 'LOCK', + 'MKCOL', + 'MOVE', + 'PROPFIND', + ...
{"golden_diff": "diff --git a/falcon/constants.py b/falcon/constants.py\n--- a/falcon/constants.py\n+++ b/falcon/constants.py\n@@ -13,12 +13,19 @@\n 'TRACE',\n ]\n \n-# RFC 3253 methods\n+# RFC 2518 and 4918 methods\n WEBDAV_METHODS = [\n 'CHECKIN',\n 'CHECKOUT',\n+ 'COPY',\n+ 'LOCK',\n+ 'MKCOL',\n...
1,294
226
gh_patches_debug_1925
rasdani/github-patches
git_diff
mathesar-foundation__mathesar-673
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- IndexError when deleting a column ## Description <!-- A clear and concise description of what the bug is. --> An indexError occurs when deleting a column through the API. Most of the time the error occurs w...
diff --git a/db/columns/operations/select.py b/db/columns/operations/select.py --- a/db/columns/operations/select.py +++ b/db/columns/operations/select.py @@ -22,6 +22,7 @@ sel = ( select(func.count()) .where(and_( + pg_attribute.c.attrelid == table_oid, pg_attribute.c.att...
{"golden_diff": "diff --git a/db/columns/operations/select.py b/db/columns/operations/select.py\n--- a/db/columns/operations/select.py\n+++ b/db/columns/operations/select.py\n@@ -22,6 +22,7 @@\n sel = (\n select(func.count())\n .where(and_(\n+ pg_attribute.c.attrelid == table_oid,\n ...
1,470
103
gh_patches_debug_59246
rasdani/github-patches
git_diff
projectmesa__mesa-451
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Datacollector fix Simplify the `DataCollector` API by allowing the user-provided model- and agent-level reporters to be the names of attributes, in addition to methods. e.g. instead of needing to write ```...
diff --git a/mesa/__init__.py b/mesa/__init__.py --- a/mesa/__init__.py +++ b/mesa/__init__.py @@ -14,6 +14,6 @@ __all__ = ["Model", "Agent"] __title__ = 'mesa' -__version__ = '0.8.2' +__version__ = '0.8.3' __license__ = 'Apache 2.0' __copyright__ = 'Copyright %s Project Mesa Team' % datetime.date.today().year
{"golden_diff": "diff --git a/mesa/__init__.py b/mesa/__init__.py\n--- a/mesa/__init__.py\n+++ b/mesa/__init__.py\n@@ -14,6 +14,6 @@\n __all__ = [\"Model\", \"Agent\"]\n \n __title__ = 'mesa'\n-__version__ = '0.8.2'\n+__version__ = '0.8.3'\n __license__ = 'Apache 2.0'\n __copyright__ = 'Copyright %s Project Mesa Team' ...
490
121
gh_patches_debug_31990
rasdani/github-patches
git_diff
cloudtools__troposphere-1811
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Add AWS::Elasticsearch::Domain DomainEndpointOptions Cloudformation now allows you to specify additional options for the domain endpoint, such as whether to require HTTPS for all traffic, with an Elasticseac...
diff --git a/troposphere/elasticsearch.py b/troposphere/elasticsearch.py --- a/troposphere/elasticsearch.py +++ b/troposphere/elasticsearch.py @@ -8,6 +8,10 @@ from .validators import boolean, integer, integer_range, positive_integer VALID_VOLUME_TYPES = ('standard', 'gp2', 'io1') +VALID_TLS_SECURITY_POLICIES = ( +...
{"golden_diff": "diff --git a/troposphere/elasticsearch.py b/troposphere/elasticsearch.py\n--- a/troposphere/elasticsearch.py\n+++ b/troposphere/elasticsearch.py\n@@ -8,6 +8,10 @@\n from .validators import boolean, integer, integer_range, positive_integer\n \n VALID_VOLUME_TYPES = ('standard', 'gp2', 'io1')\n+VALID_TLS...
1,536
451
gh_patches_debug_12129
rasdani/github-patches
git_diff
mathesar-foundation__mathesar-1670
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Filters not applied when calculating count of items within group ## Reproduce 1. Go to the Library Management schema. 1. Load the Table Page for the Publications table. 1. Group by "Publication Year". 1. Obs...
diff --git a/db/transforms/operations/apply.py b/db/transforms/operations/apply.py --- a/db/transforms/operations/apply.py +++ b/db/transforms/operations/apply.py @@ -35,14 +35,14 @@ transforms = [] + if filter: + transforms.append(base.Filter(filter)) if duplicate_only: transforms.appe...
{"golden_diff": "diff --git a/db/transforms/operations/apply.py b/db/transforms/operations/apply.py\n--- a/db/transforms/operations/apply.py\n+++ b/db/transforms/operations/apply.py\n@@ -35,14 +35,14 @@\n \n transforms = []\n \n+ if filter:\n+ transforms.append(base.Filter(filter))\n if duplicate_only...
884
152
gh_patches_debug_1479
rasdani/github-patches
git_diff
fidals__shopelectro-870
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Add absolute urls to the canonical links. stb2 Необходимо поправить построение канонических ссылок на сайте Адрес в канонической ссылке должен быть обязательно абсолютный <link rel="canonical" href="https:/...
diff --git a/shopelectro/context_processors.py b/shopelectro/context_processors.py --- a/shopelectro/context_processors.py +++ b/shopelectro/context_processors.py @@ -11,6 +11,6 @@ return { 'shop': settings.SHOP, 'DEBUG': settings.DEBUG, - 'BASE_URL': settings.BASE_URL, + 'base_url'...
{"golden_diff": "diff --git a/shopelectro/context_processors.py b/shopelectro/context_processors.py\n--- a/shopelectro/context_processors.py\n+++ b/shopelectro/context_processors.py\n@@ -11,6 +11,6 @@\n return {\n 'shop': settings.SHOP,\n 'DEBUG': settings.DEBUG,\n- 'BASE_URL': settings.BASE_...
565
107
gh_patches_debug_16334
rasdani/github-patches
git_diff
falconry__falcon-741
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Refactor setup.py external module selection for Cython Reduce complexity and duplication of the external module selection for Cython in setup.py. At the time of this issue, this cruft was located in: https:...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -52,21 +52,15 @@ return module_names + package_names = ['falcon', 'falcon.util', 'falcon.routing'] ext_modules = [ - Extension('falcon.' + ext, [path.join('falcon', ext + '.py')]) - for ext in list_modules(path.join(MYD...
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -52,21 +52,15 @@\n \n return module_names\n \n+ package_names = ['falcon', 'falcon.util', 'falcon.routing']\n ext_modules = [\n- Extension('falcon.' + ext, [path.join('falcon', ext + '.py')])\n- for ext in...
1,516
291
gh_patches_debug_89
rasdani/github-patches
git_diff
encode__httpx-286
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- stop nox on first error During nox is running, if it gets an error, continues running. if we add this: `nox.options.stop_on_first_error = True`, we don't overlook check errors or others before PR. --- END IS...
diff --git a/noxfile.py b/noxfile.py --- a/noxfile.py +++ b/noxfile.py @@ -1,5 +1,7 @@ import nox +nox.options.stop_on_first_error = True + source_files = ("httpx", "tests", "setup.py", "noxfile.py")
{"golden_diff": "diff --git a/noxfile.py b/noxfile.py\n--- a/noxfile.py\n+++ b/noxfile.py\n@@ -1,5 +1,7 @@\n import nox\n \n+nox.options.stop_on_first_error = True\n+\n source_files = (\"httpx\", \"tests\", \"setup.py\", \"noxfile.py\")\n", "issue": "stop nox on first error\nDuring nox is running, if it gets an error, ...
709
72
gh_patches_debug_24283
rasdani/github-patches
git_diff
ESMCI__cime-260
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Remove ESMF from driver code --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --- BEGIN FILES --- Path: `utils/python/CIME/SystemTests...
diff --git a/utils/python/CIME/SystemTests/pfs.py b/utils/python/CIME/SystemTests/pfs.py --- a/utils/python/CIME/SystemTests/pfs.py +++ b/utils/python/CIME/SystemTests/pfs.py @@ -18,7 +18,7 @@ SystemTestsCommon.__init__(self, case) def run(self): - self._case_set_value("STOP_OPTION", "ndays") + ...
{"golden_diff": "diff --git a/utils/python/CIME/SystemTests/pfs.py b/utils/python/CIME/SystemTests/pfs.py\n--- a/utils/python/CIME/SystemTests/pfs.py\n+++ b/utils/python/CIME/SystemTests/pfs.py\n@@ -18,7 +18,7 @@\n SystemTestsCommon.__init__(self, case)\n \n def run(self):\n- self._case_set_value(\"S...
1,744
437
gh_patches_debug_14453
rasdani/github-patches
git_diff
interlegis__sapl-3226
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Erro encontrado quando a audiência não possui matéria ligada. <!--- Forneça um resumo geral da _issue_ no título acima --> Erro encontrado quando a audiência não possui matéria ligada. Derivado do ticket [27...
diff --git a/sapl/audiencia/views.py b/sapl/audiencia/views.py --- a/sapl/audiencia/views.py +++ b/sapl/audiencia/views.py @@ -38,8 +38,11 @@ coluna_materia = row[3] # se mudar a ordem de listagem mudar aqui if coluna_materia[0]: materia = audiencia_materia[row[0][...
{"golden_diff": "diff --git a/sapl/audiencia/views.py b/sapl/audiencia/views.py\n--- a/sapl/audiencia/views.py\n+++ b/sapl/audiencia/views.py\n@@ -38,8 +38,11 @@\n coluna_materia = row[3] # se mudar a ordem de listagem mudar aqui\n if coluna_materia[0]:\n materia = au...
1,588
196
gh_patches_debug_62155
rasdani/github-patches
git_diff
Parsl__parsl-597
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Make `GlobusScheme` inherit from `RepresentationMixin` Otherwise, the config printed in the log is not copy-and-pasteable: ``` storage_access=[<parsl.data_provider.scheme.GlobusScheme object at 0x...
diff --git a/parsl/data_provider/scheme.py b/parsl/data_provider/scheme.py --- a/parsl/data_provider/scheme.py +++ b/parsl/data_provider/scheme.py @@ -1,5 +1,7 @@ +from parsl.utils import RepresentationMixin -class GlobusScheme(object): + +class GlobusScheme(RepresentationMixin): """Specification for accessing d...
{"golden_diff": "diff --git a/parsl/data_provider/scheme.py b/parsl/data_provider/scheme.py\n--- a/parsl/data_provider/scheme.py\n+++ b/parsl/data_provider/scheme.py\n@@ -1,5 +1,7 @@\n+from parsl.utils import RepresentationMixin\n \n-class GlobusScheme(object):\n+\n+class GlobusScheme(RepresentationMixin):\n \"\"\"...
575
97
gh_patches_debug_5521
rasdani/github-patches
git_diff
aws__aws-cli-2510
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Version 1.11.17 and above breaks EC2 describe volumes with JSON input Related Issue: #1976 JSON File: ```json { "VolumeIds": [ "vol-<id>" ] } ``` Command: ``` aws ec2 describe-volumes ...
diff --git a/awscli/customizations/cliinputjson.py b/awscli/customizations/cliinputjson.py --- a/awscli/customizations/cliinputjson.py +++ b/awscli/customizations/cliinputjson.py @@ -50,7 +50,7 @@ def _register_argument_action(self): self._session.register( - 'calling-command', self.add_to_ca...
{"golden_diff": "diff --git a/awscli/customizations/cliinputjson.py b/awscli/customizations/cliinputjson.py\n--- a/awscli/customizations/cliinputjson.py\n+++ b/awscli/customizations/cliinputjson.py\n@@ -50,7 +50,7 @@\n \n def _register_argument_action(self):\n self._session.register(\n- 'calling-...
1,569
125
gh_patches_debug_62141
rasdani/github-patches
git_diff
searx__searx-1277
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- findx crashes ... with message on web page: findx (unexpected crash: string indices must be integers) --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files m...
diff --git a/searx/engines/findx.py b/searx/engines/findx.py --- a/searx/engines/findx.py +++ b/searx/engines/findx.py @@ -49,7 +49,7 @@ results_json = loads(extract_text(results_raw_json)) if len(results_json['web']['results']) > 0: - return _general_results(results_json['web']['results']) + ...
{"golden_diff": "diff --git a/searx/engines/findx.py b/searx/engines/findx.py\n--- a/searx/engines/findx.py\n+++ b/searx/engines/findx.py\n@@ -49,7 +49,7 @@\n results_json = loads(extract_text(results_raw_json))\n \n if len(results_json['web']['results']) > 0:\n- return _general_results(results_json['web...
1,266
145
gh_patches_debug_21871
rasdani/github-patches
git_diff
kubeflow__pipelines-4611
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- SDK - Drop support for Python 3.5 Python 3.5 has reached EoL: https://www.python.org/downloads/release/python-3510/#:~:text=Python%203.5%20will%20reach%20its,release%20of%20the%203.5%20series. We're going ...
diff --git a/sdk/python/setup.py b/sdk/python/setup.py --- a/sdk/python/setup.py +++ b/sdk/python/setup.py @@ -96,16 +96,16 @@ 'Intended Audience :: Science/Research', 'License :: OSI Approved :: Apache Software License', 'Programming Language :: Python :: 3', - 'Programming Language :...
{"golden_diff": "diff --git a/sdk/python/setup.py b/sdk/python/setup.py\n--- a/sdk/python/setup.py\n+++ b/sdk/python/setup.py\n@@ -96,16 +96,16 @@\n 'Intended Audience :: Science/Research',\n 'License :: OSI Approved :: Apache Software License',\n 'Programming Language :: Python :: 3',\n- ...
1,587
212
gh_patches_debug_2002
rasdani/github-patches
git_diff
uclapi__uclapi-4023
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [Feature Request] Add /authorize Oauth route **Is your feature request related to a problem? Please describe.** I have been attempting to use 'auth0-react' to implement Oauth with UCL API, however, this req...
diff --git a/backend/uclapi/oauth/urls.py b/backend/uclapi/oauth/urls.py --- a/backend/uclapi/oauth/urls.py +++ b/backend/uclapi/oauth/urls.py @@ -4,6 +4,7 @@ urlpatterns = [ url(r'authorise/$', views.authorise), + url(r'authorize/$', views.authorise), url(r'adcallback', views.adcallback), url(r'to...
{"golden_diff": "diff --git a/backend/uclapi/oauth/urls.py b/backend/uclapi/oauth/urls.py\n--- a/backend/uclapi/oauth/urls.py\n+++ b/backend/uclapi/oauth/urls.py\n@@ -4,6 +4,7 @@\n \n urlpatterns = [\n url(r'authorise/$', views.authorise),\n+ url(r'authorize/$', views.authorise),\n url(r'adcallback', views.a...
876
112
gh_patches_debug_31634
rasdani/github-patches
git_diff
Pylons__pyramid-1467
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Creating Integration Tests needs an example plug-in We have test code here, without the corresponding tested code: http://docs.pylonsproject.org/projects/pyramid/en/latest/narr/testing.html#creating-integrati...
diff --git a/docs/narr/MyProject/setup.py b/docs/narr/MyProject/setup.py --- a/docs/narr/MyProject/setup.py +++ b/docs/narr/MyProject/setup.py @@ -1,30 +1,42 @@ -import os +"""Setup for the MyProject package. +""" +import os from setuptools import setup, find_packages -here = os.path.abspath(os.path.dirname(__file...
{"golden_diff": "diff --git a/docs/narr/MyProject/setup.py b/docs/narr/MyProject/setup.py\n--- a/docs/narr/MyProject/setup.py\n+++ b/docs/narr/MyProject/setup.py\n@@ -1,30 +1,42 @@\n-import os\n+\"\"\"Setup for the MyProject package.\n \n+\"\"\"\n+import os\n from setuptools import setup, find_packages\n \n-here = os.p...
648
505
gh_patches_debug_6035
rasdani/github-patches
git_diff
pyro-ppl__pyro-3325
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Bug in `CVAE` example There is a bug in `CVAE` example. The `target` input to the `MaskedBCELoss` is not binary (it has values of -1, 0, 1). This was discovered by the PyTorch 2.1 update which started to vali...
diff --git a/examples/cvae/baseline.py b/examples/cvae/baseline.py --- a/examples/cvae/baseline.py +++ b/examples/cvae/baseline.py @@ -34,8 +34,12 @@ def forward(self, input, target): target = target.view(input.shape) - loss = F.binary_cross_entropy(input, target, reduction="none") - loss[...
{"golden_diff": "diff --git a/examples/cvae/baseline.py b/examples/cvae/baseline.py\n--- a/examples/cvae/baseline.py\n+++ b/examples/cvae/baseline.py\n@@ -34,8 +34,12 @@\n \n def forward(self, input, target):\n target = target.view(input.shape)\n- loss = F.binary_cross_entropy(input, target, reductio...
1,485
155
gh_patches_debug_23373
rasdani/github-patches
git_diff
dotkom__onlineweb4-2485
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Updated membership "fails" for users with membership > 1 year old Currrently the new expiration date for memberships is determined like this: ``` python new_expiration_date = datetime.date(membership.expirat...
diff --git a/apps/approval/views.py b/apps/approval/views.py --- a/apps/approval/views.py +++ b/apps/approval/views.py @@ -11,7 +11,7 @@ from apps.approval.forms import FieldOfStudyApplicationForm from apps.approval.models import MembershipApproval -from apps.authentication.models import Membership, get_length_of_m...
{"golden_diff": "diff --git a/apps/approval/views.py b/apps/approval/views.py\n--- a/apps/approval/views.py\n+++ b/apps/approval/views.py\n@@ -11,7 +11,7 @@\n \n from apps.approval.forms import FieldOfStudyApplicationForm\n from apps.approval.models import MembershipApproval\n-from apps.authentication.models import Mem...
1,898
322
gh_patches_debug_36871
rasdani/github-patches
git_diff
facebookresearch__ParlAI-2851
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Building Dict is too slow **Bug description** ``` from parlai.scripts.train_model import TrainModel TrainModel.main( # similar to before task='amazon_qa', model='projects.wizard_of_wikiped...
diff --git a/parlai/tasks/amazon_qa/agents.py b/parlai/tasks/amazon_qa/agents.py --- a/parlai/tasks/amazon_qa/agents.py +++ b/parlai/tasks/amazon_qa/agents.py @@ -10,6 +10,22 @@ import json +EXISTING_KEYS = [ + 'question', + 'answer', + 'asin', + 'questionType', + 'questionTime', + 'askerID', + ...
{"golden_diff": "diff --git a/parlai/tasks/amazon_qa/agents.py b/parlai/tasks/amazon_qa/agents.py\n--- a/parlai/tasks/amazon_qa/agents.py\n+++ b/parlai/tasks/amazon_qa/agents.py\n@@ -10,6 +10,22 @@\n import json\n \n \n+EXISTING_KEYS = [\n+ 'question',\n+ 'answer',\n+ 'asin',\n+ 'questionType',\n+ 'quest...
1,762
611
gh_patches_debug_30682
rasdani/github-patches
git_diff
freedomofpress__securedrop-6032
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- QA: Automate basic server testing The default QA test plan includes a basic testing section that mostly checks server configuration. These tests are duplicated in the production testinfra tests, so with some ...
diff --git a/molecule/testinfra/conftest.py b/molecule/testinfra/conftest.py --- a/molecule/testinfra/conftest.py +++ b/molecule/testinfra/conftest.py @@ -14,8 +14,7 @@ import testutils -# The config tests target staging by default. It's possible to override -# for e.g. prod, but the associated vars files are not ...
{"golden_diff": "diff --git a/molecule/testinfra/conftest.py b/molecule/testinfra/conftest.py\n--- a/molecule/testinfra/conftest.py\n+++ b/molecule/testinfra/conftest.py\n@@ -14,8 +14,7 @@\n import testutils\n \n \n-# The config tests target staging by default. It's possible to override\n-# for e.g. prod, but the assoc...
1,064
532
gh_patches_debug_2091
rasdani/github-patches
git_diff
ddionrails__ddionrails-801
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Add dynamic range slider for publication year facet see <https://opensource.appbase.io/reactive-manual/vue/range-components/dynamicrangeslider.html> --- END ISSUE --- Below are some code segments, each from...
diff --git a/ddionrails/publications/documents.py b/ddionrails/publications/documents.py --- a/ddionrails/publications/documents.py +++ b/ddionrails/publications/documents.py @@ -36,7 +36,7 @@ # facets sub_type = fields.KeywordField() study = fields.KeywordField() - year = fields.KeywordField() + y...
{"golden_diff": "diff --git a/ddionrails/publications/documents.py b/ddionrails/publications/documents.py\n--- a/ddionrails/publications/documents.py\n+++ b/ddionrails/publications/documents.py\n@@ -36,7 +36,7 @@\n # facets\n sub_type = fields.KeywordField()\n study = fields.KeywordField()\n- year = fiel...
884
102
gh_patches_debug_21420
rasdani/github-patches
git_diff
getsentry__sentry-python-1931
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Patched task factory in AsyncioIntegration loses task result. ### How do you use Sentry? Sentry Saas (sentry.io) ### Version 1.14.0 ### Steps to Reproduce ```python import asyncio import sentry_sdk fr...
diff --git a/sentry_sdk/integrations/asyncio.py b/sentry_sdk/integrations/asyncio.py --- a/sentry_sdk/integrations/asyncio.py +++ b/sentry_sdk/integrations/asyncio.py @@ -32,15 +32,19 @@ # type: (Any, Any) -> Any async def _coro_creating_hub_and_span(): - # type: () -> None + ...
{"golden_diff": "diff --git a/sentry_sdk/integrations/asyncio.py b/sentry_sdk/integrations/asyncio.py\n--- a/sentry_sdk/integrations/asyncio.py\n+++ b/sentry_sdk/integrations/asyncio.py\n@@ -32,15 +32,19 @@\n # type: (Any, Any) -> Any\n \n async def _coro_creating_hub_and_span():\n- ...
1,253
229
gh_patches_debug_19032
rasdani/github-patches
git_diff
streamlit__streamlit-3975
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Slider value and description text overlap for slider in sidebar with long description ### Summary If you use a slider in the sidebar with a long description text, the slider value and the description text ...
diff --git a/e2e/scripts/st_slider.py b/e2e/scripts/st_slider.py --- a/e2e/scripts/st_slider.py +++ b/e2e/scripts/st_slider.py @@ -20,19 +20,28 @@ w2 = st.slider("Label 2", 0.0, 100.0, (25.0, 75.0), 0.5) st.write("Value 2:", w2) +w3 = st.slider( + "Label 3 - This is a very very very very very very very very very...
{"golden_diff": "diff --git a/e2e/scripts/st_slider.py b/e2e/scripts/st_slider.py\n--- a/e2e/scripts/st_slider.py\n+++ b/e2e/scripts/st_slider.py\n@@ -20,19 +20,28 @@\n w2 = st.slider(\"Label 2\", 0.0, 100.0, (25.0, 75.0), 0.5)\n st.write(\"Value 2:\", w2)\n \n+w3 = st.slider(\n+ \"Label 3 - This is a very very very...
1,096
330
gh_patches_debug_12152
rasdani/github-patches
git_diff
Pylons__pyramid-3657
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Sphinx doesn't like the reify decorator > Failed to get a method signature for kinto.core.resource.Resource.timestamp: <pyramid.decorator.reify object at 0x7f175ae45640> is not a callable object If I under...
diff --git a/src/pyramid/decorator.py b/src/pyramid/decorator.py --- a/src/pyramid/decorator.py +++ b/src/pyramid/decorator.py @@ -1,6 +1,3 @@ -from functools import update_wrapper - - class reify: """Use as a class method decorator. It operates almost exactly like the Python ``@property`` decorator, but it...
{"golden_diff": "diff --git a/src/pyramid/decorator.py b/src/pyramid/decorator.py\n--- a/src/pyramid/decorator.py\n+++ b/src/pyramid/decorator.py\n@@ -1,6 +1,3 @@\n-from functools import update_wrapper\n-\n-\n class reify:\n \"\"\"Use as a class method decorator. It operates almost exactly like the\n Python ``...
802
165
gh_patches_debug_12432
rasdani/github-patches
git_diff
pyca__cryptography-8403
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- ignore FRP256v1 in wycheproof tests --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --- BEGIN FILES --- Path: `src/cryptography/hazma...
diff --git a/src/cryptography/hazmat/backends/openssl/utils.py b/src/cryptography/hazmat/backends/openssl/utils.py --- a/src/cryptography/hazmat/backends/openssl/utils.py +++ b/src/cryptography/hazmat/backends/openssl/utils.py @@ -18,7 +18,10 @@ res = backend._lib.EVP_PKEY_derive_init(ctx) backend.openssl_ass...
{"golden_diff": "diff --git a/src/cryptography/hazmat/backends/openssl/utils.py b/src/cryptography/hazmat/backends/openssl/utils.py\n--- a/src/cryptography/hazmat/backends/openssl/utils.py\n+++ b/src/cryptography/hazmat/backends/openssl/utils.py\n@@ -18,7 +18,10 @@\n res = backend._lib.EVP_PKEY_derive_init(ctx)\n ...
882
215
gh_patches_debug_331
rasdani/github-patches
git_diff
InternLM__lmdeploy-205
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Serving gradio报错 ![image](https://github.com/InternLM/lmdeploy/assets/6971044/d84724e1-e098-4ad7-9b02-bdc5e0bdeec0) 报错: no module named lmdeploy.serve.gradio 环境里已安装了lmdeploy 0.0.2 python包。 --- END ISSU...
diff --git a/lmdeploy/version.py b/lmdeploy/version.py --- a/lmdeploy/version.py +++ b/lmdeploy/version.py @@ -1,7 +1,7 @@ # Copyright (c) OpenMMLab. All rights reserved. from typing import Tuple -__version__ = '0.0.2' +__version__ = '0.0.3' short_version = __version__
{"golden_diff": "diff --git a/lmdeploy/version.py b/lmdeploy/version.py\n--- a/lmdeploy/version.py\n+++ b/lmdeploy/version.py\n@@ -1,7 +1,7 @@\n # Copyright (c) OpenMMLab. All rights reserved.\n from typing import Tuple\n \n-__version__ = '0.0.2'\n+__version__ = '0.0.3'\n short_version = __version__\n", "issue": "Servi...
604
91
gh_patches_debug_935
rasdani/github-patches
git_diff
e-valuation__EvaP-817
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- +x on update.sh, earlier apache restart update_production.sh is missing the x bit, also because of the cache clearing the apache is restarted 2min after the code has changed. --- END ISSUE --- Below are so...
diff --git a/evap/evaluation/management/commands/refresh_results_cache.py b/evap/evaluation/management/commands/refresh_results_cache.py --- a/evap/evaluation/management/commands/refresh_results_cache.py +++ b/evap/evaluation/management/commands/refresh_results_cache.py @@ -24,4 +24,4 @@ progress_bar.updat...
{"golden_diff": "diff --git a/evap/evaluation/management/commands/refresh_results_cache.py b/evap/evaluation/management/commands/refresh_results_cache.py\n--- a/evap/evaluation/management/commands/refresh_results_cache.py\n+++ b/evap/evaluation/management/commands/refresh_results_cache.py\n@@ -24,4 +24,4 @@\n ...
533
122
gh_patches_debug_7052
rasdani/github-patches
git_diff
hpcaitech__ColossalAI-2712
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [tensor] fix some unittests [tensor] fix some unittests [tensor] fix some unittests --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs....
diff --git a/colossalai/context/process_group_initializer/initializer_sequence.py b/colossalai/context/process_group_initializer/initializer_sequence.py --- a/colossalai/context/process_group_initializer/initializer_sequence.py +++ b/colossalai/context/process_group_initializer/initializer_sequence.py @@ -3,9 +3,10 @@ ...
{"golden_diff": "diff --git a/colossalai/context/process_group_initializer/initializer_sequence.py b/colossalai/context/process_group_initializer/initializer_sequence.py\n--- a/colossalai/context/process_group_initializer/initializer_sequence.py\n+++ b/colossalai/context/process_group_initializer/initializer_sequence.p...
1,339
133
gh_patches_debug_10437
rasdani/github-patches
git_diff
Project-MONAI__MONAI-2060
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- ignore `label` in the workflow if it's not tensor **Is your feature request related to a problem? Please describe.** During evaluation, now we use `prepare_batch` to extract `image` and `label` fields if exi...
diff --git a/monai/engines/utils.py b/monai/engines/utils.py --- a/monai/engines/utils.py +++ b/monai/engines/utils.py @@ -107,7 +107,7 @@ """ if not isinstance(batchdata, dict): raise AssertionError("default prepare_batch expects dictionary input data.") - if CommonKeys.LABEL in batchdata: + i...
{"golden_diff": "diff --git a/monai/engines/utils.py b/monai/engines/utils.py\n--- a/monai/engines/utils.py\n+++ b/monai/engines/utils.py\n@@ -107,7 +107,7 @@\n \"\"\"\n if not isinstance(batchdata, dict):\n raise AssertionError(\"default prepare_batch expects dictionary input data.\")\n- if CommonKe...
1,646
149
gh_patches_debug_33202
rasdani/github-patches
git_diff
DataDog__dd-trace-py-439
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- TracePlugin not working for bottle + python 2.7.x Hi, we have a backend using python 2.7.x, Im integrating Datadog APM following the documentation and I have the following error: ``` Traceback (most recent ...
diff --git a/ddtrace/contrib/bottle/trace.py b/ddtrace/contrib/bottle/trace.py --- a/ddtrace/contrib/bottle/trace.py +++ b/ddtrace/contrib/bottle/trace.py @@ -1,4 +1,3 @@ - # 3p from bottle import response, request @@ -10,18 +9,18 @@ from ...propagation.http import HTTPPropagator class TracePlugin(object): - ...
{"golden_diff": "diff --git a/ddtrace/contrib/bottle/trace.py b/ddtrace/contrib/bottle/trace.py\n--- a/ddtrace/contrib/bottle/trace.py\n+++ b/ddtrace/contrib/bottle/trace.py\n@@ -1,4 +1,3 @@\n-\n # 3p\n from bottle import response, request\n \n@@ -10,18 +9,18 @@\n from ...propagation.http import HTTPPropagator\n \n cla...
1,105
438
gh_patches_debug_3827
rasdani/github-patches
git_diff
kivy__python-for-android-1427
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Pin pyjnius version This pull request adds a version pin for pyjnius as requested here: #1415 Please note I am proposing this as a **permanent measure** because this is such a core component - not this sp...
diff --git a/pythonforandroid/recipes/pyjnius/__init__.py b/pythonforandroid/recipes/pyjnius/__init__.py --- a/pythonforandroid/recipes/pyjnius/__init__.py +++ b/pythonforandroid/recipes/pyjnius/__init__.py @@ -6,7 +6,7 @@ class PyjniusRecipe(CythonRecipe): - version = 'master' + version = '1.1.3' url =...
{"golden_diff": "diff --git a/pythonforandroid/recipes/pyjnius/__init__.py b/pythonforandroid/recipes/pyjnius/__init__.py\n--- a/pythonforandroid/recipes/pyjnius/__init__.py\n+++ b/pythonforandroid/recipes/pyjnius/__init__.py\n@@ -6,7 +6,7 @@\n \n \n class PyjniusRecipe(CythonRecipe):\n- version = 'master'\n+ ver...
812
157
gh_patches_debug_39067
rasdani/github-patches
git_diff
ultrabug__py3status-958
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- selinux module install check refers to binary not in user path The selinux module tries to check whether selinux is installed. `if not self.py3.check_commands(['getenforce']):` this effectively runs `wh...
diff --git a/py3status/modules/selinux.py b/py3status/modules/selinux.py --- a/py3status/modules/selinux.py +++ b/py3status/modules/selinux.py @@ -3,11 +3,11 @@ Display SELinux state. This module displays the state of SELinux on your machine: -Enforcing (good), Permissive (bad), or Disabled (bad). +Enforcing (good)...
{"golden_diff": "diff --git a/py3status/modules/selinux.py b/py3status/modules/selinux.py\n--- a/py3status/modules/selinux.py\n+++ b/py3status/modules/selinux.py\n@@ -3,11 +3,11 @@\n Display SELinux state.\n \n This module displays the state of SELinux on your machine:\n-Enforcing (good), Permissive (bad), or Disabled ...
1,091
694
gh_patches_debug_1998
rasdani/github-patches
git_diff
PrefectHQ__prefect-2609
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Consider promoting `case` to the top level ## Current behavior *Please describe how the feature works today* Currently, the `case` context manager must be imported from `prefect.tasks.control_flow.case`. ...
diff --git a/src/prefect/__init__.py b/src/prefect/__init__.py --- a/src/prefect/__init__.py +++ b/src/prefect/__init__.py @@ -11,6 +11,7 @@ from prefect.core import Task, Flow, Parameter import prefect.engine import prefect.tasks +from prefect.tasks.control_flow import case from prefect.utilities.tasks import task...
{"golden_diff": "diff --git a/src/prefect/__init__.py b/src/prefect/__init__.py\n--- a/src/prefect/__init__.py\n+++ b/src/prefect/__init__.py\n@@ -11,6 +11,7 @@\n from prefect.core import Task, Flow, Parameter\n import prefect.engine\n import prefect.tasks\n+from prefect.tasks.control_flow import case\n from prefect.ut...
694
99
gh_patches_debug_20034
rasdani/github-patches
git_diff
python-discord__bot-790
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Filters should not apply to staff members Currently, we have certain channels whitelisted for certain filters and some filters apply to all members, even Owners cannot post filetypes that aren't on the whitel...
diff --git a/bot/cogs/antimalware.py b/bot/cogs/antimalware.py --- a/bot/cogs/antimalware.py +++ b/bot/cogs/antimalware.py @@ -4,7 +4,7 @@ from discord.ext.commands import Cog from bot.bot import Bot -from bot.constants import AntiMalware as AntiMalwareConfig, Channels, URLs +from bot.constants import AntiMalware a...
{"golden_diff": "diff --git a/bot/cogs/antimalware.py b/bot/cogs/antimalware.py\n--- a/bot/cogs/antimalware.py\n+++ b/bot/cogs/antimalware.py\n@@ -4,7 +4,7 @@\n from discord.ext.commands import Cog\n \n from bot.bot import Bot\n-from bot.constants import AntiMalware as AntiMalwareConfig, Channels, URLs\n+from bot.const...
897
277
gh_patches_debug_19708
rasdani/github-patches
git_diff
translate__pootle-4422
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Migrations that alter sensitive schema fail I am using `mysql Ver 14.14 Distrib 5.5.46, for debian-linux-gnu (x86_64) using readline 6.3`. ``` pytb ./manage.py migrate 2016-01-22 09:33:09,204 INFO Using Py...
diff --git a/pootle/core/utils/db.py b/pootle/core/utils/db.py --- a/pootle/core/utils/db.py +++ b/pootle/core/utils/db.py @@ -24,7 +24,7 @@ # Get the current collation cursor.execute( "SELECT COLLATION_NAME" - " FROM information_schema.columns" + " FROM `information_schema`.`columns`" ...
{"golden_diff": "diff --git a/pootle/core/utils/db.py b/pootle/core/utils/db.py\n--- a/pootle/core/utils/db.py\n+++ b/pootle/core/utils/db.py\n@@ -24,7 +24,7 @@\n # Get the current collation\n cursor.execute(\n \"SELECT COLLATION_NAME\"\n- \" FROM information_schema.columns\"\n+ \" FROM `i...
1,945
255
gh_patches_debug_265
rasdani/github-patches
git_diff
Nitrate__Nitrate-603
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Upgrade celery to 4.3.0 As per title. Remove `skipIf` from test `test_uses_celery`. --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may contain bugs. --...
diff --git a/setup.py b/setup.py --- a/setup.py +++ b/setup.py @@ -61,7 +61,7 @@ # Required packages required to run async tasks 'async': [ - 'celery == 4.2.0', + 'celery == 4.4.2', ], 'multiauth': [
{"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -61,7 +61,7 @@\n \n # Required packages required to run async tasks\n 'async': [\n- 'celery == 4.2.0',\n+ 'celery == 4.4.2',\n ],\n \n 'multiauth': [\n", "issue": "Upgrade celery to 4.3.0\nAs per title. R...
1,289
84
gh_patches_debug_1675
rasdani/github-patches
git_diff
translate__pootle-4882
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Make `pootle webpack` not require system checks `pootle webpack` fails if eg the db is not set up/correctly. It would be helpful if it didnt --- END ISSUE --- Below are some code segments, each from a rele...
diff --git a/pootle/apps/pootle_app/management/commands/webpack.py b/pootle/apps/pootle_app/management/commands/webpack.py --- a/pootle/apps/pootle_app/management/commands/webpack.py +++ b/pootle/apps/pootle_app/management/commands/webpack.py @@ -19,6 +19,7 @@ class Command(BaseCommand): help = 'Builds and bund...
{"golden_diff": "diff --git a/pootle/apps/pootle_app/management/commands/webpack.py b/pootle/apps/pootle_app/management/commands/webpack.py\n--- a/pootle/apps/pootle_app/management/commands/webpack.py\n+++ b/pootle/apps/pootle_app/management/commands/webpack.py\n@@ -19,6 +19,7 @@\n \n class Command(BaseCommand):\n ...
1,259
124
gh_patches_debug_39408
rasdani/github-patches
git_diff
deepset-ai__haystack-6396
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- `PyPDFToDocument` 2.0 is not JSON-serializable due to its `DefaultConverter` **Describe the bug** Pipelines containing a PyPDFConverter are not JSON-serializable due to the `DefaultConverter` set in its init...
diff --git a/haystack/preview/components/converters/pypdf.py b/haystack/preview/components/converters/pypdf.py --- a/haystack/preview/components/converters/pypdf.py +++ b/haystack/preview/components/converters/pypdf.py @@ -1,11 +1,11 @@ import io import logging -from typing import List, Union, Optional, Protocol +fro...
{"golden_diff": "diff --git a/haystack/preview/components/converters/pypdf.py b/haystack/preview/components/converters/pypdf.py\n--- a/haystack/preview/components/converters/pypdf.py\n+++ b/haystack/preview/components/converters/pypdf.py\n@@ -1,11 +1,11 @@\n import io\n import logging\n-from typing import List, Union, ...
1,929
650
gh_patches_debug_16748
rasdani/github-patches
git_diff
Lightning-Universe__lightning-flash-375
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- `val_split` + `overfit_batches` gives infinite recursion error ## 🐛 Bug `val_split` + `overfit_batches` gives infinite recursion error on master --- END ISSUE --- Below are some code segments, each from...
diff --git a/flash/core/data/splits.py b/flash/core/data/splits.py --- a/flash/core/data/splits.py +++ b/flash/core/data/splits.py @@ -13,7 +13,7 @@ dataset: A dataset to be splitted indices: List of indices to expose from the dataset - use_duplicated_indices: Wether to allow duplicated indic...
{"golden_diff": "diff --git a/flash/core/data/splits.py b/flash/core/data/splits.py\n--- a/flash/core/data/splits.py\n+++ b/flash/core/data/splits.py\n@@ -13,7 +13,7 @@\n \n dataset: A dataset to be splitted\n indices: List of indices to expose from the dataset\n- use_duplicated_indices: Wether t...
839
216
gh_patches_debug_7021
rasdani/github-patches
git_diff
zulip__zulip-26839
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Update documentation on previews permissions The help center should be updated following #27783. --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of these files may con...
diff --git a/zerver/lib/url_redirects.py b/zerver/lib/url_redirects.py --- a/zerver/lib/url_redirects.py +++ b/zerver/lib/url_redirects.py @@ -80,6 +80,7 @@ URLRedirect("/help/configure-default-view", "/help/configure-home-view"), URLRedirect("/help/reading-topics", "/help/reading-conversations"), URLRed...
{"golden_diff": "diff --git a/zerver/lib/url_redirects.py b/zerver/lib/url_redirects.py\n--- a/zerver/lib/url_redirects.py\n+++ b/zerver/lib/url_redirects.py\n@@ -80,6 +80,7 @@\n URLRedirect(\"/help/configure-default-view\", \"/help/configure-home-view\"),\n URLRedirect(\"/help/reading-topics\", \"/help/reading...
1,482
137
gh_patches_debug_32222
rasdani/github-patches
git_diff
explosion__spaCy-3281
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Incorrect tokenization of dash punctuation in Spanish In Spanish text, the conventions for using dashes and em-dashes as punctuation seems to be considerably different than in English. Spacy often does not to...
diff --git a/spacy/lang/punctuation.py b/spacy/lang/punctuation.py --- a/spacy/lang/punctuation.py +++ b/spacy/lang/punctuation.py @@ -1,14 +1,13 @@ # coding: utf8 from __future__ import unicode_literals -from .char_classes import LIST_PUNCT, LIST_ELLIPSES, LIST_QUOTES, LIST_CURRENCY, LIST_ICONS -from .char_classes...
{"golden_diff": "diff --git a/spacy/lang/punctuation.py b/spacy/lang/punctuation.py\n--- a/spacy/lang/punctuation.py\n+++ b/spacy/lang/punctuation.py\n@@ -1,14 +1,13 @@\n # coding: utf8\n from __future__ import unicode_literals\n \n-from .char_classes import LIST_PUNCT, LIST_ELLIPSES, LIST_QUOTES, LIST_CURRENCY, LIST_I...
1,171
710
gh_patches_debug_47933
rasdani/github-patches
git_diff
liqd__a4-opin-583
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- when I log out while I am on my profile page I get a 500 --- 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/follows/templatetags/follow_tags.py b/euth/follows/templatetags/follow_tags.py --- a/euth/follows/templatetags/follow_tags.py +++ b/euth/follows/templatetags/follow_tags.py @@ -7,8 +7,11 @@ @register.assignment_tag() def is_following(user, project): - return models.Follow.objects.filter( - ...
{"golden_diff": "diff --git a/euth/follows/templatetags/follow_tags.py b/euth/follows/templatetags/follow_tags.py\n--- a/euth/follows/templatetags/follow_tags.py\n+++ b/euth/follows/templatetags/follow_tags.py\n@@ -7,8 +7,11 @@\n \n @register.assignment_tag()\n def is_following(user, project):\n- return models.Follo...
366
171
gh_patches_debug_10257
rasdani/github-patches
git_diff
getsentry__sentry-48159
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Unable to disable issue alert notifications for specific projects on old sentry accounts. ### Environment SaaS (https://sentry.io/) ### Version _No response_ ### Link _No response_ ### DSN _No response...
diff --git a/src/sentry/incidents/endpoints/bases.py b/src/sentry/incidents/endpoints/bases.py --- a/src/sentry/incidents/endpoints/bases.py +++ b/src/sentry/incidents/endpoints/bases.py @@ -15,7 +15,10 @@ args, kwargs = super().convert_args(request, *args, **kwargs) project = kwargs["project"] - ...
{"golden_diff": "diff --git a/src/sentry/incidents/endpoints/bases.py b/src/sentry/incidents/endpoints/bases.py\n--- a/src/sentry/incidents/endpoints/bases.py\n+++ b/src/sentry/incidents/endpoints/bases.py\n@@ -15,7 +15,10 @@\n args, kwargs = super().convert_args(request, *args, **kwargs)\n project = kw...
1,437
173
gh_patches_debug_5127
rasdani/github-patches
git_diff
comic__grand-challenge.org-1064
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Duplicate email to algorithm user that is also an editor when job fails A tiny improvement request: When an algorithm job fails, the editors and the job creator are emailed (#1018), but there is apparently no...
diff --git a/app/grandchallenge/algorithms/emails.py b/app/grandchallenge/algorithms/emails.py --- a/app/grandchallenge/algorithms/emails.py +++ b/app/grandchallenge/algorithms/emails.py @@ -99,7 +99,8 @@ o.email for o in algorithm.editors_group.user_set.all() ] recipient_emails.append(job.creator.em...
{"golden_diff": "diff --git a/app/grandchallenge/algorithms/emails.py b/app/grandchallenge/algorithms/emails.py\n--- a/app/grandchallenge/algorithms/emails.py\n+++ b/app/grandchallenge/algorithms/emails.py\n@@ -99,7 +99,8 @@\n o.email for o in algorithm.editors_group.user_set.all()\n ]\n recipient_email...
1,268
124
gh_patches_debug_23994
rasdani/github-patches
git_diff
jupyter__docker-stacks-2074
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- [BUG] Healthcheck fails when using a custom runtime dir ### What docker image(s) are you using? scipy-notebook (but applies to all images based on the `base-notebook` image) ### Host OS system RHEL 8...
diff --git a/images/base-notebook/docker_healthcheck.py b/images/base-notebook/docker_healthcheck.py --- a/images/base-notebook/docker_healthcheck.py +++ b/images/base-notebook/docker_healthcheck.py @@ -3,6 +3,7 @@ # Distributed under the terms of the Modified BSD License. import json import os +import subprocess f...
{"golden_diff": "diff --git a/images/base-notebook/docker_healthcheck.py b/images/base-notebook/docker_healthcheck.py\n--- a/images/base-notebook/docker_healthcheck.py\n+++ b/images/base-notebook/docker_healthcheck.py\n@@ -3,6 +3,7 @@\n # Distributed under the terms of the Modified BSD License.\n import json\n import o...
1,395
338
gh_patches_debug_24008
rasdani/github-patches
git_diff
fossasia__open-event-server-4806
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Change is-ticketing-enabled field of Event to dump_only **I'm submitting a ...** (check one with "x") - [ ] bug report - [x] feature request - [ ] support request => Please do not submit support requests ...
diff --git a/app/api/tickets.py b/app/api/tickets.py --- a/app/api/tickets.py +++ b/app/api/tickets.py @@ -11,8 +11,9 @@ from app.models.access_code import AccessCode from app.models.order import Order from app.models.ticket import Ticket, TicketTag, ticket_tags_table +from app.models.event import Event from app.mo...
{"golden_diff": "diff --git a/app/api/tickets.py b/app/api/tickets.py\n--- a/app/api/tickets.py\n+++ b/app/api/tickets.py\n@@ -11,8 +11,9 @@\n from app.models.access_code import AccessCode\n from app.models.order import Order\n from app.models.ticket import Ticket, TicketTag, ticket_tags_table\n+from app.models.event i...
1,997
257
gh_patches_debug_4691
rasdani/github-patches
git_diff
mindsdb__lightwood-608
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- :wrench: Colored terminal output ## Task Modify the lightwood [logger class](https://github.com/mindsdb/lightwood/blob/stable/lightwood/helpers/log.py) so that its output is colored, depending on the log l...
diff --git a/lightwood/helpers/log.py b/lightwood/helpers/log.py --- a/lightwood/helpers/log.py +++ b/lightwood/helpers/log.py @@ -1,10 +1,15 @@ import logging import os +import colorlog def initialize_log(): pid = os.getpid() - logging.basicConfig() + + handler = colorlog.StreamHandler() + handler...
{"golden_diff": "diff --git a/lightwood/helpers/log.py b/lightwood/helpers/log.py\n--- a/lightwood/helpers/log.py\n+++ b/lightwood/helpers/log.py\n@@ -1,10 +1,15 @@\n import logging\n import os\n+import colorlog\n \n \n def initialize_log():\n pid = os.getpid()\n- logging.basicConfig()\n+\n+ handler = colorlo...
669
125
gh_patches_debug_40903
rasdani/github-patches
git_diff
mozilla__bugbug-916
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Tune the check for training metrics We currently set an arbitrary max 5% worse result, we might need to tune it --- END ISSUE --- Below are some code segments, each from a relevant file. One or more of thes...
diff --git a/scripts/analyze_training_metrics.py b/scripts/analyze_training_metrics.py --- a/scripts/analyze_training_metrics.py +++ b/scripts/analyze_training_metrics.py @@ -21,7 +21,8 @@ logging.basicConfig(level=logging.INFO) -# If the latest metric point is 5% lower than the previous one, show a warning and ex...
{"golden_diff": "diff --git a/scripts/analyze_training_metrics.py b/scripts/analyze_training_metrics.py\n--- a/scripts/analyze_training_metrics.py\n+++ b/scripts/analyze_training_metrics.py\n@@ -21,7 +21,8 @@\n \n logging.basicConfig(level=logging.INFO)\n \n-# If the latest metric point is 5% lower than the previous on...
1,961
686
gh_patches_debug_5795
rasdani/github-patches
git_diff
sunpy__sunpy-7148
We are currently solving the following issue within our repository. Here is the issue text: --- BEGIN ISSUE --- Fido query for GBM data only matches files with v00.pha and misses those that have been version updated (e.g. v01.pha) ### Describe the bug The way the source client for GBM is currently implemented, scrap...
diff --git a/sunpy/net/dataretriever/sources/fermi_gbm.py b/sunpy/net/dataretriever/sources/fermi_gbm.py --- a/sunpy/net/dataretriever/sources/fermi_gbm.py +++ b/sunpy/net/dataretriever/sources/fermi_gbm.py @@ -48,7 +48,8 @@ <BLANKLINE> """ - baseurl = r'https://heasarc.gsfc.nasa.gov/FTP/fermi/data/gbm/d...
{"golden_diff": "diff --git a/sunpy/net/dataretriever/sources/fermi_gbm.py b/sunpy/net/dataretriever/sources/fermi_gbm.py\n--- a/sunpy/net/dataretriever/sources/fermi_gbm.py\n+++ b/sunpy/net/dataretriever/sources/fermi_gbm.py\n@@ -48,7 +48,8 @@\n <BLANKLINE>\n \n \"\"\"\n- baseurl = r'https://heasarc.gsfc.na...
1,727
250