selection_rank
int64
0
10k
uid
stringlengths
17
29
source
stringclasses
7 values
split
stringclasses
3 values
row_idx
int64
0
58.9k
instance_id
stringlengths
14
120
repo
stringclasses
246 values
repo_canon
stringclasses
232 values
language
stringclasses
8 values
base_commit
stringlengths
40
40
⌀
problem_statement
stringlengths
84
23.6k
extra_context
stringclasses
626 values
hints
stringlengths
0
59.3k
patch
stringlengths
252
175k
test_patch
stringlengths
0
358k
f2p
stringlengths
10
155k
⌀
p2p
stringlengths
2
1.75M
⌀
env_image
stringlengths
41
154
⌀
env_available
bool
1 class
created_at
stringlengths
10
20
⌀
n_src_files
int64
1
15
src_lines
int64
1
1.48k
n_f2p
float64
1
1.87k
⌀
ps_chars
int64
84
23.6k
leak_ratio
float64
0
0.6
s_prior
float64
0.6
1
s_verif
float64
0.75
1
s_ps
float64
0.04
1
s_patch
float64
0.07
1
s_tiebreak
float64
0.02
1
score
float64
47.9
98.6
7,000
swe_smith::train::4942
swe_smith
train
4,942
bottlepy__bottle.a8dfef30.func_pm_ctrl_shuffle__bbq9r6gt
swesmith/bottlepy__bottle.a8dfef30
bottlepy/bottle
python
null
WSGI mount fails with UnboundLocalError on path_depth and segments variables #### Description When mounting WSGI applications using the `mount()` method, the application crashes with an `UnboundLocalError` because variables `path_depth` and `segments` are referenced before being defined in the `_mount_wsgi` method. ...
diff --git a/bottle.py b/bottle.py index 286b5bc..eaf8347 100755 --- a/bottle.py +++ b/bottle.py @@ -699,10 +699,6 @@ class Bottle(object): return decorator def _mount_wsgi(self, prefix, app, **options): - segments = [p for p in prefix.split('/') if p] - if not segments: - raise...
["test/test_mount.py::TestAppMounting::test_mount_wsgi", "test/test_mount.py::TestAppMounting::test_mount_wsgi_ctype_bug", "test/test_mount.py::TestAppMounting::test_no_slash_prefix"]
["test/test_app.py::TestApplicationObject::test_setattr", "test/test_auth.py::TestBasicAuth::test__header", "test/test_config.py::TestConfDict::test_gc_overlays", "test/test_config.py::TestConfDict::test_isadict", "test/test_config.py::TestConfDict::test_load_dict", "test/test_config.py::TestConfDict::test_load_module"...
jyangballin/swesmith.x86_64.bottlepy_1776_bottle.a8dfef30
true
null
1
15
3
1,118
0
0.6
1
0.75
1
0.236333
80.984
7,001
swe_smith::train::7428
swe_smith
train
7,428
cantools__cantools.0c6a7871.func_basic__b0n17uz1
swesmith/cantools__cantools.0c6a7871
cantools/cantools
python
null
Signal encoding returns incomplete data when encountering unsupported value types #### Description When encoding CAN messages with signal values that have unsupported types, the encoding process silently returns incomplete data instead of raising an error. This can lead to corrupted or partial message encoding withou...
diff --git a/src/cantools/database/utils.py b/src/cantools/database/utils.py index cd33b81..713fd8b 100644 --- a/src/cantools/database/utils.py +++ b/src/cantools/database/utils.py @@ -76,14 +76,14 @@ def _encode_signal_values(signals: Sequence[Union["Signal", "Data"]], for signal in signals: name = signa...
["tests/test_database.py::CanToolsDatabaseTest::test_encode_mixed_signal", "tests/test_database.py::CanToolsDatabaseTest::test_encode_signal_strict", "tests/test_database.py::CanToolsDatabaseTest::test_motohawk_encode_decode"]
["tests/test_autosar.py::CanToolsAutosarTest::test_autosar3_e2e_profile2", "tests/test_autosar.py::CanToolsAutosarTest::test_autosar4_e2e", "tests/test_autosar.py::CanToolsAutosarTest::test_autosar4_e2e_profile5", "tests/test_autosar.py::CanToolsAutosarTest::test_autosar4_secoc", "tests/test_command_line.py::CanToolsCo...
jyangballin/swesmith.x86_64.cantools_1776_cantools.0c6a7871
true
null
1
12
3
1,178
0
0.6
1
0.75
1
0.236333
80.984
7,002
swe_smith::train::52557
swe_smith
train
52,557
pydicom__pydicom.7d361b3d.func_pm_remove_cond__a4opnv32
swesmith/pydicom__pydicom.7d361b3d
pydicom/pydicom
python
null
FileSet.load() fails with NameError when loading DICOMDIR files #### Description When trying to load DICOMDIR files using `FileSet.load()`, the method fails with a `NameError: name 'ds' is not defined`. This appears to affect all DICOMDIR loading operations. #### Steps/Code to Reproduce ```python from pydicom.files...
diff --git a/src/pydicom/fileset.py b/src/pydicom/fileset.py index 75976eb..c8f23c9 100644 --- a/src/pydicom/fileset.py +++ b/src/pydicom/fileset.py @@ -1614,10 +1614,6 @@ class FileSet: If ``True`` then raise an exception if orphaned directory records are found in the File-set (default ``Fals...
["tests/test_fileset.py::TestRecordNode::test_root", "tests/test_fileset.py::TestRecordNode::test_leaf", "tests/test_fileset.py::TestRecordNode::test_add", "tests/test_fileset.py::TestRecordNode::test_key", "tests/test_fileset.py::TestRecordNode::test_bad_record", "tests/test_fileset.py::TestRecordNode::test_bad_record...
["tests/pixels/test_common.py::TestRunnerBase::test_init", "tests/pixels/test_common.py::TestRunnerBase::test_del_option", "tests/pixels/test_common.py::TestRunnerBase::test_option_properties", "tests/pixels/test_common.py::TestRunnerBase::test_planar_configuration", "tests/pixels/test_common.py::TestRunnerBase::test_s...
jyangballin/swesmith.x86_64.pydicom_1776_pydicom.7d361b3d
true
null
1
8
109
1,258
0
0.6
1
0.75
1
0.236333
80.984
7,003
swe_smith::train::42644
swe_smith
train
42,644
python-jsonschema__jsonschema.93e0caa5.func_basic__rudj6rn4
swesmith/python-jsonschema__jsonschema.93e0caa5
python-jsonschema/jsonschema
python
null
Validator evolve method broken with custom field aliases #### Description The `evolve` method on validator instances fails when the validator class has custom field aliases. The method incorrectly uses the field name instead of the field alias when building the changes dictionary, causing a TypeError when instantiati...
diff --git a/jsonschema/validators.py b/jsonschema/validators.py index b8ca3bd..7b463e7 100644 --- a/jsonschema/validators.py +++ b/jsonschema/validators.py @@ -259,22 +259,22 @@ def create( "composition of validators, wrapping them in an object " "owned entirely by the downstr...
["jsonschema/tests/test_deprecations.py::TestDeprecations::test_Validator_subclassing", "jsonschema/tests/test_validators.py::TestDraft3Validator::test_evolve_with_subclass", "jsonschema/tests/test_validators.py::TestDraft4Validator::test_evolve_with_subclass", "jsonschema/tests/test_validators.py::TestDraft6Validator:...
["jsonschema/tests/test_cli.py::TestCLI::test_custom_error_format", "jsonschema/tests/test_cli.py::TestCLI::test_custom_error_format_applies_to_schema_errors", "jsonschema/tests/test_cli.py::TestCLI::test_instance_does_not_exist", "jsonschema/tests/test_cli.py::TestCLI::test_instance_does_not_exist_pretty_output", "jso...
jyangballin/swesmith.x86_64.python-jsonschema_1776_jsonschema.93e0caa5
true
null
1
12
7
1,178
0
0.6
1
0.75
1
0.236333
80.984
7,004
swe_smith::train::5136
swe_smith
train
5,136
agronholm__exceptiongroup.0b4f4937.func_basic__obno4b6g
swesmith/agronholm__exceptiongroup.0b4f4937
agronholm/exceptiongroup
python
null
catch() function validation logic broken #### Description The `catch()` function has broken validation logic that prevents normal usage and raises incorrect errors. #### Steps/Code to Reproduce ```python from exceptiongroup import catch # This should work but raises TypeError def handler(eg): pass with catch(...
diff --git a/src/exceptiongroup/_catch.py b/src/exceptiongroup/_catch.py index 0246568..e895a1e 100644 --- a/src/exceptiongroup/_catch.py +++ b/src/exceptiongroup/_catch.py @@ -96,7 +96,7 @@ class _Catcher: def catch( __handlers: Mapping[type[BaseException] | Iterable[type[BaseException]], _Handler], ) -> Abstra...
["tests/test_catch.py::test_bad_arg", "tests/test_catch.py::test_bad_handler", "tests/test_catch.py::test_catch_exceptiongroup[naked_basegroup]", "tests/test_catch.py::test_catch_exceptiongroup[naked_group]", "tests/test_catch.py::test_catch_exceptiongroup[iterable_basegroup]", "tests/test_catch.py::test_catch_exceptio...
["tests/test_exceptions.py::TestExceptionGroupTypeHierarchy::test_exception_group_is_generic_type", "tests/test_exceptions.py::TestExceptionGroupTypeHierarchy::test_exception_group_types", "tests/test_exceptions.py::BadConstructorArgs::test_bad_EG_construction__bad_excs_sequence", "tests/test_exceptions.py::BadConstruc...
jyangballin/swesmith.x86_64.agronholm_1776_exceptiongroup.0b4f4937
true
null
1
26
17
898
0
0.6
1
0.75
1
0.236333
80.984
7,005
swe_smith::train::38675
swe_smith
train
38,675
erikrose__parsimonious.0d3f5f93.lm_rewrite__m56eyws9
swesmith/erikrose__parsimonious.0d3f5f93
erikrose/parsimonious
python
null
# IncompleteParseError shows incorrect position information There's an issue with the `IncompleteParseError` in the `parse()` method. When parsing text that doesn't fully match the grammar, the error message shows incorrect position information. ## Reproduction Here's a minimal example that demonstrates the issue: ...
diff --git a/parsimonious/expressions.py b/parsimonious/expressions.py index a1cf40b..6ac4b41 100644 --- a/parsimonious/expressions.py +++ b/parsimonious/expressions.py @@ -141,11 +141,13 @@ class Expression(StrAndRepr): consume the full string. """ - node = self.match(text, pos=pos) - ...
["parsimonious/tests/test_expressions.py::ErrorReportingTests::test_parse_with_leftovers"]
["parsimonious/tests/test_benchmarks.py::TestBenchmarks::test_call_vs_inline", "parsimonious/tests/test_benchmarks.py::TestBenchmarks::test_lists_vs_dicts", "parsimonious/tests/test_benchmarks.py::TestBenchmarks::test_startswith_vs_regex", "parsimonious/tests/test_expressions.py::LengthTests::test_not", "parsimonious/t...
jyangballin/swesmith.x86_64.erikrose_1776_parsimonious.0d3f5f93
true
null
1
10
1
1,218
0
0.6
1
0.75
1
0.236333
80.984
7,006
swe_smith::train::22018
swe_smith
train
22,018
life4__textdistance.c3aca916.func_pm_remove_assign__3pphwdf7
swesmith/life4__textdistance.c3aca916
life4/textdistance
python
null
JaroWinkler algorithm broken after recent changes #### Description The JaroWinkler similarity calculation is throwing NameError exceptions when trying to compute distances between strings. This affects both the Jaro and JaroWinkler algorithms. #### Steps/Code to Reproduce ```python import textdistance # This shoul...
diff --git a/textdistance/algorithms/edit_based.py b/textdistance/algorithms/edit_based.py index 0a6e02f..c6fbbcc 100644 --- a/textdistance/algorithms/edit_based.py +++ b/textdistance/algorithms/edit_based.py @@ -328,20 +328,13 @@ class JaroWinkler(_BaseSimilarity): result = self.quick_answer(s1, s2) ...
["tests/test_edit/test_jaro.py::test_distance[hello-haloa-0.7333333333333334]", "tests/test_edit/test_jaro.py::test_distance[fly-ant-0.0]", "tests/test_edit/test_jaro.py::test_distance[frog-fog-0.9166666666666666]", "tests/test_edit/test_jaro.py::test_distance[ATCG-TAGC-0.8333333333333334]", "tests/test_edit/test_jaro....
["tests/test_common.py::test_normalization_range[alg0]", "tests/test_common.py::test_normalization_range[alg1]", "tests/test_common.py::test_normalization_range[alg2]", "tests/test_common.py::test_normalization_range[alg3]", "tests/test_common.py::test_normalization_range[alg4]", "tests/test_common.py::test_normalizati...
jyangballin/swesmith.x86_64.life4_1776_textdistance.c3aca916
true
null
1
17
25
1,077
0
0.6
1
0.75
1
0.236167
80.9835
7,007
swe_smith::train::21796
swe_smith
train
21,796
life4__textdistance.c3aca916.combine_file__hxml8xjz
swesmith/life4__textdistance.c3aca916
life4/textdistance
python
null
Jaccard similarity returns incorrect results due to variable ordering issue #### Description The Jaccard similarity algorithm is producing incorrect results. When comparing identical strings, it should return a similarity of 1.0, but instead it's throwing an `UnboundLocalError`. #### Steps/Code to Reproduce ```pyth...
diff --git a/textdistance/algorithms/token_based.py b/textdistance/algorithms/token_based.py index d499b84..c6baa5d 100644 --- a/textdistance/algorithms/token_based.py +++ b/textdistance/algorithms/token_based.py @@ -46,16 +46,15 @@ class Jaccard(_BaseSimilarity): def __call__(self, *sequences: Sequence) -> floa...
["tests/test_common.py::test_normalization_range[alg10]", "tests/test_common.py::test_normalization_range[alg16]", "tests/test_common.py::test_normalization_by_one[alg10]", "tests/test_common.py::test_normalization_by_one[alg16]", "tests/test_common.py::test_normalization_same[alg0]", "tests/test_common.py::test_normal...
["tests/test_common.py::test_normalization_range[alg0]", "tests/test_common.py::test_normalization_range[alg1]", "tests/test_common.py::test_normalization_range[alg2]", "tests/test_common.py::test_normalization_range[alg3]", "tests/test_common.py::test_normalization_range[alg4]", "tests/test_common.py::test_normalizati...
jyangballin/swesmith.x86_64.life4_1776_textdistance.c3aca916
true
null
1
28
26
857
0
0.6
1
0.75
1
0.236167
80.9835
7,008
swe_smith::train::20077
swe_smith
train
20,077
kurtmckee__feedparser.cad965a3.func_pm_op_swap__51nnz0f2
swesmith/kurtmckee__feedparser.cad965a3
kurtmckee/feedparser
python
null
DOCTYPE replacement generates malformed XML when entities are present #### Description When parsing RSS feeds that contain DOCTYPE declarations with entities, the `replace_doctype` function produces malformed XML output. The entity declarations are being concatenated in the wrong order, resulting in invalid DOCTYPE s...
diff --git a/feedparser/sanitizer.py b/feedparser/sanitizer.py index f9b50e2..ffabaff 100644 --- a/feedparser/sanitizer.py +++ b/feedparser/sanitizer.py @@ -916,7 +916,7 @@ RE_DOCTYPE_PATTERN = re.compile(rb"^\s*<!DOCTYPE([^>]*?)>", re.MULTILINE) RE_SAFE_ENTITY_PATTERN = re.compile(rb'\s+(\w+)\s+"(&#\w+;|[^&"]*)"') ...
["tests/test_well_formed.py::test_strict_parser[info1619]"]
["tests/test_temporary_behavior.py::test_issue_328_fallback_behavior", "tests/test_make_safe_absolute_uri.py::test_catch_value_error[http://bad]test/]", "tests/test_feedparser_dict.py::test_single_mapping_target_2", "tests/test_feedparser_dict.py::test_license", "tests/test_feedparser_dict.py::test_category", "tests/te...
jyangballin/swesmith.x86_64.kurtmckee_1776_feedparser.cad965a3
true
null
1
8
1
1,257
0
0.6
1
0.75
1
0.236167
80.9835
7,009
swe_smith::train::19466
swe_smith
train
19,466
seperman__deepdiff.ed252022.lm_rewrite__220a8wgp
swesmith/seperman__deepdiff.ed252022
seperman/deepdiff
python
null
### Issue: Unexpected Behavior in DeepHash Attribute Handling #### Description It seems there's an issue with how `DeepHash` handles certain attributes. After a recent change, the behavior of the `DeepHash` class when processing specific attributes has become inconsistent, leading to unexpected results. #### Steps t...
diff --git a/deepdiff/deephash.py b/deepdiff/deephash.py index 1f293bd..255f93c 100644 --- a/deepdiff/deephash.py +++ b/deepdiff/deephash.py @@ -294,14 +294,11 @@ class DeepHash(Base): or a dictionary of objects to the count of items that went to build them. extract_index=0 for hashes and extract_inde...
["tests/test_hash.py::TestDeepHash::test_bad_attribute", "tests/test_hash.py::TestDeepHashPrep::test_bad_attribute_prep"]
["tests/test_anyset.py::TestAnySet::test_anyset_init1", "tests/test_anyset.py::TestAnySet::test_anyset_init2", "tests/test_anyset.py::TestAnySet::test_anyset_init3_add", "tests/test_anyset.py::TestAnySet::test_anyset_pop1", "tests/test_anyset.py::TestAnySet::test_iter_anyset", "tests/test_cache.py::TestCache::test_cach...
jyangballin/swesmith.x86_64.seperman_1776_deepdiff.ed252022
true
null
1
7
2
1,277
0
0.6
1
0.75
1
0.236167
80.9835
7,010
swe_smith::train::42822
swe_smith
train
42,822
python-jsonschema__jsonschema.93e0caa5.lm_rewrite__drqoe0tx
swesmith/python-jsonschema__jsonschema.93e0caa5
python-jsonschema/jsonschema
python
null
### Issue with `dependentRequired` Validation #### Current Problem It seems that the `dependentRequired` keyword is not functioning as expected. When a property is present in an instance, its dependencies are not being correctly validated. This results in missing dependencies not being flagged as errors. #### Steps ...
diff --git a/jsonschema/_keywords.py b/jsonschema/_keywords.py index f30f954..bc71fde 100644 --- a/jsonschema/_keywords.py +++ b/jsonschema/_keywords.py @@ -241,18 +241,17 @@ def maxLength(validator, mL, instance, schema): def dependentRequired(validator, dependentRequired, instance, schema): + """TODO: Impleme...
["jsonschema/tests/test_validators.py::TestValidationErrorMessages::test_dependentRequired"]
["jsonschema/tests/test_cli.py::TestCLI::test_custom_error_format", "jsonschema/tests/test_cli.py::TestCLI::test_custom_error_format_applies_to_schema_errors", "jsonschema/tests/test_cli.py::TestCLI::test_instance_does_not_exist", "jsonschema/tests/test_cli.py::TestCLI::test_instance_does_not_exist_pretty_output", "jso...
jyangballin/swesmith.x86_64.python-jsonschema_1776_jsonschema.93e0caa5
true
null
1
17
1
1,077
0
0.6
1
0.75
1
0.236167
80.9835
7,011
swe_smith::train::44552
swe_smith
train
44,552
pydata__patsy.a5d16484.pr_140
swesmith/pydata__patsy.a5d16484
pydata/patsy
python
null
ImportError with collections.Mapping on Python 3.10+ #### Description When using patsy on Python 3.10 or later, importing the library fails with an ImportError related to `collections.Mapping`. The issue occurs because `collections.Mapping` was deprecated in Python 3.3 and removed in Python 3.10, but the code is tryi...
diff --git a/patsy/constraint.py b/patsy/constraint.py index 6c04414..b77c410 100644 --- a/patsy/constraint.py +++ b/patsy/constraint.py @@ -9,10 +9,7 @@ __all__ = ["LinearConstraint"] import re -try: - from collections.abc import Mapping -except ImportError: - from collections import Mapping +from collectio...
["patsy/build.py::test__max_allowed_dim", "patsy/build.py::test__eval_factor_numerical", "patsy/build.py::test__eval_factor_categorical", "patsy/build.py::test__column_combinations", "patsy/build.py::test__subterm_column_names_iter_and__build_subterm", "patsy/build.py::test__factors_memorize", "patsy/build.py::test__ex...
[]
jyangballin/swesmith.x86_64.pydata_1776_patsy.a5d16484
true
null
2
13
147
1,156
0
0.6
1
0.75
1
0.236
80.983
7,012
swe_smith::train::52403
swe_smith
train
52,403
pydicom__pydicom.7d361b3d.func_pm_ctrl_shuffle__3l6bgwvw
swesmith/pydicom__pydicom.7d361b3d
pydicom/pydicom
python
null
NameError when using convert_pixel_data with handler names #### Description When calling `convert_pixel_data()` or `decompress()` with a handler name, a `NameError` is raised because the variable `tsyntax` is referenced before being defined. #### Steps/Code to Reproduce ```python import pydicom from pydicom.data im...
diff --git a/src/pydicom/dataset.py b/src/pydicom/dataset.py index e7abffd..789deaf 100644 --- a/src/pydicom/dataset.py +++ b/src/pydicom/dataset.py @@ -1750,26 +1750,13 @@ class Dataset: self._convert_pixel_data_without_handler() def _convert_pixel_data_using_handler(self, name: str) -> None: -...
["tests/test_pillow_pixel_data.py::TestNoNumpy_NoPillowHandler::test_using_pillow_handler_raises"]
["tests/pixels/test_common.py::TestRunnerBase::test_init", "tests/pixels/test_common.py::TestRunnerBase::test_del_option", "tests/pixels/test_common.py::TestRunnerBase::test_option_properties", "tests/pixels/test_common.py::TestRunnerBase::test_planar_configuration", "tests/pixels/test_common.py::TestRunnerBase::test_s...
jyangballin/swesmith.x86_64.pydicom_1776_pydicom.7d361b3d
true
null
1
27
1
876
0
0.6
1
0.75
1
0.236
80.983
7,013
swe_smith::train::43734
swe_smith
train
43,734
sloria__environs.73c372df.pr_320
swesmith/sloria__environs.73c372df
sloria/environs
python
null
NameError when accessing environment variables with default values #### Description It seems there's an issue when trying to access environment variables with default values using the `environs` library. The problem arises when attempting to retrieve a variable that isn't set in the environment, and a default value is...
diff --git a/src/environs/__init__.py b/src/environs/__init__.py index 00f6072..b4206c4 100644 --- a/src/environs/__init__.py +++ b/src/environs/__init__.py @@ -96,6 +96,9 @@ class ParserConflictError(ValueError): """ +_SUPPORTS_LOAD_DEFAULT = ma.__version_info__ >= (3, 13) + + def _field2method( field_o...
["tests/test_environs.py::TestCasting::test_call", "tests/test_environs.py::TestCasting::test_call_with_default", "tests/test_environs.py::TestCasting::test_basic", "tests/test_environs.py::TestCasting::test_empty_str", "tests/test_environs.py::TestCasting::test_int_cast", "tests/test_environs.py::TestCasting::test_inv...
["tests/test_environs.py::TestCasting::test_enum_cast", "tests/test_environs.py::TestCasting::test_enum_cast_ignore_case", "tests/test_environs.py::TestCasting::test_invalid_enum", "tests/test_environs.py::TestCasting::test_invalid_enum_ignore_case", "tests/test_environs.py::TestCasting::test_enum_default", "tests/test...
jyangballin/swesmith.x86_64.sloria_1776_environs.73c372df
true
null
1
21
78
996
0
0.6
1
0.75
1
0.236
80.983
7,014
swe_smith::train::1043
swe_smith
train
1,043
jd__tenacity.0d40e76f.combine_file__cuo9gg46
swesmith/jd__tenacity.0d40e76f
jd/tenacity
python
null
stop_after_attempt and stop_after_delay conditions trigger one attempt too late #### Description The stop conditions `stop_after_attempt` and `stop_after_delay` are not stopping at the correct attempt/time. They appear to be allowing one extra attempt beyond what should be the maximum. #### Steps/Code to Reproduce ...
diff --git a/tenacity/stop.py b/tenacity/stop.py index 5cda59a..e6f0814 100644 --- a/tenacity/stop.py +++ b/tenacity/stop.py @@ -88,7 +88,7 @@ class stop_after_attempt(stop_base): self.max_attempt_number = max_attempt_number def __call__(self, retry_state: "RetryCallState") -> bool: - return retr...
["tests/test_asyncio.py::TestContextManager::test_do_max_attempts", "tests/test_asyncio.py::TestContextManager::test_sleeps", "tests/test_asyncio.py::TestDecoratorWrapper::test_retry_function_attributes", "tests/test_tenacity.py::TestStopConditions::test_stop_after_attempt", "tests/test_tenacity.py::TestStopConditions:...
["tests/test_after.py::TestAfterLogFormat::test_01_default", "tests/test_after.py::TestAfterLogFormat::test_02_custom_sec_format", "tests/test_asyncio.py::TestAsyncio::test_attempt_number_is_correct_for_interleaved_coroutines", "tests/test_asyncio.py::TestAsyncio::test_iscoroutinefunction", "tests/test_asyncio.py::Test...
jyangballin/swesmith.x86_64.jd_1776_tenacity.0d40e76f
true
null
1
6
25
1,296
0
0.6
1
0.75
1
0.236
80.983
7,015
swe_smith::train::47903
swe_smith
train
47,903
sqlfluff__sqlfluff.50a1c4b6.func_basic__hxfusrrn
swesmith/sqlfluff__sqlfluff.50a1c4b6
sqlfluff/sqlfluff
python
null
SQLLintError constructor arguments swapped causing incorrect error handling #### Description When creating SQLLintError instances, the segment and rule arguments appear to be swapped internally, causing incorrect error handling and potentially breaking serialization/deserialization of lint errors. #### Steps/Code to...
diff --git a/src/sqlfluff/core/errors.py b/src/sqlfluff/core/errors.py index db964c5..b7f89eb 100644 --- a/src/sqlfluff/core/errors.py +++ b/src/sqlfluff/core/errors.py @@ -264,18 +264,18 @@ class SQLLintError(SQLBaseError): rule: "BaseRule", fixes: Optional[List["LintFix"]] = None, ignore: b...
["test/core/errors_test.py::test__lint_error_pickle[True]", "test/core/errors_test.py::test__lint_error_pickle[False]"]
["test/core/errors_test.py::test__lex_error_pickle[True]", "test/core/errors_test.py::test__lex_error_pickle[False]", "test/core/errors_test.py::test__parse_error_pickle[True]", "test/core/errors_test.py::test__parse_error_pickle[False]"]
jyangballin/swesmith.x86_64.sqlfluff_1776_sqlfluff.50a1c4b6
true
null
1
16
2
1,096
0
0.6
1
0.75
1
0.236
80.983
7,016
swe_smith::train::36445
swe_smith
train
36,445
lincolnloop__python-qrcode.456b01d4.combine_file__47m1l8q8
swesmith/lincolnloop__python-qrcode.456b01d4
lincolnloop/python-qrcode
python
null
QR code image generation fails with TypeError when using image factories #### Description When generating QR codes using various image factories (PIL, SVG, PNG), the code throws TypeErrors related to incorrect parameter passing and method calls. This affects basic QR code generation functionality across different out...
diff --git a/qrcode/image/base.py b/qrcode/image/base.py index 4e8468b..7af1a2c 100644 --- a/qrcode/image/base.py +++ b/qrcode/image/base.py @@ -22,12 +22,12 @@ class BaseImage: needs_drawrect = True def __init__(self, border, width, box_size, *args, **kwargs): - self.border = border - self.wi...
["qrcode/tests/test_qrcode_pil.py::test_render_styled_Image", "qrcode/tests/test_qrcode_pil.py::test_render_styled_with_embeded_image", "qrcode/tests/test_qrcode_pil.py::test_render_styled_with_embeded_image_path", "qrcode/tests/test_qrcode_pil.py::test_render_styled_with_mask[mask0]", "qrcode/tests/test_qrcode_pil.py:...
["qrcode/tests/test_example.py::test_example", "qrcode/tests/test_qrcode.py::test_basic", "qrcode/tests/test_qrcode.py::test_large", "qrcode/tests/test_qrcode.py::test_invalid_version", "qrcode/tests/test_qrcode.py::test_invalid_border", "qrcode/tests/test_qrcode.py::test_overflow", "qrcode/tests/test_qrcode.py::test_a...
jyangballin/swesmith.x86_64.lincolnloop_1776_python-qrcode.456b01d4
true
null
1
12
19
1,175
0
0.6
1
0.75
1
0.235833
80.9825
7,017
swe_smith::train::35346
swe_smith
train
35,346
alecthomas__voluptuous.a7a55f83.func_pm_class_rm_funcs__jk97ivcz
swesmith/alecthomas__voluptuous.a7a55f83
alecthomas/voluptuous
python
null
Length validator broken after recent changes #### Description The `Length` validator is completely broken and cannot be instantiated. When trying to create a `Length` validator with min/max parameters, it throws a `TypeError` saying it takes no arguments. #### Steps/Code to Reproduce ```python from voluptuous impor...
diff --git a/voluptuous/validators.py b/voluptuous/validators.py index 3f026b1..ccd916f 100644 --- a/voluptuous/validators.py +++ b/voluptuous/validators.py @@ -736,36 +736,9 @@ class Clamp(object): class Length(object): """The length of a value must be in a certain range.""" - def __init__( - self, -...
["voluptuous/tests/tests.py::test_nested_multiple_validation_errors", "voluptuous/tests/tests.py::test_fix_157", "voluptuous/tests/tests.py::test_length_ok", "voluptuous/tests/tests.py::test_length_too_short", "voluptuous/tests/tests.py::test_length_too_long", "voluptuous/tests/tests.py::test_length_invalid", "voluptuo...
["voluptuous/tests/tests.md::tests.md", "voluptuous/tests/tests.py::test_new_required_test", "voluptuous/tests/tests.py::test_exact_sequence", "voluptuous/tests/tests.py::test_required", "voluptuous/tests/tests.py::test_extra_with_required", "voluptuous/tests/tests.py::test_iterate_candidates", "voluptuous/tests/tests....
jyangballin/swesmith.x86_64.alecthomas_1776_voluptuous.a7a55f83
true
null
1
27
8
875
0
0.6
1
0.75
1
0.235833
80.9825
7,018
swe_smith::train::19087
swe_smith
train
19,087
seperman__deepdiff.ed252022.func_pm_ctrl_shuffle__ctmwhbu8
swesmith/seperman__deepdiff.ed252022
seperman/deepdiff
python
null
DeepHash._get_objects_to_hashes_dict returns None instead of dictionary #### Description When calling methods that rely on `_get_objects_to_hashes_dict`, the function returns `None` instead of the expected dictionary containing object-to-hash mappings. #### Steps/Code to Reproduce ```python from deepdiff import Dee...
diff --git a/deepdiff/deephash.py b/deepdiff/deephash.py index 1f293bd..6575526 100644 --- a/deepdiff/deephash.py +++ b/deepdiff/deephash.py @@ -289,19 +289,18 @@ class DeepHash(Base): return result def _get_objects_to_hashes_dict(self, extract_index=0): - """ - A dictionary containing onl...
["tests/test_diff_other.py::TestDiffOther::test_multi_processing3_deephash", "tests/test_hash.py::TestDeepHash::test_deephash_repr", "tests/test_hash.py::TestDeepHash::test_bad_attribute", "tests/test_hash.py::TestDeepHashPrep::test_prep_bool_vs_num1", "tests/test_hash.py::TestDeepHashPrep::test_prep_str", "tests/test_...
["tests/test_anyset.py::TestAnySet::test_anyset_init1", "tests/test_anyset.py::TestAnySet::test_anyset_init2", "tests/test_anyset.py::TestAnySet::test_anyset_init3_add", "tests/test_anyset.py::TestAnySet::test_anyset_pop1", "tests/test_anyset.py::TestAnySet::test_iter_anyset", "tests/test_cache.py::TestCache::test_cach...
jyangballin/swesmith.x86_64.seperman_1776_deepdiff.ed252022
true
null
1
13
23
1,155
0
0.6
1
0.75
1
0.235833
80.9825
7,019
swe_smith::train::24272
swe_smith
train
24,272
sunpy__sunpy.f8edfd5c.func_pm_remove_assign__tu1unjlr
swesmith/sunpy__sunpy.f8edfd5c
sunpy/sunpy
python
null
#### Description The `solar_wcs_frame_mapping` function in `sunpy.coordinates.wcs_utils` is raising `UnboundLocalError` and `NameError` exceptions when trying to access variables that are no longer defined. #### Steps/Code to Reproduce ```python import sunpy from sunpy.coordinates.wcs_utils import solar_wcs_frame_ma...
diff --git a/sunpy/coordinates/wcs_utils.py b/sunpy/coordinates/wcs_utils.py index 72706d7..2d52b57 100644 --- a/sunpy/coordinates/wcs_utils.py +++ b/sunpy/coordinates/wcs_utils.py @@ -36,8 +36,6 @@ def solar_wcs_frame_mapping(wcs): if hasattr(wcs, "coordinate_frame"): return wcs.coordinate_frame - d...
["sunpy/coordinates/tests/test_wcs_utils.py::test_wcs_frame_mapping[ctype0-Helioprojective]", "sunpy/coordinates/tests/test_wcs_utils.py::test_wcs_frame_mapping[ctype1-Helioprojective]", "sunpy/coordinates/tests/test_wcs_utils.py::test_wcs_frame_mapping[ctype2-HeliographicStonyhurst]", "sunpy/coordinates/tests/test_wcs...
["sunpy/coordinates/tests/test_wcs_utils.py::test_non_sunpy_frame_to_wcs", "sunpy/coordinates/tests/test_wcs_utils.py::test_attribute_errors", "sunpy/coordinates/tests/test_wcs_utils.py::test_set_wcs_aux", "sunpy/coordinates/tests/test_wcs_utils.py::test_self_observer", "sunpy/coordinates/tests/test_wcs_utils.py::test_...
jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c
true
null
1
16
14
1,095
0
0.6
1
0.75
1
0.235833
80.9825
7,020
swe_smith::train::24089
swe_smith
train
24,089
sunpy__sunpy.f8edfd5c.func_pm_ctrl_shuffle__um3yece8
swesmith/sunpy__sunpy.f8edfd5c
sunpy/sunpy
python
null
HECClient initialization fails with UnboundLocalError when SSL error occurs #### Description When creating a HECClient instance and an SSL error occurs during initialization, the code raises an `UnboundLocalError: cannot access local variable 'session' where it is not associated with a value` instead of properly hand...
diff --git a/sunpy/net/helio/hec.py b/sunpy/net/helio/hec.py index 8b84536..cd0da7b 100644 --- a/sunpy/net/helio/hec.py +++ b/sunpy/net/helio/hec.py @@ -67,6 +67,16 @@ class HECClient(BaseClient): """ def __init__(self, link=None): + transport = Transport(session=session) + if link is None: + ...
["sunpy/net/helio/tests/test_helio.py::test_ssl_verify_error"]
["sunpy/net/helio/tests/test_helio.py::test_webservice_parser_no_content", "sunpy/net/helio/tests/test_helio.py::test_webservice_parser_get_links", "sunpy/net/helio/tests/test_helio.py::test_endpoint_parser_no_content", "sunpy/net/helio/tests/test_helio.py::test_endpoint_parser_get_links", "sunpy/net/helio/tests/test_h...
jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c
true
null
1
23
1
955
0
0.6
1
0.75
1
0.235833
80.9825
7,021
swe_smith::train::28214
swe_smith
train
28,214
Mimino666__langdetect.a1598f1a.combine_module__pej2hdb4
swesmith/Mimino666__langdetect.a1598f1a
mimino666/langdetect
python
null
NGram initialization breaks n-gram extraction #### Description The NGram class initialization is causing issues with n-gram extraction. When creating a new NGram instance, the internal state is not properly initialized, leading to IndexError when trying to extract n-grams. #### Steps/Code to Reproduce ```python fro...
diff --git a/langdetect/utils/lang_profile.py b/langdetect/utils/lang_profile.py index 118cff8..5431c9e 100644 --- a/langdetect/utils/lang_profile.py +++ b/langdetect/utils/lang_profile.py @@ -17,42 +17,42 @@ class LangProfile(object): def __init__(self, name=None, freq=None, n_words=None): self.freq = de...
["langdetect/tests/test_detector.py::DetectorTest::test_detector1", "langdetect/tests/test_detector.py::DetectorTest::test_detector2", "langdetect/tests/test_detector.py::DetectorTest::test_detector3", "langdetect/tests/test_detector.py::DetectorTest::test_detector4", "langdetect/tests/test_detector.py::DetectorTest::t...
["langdetect/tests/test_detector.py::DetectorTest::test_lang_list", "langdetect/tests/test_language.py::LanguageTest::test_cmp", "langdetect/tests/test_language.py::LanguageTest::test_language", "langdetect/tests/utils/test_lang_profile.py::LangProfileText::test_add", "langdetect/tests/utils/test_lang_profile.py::LangP...
jyangballin/swesmith.x86_64.mimino666_1776_langdetect.a1598f1a
true
null
2
30
9
815
0
0.6
1
0.75
1
0.235833
80.9825
7,022
swe_smith::train::47160
swe_smith
train
47,160
python-trio__trio.cfbbe2c1.func_pm_ctrl_shuffle__u1y6t4pe
swesmith/python-trio__trio.cfbbe2c1
python-trio/trio
python
null
RunVar.reset() validation checks execute in wrong order #### Description The `RunVar.reset()` method has validation checks that execute in the wrong order, causing some error conditions to not be properly detected. #### Steps/Code to Reproduce ```python import trio from trio._core._local import RunVar async def ma...
diff --git a/src/trio/_core/_local.py b/src/trio/_core/_local.py index fff1234..2bb10e9 100644 --- a/src/trio/_core/_local.py +++ b/src/trio/_core/_local.py @@ -76,20 +76,15 @@ class RunVar(Generic[T]): return token def reset(self, token: RunVarToken[T]) -> None: - """Resets the value of this :cl...
["src/trio/_core/_tests/test_local.py::test_runvar_resetting"]
["src/trio/_core/_tests/test_asyncgen.py::test_asyncgen_basics", "src/trio/_core/_tests/test_asyncgen.py::test_asyncgen_throws_during_finalization", "src/trio/_core/_tests/test_asyncgen.py::test_firstiter_after_closing", "src/trio/_core/_tests/test_asyncgen.py::test_interdependent_asyncgen_cleanup_order", "src/trio/_co...
jyangballin/swesmith.x86_64.python-trio_1776_trio.cfbbe2c1
true
null
1
19
1
1,035
0
0.6
1
0.75
1
0.235833
80.9825
7,023
swe_smith::train::27090
swe_smith
train
27,090
tkrajina__gpxpy.09fc46b3.func_pm_class_rm_funcs__3rlllb62
swesmith/tkrajina__gpxpy.09fc46b3
tkrajina/gpxpy
python
null
GPXTrack missing add_elevation method #### Description When trying to adjust elevation data on a GPX track, the `add_elevation` method is not available on `GPXTrack` objects. #### Steps/Code to Reproduce ```python import gpxpy # Create a simple GPX track with elevation data gpx = gpxpy.GPX() track = gpxpy.GPXTrack...
diff --git a/gpxpy/gpx.py b/gpxpy/gpx.py index 73e2024..d6e66aa 100644 --- a/gpxpy/gpx.py +++ b/gpxpy/gpx.py @@ -1473,16 +1473,6 @@ class GPXTrack: for segment in self.segments: segment.remove_elevation() - def remove_empty(self) -> None: - """ Removes empty segments in track """ - ...
["test.py::GPXTests::test_add_elevation"]
["test.py::GPXTests::test_10_to_11_conversion", "test.py::GPXTests::test_add_missing_data_no_intervals", "test.py::GPXTests::test_add_missing_data_one_interval", "test.py::GPXTests::test_add_missing_data_one_interval_and_empty_points_on_start_and_end", "test.py::GPXTests::test_add_missing_elevations", "test.py::GPXTest...
jyangballin/swesmith.x86_64.tkrajina_1776_gpxpy.09fc46b3
true
null
1
23
1
955
0
0.6
1
0.75
1
0.235833
80.9825
7,024
swe_smith::train::39442
swe_smith
train
39,442
pallets__jinja.ada0a9a6.func_pm_ctrl_shuffle__gyqzeyzv
swesmith/pallets__jinja.ada0a9a6
pallets/jinja
python
null
NativeEnvironment templates raise UnboundLocalError when rendering #### Description When using Jinja2's NativeEnvironment, template rendering fails with `UnboundLocalError: local variable 'head' referenced before assignment`. This affects all native template rendering operations. #### Steps/Code to Reproduce ```pyt...
diff --git a/src/jinja2/nativetypes.py b/src/jinja2/nativetypes.py index 71db8cc..8b0e33d 100644 --- a/src/jinja2/nativetypes.py +++ b/src/jinja2/nativetypes.py @@ -14,18 +14,6 @@ from .environment import Template def native_concat(values: t.Iterable[t.Any]) -> t.Optional[t.Any]: - """Return a native Python typ...
["tests/test_async.py::test_native_async[asyncio]", "tests/test_async.py::test_native_async[trio]", "tests/test_async.py::test_native_list_async[asyncio]", "tests/test_async.py::test_native_list_async[trio]", "tests/test_nativetypes.py::test_is_defined_native_return", "tests/test_nativetypes.py::test_undefined_native_r...
["tests/test_api.py::TestExtendedAPI::test_item_and_attribute", "tests/test_api.py::TestExtendedAPI::test_finalize", "tests/test_api.py::TestExtendedAPI::test_finalize_constant_expression", "tests/test_api.py::TestExtendedAPI::test_no_finalize_template_data", "tests/test_api.py::TestExtendedAPI::test_context_finalize",...
jyangballin/swesmith.x86_64.pallets_1776_jinja.ada0a9a6
true
null
1
23
25
955
0
0.6
1
0.75
1
0.235833
80.9825
7,025
swe_smith::train::29541
swe_smith
train
29,541
django__channels.a144b4b8.combine_file__dx22prxz
swesmith/django__channels.a144b4b8
django/channels
python
null
Channel layer manager returns None instead of backend when accessing configured layers #### Description When accessing a configured channel layer through the channel layer manager, it returns `None` instead of the expected backend instance. This breaks channel layer functionality across the application. #### Steps/C...
diff --git a/channels/layers.py b/channels/layers.py index 5fc53f7..df7c4a1 100644 --- a/channels/layers.py +++ b/channels/layers.py @@ -34,7 +34,7 @@ class ChannelLayerManager: @property def configs(self): # Lazy load settings so we can be imported - return getattr(settings, "CHANNEL_LAYERS",...
["tests/test_generic_websocket.py::test_websocket_consumer_groups", "tests/test_generic_websocket.py::test_async_websocket_consumer_groups", "tests/test_generic_websocket.py::test_async_websocket_consumer_specific_channel_layer", "tests/test_generic_websocket.py::test_block_underscored_type_function_call", "tests/test_...
["tests/test_database.py::ConnectionClosingTests::test_http", "tests/test_database.py::ConnectionClosingTests::test_websocket", "tests/test_generic_websocket.py::test_websocket_consumer", "tests/test_generic_websocket.py::test_multiple_websocket_consumers_with_sessions", "tests/test_generic_websocket.py::test_websocket...
jyangballin/swesmith.x86_64.django_1776_channels.a144b4b8
true
null
1
12
23
1,174
0
0.6
1
0.75
1
0.235667
80.982
7,026
swe_smith::train::26107
swe_smith
train
26,107
pylint-dev__astroid.b114f6b5.func_basic__y01tftjf
swesmith/pylint-dev__astroid.b114f6b5
pylint-dev/astroid
python
null
Compare operations return raw boolean values instead of Const nodes #### Description When inferring comparison operations, the Compare node's infer method is returning raw Python boolean values instead of properly wrapped Const nodes. This causes AttributeError when trying to access the `.value` attribute on the infe...
diff --git a/astroid/nodes/node_classes.py b/astroid/nodes/node_classes.py index fde3239..6099de1 100644 --- a/astroid/nodes/node_classes.py +++ b/astroid/nodes/node_classes.py @@ -1919,22 +1919,20 @@ class Compare(NodeNG): ops = self.ops left_node = self.left lhs = list(left_node.infer(conte...
["tests/test_inference.py::test_compare[<-False]", "tests/test_inference.py::test_compare[<=-True]", "tests/test_inference.py::test_compare[==-True]", "tests/test_inference.py::test_compare[>=-True]", "tests/test_inference.py::test_compare[>-False]", "tests/test_inference.py::test_compare[!=-False]", "tests/test_infere...
["tests/brain/numpy/test_core_einsumfunc.py::test_numpy_function_calls_inferred_as_ndarray", "tests/brain/numpy/test_core_einsumfunc.py::test_function_parameters", "tests/brain/numpy/test_core_fromnumeric.py::BrainNumpyCoreFromNumericTest::test_numpy_function_calls_inferred_as_ndarray", "tests/brain/numpy/test_core_fun...
jyangballin/swesmith.x86_64.pylint-dev_1776_astroid.b114f6b5
true
null
1
12
34
1,174
0
0.6
1
0.75
1
0.235667
80.982
7,027
swe_smith::train::12086
swe_smith
train
12,086
lepture__mistune.bf54ef67.combine_file__m123kz6d
swesmith/lepture__mistune.bf54ef67
lepture/mistune
python
null
Table plugin broken after recent changes #### Description The table plugin seems to be completely broken. When trying to parse markdown tables, I'm getting AttributeError exceptions instead of proper table rendering. #### Steps/Code to Reproduce ```python import mistune # Simple table markdown text = ''' | Header ...
diff --git a/src/mistune/plugins/table.py b/src/mistune/plugins/table.py index 39e81f9..680a36b 100644 --- a/src/mistune/plugins/table.py +++ b/src/mistune/plugins/table.py @@ -46,25 +46,24 @@ def parse_table( pos = m.end() header = m.group('table_head') align = m.group('table_align') - thead, aligns ...
["tests/test_plugins.py::TestPlugin1_table::test_align_table_001", "tests/test_plugins.py::TestPlugin1_table::test_align_table_002", "tests/test_plugins.py::TestPlugin1_table::test_misc_table_001", "tests/test_plugins.py::TestPlugin1_table::test_misc_table_002", "tests/test_plugins.py::TestPlugin1_table::test_misc_tabl...
["tests/test_commonmark.py::TestCommonMark::test_atx_headings_062", "tests/test_commonmark.py::TestCommonMark::test_atx_headings_063", "tests/test_commonmark.py::TestCommonMark::test_atx_headings_064", "tests/test_commonmark.py::TestCommonMark::test_atx_headings_065", "tests/test_commonmark.py::TestCommonMark::test_atx...
jyangballin/swesmith.x86_64.lepture_1776_mistune.bf54ef67
true
null
1
23
20
953
0
0.6
1
0.75
1
0.2355
80.9815
7,028
swe_smith::train::36167
swe_smith
train
36,167
facelessuser__soupsieve.a8080d97.combine_file__9n0vmn3t
swesmith/facelessuser__soupsieve.a8080d97
facelessuser/soupsieve
python
null
String case conversion broken for uppercase letters #### Description The `lower()` function in `soupsieve/util.py` is not correctly converting uppercase letters to lowercase. This affects CSS selector parsing when case-insensitive matching is expected. #### Steps/Code to Reproduce ```python import soupsieve as sv ...
diff --git a/soupsieve/util.py b/soupsieve/util.py index 9b2e64d..dcb7195 100644 --- a/soupsieve/util.py +++ b/soupsieve/util.py @@ -20,7 +20,7 @@ def lower(string: str) -> str: new_string = [] for c in string: o = ord(c) - new_string.append(chr(o + 32) if UC_A <= o <= UC_Z else c) + ne...
["tests/test_api.py::TestSyntaxErrorReporting::test_syntax_error_has_text_and_position", "tests/test_api.py::TestSyntaxErrorReporting::test_syntax_error_on_third_line", "tests/test_api.py::TestSyntaxErrorReporting::test_syntax_error_with_multiple_lines", "tests/test_extra/test_custom.py::TestCustomSelectors::test_custo...
["tests/test_api.py::TestSoupSieve::test_cache", "tests/test_api.py::TestSoupSieve::test_closest_match_complex_parent", "tests/test_api.py::TestSoupSieve::test_closest_match_parent", "tests/test_api.py::TestSoupSieve::test_closest_match_self", "tests/test_api.py::TestSoupSieve::test_closest_must_be_parent", "tests/test...
jyangballin/swesmith.x86_64.facelessuser_1776_soupsieve.a8080d97
true
null
1
26
15
893
0
0.6
1
0.75
1
0.2355
80.9815
7,029
swe_smith::train::32396
swe_smith
train
32,396
pydantic__pydantic.acb0f10f.combine_file__y6jgl9pw
swesmith/pydantic__pydantic.acb0f10f
pydantic/pydantic
python
null
Pydantic dataclass kw_only fields not working on Python 3.10+ #### Description When using `kw_only=True` fields in pydantic dataclasses on Python 3.10+, the keyword-only behavior is not enforced. Fields that should be keyword-only can still be passed as positional arguments. #### Steps/Code to Reproduce ```python i...
diff --git a/pydantic/dataclasses.py b/pydantic/dataclasses.py index 5111bc3..878e0d5 100644 --- a/pydantic/dataclasses.py +++ b/pydantic/dataclasses.py @@ -103,8 +103,8 @@ def dataclass( eq: bool = True, order: bool = False, unsafe_hash: bool = False, - frozen: bool | None = None, - config: Config...
["tests/benchmarks/test_model_schema_generation.py::test_construct_dataclass_schema", "tests/test_config.py::test_config_dataclass_defer_build[True]", "tests/test_config.py::test_dataclass_defer_build_override_on_rebuild_dataclass", "tests/test_dataclasses.py::test_cyclic_reference_dataclass", "tests/test_dataclasses.p...
["tests/benchmarks/test_attribute_access.py::test_setattr", "tests/benchmarks/test_attribute_access.py::test_getattr", "tests/benchmarks/test_discriminated_unions.py::test_schema_build", "tests/benchmarks/test_discriminated_unions.py::test_efficiency_with_highly_nested_examples", "tests/benchmarks/test_fastapi_startup_...
jyangballin/swesmith.x86_64.pydantic_1776_pydantic.acb0f10f
true
null
1
17
24
1,073
0
0.6
1
0.75
1
0.2355
80.9815
7,030
swe_smith::train::22675
swe_smith
train
22,675
graphql-python__graphene.82903263.combine_module__9z44e97d
swesmith/graphql-python__graphene.82903263
graphql-python/graphene
python
null
# Decimal type doesn't handle integer values correctly When using the Decimal scalar type in GraphQL queries, it fails to properly handle integer values. The current implementation only accepts string and float values, but not integer values. ## Reproduction ```python import graphene from graphene import Schema, Obj...
diff --git a/graphene/types/decimal.py b/graphene/types/decimal.py index 69952f9..92ffda1 100644 --- a/graphene/types/decimal.py +++ b/graphene/types/decimal.py @@ -22,9 +22,9 @@ class Decimal(Scalar): @classmethod def parse_literal(cls, node, _variables=None): - if isinstance(node, (StringValueNode,...
["examples/starwars/tests/test_query.py::test_check_type_of_luke", "graphene/tests/issues/test_1419.py::test_parse_literal_with_variables[Decimal-\"1.1\"]", "graphene/tests/issues/test_881.py::test_enums_pickling", "graphene/types/tests/test_decimal.py::test_decimal_string_query", "graphene/types/tests/test_decimal.py:...
["examples/starwars/tests/test_query.py::test_hero_name_query", "examples/starwars/tests/test_query.py::test_hero_name_and_friends_query", "examples/starwars/tests/test_query.py::test_nested_query", "examples/starwars/tests/test_query.py::test_fetch_luke_query", "examples/starwars/tests/test_query.py::test_fetch_some_i...
jyangballin/swesmith.x86_64.graphql-python_1776_graphene.82903263
true
null
2
22
9
973
0
0.6
1
0.75
1
0.2355
80.9815
7,031
swe_smith::train::27875
swe_smith
train
27,875
jsvine__pdfplumber.02ff4313.func_pm_ctrl_shuffle__beaxc7rb
swesmith/jsvine__pdfplumber.02ff4313
jsvine/pdfplumber
python
null
UnboundLocalError when using cropped pages #### Description When working with cropped pages, operations that involve bounding box validation are failing with `UnboundLocalError: local variable 'bbox_area' referenced before assignment`. This affects various page operations including cropping, filtering, and table extr...
diff --git a/pdfplumber/page.py b/pdfplumber/page.py index 71330d8..84e77b3 100644 --- a/pdfplumber/page.py +++ b/pdfplumber/page.py @@ -682,9 +682,6 @@ class DerivedPage(Page): def test_proposed_bbox(bbox: T_bbox, parent_bbox: T_bbox) -> None: - bbox_area = utils.calculate_area(bbox) - if bbox_area == 0: - ...
["tests/test_basics.py::Test::test_annots_cropped", "tests/test_basics.py::Test::test_crop_and_filter", "tests/test_basics.py::Test::test_invalid_crops", "tests/test_basics.py::Test::test_outside_bbox", "tests/test_basics.py::Test::test_relative_crop", "tests/test_display.py::Test::test_cropped", "tests/test_issues.py:...
["tests/test_basics.py::Test::test_annots", "tests/test_basics.py::Test::test_annots_rotated", "tests/test_basics.py::Test::test_bad_fileobj", "tests/test_basics.py::Test::test_colors", "tests/test_basics.py::Test::test_load_with_custom_laparams", "tests/test_basics.py::Test::test_loading_fileobj", "tests/test_basics.p...
jyangballin/swesmith.x86_64.jsvine_1776_pdfplumber.02ff4313
true
null
1
7
18
1,273
0
0.6
1
0.75
1
0.2355
80.9815
7,032
swe_smith::train::24345
swe_smith
train
24,345
sunpy__sunpy.f8edfd5c.func_pm_remove_loop__0znbtur5
swesmith/sunpy__sunpy.f8edfd5c
sunpy/sunpy
python
null
TimeSeries factory returns empty list when reading files #### Description When creating a TimeSeries from a file, the factory method returns an empty list instead of properly processing the file data. This affects all TimeSeries sources that rely on the factory's file reading mechanism. #### Steps/Code to Reproduce ...
diff --git a/sunpy/timeseries/timeseries_factory.py b/sunpy/timeseries/timeseries_factory.py index e5f59d1..40c40f7 100644 --- a/sunpy/timeseries/timeseries_factory.py +++ b/sunpy/timeseries/timeseries_factory.py @@ -154,18 +154,11 @@ class TimeSeriesFactory(BasicRegistrationFactory): pairs = read_file...
["sunpy/timeseries/sources/tests/test_eve.py::test_implicit_esp", "sunpy/timeseries/sources/tests/test_fermi_gbm.py::test_implicit_fermi_gbm", "sunpy/timeseries/sources/tests/test_goes.py::test_implicit_goes_satno_missing[/testbed/sunpy/data/test/go1520120601.fits.gz]", "sunpy/timeseries/sources/tests/test_lyra.py::tes...
["sunpy/timeseries/metadata.py::sunpy.timeseries.metadata.TimeSeriesMetaData", "sunpy/timeseries/sources/eve.py::sunpy.timeseries.sources.eve.EVESpWxTimeSeries", "sunpy/timeseries/sources/fermi_gbm.py::sunpy.timeseries.sources.fermi_gbm.GBMSummaryTimeSeries", "sunpy/timeseries/sources/goes.py::sunpy.timeseries.sources....
jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c
true
null
1
7
6
1,273
0
0.6
1
0.75
1
0.2355
80.9815
7,033
swe_smith::train::23967
swe_smith
train
23,967
sunpy__sunpy.f8edfd5c.func_pm_ctrl_shuffle__9xaztntz
swesmith/sunpy__sunpy.f8edfd5c
sunpy/sunpy
python
null
resample function broken - UnboundLocalError for 'offset' variable #### Description The `resample` function in `sunpy.image.resample` is throwing an `UnboundLocalError` when trying to access the `offset` variable. This appears to affect all resampling methods including 'nearest', 'linear', and 'spline'. #### Steps/C...
diff --git a/sunpy/image/resample.py b/sunpy/image/resample.py index c7b72f5..82e7d5e 100644 --- a/sunpy/image/resample.py +++ b/sunpy/image/resample.py @@ -50,18 +50,8 @@ def resample(orig, dimensions, method='linear', center=False, minusone=False): https://scipy-cookbook.readthedocs.io/items/Rebinning.html ...
["sunpy/image/tests/test_resample.py::test_resample_nearest", "sunpy/image/tests/test_resample.py::test_resample_linear", "sunpy/image/tests/test_resample.py::test_resample_spline"]
["sunpy/image/tests/test_resample.py::test_reshape"]
jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c
true
null
1
19
3
1,033
0
0.6
1
0.75
1
0.2355
80.9815
7,034
swe_smith::train::4527
swe_smith
train
4,527
pygments__pygments.27649ebb.func_pm_remove_loop__sbnqpvvu
swesmith/pygments__pygments.27649ebb
pygments/pygments
python
null
Perl6 lexer fails with NameError on nested delimiters #### Description The Perl6 lexer crashes with a `NameError: name 'next_close_pos' is not defined` when processing code that contains nested delimiters in certain constructs. #### Steps/Code to Reproduce ```python from pygments import highlight from pygments.lexe...
diff --git a/pygments/lexers/perl.py b/pygments/lexers/perl.py index 3ec1944..92abc28 100644 --- a/pygments/lexers/perl.py +++ b/pygments/lexers/perl.py @@ -522,20 +522,6 @@ class Perl6Lexer(ExtendedRegexLexer): search_pos = match.start('delimiter') - while nesting_level > 0: - ...
["tests/examplefiles/perl6/RoleQ.pm6::", "tests/examplefiles/perl6/grammar-test.p6::", "tests/examplefiles/perl6/test.p6::"]
["tests/test_rtf_formatter.py::test_hl_linenostart_lines_highlighted", "tests/test_rtf_formatter.py::test_rtf_footer", "tests/test_rtf_formatter.py::test_rtf_header", "tests/test_rtf_formatter.py::test_lineno_color_style_specify_hex", "tests/test_rtf_formatter.py::test_linenos_newline_characters", "tests/test_rtf_forma...
jyangballin/swesmith.x86_64.pygments_1776_pygments.27649ebb
true
null
1
15
3
1,113
0
0.6
1
0.75
1
0.2355
80.9815
7,035
swe_smith::train::4729
swe_smith
train
4,729
bottlepy__bottle.a8dfef30.func_basic__561hzhdd
swesmith/bottlepy__bottle.a8dfef30
bottlepy/bottle
python
null
HTTPError constructor arguments swapped causing unexpected behavior #### Description When creating HTTPError instances, the exception and traceback attributes are being assigned incorrectly, causing unexpected behavior in error handling. #### Steps/Code to Reproduce ```python import bottle import traceback try: ...
diff --git a/bottle.py b/bottle.py index 286b5bc..e6710f1 100755 --- a/bottle.py +++ b/bottle.py @@ -1966,9 +1966,9 @@ class HTTPError(HTTPResponse): body=None, exception=None, traceback=None, **more_headers): - self.exception = exception - self.traceb...
["test/test_auth.py::TestBasicAuth::test__header", "test/test_environ.py::TestRequest::test_chunked", "test/test_environ.py::TestRequest::test_chunked_illegal_size", "test/test_environ.py::TestRequest::test_chunked_meta_fields", "test/test_environ.py::TestRequest::test_chunked_not_chunked_at_all", "test/test_environ.py...
["test/test_app.py::TestApplicationObject::test_setattr", "test/test_config.py::TestConfDict::test_gc_overlays", "test/test_config.py::TestConfDict::test_isadict", "test/test_config.py::TestConfDict::test_load_dict", "test/test_config.py::TestConfDict::test_load_module", "test/test_config.py::TestConfDict::test_meta", ...
jyangballin/swesmith.x86_64.bottlepy_1776_bottle.a8dfef30
true
null
1
6
50
1,292
0
0.6
1
0.75
1
0.235333
80.981
7,036
swe_smith::train::48546
swe_smith
train
48,546
sqlfluff__sqlfluff.50a1c4b6.func_pm_remove_loop__vaz6k5ia
swesmith/sqlfluff__sqlfluff.50a1c4b6
sqlfluff/sqlfluff
python
null
Linter fails to process files when no valid root variant found #### Description When linting SQL files, the linter crashes with an `UnboundLocalError` if no valid root variant can be parsed from the file. The error occurs because the `root_variant` variable is referenced without being properly initialized when all pa...
diff --git a/src/sqlfluff/core/linter/linter.py b/src/sqlfluff/core/linter/linter.py index 5e5474f..5cef83f 100644 --- a/src/sqlfluff/core/linter/linter.py +++ b/src/sqlfluff/core/linter/linter.py @@ -636,14 +636,6 @@ class Linter: # First identify the root variant. That's the first variant # that suc...
["test/core/linter/linter_test.py::test__linter__skip_large_bytes[0-False]", "test/core/linter/linter_test.py::test__linter__skip_large_bytes[2000-False]", "test/core/linter/linter_test.py::test__linter__get_violations_filter_rules[None-6]", "test/core/linter/linter_test.py::test__linter__get_violations_filter_rules[CP...
["test/core/linter/linter_test.py::test__linter__skip_large_bytes[5-True]", "test/core/linter/linter_test.py::test__linter__lint_string_vs_file[test/fixtures/linter/indentation_errors.sql]", "test/core/linter/linter_test.py::test__linter__lint_string_vs_file[test/fixtures/linter/whitespace_errors.sql]", "test/core/lint...
jyangballin/swesmith.x86_64.sqlfluff_1776_sqlfluff.50a1c4b6
true
null
1
9
14
1,232
0
0.6
1
0.75
1
0.235333
80.981
7,037
swe_smith::train::45593
swe_smith
train
45,593
conan-io__conan.86f29e13.combine_module__3q3awrb7
swesmith/conan-io__conan.86f29e13
conan-io/conan
python
null
# Incorrect string formatting in add_millennium function Description There appears to be an issue with the string formatting in the `add_millennium` function in the `conan/tools/build/cppstd.py` file. The function is not correctly formatting the C++ standard version numbers. When trying to use a specific C++ standar...
diff --git a/conan/tools/build/cppstd.py b/conan/tools/build/cppstd.py index 43c3e9d..4a8948c 100644 --- a/conan/tools/build/cppstd.py +++ b/conan/tools/build/cppstd.py @@ -131,7 +131,7 @@ def _check_cppstd(conanfile, cppstd, comparator, gnu_extensions): return str(_cppstd).replace("gnu", "") de...
["test/unittests/client/build/cpp_std_flags_test.py::CompilerFlagsTest::test_gcc_cppstd_flags"]
["test/unittests/client/build/cpp_std_flags_test.py::CompilerFlagsTest::test_apple_clang_cppstd_defaults", "test/unittests/client/build/cpp_std_flags_test.py::CompilerFlagsTest::test_apple_clang_cppstd_flags", "test/unittests/client/build/cpp_std_flags_test.py::CompilerFlagsTest::test_clang_cppstd_defaults", "test/unit...
jyangballin/swesmith.x86_64.conan-io_1776_conan.86f29e13
true
null
2
16
1
1,092
0
0.6
1
0.75
1
0.235333
80.981
7,038
swe_smith::train::9682
swe_smith
train
9,682
marshmallow-code__webargs.dbde72fe.func_basic__plixi7q2
swesmith/marshmallow-code__webargs.dbde72fe
marshmallow-code/webargs
python
null
MultiDictProxy returns incorrect values when key not in multiple_keys #### Description When accessing a key through MultiDictProxy that is not in `multiple_keys`, the proxy returns unexpected wrapped values instead of the original data. #### Steps/Code to Reproduce ```python from webargs.multidictproxy import Multi...
diff --git a/src/webargs/multidictproxy.py b/src/webargs/multidictproxy.py index de9b82b..8621560 100644 --- a/src/webargs/multidictproxy.py +++ b/src/webargs/multidictproxy.py @@ -48,17 +48,17 @@ class MultiDictProxy(MutableMapping): def __getitem__(self, key: str) -> typing.Any: val = self.data.get(ke...
["tests/test_aiohttpparser.py::TestAIOHTTPParser::test_parse_querystring_args", "tests/test_aiohttpparser.py::TestAIOHTTPParser::test_parse_form", "tests/test_aiohttpparser.py::TestAIOHTTPParser::test_parse_json_or_form", "tests/test_aiohttpparser.py::TestAIOHTTPParser::test_parse_querystring_default", "tests/test_aioh...
["tests/test_aiohttpparser.py::TestAIOHTTPParser::test_parse_json", "tests/test_aiohttpparser.py::TestAIOHTTPParser::test_parse_json_missing", "tests/test_aiohttpparser.py::TestAIOHTTPParser::test_parse_json_with_charset", "tests/test_aiohttpparser.py::TestAIOHTTPParser::test_parse_json_with_vendor_media_type", "tests/...
jyangballin/swesmith.x86_64.marshmallow-code_1776_webargs.dbde72fe
true
null
1
16
109
1,092
0
0.6
1
0.75
1
0.235333
80.981
7,039
swe_smith::train::17771
swe_smith
train
17,771
pyasn1__pyasn1.0f07d724.func_basic__ty56pxro
swesmith/pyasn1__pyasn1.0f07d724
pyasn1/pyasn1
python
null
SequenceOf and SetOf components not properly handled with list-based storage #### Description When working with SequenceOf and SetOf types, component access and manipulation fails due to incorrect storage implementation. The internal component storage appears to be using dictionary-based access patterns on what shoul...
diff --git a/pyasn1/type/univ.py b/pyasn1/type/univ.py index 9aff5e6..740649c 100644 --- a/pyasn1/type/univ.py +++ b/pyasn1/type/univ.py @@ -1913,12 +1913,12 @@ class SequenceOfAndSetOfBase(base.ConstructedAsn1Type): componentType = self.componentType if self._componentValues is noValue: - ...
["tests/codec/ber/test_decoder.py::SequenceOfDecoderTestCase::testDefMode", "tests/codec/ber/test_decoder.py::SequenceOfDecoderTestCase::testDefModeChunked", "tests/codec/ber/test_decoder.py::SequenceOfDecoderTestCase::testIndefMode", "tests/codec/ber/test_decoder.py::SequenceOfDecoderTestCase::testIndefModeChunked", "...
["tests/codec/ber/test_decoder.py::LargeTagDecoderTestCase::testLargeTag", "tests/codec/ber/test_decoder.py::LargeTagDecoderTestCase::testLongTag", "tests/codec/ber/test_decoder.py::LargeTagDecoderTestCase::testTagsEquivalence", "tests/codec/ber/test_decoder.py::DecoderCacheTestCase::testCache", "tests/codec/ber/test_d...
jyangballin/swesmith.x86_64.pyasn1_1776_pyasn1.0f07d724
true
null
1
11
140
1,192
0
0.6
1
0.75
1
0.235333
80.981
7,040
swe_smith::train::28014
swe_smith
train
28,014
jsvine__pdfplumber.02ff4313.func_pm_remove_loop__m7dgkt1x
swesmith/jsvine__pdfplumber.02ff4313
jsvine/pdfplumber
python
null
Table extraction returns empty results after recent changes #### Description Table extraction is not working properly and returns empty or None results where it should find valid tables. This affects both `extract_table()` and `find_table()` methods. #### Steps/Code to Reproduce ```python import pdfplumber # Examp...
diff --git a/pdfplumber/table.py b/pdfplumber/table.py index 0ba4445..8bbdacf 100644 --- a/pdfplumber/table.py +++ b/pdfplumber/table.py @@ -274,22 +274,7 @@ def intersections_to_cells(intersections: T_intersections) -> List[T_bbox]: for below_pt in below: if not edge_connects(pt, below_pt): ...
["tests/test_basics.py::Test::test_outside_bbox", "tests/test_ca_warn_report.py::Test::test_parse", "tests/test_dedupe_chars.py::Test::test_extract_table", "tests/test_issues.py::Test::test_issue_1181", "tests/test_issues.py::Test::test_issue_140", "tests/test_nics_report.py::Test::test_explicit_horizontal", "tests/tes...
["tests/test_basics.py::Test::test_annots", "tests/test_basics.py::Test::test_annots_cropped", "tests/test_basics.py::Test::test_annots_rotated", "tests/test_basics.py::Test::test_bad_fileobj", "tests/test_basics.py::Test::test_colors", "tests/test_basics.py::Test::test_crop_and_filter", "tests/test_basics.py::Test::te...
jyangballin/swesmith.x86_64.jsvine_1776_pdfplumber.02ff4313
true
null
1
15
16
1,111
0
0.6
1
0.75
1
0.235167
80.9805
7,041
swe_smith::train::39382
swe_smith
train
39,382
pallets__jinja.ada0a9a6.func_pm_ctrl_invert_if__c7aw3ms7
swesmith/pallets__jinja.ada0a9a6
pallets/jinja
python
null
PackageLoader.list_templates() fails for zip imports When using PackageLoader with packages installed from zip files, the `list_templates()` method raises a TypeError. This affects packages that are imported from zip archives or wheel files. #### Steps/Code to Reproduce ```python from jinja2 import PackageLoader # ...
diff --git a/src/jinja2/loaders.py b/src/jinja2/loaders.py index 8ca32cb..d8f5eaf 100644 --- a/src/jinja2/loaders.py +++ b/src/jinja2/loaders.py @@ -396,16 +396,6 @@ class PackageLoader(BaseLoader): results: t.List[str] = [] if self._archive is None: - # Package is a directory. - ...
["tests/test_loader.py::test_package_dir_list", "tests/test_loader.py::test_package_file_list", "tests/test_loader.py::test_package_zip_list", "tests/test_loader.py::test_pep_451_import_hook"]
["tests/test_api.py::TestExtendedAPI::test_item_and_attribute", "tests/test_api.py::TestExtendedAPI::test_finalize", "tests/test_api.py::TestExtendedAPI::test_finalize_constant_expression", "tests/test_api.py::TestExtendedAPI::test_no_finalize_template_data", "tests/test_api.py::TestExtendedAPI::test_context_finalize",...
jyangballin/swesmith.x86_64.pallets_1776_jinja.ada0a9a6
true
null
1
21
4
991
0
0.6
1
0.75
1
0.235167
80.9805
7,042
swe_smith::train::5072
swe_smith
train
5,072
agronholm__exceptiongroup.0b4f4937.combine_file__74zzufuj
swesmith/agronholm__exceptiongroup.0b4f4937
agronholm/exceptiongroup
python
null
ExceptionGroup.exceptions property returns reversed order #### Description The `exceptions` property of `BaseExceptionGroup` is returning exceptions in reversed order compared to what was passed during construction. #### Steps/Code to Reproduce ```python from exceptiongroup import ExceptionGroup # Create some exce...
diff --git a/src/exceptiongroup/_exceptions.py b/src/exceptiongroup/_exceptions.py index a4a7ace..386e103 100644 --- a/src/exceptiongroup/_exceptions.py +++ b/src/exceptiongroup/_exceptions.py @@ -110,13 +110,15 @@ class BaseExceptionGroup(BaseException, Generic[_BaseExceptionT_co]): @property def message(s...
["tests/test_catch.py::test_catch_handler_raises", "tests/test_exceptions.py::ExceptionGroupFields::test_basics_ExceptionGroup_fields", "tests/test_exceptions.py::ExceptionGroupSubgroupTests::test_basics_subgroup_by_predicate__match", "tests/test_exceptions.py::ExceptionGroupSubgroupTests::test_basics_subgroup_by_predi...
["tests/test_catch.py::test_bad_arg", "tests/test_catch.py::test_bad_handler", "tests/test_catch.py::test_catch_exceptiongroup[naked_basegroup]", "tests/test_catch.py::test_catch_exceptiongroup[naked_group]", "tests/test_catch.py::test_catch_exceptiongroup[iterable_basegroup]", "tests/test_catch.py::test_catch_exceptio...
jyangballin/swesmith.x86_64.agronholm_1776_exceptiongroup.0b4f4937
true
null
1
22
38
971
0
0.6
1
0.75
1
0.235167
80.9805
7,043
swe_smith::train::1468
swe_smith
train
1,468
Cog-Creators__Red-DiscordBot.33e0eac7.func_basic__dip0sy1i
swesmith/Cog-Creators__Red-DiscordBot.33e0eac7
cog-creators/red-discordbot
python
null
# TypeError in bounded_gather when limit is 0 ## Description I'm encountering a TypeError when using `bounded_gather` with a limit of 0. The function is supposed to limit the number of concurrent tasks, but it fails when the limit is set to 0. ## Steps to Reproduce ```python import asyncio from redbot.core.utils imp...
diff --git a/redbot/core/utils/__init__.py b/redbot/core/utils/__init__.py index dc3687f..8ccc0f6 100644 --- a/redbot/core/utils/__init__.py +++ b/redbot/core/utils/__init__.py @@ -261,14 +261,14 @@ def bounded_gather( loop = asyncio.get_running_loop() if semaphore is None: - if not isinstance(limit,...
["tests/core/test_utils.py::test_bounded_gather"]
["tests/cogs/test_alias.py::test_is_valid_alias_name", "tests/cogs/test_alias.py::test_empty_guild_aliases", "tests/cogs/test_alias.py::test_empty_global_aliases", "tests/cogs/test_alias.py::test_add_guild_alias", "tests/cogs/test_alias.py::test_translate_alias_message", "tests/cogs/test_alias.py::test_delete_guild_ali...
jyangballin/swesmith.x86_64.cog-creators_1776_red-discordbot.33e0eac7
true
null
1
6
1
1,290
0
0.6
1
0.75
1
0.235
80.98
7,044
swe_smith::train::24520
swe_smith
train
24,520
sunpy__sunpy.f8edfd5c.combine_module__lfyld2oh
swesmith/sunpy__sunpy.f8edfd5c
sunpy/sunpy
python
null
# [Bug]: Chaincode.sub_boundingbox method fails with UnboundLocalError ## Bug summary The `sub_boundingbox` method in the `Chaincode` class fails with an `UnboundLocalError` because it tries to use variables that are not defined at the point of use. ## Code for reproduction ```python from sunpy.net.helio.chaincode ...
diff --git a/sunpy/net/helio/chaincode.py b/sunpy/net/helio/chaincode.py index e4757ef..1003dfd 100644 --- a/sunpy/net/helio/chaincode.py +++ b/sunpy/net/helio/chaincode.py @@ -86,6 +86,7 @@ class Chaincode(np.ndarray): raise NotImplementedError def sub_boundingbox(self, xedge=None, yedge=None): + ...
["sunpy/net/helio/tests/test_chaincode.py::test_subboundingboxx", "sunpy/net/helio/tests/test_chaincode.py::test_subboundingboxy", "sunpy/net/vso/tests/test_vso.py::test_iter_sort_response", "sunpy/net/vso/tests/test_vso.py::test_from_zeep_response", "sunpy/net/vso/tests/test_vso.py::test_QueryResponse_build_table_with...
["sunpy/net/helio/tests/test_chaincode.py::test_ends", "sunpy/net/helio/tests/test_chaincode.py::test_endsfalse", "sunpy/net/helio/tests/test_chaincode.py::test_secondcoordinate", "sunpy/net/helio/tests/test_chaincode.py::test_secondcoordinatefails", "sunpy/net/helio/tests/test_chaincode.py::test_scalesecond", "sunpy/n...
jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c
true
null
2
10
8
1,210
0
0.6
1
0.75
1
0.235
80.98
7,045
swe_smith::train::23398
swe_smith
train
23,398
pyparsing__pyparsing.533adf47.combine_file__ktbqobu7
swesmith/pyparsing__pyparsing.533adf47
pyparsing/pyparsing
python
null
OnlyOnce action not working correctly after recent changes #### Description The `OnlyOnce` parse action is not functioning as expected. When used with expressions, it appears to be calling the wrapped function multiple times instead of restricting it to a single call, and the reset functionality is also broken. ####...
diff --git a/pyparsing/actions.py b/pyparsing/actions.py index b584048..5357698 100644 --- a/pyparsing/actions.py +++ b/pyparsing/actions.py @@ -30,10 +30,10 @@ class OnlyOnce: def __call__(self, s: str, l: int, t: ParseResults) -> ParseResults: if not self.called: - results = self.callable(s...
["tests/test_unit.py::Test02_WithoutPackrat::testOnlyOnce", "tests/test_unit.py::Test02_WithoutPackrat::testWithAttributeParseAction", "tests/test_unit.py::Test04_WithPackrat::testOnlyOnce", "tests/test_unit.py::Test04_WithPackrat::testWithAttributeParseAction", "tests/test_unit.py::Test06_WithBoundedPackrat::testOnlyO...
["examples/test_bibparse.py::TestBibparse::test_bib1", "examples/test_bibparse.py::TestBibparse::test_bibfile", "examples/test_bibparse.py::TestBibparse::test_comments", "examples/test_bibparse.py::TestBibparse::test_entry", "examples/test_bibparse.py::TestBibparse::test_macro", "examples/test_bibparse.py::TestBibparse...
jyangballin/swesmith.x86_64.pyparsing_1776_pyparsing.533adf47
true
null
1
8
12
1,250
0
0.6
1
0.75
1
0.235
80.98
7,046
swe_smith::train::23840
swe_smith
train
23,840
sunpy__sunpy.f8edfd5c.func_pm_ctrl_invert_if__azb7a5dd
swesmith/sunpy__sunpy.f8edfd5c
sunpy/sunpy
python
null
Map scale property returns incorrect values when CD matrix is present #### Description When a map has CD matrix elements (cd1_1, cd1_2, cd2_1, cd2_2) in its metadata but lacks CDELT1/CDELT2 keywords, the `scale` property returns the CDELT values instead of calculating the scale from the CD matrix. This results in inc...
diff --git a/sunpy/map/mapbase.py b/sunpy/map/mapbase.py index bdcac77..fd55333 100644 --- a/sunpy/map/mapbase.py +++ b/sunpy/map/mapbase.py @@ -1447,15 +1447,14 @@ class GenericMap(NDData): be as optimal if the PCij matrix includes any skew. """ if 'cd1_1' in self.meta and 'cdelt1' not in se...
["sunpy/map/tests/test_mapbase.py::test_wcs", "sunpy/map/tests/test_mapbase.py::test_wcs_pv", "sunpy/map/tests/test_mapbase.py::test_wcs_cache", "sunpy/map/tests/test_mapbase.py::test_header_immutability", "sunpy/map/tests/test_mapbase.py::test_coordinate_frame", "sunpy/map/tests/test_mapbase.py::test_observer_hgln_crl...
["sunpy/map/tests/test_mapbase.py::test_notes_combined", "sunpy/map/tests/test_mapbase.py::test_notes_combined_no_references", "sunpy/map/tests/test_mapbase.py::test_notes_combined_no_existing_notes", "sunpy/map/tests/test_mapbase.py::test_notes_combined_no_notes_no_references", "sunpy/map/tests/test_mapbase.py::test_f...
jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c
true
null
1
7
71
1,270
0
0.6
1
0.75
1
0.235
80.98
7,047
swe_smith::train::32237
swe_smith
train
32,237
davidhalter__parso.338a5760.func_pm_remove_assign__7lr0wvsd
swesmith/davidhalter__parso.338a5760
davidhalter/parso
python
null
NameError when parsing valid named expressions (walrus operator) #### Description When parsing valid Python 3.8+ named expressions (walrus operator `:=`), parso incorrectly raises NameError for undefined variables in cases where the code should be valid. #### Steps/Code to Reproduce ```python import parso # These ...
diff --git a/parso/python/errors.py b/parso/python/errors.py index 09c5047..137543f 100644 --- a/parso/python/errors.py +++ b/parso/python/errors.py @@ -1263,8 +1263,6 @@ class _NamedExprRule(_CheckAssignmentRule): # namedexpr_test: test [':=' test] def is_issue(self, namedexpr_test): - # assigned na...
["test/test_python_errors.py::test_valid_namedexpr[a[(b:=0)]]", "test/test_python_errors.py::test_valid_namedexpr[a[(b:=0):1:2]]"]
["parso/__init__.py::parso", "parso/python/tree.py::parso.python.tree", "parso/tree.py::parso.tree.NodeOrLeaf.dump", "test/test_cache.py::test_modulepickling_change_cache_dir", "test/test_cache.py::test_modulepickling_simulate_deleted_cache", "test/test_cache.py::test_cache_limit", "test/test_cache.py::test_cache_last_...
jyangballin/swesmith.x86_64.davidhalter_1776_parso.338a5760
true
null
1
6
2
1,289
0
0.6
1
0.75
1
0.234833
80.9795
7,048
swe_smith::train::48401
swe_smith
train
48,401
sqlfluff__sqlfluff.50a1c4b6.func_pm_remove_assign__rlr4stk4
swesmith/sqlfluff__sqlfluff.50a1c4b6
sqlfluff/sqlfluff
python
null
NameError in patch generation after removing variable assignments #### Description When generating source patches, the linter crashes with a `NameError` because variables that were removed from the code are still being referenced later in the function. #### Steps/Code to Reproduce The issue occurs during the patch ...
diff --git a/src/sqlfluff/core/linter/patch.py b/src/sqlfluff/core/linter/patch.py index 0262713..f563bc2 100644 --- a/src/sqlfluff/core/linter/patch.py +++ b/src/sqlfluff/core/linter/patch.py @@ -71,7 +71,6 @@ def _iter_templated_patches( """ # Does it match? If so we can ignore it. assert segment.pos_m...
["test/core/linter/fix_test.py::test__fix__generate_source_patches[tree0-templated_file0-expected_result0]", "test/core/linter/fix_test.py::test__fix__generate_source_patches[tree1-templated_file1-expected_result1]", "test/core/linter/fix_test.py::test__fix__generate_source_patches[tree2-templated_file2-expected_result...
["test/core/linter/discovery_test.py::test__linter__path_from_paths__dir", "test/core/linter/discovery_test.py::test__linter__path_from_paths__default", "test/core/linter/discovery_test.py::test__linter__path_from_paths__exts", "test/core/linter/discovery_test.py::test__linter__path_from_paths__file", "test/core/linter...
jyangballin/swesmith.x86_64.sqlfluff_1776_sqlfluff.50a1c4b6
true
null
1
10
6
1,209
0
0.6
1
0.75
1
0.234833
80.9795
7,049
swe_smith::train::31669
swe_smith
train
31,669
benoitc__gunicorn.bacbf8aa.lm_rewrite__4fqc3ggz
swesmith/benoitc__gunicorn.bacbf8aa
benoitc/gunicorn
python
null
KeyError when logging access with Statsd I've encountered an issue with the logging functionality when using Statsd in Gunicorn. It seems that a `KeyError` is raised when attempting to log access information. Here's a snippet to reproduce the problem: ```python from gunicorn.glogging import Logger from types import S...
diff --git a/gunicorn/glogging.py b/gunicorn/glogging.py index e34fcd5..96d5f2a 100644 --- a/gunicorn/glogging.py +++ b/gunicorn/glogging.py @@ -345,24 +345,22 @@ class Logger: """ See http://httpd.apache.org/docs/2.0/logs.html#combined for format details """ - - if not (self.cfg.acces...
["tests/test_statsd.py::test_instrument"]
["tests/test_arbiter.py::test_arbiter_stop_closes_listeners", "tests/test_arbiter.py::test_arbiter_stop_child_does_not_unlink_listeners", "tests/test_arbiter.py::test_arbiter_stop_parent_does_not_unlink_listeners", "tests/test_arbiter.py::test_arbiter_stop_does_not_unlink_systemd_listeners", "tests/test_arbiter.py::tes...
jyangballin/swesmith.x86_64.benoitc_1776_gunicorn.bacbf8aa
true
null
1
32
1
769
0
0.6
1
0.75
1
0.234833
80.9795
7,050
swe_smith::train::25028
swe_smith
train
25,028
pylint-dev__astroid.b114f6b5.combine_file__cr3o8u7k
swesmith/pylint-dev__astroid.b114f6b5
pylint-dev/astroid
python
null
Statement filtering returns incorrect results for exception handlers #### Description When filtering statements in code that contains exception handlers, the filtering logic produces incorrect results. The issue affects statement lookup and inference, causing various operations to fail unexpectedly. #### Steps/Code ...
diff --git a/astroid/filter_statements.py b/astroid/filter_statements.py index a48b6e7..6601ca3 100644 --- a/astroid/filter_statements.py +++ b/astroid/filter_statements.py @@ -29,22 +29,24 @@ def _get_filtered_node_statements( isinstance(stmt, nodes.ExceptHandler) for _, stmt in statements ): st...
["tests/brain/test_attr.py::AttrsTest::test_attr_transform", "tests/brain/test_attr.py::AttrsTest::test_attrs_transform", "tests/brain/test_brain.py::test_http_status_brain", "tests/brain/test_brain.py::test_http_status_brain_iterable", "tests/brain/test_enum.py::EnumBrainTest::test_int_enum", "tests/brain/test_named_t...
["tests/brain/numpy/test_core_einsumfunc.py::test_numpy_function_calls_inferred_as_ndarray", "tests/brain/numpy/test_core_einsumfunc.py::test_function_parameters", "tests/brain/numpy/test_core_fromnumeric.py::BrainNumpyCoreFromNumericTest::test_numpy_function_calls_inferred_as_ndarray", "tests/brain/numpy/test_core_fun...
jyangballin/swesmith.x86_64.pylint-dev_1776_astroid.b114f6b5
true
null
1
12
81
1,168
0
0.6
1
0.75
1
0.234667
80.979
7,051
swe_smith::train::20211
swe_smith
train
20,211
gruns__furl.da386f68.func_basic__2mdytao1
swesmith/gruns__furl.da386f68
gruns/furl
python
null
furl.remove() method returns None instead of self When calling the `remove()` method on a furl object, it should return the modified furl instance to allow method chaining, but it's currently returning `None`. #### Steps/Code to Reproduce ```python from furl import furl # This should work but raises AttributeError ...
diff --git a/furl/furl.py b/furl/furl.py index cd6d710..31d7562 100644 --- a/furl/furl.py +++ b/furl/furl.py @@ -1786,38 +1786,48 @@ class furl(URLPathCompositionInterface, QueryCompositionInterface, Returns: <self>. """ if scheme is True: - self.scheme = None + self.sch...
["tests/test_furl.py::TestFurl::test_remove", "tests/test_furl.py::TestFurl::test_username_and_password"]
["tests/test_furl.py::TestPath::test_add", "tests/test_furl.py::TestPath::test_asdict", "tests/test_furl.py::TestPath::test_encoding", "tests/test_furl.py::TestPath::test_equality", "tests/test_furl.py::TestPath::test_isabsolute", "tests/test_furl.py::TestPath::test_isdir_isfile", "tests/test_furl.py::TestPath::test_it...
jyangballin/swesmith.x86_64.gruns_1776_furl.da386f68
true
null
1
38
2
648
0
0.6
1
0.75
1
0.234667
80.979
7,052
r2e_gym::train::4270
r2e_gym
train
4,270
numpy__d6a8cabd725e93a1dcfc03f0b4154dd96fd4ce8f
numpy
numpy/numpy
python
d6a8cabd725e93a1dcfc03f0b4154dd96fd4ce8f
**Title:** `nan_to_num` Raises TypeError When Using `nan`, `posinf`, or `neginf` Keywords **Description:** When attempting to use the `nan`, `posinf`, or `neginf` keyword arguments with the `nan_to_num` function, a `TypeError` is raised. This prevents users from specifying custom replacement values for NaN, positive i...
diff --git a/doc/release/1.17.0-notes.rst b/doc/release/1.17.0-notes.rst --- a/doc/release/1.17.0-notes.rst +++ b/doc/release/1.17.0-notes.rst @@ -197,6 +197,12 @@ which allows us to provide specialized ufuncs that are up to 250x faster than the current approach. +New keywords added to ``np.nan_to_num`` +----------...
diff --git a/numpy/lib/tests/test_type_check.py b/numpy/lib/tests/test_type_check.py --- a/numpy/lib/tests/test_type_check.py +++ b/numpy/lib/tests/test_type_check.py @@ -360,6 +360,14 @@ assert_(vals[1] == 0) assert_all(vals[2] > 1e10) and assert_all(np.isfinite(vals[2])) assert_equal(type(v...
null
null
namanjain12/numpy_final:d6a8cabd725e93a1dcfc03f0b4154dd96fd4ce8f
true
null
2
56
null
1,000
0
0.75
1
0.6375
1
0.353333
80.97875
7,053
swe_smith::train::35389
swe_smith
train
35,389
alecthomas__voluptuous.a7a55f83.func_pm_op_swap__ik9k7pih
swesmith/alecthomas__voluptuous.a7a55f83
alecthomas/voluptuous
python
null
# TypeError when validating numbers with precision and scale constraints I'm encountering a TypeError when using the Number validator with precision and scale constraints. ## Steps to reproduce ```python from voluptuous import Schema, Number, MultipleInvalid # Case 1: Both precision and scale constraints schema1 = ...
diff --git a/voluptuous/validators.py b/voluptuous/validators.py index 3f026b1..f80ac26 100644 --- a/voluptuous/validators.py +++ b/voluptuous/validators.py @@ -1135,8 +1135,8 @@ class Number(object): ): raise Invalid( self.msg - or "Precision must be equal to %s, a...
["voluptuous/tests/tests.py::test_number_validation_with_invalid_precision_invalid_scale", "voluptuous/tests/tests.py::test_number_when_precision_none_n_invalid_scale_yield_decimal_true"]
["voluptuous/tests/tests.md::tests.md", "voluptuous/tests/tests.py::test_new_required_test", "voluptuous/tests/tests.py::test_exact_sequence", "voluptuous/tests/tests.py::test_required", "voluptuous/tests/tests.py::test_extra_with_required", "voluptuous/tests/tests.py::test_iterate_candidates", "voluptuous/tests/tests....
jyangballin/swesmith.x86_64.alecthomas_1776_voluptuous.a7a55f83
true
null
1
7
2
1,267
0
0.6
1
0.75
1
0.2345
80.9785
7,054
swe_smith::train::48849
swe_smith
train
48,849
facebookresearch__hydra.0f03eb60.func_pm_op_swap__0yml2dmz
swesmith/facebookresearch__hydra.0f03eb60
facebookresearch/hydra
python
null
Error message order changed in _locate function causing test failures #### Description The error message formatting in the `_locate` function has been altered, causing the order of error message components to be reversed. This affects error handling when importing modules or accessing attributes fails. #### Steps/Co...
diff --git a/hydra/_internal/utils.py b/hydra/_internal/utils.py index 941efc5..932be73 100644 --- a/hydra/_internal/utils.py +++ b/hydra/_internal/utils.py @@ -626,8 +626,8 @@ def _locate(path: str) -> Any: for part in parts: if not len(part): raise ValueError( - f"Error loadi...
["tests/instantiate/test_helpers.py::test_locate[nested_not_found]", "tests/instantiate/test_helpers.py::test_locate_relative_import_fails[invalid-path-period]", "tests/instantiate/test_helpers.py::test_locate_relative_import_fails[invalid-path-period2]", "tests/instantiate/test_helpers.py::test_locate_relative_import_...
["build_helpers/test_helpers.py::test_find[none]", "build_helpers/test_helpers.py::test_find[all]", "build_helpers/test_helpers.py::test_find[filter_a]", "build_helpers/test_helpers.py::test_find[include_a]", "build_helpers/test_helpers.py::test_find[include_a,exclude_file1]", "build_helpers/test_helpers.py::test_find[...
jyangballin/swesmith.x86_64.facebookresearch_1776_hydra.0f03eb60
true
null
1
11
7
1,187
0
0.6
1
0.75
1
0.2345
80.9785
7,055
swe_smith::train::10410
swe_smith
train
10,410
paramiko__paramiko.23f92003.func_basic__cch7tgce
swesmith/paramiko__paramiko.23f92003
paramiko/paramiko
python
null
OpenSSH private key loading fails with "Invalid key" error #### Description When loading OpenSSH format private keys, paramiko raises an "Invalid key" SSHException during the unpadding process. This affects various key types including RSA, DSS, ECDSA, and Ed25519 keys in OpenSSH format. #### Steps/Code to Reproduce ...
diff --git a/paramiko/pkey.py b/paramiko/pkey.py index f0b2d6d..8a31aa7 100644 --- a/paramiko/pkey.py +++ b/paramiko/pkey.py @@ -61,18 +61,15 @@ OPENSSH_AUTH_MAGIC = b"openssh-key-v1\x00" def _unpad_openssh(data): - # At the moment, this is only used for unpadding private keys on disk. This - # really ought ...
["tests/auth.py::AuthSource_::InMemoryPrivateKey_::repr_shows_pkey_repr", "tests/auth.py::AuthSource_::InMemoryPrivateKey_::repr_appends_agent_flag_when_AgentKey", "tests/pkey.py::PKey_::load_certificate::loading_cert_of_different_type_from_key_raises_ValueError", "tests/test_client.py::SSHClientTest::test_certs_allowe...
["tests/agent.py::AgentKey_::str_is_repr", "tests/agent.py::AgentKey_::init::needs_at_least_two_arguments", "tests/agent.py::AgentKey_::init::sets_attributes_and_parses_blob", "tests/agent.py::AgentKey_::init::comment_optional", "tests/agent.py::AgentKey_::init::sets_inner_key_when_known_type[rsa]", "tests/agent.py::Ag...
jyangballin/swesmith.x86_64.paramiko_1776_paramiko.23f92003
true
null
1
13
14
1,147
0
0.6
1
0.75
1
0.2345
80.9785
7,056
swe_smith::train::44507
swe_smith
train
44,507
pydata__patsy.a5d16484.lm_rewrite__ef15p0uw
swesmith/pydata__patsy.a5d16484
pydata/patsy
python
null
### Issue: TypeError when using formulas with terms #### Description After the recent changes, there seems to be an issue with handling terms in formulas. When attempting to use formulas that involve terms, a `TypeError` is raised. This error occurs when the code tries to concatenate tuples with non-tuple elements, w...
diff --git a/patsy/desc.py b/patsy/desc.py index 210350d..6784838 100644 --- a/patsy/desc.py +++ b/patsy/desc.py @@ -214,11 +214,7 @@ class IntermediateExpr(object): self.intercept = intercept self.intercept_origin = intercept_origin self.intercept_removed = intercept_removed - self.te...
["patsy/desc.py::test_ModelDesc_from_formula", "patsy/desc.py::test_eval_formula", "patsy/desc.py::test_eval_formula_error_reporting", "patsy/desc.py::test_formula_factor_origin", "patsy/mgcv_cubic_splines.py::test_crs_with_specific_constraint", "patsy/test_build.py::test_DesignInfo_subset", "patsy/test_highlevel.py::t...
["patsy/build.py::test__max_allowed_dim", "patsy/build.py::test__eval_factor_numerical", "patsy/build.py::test__eval_factor_categorical", "patsy/build.py::test__column_combinations", "patsy/build.py::test__subterm_column_names_iter_and__build_subterm", "patsy/build.py::test__factors_memorize", "patsy/build.py::test__ex...
jyangballin/swesmith.x86_64.pydata_1776_patsy.a5d16484
true
null
1
6
21
1,287
0
0.6
1
0.75
1
0.2345
80.9785
7,057
swe_smith::train::10343
swe_smith
train
10,343
paramiko__paramiko.23f92003.func_basic__722rg7mn
swesmith/paramiko__paramiko.23f92003
paramiko/paramiko
python
null
SFTP operations failing with IOError instead of proper exception types #### Description SFTP operations are now raising generic `IOError` exceptions instead of the expected specific exception types. This breaks error handling code that relies on catching specific exceptions like `EOFError` for end-of-file conditions....
diff --git a/paramiko/sftp_client.py b/paramiko/sftp_client.py index 066cd83..6a1e59a 100644 --- a/paramiko/sftp_client.py +++ b/paramiko/sftp_client.py @@ -932,14 +932,14 @@ class SFTPClient(BaseSFTP, ClosingContextManager): if code == SFTP_OK: return elif code == SFTP_EOF: - ...
["tests/test_sftp.py::TestSFTP::testa_posix_rename", "tests/test_sftp.py::TestSFTP::test_listdir", "tests/test_sftp.py::TestSFTP::test_listdir_iter", "tests/test_sftp.py::TestSFTP::test_listdir_in_locale", "tests/test_sftp.py::TestSFTP::test_readline_seek", "tests/test_sftp.py::TestSFTP::test_write_seek", "tests/test_s...
["tests/agent.py::AgentKey_::str_is_repr", "tests/agent.py::AgentKey_::init::needs_at_least_two_arguments", "tests/agent.py::AgentKey_::init::sets_attributes_and_parses_blob", "tests/agent.py::AgentKey_::init::comment_optional", "tests/agent.py::AgentKey_::init::sets_inner_key_when_known_type[rsa]", "tests/agent.py::Ag...
jyangballin/swesmith.x86_64.paramiko_1776_paramiko.23f92003
true
null
1
8
16
1,247
0
0.6
1
0.75
1
0.2345
80.9785
7,058
swe_smith::train::762
swe_smith
train
762
oauthlib__oauthlib.1fd52536.func_pm_ctrl_shuffle__k1sh1qcd
swesmith/oauthlib__oauthlib.1fd52536
oauthlib/oauthlib
python
null
#### Description OAuth2 client authorization request preparation returns early without proper URL construction #### Steps/Code to Reproduce ```python from oauthlib.oauth2 import WebApplicationClient client = WebApplicationClient('client_id') url, headers, body = client.prepare_authorization_request( 'https://ex...
diff --git a/oauthlib/oauth2/rfc6749/clients/base.py b/oauthlib/oauth2/rfc6749/clients/base.py index a8de78b..c8da67b 100644 --- a/oauthlib/oauth2/rfc6749/clients/base.py +++ b/oauthlib/oauth2/rfc6749/clients/base.py @@ -220,6 +220,14 @@ class Client: def prepare_authorization_request(self, authorization_url, st...
["tests/oauth2/rfc6749/clients/test_base.py::ClientTest::test_prepare_authorization_request", "tests/oauth2/rfc6749/clients/test_web_application.py::WebApplicationClientTest::test_prepare_authorization_requeset"]
["tests/oauth1/rfc5849/endpoints/test_access_token.py::AccessTokenEndpointTest::test_check_request_token", "tests/oauth1/rfc5849/endpoints/test_access_token.py::AccessTokenEndpointTest::test_check_verifier", "tests/oauth1/rfc5849/endpoints/test_access_token.py::AccessTokenEndpointTest::test_valid_request", "tests/oauth...
jyangballin/swesmith.x86_64.oauthlib_1776_oauthlib.1fd52536
true
null
1
17
2
1,067
0
0.6
1
0.75
1
0.2345
80.9785
7,059
swe_smith::train::51130
swe_smith
train
51,130
marshmallow-code__apispec.8b421526.combine_module__uw8tzyjs
swesmith/marshmallow-code__apispec.8b421526
marshmallow-code/apispec
python
null
MarshmallowPlugin initialization breaks schema resolution #### Description After recent changes, the MarshmallowPlugin fails to properly initialize and resolve schemas. The plugin sets `self.spec = None` during initialization instead of preserving the spec reference, causing schema resolution to fail. #### Steps/Cod...
diff --git a/src/apispec/ext/marshmallow/__init__.py b/src/apispec/ext/marshmallow/__init__.py index d4f1a54..0c00409 100644 --- a/src/apispec/ext/marshmallow/__init__.py +++ b/src/apispec/ext/marshmallow/__init__.py @@ -130,15 +130,15 @@ class MarshmallowPlugin(BasePlugin): def init_spec(self, spec: APISpec) ->...
["tests/test_ext_marshmallow.py::TestDefinitionHelper::test_resolve_schema_dict_auto_reference[AnalysisSchema]", "tests/test_ext_marshmallow.py::TestDefinitionHelper::test_resolve_schema_dict_auto_reference[schema1]", "tests/test_ext_marshmallow.py::TestDefinitionHelper::test_resolve_schema_dict_auto_reference_in_list[...
["tests/test_core.py::TestAPISpecInit::test_raises_wrong_apispec_version", "tests/test_core.py::TestMetadata::test_openapi_metadata[2.0]", "tests/test_core.py::TestMetadata::test_openapi_metadata[3.0.0]", "tests/test_core.py::TestMetadata::test_openapi_metadata_merge_v3[3.0.0]", "tests/test_core.py::TestTags::test_tag[...
jyangballin/swesmith.x86_64.marshmallow-code_1776_apispec.8b421526
true
null
2
13
118
1,147
0
0.6
1
0.75
1
0.2345
80.9785
7,060
swe_smith::train::10115
swe_smith
train
10,115
paramiko__paramiko.23f92003.combine_file__gf849amk
swesmith/paramiko__paramiko.23f92003
paramiko/paramiko
python
null
ECDSA key generation and signature verification broken Description ECDSA key generation is failing and signature verification always returns True regardless of signature validity. When generating ECDSA keys, the process crashes with an AttributeError, and when verifying signatures, the verification logic is inverted....
diff --git a/paramiko/ecdsakey.py b/paramiko/ecdsakey.py index 6fd95fa..c8971e8 100644 --- a/paramiko/ecdsakey.py +++ b/paramiko/ecdsakey.py @@ -228,10 +228,10 @@ class ECDSAKey(PKey): return m def verify_ssh_sig(self, data, msg): - if msg.get_text() != self.ecdsa_curve.key_format_identifier: + ...
["tests/test_client.py::SSHClientTest::test_auto_add_policy", "tests/test_client.py::SSHClientTest::test_certs_allowed_as_key_filename_values", "tests/test_client.py::SSHClientTest::test_certs_implicitly_loaded_alongside_key_filename_keys", "tests/test_client.py::SSHClientTest::test_channel_timeout", "tests/test_client...
["tests/agent.py::AgentKey_::str_is_repr", "tests/agent.py::AgentKey_::init::needs_at_least_two_arguments", "tests/agent.py::AgentKey_::init::sets_attributes_and_parses_blob", "tests/agent.py::AgentKey_::init::comment_optional", "tests/agent.py::AgentKey_::init::sets_inner_key_when_known_type[rsa]", "tests/agent.py::Ag...
jyangballin/swesmith.x86_64.paramiko_1776_paramiko.23f92003
true
null
1
16
15
1,087
0
0.6
1
0.75
1
0.2345
80.9785
7,061
swe_smith::train::3166
swe_smith
train
3,166
Suor__funcy.207a7810.func_basic__rmnnpv0q
swesmith/Suor__funcy.207a7810
suor/funcy
python
null
Lookuper functions not working correctly after recent changes #### Description The `make_lookuper` and `silent_lookuper` decorators are not functioning as expected. When trying to use lookup functions created with these decorators, they either fail to return correct values or raise unexpected errors. #### Steps/Code...
diff --git a/funcy/calc.py b/funcy/calc.py index 2966bdd..a4ca7a3 100644 --- a/funcy/calc.py +++ b/funcy/calc.py @@ -116,7 +116,7 @@ def _make_lookuper(silent): assert not has_keys, \ 'Lookup table building function should not have keyword arguments' - if has_args: + if not has_arg...
["tests/test_calc.py::test_make_lookuper", "tests/test_calc.py::test_make_lookuper_nested", "tests/test_calc.py::test_silent_lookuper", "tests/test_calc.py::test_silnent_lookuper_nested"]
["tests/test_calc.py::test_memoize", "tests/test_calc.py::test_memoize_args_kwargs", "tests/test_calc.py::test_memoize_skip", "tests/test_calc.py::test_memoize_memory", "tests/test_calc.py::test_memoize_key_func", "tests/test_calc.py::test_cache[int]", "tests/test_calc.py::test_cache[timedelta]", "tests/test_calc.py::t...
jyangballin/swesmith.x86_64.suor_1776_funcy.207a7810
true
null
1
7
4
1,267
0
0.6
1
0.75
1
0.2345
80.9785
7,062
swe_smith::train::17848
swe_smith
train
17,848
pyasn1__pyasn1.0f07d724.func_pm_class_rm_funcs__b176z0v6
swesmith/pyasn1__pyasn1.0f07d724
pyasn1/pyasn1
python
null
NamedValues missing essential methods after refactoring #### Description The NamedValues class is missing several essential methods that were apparently removed, causing basic operations to fail. #### Steps/Code to Reproduce ```python from pyasn1.type import namedval # Create a NamedValues instance nv = namedval.N...
diff --git a/pyasn1/type/namedval.py b/pyasn1/type/namedval.py index 46a6496..0ace3ba 100644 --- a/pyasn1/type/namedval.py +++ b/pyasn1/type/namedval.py @@ -118,15 +118,9 @@ class NamedValues(object): def __ne__(self, other): return dict(self) != other - def __lt__(self, other): - return dict(...
["tests/type/test_namedval.py::NamedValuesCaseBase::testDict", "tests/type/test_namedval.py::NamedValuesCaseBase::testLen"]
["tests/codec/ber/test_decoder.py::LargeTagDecoderTestCase::testLargeTag", "tests/codec/ber/test_decoder.py::LargeTagDecoderTestCase::testLongTag", "tests/codec/ber/test_decoder.py::LargeTagDecoderTestCase::testTagsEquivalence", "tests/codec/ber/test_decoder.py::DecoderCacheTestCase::testCache", "tests/codec/ber/test_d...
jyangballin/swesmith.x86_64.pyasn1_1776_pyasn1.0f07d724
true
null
1
27
2
867
0
0.6
1
0.75
1
0.2345
80.9785
7,063
swe_smith::train::39406
swe_smith
train
39,406
pallets__jinja.ada0a9a6.func_pm_ctrl_invert_if__ptlk0ui1
swesmith/pallets__jinja.ada0a9a6
pallets/jinja
python
null
Async variant decorator incorrectly swaps is_async check logic #### Description The `async_variant` decorator in `async_utils.py` has swapped logic for determining when to check `is_async` on the environment vs the first argument. This causes async filters and functions to fail with `AttributeError` when trying to ac...
diff --git a/src/jinja2/async_utils.py b/src/jinja2/async_utils.py index f0c1402..cb73f1e 100644 --- a/src/jinja2/async_utils.py +++ b/src/jinja2/async_utils.py @@ -20,12 +20,11 @@ def async_variant(normal_func): # type: ignore if pass_arg is _PassArg.environment: def is_async(args: t.Any) -> b...
["tests/test_api.py::TestExtendedAPI::test_item_and_attribute", "tests/test_api.py::TestUndefined::test_logging_undefined", "tests/test_api.py::TestUndefined::test_default_undefined", "tests/test_api.py::TestUndefined::test_chainable_undefined", "tests/test_api.py::TestUndefined::test_debug_undefined", "tests/test_api....
["tests/test_api.py::TestExtendedAPI::test_finalize", "tests/test_api.py::TestExtendedAPI::test_finalize_constant_expression", "tests/test_api.py::TestExtendedAPI::test_no_finalize_template_data", "tests/test_api.py::TestExtendedAPI::test_context_finalize", "tests/test_api.py::TestExtendedAPI::test_eval_finalize", "tes...
jyangballin/swesmith.x86_64.pallets_1776_jinja.ada0a9a6
true
null
1
6
86
1,287
0
0.6
1
0.75
1
0.2345
80.9785
7,064
swe_smith::train::39322
swe_smith
train
39,322
pallets__jinja.ada0a9a6.func_basic__zeyxxbdf
swesmith/pallets__jinja.ada0a9a6
pallets/jinja
python
null
Template.module returns None instead of module object #### Description When accessing the `module` attribute on a Template instance, it returns `None` instead of the expected module object. This breaks functionality that depends on accessing template modules, such as importing macros and accessing template globals. ...
diff --git a/src/jinja2/environment.py b/src/jinja2/environment.py index 0b303d5..4cf6c5b 100644 --- a/src/jinja2/environment.py +++ b/src/jinja2/environment.py @@ -1435,18 +1435,18 @@ class Template: should have access to only the current template's globals. """ if self.environment.is_async:...
["tests/test_core_tags.py::TestMacros::test_macro_api", "tests/test_core_tags.py::TestMacros::test_macro_defaults_self_ref", "tests/test_core_tags.py::TestSet::test_normal", "tests/test_core_tags.py::TestSet::test_block", "tests/test_core_tags.py::TestSet::test_block_filtered", "tests/test_core_tags.py::TestSet::test_b...
["tests/test_api.py::TestExtendedAPI::test_item_and_attribute", "tests/test_api.py::TestExtendedAPI::test_finalize", "tests/test_api.py::TestExtendedAPI::test_finalize_constant_expression", "tests/test_api.py::TestExtendedAPI::test_no_finalize_template_data", "tests/test_api.py::TestExtendedAPI::test_context_finalize",...
jyangballin/swesmith.x86_64.pallets_1776_jinja.ada0a9a6
true
null
1
10
14
1,206
0
0.6
1
0.75
1
0.234333
80.978
7,065
swe_smith::train::27849
swe_smith
train
27,849
jsvine__pdfplumber.02ff4313.func_pm_ctrl_invert_if__h1h17dng
swesmith/jsvine__pdfplumber.02ff4313
jsvine/pdfplumber
python
null
Explicit vertical lines handling broken when passed as numeric values #### Description When using `explicit_vertical_lines` with numeric values (floats or integers) in table extraction settings, the table finder incorrectly treats them as dictionary objects instead of coordinate values, causing a TypeError. #### Ste...
diff --git a/pdfplumber/table.py b/pdfplumber/table.py index 0ba4445..2d234f6 100644 --- a/pdfplumber/table.py +++ b/pdfplumber/table.py @@ -621,10 +621,6 @@ class TableFinder(object): v_explicit = [] for desc in settings.explicit_vertical_lines or []: if isinstance(desc, dict): - ...
["tests/test_ca_warn_report.py::Test::test_parse", "tests/test_issues.py::Test::test_pr_138", "tests/test_nics_report.py::Test::test_plain", "tests/test_table.py::Test::test_explicit_desc_decimalization"]
["tests/test_basics.py::Test::test_annots", "tests/test_basics.py::Test::test_annots_cropped", "tests/test_basics.py::Test::test_annots_rotated", "tests/test_basics.py::Test::test_bad_fileobj", "tests/test_basics.py::Test::test_colors", "tests/test_basics.py::Test::test_crop_and_filter", "tests/test_basics.py::Test::te...
jyangballin/swesmith.x86_64.jsvine_1776_pdfplumber.02ff4313
true
null
1
10
4
1,206
0
0.6
1
0.75
1
0.234333
80.978
7,066
swe_smith::train::1740
swe_smith
train
1,740
agronholm__typeguard.b6a7e438.func_basic__1vy7d8i5
swesmith/agronholm__typeguard.b6a7e438
agronholm/typeguard
python
null
Type checking fails silently when typecheck_fail_callback is None #### Description When `typecheck_fail_callback` is set to `None`, type checking errors are being silently ignored instead of raising exceptions. This breaks the expected behavior where type violations should raise `TypeCheckError` by default. #### Ste...
diff --git a/src/typeguard/_functions.py b/src/typeguard/_functions.py index ca21c14..31fd4e0 100644 --- a/src/typeguard/_functions.py +++ b/src/typeguard/_functions.py @@ -128,20 +128,20 @@ def check_argument_types( exc = TypeCheckError( f"{func_name}() was declared never to be called but...
["tests/test_importhook.py::test_blanket_import", "tests/test_instrumentation.py::test_type_checked_func_error[typechecked]", "tests/test_instrumentation.py::test_type_checked_method[typechecked]", "tests/test_instrumentation.py::test_type_checked_classmethod[typechecked]", "tests/test_instrumentation.py::test_type_che...
["tests/mypy/test_type_annotations.py::test_positive", "tests/mypy/test_type_annotations.py::test_negative", "tests/test_checkers.py::TestAnyStr::test_valid[str]", "tests/test_checkers.py::TestAnyStr::test_valid[bytes]", "tests/test_checkers.py::TestAnyStr::test_bad_type", "tests/test_checkers.py::TestBytesLike::test_v...
jyangballin/swesmith.x86_64.agronholm_1776_typeguard.b6a7e438
true
null
1
10
40
1,206
0
0.6
1
0.75
1
0.234333
80.978
7,067
r2e_gym::train::6475
r2e_gym
train
6,475
pillow__b9b5d39f2b32cec75b9cf96b882acb7a77a4ed4b
pillow
python-pillow/pillow
python
b9b5d39f2b32cec75b9cf96b882acb7a77a4ed4b
**Title:** `Image` object lacks `alpha_composite` method causing AttributeError **Description:** When attempting to use the `alpha_composite` method on an `Image` object, an `AttributeError` is raised because the method does not exist. This prevents users from compositing images with alpha transparency as intended. *...
diff --git a/PIL/Image.py b/PIL/Image.py --- a/PIL/Image.py +++ b/PIL/Image.py @@ -1376,6 +1376,54 @@ else: self.im.paste(im, box) + def alpha_composite(self, im, dest=(0,0), source=(0,0)): + """ 'In-place' analog of Image.alpha_composite. Composites an image + onto this image. ...
diff --git a/Tests/test_image.py b/Tests/test_image.py --- a/Tests/test_image.py +++ b/Tests/test_image.py @@ -201,6 +201,44 @@ # Assert img_colors = sorted(img.getcolors()) self.assertEqual(img_colors, expected_colors) + + def test_alpha_inplace(self): + src = Image.new('RGBA', (12...
null
null
namanjain12/pillow_final:b9b5d39f2b32cec75b9cf96b882acb7a77a4ed4b
true
null
2
50
null
1,118
0
0.75
1
0.6375
1
0.353
80.97775
7,068
swe_smith::train::29258
swe_smith
train
29,258
tox-dev__pipdeptree.c31b6418.pr_227
swesmith/tox-dev__pipdeptree.c31b6418
tox-dev/pipdeptree
python
null
### Description Encountered an indentation error in the `pipdeptree` module. It seems like there's a problem with the indentation level in the `__init__.py` file, which is causing an import error when trying to load the module. ### How to Reproduce 1. Ensure you have the latest version of the `pipdeptree` module. 2....
diff --git a/src/pipdeptree/__init__.py b/src/pipdeptree/__init__.py index e69de29..4ec28a0 100644 --- a/src/pipdeptree/__init__.py +++ b/src/pipdeptree/__init__.py @@ -0,0 +1,8 @@ +def get_parser(): + "--mermaid", + action="store_true", + default=False, + help=("Display dependency tree as a...
["tests/_models/test_dag.py::test_package_dag_get_node_as_parent", "tests/_models/test_dag.py::test_package_dag_filter_fnmatch_include_a", "tests/_models/test_dag.py::test_package_dag_filter_fnmatch_include_b", "tests/_models/test_dag.py::test_package_dag_filter_fnmatch_exclude_c", "tests/_models/test_dag.py::test_pack...
[]
jyangballin/swesmith.x86_64.tox-dev_1776_pipdeptree.c31b6418
true
null
1
8
125
1,245
0
0.6
1
0.75
1
0.234167
80.9775
7,069
swe_smith::train::25893
swe_smith
train
25,893
pylint-dev__astroid.b114f6b5.func_basic__piu8grkj
swesmith/pylint-dev__astroid.b114f6b5
pylint-dev/astroid
python
null
Lambda getattr returns empty list instead of raising AttributeInferenceError #### Description When calling `getattr` on a lambda function with a non-existent attribute, the method returns an empty list instead of raising an `AttributeInferenceError` as expected. #### Steps/Code to Reproduce ```python import astroid...
diff --git a/astroid/nodes/scoped_nodes/scoped_nodes.py b/astroid/nodes/scoped_nodes/scoped_nodes.py index 99ed796..d13e56b 100644 --- a/astroid/nodes/scoped_nodes/scoped_nodes.py +++ b/astroid/nodes/scoped_nodes/scoped_nodes.py @@ -1054,13 +1054,13 @@ class Lambda(_base_nodes.FilterStmtsBaseNode, LocalsDictNodeNG): ...
["tests/test_inference.py::HasattrTest::test_lambda", "tests/test_scoped_nodes.py::FunctionNodeTest::test_lambda_getattr"]
["tests/brain/numpy/test_core_einsumfunc.py::test_numpy_function_calls_inferred_as_ndarray", "tests/brain/numpy/test_core_einsumfunc.py::test_function_parameters", "tests/brain/numpy/test_core_fromnumeric.py::BrainNumpyCoreFromNumericTest::test_numpy_function_calls_inferred_as_ndarray", "tests/brain/numpy/test_core_fun...
jyangballin/swesmith.x86_64.pylint-dev_1776_astroid.b114f6b5
true
null
1
8
2
1,245
0
0.6
1
0.75
1
0.234167
80.9775
7,070
swe_smith::train::20671
swe_smith
train
20,671
tobymao__sqlglot.036601ba.func_pm_ctrl_shuffle__m52thc0b
swesmith/tobymao__sqlglot.036601ba
tobymao/sqlglot
python
null
JSON_TABLE parsing fails with NESTED columns #### Description When parsing JSON_TABLE expressions with NESTED columns, the parser produces incorrect results due to variables being referenced before assignment. #### Steps/Code to Reproduce ```python import sqlglot # This should parse correctly but fails sql = """ S...
diff --git a/sqlglot/parser.py b/sqlglot/parser.py index 248a128..5c42089 100644 --- a/sqlglot/parser.py +++ b/sqlglot/parser.py @@ -6496,17 +6496,8 @@ class Parser(metaclass=_Parser): # Note: this is currently incomplete; it only implements the "JSON_value_column" part def _parse_json_column_def(self) -> e...
["tests/dialects/test_mysql.py::TestMySQL::test_ddl", "tests/dialects/test_oracle.py::TestOracle::test_json_table"]
["tests/dialects/test_athena.py::TestAthena::test_athena", "tests/dialects/test_athena.py::TestAthena::test_ctas", "tests/dialects/test_athena.py::TestAthena::test_ddl", "tests/dialects/test_athena.py::TestAthena::test_ddl_quoting", "tests/dialects/test_athena.py::TestAthena::test_dml", "tests/dialects/test_athena.py::...
jyangballin/swesmith.x86_64.tobymao_1776_sqlglot.036601ba
true
null
1
19
2
1,025
0
0.6
1
0.75
1
0.234167
80.9775
7,071
swe_smith::train::32667
swe_smith
train
32,667
pydantic__pydantic.acb0f10f.func_pm_remove_cond__84wpq7zk
swesmith/pydantic__pydantic.acb0f10f
pydantic/pydantic
python
null
Discriminator allows None tags without validation error #### Description When using `Discriminator` with callable discriminators, `None` tags are now accepted without raising a validation error. This breaks the expected behavior where discriminators should require valid tags for all choices. #### Steps/Code to Repro...
diff --git a/pydantic/types.py b/pydantic/types.py index 02e61dd..b91da7d 100644 --- a/pydantic/types.py +++ b/pydantic/types.py @@ -3092,11 +3092,6 @@ class Discriminator: metadata = cast('CoreMetadata | None', choice.get('metadata')) if metadata is not None: tag = metadata.g...
["tests/test_docs.py::test_docstrings_examples[pydantic/types.py:3186-3211]", "tests/test_docs.py::test_docstrings_examples[pydantic/types.py:3264-3282]"]
["tests/benchmarks/test_attribute_access.py::test_setattr", "tests/benchmarks/test_attribute_access.py::test_getattr", "tests/benchmarks/test_discriminated_unions.py::test_schema_build", "tests/benchmarks/test_discriminated_unions.py::test_efficiency_with_highly_nested_examples", "tests/benchmarks/test_fastapi_startup_...
jyangballin/swesmith.x86_64.pydantic_1776_pydantic.acb0f10f
true
null
1
6
2
1,285
0
0.6
1
0.75
1
0.234167
80.9775
7,072
swe_smith::train::17451
swe_smith
train
17,451
pyasn1__pyasn1.0f07d724.combine_module__vhs8lqps
swesmith/pyasn1__pyasn1.0f07d724
pyasn1/pyasn1
python
null
StreamingDecoder yields unexpected results after recent changes #### Description The StreamingDecoder is not working correctly and appears to be yielding the wrong objects or not yielding at all in certain scenarios. This affects decoding from various stream sources including compressed files and non-blocking streams...
diff --git a/pyasn1/codec/ber/decoder.py b/pyasn1/codec/ber/decoder.py index 7e69ca1..def7855 100644 --- a/pyasn1/codec/ber/decoder.py +++ b/pyasn1/codec/ber/decoder.py @@ -1977,12 +1977,12 @@ class StreamingDecoder(object): yield asn1Object for chunk in isEndOfStream(self._substrate): -...
["tests/codec/ber/test_decoder.py::NonStringDecoderTestCase::testAny", "tests/codec/ber/test_decoder.py::NonStringDecoderTestCase::testOctetString", "tests/codec/ber/test_decoder.py::BinaryFileTestCase::testMoreObjects", "tests/codec/ber/test_decoder.py::BinaryFileTestCase::testOneObject", "tests/codec/ber/test_decoder...
["tests/codec/ber/test_decoder.py::LargeTagDecoderTestCase::testLargeTag", "tests/codec/ber/test_decoder.py::LargeTagDecoderTestCase::testLongTag", "tests/codec/ber/test_decoder.py::LargeTagDecoderTestCase::testTagsEquivalence", "tests/codec/ber/test_decoder.py::DecoderCacheTestCase::testCache", "tests/codec/ber/test_d...
jyangballin/swesmith.x86_64.pyasn1_1776_pyasn1.0f07d724
true
null
2
8
10
1,244
0
0.6
1
0.75
1
0.234
80.977
7,073
swe_smith::train::20342
swe_smith
train
20,342
gruns__furl.da386f68.func_pm_ctrl_shuffle__rj2kzpar
swesmith/gruns__furl.da386f68
gruns/furl
python
null
furl constructor fails with UnboundLocalError when parsing URLs #### Description When creating a furl object with a URL string, the constructor raises an `UnboundLocalError: local variable 'url' referenced before assignment`. This affects basic URL parsing functionality. #### Steps/Code to Reproduce ```python impor...
diff --git a/furl/furl.py b/furl/furl.py index cd6d710..9ad7df8 100644 --- a/furl/furl.py +++ b/furl/furl.py @@ -1393,28 +1393,27 @@ class furl(URLPathCompositionInterface, QueryCompositionInterface, Raises: ValueError on invalid URL, like a malformed IPv6 address or invalid port. """ + ...
["tests/test_furl.py::TestPath::test_add", "tests/test_furl.py::TestPath::test_encoding", "tests/test_furl.py::TestPath::test_equality", "tests/test_furl.py::TestPath::test_isabsolute", "tests/test_furl.py::TestQuery::test_equality", "tests/test_furl.py::TestQuery::test_special_characters", "tests/test_furl.py::TestFra...
["tests/test_furl.py::TestPath::test_asdict", "tests/test_furl.py::TestPath::test_isdir_isfile", "tests/test_furl.py::TestPath::test_itruediv", "tests/test_furl.py::TestPath::test_leading_slash", "tests/test_furl.py::TestPath::test_load", "tests/test_furl.py::TestPath::test_none", "tests/test_furl.py::TestPath::test_no...
jyangballin/swesmith.x86_64.gruns_1776_furl.da386f68
true
null
1
23
31
944
0
0.6
1
0.75
1
0.234
80.977
7,074
swe_smith::train::31532
swe_smith
train
31,532
benoitc__gunicorn.bacbf8aa.func_basic__jdstad25
swesmith/benoitc__gunicorn.bacbf8aa
benoitc/gunicorn
python
null
Config validation returns wrong type when callable import fails #### Description When using import strings for callable configuration options, the validation function returns incorrect types instead of raising proper exceptions. This causes downstream code to fail with confusing error messages. #### Steps/Code to Re...
diff --git a/gunicorn/config.py b/gunicorn/config.py index 402a26b..a92baf4 100644 --- a/gunicorn/config.py +++ b/gunicorn/config.py @@ -439,17 +439,17 @@ def validate_callable(arity): raise TypeError("Value '%s' is not import string. " "Format: module[.submodules...].o...
["tests/test_arbiter.py::test_arbiter_stop_closes_listeners", "tests/test_arbiter.py::test_arbiter_stop_child_does_not_unlink_listeners", "tests/test_arbiter.py::test_arbiter_stop_parent_does_not_unlink_listeners", "tests/test_arbiter.py::test_arbiter_stop_does_not_unlink_systemd_listeners", "tests/test_arbiter.py::tes...
["tests/test_http.py::test_method_pattern", "tests/test_http.py::test_readline_empty_body", "tests/test_http.py::test_readline_zero_size", "tests/test_http.py::test_readline_new_line_before_size", "tests/test_http.py::test_readline_new_line_after_size", "tests/test_http.py::test_readline_no_new_line", "tests/test_http....
jyangballin/swesmith.x86_64.benoitc_1776_gunicorn.bacbf8aa
true
null
1
12
171
1,163
0
0.6
1
0.75
1
0.233833
80.9765
7,075
swe_smith::train::28703
swe_smith
train
28,703
encode__starlette.db5063c2.func_basic__w7v9evr6
swesmith/encode__starlette.db5063c2
encode/starlette
python
null
Error page traceback frames displayed in wrong order #### Description When using ServerErrorMiddleware with debug=True, the traceback frames in the HTML error page are displayed in the wrong order. The frames appear to be reversed from what they should be, making it difficult to follow the execution flow when debuggi...
diff --git a/starlette/middleware/errors.py b/starlette/middleware/errors.py index 76ad776..c453bfd 100644 --- a/starlette/middleware/errors.py +++ b/starlette/middleware/errors.py @@ -226,21 +226,21 @@ class ServerErrorMiddleware: traceback_obj = traceback.TracebackException.from_exception(exc, capture_locals...
["tests/middleware/test_errors.py::test_debug_html[asyncio]", "tests/middleware/test_errors.py::test_debug_html[trio]"]
["tests/middleware/test_base.py::test_custom_middleware[asyncio]", "tests/middleware/test_base.py::test_state_data_across_multiple_middlewares[asyncio]", "tests/middleware/test_base.py::test_app_middleware_argument[asyncio]", "tests/middleware/test_base.py::test_fully_evaluated_response[asyncio]", "tests/middleware/tes...
jyangballin/swesmith.x86_64.encode_1776_starlette.db5063c2
true
null
1
14
2
1,123
0
0.6
1
0.75
1
0.233833
80.9765
7,076
swe_smith::train::31771
swe_smith
train
31,771
davidhalter__parso.338a5760.combine_file__8yjnfpws
swesmith/davidhalter__parso.338a5760
davidhalter/parso
python
null
DiffParser returns integer instead of node in _get_old_line_stmt When using the DiffParser, the `_get_old_line_stmt` method is returning an integer `0` instead of a proper node object in certain cases. This causes AttributeError when the returned value is used as if it were a node. #### Steps/Code to Reproduce ```py...
diff --git a/parso/python/diff.py b/parso/python/diff.py index ba999fa..3d43278 100644 --- a/parso/python/diff.py +++ b/parso/python/diff.py @@ -65,11 +65,11 @@ def _get_next_leaf_if_indentation(leaf): def _get_suite_indentation(tree_node): - return _get_indentation(tree_node.children[1]) + return _get_inden...
["test/test_diff_parser.py::test_change_and_undo", "test/test_diff_parser.py::test_positions", "test/test_diff_parser.py::test_if_simple", "test/test_diff_parser.py::test_func_with_for_and_comment", "test/test_diff_parser.py::test_one_statement_func", "test/test_diff_parser.py::test_for_on_one_line", "test/test_diff_pa...
["parso/__init__.py::parso", "parso/python/tree.py::parso.python.tree", "parso/tree.py::parso.tree.NodeOrLeaf.dump", "test/test_cache.py::test_modulepickling_change_cache_dir", "test/test_cache.py::test_modulepickling_simulate_deleted_cache", "test/test_cache.py::test_cache_limit", "test/test_cache.py::test_cache_last_...
jyangballin/swesmith.x86_64.davidhalter_1776_parso.338a5760
true
null
1
17
75
1,063
0
0.6
1
0.75
1
0.233833
80.9765
7,077
swe_smith::train::19261
swe_smith
train
19,261
seperman__deepdiff.ed252022.func_pm_remove_assign__oevu60k3
swesmith/seperman__deepdiff.ed252022
seperman/deepdiff
python
null
Path extraction fails with UnboundLocalError when accessing nested objects #### Description When using deepdiff's path functionality to access nested objects, an `UnboundLocalError` is raised for the variable `_prev_obj`. This occurs during path traversal operations that involve getting nested attributes or dictionar...
diff --git a/deepdiff/path.py b/deepdiff/path.py index ee63b5b..6f2156d 100644 --- a/deepdiff/path.py +++ b/deepdiff/path.py @@ -135,25 +135,20 @@ def _guess_type(elements, elem, index, next_element): def _get_nested_obj_and_force(obj, elements, next_element=None): - prev_elem = None prev_action = None ...
["tests/test_delta.py::TestDeltaCompareFunc::test_delta_force1", "tests/test_delta.py::TestDeltaCompareFunc::test_flatten_dict_with_one_key_added", "tests/test_delta.py::TestDeltaCompareFunc::test_flatten_list_with_one_item_added", "tests/test_delta.py::TestDeltaCompareFunc::test_flatten_set_with_one_item_added", "test...
["tests/test_anyset.py::TestAnySet::test_anyset_init1", "tests/test_anyset.py::TestAnySet::test_anyset_init2", "tests/test_anyset.py::TestAnySet::test_anyset_init3_add", "tests/test_anyset.py::TestAnySet::test_anyset_pop1", "tests/test_anyset.py::TestAnySet::test_iter_anyset", "tests/test_cache.py::TestCache::test_cach...
jyangballin/swesmith.x86_64.seperman_1776_deepdiff.ed252022
true
null
1
7
9
1,263
0
0.6
1
0.75
1
0.233833
80.9765
7,078
swe_smith::train::24613
swe_smith
train
24,613
marshmallow-code__marshmallow.9716fc62.combine_module__zv4fhthn
swesmith/marshmallow-code__marshmallow.9716fc62
marshmallow-code/marshmallow
python
null
NoneOf validator returns None instead of value and validates incorrectly #### Description The `NoneOf` validator is not working as expected. It's returning `None` for all inputs instead of the original value, and the validation logic appears to be inverted. #### Steps/Code to Reproduce ```python from marshmallow im...
diff --git a/src/marshmallow/decorators.py b/src/marshmallow/decorators.py index 965edb6..472ca20 100644 --- a/src/marshmallow/decorators.py +++ b/src/marshmallow/decorators.py @@ -119,9 +119,9 @@ def validates_schema( return set_hook( fn, VALIDATES_SCHEMA, - many=pass_many, - pass_...
["tests/test_decorators.py::TestValidatesSchemaDecorator::test_validator_nested_many_pass_original_and_pass_many[False-expected_data1-expected_original_data1-data0]", "tests/test_decorators.py::TestValidatesSchemaDecorator::test_decorated_validators", "tests/test_decorators.py::TestValidatesSchemaDecorator::test_passin...
["tests/test_decorators.py::test_decorated_processors[True]", "tests/test_decorators.py::test_decorated_processors[False]", "tests/test_decorators.py::test_decorated_processor_returning_none[exclude]", "tests/test_decorators.py::test_decorated_processor_returning_none[include]", "tests/test_decorators.py::test_decorate...
jyangballin/swesmith.x86_64.marshmallow-code_1776_marshmallow.9716fc62
true
null
2
12
6
1,162
0
0.6
1
0.75
1
0.233667
80.976
7,079
r2e_gym::train::5681
r2e_gym
train
5,681
scrapy__a06a5f00f4a62028416ada4919994efd7d439eb2
scrapy
scrapy/scrapy
python
a06a5f00f4a62028416ada4919994efd7d439eb2
**Title:** `HttpProxyMiddleware` Does Not Accept `auth_encoding` Parameter, Causing Authentication Encoding Failures **Description:** When attempting to configure the encoding for HTTP proxy authentication, passing the `auth_encoding` parameter to `HttpProxyMiddleware` results in an error. This limitation prevents the...
diff --git a/docs/topics/downloader-middleware.rst b/docs/topics/downloader-middleware.rst --- a/docs/topics/downloader-middleware.rst +++ b/docs/topics/downloader-middleware.rst @@ -951,6 +951,18 @@ Whether the AjaxCrawlMiddleware will be enabled. You may want to enable it for :ref:`broad crawls <topics-broad-crawls...
diff --git a/tests/test_downloadermiddleware_httpproxy.py b/tests/test_downloadermiddleware_httpproxy.py --- a/tests/test_downloadermiddleware_httpproxy.py +++ b/tests/test_downloadermiddleware_httpproxy.py @@ -8,6 +8,7 @@ from scrapy.spiders import Spider spider = Spider('foo') + class TestDefaultHeadersMiddlew...
null
null
namanjain12/scrapy_final:a06a5f00f4a62028416ada4919994efd7d439eb2
true
null
3
27
null
1,574
0
0.75
1
0.6375
1
0.352333
80.97575
7,080
r2e_gym::train::6358
r2e_gym
train
6,358
pillow__488691bda4b92711aa3b96eebe074febc3375633
pillow
python-pillow/pillow
python
488691bda4b92711aa3b96eebe074febc3375633
**Title:** Error Accessing Rational Metadata Tag Attributes Due to Incorrect Parsing **Description:** When handling TIFF images, setting a metadata tag with a rational value and then reloading the image leads to an unexpected structure for the tag. Specifically, tags that are supposed to contain a single rational numb...
diff --git a/PIL/TiffImagePlugin.py b/PIL/TiffImagePlugin.py --- a/PIL/TiffImagePlugin.py +++ b/PIL/TiffImagePlugin.py @@ -550,11 +550,28 @@ dest = self._tags_v1 if legacy_api else self._tags_v2 - if info.length == 1: - if legacy_api and self.tagtype[tag] in [5, 10]: + # Three bran...
diff --git a/Tests/test_file_tiff_metadata.py b/Tests/test_file_tiff_metadata.py --- a/Tests/test_file_tiff_metadata.py +++ b/Tests/test_file_tiff_metadata.py @@ -202,8 +202,8 @@ im.save(out, tiffinfo=info, compression='raw') reloaded = Image.open(out) - self.assertEqual(0, reloaded.tag_v2[41...
null
null
namanjain12/pillow_final:488691bda4b92711aa3b96eebe074febc3375633
true
null
2
25
null
1,614
0
0.75
1
0.6375
1
0.352333
80.97575
7,081
swe_smith::train::27799
swe_smith
train
27,799
arrow-py__arrow.1d70d009.lm_rewrite__76bcuvzu
swesmith/arrow-py__arrow.1d70d009
arrow-py/arrow
python
null
# normalize_timestamp doesn't raise ValueError for timestamps larger than MAX_TIMESTAMP_US When using the `normalize_timestamp` function with extremely large timestamp values, it no longer raises a ValueError as expected. This can lead to unexpected behavior when working with timestamp values. ## Steps to reproduce ...
diff --git a/arrow/util.py b/arrow/util.py index f3eaa21..c113d6d 100644 --- a/arrow/util.py +++ b/arrow/util.py @@ -73,15 +73,14 @@ def validate_ordinal(value: Any) -> None: def normalize_timestamp(timestamp: float) -> float: """Normalize millisecond and microsecond timestamps into normal timestamps.""" if ...
["tests/test_parser.py::TestDateTimeParserParse::test_parse_expanded_timestamp", "tests/test_util.py::TestUtil::test_normalize_timestamp"]
["tests/test_api.py::TestModule::test_get", "tests/test_api.py::TestModule::test_utcnow", "tests/test_api.py::TestModule::test_now", "tests/test_api.py::TestModule::test_factory", "tests/test_arrow.py::TestTestArrowInit::test_init_bad_input", "tests/test_arrow.py::TestTestArrowInit::test_init", "tests/test_arrow.py::Te...
jyangballin/swesmith.x86_64.arrow-py_1776_arrow.1d70d009
true
null
1
13
2
1,141
0
0.6
1
0.75
1
0.2335
80.9755
7,082
swe_smith::train::36516
swe_smith
train
36,516
lincolnloop__python-qrcode.456b01d4.combine_module__b34pj15y
swesmith/lincolnloop__python-qrcode.456b01d4
lincolnloop/python-qrcode
python
null
# QR Code generation broken in multiple ways ### Steps to reproduce I'm trying to generate QR codes using the library and encountering multiple issues: 1. When trying to save a PNG image: ```python import qrcode qr = qrcode.QRCode() qr.add_data("test data") img = qr.make_image(image_factory=qrcode.image.pure.PyPNGI...
diff --git a/qrcode/image/pure.py b/qrcode/image/pure.py index 5a8b2c5..0070716 100644 --- a/qrcode/image/pure.py +++ b/qrcode/image/pure.py @@ -26,8 +26,8 @@ class PyPNGImage(BaseImage): def save(self, stream, kind=None): if isinstance(stream, str): - stream = open(stream, "wb") - sel...
["qrcode/tests/test_qrcode_pypng.py::test_render_pypng", "qrcode/tests/test_qrcode_pypng.py::test_render_pypng_to_str", "qrcode/tests/test_script.py::test_factory_drawer"]
["qrcode/tests/test_example.py::test_example", "qrcode/tests/test_qrcode.py::test_basic", "qrcode/tests/test_qrcode.py::test_large", "qrcode/tests/test_qrcode.py::test_invalid_version", "qrcode/tests/test_qrcode.py::test_invalid_border", "qrcode/tests/test_qrcode.py::test_overflow", "qrcode/tests/test_qrcode.py::test_a...
jyangballin/swesmith.x86_64.lincolnloop_1776_python-qrcode.456b01d4
true
null
2
10
3
1,201
0
0.6
1
0.75
1
0.2335
80.9755
7,083
swe_smith::train::46614
swe_smith
train
46,614
python-trio__trio.cfbbe2c1.combine_file__f6zhi437
swesmith/python-trio__trio.cfbbe2c1
python-trio/trio
python
null
SocketListener missing aclose method #### Description After recent changes, `SocketListener` no longer has an `aclose()` method, causing `TypeError` when trying to close listeners properly. #### Steps/Code to Reproduce ```python import trio async def main(): listeners = await trio.open_tcp_listeners(0) lis...
diff --git a/src/trio/_highlevel_socket.py b/src/trio/_highlevel_socket.py index c04e66e..1fbf23f 100644 --- a/src/trio/_highlevel_socket.py +++ b/src/trio/_highlevel_socket.py @@ -37,10 +37,10 @@ def _translate_socket_errors_to_stream_errors() -> Generator[None, None, None]: try: yield except OSErro...
["src/trio/_tests/test_highlevel_open_tcp_listeners.py::test_open_tcp_listeners_basic", "src/trio/_tests/test_highlevel_open_tcp_listeners.py::test_open_tcp_listeners_specific_port_specific_host", "src/trio/_tests/test_highlevel_open_tcp_listeners.py::test_open_tcp_listeners_ipv6_v6only", "src/trio/_tests/test_highleve...
["src/trio/_core/_tests/test_asyncgen.py::test_asyncgen_basics", "src/trio/_core/_tests/test_asyncgen.py::test_asyncgen_throws_during_finalization", "src/trio/_core/_tests/test_asyncgen.py::test_firstiter_after_closing", "src/trio/_core/_tests/test_asyncgen.py::test_interdependent_asyncgen_cleanup_order", "src/trio/_co...
jyangballin/swesmith.x86_64.python-trio_1776_trio.cfbbe2c1
true
null
1
21
26
981
0
0.6
1
0.75
1
0.2335
80.9755
7,084
swe_smith::train::24015
swe_smith
train
24,015
sunpy__sunpy.f8edfd5c.func_pm_ctrl_shuffle__gxyl3gup
swesmith/sunpy__sunpy.f8edfd5c
sunpy/sunpy
python
null
Map.date property returns undefined variable after accessing date-related metadata #### Description When accessing the `date` property on a Map object, an `UnboundLocalError` is raised because the variable `time` is referenced before being defined in the property method. #### Steps/Code to Reproduce ```python impor...
diff --git a/sunpy/map/mapbase.py b/sunpy/map/mapbase.py index bdcac77..b4ba889 100644 --- a/sunpy/map/mapbase.py +++ b/sunpy/map/mapbase.py @@ -987,6 +987,16 @@ class GenericMap(NDData): @property def date(self): + + if time is None: + if self._default_time is None: + warn_...
["sunpy/map/tests/test_mapbase.py::test_wcs", "sunpy/map/tests/test_mapbase.py::test_wcs_pv", "sunpy/map/tests/test_mapbase.py::test_wcs_cache", "sunpy/map/tests/test_mapbase.py::test_header_immutability", "sunpy/map/tests/test_mapbase.py::test_name", "sunpy/map/tests/test_mapbase.py::test_date[keys0-expected_date0]", ...
["sunpy/map/tests/test_mapbase.py::test_notes_combined", "sunpy/map/tests/test_mapbase.py::test_notes_combined_no_references", "sunpy/map/tests/test_mapbase.py::test_notes_combined_no_existing_notes", "sunpy/map/tests/test_mapbase.py::test_notes_combined_no_notes_no_references", "sunpy/map/tests/test_mapbase.py::test_f...
jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c
true
null
1
21
80
981
0
0.6
1
0.75
1
0.2335
80.9755
7,085
swe_smith::train::5019
swe_smith
train
5,019
bottlepy__bottle.a8dfef30.lm_rewrite__2dlm381n
swesmith/bottlepy__bottle.a8dfef30
bottlepy/bottle
python
null
### Bug: Template Rendering Issue with View Decorator #### Description After the recent changes, it seems that the view decorator is not rendering templates as expected. The issue arises when using the view decorator with specific template strings or options, leading to unexpected output or errors. #### Steps to Rep...
diff --git a/bottle.py b/bottle.py index 286b5bc..0d8ad7c 100755 --- a/bottle.py +++ b/bottle.py @@ -4501,20 +4501,15 @@ def view(tpl_name, **defaults): """ def decorator(func): - @functools.wraps(func) def wrapper(*args, **kwargs): result = func(*args, **kwargs) ...
["test/test_jinja2.py::TestJinja2Template::test_view_decorator", "test/test_stpl.py::TestSimpleTemplate::test_view_decorator", "test/test_stpl.py::TestSimpleTemplate::test_view_decorator_issue_407", "test/test_wsgi.py::TestRouteDecorator::test_template", "test/test_wsgi.py::TestRouteDecorator::test_template_opts", "tes...
["test/test_app.py::TestApplicationObject::test_setattr", "test/test_auth.py::TestBasicAuth::test__header", "test/test_config.py::TestConfDict::test_gc_overlays", "test/test_config.py::TestConfDict::test_isadict", "test/test_config.py::TestConfDict::test_load_dict", "test/test_config.py::TestConfDict::test_load_module"...
jyangballin/swesmith.x86_64.bottlepy_1776_bottle.a8dfef30
true
null
1
7
6
1,261
0
0.6
1
0.75
1
0.2335
80.9755
7,086
swe_bench::test::969
swe_bench
test
969
matplotlib__matplotlib-20761
matplotlib/matplotlib
matplotlib/matplotlib
python
7413aa92b5be5760c73e31641ab0770f328ad546
[Bug]: subfigure position shifts on y-axis when x kwarg added to supxlabel ### Bug summary Location of subfigure shifts lower on y-axis when 'x' kwarg is used for supxlabel for that subfigure. I've also posted to StackOverflow: https://stackoverflow.com/q/68567315/9249533 ### Code for reproduction ```python fig = pl...
This has nothing to do with subfigures, right? This happens if you specify x or y in supx/ylabel even on a normal figure, I think. Not sure. I've only used suptitles to date. Will do some more digging. Cheers ```python import matplotlib.pyplot as plt fig, ax = plt.subplots(constrained_layout=True) fig.supx...
diff --git a/lib/matplotlib/figure.py b/lib/matplotlib/figure.py --- a/lib/matplotlib/figure.py +++ b/lib/matplotlib/figure.py @@ -370,7 +370,10 @@ def _suplabels(self, t, info, **kwargs): x = kwargs.pop('x', None) y = kwargs.pop('y', None) - autopos = x is None and y is None + if info...
diff --git a/lib/matplotlib/tests/test_constrainedlayout.py b/lib/matplotlib/tests/test_constrainedlayout.py --- a/lib/matplotlib/tests/test_constrainedlayout.py +++ b/lib/matplotlib/tests/test_constrainedlayout.py @@ -537,3 +537,26 @@ def test_align_labels(): after_align[1].x0, rtol=0, ...
["lib/matplotlib/tests/test_constrainedlayout.py::test_suplabels"]
["lib/matplotlib/tests/test_constrainedlayout.py::test_constrained_layout1[png]", "lib/matplotlib/tests/test_constrainedlayout.py::test_constrained_layout2[png]", "lib/matplotlib/tests/test_constrainedlayout.py::test_constrained_layout3[png]", "lib/matplotlib/tests/test_constrainedlayout.py::test_constrained_layout4[pn...
null
true
2021-07-28T22:36:30Z
1
5
1
2,050
0
0.8
1
0.7
0.8
0.358333
80.975
7,087
swe_smith::train::31592
swe_smith
train
31,592
benoitc__gunicorn.bacbf8aa.func_pm_class_rm_funcs__qhp1r6ts
swesmith/benoitc__gunicorn.bacbf8aa
benoitc/gunicorn
python
null
Worker signal handlers removed causing AttributeError in reload functionality #### Description When using gunicorn with reload functionality, workers are failing with AttributeError because signal handler methods have been removed from the Worker base class. #### Steps/Code to Reproduce ```python from gunicorn.work...
diff --git a/gunicorn/workers/base.py b/gunicorn/workers/base.py index 93c465c..bb3b389 100644 --- a/gunicorn/workers/base.py +++ b/gunicorn/workers/base.py @@ -185,9 +185,6 @@ class Worker: if hasattr(signal, 'set_wakeup_fd'): signal.set_wakeup_fd(self.PIPE[1]) - def handle_usr1(self, sig, f...
["tests/test_reload.py::test_reload_on_syntax_error", "tests/test_reload.py::test_start_reloader_after_load_wsgi"]
["tests/test_arbiter.py::test_arbiter_stop_closes_listeners", "tests/test_arbiter.py::test_arbiter_stop_child_does_not_unlink_listeners", "tests/test_arbiter.py::test_arbiter_stop_parent_does_not_unlink_listeners", "tests/test_arbiter.py::test_arbiter_stop_does_not_unlink_systemd_listeners", "tests/test_arbiter.py::tes...
jyangballin/swesmith.x86_64.benoitc_1776_gunicorn.bacbf8aa
true
null
1
14
2
1,120
0
0.6
1
0.75
1
0.233333
80.975
7,088
swe_smith::train::39841
swe_smith
train
39,841
tornadoweb__tornado.d5ac65c1.func_pm_remove_assign__3hk3g4ng
swesmith/tornadoweb__tornado.d5ac65c1
tornadoweb/tornado
python
null
StaticFileHandler crashes with NameError when If-Modified-Since header is present #### Description When serving static files with an If-Modified-Since header, the StaticFileHandler raises a NameError because `ims_value` is referenced but not defined in the current scope. #### Steps/Code to Reproduce ```python impor...
diff --git a/tornado/web.py b/tornado/web.py index 357c5f1..94777a0 100644 --- a/tornado/web.py +++ b/tornado/web.py @@ -2856,23 +2856,18 @@ class StaticFileHandler(RequestHandler): # If client sent If-None-Match, use it, ignore If-Modified-Since if self.request.headers.get("If-None-Match"): ...
["test_serve (tornado.test.web_test.CustomStaticFileTest)", "test_gzip_static (tornado.test.web_test.GzipTestCase)", "test_static_default_filename (tornado.test.web_test.StaticDefaultFilenameTest)", "test_root_static_path (tornado.test.web_test.StaticFileTest)", "test_static_304_etag_modified_bug (tornado.test.web_test...
["Doctest: tornado.httputil.HTTPHeaders", "Doctest: tornado.httputil.HTTPHeaders.parse", "Doctest: tornado.httputil.HTTPHeaders.parse_line", "Doctest: tornado.httputil._encode_header", "Doctest: tornado.httputil._get_content_range", "Doctest: tornado.httputil._normalize_header", "Doctest: tornado.httputil._parse_header...
jyangballin/swesmith.x86_64.tornadoweb_1776_tornado.d5ac65c1
true
null
1
7
28
1,260
0
0.6
1
0.75
1
0.233333
80.975
7,089
swe_smith::train::36328
swe_smith
train
36,328
facelessuser__soupsieve.a8080d97.func_pm_ctrl_invert_if__yzlxpvf7
swesmith/facelessuser__soupsieve.a8080d97
facelessuser/soupsieve
python
null
[Bug]: Version parsing logic is reversed for pre-release versions ### Bug summary In version 2.6.0, there's an issue with the version parsing logic in `parse_version()` function. The conditional logic for handling pre-release versions is reversed, causing version parsing to fail. ### Code for reproduction ```python...
diff --git a/soupsieve/__meta__.py b/soupsieve/__meta__.py index 0fbf71b..a9a0bbc 100644 --- a/soupsieve/__meta__.py +++ b/soupsieve/__meta__.py @@ -173,11 +173,11 @@ def parse_version(ver: str) -> Version: # Handle pre releases if m.group('type'): - release = PRE_REL_MAP[m.group('type')] - pr...
["tests/test_versions.py::TestVersion::test_version_parsing"]
["tests/test_api.py::TestSoupSieve::test_cache", "tests/test_api.py::TestSoupSieve::test_closest_match_complex_parent", "tests/test_api.py::TestSoupSieve::test_closest_match_parent", "tests/test_api.py::TestSoupSieve::test_closest_match_self", "tests/test_api.py::TestSoupSieve::test_closest_must_be_parent", "tests/test...
jyangballin/swesmith.x86_64.facelessuser_1776_soupsieve.a8080d97
true
null
1
7
1
1,260
0
0.6
1
0.75
1
0.233333
80.975
7,090
swe_smith::train::42320
swe_smith
train
42,320
scanny__python-pptx.278b47b1.lm_rewrite__qhljutqe
swesmith/scanny__python-pptx.278b47b1
scanny/python-pptx
python
null
Bubble Chart Type Detection Fails with ValueError When attempting to determine the chart type for a bubble chart, a ValueError is raised unexpectedly. This occurs when the bubble chart is supposed to be identified as having a 3D effect, but the detection mechanism fails to recognize it correctly. To reproduce the iss...
diff --git a/src/pptx/chart/plot.py b/src/pptx/chart/plot.py index 6e72358..bc75649 100644 --- a/src/pptx/chart/plot.py +++ b/src/pptx/chart/plot.py @@ -313,21 +313,24 @@ class PlotTypeInspector(object): }[barChart.grouping_val] raise ValueError("invalid barChart.barDir value '%s'" % barChart.barD...
["tests/chart/test_plot.py::DescribePlotTypeInspector::it_can_determine_the_chart_type_of_a_plot[chart_type_fixture42]", "tests/chart/test_plot.py::DescribePlotTypeInspector::it_can_determine_the_chart_type_of_a_plot[chart_type_fixture44]"]
["tests/chart/test_axis.py::Describe_BaseAxis::it_provides_access_to_its_title[c:catAx]", "tests/chart/test_axis.py::Describe_BaseAxis::it_provides_access_to_its_title[c:dateAx]", "tests/chart/test_axis.py::Describe_BaseAxis::it_provides_access_to_its_title[c:valAx]", "tests/chart/test_axis.py::Describe_BaseAxis::it_pr...
jyangballin/swesmith.x86_64.scanny_1776_python-pptx.278b47b1
true
null
1
25
2
900
0
0.6
1
0.75
1
0.233333
80.975
7,091
swe_smith::train::18059
swe_smith
train
18,059
pyasn1__pyasn1.0f07d724.lm_rewrite__xm711v13
swesmith/pyasn1__pyasn1.0f07d724
pyasn1/pyasn1
python
null
Real number operations causing TypeError It seems like there's an issue with handling real numbers in the current implementation. When performing operations on `univ.Real` objects, a `TypeError` is raised unexpectedly. This is affecting various functionalities, including arithmetic operations and conversions. Here's ...
diff --git a/pyasn1/type/univ.py b/pyasn1/type/univ.py index 9aff5e6..4ad1671 100644 --- a/pyasn1/type/univ.py +++ b/pyasn1/type/univ.py @@ -1491,10 +1491,8 @@ class Real(base.SimpleAsn1Type): if self._value in self._inf: return self._value else: - return float( - ...
["tests/codec/ber/test_decoder.py::RealDecoderTestCase::testBin4", "tests/codec/ber/test_decoder.py::RealDecoderTestCase::testChar", "tests/codec/ber/test_decoder.py::RealDecoderTestCase::testEmpty", "tests/codec/ber/test_encoder.py::RealEncoderTestCase::testBin4", "tests/codec/ber/test_encoder.py::RealEncoderTestCase:...
["tests/codec/ber/test_decoder.py::LargeTagDecoderTestCase::testLargeTag", "tests/codec/ber/test_decoder.py::LargeTagDecoderTestCase::testLongTag", "tests/codec/ber/test_decoder.py::LargeTagDecoderTestCase::testTagsEquivalence", "tests/codec/ber/test_decoder.py::DecoderCacheTestCase::testCache", "tests/codec/ber/test_d...
jyangballin/swesmith.x86_64.pyasn1_1776_pyasn1.0f07d724
true
null
1
6
34
1,280
0
0.6
1
0.75
1
0.233333
80.975
7,092
swe_smith::train::31302
swe_smith
train
31,302
scrapy__scrapy.35212ec5.func_pm_remove_loop__a7it6szj
swesmith/scrapy__scrapy.35212ec5
scrapy/scrapy
python
null
BaseItemExporter._get_serialized_fields method missing #### Description The `BaseItemExporter` class is missing the `_get_serialized_fields` method which is essential for field serialization in item exporters. This causes all exporters that inherit from `BaseItemExporter` to fail when trying to export items. #### St...
diff --git a/scrapy/exporters.py b/scrapy/exporters.py index 46c6aa3..c842d79 100644 --- a/scrapy/exporters.py +++ b/scrapy/exporters.py @@ -94,20 +94,6 @@ class BaseItemExporter: else: field_iter = (x for x in self.fields_to_export if x in item) - for field_name in field_iter: - ...
["tests/test_exporters.py::BaseItemExporterTest::test_fields_to_export", "tests/test_exporters.py::BaseItemExporterDataclassTest::test_fields_to_export", "tests/test_exporters.py::PythonItemExporterTest::test_export_dict_item", "tests/test_exporters.py::PythonItemExporterTest::test_export_item", "tests/test_exporters.p...
["tests/test_exporters.py::BaseItemExporterTest::test_export_dict_item", "tests/test_exporters.py::BaseItemExporterTest::test_export_item", "tests/test_exporters.py::BaseItemExporterTest::test_field_custom_serializer", "tests/test_exporters.py::BaseItemExporterTest::test_serialize_field", "tests/test_exporters.py::Base...
jyangballin/swesmith.x86_64.scrapy_1776_scrapy.35212ec5
true
null
1
14
116
1,120
0
0.6
1
0.75
1
0.233333
80.975
7,093
swe_smith::train::18265
swe_smith
train
18,265
msiemens__tinydb.10644a0e.func_basic__g031vx78
swesmith/msiemens__tinydb.10644a0e
msiemens/tinydb
python
null
Table.contains() returns inverted results #### Description The `contains()` method in TinyDB is returning inverted boolean results - it returns `False` when a document exists and `True` when it doesn't exist. #### Steps/Code to Reproduce ```python from tinydb import TinyDB from tinydb.queries import where # Create...
diff --git a/tinydb/table.py b/tinydb/table.py index c562d02..0c62a45 100644 --- a/tinydb/table.py +++ b/tinydb/table.py @@ -358,14 +358,12 @@ class Table: :param doc_id: the document ID to look for """ if doc_id is not None: - # Documents specified by ID - return self.g...
["tests/test_storages.py::test_yaml", "tests/test_tinydb.py::test_insert_multiple[memory]", "tests/test_tinydb.py::test_insert_multiple[json]", "tests/test_tinydb.py::test_contains[memory]", "tests/test_tinydb.py::test_contains[json]", "tests/test_tinydb.py::test_contains_ids[memory]", "tests/test_tinydb.py::test_conta...
["tests/test_middlewares.py::test_caching", "tests/test_middlewares.py::test_caching_read", "tests/test_middlewares.py::test_caching_write_many", "tests/test_middlewares.py::test_caching_flush", "tests/test_middlewares.py::test_caching_flush_manually", "tests/test_middlewares.py::test_caching_write", "tests/test_middle...
jyangballin/swesmith.x86_64.msiemens_1776_tinydb.10644a0e
true
null
1
8
10
1,240
0
0.6
1
0.75
1
0.233333
80.975
7,094
swe_smith::train::41988
swe_smith
train
41,988
scanny__python-pptx.278b47b1.func_pm_class_rm_funcs__m8oxfyr2
swesmith/scanny__python-pptx.278b47b1
scanny/python-pptx
python
null
DataLabel.font property missing after recent changes #### Description The `font` property on `DataLabel` objects is no longer accessible, causing an AttributeError when trying to access font formatting for chart data labels. #### Steps/Code to Reproduce ```python from pptx import Presentation from pptx.chart.datala...
diff --git a/src/pptx/chart/datalabel.py b/src/pptx/chart/datalabel.py index af7cdf5..2ee04bc 100644 --- a/src/pptx/chart/datalabel.py +++ b/src/pptx/chart/datalabel.py @@ -150,21 +150,6 @@ class DataLabel(object): self._ser = self._element = ser self._idx = idx - @lazyproperty - def font(self...
["tests/chart/test_datalabel.py::DescribeDataLabel::it_has_a_font[font_fixture0]", "tests/chart/test_datalabel.py::DescribeDataLabel::it_has_a_font[font_fixture1]"]
["tests/chart/test_axis.py::Describe_BaseAxis::it_provides_access_to_its_title[c:catAx]", "tests/chart/test_axis.py::Describe_BaseAxis::it_provides_access_to_its_title[c:dateAx]", "tests/chart/test_axis.py::Describe_BaseAxis::it_provides_access_to_its_title[c:valAx]", "tests/chart/test_axis.py::Describe_BaseAxis::it_pr...
jyangballin/swesmith.x86_64.scanny_1776_python-pptx.278b47b1
true
null
1
17
2
1,060
0
0.6
1
0.75
1
0.233333
80.975
7,095
swe_smith::train::5002
swe_smith
train
5,002
bottlepy__bottle.a8dfef30.func_pm_remove_cond__0zlkz504
swesmith/bottlepy__bottle.a8dfef30
bottlepy/bottle
python
null
Multipart parser doesn't validate Content-Length header When processing multipart form data, the parser no longer validates that the actual body size matches the Content-Length header specified in individual parts. This allows malformed requests to be processed without proper error handling. #### Steps/Code to Reprod...
diff --git a/bottle.py b/bottle.py index 286b5bc..de769ed 100755 --- a/bottle.py +++ b/bottle.py @@ -3366,16 +3366,11 @@ class _MultipartPart(object): self.headerlist.append((name.strip(), value.strip())) def write_body(self, line, nl): - if not line and not nl: - return # This do...
["test/test_multipart.py::TestBrokenMultipart::test_content_length_to_small"]
["test/test_app.py::TestApplicationObject::test_setattr", "test/test_auth.py::TestBasicAuth::test__header", "test/test_config.py::TestConfDict::test_gc_overlays", "test/test_config.py::TestConfDict::test_isadict", "test/test_config.py::TestConfDict::test_load_dict", "test/test_config.py::TestConfDict::test_load_module"...
jyangballin/swesmith.x86_64.bottlepy_1776_bottle.a8dfef30
true
null
1
6
1
1,280
0
0.6
1
0.75
1
0.233333
80.975
7,096
swe_smith::train::30443
swe_smith
train
30,443
pyca__pyopenssl.04766a49.func_pm_remove_cond__ec87djy8
swesmith/pyca__pyopenssl.04766a49
pyca/pyopenssl
python
null
# Setting invalid attribute on X509Name doesn't raise AttributeError I'm using pyOpenSSL and found an issue when trying to set an invalid attribute on an X509Name object. ## Description When trying to set an attribute on an X509Name object for which no corresponding NID is defined, the operation silently succeeds in...
diff --git a/src/OpenSSL/crypto.py b/src/OpenSSL/crypto.py index 448a19a..9a7fd25 100644 --- a/src/OpenSSL/crypto.py +++ b/src/OpenSSL/crypto.py @@ -638,12 +638,6 @@ class X509Name: ) nid = _lib.OBJ_txt2nid(_byte_string(name)) - if nid == _lib.NID_undef: - try: - ...
["tests/test_crypto.py::TestX509Name::test_set_invalid_attribute"]
["tests/test_crypto.py::TestX509Ext::test_str", "tests/test_crypto.py::TestX509Ext::test_type", "tests/test_crypto.py::TestX509Ext::test_construction", "tests/test_crypto.py::TestX509Ext::test_invalid_extension[thisIsMadeUp-False-hi]", "tests/test_crypto.py::TestX509Ext::test_invalid_extension[proxyCertInfo-True-langua...
jyangballin/swesmith.x86_64.pyca_1776_pyopenssl.04766a49
true
null
1
7
1
1,260
0
0.6
1
0.75
1
0.233333
80.975
7,097
r2e_gym::train::5823
r2e_gym
train
5,823
tornado__522b2c70b69febc2541449583e36c1853c6371cd
tornado
tornadoweb/tornado
python
522b2c70b69febc2541449583e36c1853c6371cd
**Title:** HTTP/1.0 Keep-Alive Connections with Chunked Encoding or Extra CRLFs Cause Timeouts **Description:** When establishing HTTP/1.0 connections with the `keep-alive` header and sending requests with chunked `Transfer-Encoding` or additional CRLFs between messages, the server fails to process the requests proper...
diff --git a/tornado/http1connection.py b/tornado/http1connection.py --- a/tornado/http1connection.py +++ b/tornado/http1connection.py @@ -455,6 +455,7 @@ if start_line.version == "HTTP/1.1": return connection_header != "close" elif ("Content-Length" in headers + or headers.g...
diff --git a/tornado/test/httpclient_test.py b/tornado/test/httpclient_test.py --- a/tornado/test/httpclient_test.py +++ b/tornado/test/httpclient_test.py @@ -338,10 +338,12 @@ # Construct a new instance of the configured client class client = self.http_client.__class__(self.io_loop, force_instance=Tr...
null
null
namanjain12/tornado_final:522b2c70b69febc2541449583e36c1853c6371cd
true
null
1
7
null
1,972
0
0.75
1
0.6375
1
0.352
80.97475
7,098
r2e_gym::train::6432
r2e_gym
train
6,432
pillow__c16737d589144e4ee5f0c239b90ad0935a0dfe6a
pillow
python-pillow/pillow
python
c16737d589144e4ee5f0c239b90ad0935a0dfe6a
**Cleanup Not Called When Saving Image with Negative Size Raises ValueError** **Description** When attempting to save an image with a negative size, a `ValueError` is correctly raised. However, the cleanup process is not invoked, which can lead to resource leaks or inconsistent states within the application. **Exampl...
diff --git a/src/PIL/ImageFile.py b/src/PIL/ImageFile.py --- a/src/PIL/ImageFile.py +++ b/src/PIL/ImageFile.py @@ -223,11 +223,11 @@ ) ] for decoder_name, extents, offset, args in self.tile: + seek(offset) decoder = Image._getdecoder( ...
diff --git a/Tests/test_imagefile.py b/Tests/test_imagefile.py --- a/Tests/test_imagefile.py +++ b/Tests/test_imagefile.py @@ -200,6 +200,9 @@ def encode(self, buffer): return 1, 1, b"" + def cleanup(self): + self.cleanup_called = True + xoff, yoff, xsize, ysize = 10, 20, 100, 100 @@ -327...
null
null
namanjain12/pillow_final:c16737d589144e4ee5f0c239b90ad0935a0dfe6a
true
null
1
57
null
972
0
0.75
1
0.6375
1
0.352
80.97475
7,099
swe_smith::train::26431
swe_smith
train
26,431
pylint-dev__astroid.b114f6b5.func_pm_remove_cond__l67nni8e
swesmith/pylint-dev__astroid.b114f6b5
pylint-dev/astroid
python
null
Enum inference broken after recent changes #### Description Enum class inference is completely broken. When trying to access enum members or their values, astroid throws `NameError: name 'targets' is not defined`. #### Steps/Code to Reproduce ```python import astroid code = """ from enum import Enum class Color(E...
diff --git a/astroid/brain/brain_namedtuple_enum.py b/astroid/brain/brain_namedtuple_enum.py index 67d706d..a0a181f 100644 --- a/astroid/brain/brain_namedtuple_enum.py +++ b/astroid/brain/brain_namedtuple_enum.py @@ -403,29 +403,14 @@ def infer_enum_class(node: nodes.ClassDef) -> nodes.ClassDef: stmt = v...
["tests/brain/test_attr.py::AttrsTest::test_attr_transform", "tests/brain/test_brain.py::ModuleExtenderTest::test_extension_modules", "tests/brain/test_brain.py::ReBrainTest::test_re_pattern_subscriptable", "tests/brain/test_brain.py::ReBrainTest::test_regex_flags", "tests/brain/test_brain.py::BrainNamedtupleAnnAssignT...
["tests/brain/numpy/test_core_einsumfunc.py::test_numpy_function_calls_inferred_as_ndarray", "tests/brain/numpy/test_core_einsumfunc.py::test_function_parameters", "tests/brain/numpy/test_core_fromnumeric.py::BrainNumpyCoreFromNumericTest::test_numpy_function_calls_inferred_as_ndarray", "tests/brain/numpy/test_core_fun...
jyangballin/swesmith.x86_64.pylint-dev_1776_astroid.b114f6b5
true
null
1
20
48
999
0
0.6
1
0.75
1
0.233167
80.9745