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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
4,100 | swe_smith::train::45083 | swe_smith | train | 45,083 | mahmoud__glom.fb3c4e76.lm_rewrite__rbqgu4sb | swesmith/mahmoud__glom.fb3c4e76 | mahmoud/glom | python | null | ### Unregistered Target Error in Mutation and Scope Operations
#### Description
I've encountered an issue with the recent changes in the `TargetRegistry` class. It seems that certain operations involving assignment and deletion are now failing due to unregistered targets. This is particularly evident when attempting ... | diff --git a/glom/core.py b/glom/core.py
index cee71a3..6d788d1 100644
--- a/glom/core.py
+++ b/glom/core.py
@@ -2138,40 +2138,17 @@ class TargetRegistry:
See glom.core.register_op() for the global version used by
extensions.
"""
- if not isinstance(op_name, basestring):
- r... | ["glom/test/test_error.py::test_all_public_errors", "glom/test/test_mutation.py::test_assign", "glom/test/test_mutation.py::test_assign_spec_val", "glom/test/test_mutation.py::test_bad_assign_target", "glom/test/test_mutation.py::test_sequence_assign", "glom/test/test_mutation.py::test_assign_missing_dict", "glom/test/... | ["glom/test/test_basic.py::test_initial_integration", "glom/test/test_basic.py::test_list_item_lift_and_access", "glom/test/test_basic.py::test_coalesce", "glom/test/test_basic.py::test_skip", "glom/test/test_basic.py::test_stop", "glom/test/test_basic.py::test_top_level_default", "glom/test/test_basic.py::test_val", "... | jyangballin/swesmith.x86_64.mahmoud_1776_glom.fb3c4e76 | true | null | 1 | 45 | 18 | 1,881 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4635 | 81.6655 | |||
4,101 | swe_smith::train::45102 | swe_smith | train | 45,102 | modin-project__modin.8c7799fd.combine_file__3yqhqq77 | swesmith/modin-project__modin.8c7799fd | modin-project/modin | python | null | PandasProtocolColumn missing required methods after refactoring
#### Description
The dataframe interchange protocol implementation is broken due to missing essential methods in `PandasProtocolColumn`. Several core methods like `describe_null`, `metadata`, and proper string data handling have been removed, causing fai... | diff --git a/modin/core/dataframe/pandas/interchange/dataframe_protocol/column.py b/modin/core/dataframe/pandas/interchange/dataframe_protocol/column.py
index 01a2e10..bf55697 100644
--- a/modin/core/dataframe/pandas/interchange/dataframe_protocol/column.py
+++ b/modin/core/dataframe/pandas/interchange/dataframe_protoc... | ["modin/tests/interchange/dataframe_protocol/pandas/test_protocol.py::test_simple_import", "modin/tests/interchange/dataframe_protocol/pandas/test_protocol.py::test_categorical_from_dataframe", "modin/tests/interchange/dataframe_protocol/pandas/test_protocol.py::test_interchange_with_pandas_string", "modin/tests/interc... | ["modin/tests/interchange/dataframe_protocol/base/test_sanity.py::test_sanity", "modin/tests/interchange/dataframe_protocol/base/test_sanity.py::test_basic_io", "modin/tests/interchange/dataframe_protocol/base/test_utils.py::test_dtype_to_arrow_c[pandas_dtype0-b]", "modin/tests/interchange/dataframe_protocol/base/test_... | jyangballin/swesmith.x86_64.modin-project_1776_modin.8c7799fd | true | null | 1 | 61 | 17 | 1,560 | 0 | 0.6 | 1 | 0.75 | 1 | 0.463333 | 81.665 | |||
4,102 | swe_smith::train::26711 | swe_smith | train | 26,711 | pylint-dev__astroid.b114f6b5.pr_2596 | swesmith/pylint-dev__astroid.b114f6b5 | pylint-dev/astroid | python | null | MemoryError in _multiply_seq_by_int when constructing large list
### Steps to reproduce
The following code triggers a `MemoryError` in astroid:
```python
a = [[]] * 825 * 16547118
```
This bug was discovered by OSS-Fuzz:
https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=62196 (report not public yet)
Related fix... | diff --git a/astroid/protocols.py b/astroid/protocols.py
index 8a837b8..88bf78b 100644
--- a/astroid/protocols.py
+++ b/astroid/protocols.py
@@ -142,10 +142,7 @@ def _multiply_seq_by_int(
context: InferenceContext,
) -> _TupleListNodeT:
node = self.__class__(parent=opnode)
- if value <= 0 or not self.elts... | ["tests/test_protocols.py::ProtocolTests::test_list_multiplication_with_empty_list_and_overflowing_multiplier", "tests/test_protocols.py::ProtocolTests::test_list_multiplication_with_negative_overflowing_multiplier", "tests/test_protocols.py::ProtocolTests::test_uninferable_list_multiplication_with_multiple_operands"] | ["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 | 6 | 3 | 2,660 | 0 | 0.6 | 1 | 0.75 | 1 | 0.463333 | 81.665 | |||
4,103 | swe_smith::train::43937 | swe_smith | train | 43,937 | pydata__patsy.a5d16484.func_basic__7may2h7e | swesmith/pydata__patsy.a5d16484 | pydata/patsy | python | null | Design matrix row count validation fails with off-by-one error
When building design matrices, the row count validation is incorrectly checking for mismatches. This causes failures when the data dimensions should match properly.
#### Steps/Code to Reproduce
```python
import numpy as np
import patsy
# Simple case tha... | diff --git a/patsy/build.py b/patsy/build.py
index cbe2524..60218e9 100644
--- a/patsy/build.py
+++ b/patsy/build.py
@@ -861,71 +861,6 @@ class _CheckMatch(object):
def build_design_matrices(
design_infos, data, NA_action="drop", return_type="matrix", dtype=np.dtype(float)
):
- """Construct several design mat... | ["patsy/mgcv_cubic_splines.py::test_crs_with_specific_constraint", "patsy/mgcv_cubic_splines.py::test_te_2smooths", "patsy/test_build.py::test_simple", "patsy/test_build.py::test_R_bugs", "patsy/test_build.py::test_redundancy_thoroughly", "patsy/test_build.py::test_data_types", "patsy/test_build.py::test_build_design_m... | ["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 | 96 | 31 | 857 | 0 | 0.6 | 1 | 0.75 | 1 | 0.462833 | 81.6635 | |||
4,104 | swe_smith::train::39580 | swe_smith | train | 39,580 | pallets__jinja.ada0a9a6.lm_rewrite__9wrmgt7e | swesmith/pallets__jinja.ada0a9a6 | pallets/jinja | python | null | Tuple Parsing Behavior Change in Jinja2 Parser
I encountered an issue with the tuple parsing behavior in the Jinja2 parser after a recent update. It seems that the handling of tuples, especially those with explicit parentheses, has changed unexpectedly.
Here's a minimal example to reproduce the issue:
```python
from... | diff --git a/src/jinja2/parser.py b/src/jinja2/parser.py
index 817abec..5e5d846 100644
--- a/src/jinja2/parser.py
+++ b/src/jinja2/parser.py
@@ -677,13 +677,9 @@ class Parser:
self.fail(f"unexpected {describe_token(token)!r}", token.lineno)
return node
- def parse_tuple(
- self,
- ... | ["tests/test_lexnparse.py::TestSyntax::test_tuple", "tests/test_regression.py::TestBug::test_empty_if_condition_fails"] | ["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 | 73 | 2 | 1,314 | 0 | 0.6 | 1 | 0.75 | 1 | 0.462333 | 81.662 | |||
4,105 | swe_smith::train::38476 | swe_smith | train | 38,476 | amueller__word_cloud.ec24191c.func_basic__em24z2r4 | swesmith/amueller__word_cloud.ec24191c | amueller/word_cloud | python | null | # SVG export broken in WordCloud
I'm trying to export a word cloud to SVG format but it's failing with a TypeError.
```python
>>> from wordcloud import WordCloud
>>> wc = WordCloud()
>>> wc.generate("some text to generate a word cloud from")
>>> svg = wc.to_svg()
```
This results in the following error:
```
TypeErro... | diff --git a/wordcloud/wordcloud.py b/wordcloud/wordcloud.py
index 1622c03..9f65097 100644
--- a/wordcloud/wordcloud.py
+++ b/wordcloud/wordcloud.py
@@ -749,7 +749,7 @@ class WordCloud(object):
"""
return self.to_array()
- def to_svg(self, embed_font=False, optimize_embedded_font=True, embed_imag... | ["test/test_wordcloud.py::test_svg_syntax"] | ["test/test_wordcloud.py::test_collocations", "test/test_wordcloud.py::test_collocation_stopwords", "test/test_wordcloud.py::test_collocation_stopwords_uppercase", "test/test_wordcloud.py::test_plurals_numbers", "test/test_wordcloud.py::test_multiple_s", "test/test_wordcloud.py::test_empty_text", "test/test_wordcloud.p... | jyangballin/swesmith.x86_64.amueller_1776_word_cloud.ec24191c | true | null | 1 | 77 | 1 | 1,234 | 0 | 0.6 | 1 | 0.75 | 1 | 0.462333 | 81.662 | |||
4,106 | swe_smith::train::45093 | swe_smith | train | 45,093 | mahmoud__glom.fb3c4e76.lm_rewrite__xqg1nzcn | swesmith/mahmoud__glom.fb3c4e76 | mahmoud/glom | python | null | ### UnregisteredTarget Error with TargetRegistry Registration
#### Description
After the recent changes, it seems that the `TargetRegistry` is not handling certain registrations correctly, leading to `UnregisteredTarget` errors. This issue appears when attempting to register operations with specific target types.
##... | diff --git a/glom/core.py b/glom/core.py
index cee71a3..31bb343 100644
--- a/glom/core.py
+++ b/glom/core.py
@@ -2092,41 +2092,37 @@ class TargetRegistry:
return _type_tree
def register(self, target_type, **kwargs):
- if not isinstance(target_type, type):
- raise TypeError(f'register e... | ["glom/test/test_basic.py::test_initial_integration", "glom/test/test_basic.py::test_ref", "glom/test/test_basic.py::test_pipe", "glom/test/test_error.py::test_glom_error_stack", "glom/test/test_error.py::test_glom_error_double_stack", "glom/test/test_error.py::test_partially_failing_branch", "glom/test/test_error.py::... | ["glom/test/test_basic.py::test_list_item_lift_and_access", "glom/test/test_basic.py::test_coalesce", "glom/test/test_basic.py::test_skip", "glom/test/test_basic.py::test_stop", "glom/test/test_basic.py::test_top_level_default", "glom/test/test_basic.py::test_val", "glom/test/test_basic.py::test_abstract_iterable", "gl... | jyangballin/swesmith.x86_64.mahmoud_1776_glom.fb3c4e76 | true | null | 1 | 64 | 16 | 1,494 | 0 | 0.6 | 1 | 0.75 | 1 | 0.462333 | 81.662 | |||
4,107 | swe_smith::train::12019 | swe_smith | train | 12,019 | lepture__mistune.bf54ef67.combine_file__4tbz1hst | swesmith/lepture__mistune.bf54ef67 | lepture/mistune | python | null | Multiple issues with Markdown parsing in block_parser.py
#### Description
I've found several issues with the Markdown parser that cause incorrect rendering of various Markdown elements. The most noticeable problems are with block quotes, lists, and HTML parsing.
#### Steps to Reproduce
Here's a simple example showi... | diff --git a/src/mistune/block_parser.py b/src/mistune/block_parser.py
index 8e43bb6..2f424ca 100644
--- a/src/mistune/block_parser.py
+++ b/src/mistune/block_parser.py
@@ -368,23 +368,25 @@ class BlockParser(Parser[BlockState]):
text, end_pos = self.extract_block_quote(m, state)
# scan children state... | ["tests/test_commonmark.py::TestCommonMark::test_backslash_escapes_021", "tests/test_commonmark.py::TestCommonMark::test_block_quotes_228", "tests/test_commonmark.py::TestCommonMark::test_block_quotes_229", "tests/test_commonmark.py::TestCommonMark::test_block_quotes_230", "tests/test_commonmark.py::TestCommonMark::tes... | ["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 | 51 | 194 | 1,753 | 0 | 0.6 | 1 | 0.75 | 1 | 0.462167 | 81.6615 | |||
4,108 | swe_smith::train::36111 | swe_smith | train | 36,111 | borntyping__python-colorlog.dfa10f59.combine_file__5iaprkn8 | swesmith/borntyping__python-colorlog.dfa10f59 | borntyping/python-colorlog | python | null | ColoredFormatter missing __init__ method after recent changes
#### Description
The ColoredFormatter class is missing its `__init__` method, causing instantiation to fail with various errors. When trying to create a ColoredFormatter instance, it throws AttributeError or TypeError depending on the parameters passed.
#... | diff --git a/colorlog/formatter.py b/colorlog/formatter.py
index f011ca2..bea642b 100644
--- a/colorlog/formatter.py
+++ b/colorlog/formatter.py
@@ -60,72 +60,6 @@ class ColoredFormatter(logging.Formatter):
Intended to help in creating more readable logging output.
"""
- def __init__(
- self,
- ... | ["colorlog/tests/test_colorlog.py::test_colored_formatter", "colorlog/tests/test_colorlog.py::test_custom_colors", "colorlog/tests/test_colorlog.py::test_reset", "colorlog/tests/test_colorlog.py::test_no_reset", "colorlog/tests/test_colorlog.py::test_secondary_colors", "colorlog/tests/test_colorlog.py::test_some_second... | ["colorlog/tests/test_escape_codes.py::test_esc", "colorlog/tests/test_escape_codes.py::test_reset", "colorlog/tests/test_escape_codes.py::test_bold_color", "colorlog/tests/test_escape_codes.py::test_fg_color", "colorlog/tests/test_escape_codes.py::test_bg_color", "colorlog/tests/test_escape_codes.py::test_parse_colors... | jyangballin/swesmith.x86_64.borntyping_1776_python-colorlog.dfa10f59 | true | null | 1 | 83 | 17 | 1,111 | 0 | 0.6 | 1 | 0.75 | 1 | 0.461833 | 81.6605 | |||
4,109 | swe_smith::train::5034 | swe_smith | train | 5,034 | bottlepy__bottle.a8dfef30.lm_rewrite__b4pjit43 | swesmith/bottlepy__bottle.a8dfef30 | bottlepy/bottle | python | null | ### Description
It seems there's an issue with the `path_shift` function in the latest update. When attempting to shift path segments between `SCRIPT_NAME` and `PATH_INFO`, the function does not handle certain cases as expected. Specifically, when the shift count exceeds the available segments in either direction, the... | diff --git a/bottle.py b/bottle.py
index 286b5bc..cad9952 100755
--- a/bottle.py
+++ b/bottle.py
@@ -3122,27 +3122,37 @@ def path_shift(script_name, path_info, shift=1):
:param shift: The number of path fragments to shift. May be negative to
change the shift direction. (default: 1)
"""
- if ... | ["test/test_environ.py::TestRequest::test_pathshift"] | ["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 | 52 | 1 | 1,730 | 0 | 0.6 | 1 | 0.75 | 1 | 0.461667 | 81.66 | |||
4,110 | swe_bench::test::1389 | swe_bench | test | 1,389 | pytest-dev__pytest-11125 | pytest-dev/pytest | pytest-dev/pytest | python | 797b924fc44189d0b9c2ad905410f0bd89461ab7 | Pytest 7.3.2 changes in behaviour regarding conftest.py and `testpaths`
In [cibuildwheel](https://github.com/pypa/cibuildwheel), we have two test suites - the unit tests at `/unit_test` and the integration test suite at `/test`. Both `/unit_test` and `/test` are listed in testpaths-
[**pyproject.toml**](https://github... | a recent bugfix made a hidden mistake in your conftest layout surface
the basic gist is, that with testpaths, pytest now correctly consider the conf-tests in those root test paths as possible early loaded conftests (to supply addopts & co) in turn making sure that all options are always registred
as far as i unde... | diff --git a/src/_pytest/config/__init__.py b/src/_pytest/config/__init__.py
--- a/src/_pytest/config/__init__.py
+++ b/src/_pytest/config/__init__.py
@@ -527,9 +527,12 @@ def pytest_configure(self, config: "Config") -> None:
#
def _set_initial_conftests(
self,
- namespace: argparse.Namespace,... | diff --git a/testing/test_collection.py b/testing/test_collection.py
--- a/testing/test_collection.py
+++ b/testing/test_collection.py
@@ -1264,11 +1264,18 @@ def pytest_sessionstart(session):
testpaths = some_path
"""
)
+
+ # No command line args - falls back to testpaths.
result = pytes... | ["testing/test_conftest.py::TestConftestValueAccessGlobal::test_value_access_not_existing[global]", "testing/test_conftest.py::TestConftestValueAccessGlobal::test_value_access_by_path[global]", "testing/test_conftest.py::TestConftestValueAccessGlobal::test_value_access_with_confmod[global]", "testing/test_conftest.py::... | ["testing/test_collection.py::TestCollector::test_collect_versus_item", "testing/test_conftest.py::TestConftestValueAccessGlobal::test_basic_init[global]", "testing/test_conftest.py::TestConftestValueAccessGlobal::test_immediate_initialiation_and_incremental_are_the_same[global]", "testing/test_conftest.py::TestConftes... | null | true | 2023-06-20T18:36:34Z | 1 | 121 | 16 | 8,059 | 0 | 0.8 | 1 | 0.5 | 1 | 0.903333 | 81.66 | |
4,111 | swe_smith::train::1685 | swe_smith | train | 1,685 | agronholm__typeguard.b6a7e438.combine_file__z8bzaj2a | swesmith/agronholm__typeguard.b6a7e438 | agronholm/typeguard | python | null | Type checking fails with AttributeError after recent changes
#### Description
After some recent changes, type checking is completely broken and raises AttributeError instead of proper TypeCheckError messages. This affects all type checking functionality.
#### Steps/Code to Reproduce
```python
from typeguard import ... | diff --git a/src/typeguard/_checkers.py b/src/typeguard/_checkers.py
index 5e34036..60332eb 100644
--- a/src/typeguard/_checkers.py
+++ b/src/typeguard/_checkers.py
@@ -533,25 +533,24 @@ def check_typevar(
) -> None:
if origin_type.__bound__ is not None:
annotation = (
- Type[origin_type.__bou... | ["tests/test_checkers.py::TestAnyStr::test_valid[str]", "tests/test_checkers.py::TestAnyStr::test_valid[bytes]", "tests/test_checkers.py::TestLiteral::test_literal_union", "tests/test_checkers.py::TestMapping::test_bad_key_type", "tests/test_checkers.py::TestMapping::test_bad_value_type", "tests/test_checkers.py::TestM... | ["tests/mypy/test_type_annotations.py::test_positive", "tests/mypy/test_type_annotations.py::test_negative", "tests/test_checkers.py::TestAnyStr::test_bad_type", "tests/test_checkers.py::TestBytesLike::test_valid[bytes]", "tests/test_checkers.py::TestBytesLike::test_valid[bytearray]", "tests/test_checkers.py::TestBytes... | jyangballin/swesmith.x86_64.agronholm_1776_typeguard.b6a7e438 | true | null | 1 | 88 | 122 | 1,010 | 0 | 0.6 | 1 | 0.75 | 1 | 0.461667 | 81.66 | |||
4,112 | swe_smith::train::5111 | swe_smith | train | 5,111 | agronholm__exceptiongroup.0b4f4937.combine_module__ps4pitxu | swesmith/agronholm__exceptiongroup.0b4f4937 | agronholm/exceptiongroup | python | null | ExceptionGroup.subgroup() returns wrong results when filtering
#### Description
The `subgroup()` method on ExceptionGroup instances is returning incorrect results. When trying to filter exceptions using a condition, the method appears to be applying inverted logic and returning unexpected subgroups.
#### Steps/Code ... | diff --git a/src/exceptiongroup/_exceptions.py b/src/exceptiongroup/_exceptions.py
index a4a7ace..e6be7c2 100644
--- a/src/exceptiongroup/_exceptions.py
+++ b/src/exceptiongroup/_exceptions.py
@@ -110,7 +110,9 @@ class BaseExceptionGroup(BaseException, Generic[_BaseExceptionT_co]):
@property
def message(sel... | ["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 | 2 | 87 | 42 | 1,028 | 0 | 0.6 | 1 | 0.75 | 1 | 0.461333 | 81.659 | |||
4,113 | swe_smith::train::44505 | swe_smith | train | 44,505 | pydata__patsy.a5d16484.lm_rewrite__drfrqonb | swesmith/pydata__patsy.a5d16484 | pydata/patsy | python | null | Tokenization of Constraint Strings Fails with AttributeError
I encountered an issue when trying to tokenize constraint strings using the `_tokenize_constraint` function. The function is supposed to break down a string into tokens, but it seems to be failing with an `AttributeError`.
Here's a minimal example to reprod... | diff --git a/patsy/constraint.py b/patsy/constraint.py
index 6c04414..79fa8ec 100644
--- a/patsy/constraint.py
+++ b/patsy/constraint.py
@@ -215,44 +215,64 @@ def _tokenize_constraint(string, variable_names):
def test__tokenize_constraint():
- code = "2 * (a + b) = q"
- tokens = _tokenize_constraint(code, ["... | ["patsy/constraint.py::test__tokenize_constraint"] | ["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 | 94 | 1 | 887 | 0 | 0.6 | 1 | 0.75 | 1 | 0.461167 | 81.6585 | |||
4,114 | swe_smith::train::45205 | swe_smith | train | 45,205 | dask__dask.5f61e423.combine_file__ooj0gt83 | swesmith/dask__dask.5f61e423 | dask/dask | python | null | CSV reading fails with NameError: name 'b_lineterminator' is not defined
#### Description
When trying to read CSV files with dask dataframe, I'm getting a `NameError` saying that `b_lineterminator` is not defined. This seems to happen during the CSV parsing process.
#### Steps/Code to Reproduce
```python
import das... | diff --git a/dask/dataframe/io/csv.py b/dask/dataframe/io/csv.py
index 4dc9ad8..436db6f 100644
--- a/dask/dataframe/io/csv.py
+++ b/dask/dataframe/io/csv.py
@@ -239,9 +239,7 @@ def text_blocks_to_pandas(
# Fixup the dtypes
for k in unknown_categoricals:
- dtypes[k] = "category"
-
- columns = list(... | ["dask/dataframe/io/tests/test_csv.py::test_text_blocks_to_pandas_simple[read_csv-files0]", "dask/dataframe/io/tests/test_csv.py::test_text_blocks_to_pandas_simple[read_table-files1]", "dask/dataframe/io/tests/test_csv.py::test_text_blocks_to_pandas_simple[read_fwf-files2]", "dask/dataframe/io/tests/test_csv.py::test_t... | ["dask/dataframe/io/tests/test_csv.py::test_pandas_read_text[read_csv-files0]", "dask/dataframe/io/tests/test_csv.py::test_pandas_read_text[read_table-files1]", "dask/dataframe/io/tests/test_csv.py::test_pandas_read_text[read_fwf-files2]", "dask/dataframe/io/tests/test_csv.py::test_pandas_read_text_kwargs[read_csv-file... | jyangballin/swesmith.x86_64.dask_1776_dask.5f61e423 | true | null | 1 | 83 | 127 | 1,103 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4605 | 81.6565 | |||
4,115 | swe_smith::train::24459 | swe_smith | train | 24,459 | sunpy__sunpy.f8edfd5c.combine_file__wvdsb700 | swesmith/sunpy__sunpy.f8edfd5c | sunpy/sunpy | python | null | GreatArc initialization broken due to attribute access before definition
When creating a GreatArc object, the initialization fails because the code tries to access attributes that haven't been defined yet.
#### Steps/Code to Reproduce
```python
from sunpy.coordinates.utils import GreatArc
from sunpy.coordinates impo... | diff --git a/sunpy/coordinates/utils.py b/sunpy/coordinates/utils.py
index 6f868af..22b7166 100644
--- a/sunpy/coordinates/utils.py
+++ b/sunpy/coordinates/utils.py
@@ -84,35 +84,40 @@ class GreatArc:
def __init__(self, start, end, center=None, points=None):
+ # Convert the start, end and center points ... | ["sunpy/coordinates/tests/test_utils.py::test_great_arc_calculable[start0-end0]", "sunpy/coordinates/tests/test_utils.py::test_great_arc_calculable[start1-end1]", "sunpy/coordinates/tests/test_utils.py::test_great_arc_calculable[start2-end2]", "sunpy/coordinates/tests/test_utils.py::test_great_arc_calculable[start3-end... | ["sunpy/coordinates/tests/test_utils.py::test_rectangle_incomplete_input", "sunpy/coordinates/tests/test_utils.py::test_rectangle_invalid_input", "sunpy/coordinates/tests/test_utils.py::test_rectangle_all_parameters_passed", "sunpy/coordinates/tests/test_utils.py::test_rectangle_mismatching_frames_missing_parameters", ... | jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c | true | null | 1 | 71 | 18 | 1,343 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4605 | 81.6565 | |||
4,116 | swe_smith::train::44482 | swe_smith | train | 44,482 | pydata__patsy.a5d16484.lm_rewrite__1gsw4cb6 | swesmith/pydata__patsy.a5d16484 | pydata/patsy | python | null | # Floating point number formatting in _format_float_column function fails with certain inputs
### Bug description
I discovered an issue with the `_format_float_column` function in the `design_info.py` file. The function is supposed to format floating point numbers for display with proper alignment of decimal points, ... | diff --git a/patsy/design_info.py b/patsy/design_info.py
index d94b97a..25882d6 100644
--- a/patsy/design_info.py
+++ b/patsy/design_info.py
@@ -1057,33 +1057,37 @@ def test_DesignInfo_deprecated_attributes():
# this while we can do it to *all* the ordinarily-formatted numbers, to keep
# decimal points aligned.
def ... | ["patsy/design_info.py::test__format_float_column", "patsy/design_info.py::test_design_matrix"] | ["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 | 58 | 2 | 1,601 | 0 | 0.6 | 1 | 0.75 | 1 | 0.460167 | 81.6555 | |||
4,117 | swe_smith::train::11628 | swe_smith | train | 11,628 | andialbrecht__sqlparse.e57923b3.combine_module__jp1804gl | swesmith/andialbrecht__sqlparse.e57923b3 | andialbrecht/sqlparse | python | null | # SQL formatting breaks with changes to parenthesis processing and reindent filter
## Description
I've discovered an issue with SQL formatting when using the reindent and aligned indent filters. After recent changes, SQL statements with parentheses are not being formatted correctly, and in some cases, the formatter i... | diff --git a/sqlparse/filters/aligned_indent.py b/sqlparse/filters/aligned_indent.py
index dc60926..1c710bb 100644
--- a/sqlparse/filters/aligned_indent.py
+++ b/sqlparse/filters/aligned_indent.py
@@ -46,17 +46,33 @@ class AlignedIndentFilter:
self._process(sql.TokenList(tlist.tokens))
def _process_pare... | ["tests/test_cli.py::test_valid_args", "tests/test_format.py::TestFormatReindentAligned::test_basic", "tests/test_format.py::TestFormatReindentAligned::test_joins", "tests/test_format.py::TestFormatReindentAligned::test_group_by_subquery", "tests/test_format.py::TestFormatReindentAligned::test_window_functions", "tests... | ["tests/test_cli.py::test_cli_main_empty", "tests/test_cli.py::test_parser_empty", "tests/test_cli.py::test_main_help", "tests/test_cli.py::test_invalid_choice", "tests/test_cli.py::test_invalid_args", "tests/test_cli.py::test_invalid_infile", "tests/test_cli.py::test_invalid_outfile", "tests/test_cli.py::test_stdout",... | jyangballin/swesmith.x86_64.andialbrecht_1776_sqlparse.e57923b3 | true | null | 2 | 46 | 28 | 1,839 | 0 | 0.6 | 1 | 0.75 | 1 | 0.459833 | 81.6545 | |||
4,118 | swe_smith::train::30451 | swe_smith | train | 30,451 | pyca__pyopenssl.04766a49.lm_rewrite__55pbx8e4 | swesmith/pyca__pyopenssl.04766a49 | pyca/pyopenssl | python | null | # get_signature_algorithm() returns None instead of signature algorithm
I'm trying to get the signature algorithm from an X509 certificate, but the method returns None instead of the expected algorithm name.
## Reproduction Steps
```python
from OpenSSL import crypto
# Load a certificate
cert_data = """-----BEGIN CE... | diff --git a/src/OpenSSL/crypto.py b/src/OpenSSL/crypto.py
index 448a19a..3f9692a 100644
--- a/src/OpenSSL/crypto.py
+++ b/src/OpenSSL/crypto.py
@@ -1361,7 +1361,7 @@ class X509:
sign_result = _lib.X509_sign(self._x509, pkey._pkey, evp_md)
_openssl_assert(sign_result > 0)
- def get_signature_algo... | ["tests/test_crypto.py::TestX509::test_get_signature_algorithm", "tests/test_crypto.py::TestX509::test_get_undefined_signature_algorithm"] | ["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 | 17 | 2 | 2,419 | 0 | 0.6 | 1 | 0.75 | 1 | 0.459833 | 81.6545 | |||
4,119 | swe_smith::train::31702 | swe_smith | train | 31,702 | benoitc__gunicorn.bacbf8aa.lm_rewrite__qx97z56z | swesmith/benoitc__gunicorn.bacbf8aa | benoitc/gunicorn | python | null | # Unable to load custom worker class in Gunicorn
I'm experiencing an issue with loading custom worker classes in Gunicorn. When trying to use a custom worker class, Gunicorn fails to load it properly.
## Reproduction steps
1. Create a custom worker class:
```python
class CustomWorker:
# Custom worker implementat... | diff --git a/gunicorn/util.py b/gunicorn/util.py
index e66dbeb..1d41360 100644
--- a/gunicorn/util.py
+++ b/gunicorn/util.py
@@ -65,55 +65,45 @@ def load_entry_point(distribution, group, name):
return eps[0].load()
-def load_class(uri, default="gunicorn.workers.sync.SyncWorker",
- section="gunico... | ["tests/test_config.py::test_worker_class", "tests/test_config.py::test_property_access"] | ["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 | 84 | 2 | 1,078 | 0 | 0.6 | 1 | 0.75 | 1 | 0.459667 | 81.654 | |||
4,120 | swe_smith::train::27822 | swe_smith | train | 27,822 | arrow-py__arrow.1d70d009.lm_rewrite__ztqf7kyf | swesmith/arrow-py__arrow.1d70d009 | arrow-py/arrow | python | null | # Arrow.replace() method doesn't validate attribute names properly
## Description
I'm using the Arrow library to manipulate dates and times in my application, and I've encountered an issue with the `replace()` method. The method is supposed to raise a `ValueError` when invalid attributes are provided, but it's not wo... | diff --git a/arrow/arrow.py b/arrow/arrow.py
index 9d1f5e3..78ba138 100644
--- a/arrow/arrow.py
+++ b/arrow/arrow.py
@@ -936,7 +936,7 @@ class Arrow:
return self.fromdatetime(self._datetime)
- def replace(self, **kwargs: Any) -> "Arrow":
+ def replace(self, **kwargs: Any) -> 'Arrow':
"""Retu... | ["tests/test_arrow.py::TestArrowReplace::test_not_attr", "tests/test_arrow.py::TestArrowReplace::test_replace_week", "tests/test_arrow.py::TestArrowReplace::test_replace_quarter"] | ["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 | 63 | 3 | 1,497 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4595 | 81.6535 | |||
4,121 | swe_smith::train::45440 | swe_smith | train | 45,440 | dask__dask.5f61e423.lm_rewrite__svt3emd3 | swesmith/dask__dask.5f61e423 | dask/dask | python | null | ### Description
It seems there's an issue with the `save_config` function in the Dask CLI. When attempting to set a configuration value without specifying a config file, an error occurs. The function tries to access the `exists` attribute on a string, which leads to an `AttributeError`. This behavior is unexpected and... | diff --git a/dask/cli.py b/dask/cli.py
index 613b32f..2f73ced 100644
--- a/dask/cli.py
+++ b/dask/cli.py
@@ -110,51 +110,58 @@ def config_set(key, value, file):
click.echo(f"Updated [{key}] to [{value}], config saved to {path}")
-def save_config(
- key: str,
- value: Any,
- config_file: pathlib.Path |... | ["dask/tests/test_cli.py::test_config_set_value[False-None-True-333MiB]", "dask/tests/test_cli.py::test_config_set_value[False-None-True-2]", "dask/tests/test_cli.py::test_config_set_value[False-None-True-value2]", "dask/tests/test_cli.py::test_config_set_value[False-None-True-value3]", "dask/tests/test_cli.py::test_co... | ["dask/tests/test_cli.py::test_config_get_no_key", "dask/tests/test_cli.py::test_config_get_value", "dask/tests/test_cli.py::test_config_get_bad_value", "dask/tests/test_cli.py::test_config_get_none", "dask/tests/test_cli.py::test_config_set_value[True-None-True-333MiB]", "dask/tests/test_cli.py::test_config_set_value[... | jyangballin/swesmith.x86_64.dask_1776_dask.5f61e423 | true | null | 1 | 77 | 10 | 1,217 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4595 | 81.6535 | |||
4,122 | swe_smith::train::38459 | swe_smith | train | 38,459 | amueller__word_cloud.ec24191c.combine_file__g0znxmoz | swesmith/amueller__word_cloud.ec24191c | amueller/word_cloud | python | null | # Multiple issues with WordCloud processing and rendering
I found several issues with the WordCloud library that break functionality:
1. The `process_text` method returns a list instead of a dictionary, causing errors when trying to access items or keys:
```python
word_counts = wc.process_text("Some text")
# This fai... | diff --git a/wordcloud/wordcloud.py b/wordcloud/wordcloud.py
index 1622c03..b0dd743 100644
--- a/wordcloud/wordcloud.py
+++ b/wordcloud/wordcloud.py
@@ -577,31 +577,27 @@ class WordCloud(object):
include all those things.
"""
- flags = (re.UNICODE if sys.version < '3' and type(text) is unicod... | ["test/test_wordcloud.py::test_collocations", "test/test_wordcloud.py::test_collocation_stopwords", "test/test_wordcloud.py::test_collocation_stopwords_uppercase", "test/test_wordcloud.py::test_plurals_numbers", "test/test_wordcloud.py::test_multiple_s", "test/test_wordcloud.py::test_empty_text", "test/test_wordcloud.p... | ["test/test_wordcloud.py::test_stopwords_lowercasing", "test/test_wordcloud.py::test_check_errors", "test/test_wordcloud.py::test_single_color_func", "test/test_wordcloud.py::test_single_color_func_grey", "test/test_wordcloud.py::test_process_text_regexp_parameter", "test/test_wordcloud.py::test_unicode_stopwords", "te... | jyangballin/swesmith.x86_64.amueller_1776_word_cloud.ec24191c | true | null | 1 | 38 | 29 | 1,996 | 0 | 0.6 | 1 | 0.75 | 1 | 0.459333 | 81.653 | |||
4,123 | swe_smith::train::39633 | swe_smith | train | 39,633 | pallets__jinja.ada0a9a6.lm_rewrite__zwqtx1ba | swesmith/pallets__jinja.ada0a9a6 | pallets/jinja | python | null | ### Issue: Undefined Filter and Test Name Handling
#### Description
It seems that the recent changes have introduced an issue with handling undefined filters and test names in templates. When attempting to use a filter or test that is not defined, the system raises a `KeyError` instead of the expected `TemplateAssert... | diff --git a/src/jinja2/nodes.py b/src/jinja2/nodes.py
index 2f93b90..1ccf35b 100644
--- a/src/jinja2/nodes.py
+++ b/src/jinja2/nodes.py
@@ -747,42 +747,39 @@ class _FilterTestCommon(Expr):
abstract = True
_is_filter = True
- def as_const(self, eval_ctx: t.Optional[EvalContext] = None) -> t.Any:
+ def... | ["tests/test_async_filters.py::test_custom_async_filter[asyncio]", "tests/test_async_filters.py::test_custom_async_filter[trio]", "tests/test_async_filters.py::test_custom_async_iteratable_filter[asyncio-<lambda>0]", "tests/test_async_filters.py::test_custom_async_iteratable_filter[asyncio-<lambda>1]", "tests/test_asyn... | ["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 | 57 | 14 | 1,613 | 0 | 0.6 | 1 | 0.75 | 1 | 0.458833 | 81.6515 | |||
4,124 | swe_smith::train::7451 | swe_smith | train | 7,451 | cantools__cantools.0c6a7871.func_basic__c4jxr5f2 | swesmith/cantools__cantools.0c6a7871 | cantools/cantools | python | null | DBC signal parsing fails with "list index out of range" error
When loading DBC files, the signal parsing logic is accessing incorrect indices in the signal token array, causing a "list index out of range" error that prevents DBC files from being loaded properly.
#### Steps to Reproduce
```python
import cantools
# T... | diff --git a/src/cantools/database/can/formats/dbc.py b/src/cantools/database/can/formats/dbc.py
index a5b6092..418258f 100644
--- a/src/cantools/database/can/formats/dbc.py
+++ b/src/cantools/database/can/formats/dbc.py
@@ -1400,40 +1400,28 @@ def _load_signals(tokens,
pass
def get_attributes(frame_id_... | ["tests/test_command_line.py::CanToolsCommandLineTest::test_convert", "tests/test_command_line.py::CanToolsCommandLineTest::test_convert_bad_outfile", "tests/test_command_line.py::CanToolsCommandLineTest::test_decode", "tests/test_command_line.py::CanToolsCommandLineTest::test_decode_can_fd", "tests/test_command_line.p... | ["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 | 95 | 192 | 853 | 0 | 0.6 | 1 | 0.75 | 1 | 0.458833 | 81.6515 | |||
4,125 | swe_smith::train::26564 | swe_smith | train | 26,564 | pylint-dev__astroid.b114f6b5.lm_rewrite__d0ail4ie | swesmith/pylint-dev__astroid.b114f6b5 | pylint-dev/astroid | python | null | ### InferenceError Raised During Recursion in Inference
#### Description
It seems there's an issue with the `raise_if_nothing_inferred` decorator when handling recursion during inference. The problem arises when the recursion limit is hit, leading to an `InferenceError` being raised unexpectedly.
#### Steps/Code to R... | diff --git a/astroid/decorators.py b/astroid/decorators.py
index cd0f5a7..fffc0e9 100644
--- a/astroid/decorators.py
+++ b/astroid/decorators.py
@@ -77,30 +77,27 @@ def yes_if_nothing_inferred(
return inner
-def raise_if_nothing_inferred(
- func: Callable[_P, Generator[InferenceResult]],
-) -> Callable[_P, ... | ["tests/test_inference.py::InferenceTest::test_no_infinite_ancestor_loop", "tests/test_inference.py::test_recursion_on_inference_tip", "tests/test_regrtest.py::test_recursion_during_inference"] | ["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 | 29 | 3 | 2,172 | 0 | 0.6 | 1 | 0.75 | 1 | 0.458667 | 81.651 | |||
4,126 | swe_smith::train::3578 | swe_smith | train | 3,578 | pygments__pygments.27649ebb.combine_module__153j9tr5 | swesmith/pygments__pygments.27649ebb | pygments/pygments | python | null | # [Bug]: Missing __init__ method in LatexFormatter and broken RTF formatter
## Bug summary
There are two issues:
1. The `LatexFormatter` class is missing its `__init__` method, causing any attempt to use it to fail with an AttributeError.
2. The `RtfFormatter` has several issues:
- It processes lines in the wron... | diff --git a/pygments/formatters/latex.py b/pygments/formatters/latex.py
index 2f7971e..e8d202e 100644
--- a/pygments/formatters/latex.py
+++ b/pygments/formatters/latex.py
@@ -253,29 +253,6 @@ class LatexFormatter(Formatter):
aliases = ['latex', 'tex']
filenames = ['*.tex']
- def __init__(self, **option... | ["tests/test_rtf_formatter.py::test_hl_linenostart_lines_highlighted", "tests/test_rtf_formatter.py::test_lineno_color_style_specify_hex", "tests/test_rtf_formatter.py::test_linenos_newline_characters", "tests/test_rtf_formatter.py::test_linenos_left_padding", "tests/test_rtf_formatter.py::test_linenostart", "tests/tes... | ["tests/test_rtf_formatter.py::test_rtf_footer", "tests/test_rtf_formatter.py::test_rtf_header", "tests/test_rtf_formatter.py::test_all_options", "tests/test_html_formatter.py::test_lineanchors_with_startnum", "tests/test_html_formatter.py::test_get_style_defs_contains_pre_style", "tests/test_html_formatter.py::test_ge... | jyangballin/swesmith.x86_64.pygments_1776_pygments.27649ebb | true | null | 2 | 43 | 28 | 1,892 | 0 | 0.6 | 1 | 0.75 | 1 | 0.458667 | 81.651 | |||
4,127 | swe_smith::train::10071 | swe_smith | train | 10,071 | paramiko__paramiko.23f92003.combine_file__7e1ieiw4 | swesmith/paramiko__paramiko.23f92003 | paramiko/paramiko | python | null | SSH authentication fails with "AttributeError: 'HostKeys' object has no attribute 'copy'"
#### Description
When attempting to establish SSH connections, authentication consistently fails with an AttributeError related to the HostKeys object not having a 'copy' method. This affects all authentication methods including... | diff --git a/paramiko/client.py b/paramiko/client.py
index d8be910..6b2e906 100644
--- a/paramiko/client.py
+++ b/paramiko/client.py
@@ -157,7 +157,8 @@ class SSHClient(ClosingContextManager):
:return: the local host keys as a `.HostKeys` object.
"""
- return self._host_keys
+ backup_k... | ["tests/test_client.py::SSHClientTest::test_auth_timeout", "tests/test_client.py::SSHClientTest::test_auth_trickledown", "tests/test_client.py::SSHClientTest::test_auto_add_policy", "tests/test_client.py::SSHClientTest::test_banner_timeout", "tests/test_client.py::SSHClientTest::test_certs_allowed_as_key_filename_value... | ["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 | 67 | 34 | 1,412 | 0 | 0.6 | 1 | 0.75 | 1 | 0.458667 | 81.651 | |||
4,128 | swe_smith::train::26523 | swe_smith | train | 26,523 | pylint-dev__astroid.b114f6b5.lm_rewrite__2tj66f5p | swesmith/pylint-dev__astroid.b114f6b5 | pylint-dev/astroid | python | null | ### Issue: AttributeError in Slice Inference
#### Description
It seems there's an issue with the `infer_slice` function when handling `slice` objects. The recent changes have introduced an `AttributeError` when trying to infer attributes of a `slice`. This is causing problems when attempting to access the `start`, `s... | diff --git a/astroid/brain/brain_builtin_inference.py b/astroid/brain/brain_builtin_inference.py
index a56b152..938a8ab 100644
--- a/astroid/brain/brain_builtin_inference.py
+++ b/astroid/brain/brain_builtin_inference.py
@@ -693,34 +693,46 @@ def infer_type(node, context: InferenceContext | None = None):
def infer_s... | ["tests/test_inference.py::InferenceTest::test_unary_type_errors_for_non_instance_objects", "tests/test_inference.py::SliceTest::test_slice", "tests/test_inference.py::SliceTest::test_slice_attributes", "tests/test_inference.py::SliceTest::test_slice_inference_error", "tests/test_inference.py::SliceTest::test_slice_typ... | ["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 | 60 | 6 | 1,550 | 0 | 0.6 | 1 | 0.75 | 1 | 0.458333 | 81.65 | |||
4,129 | swe_smith::train::18566 | swe_smith | train | 18,566 | HIPS__autograd.ac044f0d.lm_rewrite__v9lj4x6z | swesmith/HIPS__autograd.ac044f0d | hips/autograd | python | null | ### Bug report
**Bug summary**
The `np.kron` function seems to be causing an `AttributeError` when used with certain input shapes. This issue arises when attempting to compute the Kronecker product of arrays with specific dimensions, leading to unexpected behavior.
**Code for reproduction**
```python
import numpy as... | diff --git a/autograd/numpy/numpy_vjps.py b/autograd/numpy/numpy_vjps.py
index 08d4e1b..45270ee 100644
--- a/autograd/numpy/numpy_vjps.py
+++ b/autograd/numpy/numpy_vjps.py
@@ -374,29 +374,68 @@ defvjp(anp.tile, grad_tile)
def grad_kron(argnum, ans, orig_A, orig_B):
- # kron has different promotion rules than d... | ["tests/test_systematic.py::test_kron"] | ["tests/test_core.py::test_sub", "tests/test_direct.py::test_grad", "tests/test_fft.py::test_rfftn_odd_not_implemented", "tests/test_core.py::test_div", "tests/test_direct.py::test_deriv", "tests/test_linalg.py::test_norm_axis[shape0-2]", "tests/test_linalg.py::test_inv_3d", "tests/test_core.py::test_mul", "tests/test_... | jyangballin/swesmith.x86_64.hips_1776_autograd.ac044f0d | true | null | 1 | 81 | 1 | 1,129 | 0 | 0.6 | 1 | 0.75 | 1 | 0.458167 | 81.6495 | |||
4,130 | swe_smith::train::38454 | swe_smith | train | 38,454 | amueller__word_cloud.ec24191c.combine_file__7za9eqrj | swesmith/amueller__word_cloud.ec24191c | amueller/word_cloud | python | null | # Multiple issues in tokenization.py causing word processing failures
## Bug description
There are several issues in the tokenization.py file that cause word processing to fail. The most noticeable problems are:
1. The collocation scoring function has incorrect sign in the log function
2. The word normalization proc... | diff --git a/wordcloud/tokenization.py b/wordcloud/tokenization.py
index 0d461ff..25008bb 100644
--- a/wordcloud/tokenization.py
+++ b/wordcloud/tokenization.py
@@ -6,26 +6,23 @@ from math import log
def l(k, n, x): # noqa: E741, E743
- # dunning's likelihood ratio with notation from
- # http://nlp.stanford... | ["test/test_wordcloud.py::test_collocations", "test/test_wordcloud.py::test_collocation_stopwords", "test/test_wordcloud.py::test_collocation_stopwords_uppercase", "test/test_wordcloud.py::test_plurals_numbers", "test/test_wordcloud.py::test_multiple_s", "test/test_wordcloud.py::test_default", "test/test_wordcloud.py::... | ["test/test_wordcloud.py::test_empty_text", "test/test_wordcloud.py::test_check_errors", "test/test_wordcloud.py::test_single_color_func", "test/test_wordcloud.py::test_single_color_func_grey", "test/test_wordcloud.py::test_process_text_default_patterns", "test/test_wordcloud.py::test_repeat", "test/test_wordcloud.py::... | jyangballin/swesmith.x86_64.amueller_1776_word_cloud.ec24191c | true | null | 1 | 61 | 28 | 1,528 | 0 | 0.6 | 1 | 0.75 | 1 | 0.458 | 81.649 | |||
4,131 | r2e_gym::train::4992 | r2e_gym | train | 4,992 | datalad__615910dbe77da5573a05456e81b01a67da2a987a | datalad | datalad/datalad | python | 615910dbe77da5573a05456e81b01a67da2a987a | **Title:** AttributeError When Handling `CommandError` in `get_status_dict`
**Description:**
When a `CommandError` exception is passed to the `get_status_dict` function, it raises an `AttributeError` because the `CommandError` object does not have the `format_oneline_tb` method. This prevents the function from correct... | diff --git a/datalad/interface/results.py b/datalad/interface/results.py
--- a/datalad/interface/results.py
+++ b/datalad/interface/results.py
@@ -27,8 +27,12 @@
path_is_subpath,
PurePosixPath,
)
+from datalad.support.exceptions import CommandError
from datalad.support.path import robust_abspath
-
+from dat... | diff --git a/datalad/interface/tests/test_results.py b/datalad/interface/tests/test_results.py
--- a/datalad/interface/tests/test_results.py
+++ b/datalad/interface/tests/test_results.py
@@ -12,9 +12,10 @@
from datalad.interface.results import (
annexjson2result,
+ get_status_dict,
)
from datalad.distribut... | null | null | namanjain12/datalad_final:615910dbe77da5573a05456e81b01a67da2a987a | true | null | 2 | 120 | null | 1,060 | 0 | 0.75 | 1 | 0.6375 | 1 | 0.576667 | 81.64875 | ||
4,132 | swe_smith::train::32762 | swe_smith | train | 32,762 | pydantic__pydantic.acb0f10f.lm_rewrite__673k1cn4 | swesmith/pydantic__pydantic.acb0f10f | pydantic/pydantic | python | null | Pattern validation error messages changed unexpectedly
#### Description
When validating Pattern types with invalid inputs, the error messages have changed from the expected format. The validation now produces `pattern_type` errors with message "Invalid regular expression: ..." instead of the expected specific error t... | diff --git a/pydantic/_internal/_generate_schema.py b/pydantic/_internal/_generate_schema.py
index 9ec8a61..e5cf021 100644
--- a/pydantic/_internal/_generate_schema.py
+++ b/pydantic/_internal/_generate_schema.py
@@ -1752,33 +1752,57 @@ class GenerateSchema:
return core_schema.generator_schema(self.generate_sc... | ["tests/test_types.py::test_pattern_with_invalid_param", "tests/test_types.py::test_pattern_error[re.Pattern-pattern_regex0]", "tests/test_types.py::test_pattern_error[re.Pattern-pattern_regex1]", "tests/test_types.py::test_pattern_error[typing.Pattern-pattern_type0]", "tests/test_types.py::test_pattern_error[typing.Pa... | ["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 | 70 | 11 | 1,343 | 0 | 0.6 | 1 | 0.75 | 1 | 0.457167 | 81.6465 | |||
4,133 | swe_smith::train::34139 | swe_smith | train | 34,139 | iterative__dvc.1d6ea681.combine_module__huz0b3i8 | swesmith/iterative__dvc.1d6ea681 | iterative/dvc | python | null | AttributeError: 'Output' object has no attribute 'path_info'
#### Description
After recent changes to the trie building logic, DVC is failing with `AttributeError: 'Output' object has no attribute 'path_info'` when trying to access output path information. The error occurs in various operations that involve building ... | diff --git a/dvc/repo/experiments/show.py b/dvc/repo/experiments/show.py
index a307718..f4300c8 100644
--- a/dvc/repo/experiments/show.py
+++ b/dvc/repo/experiments/show.py
@@ -174,17 +174,8 @@ def _sort_column( # noqa: C901
sort_name = sep.join(parts[split_num:])
if not path: # handles ':metric_nam... | ["tests/func/params/test_show.py::test_pipeline_params", "tests/func/params/test_show.py::test_deps_multi_stage", "tests/func/params/test_show.py::test_deps_with_targets", "tests/func/params/test_show.py::test_cached_params", "tests/func/params/test_show.py::test_param_in_a_tracked_directory_with_missing_dir_file", "te... | ["tests/func/params/test_show.py::test_show_empty", "tests/func/params/test_show.py::test_show", "tests/func/params/test_show.py::test_show_targets", "tests/func/params/test_show.py::test_show_toml", "tests/func/params/test_show.py::test_show_py", "tests/func/params/test_show.py::test_show_multiple", "tests/func/params... | jyangballin/swesmith.x86_64.iterative_1776_dvc.1d6ea681 | true | null | 2 | 74 | 18 | 1,261 | 0 | 0.6 | 1 | 0.75 | 1 | 0.456833 | 81.6455 | |||
4,134 | swe_bench::test::1695 | swe_bench | test | 1,695 | scikit-learn__scikit-learn-25697 | scikit-learn/scikit-learn | scikit-learn/scikit-learn | python | 097c3683a73c5805a84e6eada71e4928cb35496e | Deprecate `n_iter` in favor of `max_iter` for consistency
`BayesianRidge` and `ARDRegression` are exposing the parameter `n_iter` instead of `max_iter` as in other models. I think that we should deprecate `n_iter` and rename it `max_iter` to be consistent. | @glemaitre I would like to attempt this one !
@saucam please go ahead and propose a pull-request. You can refer to the following documentation page to follow our deprecation rule: https://scikit-learn.org/dev/developers/contributing.html#deprecation
@saucam ,let me know incase you need help. We can work together on thi... | diff --git a/sklearn/linear_model/_bayes.py b/sklearn/linear_model/_bayes.py
--- a/sklearn/linear_model/_bayes.py
+++ b/sklearn/linear_model/_bayes.py
@@ -5,6 +5,7 @@
# Authors: V. Michel, F. Pedregosa, A. Gramfort
# License: BSD 3 clause
+import warnings
from math import log
from numbers import Integral, Real
i... | diff --git a/sklearn/linear_model/tests/test_bayes.py b/sklearn/linear_model/tests/test_bayes.py
--- a/sklearn/linear_model/tests/test_bayes.py
+++ b/sklearn/linear_model/tests/test_bayes.py
@@ -73,7 +73,7 @@ def test_bayesian_ridge_score_values():
alpha_2=alpha_2,
lambda_1=lambda_1,
lambda_2... | ["sklearn/linear_model/tests/test_bayes.py::test_bayesian_ridge_score_values", "sklearn/linear_model/tests/test_bayes.py::test_update_of_sigma_in_ard", "sklearn/linear_model/tests/test_bayes.py::test_bayesian_ridge_ard_n_iter_deprecated[BayesianRidge]", "sklearn/linear_model/tests/test_bayes.py::test_bayesian_ridge_ard... | ["sklearn/linear_model/tests/test_bayes.py::test_bayesian_ridge_scores", "sklearn/linear_model/tests/test_bayes.py::test_bayesian_ridge_parameter", "sklearn/linear_model/tests/test_bayes.py::test_bayesian_sample_weights", "sklearn/linear_model/tests/test_bayes.py::test_toy_bayesian_ridge_object", "sklearn/linear_model/... | null | true | 2023-02-24T21:43:48Z | 1 | 114 | 6 | 256 | 0 | 0.8 | 1 | 0.55 | 1 | 0.422667 | 81.643 | |
4,135 | swe_smith::train::103 | swe_smith | train | 103 | oauthlib__oauthlib.1fd52536.combine_file__lx19kzmh | swesmith/oauthlib__oauthlib.1fd52536 | oauthlib/oauthlib | python | null | # RefreshTokenGrant broken in latest version
### What happened?
When trying to use the refresh token grant type, it fails with various errors. Here's a simple reproduction:
```python
from oauthlib.oauth2 import RefreshTokenGrant
from oauthlib.oauth2 import RequestValidator
validator = RequestValidator()
grant = Ref... | diff --git a/oauthlib/oauth2/rfc6749/grant_types/refresh_token.py b/oauthlib/oauth2/rfc6749/grant_types/refresh_token.py
index 43bf55a..f190dd9 100644
--- a/oauthlib/oauth2/rfc6749/grant_types/refresh_token.py
+++ b/oauthlib/oauth2/rfc6749/grant_types/refresh_token.py
@@ -22,8 +22,8 @@ class RefreshTokenGrant(GrantType... | ["tests/oauth2/rfc6749/grant_types/test_refresh_token.py::RefreshTokenGrantTest::test_authenticate_client_id", "tests/oauth2/rfc6749/grant_types/test_refresh_token.py::RefreshTokenGrantTest::test_authentication_required", "tests/oauth2/rfc6749/grant_types/test_refresh_token.py::RefreshTokenGrantTest::test_authenticatio... | ["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 | 58 | 53 | 1,576 | 0 | 0.6 | 1 | 0.75 | 1 | 0.456 | 81.643 | |||
4,136 | swe_smith::train::44594 | swe_smith | train | 44,594 | mahmoud__glom.fb3c4e76.combine_file__g15o8zw3 | swesmith/mahmoud__glom.fb3c4e76 | mahmoud/glom | python | null | # [Bug]: Pattern matching in glom is broken after recent changes
## Description
After recent changes to the matching module, several pattern matching operations are failing. The issue appears to be in the `_m_repr` and `_precedence` functions which have been modified in a way that breaks existing functionality.
## S... | diff --git a/glom/matching.py b/glom/matching.py
index 798ac40..c17e17e 100644
--- a/glom/matching.py
+++ b/glom/matching.py
@@ -289,12 +289,11 @@ class _Bool:
def _m_repr(self):
"""should this Or() repr as M |?"""
- # only used by And() and Or(), not Not(), so len(children) >= 1
- if isin... | ["glom/test/test_error.py::test_partially_failing_branch", "glom/test/test_match.py::test_basic", "glom/test/test_match.py::test_double_wrapping", "glom/test/test_match.py::test_and_or_reduction", "glom/test/test_match.py::test_precedence", "glom/test/test_match.py::test_cruddy_json", "glom/test/test_match.py::test_rep... | ["glom/test/test_basic.py::test_initial_integration", "glom/test/test_basic.py::test_list_item_lift_and_access", "glom/test/test_basic.py::test_coalesce", "glom/test/test_basic.py::test_skip", "glom/test/test_basic.py::test_stop", "glom/test/test_basic.py::test_top_level_default", "glom/test/test_basic.py::test_val", "... | jyangballin/swesmith.x86_64.mahmoud_1776_glom.fb3c4e76 | true | null | 1 | 50 | 12 | 1,736 | 0 | 0.6 | 1 | 0.75 | 1 | 0.456 | 81.643 | |||
4,137 | swe_smith::train::34355 | swe_smith | train | 34,355 | iterative__dvc.1d6ea681.lm_rewrite__yu6fplgq | swesmith/iterative__dvc.1d6ea681 | iterative/dvc | python | null | # Variables in DVC stage definitions not being processed correctly
## Bug description
When defining stages in DVC with variables, the variables are not being processed correctly. This affects all variable interpolation, foreach loops, and matrix definitions in stage files.
## Reproduction
Create a simple dvc.yaml f... | diff --git a/dvc/parsing/__init__.py b/dvc/parsing/__init__.py
index a0a65d5..fb1e3bd 100644
--- a/dvc/parsing/__init__.py
+++ b/dvc/parsing/__init__.py
@@ -295,51 +295,37 @@ class EntryDefinition:
except ContextError as exc:
format_and_raise(exc, f"stage '{self.name}'", self.relpath)
- def r... | ["tests/func/parsing/test_errors.py::test_vars_interpolation_errors[${file}_params.yaml]", "tests/func/parsing/test_errors.py::test_vars_interpolation_errors[vars_1]", "tests/func/parsing/test_errors.py::test_local_vars_params_file_not_exist", "tests/func/parsing/test_errors.py::test_specified_key_does_not_exist", "tes... | ["tests/func/parsing/test_errors.py::test_failed_to_interpolate", "tests/func/parsing/test_errors.py::test_foreach_data_syntax_error", "tests/func/parsing/test_errors.py::test_foreach_data_key_does_not_exists[modelss]", "tests/func/parsing/test_errors.py::test_foreach_data_key_does_not_exists[modelss.123]", "tests/func... | jyangballin/swesmith.x86_64.iterative_1776_dvc.1d6ea681 | true | null | 1 | 74 | 69 | 1,255 | 0 | 0.6 | 1 | 0.75 | 1 | 0.455833 | 81.6425 | |||
4,138 | swe_smith::train::29700 | swe_smith | train | 29,700 | cookiecutter__cookiecutter.b4451231.lm_rewrite__t9ywmwp3 | swesmith/cookiecutter__cookiecutter.b4451231 | cookiecutter/cookiecutter | python | null | [BUG] YAML config file validation issues in get_config
#### Reference Issues/PRs
None yet.
#### What does this implement/fix? Explain your changes.
There are two issues with the `get_config` function in the config.py file:
1. When a YAML file has an array as the top-level element instead of an object/dictionary, the... | diff --git a/cookiecutter/config.py b/cookiecutter/config.py
index 299a720..91c235d 100644
--- a/cookiecutter/config.py
+++ b/cookiecutter/config.py
@@ -58,33 +58,29 @@ def merge_configs(default: dict[str, Any], overwrite: dict[str, Any]) -> dict[st
return new_config
-def get_config(config_path: Path | str) ->... | ["tests/test_get_config.py::test_get_config_invalid_file_with_array_as_top_level_element", "tests/test_get_config.py::test_get_config_invalid_file_with_multiple_docs"] | ["tests/replay/test_dump.py::test_value_error_if_key_missing_in_context", "tests/replay/test_dump.py::test_ioerror_if_replay_dir_creation_fails", "tests/replay/test_dump.py::test_run_json_dump", "tests/replay/test_load.py::test_value_error_if_key_missing_in_context", "tests/replay/test_load.py::test_io_error_if_no_repl... | jyangballin/swesmith.x86_64.cookiecutter_1776_cookiecutter.b4451231 | true | null | 1 | 46 | 2 | 1,812 | 0 | 0.6 | 1 | 0.75 | 1 | 0.455333 | 81.641 | |||
4,139 | swe_smith::train::5105 | swe_smith | train | 5,105 | agronholm__exceptiongroup.0b4f4937.combine_module__lvq30r88 | swesmith/agronholm__exceptiongroup.0b4f4937 | agronholm/exceptiongroup | python | null | ExceptionGroup exceptions property returns reversed order
#### Description
When accessing the `exceptions` property of an `ExceptionGroup`, the exceptions are returned in reversed order compared to how they were originally added to the group.
#### Steps/Code to Reproduce
```python
from exceptiongroup import Excepti... | diff --git a/src/exceptiongroup/_exceptions.py b/src/exceptiongroup/_exceptions.py
index a4a7ace..40c063a 100644
--- a/src/exceptiongroup/_exceptions.py
+++ b/src/exceptiongroup/_exceptions.py
@@ -116,7 +116,7 @@ class BaseExceptionGroup(BaseException, Generic[_BaseExceptionT_co]):
def exceptions(
self,
... | ["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_type_... | ["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 | 2 | 81 | 43 | 1,110 | 0 | 0.6 | 1 | 0.75 | 1 | 0.455 | 81.64 | |||
4,140 | swe_smith::train::45409 | swe_smith | train | 45,409 | dask__dask.5f61e423.lm_rewrite__cqzhrhb4 | swesmith/dask__dask.5f61e423 | dask/dask | python | null | # DataFrame.squeeze() behavior inconsistent with pandas when using axis=0
## Description
I discovered an issue with the `squeeze()` method in Dask DataFrame. When using `axis=0` with a DataFrame that has only one row, the behavior is inconsistent with pandas.
Given the following code:
```python
import pandas as pd
... | diff --git a/dask/dataframe/dask_expr/_collection.py b/dask/dataframe/dask_expr/_collection.py
index 7aa07d4..6ad6b74 100644
--- a/dask/dataframe/dask_expr/_collection.py
+++ b/dask/dataframe/dask_expr/_collection.py
@@ -3276,20 +3276,46 @@ class DataFrame(FrameBase):
@derived_from(pd.DataFrame)
def squeeze... | ["dask/dataframe/dask_expr/tests/test_collection.py::test_squeeze"] | ["dask/dataframe/dask_expr/tests/test_collection.py::test_del", "dask/dataframe/dask_expr/tests/test_collection.py::test_info[True-None-True]", "dask/dataframe/dask_expr/tests/test_collection.py::test_info[True-None-False]", "dask/dataframe/dask_expr/tests/test_collection.py::test_info[True-None-None]", "dask/dataframe... | jyangballin/swesmith.x86_64.dask_1776_dask.5f61e423 | true | null | 1 | 48 | 1 | 1,770 | 0 | 0.6 | 1 | 0.75 | 1 | 0.455 | 81.64 | |||
4,141 | swe_smith::train::6882 | swe_smith | train | 6,882 | joke2k__faker.8b401a7d.lm_rewrite__ra71hzpl | swesmith/joke2k__faker.8b401a7d | joke2k/faker | python | null | AttributeError: 'Generator' object has no attribute 'kana_name'
**Describe the bug**
After updating the `Factory.create` method, I encountered an `AttributeError` when trying to access the `kana_name` attribute on a `Generator` object. This seems to occur when using the Japanese locale.
**To Reproduce**
Steps to repr... | diff --git a/faker/factory.py b/faker/factory.py
index 6849570..3506278 100644
--- a/faker/factory.py
+++ b/faker/factory.py
@@ -22,48 +22,55 @@ else:
class Factory:
@classmethod
- def create(
- cls,
- locale: Optional[str] = None,
- providers: Optional[List[str]] = None,
- genera... | ["tests/providers/test_address.py::TestBaseProvider::test_administrative_unit_all_locales", "tests/providers/test_address.py::TestBaseProvider::test_country_code_all_locales", "tests/providers/test_address.py::TestBaseProvider::test_current_country_errors", "tests/providers/test_date_time.py::TestAr::test_ar_aa", "test... | ["tests/providers/__init__.py::TestBaseProvider::test_locale", "tests/providers/__init__.py::TestBaseProvider::test_language_code", "tests/providers/__init__.py::TestBaseProvider::test_random_digit", "tests/providers/__init__.py::TestBaseProvider::test_random_digit_not_null", "tests/providers/__init__.py::TestBaseProvi... | jyangballin/swesmith.x86_64.joke2k_1776_faker.8b401a7d | true | null | 1 | 91 | 29 | 909 | 0 | 0.6 | 1 | 0.75 | 1 | 0.454833 | 81.6395 | |||
4,142 | swe_smith::train::27503 | swe_smith | train | 27,503 | arrow-py__arrow.1d70d009.combine_file__g7xl7zbb | swesmith/arrow-py__arrow.1d70d009 | arrow-py/arrow | python | null | # Timestamp handling issues in Arrow library
## Describe the bug
I've encountered several issues with timestamp handling in the Arrow library. The functions `is_timestamp`, `next_weekday`, and `normalize_timestamp` seem to be behaving incorrectly.
## To Reproduce
Here's a simple script to demonstrate the issues:
``... | diff --git a/arrow/util.py b/arrow/util.py
index f3eaa21..7a7afa4 100644
--- a/arrow/util.py
+++ b/arrow/util.py
@@ -41,21 +41,21 @@ def next_weekday(
raise ValueError("Weekday must be between 0 (Monday) and 6 (Sunday).")
return cast(
datetime.datetime,
- rrule(freq=WEEKLY, dtstart=start_d... | ["tests/test_arrow.py::TestTestArrowFactory::test_fromtimestamp", "tests/test_arrow.py::TestTestArrowFactory::test_utcfromtimestamp", "tests/test_arrow.py::TestArrowUtil::test_get_datetime", "tests/test_factory.py::TestGet::test_timestamp_one_arg_no_arg", "tests/test_factory.py::TestGet::test_struct_time", "tests/test_... | ["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 | 25 | 26 | 2,228 | 0 | 0.6 | 1 | 0.75 | 1 | 0.454667 | 81.639 | |||
4,143 | swe_smith::train::43758 | swe_smith | train | 43,758 | pydata__patsy.a5d16484.combine_file__4zw01ak1 | swesmith/pydata__patsy.a5d16484 | pydata/patsy | python | null | Categorical data handling broken for scalar inputs
#### Description
When passing scalar categorical data to patsy, the categorical shape fixing function incorrectly processes the input, causing errors in downstream operations.
#### Steps/Code to Reproduce
```python
import patsy
import numpy as np
# This should wor... | diff --git a/patsy/categorical.py b/patsy/categorical.py
index c88ecd5..6206c39 100644
--- a/patsy/categorical.py
+++ b/patsy/categorical.py
@@ -158,17 +158,11 @@ def test_guess_categorical():
def _categorical_shape_fix(data):
- # helper function
- # data should not be a _CategoricalBox or pandas Categorical... | ["patsy/categorical.py::test_CategoricalSniffer", "patsy/categorical.py::test_categorical_to_int", "patsy/test_highlevel.py::test_0d_data"] | ["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 | 85 | 3 | 1,025 | 0 | 0.6 | 1 | 0.75 | 1 | 0.454167 | 81.6375 | |||
4,144 | swe_smith::train::46110 | swe_smith | train | 46,110 | conan-io__conan.86f29e13.pr_13367 | swesmith/conan-io__conan.86f29e13 | conan-io/conan | python | null | ### Description
It seems there's an issue with the package installation process in the `BinaryInstaller` class. When attempting to install packages, the process does not handle certain package states correctly, leading to unexpected behavior.
### Steps/Code to Reproduce
Here's a simple script to reproduce the issue:... | diff --git a/conans/client/installer.py b/conans/client/installer.py
index 2c70382..0b111ec 100644
--- a/conans/client/installer.py
+++ b/conans/client/installer.py
@@ -169,7 +169,6 @@ class BinaryInstaller:
""" main responsible of retrieving binary packages or building them from source
locally in case they a... | ["test/unittests/client/optimize_conanfile_load_test.py::OptimizeConanFileLoadTest::test_multiple_load"] | ["test/unittests/client/conan_output_test.py::TestConanOutput::test_output_color_prevent_strip[True-env0]", "test/unittests/client/conan_output_test.py::TestConanOutput::test_output_color_prevent_strip[True-env1]", "test/unittests/client/conan_output_test.py::test_output_forced[1]", "test/unittests/client/conan_output_... | jyangballin/swesmith.x86_64.conan-io_1776_conan.86f29e13 | true | null | 1 | 42 | 1 | 1,882 | 0 | 0.6 | 1 | 0.75 | 1 | 0.453667 | 81.636 | |||
4,145 | swe_smith::train::36065 | swe_smith | train | 36,065 | stanfordnlp__dspy.651a4c71.pr_7940 | swesmith/stanfordnlp__dspy.651a4c71 | stanfordnlp/dspy | python | null | LM.__call__ method is broken and causes NameError
Description
When using the LM class's __call__ method, it causes a NameError because it tries to use variables that haven't been defined yet. This happens when making direct calls to language models.
To reproduce the issue:
```python
import dspy
from dspy.clients.lm... | diff --git a/dspy/clients/base_lm.py b/dspy/clients/base_lm.py
index 9080d4c..2a70583 100644
--- a/dspy/clients/base_lm.py
+++ b/dspy/clients/base_lm.py
@@ -112,22 +112,6 @@ class BaseLM:
"""
raise NotImplementedError("Subclasses must implement this method.")
- def copy(self, **kwargs):
- ... | ["tests/adapters/test_json_adapter.py::test_json_adapter_with_structured_outputs_does_not_mutate_original_signature", "tests/adapters/test_json_adapter.py::test_json_adapter_on_pydantic_model", "tests/caching/test_litellm_cache.py::test_lm_calls_are_cached_across_lm_instances", "tests/caching/test_litellm_cache.py::tes... | ["tests/adapters/test_chat_adapter.py::test_chat_adapter_sync_call", "tests/adapters/test_chat_adapter.py::test_chat_adapter_async_call", "tests/adapters/test_json_adapter.py::test_json_adapter_sync_call", "tests/adapters/test_json_adapter.py::test_json_adapter_async_call", "tests/adapters/test_json_adapter.py::test_js... | jyangballin/swesmith.x86_64.stanfordnlp_1776_dspy.651a4c71 | true | null | 3 | 95 | 22 | 822 | 0 | 0.6 | 1 | 0.75 | 1 | 0.453667 | 81.636 | |||
4,146 | swe_smith::train::5201 | swe_smith | train | 5,201 | agronholm__exceptiongroup.0b4f4937.lm_rewrite__f9wbpgqd | swesmith/agronholm__exceptiongroup.0b4f4937 | agronholm/exceptiongroup | python | null | # Bare `raise` in exception handler doesn't preserve exception chaining
### Description
When using a bare `raise` statement in an exception handler within the `catch` context manager, the exception chaining information (specifically `__cause__`) is lost. This affects how exceptions are propagated and can lead to inco... | diff --git a/src/exceptiongroup/_catch.py b/src/exceptiongroup/_catch.py
index 0246568..15cb971 100644
--- a/src/exceptiongroup/_catch.py
+++ b/src/exceptiongroup/_catch.py
@@ -21,32 +21,29 @@ class _Catcher:
def __enter__(self) -> None:
pass
- def __exit__(
- self,
- etype: type[BaseEx... | ["tests/test_catch.py::test_bare_raise_in_handler"] | ["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 | 49 | 1 | 1,740 | 0 | 0.6 | 1 | 0.75 | 1 | 0.453333 | 81.635 | |||
4,147 | swe_smith::train::12681 | swe_smith | train | 12,681 | lepture__mistune.bf54ef67.lm_rewrite__l3zt01nq | swesmith/lepture__mistune.bf54ef67 | lepture/mistune | python | null | ### Ruby Annotation Parsing Issue
#### Description
It seems there's an issue with the ruby annotation parsing in the latest update. The problem arises when handling ruby annotations with or without links. The parsing logic doesn't seem to handle certain cases correctly, leading to unexpected behavior.
#### Steps to ... | diff --git a/src/mistune/plugins/ruby.py b/src/mistune/plugins/ruby.py
index 6cc3111..c1eba02 100644
--- a/src/mistune/plugins/ruby.py
+++ b/src/mistune/plugins/ruby.py
@@ -14,36 +14,48 @@ RUBY_PATTERN = r'\[(?:\w+\(\w+\))+\]'
_ruby_re = re.compile(RUBY_PATTERN)
-def parse_ruby(inline: "InlineParser", m: Match[str... | ["tests/test_plugins.py::TestPlugin1_ruby::test_ruby_splits_001", "tests/test_plugins.py::TestPlugin1_ruby::test_ruby_splits_002", "tests/test_plugins.py::TestPlugin1_ruby::test_ruby_with_link_001", "tests/test_plugins.py::TestPlugin1_ruby::test_ruby_with_link_002", "tests/test_plugins.py::TestPlugin1_ruby::test_ruby_w... | ["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 | 64 | 18 | 1,437 | 0 | 0.6 | 1 | 0.75 | 1 | 0.452833 | 81.6335 | |||
4,148 | swe_smith::train::34184 | swe_smith | train | 34,184 | iterative__dvc.1d6ea681.func_pm_class_rm_funcs__47jzfk8p | swesmith/iterative__dvc.1d6ea681 | iterative/dvc | python | null | Tqdm progress bar crashes with TypeError when postfix is None
#### Description
When using DVC's progress bar functionality, the application crashes with a `TypeError: 'NoneType' object does not support item assignment` error during cleanup. This happens when the Tqdm progress bar is destroyed and tries to access the ... | diff --git a/dvc/progress.py b/dvc/progress.py
index bdb1723..7adc1ea 100644
--- a/dvc/progress.py
+++ b/dvc/progress.py
@@ -41,67 +41,6 @@ class Tqdm(tqdm):
"miniters": 1,
}
- def __init__(
- self,
- iterable=None,
- disable=None,
- level=logging.ERROR,
- desc=None... | ["tests/unit/fs/test_dvc.py::test_exists", "tests/unit/fs/test_dvc.py::test_open", "tests/unit/fs/test_dvc.py::test_open_in_history", "tests/unit/fs/test_dvc.py::test_isdir_isfile", "tests/unit/fs/test_dvc.py::test_exists_isdir_isfile_dirty", "tests/unit/fs/test_dvc.py::test_isdir_mixed", "tests/unit/fs/test_dvc.py::te... | ["tests/unit/fs/test_dvc.py::test_open_dirty_no_hash", "tests/unit/fs/test_dvc.py::test_walk_missing", "tests/unit/fs/test_dvc.py::test_fsid_noscm"] | jyangballin/swesmith.x86_64.iterative_1776_dvc.1d6ea681 | true | null | 1 | 63 | 28 | 1,455 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4525 | 81.6325 | |||
4,149 | swe_smith::train::22251 | swe_smith | train | 22,251 | tweepy__tweepy.91a41c6e.combine_file__oz6hoig7 | swesmith/tweepy__tweepy.91a41c6e | tweepy/tweepy | python | null | # Cache functionality broken in tweepy
I've discovered a serious issue with the cache functionality in tweepy. Both the MemoryCache and FileCache implementations are broken and not working as expected.
## Description
After updating to the latest version, I noticed that my application started behaving strangely when ... | diff --git a/tweepy/cache.py b/tweepy/cache.py
index bfb87b3..a6399de 100644
--- a/tweepy/cache.py
+++ b/tweepy/cache.py
@@ -85,25 +85,18 @@ class MemoryCache(Cache):
def get(self, key, timeout=None):
self.lock.acquire()
try:
- # check to see if we have this key
entry = se... | ["tests/test_api.py::TweepyAPITests::testcachedresult", "tests/test_api.py::TweepyCacheTests::testfilecache", "tests/test_api.py::TweepyCacheTests::testmemorycache"] | ["tests/test_api.py::TweepyAPITests::test_indicate_direct_message_typing", "tests/test_api.py::TweepyAPITests::testaddremovelistmember", "tests/test_api.py::TweepyAPITests::testaddremovelistmembers", "tests/test_api.py::TweepyAPITests::testcachedifferentqueryparameters", "tests/test_api.py::TweepyAPITests::testcreatede... | jyangballin/swesmith.x86_64.tweepy_1776_tweepy.91a41c6e | true | null | 1 | 35 | 3 | 2,015 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4525 | 81.6325 | |||
4,150 | swe_smith::train::10141 | swe_smith | train | 10,141 | paramiko__paramiko.23f92003.combine_file__ki070dbl | swesmith/paramiko__paramiko.23f92003 | paramiko/paramiko | python | null | SFTPAttributes initialization and from_stat method broken
When creating SFTPAttributes objects or using the from_stat class method, several critical issues occur that break SFTP functionality:
1. The `attr` field is initialized as a list instead of a dictionary, causing attribute access failures
2. Field assignments ... | diff --git a/paramiko/sftp_attr.py b/paramiko/sftp_attr.py
index 18ffbf8..f77a82b 100644
--- a/paramiko/sftp_attr.py
+++ b/paramiko/sftp_attr.py
@@ -51,13 +51,13 @@ class SFTPAttributes:
Create a new (empty) SFTPAttributes object. All fields will be empty.
"""
self._flags = 0
- self.s... | ["tests/test_sftp.py::TestSFTP::test_file", "tests/test_sftp.py::TestSFTP::test_write", "tests/test_sftp.py::TestSFTP::test_sftp_file_can_be_used_as_context_manager", "tests/test_sftp.py::TestSFTP::test_append", "tests/test_sftp.py::TestSFTP::test_rename", "tests/test_sftp.py::TestSFTP::testa_posix_rename", "tests/test... | ["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 | 52 | 44 | 1,674 | 0 | 0.6 | 1 | 0.75 | 1 | 0.452333 | 81.632 | |||
4,151 | swe_smith::train::45243 | swe_smith | train | 45,243 | dask__dask.5f61e423.combine_module__oixbxnrz | swesmith/dask__dask.5f61e423 | dask/dask | python | null | DataFrame.squeeze() fails with axis=0 for single-row DataFrames
#### Description
When calling `squeeze(axis=0)` on a single-row DataFrame, the method raises a `NotImplementedError` instead of returning a Series as expected. This breaks compatibility with pandas behavior.
#### Steps/Code to Reproduce
```python
impor... | diff --git a/dask/dataframe/dask_expr/_collection.py b/dask/dataframe/dask_expr/_collection.py
index 7aa07d4..6ad6b74 100644
--- a/dask/dataframe/dask_expr/_collection.py
+++ b/dask/dataframe/dask_expr/_collection.py
@@ -3276,20 +3276,46 @@ class DataFrame(FrameBase):
@derived_from(pd.DataFrame)
def squeeze... | ["dask/dataframe/dask_expr/io/tests/test_delayed.py::test_from_delayed[None]", "dask/dataframe/dask_expr/io/tests/test_delayed.py::test_from_delayed[foo]", "dask/dataframe/dask_expr/io/tests/test_delayed.py::test_from_delayed_dask", "dask/dataframe/dask_expr/io/tests/test_io.py::test_io_fusion_zero", "dask/dataframe/da... | ["dask/dataframe/dask_expr/io/tests/test_delayed.py::test_from_delayed_optimizing", "dask/dataframe/dask_expr/io/tests/test_delayed.py::test_from_delayed_fusion", "dask/dataframe/dask_expr/io/tests/test_io.py::test_simplify[<lambda>-<lambda>0]", "dask/dataframe/dask_expr/io/tests/test_io.py::test_simplify[<lambda>-<lam... | jyangballin/swesmith.x86_64.dask_1776_dask.5f61e423 | true | null | 3 | 71 | 6 | 1,294 | 0 | 0.6 | 1 | 0.75 | 1 | 0.452333 | 81.632 | |||
4,152 | swe_smith::train::8229 | swe_smith | train | 8,229 | cantools__cantools.0c6a7871.lm_rewrite__5cr0n0ys | swesmith/cantools__cantools.0c6a7871 | cantools/cantools | python | null | ### [Bug]: ARXML Parsing Error with Scientific Notation
#### Description
When parsing ARXML files, the `parse_number_string` function fails to handle numbers in scientific notation, resulting in an `UnsupportedDatabaseFormatError`.
#### Steps/Code to Reproduce
```python
import cantools
# Load ARXML file
db = cantool... | diff --git a/src/cantools/database/can/formats/arxml/utils.py b/src/cantools/database/can/formats/arxml/utils.py
index d5236ed..b272ccc 100644
--- a/src/cantools/database/can/formats/arxml/utils.py
+++ b/src/cantools/database/can/formats/arxml/utils.py
@@ -2,8 +2,8 @@
from typing import Union
-def parse_number_str... | ["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_database.py::CanToolsDataba... | ["tests/test_command_line.py::CanToolsCommandLineTest::test_convert", "tests/test_command_line.py::CanToolsCommandLineTest::test_convert_bad_outfile", "tests/test_command_line.py::CanToolsCommandLineTest::test_decode", "tests/test_command_line.py::CanToolsCommandLineTest::test_decode_can_fd", "tests/test_command_line.p... | jyangballin/swesmith.x86_64.cantools_1776_cantools.0c6a7871 | true | null | 1 | 81 | 10 | 1,091 | 0 | 0.6 | 1 | 0.75 | 1 | 0.451833 | 81.6305 | |||
4,153 | swe_smith::train::2787 | swe_smith | train | 2,787 | pudo__dataset.5c2dc8d3.combine_file__2krxnkkn | swesmith/pudo__dataset.5c2dc8d3 | pudo/dataset | python | null | # Database class has multiple issues with dialect detection and table operations
I've been working with the dataset library and encountered several issues with the Database class. The problems seem to be related to incorrect dialect detection and table operations.
## Issue Description
When trying to use the Database... | diff --git a/dataset/database.py b/dataset/database.py
index d8a07ad..7b1edb8 100644
--- a/dataset/database.py
+++ b/dataset/database.py
@@ -37,10 +37,6 @@ class Database(object):
engine_kwargs = {}
parsed_url = urlparse(url)
- # if parsed_url.scheme.lower() in 'sqlite':
- # # ... | ["test/test_dataset.py::DatabaseTestCase::test_create_table", "test/test_dataset.py::DatabaseTestCase::test_create_table_custom_id1", "test/test_dataset.py::DatabaseTestCase::test_create_table_custom_id2", "test/test_dataset.py::DatabaseTestCase::test_create_table_custom_id3", "test/test_dataset.py::DatabaseTestCase::t... | ["test/test_dataset.py::DatabaseTestCase::test_contains", "test/test_dataset.py::DatabaseTestCase::test_create_table_no_ids", "test/test_dataset.py::DatabaseTestCase::test_database_url_query_string", "test/test_dataset.py::DatabaseTestCase::test_invalid_values", "test/test_dataset.py::DatabaseTestCase::test_load_table"... | jyangballin/swesmith.x86_64.pudo_1776_dataset.5c2dc8d3 | true | null | 1 | 38 | 30 | 1,951 | 0 | 0.6 | 1 | 0.75 | 1 | 0.451833 | 81.6305 | |||
4,154 | swe_smith::train::14513 | swe_smith | train | 14,513 | hukkin__tomli.443a0c1b.combine_module__phw8vrq7 | swesmith/hukkin__tomli.443a0c1b | hukkin/tomli | python | null | # TOML parsing broken in multiple ways
## Description
I've discovered several issues with the TOML parser that make it completely unusable in its current state. The parser seems to have been significantly altered and now fails to correctly parse TOML files.
## How to reproduce:
1. Try to load a TOML file:
```pytho... | diff --git a/src/tomli/_parser.py b/src/tomli/_parser.py
index 16c76cd..7a69885 100644
--- a/src/tomli/_parser.py
+++ b/src/tomli/_parser.py
@@ -117,14 +117,14 @@ class TOMLDecodeError(ValueError):
def load(__fp: IO[bytes], *, parse_float: ParseFloat = float) -> dict[str, Any]:
"""Parse TOML from a binary file ... | ["tests/test_data.py::TestData::test_invalid", "tests/test_data.py::TestData::test_valid", "tests/test_error.py::TestError::test_invalid_parse_float", "tests/test_misc.py::TestMiscellaneous::test_deepcopy", "tests/test_misc.py::TestMiscellaneous::test_incorrect_load", "tests/test_misc.py::TestMiscellaneous::test_load",... | ["tests/test_error.py::TestError::test_deprecated_tomldecodeerror", "tests/test_error.py::TestError::test_invalid_char_quotes", "tests/test_error.py::TestError::test_line_and_col", "tests/test_error.py::TestError::test_missing_value", "tests/test_error.py::TestError::test_module_name", "tests/test_error.py::TestError::... | jyangballin/swesmith.x86_64.hukkin_1776_tomli.443a0c1b | true | null | 2 | 46 | 7 | 1,788 | 0 | 0.6 | 1 | 0.75 | 1 | 0.451333 | 81.629 | |||
4,155 | swe_smith::train::32490 | swe_smith | train | 32,490 | pydantic__pydantic.acb0f10f.func_pm_class_shuffle_funcs__ytbdmhe0 | swesmith/pydantic__pydantic.acb0f10f | pydantic/pydantic | python | null | PaymentCardNumber validation fails when methods are reordered
#### Description
When using PaymentCardNumber, validation fails with an AttributeError because the `validate` method tries to call `validate_luhn_check_digit` before it's defined in the class.
#### Steps/Code to Reproduce
```python
from pydantic.types im... | diff --git a/pydantic/types.py b/pydantic/types.py
index 02e61dd..211434d 100644
--- a/pydantic/types.py
+++ b/pydantic/types.py
@@ -1930,39 +1930,6 @@ class PaymentCardNumber(str):
last4: str
brand: PaymentCardBrand
- def __init__(self, card_number: str):
- self.validate_digits(card_number)
-
- ... | ["tests/test_docs.py::test_docstrings_examples[pydantic/types.py:2042-2063]", "tests/test_docs.py::test_docstrings_examples[pydantic/types.py:2481-2527]", "tests/test_docs.py::test_docstrings_examples[pydantic/types.py:2580-2626]", "tests/test_docs.py::test_docstrings_examples[pydantic/types.py:2691-2720]", "tests/test... | ["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 | 97 | 13 | 768 | 0 | 0.6 | 1 | 0.75 | 1 | 0.451333 | 81.629 | |||
4,156 | swe_smith::train::48699 | swe_smith | train | 48,699 | facebookresearch__hydra.0f03eb60.combine_module__g5afwmzu | swesmith/facebookresearch__hydra.0f03eb60 | facebookresearch/hydra | python | null | sort() function broken with empty arguments
#### Description
The `sort()` function is not working properly when called with no arguments. It seems like the function implementation was accidentally truncated or modified, causing it to not handle the empty case correctly.
#### Steps/Code to Reproduce
```python
from h... | diff --git a/hydra/_internal/grammar/functions.py b/hydra/_internal/grammar/functions.py
index 6e84a1a..252d590 100644
--- a/hydra/_internal/grammar/functions.py
+++ b/hydra/_internal/grammar/functions.py
@@ -29,47 +29,45 @@ class Functions:
self.definitions[name] = inspect.signature(func)
self.functi... | ["tests/test_hydra_cli_errors.py::test_cli_error[empty_sort]", "tests/test_hydra_cli_errors.py::test_cli_error[sort_interval]", "tests/test_overrides_parser.py::test_value[int(10.0)]", "tests/test_overrides_parser.py::test_value[str(10.0)]", "tests/test_overrides_parser.py::test_value[bool(10.0)]", "tests/test_override... | ["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 | 2 | 84 | 126 | 1,025 | 0 | 0.6 | 1 | 0.75 | 1 | 0.450833 | 81.6275 | |||
4,157 | swe_smith::train::182 | swe_smith | train | 182 | oauthlib__oauthlib.1fd52536.combine_file__z9hi4z5f | swesmith/oauthlib__oauthlib.1fd52536 | oauthlib/oauthlib | python | null | # OAuth1 RequestValidator methods not raising NotImplementedError as expected
## Description
I've discovered an issue with the `RequestValidator` class in the OAuth1 implementation. Two methods that should raise `NotImplementedError` when not implemented by a subclass are now returning values instead:
1. `get_redire... | diff --git a/oauthlib/oauth1/rfc5849/request_validator.py b/oauthlib/oauth1/rfc5849/request_validator.py
index e937aab..5bcfdc0 100644
--- a/oauthlib/oauth1/rfc5849/request_validator.py
+++ b/oauthlib/oauth1/rfc5849/request_validator.py
@@ -408,6 +408,9 @@ class RequestValidator:
* AuthorizationEndpoint
... | ["tests/oauth1/rfc5849/test_request_validator.py::RequestValidatorTests::test_not_implemented"] | ["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 | 24 | 1 | 2,223 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4505 | 81.6265 | |||
4,158 | swe_smith::train::32306 | swe_smith | train | 32,306 | davidhalter__parso.338a5760.lm_rewrite__2gzgr9ih | swesmith/davidhalter__parso.338a5760 | davidhalter/parso | python | null | ### Bug: Unexpected AttributeError in Code Parsing
#### Description
While working with the `parso` library to parse and compare different versions of code, I encountered an `AttributeError` when dealing with certain code structures. This error seems to occur when there are specific whitespace and indentation patterns... | diff --git a/parso/tree.py b/parso/tree.py
index e529871..840cd08 100644
--- a/parso/tree.py
+++ b/parso/tree.py
@@ -414,29 +414,37 @@ class BaseNode(NodeOrLeaf):
on whitespace or comments before a leaf
:return: :py:class:`parso.tree.Leaf` at ``position``, or ``None``
"""
- def bin... | ["test/test_diff_parser.py::test_wrong_whitespace", "test/test_diff_parser.py::test_totally_wrong_whitespace", "test/test_diff_parser.py::test_paren_before_docstring", "test/test_diff_parser.py::test_parentheses_before_method", "test/test_diff_parser.py::test_indentation_issues", "test/test_diff_parser.py::test_open_br... | ["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 | 54 | 7 | 1,622 | 0 | 0.6 | 1 | 0.75 | 1 | 0.450333 | 81.626 | |||
4,159 | swe_smith::train::12658 | swe_smith | train | 12,658 | lepture__mistune.bf54ef67.lm_rewrite__afniqfkm | swesmith/lepture__mistune.bf54ef67 | lepture/mistune | python | null | ### [Bug]: Abbreviation Plugin Fails to Process Abbreviations
#### Bug Summary
The abbreviation plugin is currently failing to process abbreviations correctly. This issue seems to have been introduced in the latest update, and it affects the handling of text with defined abbreviations.
#### Code for Reproduction
``... | diff --git a/src/mistune/plugins/abbr.py b/src/mistune/plugins/abbr.py
index 729106c..3918c65 100644
--- a/src/mistune/plugins/abbr.py
+++ b/src/mistune/plugins/abbr.py
@@ -33,48 +33,53 @@ def parse_ref_abbr(block: "BlockParser", m: Match[str], state: "BlockState") ->
return m.end() + 1
-def process_text(inlin... | ["tests/test_plugins.py::TestPlugin1_abbr::test_abbreviation_001", "tests/test_plugins.py::TestPlugin1_abbr::test_abbreviation_002", "tests/test_plugins.py::TestPlugin1_abbr::test_abbreviation_003", "tests/test_plugins.py::TestPlugin1_abbr::test_abbreviation_004", "tests/test_plugins.py::TestPlugin1_abbr::test_abbrevia... | ["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 | 81 | 20 | 1,079 | 0 | 0.6 | 1 | 0.75 | 1 | 0.449833 | 81.6245 | |||
4,160 | swe_smith::train::23002 | swe_smith | train | 23,002 | graphql-python__graphene.82903263.lm_rewrite__zh7mrrwv | swesmith/graphql-python__graphene.82903263 | graphql-python/graphene | python | null | # Import string with dotted attributes fails with incorrect error message
## Describe the bug
When using `import_string` with dotted attributes, if an attribute doesn't exist, the error message is incorrect. It reports that the attribute is missing from the module path rather than from the object.
## How to Reproduc... | diff --git a/graphene/utils/module_loading.py b/graphene/utils/module_loading.py
index d9095d0..5f86f9d 100644
--- a/graphene/utils/module_loading.py
+++ b/graphene/utils/module_loading.py
@@ -11,35 +11,30 @@ def import_string(dotted_path, dotted_attributes=None):
attribute path. Raise ImportError if the import fa... | ["graphene/utils/tests/test_module_loading.py::test_import_string_attributes"] | ["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 | 1 | 43 | 1 | 1,838 | 0 | 0.6 | 1 | 0.75 | 1 | 0.449667 | 81.624 | |||
4,161 | swe_bench::test::1270 | swe_bench | test | 1,270 | pydata__xarray-5365 | pydata/xarray | pydata/xarray | python | 3960ea3ba08f81d211899827612550f6ac2de804 | Feature request: vector cross product
xarray currently has the `xarray.dot()` function for calculating arbitrary dot products which is indeed very handy.
Sometimes, especially for physical applications I also need a vector cross product. I' wondering whether you would be interested in having ` xarray.cross` as a wrappe... | Very useful :+1:
I would add:
```
try:
c.attrs["units"] = a.attrs["units"] + '*' + b.attrs["units"]
except KeyError:
pass
```
to preserve units - but I am not sure that is in scope for xarray.
it is not, but we have been working on [unit aware arrays with `pint`](https://github.com/pyda... | diff --git a/xarray/__init__.py b/xarray/__init__.py
--- a/xarray/__init__.py
+++ b/xarray/__init__.py
@@ -16,7 +16,16 @@
from .core.alignment import align, broadcast
from .core.combine import combine_by_coords, combine_nested
from .core.common import ALL_DIMS, full_like, ones_like, zeros_like
-from .core.computatio... | diff --git a/xarray/tests/test_computation.py b/xarray/tests/test_computation.py
--- a/xarray/tests/test_computation.py
+++ b/xarray/tests/test_computation.py
@@ -1952,3 +1952,110 @@ def test_polyval(use_dask, use_datetime) -> None:
da_pv = xr.polyval(da.x, coeffs)
xr.testing.assert_allclose(da, da_pv.T)
+
... | ["xarray/tests/test_computation.py::test_cross[a0-b0-ae0-be0-dim_0--1-False]", "xarray/tests/test_computation.py::test_cross[a1-b1-ae1-be1-dim_0--1-False]", "xarray/tests/test_computation.py::test_cross[a2-b2-ae2-be2-dim_0--1-False]", "xarray/tests/test_computation.py::test_cross[a3-b3-ae3-be3-dim_0--1-False]", "xarray... | ["xarray/tests/test_computation.py::test_signature_properties", "xarray/tests/test_computation.py::test_result_name", "xarray/tests/test_computation.py::test_ordered_set_union", "xarray/tests/test_computation.py::test_ordered_set_intersection", "xarray/tests/test_computation.py::test_join_dict_keys", "xarray/tests/test... | null | true | 2021-05-23T13:03:42Z | 2 | 221 | 7 | 2,822 | 0 | 0.8 | 1 | 0.7 | 0.75 | 0.970333 | 81.6235 | |
4,162 | swe_smith::train::30644 | swe_smith | train | 30,644 | mido__mido.a0158ff9.combine_file__c656xh8u | swesmith/mido__mido.a0158ff9 | mido/mido | python | null | [Bug]: Pitchwheel range check is too restrictive and time type check is incorrect
### Bug summary
I found two issues with the message validation in the latest version:
1. The pitchwheel range check is too restrictive, rejecting valid values at the min/max boundaries
2. The time check is incorrectly requiring integer... | diff --git a/mido/messages/checks.py b/mido/messages/checks.py
index 2d71918..a702fb2 100644
--- a/mido/messages/checks.py
+++ b/mido/messages/checks.py
@@ -35,10 +35,10 @@ def check_pos(pos):
def check_pitch(pitch):
if not isinstance(pitch, Integral):
- raise TypeError('pichwheel value must be int')
- ... | ["../dev/tests/messages/test_checks.py::test_check_time", "../dev/tests/messages/test_messages.py::test_encode_pitchwheel", "../dev/tests/messages/test_messages.py::test_init_invalid_argument", "../dev/tests/messages/test_messages.py::test_copy_invalid_argument"] | ["../dev/tests/test_frozen.py::test_hashability", "../dev/tests/test_frozen.py::test_freeze_and_thaw", "../dev/tests/test_frozen.py::test_thawed_message_is_copy", "../dev/tests/test_frozen.py::test_is_frozen", "../dev/tests/test_frozen.py::test_frozen_repr", "../dev/tests/test_frozen.py::test_frozen_meta_repr", "../dev... | jyangballin/swesmith.x86_64.mido_1776_mido.a0158ff9 | true | null | 1 | 45 | 4 | 1,796 | 0 | 0.6 | 1 | 0.75 | 1 | 0.449333 | 81.623 | |||
4,163 | swe_smith::train::8363 | swe_smith | train | 8,363 | pyupio__safety.7654596b.combine_file__3oso2p08 | swesmith/pyupio__safety.7654596b | pyupio/safety | python | null | # Database validation logic is inverted in is_valid_database function
## Description
I noticed that the `is_valid_database` function in `safety.py` has an inverted logic that causes it to validate databases incorrectly.
When checking if a database is valid, the function returns `True` when the schema version doesn't... | diff --git a/safety/safety.py b/safety/safety.py
index 7bb6ad7..a9a36fa 100644
--- a/safety/safety.py
+++ b/safety/safety.py
@@ -307,10 +307,10 @@ def is_valid_database(db: Dict[str, Any]) -> bool:
bool: True if the database is valid, False otherwise.
"""
try:
- if db['meta']['schema_version']... | ["tests/test_cli.py::TestSafetyCLI::test_announcements_if_is_not_tty", "tests/test_cli.py::TestSafetyCLI::test_basic_html_output_pass", "tests/test_cli.py::TestSafetyCLI::test_check_ignore_format_backward_compatible", "tests/test_cli.py::TestSafetyCLI::test_check_ignore_unpinned_requirements", "tests/test_cli.py::TestS... | ["tests/test_cli.py::TestSafetyCLI::test_check_continue_on_error", "tests/test_cli.py::TestSafetyCLI::test_check_with_fix_does_verify_api_key", "tests/test_cli.py::TestSafetyCLI::test_check_with_fix_only_works_with_files", "tests/test_cli.py::TestSafetyCLI::test_command_line_interface", "tests/test_cli.py::TestSafetyCL... | jyangballin/swesmith.x86_64.pyupio_1776_safety.7654596b | true | null | 1 | 71 | 23 | 1,275 | 0 | 0.6 | 1 | 0.75 | 1 | 0.449167 | 81.6225 | |||
4,164 | swe_bench::test::1018 | swe_bench | test | 1,018 | matplotlib__matplotlib-23348 | matplotlib/matplotlib | matplotlib/matplotlib | python | 5f53d997187e883f7fd7b6e0378e900e2384bbf1 | MultiCursor should be able to bind to axes in more than one figure...
Multicursor only works if all the axes are in the same figure...
> Each tab is its own Figure/Canvas. MultiCursor only binds itself to one Canvas so it only sees mouse events from axes on in the figure that canvas is associated with.
> The fix he... | This is complicated by https://github.com/matplotlib/matplotlib/issues/21496 . | diff --git a/examples/widgets/multicursor.py b/examples/widgets/multicursor.py
--- a/examples/widgets/multicursor.py
+++ b/examples/widgets/multicursor.py
@@ -5,22 +5,27 @@
Showing a cursor on multiple plots simultaneously.
-This example generates two subplots and on hovering the cursor over data in one
-subplot, ... | diff --git a/lib/matplotlib/tests/test_widgets.py b/lib/matplotlib/tests/test_widgets.py
--- a/lib/matplotlib/tests/test_widgets.py
+++ b/lib/matplotlib/tests/test_widgets.py
@@ -1516,11 +1516,12 @@ def test_polygon_selector_box(ax):
[(True, True), (True, False), (False, True)],
)
def test_MultiCursor(horizOn, v... | ["lib/matplotlib/tests/test_widgets.py::test_MultiCursor[True-True]", "lib/matplotlib/tests/test_widgets.py::test_MultiCursor[True-False]", "lib/matplotlib/tests/test_widgets.py::test_MultiCursor[False-True]"] | ["lib/matplotlib/tests/test_widgets.py::test_rectangle_minspan[0-10-0-10-data]", "lib/matplotlib/tests/test_widgets.py::test_rectangle_minspan[0-10-0-10-pixels]", "lib/matplotlib/tests/test_widgets.py::test_rectangle_minspan[0-10-1-10.5-data]", "lib/matplotlib/tests/test_widgets.py::test_rectangle_minspan[0-10-1-10.5-p... | null | true | 2022-06-25T22:45:58Z | 2 | 72 | 3 | 1,050 | 0 | 0.8 | 1 | 0.55 | 1 | 0.415 | 81.62 | |
4,165 | swe_smith::train::10376 | swe_smith | train | 10,376 | paramiko__paramiko.23f92003.func_basic__9wo3cxd9 | swesmith/paramiko__paramiko.23f92003 | paramiko/paramiko | python | null | SFTP operations failing with incorrect status codes and argument ordering
#### Description
SFTP operations are returning incorrect status codes and experiencing argument ordering issues, causing various file operations to fail unexpectedly.
#### Steps/Code to Reproduce
```python
import paramiko
# Set up SFTP conne... | diff --git a/paramiko/sftp_server.py b/paramiko/sftp_server.py
index cd3910d..70bf23c 100644
--- a/paramiko/sftp_server.py
+++ b/paramiko/sftp_server.py
@@ -380,13 +380,13 @@ class SFTPServer(BaseSFTP, SubsystemHandler):
flags = self._convert_pflags(msg.get_int())
attr = SFTPAttributes._from_m... | ["tests/test_sftp.py::TestSFTP::test_file", "tests/test_sftp.py::TestSFTP::test_write", "tests/test_sftp.py::TestSFTP::test_sftp_file_can_be_used_as_context_manager", "tests/test_sftp.py::TestSFTP::test_append", "tests/test_sftp.py::TestSFTP::test_rename", "tests/test_sftp.py::TestSFTP::testa_posix_rename", "tests/test... | ["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 | 56 | 43 | 1,569 | 0 | 0.6 | 1 | 0.75 | 1 | 0.448167 | 81.6195 | |||
4,166 | swe_smith::train::33122 | swe_smith | train | 33,122 | django-money__django-money.835c1ab8.combine_module__p41e1hov | swesmith/django-money__django-money.835c1ab8 | django-money/django-money | python | null | # Exchange rate backend issues with currency and value swapped
## Description
I've discovered a bug in the exchange rate backend implementation. When updating rates, the currency and value parameters are swapped, causing incorrect data to be stored in the database.
## Steps to reproduce
1. Create a simple script th... | diff --git a/djmoney/contrib/exchange/backends/base.py b/djmoney/contrib/exchange/backends/base.py
index d6c8a7b..ef9c967 100644
--- a/djmoney/contrib/exchange/backends/base.py
+++ b/djmoney/contrib/exchange/backends/base.py
@@ -47,17 +47,17 @@ class BaseExchangeBackend:
def get_response(self, **params):
... | ["tests/contrib/exchange/test_backends.py::TestBackends::test_get_rates[setup1]", "tests/contrib/exchange/test_backends.py::TestBackends::test_initial_update_rates[setup1]", "tests/contrib/exchange/test_backends.py::TestBackends::test_second_update_rates[setup1]", "tests/contrib/exchange/test_commands.py::TestCommand::... | ["tests/contrib/exchange/test_admin.py::test_last_update", "tests/contrib/exchange/test_backends.py::test_missing_settings[FixerBackend]", "tests/contrib/exchange/test_backends.py::test_missing_settings[OpenExchangeRatesBackend]", "tests/contrib/exchange/test_backends.py::test_certifi_not_installed", "tests/contrib/exc... | jyangballin/swesmith.x86_64.django-money_1776_django-money.835c1ab8 | true | null | 2 | 38 | 5 | 1,920 | 0 | 0.6 | 1 | 0.75 | 1 | 0.446667 | 81.615 | |||
4,167 | swe_smith::train::41977 | swe_smith | train | 41,977 | scanny__python-pptx.278b47b1.func_pm_class_rm_funcs__9s9nf6sp | swesmith/scanny__python-pptx.278b47b1 | scanny/python-pptx | python | null | PlotTypeInspector fails to determine chart types for bar, bubble, and scatter charts
#### Description
The PlotTypeInspector class is unable to determine chart types for bar charts, bubble charts, and scatter (XY) charts. When trying to identify these chart types, the inspector raises AttributeError because the requir... | diff --git a/src/pptx/chart/plot.py b/src/pptx/chart/plot.py
index 6e72358..5bf8b95 100644
--- a/src/pptx/chart/plot.py
+++ b/src/pptx/chart/plot.py
@@ -296,38 +296,6 @@ class PlotTypeInspector(object):
ST_Grouping.PERCENT_STACKED: XL.AREA_STACKED_100,
}[plot._element.grouping_val]
- @classme... | ["tests/chart/test_chart.py::DescribeChart::it_can_replace_the_chart_data", "tests/chart/test_plot.py::DescribePlotTypeInspector::it_can_determine_the_chart_type_of_a_plot[chart_type_fixture0]", "tests/chart/test_plot.py::DescribePlotTypeInspector::it_can_determine_the_chart_type_of_a_plot[chart_type_fixture1]", "tests... | ["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 | 63 | 50 | 1,416 | 0 | 0.6 | 1 | 0.75 | 1 | 0.446 | 81.613 | |||
4,168 | swe_smith::train::24013 | swe_smith | train | 24,013 | sunpy__sunpy.f8edfd5c.func_pm_ctrl_shuffle__gsqpok0s | swesmith/sunpy__sunpy.f8edfd5c | sunpy/sunpy | python | null | Helioprojective make_3d() method broken due to variable ordering issue
#### Description
The `make_3d()` method in the `Helioprojective` coordinate frame is failing with `UnboundLocalError: cannot access local variable 'bypass' where it is not associated with a value`. This appears to be caused by variables being used... | diff --git a/sunpy/coordinates/frames.py b/sunpy/coordinates/frames.py
index 8e1efd5..c4979e7 100644
--- a/sunpy/coordinates/frames.py
+++ b/sunpy/coordinates/frames.py
@@ -529,29 +529,24 @@ class Helioprojective(SunPyBaseCoordinateFrame):
return _angular_radius(self.rsun, self.observer.radius)
def make... | ["sunpy/coordinates/tests/test_frames.py::test_hpc_distance", "sunpy/coordinates/tests/test_frames.py::test_hpc_distance_cartesian", "sunpy/coordinates/tests/test_frames.py::test_hpc_distance_off_limb", "sunpy/coordinates/tests/test_frames.py::test_hpc_distance_3D", "sunpy/coordinates/tests/test_frames.py::test_hpc_low... | ["sunpy/coordinates/tests/test_frames.py::test_create_hpc_2d[args0-None]", "sunpy/coordinates/tests/test_frames.py::test_create_hpc_2d[args1-kwargs1]", "sunpy/coordinates/tests/test_frames.py::test_create_hpc_2d[args2-None]", "sunpy/coordinates/tests/test_frames.py::test_create_hpc_2d[args3-kwargs3]", "sunpy/coordinate... | jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c | true | null | 1 | 67 | 27 | 1,336 | 0 | 0.6 | 1 | 0.75 | 1 | 0.446 | 81.613 | |||
4,169 | swe_smith::train::46652 | swe_smith | train | 46,652 | python-trio__trio.cfbbe2c1.combine_file__og8n2hh5 | swesmith/python-trio__trio.cfbbe2c1 | python-trio/trio | python | null | # Multiple issues with TCP connection handling in Trio
I've found several issues with the TCP connection handling in Trio that are causing problems:
## Issue 1: Incorrect format_host_port function behavior
The `format_host_port` function is incorrectly formatting host:port strings. It's using a semicolon (`;`) inste... | diff --git a/src/trio/_highlevel_open_tcp_stream.py b/src/trio/_highlevel_open_tcp_stream.py
index d4ec983..d2160d0 100644
--- a/src/trio/_highlevel_open_tcp_stream.py
+++ b/src/trio/_highlevel_open_tcp_stream.py
@@ -123,44 +123,35 @@ def close_all() -> Generator[set[SocketType], None, None]:
yield sockets_to_... | ["src/trio/_tests/test_highlevel_open_tcp_listeners.py::test_open_tcp_listeners_ipv6_v6only", "src/trio/_tests/test_highlevel_open_tcp_stream.py::test_close_all", "src/trio/_tests/test_highlevel_open_tcp_stream.py::test_reorder_for_rfc_6555_section_5_4", "src/trio/_tests/test_highlevel_open_tcp_stream.py::test_format_h... | ["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 | 29 | 7 | 2,094 | 0 | 0.6 | 1 | 0.75 | 1 | 0.445667 | 81.612 | |||
4,170 | swe_smith::train::27435 | swe_smith | train | 27,435 | tkrajina__gpxpy.09fc46b3.lm_rewrite__5vxwlny3 | swesmith/tkrajina__gpxpy.09fc46b3 | tkrajina/gpxpy | python | null | TypeError when using reduce_points with both max_points and min_distance parameters
I'm trying to use the reduce_points method with both max_points and min_distance parameters, but I'm getting a TypeError.
Here's a simple example that reproduces the issue:
```python
import gpxpy
# Load a GPX file
with open('my_trac... | diff --git a/test.py b/test.py
index 7dd6f44..7318dbd 100644
--- a/test.py
+++ b/test.py
@@ -451,37 +451,55 @@ class GPXTests(mod_unittest.TestCase):
self.assertEqual(gpx.tracks[0].segments[0].points[1].time, mod_datetime.datetime(1901, 12, 13, 20, 45, 52, 207000, tzinfo=mod_gpxfield.SimpleTZ()))
def te... | ["test.py::GPXTests::test_reduce_gpx_file"] | ["test.py::GPXTests::test_10_to_11_conversion", "test.py::GPXTests::test_add_elevation", "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_a... | jyangballin/swesmith.x86_64.tkrajina_1776_gpxpy.09fc46b3 | true | null | 1 | 80 | 1 | 1,073 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4455 | 81.6115 | |||
4,171 | swe_smith::train::24493 | swe_smith | train | 24,493 | sunpy__sunpy.f8edfd5c.combine_module__dclw9x8e | swesmith/sunpy__sunpy.f8edfd5c | sunpy/sunpy | python | null | OpenCV rotation function fails with UnboundLocalError when cv2 import fails
#### Description
The OpenCV rotation function in `sunpy.image.transform` raises an `UnboundLocalError` when trying to access the `cv2` variable after an import failure. The variable `cv2` is referenced before the import statement, causing the... | diff --git a/sunpy/image/resample.py b/sunpy/image/resample.py
index c7b72f5..4d0474e 100644
--- a/sunpy/image/resample.py
+++ b/sunpy/image/resample.py
@@ -49,31 +49,27 @@ def resample(orig, dimensions, method='linear', center=False, minusone=False):
----------
https://scipy-cookbook.readthedocs.io/items/Reb... | ["sunpy/image/tests/test_resample.py::test_resample_nearest", "sunpy/image/tests/test_resample.py::test_resample_linear", "sunpy/image/tests/test_transform.py::test_endian[0-opencv]", "sunpy/image/tests/test_transform.py::test_endian[1-opencv]", "sunpy/image/tests/test_transform.py::test_endian[3-opencv]"] | ["sunpy/image/tests/test_resample.py::test_resample_spline", "sunpy/image/tests/test_resample.py::test_reshape", "sunpy/image/tests/test_transform.py::test_rotation[90.0-1]", "sunpy/image/tests/test_transform.py::test_rotation[-90.0--1]", "sunpy/image/tests/test_transform.py::test_rotation[-270.0-1]", "sunpy/image/test... | jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c | true | null | 2 | 81 | 5 | 1,051 | 0 | 0.6 | 1 | 0.75 | 1 | 0.445167 | 81.6105 | |||
4,172 | swe_smith::train::29692 | swe_smith | train | 29,692 | cookiecutter__cookiecutter.b4451231.lm_rewrite__khjpk31i | swesmith/cookiecutter__cookiecutter.b4451231 | cookiecutter/cookiecutter | python | null | ### Issue: Unexpected Keyword Argument 'password' in `determine_repo_dir`
**Description of the problem:**
When attempting to determine the repository directory using the `determine_repo_dir` function, an error is raised due to an unexpected keyword argument 'password'. This occurs when handling repository URLs or zip... | diff --git a/cookiecutter/repository.py b/cookiecutter/repository.py
index f2e2ca2..6c20beb 100644
--- a/cookiecutter/repository.py
+++ b/cookiecutter/repository.py
@@ -67,15 +67,10 @@ def repository_has_cookiecutter_json(repo_directory: str) -> bool:
return repo_directory_exists and repo_config_exists
-def de... | ["tests/repository/test_determine_repo_dir_clones_repo.py::test_zipfile_unzip[/path/to/zipfile.zip-False]", "tests/repository/test_determine_repo_dir_clones_repo.py::test_zipfile_unzip[https://example.com/path/to/zipfile.zip-True]", "tests/repository/test_determine_repo_dir_clones_repo.py::test_zipfile_unzip[http://exa... | ["tests/replay/test_dump.py::test_value_error_if_key_missing_in_context", "tests/replay/test_dump.py::test_ioerror_if_replay_dir_creation_fails", "tests/replay/test_dump.py::test_run_json_dump", "tests/replay/test_load.py::test_value_error_if_key_missing_in_context", "tests/replay/test_load.py::test_io_error_if_no_repl... | jyangballin/swesmith.x86_64.cookiecutter_1776_cookiecutter.b4451231 | true | null | 1 | 65 | 11 | 1,371 | 0 | 0.6 | 1 | 0.75 | 1 | 0.445167 | 81.6105 | |||
4,173 | swe_smith::train::52580 | swe_smith | train | 52,580 | pydicom__pydicom.7d361b3d.func_pm_remove_cond__hq5aiq5i | swesmith/pydicom__pydicom.7d361b3d | pydicom/pydicom | python | null | generate_fragmented_frames fails with ValueError when processing encapsulated pixel data
#### Description
The `generate_fragmented_frames` function in `pydicom.encaps` is raising a `ValueError` when trying to process encapsulated pixel data, even for basic cases that should work.
#### Steps/Code to Reproduce
```pyt... | diff --git a/src/pydicom/encaps.py b/src/pydicom/encaps.py
index 3493808..891d3a9 100644
--- a/src/pydicom/encaps.py
+++ b/src/pydicom/encaps.py
@@ -241,8 +241,6 @@ def generate_fragmented_frames(
An encapsulated pixel data frame, with the contents of the tuple the
frame's fragmented encoded data.
... | ["tests/pixels/test_decoder_base.py::TestDecoder::test_buffer", "tests/test_encaps.py::TestGeneratePixelDataFrames::test_empty_bot_single_fragment", "tests/test_encaps.py::TestGeneratePixelDataFrames::test_bot_single_fragment", "tests/test_encaps.py::TestGeneratePixelDataFrames::test_bot_triple_fragment_single_frame", ... | ["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 | 72 | 50 | 1,229 | 0 | 0.6 | 1 | 0.75 | 1 | 0.444833 | 81.6095 | |||
4,174 | swe_smith::train::34356 | swe_smith | train | 34,356 | iterative__dvc.1d6ea681.lm_rewrite__zsm4lnm0 | swesmith/iterative__dvc.1d6ea681 | iterative/dvc | python | null | # Frozen stages and stages without commands don't run properly
## Description
I've encountered an issue where stages without commands (like imports) or frozen stages don't run properly. When trying to run a stage that doesn't have a command or is frozen, I get an error message saying it's not a valid command or impor... | diff --git a/dvc/stage/__init__.py b/dvc/stage/__init__.py
index 92835fe..16ffbcb 100644
--- a/dvc/stage/__init__.py
+++ b/dvc/stage/__init__.py
@@ -596,46 +596,21 @@ class Stage(params.StageParams):
raise CacheLinkError(link_failures)
@rwlocked(read=["deps", "outs"])
- def run(
- self,
- ... | ["tests/func/test_stage.py::test_default_wdir_ignored_in_checksum", "tests/func/test_stage.py::test_external_remote_output_resolution", "tests/func/test_stage.py::test_external_remote_dependency_resolution", "tests/func/test_stage.py::test_stage_strings_representation", "tests/func/test_stage.py::test_stage_remove_pipe... | ["tests/func/test_stage.py::test_cmd_obj", "tests/func/test_stage.py::test_no_cmd", "tests/func/test_stage.py::test_object", "tests/func/test_stage.py::test_none", "tests/func/test_stage.py::test_empty_list", "tests/func/test_stage.py::test_list", "tests/func/test_stage.py::test_reload", "tests/func/test_stage.py::test... | jyangballin/swesmith.x86_64.iterative_1776_dvc.1d6ea681 | true | null | 1 | 47 | 9 | 1,728 | 0 | 0.6 | 1 | 0.75 | 1 | 0.444667 | 81.609 | |||
4,175 | swe_smith::train::35887 | swe_smith | train | 35,887 | stanfordnlp__dspy.651a4c71.lm_rewrite__b66xdx0z | swesmith/stanfordnlp__dspy.651a4c71 | stanfordnlp/dspy | python | null | # Cannot enable both LiteLLM and DSPy on-disk cache simultaneously
When configuring caching in DSPy, I've discovered that the validation check that prevents enabling both LiteLLM and DSPy on-disk cache simultaneously has been removed.
## Description
In the current implementation of `configure_cache()`, it's possible... | diff --git a/dspy/clients/__init__.py b/dspy/clients/__init__.py
index 52be745..ca93200 100644
--- a/dspy/clients/__init__.py
+++ b/dspy/clients/__init__.py
@@ -26,14 +26,11 @@ def _litellm_track_cache_hit_callback(kwargs, completion_response, start_time, e
litellm.success_callback = [_litellm_track_cache_hit_callback... | ["tests/caching/test_litellm_cache.py::test_lm_calls_are_cached_in_memory_when_expected", "tests/clients/test_lm.py::test_dspy_cache", "tests/clients/test_lm.py::test_async_lm_call_with_cache", "tests/signatures/test_adapter_image.py::test_pdf_url_support", "tests/signatures/test_adapter_image.py::test_different_mime_t... | ["tests/adapters/test_chat_adapter.py::test_chat_adapter_sync_call", "tests/adapters/test_chat_adapter.py::test_chat_adapter_async_call", "tests/adapters/test_json_adapter.py::test_json_adapter_with_structured_outputs_does_not_mutate_original_signature", "tests/adapters/test_json_adapter.py::test_json_adapter_sync_call... | jyangballin/swesmith.x86_64.stanfordnlp_1776_dspy.651a4c71 | true | null | 1 | 67 | 7 | 1,325 | 0 | 0.6 | 1 | 0.75 | 1 | 0.444167 | 81.6075 | |||
4,176 | swe_smith::train::24926 | swe_smith | train | 24,926 | marshmallow-code__marshmallow.9716fc62.lm_rewrite__h1q0va1t | swesmith/marshmallow-code__marshmallow.9716fc62 | marshmallow-code/marshmallow | python | null | # [Bug]: Schema Meta options validation removed in recent update
## Bug summary
In a recent update, the validation for Schema Meta options has been removed, which can lead to unexpected behavior when using invalid types for `fields`, `additional`, and `exclude` options.
## Code for reproduction
```python
from marsh... | diff --git a/src/marshmallow/schema.py b/src/marshmallow/schema.py
index e21768e..2482647 100644
--- a/src/marshmallow/schema.py
+++ b/src/marshmallow/schema.py
@@ -191,43 +191,35 @@ class SchemaMeta(ABCMeta):
class SchemaOpts:
"""class Meta options for the :class:`Schema`. Defines defaults."""
- def __init_... | ["tests/test_schema.py::test_json_module_is_deprecated", "tests/test_schema.py::test_error_raised_if_fields_option_is_not_list", "tests/test_schema.py::test_error_raised_if_additional_option_is_not_list", "tests/test_schema.py::test_fields_option_must_be_list_or_tuple", "tests/test_schema.py::test_exclude_option_must_b... | ["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 | 1 | 38 | 5 | 1,905 | 0 | 0.6 | 1 | 0.75 | 1 | 0.444167 | 81.6075 | |||
4,177 | swe_smith::train::51295 | swe_smith | train | 51,295 | marshmallow-code__apispec.8b421526.lm_rewrite__3ifk7v2p | swesmith/marshmallow-code__apispec.8b421526 | marshmallow-code/apispec | python | null | # Schema with many=True not working with schema2parameters
## Description
When using a schema with `many=True` in `schema2parameters` with a location other than 'body'/'json', the function doesn't raise an exception as expected. Instead, it tries to process the schema and fails silently.
## Steps to reproduce
Here'... | diff --git a/src/apispec/ext/marshmallow/openapi.py b/src/apispec/ext/marshmallow/openapi.py
index a114e26..9eff71c 100644
--- a/src/apispec/ext/marshmallow/openapi.py
+++ b/src/apispec/ext/marshmallow/openapi.py
@@ -135,15 +135,8 @@ class OpenAPIConverter(FieldConverterMixin):
self.spec.components.schema(... | ["tests/test_ext_marshmallow_openapi.py::TestMarshmallowFieldToOpenAPI::test_fields_default_location_mapping_if_schema_many[2.0]", "tests/test_ext_marshmallow_openapi.py::TestMarshmallowFieldToOpenAPI::test_fields_with_dump_only[2.0]", "tests/test_ext_marshmallow_openapi.py::TestMarshmallowFieldToOpenAPI::test_fields_w... | ["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 | 1 | 50 | 5 | 1,664 | 0 | 0.6 | 1 | 0.75 | 1 | 0.444 | 81.607 | |||
4,178 | swe_smith::train::5299 | swe_smith | train | 5,299 | PyCQA__flake8.cf1542ce.combine_module__8riiv8bt | swesmith/PyCQA__flake8.cf1542ce | pycqa/flake8 | python | null | # PluginExecutionFailed exception shows incorrect error message
When a plugin fails during execution, the error message displayed is incorrect due to parameter swapping in the PluginExecutionFailed class.
## Description
I noticed that when a plugin fails during execution, the error message shows the wrong informatio... | diff --git a/src/flake8/exceptions.py b/src/flake8/exceptions.py
index 18646e7..8d2372f 100644
--- a/src/flake8/exceptions.py
+++ b/src/flake8/exceptions.py
@@ -64,15 +64,15 @@ class PluginExecutionFailed(Flake8Exception):
exception: Exception,
) -> None:
"""Utilize keyword arguments for message ... | ["tests/unit/plugins/reporter_test.py::test_make_formatter_format_string", "tests/unit/test_file_checker.py::test_raises_exception_on_failed_plugin"] | ["tests/integration/test_aggregator.py::test_aggregate_options_with_config", "tests/integration/test_aggregator.py::test_aggregate_options_when_isolated", "tests/integration/test_api_legacy.py::test_legacy_api", "tests/integration/test_checker.py::test_handle_file_plugins[PluginClass]", "tests/integration/test_checker.... | jyangballin/swesmith.x86_64.pycqa_1776_flake8.cf1542ce | true | null | 2 | 55 | 2 | 1,562 | 0 | 0.6 | 1 | 0.75 | 1 | 0.443667 | 81.606 | |||
4,179 | swe_smith::train::48737 | swe_smith | train | 48,737 | facebookresearch__hydra.0f03eb60.combine_module__zq80qpkb | swesmith/facebookresearch__hydra.0f03eb60 | facebookresearch/hydra | python | null | ## BasicLauncher fails to run jobs with missing hydra_context parameter
When using the BasicLauncher to run jobs, the launcher fails because the `run_job` function is called without the required `hydra_context` parameter.
#### Steps to Reproduce
```python
from hydra._internal.core_plugins.basic_launcher import Basic... | diff --git a/hydra/_internal/core_plugins/basic_launcher.py b/hydra/_internal/core_plugins/basic_launcher.py
index af1c349..3fae69f 100644
--- a/hydra/_internal/core_plugins/basic_launcher.py
+++ b/hydra/_internal/core_plugins/basic_launcher.py
@@ -48,36 +48,48 @@ class BasicLauncher(Launcher):
self.hydra_cont... | ["tests/test_basic_launcher.py::TestBasicLauncher::test_sweep_1_job[basic-overrides0]", "tests/test_basic_launcher.py::TestBasicLauncher::test_sweep_2_jobs[basic-overrides0]", "tests/test_basic_launcher.py::TestBasicLauncher::test_not_sweeping_hydra_overrides[basic-overrides0]", "tests/test_basic_launcher.py::TestBasic... | ["tests/test_basic_launcher.py::TestBasicLauncher::test_sweep_1_job_strict_and_bad_key[basic-overrides0]"] | jyangballin/swesmith.x86_64.facebookresearch_1776_hydra.0f03eb60 | true | null | 2 | 76 | 20 | 1,141 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4435 | 81.6055 | |||
4,180 | swe_smith::train::14155 | swe_smith | train | 14,155 | python-openxml__python-docx.0cf6d71f.func_pm_class_rm_funcs__ksl0rqua | swesmith/python-openxml__python-docx.0cf6d71f | python-openxml/python-docx | python | null | Missing methods in Styles class break style operations
#### Description
Several key methods in the Styles class appear to be missing, causing failures when trying to use basic style operations like checking if a style exists, adding new styles, or getting style IDs.
#### Steps/Code to Reproduce
```python
from docx ... | diff --git a/src/docx/styles/styles.py b/src/docx/styles/styles.py
index 98a56e5..a0badbf 100644
--- a/src/docx/styles/styles.py
+++ b/src/docx/styles/styles.py
@@ -23,11 +23,6 @@ class Styles(ElementProxy):
super().__init__(styles)
self._element = styles
- def __contains__(self, name):
- ... | ["tests/parts/test_document.py::DescribeDocumentPart::it_can_get_the_id_of_a_style", "tests/styles/test_styles.py::DescribeStyles::it_supports_the_in_operator_on_style_name[in_fixture0]", "tests/styles/test_styles.py::DescribeStyles::it_supports_the_in_operator_on_style_name[in_fixture1]", "tests/styles/test_styles.py:... | ["tests/dml/test_color.py::DescribeColorFormat::it_knows_its_color_type[type_fixture0]", "tests/dml/test_color.py::DescribeColorFormat::it_knows_its_color_type[type_fixture1]", "tests/dml/test_color.py::DescribeColorFormat::it_knows_its_color_type[type_fixture2]", "tests/dml/test_color.py::DescribeColorFormat::it_knows... | jyangballin/swesmith.x86_64.python-openxml_1776_python-docx.0cf6d71f | true | null | 1 | 60 | 15 | 1,460 | 0 | 0.6 | 1 | 0.75 | 1 | 0.443333 | 81.605 | |||
4,181 | swe_smith::train::19568 | swe_smith | train | 19,568 | seperman__deepdiff.ed252022.lm_rewrite__tvs2lwbf | swesmith/seperman__deepdiff.ed252022 | seperman/deepdiff | python | null | [BUG] stringify_path fails when path is a string
#### Description
When using the `stringify_path` function with a string path, it causes an error in the Delta class when trying to flatten attribute changes.
```python
from deepdiff import DeepDiff, Delta
from some_module import PicklableClass
# Create objects for co... | diff --git a/deepdiff/path.py b/deepdiff/path.py
index ee63b5b..47d2af4 100644
--- a/deepdiff/path.py
+++ b/deepdiff/path.py
@@ -294,23 +294,29 @@ def stringify_path(path, root_element=DEFAULT_FIRST_ELEMENT, quote_str="'{}'"):
For example [1, 2, 'age'] should become
root[1][2]['age']
"""
- if not path... | ["tests/test_delta.py::TestDeltaCompareFunc::test_flatten_attribute_added"] | ["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 | 44 | 1 | 1,774 | 0 | 0.6 | 1 | 0.75 | 1 | 0.442333 | 81.602 | |||
4,182 | swe_smith::train::29237 | swe_smith | train | 29,237 | tox-dev__pipdeptree.c31b6418.lm_rewrite__dx4ttg2n | swesmith/tox-dev__pipdeptree.c31b6418 | tox-dev/pipdeptree | python | null | # EnumAction in pipdeptree doesn't properly validate type and default arguments
## Description
I've found an issue with the `EnumAction` class in pipdeptree. The class doesn't properly validate its arguments, which can lead to unexpected behavior.
When creating an `EnumAction` instance, there are several validation ... | diff --git a/src/pipdeptree/_cli.py b/src/pipdeptree/_cli.py
index 46a984a..61c20e3 100644
--- a/src/pipdeptree/_cli.py
+++ b/src/pipdeptree/_cli.py
@@ -182,46 +182,28 @@ class EnumAction(Action):
"""
- def __init__( # noqa: PLR0913, PLR0917
- self,
- option_strings: list[str],
- dest:... | ["tests/test_cli.py::test_enum_action_type_argument[None]", "tests/test_cli.py::test_enum_action_type_argument[str]", "tests/test_cli.py::test_enum_action_default_argument_not_str", "tests/test_cli.py::test_enum_action_default_argument_not_a_valid_choice"] | ["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 | 42 | 4 | 1,811 | 0 | 0.6 | 1 | 0.75 | 1 | 0.441833 | 81.6005 | |||
4,183 | r2e_gym::train::455 | r2e_gym | train | 455 | orange3__c5188443e44d3e130477d0b9ced9d44757f3bda1 | orange3 | biolab/orange3 | python | c5188443e44d3e130477d0b9ced9d44757f3bda1 | **Analysis:**
- **Key Parts:**
- **Commit Message:** Allows non-unique values in left-join if they're unused.
- **Test Results:** Two tests (`test_nonunique` and `test_nonunique_warning`) failed in the old commit due to issues with `nonunique_right` warnings not being handled correctly.
- **Error Messages:**
... | diff --git a/Orange/widgets/data/owmergedata.py b/Orange/widgets/data/owmergedata.py
--- a/Orange/widgets/data/owmergedata.py
+++ b/Orange/widgets/data/owmergedata.py
@@ -294,6 +294,11 @@
class Warning(widget.OWWidget.Warning):
renamed_vars = Msg("Some variables have been renamed "
... | diff --git a/Orange/widgets/data/tests/test_owmergedata.py b/Orange/widgets/data/tests/test_owmergedata.py
--- a/Orange/widgets/data/tests/test_owmergedata.py
+++ b/Orange/widgets/data/tests/test_owmergedata.py
@@ -838,29 +838,34 @@
self.assertFalse(widget.Error.nonunique_left.is_shown())
self.asser... | null | null | namanjain12/orange3_final:c5188443e44d3e130477d0b9ced9d44757f3bda1 | true | null | 2 | 46 | null | 2,443 | 0 | 0.75 | 1 | 0.6375 | 1 | 0.5605 | 81.60025 | ||
4,184 | swe_smith::train::913 | swe_smith | train | 913 | oauthlib__oauthlib.1fd52536.lm_rewrite__u0bjva5n | swesmith/oauthlib__oauthlib.1fd52536 | oauthlib/oauthlib | python | null | # OAuth1 Authorization Endpoint doesn't verify realms properly
## Description
Hi,
I've found an issue with the OAuth1 Authorization Endpoint in oauthlib. When creating an authorization response with realms, the endpoint doesn't properly verify that the realms are valid.
## Current Behavior
When I try to create an ... | diff --git a/oauthlib/oauth1/rfc5849/endpoints/authorization.py b/oauthlib/oauth1/rfc5849/endpoints/authorization.py
index 00d9576..5e1160c 100644
--- a/oauthlib/oauth1/rfc5849/endpoints/authorization.py
+++ b/oauthlib/oauth1/rfc5849/endpoints/authorization.py
@@ -52,7 +52,7 @@ class AuthorizationEndpoint(BaseEndpoint)... | ["tests/oauth1/rfc5849/endpoints/test_authorization.py::AuthorizationEndpointTest::test_verify_realms"] | ["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 | 39 | 1 | 1,870 | 0 | 0.6 | 1 | 0.75 | 1 | 0.441667 | 81.6 | |||
4,185 | swe_smith::train::45658 | swe_smith | train | 45,658 | conan-io__conan.86f29e13.combine_module__mi2qg2fo | swesmith/conan-io__conan.86f29e13 | conan-io/conan | python | null | ### Profile Dump Order and Settings Update Issue
Hey there! 👋
I've encountered a couple of issues with the current implementation of the `Profile` and `Settings` classes. It seems like there are some unexpected behaviors when working with profile dumps and updating settings.
### Description
1. **Profile Dump Order... | diff --git a/conan/internal/model/profile.py b/conan/internal/model/profile.py
index 54aa126..3ab4549 100644
--- a/conan/internal/model/profile.py
+++ b/conan/internal/model/profile.py
@@ -76,11 +76,8 @@ class Profile:
def dumps(self):
result = ["[settings]"]
- for name, value in sorted(self.sett... | ["test/unittests/model/profile_test.py::ProfileTest::test_apply", "test/unittests/model/profile_test.py::ProfileTest::test_profile_dump_order", "test/unittests/model/settings_test.py::test_set_value_non_existing_values"] | ["test/unittests/model/profile_test.py::ProfileTest::test_package_settings_update", "test/unittests/model/profile_test.py::ProfileTest::test_profile_settings_update", "test/unittests/model/profile_test.py::ProfileTest::test_profile_subsettings_update", "test/unittests/model/profile_test.py::test_update_build_requires",... | jyangballin/swesmith.x86_64.conan-io_1776_conan.86f29e13 | true | null | 2 | 29 | 3 | 2,070 | 0 | 0.6 | 1 | 0.75 | 1 | 0.441667 | 81.6 | |||
4,186 | swe_smith::train::37980 | swe_smith | train | 37,980 | kayak__pypika.1c9646f0.lm_rewrite__nqk3tt63 | swesmith/kayak__pypika.1c9646f0 | kayak/pypika | python | null | Rollup with MySQL and Vertica/Oracle Fails in Certain Scenarios
### What happened?
When using the `rollup` method in a query with MySQL or Vertica/Oracle, the following scenarios lead to unexpected behavior:
1. Attempting to apply multiple rollups in a single query for Vertica/Oracle results in incorrect SQL generat... | diff --git a/pypika/queries.py b/pypika/queries.py
index 42c7c45..2cc253d 100644
--- a/pypika/queries.py
+++ b/pypika/queries.py
@@ -984,31 +984,35 @@ class QueryBuilder(Selectable, Term):
self._with_totals = True
@builder
- def rollup(self, *terms: Union[list, tuple, set, Term], **kwargs: Any) -> "Q... | ["pypika/tests/test_groupby_modifiers.py::RollupTests::test_mysql_one_groupby", "pypika/tests/test_groupby_modifiers.py::RollupTests::test_mysql_rollup_two_groupbys", "pypika/tests/test_groupby_modifiers.py::RollupTests::test_no_rollup_after_rollup_mysql", "pypika/tests/test_groupby_modifiers.py::RollupTests::test_vert... | ["pypika/tests/clickhouse/test_array.py::TestArray::test_get_sql_0__ridley_scott_jimi_hendrix_", "pypika/tests/clickhouse/test_array.py::TestArray::test_get_sql_1__1_2_3_4_", "pypika/tests/clickhouse/test_array.py::TestArray::test_get_sql_2__toInt64_1_toInt64_2_toInt64_3_toInt64_4_", "pypika/tests/clickhouse/test_array... | jyangballin/swesmith.x86_64.kayak_1776_pypika.1c9646f0 | true | null | 1 | 46 | 7 | 1,729 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4415 | 81.5995 | |||
4,187 | swe_smith::train::21155 | swe_smith | train | 21,155 | tobymao__sqlglot.036601ba.lm_rewrite__pkovft2y | swesmith/tobymao__sqlglot.036601ba | tobymao/sqlglot | python | null | ### TypeError in `qualify` Function
#### Description
Encountering a `TypeError` when using the `qualify` function in certain scenarios. This seems to occur when attempting to qualify SQL expressions with specific configurations.
#### Steps/Code to Reproduce
Here's a minimal example to reproduce the issue:
```pytho... | diff --git a/sqlglot/optimizer/qualify.py b/sqlglot/optimizer/qualify.py
index a35699d..3389368 100644
--- a/sqlglot/optimizer/qualify.py
+++ b/sqlglot/optimizer/qualify.py
@@ -16,23 +16,13 @@ from sqlglot.optimizer.qualify_tables import qualify_tables
from sqlglot.schema import Schema, ensure_schema
-def qualify(... | ["tests/test_optimizer.py::TestOptimizer::test_canonicalize", "tests/test_optimizer.py::TestOptimizer::test_expand_alias_refs", "tests/test_optimizer.py::TestOptimizer::test_file_schema", "tests/test_optimizer.py::TestOptimizer::test_lateral_annotation", "tests/test_optimizer.py::TestOptimizer::test_no_pseudocolumn_exp... | ["tests/test_optimizer.py::TestOptimizer::test_aggfunc_annotation", "tests/test_optimizer.py::TestOptimizer::test_annotate_funcs", "tests/test_optimizer.py::TestOptimizer::test_annotate_types", "tests/test_optimizer.py::TestOptimizer::test_binary_annotation", "tests/test_optimizer.py::TestOptimizer::test_bracket_annota... | jyangballin/swesmith.x86_64.tobymao_1776_sqlglot.036601ba | true | null | 1 | 73 | 15 | 1,187 | 0 | 0.6 | 1 | 0.75 | 1 | 0.441167 | 81.5985 | |||
4,188 | swe_smith::train::28918 | swe_smith | train | 28,918 | encode__starlette.db5063c2.lm_rewrite__m4m0cwnn | swesmith/encode__starlette.db5063c2 | encode/starlette | python | null | ### WebSocket Connection Issue
#### Bug Summary
When attempting to establish a WebSocket connection using the `websocket_connect` method, the connection fails unexpectedly, resulting in a `RuntimeError`. This seems to occur when trying to send or receive messages before the WebSocket connection is properly accepted.
... | diff --git a/starlette/testclient.py b/starlette/testclient.py
index 645ca10..350336f 100644
--- a/starlette/testclient.py
+++ b/starlette/testclient.py
@@ -696,29 +696,30 @@ class TestClient(httpx.Client):
extensions=extensions,
)
- def websocket_connect(
- self,
- url: str,
- ... | ["tests/middleware/test_base.py::test_custom_middleware[asyncio]", "tests/middleware/test_base.py::test_custom_middleware[trio]", "tests/test_applications.py::test_websocket_route[asyncio]", "tests/test_applications.py::test_websocket_raise_websocket_exception[asyncio]", "tests/test_applications.py::test_websocket_rais... | ["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/test_base.py::test_contextvars[asyncio-CustomMiddlewareWithoutBaseHTT... | jyangballin/swesmith.x86_64.encode_1776_starlette.db5063c2 | true | null | 1 | 35 | 114 | 1,947 | 0 | 0.6 | 1 | 0.75 | 1 | 0.441167 | 81.5985 | |||
4,189 | swe_smith::train::52631 | swe_smith | train | 52,631 | pydicom__pydicom.7d361b3d.func_pm_remove_wrapper__cx8fablw | swesmith/pydicom__pydicom.7d361b3d | pydicom/pydicom | python | null | `_get_jpg_parameters` returns empty dict instead of parsing JPEG parameters
#### Description
The `_get_jpg_parameters` function in `src/pydicom/pixels/utils.py` is returning an empty dictionary instead of extracting JPEG/JPEG-LS parameters from the input data. This affects any code that relies on getting image metada... | diff --git a/src/pydicom/pixels/utils.py b/src/pydicom/pixels/utils.py
index f9a31a8..c887daa 100644
--- a/src/pydicom/pixels/utils.py
+++ b/src/pydicom/pixels/utils.py
@@ -947,84 +947,9 @@ def _get_jpg_parameters(src: bytes) -> dict[str, Any]:
* ``lossy_error``: int, JPEG-LS only
"""
info: dict[str,... | ["tests/pixels/test_utils.py::TestGetJpgParameters::test_jpg_no_app", "tests/pixels/test_utils.py::TestGetJpgParameters::test_jpg_app", "tests/pixels/test_utils.py::TestGetJpgParameters::test_jpg_component_ids", "tests/pixels/test_utils.py::TestGetJpgParameters::test_jls_ilv0", "tests/pixels/test_utils.py::TestGetJpgPa... | ["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 | 75 | 7 | 1,147 | 0 | 0.6 | 1 | 0.75 | 1 | 0.441167 | 81.5985 | |||
4,190 | swe_smith::train::45405 | swe_smith | train | 45,405 | dask__dask.5f61e423.lm_rewrite__bxt9z8w2 | swesmith/dask__dask.5f61e423 | dask/dask | python | null | ### Describe the bug
It seems that the `isin` method is not functioning as expected in certain scenarios. When attempting to use `isin` on a DataFrame, an `AttributeError` is raised, indicating that the object does not have an attribute 'isin'. This issue appears to be related to the handling of the `isin` method with... | diff --git a/dask/dataframe/dask_expr/_collection.py b/dask/dataframe/dask_expr/_collection.py
index 7aa07d4..07a3c82 100644
--- a/dask/dataframe/dask_expr/_collection.py
+++ b/dask/dataframe/dask_expr/_collection.py
@@ -742,52 +742,36 @@ Expr={expr}"""
)
return new_collection(self.expr)
+ @d... | ["dask/dataframe/dask_expr/tests/test_collection.py::test_filter_pushdown_reducer_in_predicate", "dask/dataframe/dask_expr/tests/test_collection.py::test_isin", "dask/dataframe/dask_expr/tests/test_collection.py::test_isin_repr", "dask/dataframe/dask_expr/tests/test_collection.py::test_simplify_up_blockwise[x-isin-args... | ["dask/dataframe/dask_expr/tests/test_collection.py::test_del", "dask/dataframe/dask_expr/tests/test_collection.py::test_info[True-None-True]", "dask/dataframe/dask_expr/tests/test_collection.py::test_info[True-None-False]", "dask/dataframe/dask_expr/tests/test_collection.py::test_info[True-None-None]", "dask/dataframe... | jyangballin/swesmith.x86_64.dask_1776_dask.5f61e423 | true | null | 1 | 68 | 8 | 1,284 | 0 | 0.6 | 1 | 0.75 | 1 | 0.440667 | 81.597 | |||
4,191 | swe_smith::train::5204 | swe_smith | train | 5,204 | agronholm__exceptiongroup.0b4f4937.lm_rewrite__xcemkw8b | swesmith/agronholm__exceptiongroup.0b4f4937 | agronholm/exceptiongroup | python | null | ### Issue: Unexpected Behavior in Exception Handling with BaseExceptionGroup
**Description of the Problem:**
After a recent update, there seems to be an issue with how `BaseExceptionGroup` handles certain exception scenarios. Specifically, when attempting to split or subgroup exceptions by type, the behavior is not a... | diff --git a/src/exceptiongroup/_exceptions.py b/src/exceptiongroup/_exceptions.py
index a4a7ace..e39c9f7 100644
--- a/src/exceptiongroup/_exceptions.py
+++ b/src/exceptiongroup/_exceptions.py
@@ -56,47 +56,26 @@ def _derive_and_copy_attributes(self, excs):
class BaseExceptionGroup(BaseException, Generic[_BaseExceptio... | ["tests/test_catch.py::test_catch_ungrouped", "tests/test_catch.py::test_catch_group", "tests/test_catch.py::test_catch_nested_group", "tests/test_catch.py::test_catch_no_match", "tests/test_catch.py::test_bare_raise_in_handler", "tests/test_catch.py::test_catch_subclass", "tests/test_catch.py::test_bare_reraise_from_n... | ["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 | 47 | 25 | 1,703 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4405 | 81.5965 | |||
4,192 | swe_smith::train::32382 | swe_smith | train | 32,382 | pydantic__pydantic.acb0f10f.combine_file__k40okubk | swesmith/pydantic__pydantic.acb0f10f | pydantic/pydantic | python | null | ByteSize validation error messages changed unexpectedly
#### Description
The error messages for ByteSize validation have changed from the expected format. When providing invalid byte size strings, the validation errors now show different error types and messages than before.
#### Steps/Code to Reproduce
```python
f... | diff --git a/pydantic/types.py b/pydantic/types.py
index 02e61dd..698bd6b 100644
--- a/pydantic/types.py
+++ b/pydantic/types.py
@@ -1678,8 +1678,15 @@ class Secret(_SecretBase[SecretType]):
2. The input value is not an integer, so it raises a validation error because the `SecretPosInt` type has strict mode enable... | ["tests/test_docs.py::test_docstrings_examples[pydantic/types.py:1811-1826]", "tests/test_docs.py::test_docstrings_examples[pydantic/types.py:1834-1859]", "tests/test_docs.py::test_docstrings_examples[pydantic/types.py:1879-1892]", "tests/test_docs.py::test_docstrings_examples[pydantic/types.py:2042-2063]", "tests/test... | ["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 | 65 | 17 | 1,342 | 0 | 0.6 | 1 | 0.75 | 1 | 0.440333 | 81.596 | |||
4,193 | swe_smith::train::24483 | swe_smith | train | 24,483 | sunpy__sunpy.f8edfd5c.combine_module__8tmaigpr | swesmith/sunpy__sunpy.f8edfd5c | sunpy/sunpy | python | null | show_colormaps function broken when search term returns no results
#### Description
The `show_colormaps` function in `sunpy.visualization.colormaps.cm` raises an `UnboundLocalError` when called with a search term that doesn't match any color maps.
#### Steps/Code to Reproduce
```python
import sunpy.visualization.co... | diff --git a/sunpy/visualization/animator/mapsequenceanimator.py b/sunpy/visualization/animator/mapsequenceanimator.py
index 432cd40..5bb4db3 100644
--- a/sunpy/visualization/animator/mapsequenceanimator.py
+++ b/sunpy/visualization/animator/mapsequenceanimator.py
@@ -64,26 +64,42 @@ class MapSequenceAnimator(BaseFuncA... | ["sunpy/visualization/animator/tests/test_mapsequenceanimator.py::test_map_sequence_animator_wcs_update_plot", "sunpy/visualization/colormaps/tests/test_cm.py::test_invalid_show_cmaps"] | ["sunpy/visualization/animator/tests/test_mapsequenceanimator.py::test_construct_map_sequence_animator", "sunpy/visualization/animator/tests/test_mapsequenceanimator.py::test_axes", "sunpy/visualization/colormaps/tests/test_cm.py::test_get_cmap"] | jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c | true | null | 2 | 90 | 2 | 836 | 0 | 0.6 | 1 | 0.75 | 1 | 0.439333 | 81.593 | |||
4,194 | swe_smith::train::6953 | swe_smith | train | 6,953 | cantools__cantools.0c6a7871.combine_file__7r3w9fcl | swesmith/cantools__cantools.0c6a7871 | cantools/cantools | python | null | ARXML ECU extract loader fails with AttributeError when loading database
#### Description
When loading an ARXML file using the ECU extract loader, the code fails with an AttributeError indicating that a NoneType object has no attribute 'find'. This appears to be related to the initialization and configuration handlin... | diff --git a/src/cantools/database/can/formats/arxml/ecu_extract_loader.py b/src/cantools/database/can/formats/arxml/ecu_extract_loader.py
index 67935ab..90d5690 100644
--- a/src/cantools/database/can/formats/arxml/ecu_extract_loader.py
+++ b/src/cantools/database/can/formats/arxml/ecu_extract_loader.py
@@ -54,14 +54,1... | ["tests/test_database.py::CanToolsDatabaseTest::test_ecu_extract_arxml"] | ["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 | 77 | 1 | 1,096 | 0 | 0.6 | 1 | 0.75 | 1 | 0.439333 | 81.593 | |||
4,195 | swe_smith::train::28025 | swe_smith | train | 28,025 | jsvine__pdfplumber.02ff4313.lm_rewrite__2y1t82st | swesmith/jsvine__pdfplumber.02ff4313 | jsvine/pdfplumber | python | null | CLI JSON Output Parsing Error
Description
When using the CLI to convert a PDF to JSON format, an error occurs during the JSON parsing process. This issue arises when specifying multiple pages and an indentation level for the output.
Example:
```bash
python -m pdfplumber.cli example.pdf --format json --pages 1-2,5 -... | diff --git a/pdfplumber/cli.py b/pdfplumber/cli.py
index 91af3b2..fe0ead1 100644
--- a/pdfplumber/cli.py
+++ b/pdfplumber/cli.py
@@ -18,56 +18,76 @@ def parse_page_spec(p_str: str) -> List[int]:
def parse_args(args_raw: List[str]) -> argparse.Namespace:
- parser = argparse.ArgumentParser("pdfplumber")
-
+ ""... | ["tests/test_convert.py::Test::test_cli_json"] | ["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 | 88 | 1 | 872 | 0 | 0.6 | 1 | 0.75 | 1 | 0.438667 | 81.591 | |||
4,196 | swe_smith::train::31773 | swe_smith | train | 31,773 | davidhalter__parso.338a5760.combine_file__9ubj9fgh | swesmith/davidhalter__parso.338a5760 | davidhalter/parso | python | null | # PEP8Normalizer breaks with TypeError: 'NoneType' object is not iterable
#### Description
I've discovered a bug in the `PEP8Normalizer` class where it's causing a `TypeError: 'NoneType' object is not iterable` when processing Python code. The normalizer seems to be incorrectly handling certain code patterns, particu... | diff --git a/parso/python/pep8.py b/parso/python/pep8.py
index c492dae..4f0ce79 100644
--- a/parso/python/pep8.py
+++ b/parso/python/pep8.py
@@ -129,20 +129,16 @@ class BackslashNode(IndentationNode):
equals = expr_stmt.children[-2]
if '\t' in config.indentation:
- # TODO unit... | ["test/test_normalizer_issues_files.py::test_normalizer_issue[latin-1.py]", "test/test_normalizer_issues_files.py::test_normalizer_issue[E30not.py]", "test/test_normalizer_issues_files.py::test_normalizer_issue[E12_second.py]", "test/test_normalizer_issues_files.py::test_normalizer_issue[E50.py]", "test/test_normalizer... | ["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 | 57 | 32 | 1,491 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4385 | 81.5905 | |||
4,197 | swe_smith::train::36093 | swe_smith | train | 36,093 | stanfordnlp__dspy.651a4c71.pr_8114 | swesmith/stanfordnlp__dspy.651a4c71 | stanfordnlp/dspy | python | null | # ReAct module gets stuck in infinite loop when tool execution fails
## Description
I've discovered an issue with the ReAct module where it can get stuck in an infinite loop when a tool execution fails. The problem appears to be in the `_call_with_potential_trajectory_truncation` method, which now uses a `while True`... | diff --git a/dspy/predict/react.py b/dspy/predict/react.py
index 4b369c0..dd64884 100644
--- a/dspy/predict/react.py
+++ b/dspy/predict/react.py
@@ -29,19 +29,16 @@ class ReAct(Module):
instr.extend(
[
- f"You are an Agent. In each episode, you will be given the fields {inputs} as... | ["tests/predict/test_react.py::test_async_error_retry"] | ["tests/adapters/test_chat_adapter.py::test_chat_adapter_sync_call", "tests/adapters/test_chat_adapter.py::test_chat_adapter_async_call", "tests/adapters/test_json_adapter.py::test_json_adapter_with_structured_outputs_does_not_mutate_original_signature", "tests/adapters/test_json_adapter.py::test_json_adapter_sync_call... | jyangballin/swesmith.x86_64.stanfordnlp_1776_dspy.651a4c71 | true | null | 1 | 39 | 1 | 1,850 | 0 | 0.6 | 1 | 0.75 | 1 | 0.438333 | 81.59 | |||
4,198 | swe_smith::train::44585 | swe_smith | train | 44,585 | mahmoud__glom.fb3c4e76.combine_file__6j1ump4h | swesmith/mahmoud__glom.fb3c4e76 | mahmoud/glom | python | null | # [Bug]: Iter() streaming operations broken in glom
## Bug summary
Multiple streaming operations in the `Iter()` class are broken, causing various errors when trying to use them. The issues affect filtering, mapping, windowing, and other streaming operations.
## Code for reproduction
```python
from glom import glom... | diff --git a/glom/streaming.py b/glom/streaming.py
index 4da5fb5..44e8195 100644
--- a/glom/streaming.py
+++ b/glom/streaming.py
@@ -93,21 +93,18 @@ class Iter:
def _iterate(self, target, scope):
iterate = scope[TargetRegistry].get_handler('iterate', target, path=scope[Path])
try:
- it... | ["glom/test/test_streaming.py::test_iter", "glom/test/test_streaming.py::test_filter", "glom/test/test_streaming.py::test_map", "glom/test/test_streaming.py::test_split_flatten", "glom/test/test_streaming.py::test_chunked", "glom/test/test_streaming.py::test_windowed", "glom/test/test_streaming.py::test_unique", "glom/... | ["glom/test/test_basic.py::test_initial_integration", "glom/test/test_basic.py::test_list_item_lift_and_access", "glom/test/test_basic.py::test_coalesce", "glom/test/test_basic.py::test_skip", "glom/test/test_basic.py::test_stop", "glom/test/test_basic.py::test_top_level_default", "glom/test/test_basic.py::test_val", "... | jyangballin/swesmith.x86_64.mahmoud_1776_glom.fb3c4e76 | true | null | 1 | 28 | 13 | 2,068 | 0 | 0.6 | 1 | 0.75 | 1 | 0.438 | 81.589 | |||
4,199 | swe_smith::train::51339 | swe_smith | train | 51,339 | spulec__freezegun.5f171db0.combine_file__hudw00ia | swesmith/spulec__freezegun.5f171db0 | spulec/freezegun | python | null | freezegun.stop() breaks time functions after multiple start/stop cycles
#### Description
After calling `freeze_time().start()` and `freeze_time().stop()` multiple times, the time functions become corrupted and no longer work properly. The `stop()` method appears to be incorrectly restoring time module functions.
###... | diff --git a/freezegun/api.py b/freezegun/api.py
index d235292..5d235b0 100644
--- a/freezegun/api.py
+++ b/freezegun/api.py
@@ -419,7 +419,7 @@ class FakeDatetime(real_datetime, FakeDate, metaclass=FakeDatetimeMeta):
@classmethod
def today(cls) -> "FakeDatetime":
- return cls.now(tz=None)
+ r... | ["tests/test_asyncio.py::test_datetime_in_coroutine", "tests/test_asyncio.py::test_freezing_time_in_coroutine", "tests/test_asyncio.py::test_freezing_time_before_running_coroutine", "tests/test_asyncio.py::test_asyncio_sleeping_not_affected_by_freeze_time", "tests/test_asyncio.py::test_asyncio_to_call_later_with_frozen... | ["tests/test_configure.py::test_default_ignore_list_is_overridden[ignorelist0]", "tests/test_configure.py::test_default_ignore_list_is_overridden[ignorelist1]", "tests/test_configure.py::test_extend_default_ignore_list[ignorelist0]", "tests/test_configure.py::test_extend_default_ignore_list[ignorelist1]", "tests/test_c... | jyangballin/swesmith.x86_64.spulec_1776_freezegun.5f171db0 | true | null | 1 | 66 | 121 | 1,308 | 0 | 0.6 | 1 | 0.75 | 1 | 0.438 | 81.589 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.