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,200 | swe_smith::train::35132 | swe_smith | train | 35,132 | django__daphne.32ac73e1.lm_rewrite__ojdz9h3d | swesmith/django__daphne.32ac73e1 | django/daphne | python | null | TypeError when using CLI for custom server configurations
Description
I've encountered an issue when trying to run the server with custom CLI configurations. It seems like there's a TypeError being raised when attempting to set up custom endpoints or server names. This happens when using options like `--server-name`,... | diff --git a/daphne/cli.py b/daphne/cli.py
index a036821..a39a42f 100755
--- a/daphne/cli.py
+++ b/daphne/cli.py
@@ -206,60 +206,34 @@ class CommandLineInterface:
Pass in raw argument list and it will decode them
and run the server.
"""
- # Decode args
+ # Parse the args
... | ["tests/test_cli.py::TestCLIInterface::testCLIBasics", "tests/test_cli.py::TestCLIInterface::testCustomEndpoints", "tests/test_cli.py::TestCLIInterface::testMixedCLIEndpointCreation", "tests/test_cli.py::TestCLIInterface::testUnixSockets", "tests/test_cli.py::TestCLIInterface::test_custom_proxyhost", "tests/test_cli.py... | ["tests/test_checks.py::test_check_daphne_installed", "tests/test_cli.py::TestEndpointDescriptions::testBasics", "tests/test_cli.py::TestEndpointDescriptions::testFileDescriptorBinding", "tests/test_cli.py::TestEndpointDescriptions::testMultipleEnpoints", "tests/test_cli.py::TestEndpointDescriptions::testTcpPortBinding... | jyangballin/swesmith.x86_64.django_1776_daphne.32ac73e1 | true | null | 1 | 71 | 9 | 1,207 | 0 | 0.6 | 1 | 0.75 | 1 | 0.437833 | 81.5885 | |||
4,201 | swe_smith::train::34359 | swe_smith | train | 34,359 | iterative__dvc.1d6ea681.pr_10032 | swesmith/iterative__dvc.1d6ea681 | iterative/dvc | python | null | **Issue Text**
Empty directories and missing files not handled correctly in DVCFileSystem.ls()
**Description**
I've found an issue with the `DVCFileSystem.ls()` method where it doesn't handle certain edge cases correctly:
1. When trying to list a missing file/directory, it doesn't raise a FileNotFoundError as expec... | diff --git a/dvc/fs/dvc.py b/dvc/fs/dvc.py
index f1370de..c1d5ca7 100644
--- a/dvc/fs/dvc.py
+++ b/dvc/fs/dvc.py
@@ -381,9 +381,12 @@ class _DVCFileSystem(AbstractFileSystem):
else:
for info in dvc_fs.ls(dvc_path, detail=True):
dvc_infos[dvc_fs.name(info["n... | ["tests/unit/fs/test_dvc.py::test_ls_dirty", "tests/unit/fs/test_dvc.py::test_ls_file_not_found", "tests/unit/fs/test_dvc.py::test_ls_dir_empty"] | ["tests/unit/fs/test_dvc.py::test_exists", "tests/unit/fs/test_dvc.py::test_open", "tests/unit/fs/test_dvc.py::test_open_dirty_hash", "tests/unit/fs/test_dvc.py::test_open_dirty_no_hash", "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_... | jyangballin/swesmith.x86_64.iterative_1776_dvc.1d6ea681 | true | null | 1 | 20 | 3 | 2,226 | 0 | 0.6 | 1 | 0.75 | 1 | 0.437667 | 81.588 | |||
4,202 | swe_smith::train::10631 | swe_smith | train | 10,631 | paramiko__paramiko.23f92003.func_basic__vi9j15oc | swesmith/paramiko__paramiko.23f92003 | paramiko/paramiko | python | null | SSH connection failures after key exchange negotiation
#### Description
SSH connections are failing during the key exchange phase with various errors including incompatible peer messages and connection drops. The issue appears to be related to how client and server algorithm lists are being processed during KEX negot... | diff --git a/paramiko/transport.py b/paramiko/transport.py
index f0fcb97..262d32c 100644
--- a/paramiko/transport.py
+++ b/paramiko/transport.py
@@ -2499,23 +2499,21 @@ class Transport(threading.Thread, ClosingContextManager):
def _parse_kex_init(self, m):
parsed = self._really_parse_kex_init(m)
... | ["tests/auth.py::AuthHandler_::bad_auth_type", "tests/auth.py::AuthHandler_::bad_password", "tests/auth.py::AuthHandler_::multipart_auth", "tests/auth.py::AuthHandler_::interactive_auth", "tests/auth.py::AuthHandler_::interactive_fallback", "tests/auth.py::AuthHandler_::utf8", "tests/auth.py::AuthHandler_::non_utf8", "... | ["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 | 128 | 1,286 | 0 | 0.6 | 1 | 0.75 | 1 | 0.437667 | 81.588 | |||
4,203 | swe_smith::train::21074 | swe_smith | train | 21,074 | tobymao__sqlglot.036601ba.lm_rewrite__0uzpst6e | swesmith/tobymao__sqlglot.036601ba | tobymao/sqlglot | python | null | ### Issue: ALTER TABLE SET Syntax Not Recognized
Hello,
I've encountered an issue with the SQL parser when trying to use the `ALTER TABLE SET` syntax. It seems that certain variations of this command are not being recognized correctly, leading to parsing errors.
#### Steps to Reproduce:
1. Use the following SQL com... | diff --git a/sqlglot/parser.py b/sqlglot/parser.py
index 248a128..83b329a 100644
--- a/sqlglot/parser.py
+++ b/sqlglot/parser.py
@@ -7202,40 +7202,44 @@ class Parser(metaclass=_Parser):
return self.expression(exp.AlterRename, this=self._parse_table(schema=True))
def _parse_alter_table_set(self) -> exp.A... | ["tests/dialects/test_hive.py::TestHive::test_ddl", "tests/dialects/test_postgres.py::TestPostgres::test_ddl", "tests/dialects/test_redshift.py::TestRedshift::test_alter_table", "tests/dialects/test_snowflake.py::TestSnowflake::test_alter_set_unset", "tests/dialects/test_spark.py::TestSpark::test_ddl", "tests/dialects/... | ["tests/dialects/test_athena.py::TestAthena::test_athena", "tests/dialects/test_athena.py::TestAthena::test_ctas", "tests/dialects/test_athena.py::TestAthena::test_ddl", "tests/dialects/test_athena.py::TestAthena::test_ddl_quoting", "tests/dialects/test_athena.py::TestAthena::test_dml", "tests/dialects/test_athena.py::... | jyangballin/swesmith.x86_64.tobymao_1776_sqlglot.036601ba | true | null | 1 | 72 | 8 | 1,186 | 0 | 0.6 | 1 | 0.75 | 1 | 0.437667 | 81.588 | |||
4,204 | swe_smith::train::5610 | swe_smith | train | 5,610 | PyCQA__flake8.cf1542ce.lm_rewrite__ck1l26wg | swesmith/PyCQA__flake8.cf1542ce | pycqa/flake8 | python | null | ### Unexpected Behavior with `handle_error` Method in StyleGuide
I've encountered an issue with the `handle_error` method in the `StyleGuide` class. It seems that the method is not handling errors as expected, particularly when dealing with multiline f-strings and plugin configurations.
### Description
When running ... | diff --git a/src/flake8/style_guide.py b/src/flake8/style_guide.py
index a409484..59a9f7c 100644
--- a/src/flake8/style_guide.py
+++ b/src/flake8/style_guide.py
@@ -378,15 +378,8 @@ class StyleGuide:
"""
return self.decider.decision_for(code)
- def handle_error(
- self,
- code: str,... | ["tests/integration/test_main.py::test_form_feed_line_split", "tests/integration/test_main.py::test_statistics_option", "tests/integration/test_main.py::test_show_source_option", "tests/integration/test_main.py::test_errors_sorted", "tests/integration/test_main.py::test_extend_exclude", "tests/integration/test_main.py:... | ["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 | 1 | 41 | 22 | 1,805 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4375 | 81.5875 | |||
4,205 | swe_bench::test::1647 | swe_bench | test | 1,647 | scikit-learn__scikit-learn-14704 | scikit-learn/scikit-learn | scikit-learn/scikit-learn | python | 68044b061d7abc0c16f632890939438033306161 | StratifiedKFold makes fold-sizes very unequal
I found this when trying to write tests for #14560.
Right now, ``StratifiedKFold`` might have the fold sizes unequal by ``n_classes``:
```python
import numpy as np
from sklearn.model_selection import StratifiedKFold
y = np.array([1, 1, 5, 3, 4, 4, 3, 1, 4, 2, 4, 2, 4, 3, ... | I think there have been several issues about this.
I think we should go back to a sort-then-round-robin approach.
this behaviour is actually well-documented, see https://scikit-learn.org/dev/modules/generated/sklearn.model_selection.StratifiedKFold.html:
Train and test sizes may be different in each fold, with a dif... | diff --git a/sklearn/model_selection/_split.py b/sklearn/model_selection/_split.py
--- a/sklearn/model_selection/_split.py
+++ b/sklearn/model_selection/_split.py
@@ -601,8 +601,20 @@ class StratifiedKFold(_BaseKFold):
Notes
-----
- Train and test sizes may be different in each fold, with a difference of... | diff --git a/sklearn/model_selection/tests/test_search.py b/sklearn/model_selection/tests/test_search.py
--- a/sklearn/model_selection/tests/test_search.py
+++ b/sklearn/model_selection/tests/test_search.py
@@ -210,7 +210,7 @@ def check_hyperparameter_searcher_with_fit_params(klass, **klass_kwargs):
... | ["sklearn/model_selection/tests/test_split.py::test_stratified_kfold_no_shuffle", "sklearn/model_selection/tests/test_split.py::test_stratified_kfold_ratios[4-False]", "sklearn/model_selection/tests/test_split.py::test_stratified_kfold_ratios[4-True]", "sklearn/model_selection/tests/test_split.py::test_stratified_kfold... | ["sklearn/model_selection/tests/test_search.py::test_validate_parameter_input[0-TypeError-Parameter", "sklearn/model_selection/tests/test_search.py::test_validate_parameter_input[input1-TypeError-Parameter", "sklearn/model_selection/tests/test_search.py::test_validate_parameter_input[input2-TypeError-Parameter.*", "skl... | null | true | 2019-08-21T08:52:44Z | 1 | 81 | 14 | 804 | 0 | 0.8 | 1 | 0.55 | 1 | 0.404 | 81.587 | |
4,206 | swe_smith::train::38004 | swe_smith | train | 38,004 | un33k__python-slugify.872b3750.combine_file__u8635nxq | swesmith/un33k__python-slugify.872b3750 | un33k/python-slugify | python | null | # Command line arguments for slugify are not working correctly
I encountered several issues with the command line arguments for the slugify tool. The behavior seems to be completely broken after some recent changes.
## Description
I was trying to use the slugify command line tool to process some text, but I noticed ... | diff --git a/slugify/__main__.py b/slugify/__main__.py
index 4cc4616..93c916a 100644
--- a/slugify/__main__.py
+++ b/slugify/__main__.py
@@ -16,21 +16,21 @@ def parse_args(argv: list[str]) -> argparse.Namespace:
input_group.add_argument("--stdin", action='store_true',
help="Take the t... | ["test_multivalued_options_with_text (__main__.TestCommandParams)", "test_two_text_sources_fails (__main__.TestCommandParams)", "test_valued_arguments (__main__.TestCommandParams)"] | ["test_accented_text (__main__.TestSlugify)", "test_accented_text_with_non_word_characters (__main__.TestSlugify)", "test_contains_numbers (__main__.TestSlugify)", "test_custom_separator (__main__.TestSlugify)", "test_cyrillic_text (__main__.TestSlugify)", "test_differently_cased_stopword_match (__main__.TestSlugify)",... | jyangballin/swesmith.x86_64.un33k_1776_python-slugify.872b3750 | true | null | 1 | 34 | 3 | 1,943 | 0 | 0.6 | 1 | 0.75 | 1 | 0.437167 | 81.5865 | |||
4,207 | swe_smith::train::52340 | swe_smith | train | 52,340 | pydicom__pydicom.7d361b3d.func_pm_class_rm_funcs__2ja8146d | swesmith/pydicom__pydicom.7d361b3d | pydicom/pydicom | python | null | RecordNode methods missing after refactoring
#### Description
After some recent changes, several key methods are missing from the `RecordNode` class, causing `TypeError: Can't instantiate abstract class` errors when trying to work with File-sets.
#### Steps/Code to Reproduce
```python
from pydicom.fileset import Fi... | diff --git a/src/pydicom/fileset.py b/src/pydicom/fileset.py
index 75976eb..4588c1d 100644
--- a/src/pydicom/fileset.py
+++ b/src/pydicom/fileset.py
@@ -211,29 +211,6 @@ class RecordNode(Iterable["RecordNode"]):
self._offset_next = 0
self._offset_lower = 0
- def add(self, leaf: "RecordNode") -> N... | ["tests/test_fileset.py::TestRecordNode::test_root", "tests/test_fileset.py::TestRecordNode::test_leaf", "tests/test_fileset.py::TestRecordNode::test_add", "tests/test_fileset.py::TestRecordNode::test_key", "tests/test_fileset.py::TestRecordNode::test_key_raises", "tests/test_fileset.py::TestRecordNode::test_bad_record... | ["tests/pixels/test_common.py::TestRunnerBase::test_init", "tests/pixels/test_common.py::TestRunnerBase::test_del_option", "tests/pixels/test_common.py::TestRunnerBase::test_option_properties", "tests/pixels/test_common.py::TestRunnerBase::test_planar_configuration", "tests/pixels/test_common.py::TestRunnerBase::test_s... | jyangballin/swesmith.x86_64.pydicom_1776_pydicom.7d361b3d | true | null | 1 | 76 | 119 | 1,103 | 0 | 0.6 | 1 | 0.75 | 1 | 0.437167 | 81.5865 | |||
4,208 | swe_smith::train::44533 | swe_smith | train | 44,533 | pydata__patsy.a5d16484.lm_rewrite__rywgq6nf | swesmith/pydata__patsy.a5d16484 | pydata/patsy | python | null | ### Issue: DesignMatrix Initialization Error
#### Description
When attempting to initialize a `DesignMatrix` with a `design_info` object that has a mismatched number of column names, the expected `ValueError` is not being raised. This behavior is inconsistent with the expected functionality where the number of column... | diff --git a/patsy/design_info.py b/patsy/design_info.py
index d94b97a..a4a09e4 100644
--- a/patsy/design_info.py
+++ b/patsy/design_info.py
@@ -1123,7 +1123,7 @@ class DesignMatrix(np.ndarray):
present only on "real" DesignMatrix objects.
"""
- def __new__(cls, input_array, design_info=None, default_... | ["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 | 57 | 1 | 1,482 | 0 | 0.6 | 1 | 0.75 | 1 | 0.437 | 81.586 | |||
4,209 | swe_smith::train::45096 | swe_smith | train | 45,096 | mahmoud__glom.fb3c4e76.lm_rewrite__y9d7mx1n | swesmith/mahmoud__glom.fb3c4e76 | mahmoud/glom | python | null | ### Issue: Fold Operation Fails on Iterable Targets
#### Description
It seems that the recent changes have introduced an issue with the `Fold` operation in the `glom` library. When attempting to perform fold operations on iterable targets, an error is raised, indicating that the operation cannot be completed. This be... | diff --git a/glom/reduction.py b/glom/reduction.py
index b400ce0..41db63f 100644
--- a/glom/reduction.py
+++ b/glom/reduction.py
@@ -66,22 +66,31 @@ class Fold:
(self.__class__.__name__, init))
def glomit(self, target, scope):
- is_agg = False
- if scope[MODE] is GROUP ... | ["glom/test/test_grouping.py::test_agg", "glom/test/test_grouping.py::test_reduce", "glom/test/test_reduction.py::test_sum_integers", "glom/test/test_reduction.py::test_sum_seqs", "glom/test/test_reduction.py::test_fold", "glom/test/test_reduction.py::test_flatten", "glom/test/test_reduction.py::test_flatten_func", "gl... | ["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 | 37 | 10 | 1,882 | 0 | 0.6 | 1 | 0.75 | 1 | 0.437 | 81.586 | |||
4,210 | swe_smith::train::1944 | swe_smith | train | 1,944 | agronholm__typeguard.b6a7e438.lm_rewrite__4igsgfuj | swesmith/agronholm__typeguard.b6a7e438 | agronholm/typeguard | python | null | # Type checking fails for generic aliases and protocol classes
When using `Type` or `type` annotations with generic aliases or protocol classes, the type checking fails unexpectedly.
## Reproduction
The issue occurs when trying to check if a class is a valid type according to a type annotation that involves protocol... | diff --git a/src/typeguard/_checkers.py b/src/typeguard/_checkers.py
index 5e34036..47e2e99 100644
--- a/src/typeguard/_checkers.py
+++ b/src/typeguard/_checkers.py
@@ -454,55 +454,25 @@ def check_uniontype(
raise TypeCheckError(f"did not match any element in the union:\n{formatted_errors}")
-def check_class(
... | ["tests/test_checkers.py::TestType::test_union_any", "tests/test_checkers.py::TestType::test_union_fail", "tests/test_checkers.py::TestType::test_generic_aliase[type]", "tests/test_checkers.py::TestType::test_generic_aliase[Type]", "tests/test_checkers.py::TestProtocol::test_success[typing-class]", "tests/test_checkers... | ["tests/mypy/test_type_annotations.py::test_positive", "tests/mypy/test_type_annotations.py::test_negative", "tests/test_checkers.py::TestAnyStr::test_valid[str]", "tests/test_checkers.py::TestAnyStr::test_valid[bytes]", "tests/test_checkers.py::TestAnyStr::test_bad_type", "tests/test_checkers.py::TestBytesLike::test_v... | jyangballin/swesmith.x86_64.agronholm_1776_typeguard.b6a7e438 | true | null | 1 | 62 | 13 | 1,380 | 0 | 0.6 | 1 | 0.75 | 1 | 0.436667 | 81.585 | |||
4,211 | swe_smith::train::45397 | swe_smith | train | 45,397 | dask__dask.5f61e423.lm_rewrite__7t2k5pb1 | swesmith/dask__dask.5f61e423 | dask/dask | python | null | # `eye()` function fails when `dtype=None` is specified
### Description
I've encountered an issue with the `eye()` function in dask.array. When trying to create an identity matrix with `dtype=None`, the function fails with a ValueError. This happens even though the NumPy equivalent works fine.
### Steps to Reproduce... | diff --git a/dask/array/creation.py b/dask/array/creation.py
index b906bc4..2eba159 100644
--- a/dask/array/creation.py
+++ b/dask/array/creation.py
@@ -558,7 +558,7 @@ def indices(dimensions, dtype=int, chunks="auto"):
return grid
-def eye(N, chunks="auto", M=None, k=0, dtype=float):
+def eye(N, chunks='auto'... | ["dask/array/tests/test_creation.py::test_eye"] | ["dask/array/tests/test_creation.py::test_arr_like[i4-C-None-shape0-chunks0-tuple-tuple-empty_like-numpy]", "dask/array/tests/test_creation.py::test_arr_like[i4-C-None-shape0-chunks0-tuple-tuple-empty-numpy]", "dask/array/tests/test_creation.py::test_arr_like[i4-C-None-shape0-chunks0-tuple-tuple-ones_like-numpy]", "das... | jyangballin/swesmith.x86_64.dask_1776_dask.5f61e423 | true | null | 1 | 63 | 1 | 1,360 | 0 | 0.6 | 1 | 0.75 | 1 | 0.436667 | 81.585 | |||
4,212 | swe_smith::train::26575 | swe_smith | train | 26,575 | pylint-dev__astroid.b114f6b5.lm_rewrite__gecgcl1e | swesmith/pylint-dev__astroid.b114f6b5 | pylint-dev/astroid | python | null | ### Issue: Unexpected Behavior with Keyword Argument Unpacking
#### Description
It seems there's an issue with how keyword arguments are being unpacked in the latest update. When using the `**` syntax to unpack dictionaries into function calls, the expected behavior is not being met, leading to unexpected results or ... | diff --git a/astroid/arguments.py b/astroid/arguments.py
index 3781889..4a73bae 100644
--- a/astroid/arguments.py
+++ b/astroid/arguments.py
@@ -85,41 +85,56 @@ class CallSite:
"""
return len(self.keyword_arguments) != len(self._unpacked_kwargs)
- def _unpack_keywords(
- self,
- key... | ["tests/brain/numpy/test_ma.py::TestBrainNumpyMa::test_numpy_ma_returns_maskedarray[masked_invalid-True]", "tests/brain/numpy/test_ma.py::TestBrainNumpyMa::test_numpy_ma_returns_maskedarray[masked_invalid-False]", "tests/brain/numpy/test_ma.py::TestBrainNumpyMa::test_numpy_ma_returns_maskedarray[masked_where-True]", "t... | ["tests/brain/numpy/test_core_einsumfunc.py::test_numpy_function_calls_inferred_as_ndarray", "tests/brain/numpy/test_core_einsumfunc.py::test_function_parameters", "tests/brain/numpy/test_core_fromnumeric.py::BrainNumpyCoreFromNumericTest::test_numpy_function_calls_inferred_as_ndarray", "tests/brain/numpy/test_core_fun... | jyangballin/swesmith.x86_64.pylint-dev_1776_astroid.b114f6b5 | true | null | 1 | 79 | 18 | 1,040 | 0 | 0.6 | 1 | 0.75 | 1 | 0.436667 | 81.585 | |||
4,213 | swe_smith::train::5096 | swe_smith | train | 5,096 | agronholm__exceptiongroup.0b4f4937.combine_module__b3u244k8 | swesmith/agronholm__exceptiongroup.0b4f4937 | agronholm/exceptiongroup | python | null | Exception handling broken after recent changes
#### Description
The exception catching and suppression mechanisms are not working correctly. When trying to catch specific exception types, the handlers are not being called properly and exceptions that should be suppressed are being raised instead.
#### Steps/Code to ... | diff --git a/src/exceptiongroup/_catch.py b/src/exceptiongroup/_catch.py
index 0246568..d9c256d 100644
--- a/src/exceptiongroup/_catch.py
+++ b/src/exceptiongroup/_catch.py
@@ -27,25 +27,23 @@ class _Catcher:
exc: BaseException | None,
tb: TracebackType | None,
) -> bool:
- if exc is not N... | ["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_catch_single_no_match", "tests/test_catch.py::test_catch_handler_raises", "tests/test_catch.py::test_bare_raise_in... | ["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 | 58 | 11 | 1,459 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4365 | 81.5845 | |||
4,214 | swe_smith::train::52744 | swe_smith | train | 52,744 | pydicom__pydicom.7d361b3d.lm_rewrite__wgqnk46k | swesmith/pydicom__pydicom.7d361b3d | pydicom/pydicom | python | null | # CLI command fails when accessing non-existent DICOM elements
## Description
The pydicom CLI command fails with an unexpected error when trying to access elements that don't exist in a DICOM dataset. The error handling in the `eval_element` function has been changed, causing it to raise an `AttributeError` instead o... | diff --git a/src/pydicom/cli/main.py b/src/pydicom/cli/main.py
index 2f616ba..56ef4e3 100644
--- a/src/pydicom/cli/main.py
+++ b/src/pydicom/cli/main.py
@@ -45,15 +45,38 @@ filespec_help = (
def eval_element(ds: Dataset, element: str) -> Any:
+ """Evaluate a data element expression on a dataset
+
+ Param... | ["tests/test_cli.py::TestFilespec::test_elem_not_exists[NotThere]", "tests/test_cli.py::TestFilespec::test_elem_not_exists[BeamSequenceXX]", "tests/test_cli.py::TestFilespec::test_elem_not_exists[BeamDose]", "tests/test_cli.py::TestFilespec::test_bad_index[BeamSequence[42]]", "tests/test_cli.py::TestFilespec::test_bad_... | ["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 | 39 | 5 | 1,839 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4365 | 81.5845 | |||
4,215 | swe_smith::train::24390 | swe_smith | train | 24,390 | sunpy__sunpy.f8edfd5c.lm_rewrite__4dkuon7u | swesmith/sunpy__sunpy.f8edfd5c | sunpy/sunpy | python | null | ### Unexpected Behavior in Coordinate Frame Initialization
#### Description
When initializing certain coordinate frames, unexpected behavior occurs, leading to errors and assertion failures. This issue seems to be related to the handling of observer and obstime attributes in the frames.
#### Steps to Reproduce
1. *... | diff --git a/sunpy/coordinates/frames.py b/sunpy/coordinates/frames.py
index 8e1efd5..20a920f 100644
--- a/sunpy/coordinates/frames.py
+++ b/sunpy/coordinates/frames.py
@@ -137,24 +137,14 @@ class SunPyBaseCoordinateFrame(BaseCoordinateFrame):
_wrap_angle = 180*u.deg # for longitude in spherical coordinates
... | ["sunpy/coordinates/tests/test_frames.py::test_wrapping_off", "sunpy/coordinates/tests/test_frames.py::test_hpc_default_observer", "sunpy/coordinates/tests/test_frames.py::test_hpc_obstime_from_observer", "sunpy/coordinates/tests/test_frames.py::test_hpc_is_visible_2d", "sunpy/coordinates/tests/test_frames.py::test_hpc... | ["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 | 24 | 19 | 2,138 | 0 | 0.6 | 1 | 0.75 | 1 | 0.436333 | 81.584 | |||
4,216 | swe_smith::train::8233 | swe_smith | train | 8,233 | cantools__cantools.0c6a7871.lm_rewrite__68i7a30o | swesmith/cantools__cantools.0c6a7871 | cantools/cantools | python | null | ### Issue: Invalid Literal for Integer Conversion in CDD Format
#### Description
It seems there's an issue with the CDD format handling in the `cantools` library. When attempting to load certain CDD files, an error is raised due to an invalid literal for integer conversion. This appears to occur when the code tries t... | diff --git a/src/cantools/database/diagnostics/formats/cdd.py b/src/cantools/database/diagnostics/formats/cdd.py
index b25f9d5..28d82ef 100644
--- a/src/cantools/database/diagnostics/formats/cdd.py
+++ b/src/cantools/database/diagnostics/formats/cdd.py
@@ -170,37 +170,38 @@ def _load_did_element(did, data_types, did_da... | ["tests/test_diagnostics_database.py::CanToolsDiagnosticsDatabaseTest::test_be_cdd_add", "tests/test_diagnostics_database.py::CanToolsDiagnosticsDatabaseTest::test_be_example_cdd", "tests/test_diagnostics_database.py::CanToolsDiagnosticsDatabaseTest::test_be_example_cdd_repr", "tests/test_diagnostics_database.py::CanTo... | ["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 | 61 | 7 | 1,397 | 0 | 0.6 | 1 | 0.75 | 1 | 0.436167 | 81.5835 | |||
4,217 | swe_smith::train::3260 | swe_smith | train | 3,260 | Suor__funcy.207a7810.lm_rewrite__s4m5gfwj | swesmith/Suor__funcy.207a7810 | suor/funcy | python | null | # TypeError when accessing function arguments in arggetter
## Description
The `arggetter` function in `funcy/decorators.py` is not properly handling function arguments. When trying to access arguments in decorated functions, it fails to handle default values, keyword arguments, and variable arguments correctly.
## S... | diff --git a/funcy/decorators.py b/funcy/decorators.py
index e001629..0a6f25c 100644
--- a/funcy/decorators.py
+++ b/funcy/decorators.py
@@ -106,59 +106,27 @@ def get_argnames(func):
return func.__code__.co_varnames[:func.__code__.co_argcount]
def arggetter(func, _cache={}):
+ """TODO: Implement this functio... | ["tests/test_decorators.py::test_decorator_access_args", "tests/test_decorators.py::test_double_decorator_defaults", "tests/test_flow.py::test_once_per_args"] | ["tests/test_calc.py::test_memoize", "tests/test_calc.py::test_memoize_args_kwargs", "tests/test_calc.py::test_memoize_skip", "tests/test_calc.py::test_memoize_memory", "tests/test_calc.py::test_memoize_key_func", "tests/test_calc.py::test_make_lookuper", "tests/test_calc.py::test_make_lookuper_nested", "tests/test_cal... | jyangballin/swesmith.x86_64.suor_1776_funcy.207a7810 | true | null | 1 | 68 | 3 | 1,256 | 0 | 0.6 | 1 | 0.75 | 1 | 0.436 | 81.583 | |||
4,218 | swe_smith::train::39577 | swe_smith | train | 39,577 | pallets__jinja.ada0a9a6.lm_rewrite__6w3bpnqc | swesmith/pallets__jinja.ada0a9a6 | pallets/jinja | python | null | ### Delimiter Collision Causes ValueError in Environment Configuration
#### Description
When configuring the `Environment` with certain delimiters, a `ValueError` is raised due to delimiter collisions. This issue arises when the start and end strings for blocks, variables, or comments are not distinct, leading to conf... | diff --git a/src/jinja2/environment.py b/src/jinja2/environment.py
index 0b303d5..3aa8726 100644
--- a/src/jinja2/environment.py
+++ b/src/jinja2/environment.py
@@ -125,24 +125,51 @@ def load_extensions(
return result
-def _environment_config_check(environment: "Environment") -> "Environment":
+def _environmen... | ["tests/test_lexnparse.py::TestParser::test_php_syntax", "tests/test_lexnparse.py::TestParser::test_erb_syntax", "tests/test_lexnparse.py::TestParser::test_comment_syntax", "tests/test_lexnparse.py::TestParser::test_line_syntax", "tests/test_lexnparse.py::TestLstripBlocks::test_lstrip_angle_bracket_simple", "tests/test... | ["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 | 17 | 1,476 | 0 | 0.6 | 1 | 0.75 | 1 | 0.436 | 81.583 | |||
4,219 | swe_smith::train::38247 | swe_smith | train | 38,247 | john-kurkowski__tldextract.3d1bf184.lm_rewrite__tjsvw5lt | swesmith/john-kurkowski__tldextract.3d1bf184 | john-kurkowski/tldextract | python | null | ### AttributeError: 'NoneType' object has no attribute
It seems like there's an issue with the `TLDExtract` class after the recent changes. When trying to extract components from URLs, the extraction process is failing with an `AttributeError`. This is affecting various scenarios, including handling of subdomains, IPv... | diff --git a/tldextract/tldextract.py b/tldextract/tldextract.py
index 667c36a..e77befd 100644
--- a/tldextract/tldextract.py
+++ b/tldextract/tldextract.py
@@ -142,15 +142,11 @@ class TLDExtract:
"""A callable for extracting, subdomain, domain, and suffix components from a URL."""
# TODO: too-many-argument... | ["tests/custom_suffix_test.py::test_suffix_which_is_not_in_custom_list", "tests/custom_suffix_test.py::test_custom_suffixes", "tests/custom_suffix_test.py::test_suffix_which_is_not_in_extra_list", "tests/custom_suffix_test.py::test_extra_suffixes", "tests/main_test.py::test_american", "tests/main_test.py::test_british"... | ["tests/cli_test.py::test_cli_no_input", "tests/cli_test.py::test_cli_parses_args", "tests/cli_test.py::test_cli_posargs", "tests/cli_test.py::test_cli_namedargs", "tests/cli_test.py::test_cli_json_output", "tests/custom_suffix_test.py::test_private_extraction", "tests/main_test.py::test_lenient_netloc", "tests/main_te... | jyangballin/swesmith.x86_64.john-kurkowski_1776_tldextract.3d1bf184 | true | null | 1 | 39 | 29 | 1,835 | 0 | 0.6 | 1 | 0.75 | 1 | 0.435833 | 81.5825 | |||
4,220 | swe_smith::train::28045 | swe_smith | train | 28,045 | jsvine__pdfplumber.02ff4313.lm_rewrite__gvhtvtdc | swesmith/jsvine__pdfplumber.02ff4313 | jsvine/pdfplumber | python | null | ## Issue
Unexpected behavior when serializing to JSON with `to_json` method in `Container` class.
## Description
After the recent changes, the `to_json` method in the `Container` class is not functioning as expected. When attempting to serialize certain objects, it raises errors related to object types and JSON decodi... | diff --git a/pdfplumber/container.py b/pdfplumber/container.py
index 2589a4a..8f78e9b 100644
--- a/pdfplumber/container.py
+++ b/pdfplumber/container.py
@@ -105,30 +105,66 @@ class Container(object):
return list(filter(test, self.edges))
- def to_json(
- self,
- stream: Optional[TextIO] = ... | ["tests/test_convert.py::Test::test_additional_attr_types", "tests/test_convert.py::Test::test_cli_json", "tests/test_convert.py::Test::test_json", "tests/test_convert.py::Test::test_json_all_types", "tests/test_convert.py::Test::test_json_attr_filter", "tests/test_convert.py::Test::test_single_pages", "tests/test_oss_... | ["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 | 78 | 7 | 1,054 | 0 | 0.6 | 1 | 0.75 | 1 | 0.435667 | 81.582 | |||
4,221 | swe_smith::train::24474 | swe_smith | train | 24,474 | sunpy__sunpy.f8edfd5c.combine_module__5xleifsf | swesmith/sunpy__sunpy.f8edfd5c | sunpy/sunpy | python | null | # Broken decorator and unique function behavior
## Description
I've encountered two issues in the codebase:
1. The `deprecate_positional_args_since` decorator is broken and raises an `UnboundLocalError` when used. This affects any function that uses this decorator.
2. The `unique` function in `util.py` is not retur... | diff --git a/sunpy/util/decorators.py b/sunpy/util/decorators.py
index d989247..441e803 100644
--- a/sunpy/util/decorators.py
+++ b/sunpy/util/decorators.py
@@ -166,6 +166,8 @@ def deprecated_renamed_argument(
def deprecate_positional_args_since(func=None, *, since):
+
+ return _inner_deprecate_positional_args
... | ["sunpy/util/tests/test_decorators.py::test_deprecate_positional_args_warns_for_function_version", "sunpy/util/tests/test_decorators.py::test_deprecate_positional_args_warns_quantity_input", "sunpy/util/tests/test_decorators.py::test_deprecate_positional_args_warns_for_class", "sunpy/util/tests/test_util.py::test_uniqu... | ["sunpy/util/tests/test_decorators.py::test_somefunc_context", "sunpy/util/tests/test_util.py::test_replacement_filename", "sunpy/util/tests/test_util.py::test_replacement_filename_path_not_exists", "sunpy/util/tests/test_util.py::test_expand_list", "sunpy/util/tests/test_util.py::test_expand_list_generator[input_data0... | jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c | true | null | 2 | 33 | 5 | 1,954 | 0 | 0.6 | 1 | 0.75 | 1 | 0.435667 | 81.582 | |||
4,222 | swe_smith::train::6513 | swe_smith | train | 6,513 | mahmoud__boltons.3bfcfdd0.lm_rewrite__1u2ttc6k | swesmith/mahmoud__boltons.3bfcfdd0 | mahmoud/boltons | python | null | # rotate_file function fails when file doesn't exist
## Description
I found an issue with the `rotate_file` function in `fileutils.py`. The function fails when the file doesn't exist, but according to the docstring it should just return without doing anything.
## Steps to reproduce
Here's a simple example that demo... | diff --git a/boltons/fileutils.py b/boltons/fileutils.py
index 18c6656..b40d339 100644
--- a/boltons/fileutils.py
+++ b/boltons/fileutils.py
@@ -688,7 +688,7 @@ class DummyFile:
return
-def rotate_file(filename, *, keep: int = 5):
+def rotate_file(filename, *, keep: int=5):
"""
If *filename.ext* ... | ["tests/test_fileutils.py::test_rotate_file_no_rotation", "tests/test_fileutils.py::test_rotate_file_full_rotation", "tests/test_fileutils.py::test_rotate_file_full_rotation_no_ext"] | ["tests/test_cacheutils.py::test_lru_add", "tests/test_cacheutils.py::test_lri", "tests/test_cacheutils.py::test_lri_cache_eviction", "tests/test_cacheutils.py::test_cache_sizes_on_repeat_insertions", "tests/test_cacheutils.py::test_lru_basic", "tests/test_cacheutils.py::test_lru_dict_replacement[LRU]", "tests/test_cac... | jyangballin/swesmith.x86_64.mahmoud_1776_boltons.3bfcfdd0 | true | null | 1 | 50 | 3 | 1,613 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4355 | 81.5815 | |||
4,223 | swe_smith::train::35912 | swe_smith | train | 35,912 | stanfordnlp__dspy.651a4c71.lm_rewrite__ko0qris9 | swesmith/stanfordnlp__dspy.651a4c71 | stanfordnlp/dspy | python | null | # Parallel module fails to process different example types
## Description
I've discovered an issue with the `Parallel` class in the `dspy.predict.parallel` module. After a recent update, it seems the module no longer correctly handles different types of examples.
## Reproduction
Here's a minimal example that demons... | diff --git a/dspy/predict/parallel.py b/dspy/predict/parallel.py
index 03a4235..4f603e3 100644
--- a/dspy/predict/parallel.py
+++ b/dspy/predict/parallel.py
@@ -41,26 +41,38 @@ class Parallel:
)
def process_pair(pair):
- result = None
- module, example = pair
-
- if ... | ["tests/predict/test_parallel.py::test_parallel_module", "tests/predict/test_parallel.py::test_batch_module", "tests/predict/test_parallel.py::test_nested_parallel_module", "tests/predict/test_parallel.py::test_nested_batch_method", "tests/signatures/test_adapter_image.py::test_pdf_url_support", "tests/signatures/test_... | ["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 | 48 | 8 | 1,652 | 0 | 0.6 | 1 | 0.75 | 1 | 0.435333 | 81.581 | |||
4,224 | swe_smith::train::32981 | swe_smith | train | 32,981 | pydantic__pydantic.acb0f10f.pr_7806 | swesmith/pydantic__pydantic.acb0f10f | pydantic/pydantic | python | null | # Missing `on_exception` callback in BaseValidateHandlerProtocol
I've noticed that when using custom validation handlers with Pydantic plugins, the `on_exception` callback is not being properly handled.
## Current behavior
When implementing a custom validation handler that needs to track state during validation, the... | diff --git a/pydantic/plugin/__init__.py b/pydantic/plugin/__init__.py
index 3620305..1b88eaf 100644
--- a/pydantic/plugin/__init__.py
+++ b/pydantic/plugin/__init__.py
@@ -96,14 +96,6 @@ class BaseValidateHandlerProtocol(Protocol):
"""
return
- def on_exception(self, exception: Exception) -> Non... | ["tests/test_plugins.py::test_stateful_plugin"] | ["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 | 2 | 17 | 1 | 2,270 | 0 | 0.6 | 1 | 0.75 | 1 | 0.435 | 81.58 | |||
4,225 | swe_smith::train::52431 | swe_smith | train | 52,431 | pydicom__pydicom.7d361b3d.func_pm_ctrl_shuffle__s1g0qdjr | swesmith/pydicom__pydicom.7d361b3d | pydicom/pydicom | python | null | pixel_array function returns early with undefined variables
#### Description
The `pixel_array` function in `src/pydicom/pixels/utils.py` has a code structure issue where it returns early before some variables are properly defined, causing `UnboundLocalError` when trying to access undefined variables.
#### Steps/Code... | diff --git a/src/pydicom/pixels/utils.py b/src/pydicom/pixels/utils.py
index f9a31a8..f9e45f2 100644
--- a/src/pydicom/pixels/utils.py
+++ b/src/pydicom/pixels/utils.py
@@ -1476,8 +1476,40 @@ def pixel_array(
native transfer syntaxes with ``view_only=True`` a read-only
:class:`~numpy.ndarray` will be ... | ["tests/test_dataset.py::TestDataset::test_attribute_error_in_property", "tests/test_dataset.py::TestDataset::test_pixel_array_id_changed", "tests/test_dataset.py::TestDataset::test_pixel_array_unknown_syntax"] | ["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 | 3 | 1,110 | 0 | 0.6 | 1 | 0.75 | 1 | 0.435 | 81.58 | |||
4,226 | swe_smith::train::24495 | swe_smith | train | 24,495 | sunpy__sunpy.f8edfd5c.combine_module__ey1ajaqf | swesmith/sunpy__sunpy.f8edfd5c | sunpy/sunpy | python | null | TimeRange constructor fails when only start time provided
#### Description
When creating a TimeRange with only a start time (no end time or duration), the constructor now raises a ValueError instead of the expected behavior. This breaks existing code that relied on single-argument TimeRange initialization.
#### Step... | diff --git a/sunpy/time/time.py b/sunpy/time/time.py
index 0d760c5..2997d1b 100644
--- a/sunpy/time/time.py
+++ b/sunpy/time/time.py
@@ -121,19 +121,9 @@ def _regex_parse_time(inp, format):
# Special handling to add a day if the hour is 24 and the minute/second/microsecond are all zero
add_one_day = False
-... | ["sunpy/time/tests/test_time.py::test_parse_time_24", "sunpy/time/tests/test_time.py::test_parse_time_24_2", "sunpy/time/tests/test_timerange.py::test_timerange_inputs[inputs3]", "sunpy/time/tests/test_timerange.py::test_timerange_invalid_range", "sunpy/time/tests/test_timerange.py::test_timerange_input[ainput3]", "sun... | ["sunpy/time/tests/test_time.py::test_parse_time_microseconds_excess_trailing_zeros", "sunpy/time/tests/test_time.py::test_parse_time_tuple", "sunpy/time/tests/test_time.py::test_parse_time_int", "sunpy/time/tests/test_time.py::test_parse_time_pandas_timestamp", "sunpy/time/tests/test_time.py::test_parse_time_nanosecon... | jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c | true | null | 2 | 76 | 7 | 1,088 | 0 | 0.6 | 1 | 0.75 | 1 | 0.434667 | 81.579 | |||
4,227 | swe_smith::train::43776 | swe_smith | train | 43,776 | pydata__patsy.a5d16484.combine_file__bbyopwvq | swesmith/pydata__patsy.a5d16484 | pydata/patsy | python | null | Issues with demo_data and LookupFactor in patsy
### Describe the bug
I've found some issues with the `demo_data` function and `LookupFactor` class in patsy. The behavior seems to have changed from what was expected.
### Steps/Code to Reproduce
For the `demo_data` function:
```python
from patsy import demo_data
imp... | diff --git a/patsy/user_util.py b/patsy/user_util.py
index 080af84..1debc59 100644
--- a/patsy/user_util.py
+++ b/patsy/user_util.py
@@ -150,23 +150,23 @@ def demo_data(*names, **kwargs):
def test_demo_data():
d1 = demo_data("a", "b", "x")
assert sorted(d1.keys()) == ["a", "b", "x"]
- assert d1["a"] == ["... | ["patsy/user_util.py::test_demo_data", "patsy/user_util.py::test_LookupFactor"] | ["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 | 14 | 2 | 2,324 | 0 | 0.6 | 1 | 0.75 | 1 | 0.434 | 81.577 | |||
4,228 | swe_smith::train::1050 | swe_smith | train | 1,050 | jd__tenacity.0d40e76f.combine_file__ktykmrgz | swesmith/jd__tenacity.0d40e76f | jd/tenacity | python | null | # AsyncRetrying class has swapped before/after callbacks and incorrect defaults
I noticed that the `AsyncRetrying` class in the asyncio module has some issues with its initialization parameters.
## Issues
1. The `before` and `after` parameters are swapped in the constructor. The `before` parameter is being assigned ... | diff --git a/tenacity/asyncio/__init__.py b/tenacity/asyncio/__init__.py
index a926091..24f159e 100644
--- a/tenacity/asyncio/__init__.py
+++ b/tenacity/asyncio/__init__.py
@@ -75,14 +75,14 @@ class AsyncRetrying(BaseRetrying):
retry: "t.Union[SyncRetryBaseT, RetryBaseT]" = tenacity.retry_if_exception_type(),
... | ["tests/test_asyncio.py::TestAsyncio::test_stop_after_attempt", "tests/test_asyncio.py::TestContextManager::test_async_retying_iterator", "tests/test_asyncio.py::TestContextManager::test_do_max_attempts", "tests/test_asyncio.py::TestContextManager::test_sleeps", "tests/test_asyncio.py::TestDecoratorWrapper::test_retry_... | ["tests/test_after.py::TestAfterLogFormat::test_01_default", "tests/test_after.py::TestAfterLogFormat::test_02_custom_sec_format", "tests/test_asyncio.py::TestAsyncio::test_attempt_number_is_correct_for_interleaved_coroutines", "tests/test_asyncio.py::TestAsyncio::test_iscoroutinefunction", "tests/test_asyncio.py::Test... | jyangballin/swesmith.x86_64.jd_1776_tenacity.0d40e76f | true | null | 1 | 8 | 5 | 2,443 | 0 | 0.6 | 1 | 0.75 | 1 | 0.433833 | 81.5765 | |||
4,229 | swe_smith::train::39597 | swe_smith | train | 39,597 | pallets__jinja.ada0a9a6.lm_rewrite__h38zcr0y | swesmith/pallets__jinja.ada0a9a6 | pallets/jinja | python | null | Traceback Generation Fails with Runtime and Syntax Errors
Description
It seems that the recent changes have introduced an issue with generating tracebacks for runtime and syntax errors. When attempting to simulate a traceback from a template, the expected traceback is not being produced correctly. This results in an ... | diff --git a/src/jinja2/debug.py b/src/jinja2/debug.py
index f85a319..a7056d1 100644
--- a/src/jinja2/debug.py
+++ b/src/jinja2/debug.py
@@ -73,9 +73,8 @@ def rewrite_traceback_stack(source: t.Optional[str] = None) -> BaseException:
return exc_value.with_traceback(tb_next)
-def fake_traceback( # type: ignore
... | ["tests/test_debug.py::TestDebug::test_runtime_error", "tests/test_debug.py::TestDebug::test_syntax_error"] | ["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 | 71 | 2 | 1,183 | 0 | 0.6 | 1 | 0.75 | 1 | 0.433833 | 81.5765 | |||
4,230 | swe_smith::train::6856 | swe_smith | train | 6,856 | joke2k__faker.8b401a7d.lm_rewrite__fp5bdtz8 | swesmith/joke2k__faker.8b401a7d | joke2k/faker | python | null | # SWIFT code generation fails with ValueError instead of AssertionError
## Description
I noticed that the SWIFT code generation is now raising a different exception type when an invalid length is provided. This breaks backward compatibility with existing code that might be catching the specific exception type.
## St... | diff --git a/faker/providers/bank/__init__.py b/faker/providers/bank/__init__.py
index 7a0f4d2..6ae4e26 100644
--- a/faker/providers/bank/__init__.py
+++ b/faker/providers/bank/__init__.py
@@ -89,12 +89,8 @@ class Provider(BaseProvider):
"""
return self.swift(length=11, primary=primary, use_dataset=us... | ["tests/providers/test_bank.py::TestEnPh::test_swift_invalid_length", "tests/providers/test_bank.py::TestFilPh::test_swift_invalid_length", "tests/providers/test_bank.py::TestTlPh::test_swift_invalid_length"] | ["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 | 71 | 3 | 1,182 | 0 | 0.6 | 1 | 0.75 | 1 | 0.433667 | 81.576 | |||
4,231 | swe_smith::train::33268 | swe_smith | train | 33,268 | django-money__django-money.835c1ab8.lm_rewrite__35iodhzx | swesmith/django-money__django-money.835c1ab8 | django-money/django-money | python | null | # Money validation fails with F expressions
## Description
I've found an issue with the validation of F expressions in MoneyField. When using certain F expressions, the validation fails even though it should pass.
## What I expected
I expected to be able to use valid F expressions with MoneyField without getting va... | diff --git a/djmoney/models/fields.py b/djmoney/models/fields.py
index dc5f6ad..dead31b 100644
--- a/djmoney/models/fields.py
+++ b/djmoney/models/fields.py
@@ -47,18 +47,41 @@ def validate_money_expression(obj, expr):
- Any operations with money in different currencies
- Multiplication, division, modulo ... | ["tests/test_models.py::TestFExpressions::test_invalid_expressions_access[f_obj3]"] | ["tests/contrib/exchange/test_admin.py::test_last_update", "tests/contrib/exchange/test_backends.py::TestBackends::test_get_rates[setup0]", "tests/contrib/exchange/test_backends.py::TestBackends::test_get_rates[setup1]", "tests/contrib/exchange/test_backends.py::TestBackends::test_initial_update_rates[setup0]", "tests/... | jyangballin/swesmith.x86_64.django-money_1776_django-money.835c1ab8 | true | null | 1 | 43 | 1 | 1,741 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4335 | 81.5755 | |||
4,232 | swe_smith::train::49115 | swe_smith | train | 49,115 | mozilla__bleach.73871d76.combine_file__f2u57kjw | swesmith/mozilla__bleach.73871d76 | mozilla/bleach | python | null | HTMLSerializer constructor fails with unexpected keyword argument error
#### Description
The HTMLSerializer class in bleach's vendored html5lib is throwing a TypeError when initialized with any keyword arguments. The error message indicates that the constructor requires at least one keyword argument, but then fails w... | diff --git a/bleach/_vendor/html5lib/serializer.py b/bleach/_vendor/html5lib/serializer.py
index 5666f49..9df3b23 100644
--- a/bleach/_vendor/html5lib/serializer.py
+++ b/bleach/_vendor/html5lib/serializer.py
@@ -212,21 +212,21 @@ class HTMLSerializer(object):
"""
unexpected_args = frozenset(kwargs)... | ["tests/test_clean.py::test_clean_idempotent[text<em>]", "tests/test_clean.py::test_clean_idempotent_img", "tests/test_clean.py::test_only_text_is_cleaned", "tests/test_clean.py::test_empty", "tests/test_clean.py::test_content_has_no_html", "tests/test_clean.py::test_html_is_lowercased", "tests/test_clean.py::test_comm... | ["tests/test_callbacks.py::TestNofollowCallback::test_blank", "tests/test_callbacks.py::TestNofollowCallback::test_no_href", "tests/test_callbacks.py::TestNofollowCallback::test_basic", "tests/test_callbacks.py::TestNofollowCallback::test_mailto", "tests/test_callbacks.py::TestNofollowCallback::test_has_nofollow_alread... | jyangballin/swesmith.x86_64.mozilla_1776_bleach.73871d76 | true | null | 1 | 86 | 185 | 879 | 0 | 0.6 | 1 | 0.75 | 1 | 0.433167 | 81.5745 | |||
4,233 | swe_smith::train::23908 | swe_smith | train | 23,908 | sunpy__sunpy.f8edfd5c.func_pm_ctrl_shuffle__0f82a5u6 | swesmith/sunpy__sunpy.f8edfd5c | sunpy/sunpy | python | null | GreatArc object missing start attribute after initialization
#### Description
When creating a GreatArc object, the `start` attribute is not accessible, causing AttributeError when trying to access it.
#### Steps/Code to Reproduce
```python
from sunpy.coordinates.utils import GreatArc
from sunpy.coordinates import f... | diff --git a/sunpy/coordinates/utils.py b/sunpy/coordinates/utils.py
index 6f868af..1e77056 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_width_height", "sunpy/coordinates/tests/... | jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c | true | null | 1 | 63 | 16 | 1,339 | 0 | 0.6 | 1 | 0.75 | 1 | 0.433167 | 81.5745 | |||
4,234 | swe_smith::train::35522 | swe_smith | train | 35,522 | stanfordnlp__dspy.651a4c71.func_pm_ctrl_shuffle__8y795vsh | swesmith/stanfordnlp__dspy.651a4c71 | stanfordnlp/dspy | python | null | # BootstrapFewShot initialization order causes UnboundLocalError
## Description
I've found an issue with the `BootstrapFewShot` class in the teleprompt module. The initialization order of variables in the `_prepare_predictor_mappings` method is incorrect, causing variables to be used before they're defined.
## MCVE ... | diff --git a/dspy/teleprompt/bootstrap.py b/dspy/teleprompt/bootstrap.py
index 81ab80a..daebb11 100644
--- a/dspy/teleprompt/bootstrap.py
+++ b/dspy/teleprompt/bootstrap.py
@@ -104,12 +104,6 @@ class BootstrapFewShot(Teleprompter):
self.teacher = teleprompter.compile(self.teacher.reset_copy(), trainset=sel... | ["tests/primitives/test_module.py::test_save_and_load_with_pkl", "tests/signatures/test_adapter_image.py::test_pdf_url_support", "tests/signatures/test_adapter_image.py::test_different_mime_types", "tests/signatures/test_adapter_image.py::test_mime_type_from_response_headers", "tests/signatures/test_adapter_image.py::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 | 13 | 11 | 2,338 | 0 | 0.6 | 1 | 0.75 | 1 | 0.433 | 81.574 | |||
4,235 | swe_smith::train::32736 | swe_smith | train | 32,736 | pydantic__pydantic.acb0f10f.func_pm_remove_loop__tmaphq87 | swesmith/pydantic__pydantic.acb0f10f | pydantic/pydantic | python | null | Non-annotated attributes not properly validated during model construction
#### Description
When defining a Pydantic model with non-annotated attributes, the validation logic that should catch and raise appropriate errors is not working. This allows models to be created with invalid field definitions that should norma... | diff --git a/pydantic/_internal/_model_construction.py b/pydantic/_internal/_model_construction.py
index 88f67ef..c4d0d86 100644
--- a/pydantic/_internal/_model_construction.py
+++ b/pydantic/_internal/_model_construction.py
@@ -402,66 +402,6 @@ def inspect_namespace( # noqa C901
raise TypeError("To define ro... | ["tests/test_computed_fields.py::test_properties_and_computed_fields", "tests/test_config.py::TestsBaseConfig::test_base_config_private_attribute_intersection_with_extra_field", "tests/test_construction.py::test_pickle_undefined", "tests/test_construction.py::test_copy_undefined[copy]", "tests/test_construction.py::tes... | ["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 | 61 | 43 | 1,375 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4325 | 81.5725 | |||
4,236 | swe_smith::train::50936 | swe_smith | train | 50,936 | python-hyper__h11.bed0dd4a.lm_rewrite__5pdhq39x | swesmith/python-hyper__h11.bed0dd4a | python-hyper/h11 | python | null | ### Bug report
**Issue Summary**
It seems there's a problem with handling chunked data and protocol switching in the latest update. When attempting to process chunked data or switch protocols, unexpected errors are raised, which disrupts the normal flow of data handling.
**Steps to Reproduce**
1. Set up a connectio... | diff --git a/h11/_receivebuffer.py b/h11/_receivebuffer.py
index e5c4e08..cbcc4bb 100644
--- a/h11/_receivebuffer.py
+++ b/h11/_receivebuffer.py
@@ -84,23 +84,28 @@ class ReceiveBuffer:
return self._extract(count)
- def maybe_extract_next_line(self) -> Optional[bytearray]:
+ def maybe_extract_next_li... | ["h11/tests/test_connection.py::test_chunked", "h11/tests/test_connection.py::test_chunk_boundaries", "h11/tests/test_connection.py::test_reuse_simple", "h11/tests/test_connection.py::test_protocol_switch", "h11/tests/test_connection.py::test_close_different_states", "h11/tests/test_connection.py::test_special_exceptio... | ["h11/tests/test_against_stdlib_http.py::test_h11_as_client", "h11/tests/test_against_stdlib_http.py::test_h11_as_server", "h11/tests/test_connection.py::test__keep_alive", "h11/tests/test_connection.py::test__body_framing", "h11/tests/test_connection.py::test_Connection_basics_and_content_length", "h11/tests/test_conn... | jyangballin/swesmith.x86_64.python-hyper_1776_h11.bed0dd4a | true | null | 1 | 29 | 8 | 2,015 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4325 | 81.5725 | |||
4,237 | swe_smith::train::45387 | swe_smith | train | 45,387 | dask__dask.5f61e423.lm_rewrite__4nchlpxa | swesmith/dask__dask.5f61e423 | dask/dask | python | null | ### Bug report
#### Problem Description
It seems there's an issue with reading JSON files in chunks when using the `read_json` function. When attempting to read multiple JSON files with a path column or when reading chunked JSON files, a `ValueError` is raised. The error message indicates "Trailing data" or "If using... | diff --git a/dask/dataframe/io/json.py b/dask/dataframe/io/json.py
index ab83a35..edca937 100644
--- a/dask/dataframe/io/json.py
+++ b/dask/dataframe/io/json.py
@@ -291,21 +291,49 @@ def read_json(
return dd.from_delayed(parts, meta=meta)
-def read_json_chunk(
- chunk, encoding, errors, engine, column_name,... | ["dask/dataframe/io/tests/test_json.py::test_read_json_multiple_files_with_path_column[5]", "dask/dataframe/io/tests/test_json.py::test_read_json_multiple_files_with_path_column[15]", "dask/dataframe/io/tests/test_json.py::test_read_json_multiple_files_with_path_column[33]", "dask/dataframe/io/tests/test_json.py::test_... | ["dask/dataframe/io/tests/test_json.py::test_read_json_with_path_column[split]", "dask/dataframe/io/tests/test_json.py::test_read_json_with_path_column[records]", "dask/dataframe/io/tests/test_json.py::test_read_json_with_path_column[index]", "dask/dataframe/io/tests/test_json.py::test_read_json_with_path_column[column... | jyangballin/swesmith.x86_64.dask_1776_dask.5f61e423 | true | null | 1 | 48 | 11 | 1,634 | 0 | 0.6 | 1 | 0.75 | 1 | 0.432333 | 81.572 | |||
4,238 | swe_smith::train::39559 | swe_smith | train | 39,559 | pallets__jinja.ada0a9a6.lm_rewrite__0gdszhy7 | swesmith/pallets__jinja.ada0a9a6 | pallets/jinja | python | null | ### Bug: AttributeError when exporting variables in async imports
#### Description
Encountered an issue when trying to export variables using async imports. The error seems to occur when attempting to manage context variables within async blocks. This is causing an `AttributeError` to be raised, which disrupts the ex... | diff --git a/src/jinja2/compiler.py b/src/jinja2/compiler.py
index 91720c5..13d6ab5 100644
--- a/src/jinja2/compiler.py
+++ b/src/jinja2/compiler.py
@@ -781,49 +781,37 @@ class CodeGenerator(NodeVisitor):
"""Pushes a new layer for assignment tracking."""
self._assign_stack.append(set())
- def pop... | ["tests/test_async.py::TestAsyncImports::test_exports[asyncio]", "tests/test_async.py::TestAsyncImports::test_exports[trio]", "tests/test_core_tags.py::TestForLoop::test_intended_scoping_with_set", "tests/test_core_tags.py::TestSet::test_normal", "tests/test_core_tags.py::TestSet::test_block", "tests/test_core_tags.py:... | ["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 | 64 | 9 | 1,314 | 0 | 0.6 | 1 | 0.75 | 1 | 0.432333 | 81.572 | |||
4,239 | swe_smith::train::31810 | swe_smith | train | 31,810 | davidhalter__parso.338a5760.combine_file__uclx71ar | swesmith/davidhalter__parso.338a5760 | davidhalter/parso | python | null | # [Bug]: Parso cache system is broken and causing parsing failures
## Description
I've encountered a serious issue with the parso cache system that's causing parsing failures in my project. After updating to the latest version, I'm seeing strange behavior where previously working code now fails to parse correctly.
#... | diff --git a/parso/cache.py b/parso/cache.py
index 5592a9f..94f3868 100644
--- a/parso/cache.py
+++ b/parso/cache.py
@@ -102,12 +102,12 @@ parser_cache: Dict[str, Any] = {}
class _NodeCacheItem:
def __init__(self, node, lines, change_time=None):
- self.node = node
- self.lines = lines
+ sel... | ["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_used_update[False-False]", "test/test_cache.py::test_cache_last_used_update[False-True]", "test/test_cache.py::test_... | ["parso/__init__.py::parso", "parso/python/tree.py::parso.python.tree", "parso/tree.py::parso.tree.NodeOrLeaf.dump", "test/test_diff_parser.py::test_change_and_undo", "test/test_diff_parser.py::test_positions", "test/test_diff_parser.py::test_if_simple", "test/test_diff_parser.py::test_func_with_for_and_comment", "test... | jyangballin/swesmith.x86_64.davidhalter_1776_parso.338a5760 | true | null | 1 | 33 | 10 | 1,933 | 0 | 0.6 | 1 | 0.75 | 1 | 0.432167 | 81.5715 | |||
4,240 | swe_smith::train::24533 | swe_smith | train | 24,533 | sunpy__sunpy.f8edfd5c.combine_module__qzae2swl | swesmith/sunpy__sunpy.f8edfd5c | sunpy/sunpy | python | null | Factory registration broken due to variable scope issue
#### Description
The factory registration system is throwing `UnboundLocalError` when trying to create widgets. The error occurs when accessing local variables that haven't been properly initialized in their scope.
#### Steps/Code to Reproduce
```python
from s... | diff --git a/sunpy/util/datatype_factory_base.py b/sunpy/util/datatype_factory_base.py
index 6c132c0..983af65 100644
--- a/sunpy/util/datatype_factory_base.py
+++ b/sunpy/util/datatype_factory_base.py
@@ -67,10 +67,6 @@ class BasicRegistrationFactory:
return self._check_registered_widget(*args, **kwargs)
... | ["sunpy/util/tests/test_datatype_factory_base.py::test_default_factory", "sunpy/util/tests/test_datatype_factory_base.py::test_no_default_factory", "sunpy/util/tests/test_datatype_factory_base.py::test_with_external_registry", "sunpy/util/tests/test_datatype_factory_base.py::test_multiple_match_factory", "sunpy/util/te... | ["sunpy/util/tests/test_datatype_factory_base.py::test_validation_fun_not_callable", "sunpy/util/tests/test_sysinfo.py::test_find_dependencies", "sunpy/util/tests/test_sysinfo.py::test_missing_dependencies_by_extra", "sunpy/util/tests/test_sysinfo.py::test_resolve_requirement_versions", "sunpy/util/tests/test_sysinfo.p... | jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c | true | null | 2 | 63 | 6 | 1,332 | 0 | 0.6 | 1 | 0.75 | 1 | 0.432 | 81.571 | |||
4,241 | swe_smith::train::6900 | swe_smith | train | 6,900 | joke2k__faker.8b401a7d.lm_rewrite__xamia66u | swesmith/joke2k__faker.8b401a7d | joke2k/faker | python | null | # pystr method breaks after refactoring
**Describe the bug**
After refactoring the `pystr` method in the Python provider, several issues have appeared:
1. The method now raises a `ValueError` instead of an `AssertionError` when minimum string length exceeds maximum
2. The length of strings with prefix/suffix is incor... | diff --git a/faker/providers/python/__init__.py b/faker/providers/python/__init__.py
index 28b4356..0afc36d 100644
--- a/faker/providers/python/__init__.py
+++ b/faker/providers/python/__init__.py
@@ -104,13 +104,8 @@ class Provider(BaseProvider):
return self.random_int(1, 100) <= truth_probability
- de... | ["tests/providers/test_python.py::TestPystr::test_invalid_length_limits", "tests/providers/test_python.py::TestPystr::test_prefix", "tests/providers/test_python.py::TestPystr::test_suffix", "tests/test_factory.py::FactoryTestCase::test_random_pystr_characters", "tests/test_optional.py::TestOptionalClass::test_optional"... | ["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 | 33 | 5 | 1,931 | 0 | 0.6 | 1 | 0.75 | 1 | 0.431833 | 81.5705 | |||
4,242 | swe_smith::train::31444 | swe_smith | train | 31,444 | benoitc__gunicorn.bacbf8aa.combine_module__nw0njw3b | swesmith/benoitc__gunicorn.bacbf8aa | benoitc/gunicorn | python | null | Configuration initialization broken after recent changes
#### Description
After some recent changes, gunicorn applications are failing to initialize properly. The configuration object is not being created correctly, leading to `AttributeError: 'NoneType' object has no attribute` errors when trying to access configura... | diff --git a/gunicorn/app/base.py b/gunicorn/app/base.py
index 9bf7a4f..d62821a 100644
--- a/gunicorn/app/base.py
+++ b/gunicorn/app/base.py
@@ -19,10 +19,10 @@ class BaseApplication:
the various necessities for any given web framework.
"""
def __init__(self, usage=None, prog=None):
- self.usage =... | ["tests/test_arbiter.py::test_arbiter_stop_closes_listeners", "tests/test_arbiter.py::test_arbiter_stop_child_does_not_unlink_listeners", "tests/test_arbiter.py::test_arbiter_stop_parent_does_not_unlink_listeners", "tests/test_arbiter.py::test_arbiter_stop_does_not_unlink_systemd_listeners", "tests/test_arbiter.py::tes... | ["tests/test_config.py::test_worker_class", "tests/test_config.py::test_defaults", "tests/test_config.py::test_property_access", "tests/test_config.py::test_bool_validation", "tests/test_config.py::test_pos_int_validation", "tests/test_config.py::test_str_validation", "tests/test_config.py::test_str_to_addr_list_valida... | jyangballin/swesmith.x86_64.benoitc_1776_gunicorn.bacbf8aa | true | null | 2 | 71 | 43 | 1,170 | 0 | 0.6 | 1 | 0.75 | 1 | 0.431667 | 81.57 | |||
4,243 | swe_smith::train::24957 | swe_smith | train | 24,957 | pylint-dev__astroid.b114f6b5.combine_file__174au1yz | swesmith/pylint-dev__astroid.b114f6b5 | pylint-dev/astroid | python | null | NamedTuple field order reversed and rename behavior changed
#### Description
When creating namedtuples, the field order is getting reversed and the default rename behavior has changed. This affects both the field definitions and the expected behavior when duplicate or invalid field names are provided.
#### Steps/Cod... | diff --git a/astroid/brain/brain_namedtuple_enum.py b/astroid/brain/brain_namedtuple_enum.py
index 67d706d..bda7885 100644
--- a/astroid/brain/brain_namedtuple_enum.py
+++ b/astroid/brain/brain_namedtuple_enum.py
@@ -193,9 +193,8 @@ def infer_named_tuple(
node: nodes.Call, context: InferenceContext | None = None
... | ["tests/brain/test_brain.py::BrainUUIDTest::test_uuid_has_int_member", "tests/brain/test_enum.py::EnumBrainTest::test_enum_name_is_str_on_self", "tests/brain/test_enum.py::EnumBrainTest::test_enum_subclass_different_modules", "tests/brain/test_enum.py::EnumBrainTest::test_enum_subclass_member_value", "tests/brain/test_... | ["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 | 61 | 11 | 1,369 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4315 | 81.5695 | |||
4,244 | r2e_gym::train::5191 | r2e_gym | train | 5,191 | pyramid__6f065c08410cc892e93f276ec711d82b92ba6020 | pyramid | pylons/pyramid | python | 6f065c08410cc892e93f276ec711d82b92ba6020 | **Analysis:**
- **Key Parts of Commit Details and Test Results:**
- The commit modifies `get_app` and `get_appsettings` functions in `pyramid/paster.py` to accept an `options` parameter and pass it as `global_conf`.
- Two tests were previously failing:
1. `Test_get_app.test_it_with_dummyapp_requiring_options` ... | diff --git a/docs/api/paster.rst b/docs/api/paster.rst
--- a/docs/api/paster.rst
+++ b/docs/api/paster.rst
@@ -9,6 +9,6 @@
.. autofunction:: get_app(config_uri, name=None, options=None)
- .. autofunction:: get_appsettings(config_uri, name=None)
+ .. autofunction:: get_appsettings(config_uri, name=None, o... | diff --git a/pyramid/tests/fixtures/dummy.ini b/pyramid/tests/fixtures/dummy.ini
--- a/pyramid/tests/fixtures/dummy.ini
+++ b/pyramid/tests/fixtures/dummy.ini
@@ -0,0 +1,4 @@
+[app:myapp]
+use = call:pyramid.tests.test_paster:make_dummyapp
+
+foo = %(bar)s
diff --git a/pyramid/tests/test_paster.py b/pyramid/tests/test_... | null | null | namanjain12/pyramid_final:6f065c08410cc892e93f276ec711d82b92ba6020 | true | null | 3 | 33 | null | 2,640 | 0 | 0.75 | 1 | 0.6375 | 1 | 0.55 | 81.56875 | ||
4,245 | swe_smith::train::38314 | swe_smith | train | 38,314 | burnash__gspread.a8be3b96.func_pm_ctrl_shuffle__vl1lkl0z | swesmith/burnash__gspread.a8be3b96 | burnash/gspread | python | null | Worksheet.range() method broken after recent changes
#### Description
The `range()` method in the Worksheet class is throwing `UnboundLocalError` when trying to access cell ranges. This appears to be affecting multiple worksheet operations that depend on the range functionality.
#### Steps/Code to Reproduce
```pyth... | diff --git a/gspread/worksheet.py b/gspread/worksheet.py
index 883e3a2..a0b0952 100644
--- a/gspread/worksheet.py
+++ b/gspread/worksheet.py
@@ -371,6 +371,41 @@ class Worksheet:
@cast_to_a1_notation
def range(self, name: str = "") -> List[Cell]:
+
+ if ":" not in name:
+ name = data.get("... | ["tests/worksheet_test.py::WorksheetTest::test_clear", "tests/worksheet_test.py::WorksheetTest::test_copy_cut_range", "tests/worksheet_test.py::WorksheetTest::test_delete_cols", "tests/worksheet_test.py::WorksheetTest::test_findall", "tests/worksheet_test.py::WorksheetTest::test_get_all_records_numericise_unformatted",... | ["tests/cell_test.py::CellTest::test_a1_value", "tests/cell_test.py::CellTest::test_define_named_range", "tests/cell_test.py::CellTest::test_delete_named_range", "tests/cell_test.py::CellTest::test_equality", "tests/cell_test.py::CellTest::test_merge_cells", "tests/cell_test.py::CellTest::test_numeric_value", "tests/ce... | jyangballin/swesmith.x86_64.burnash_1776_gspread.a8be3b96 | true | null | 1 | 71 | 19 | 1,166 | 0 | 0.6 | 1 | 0.75 | 1 | 0.431 | 81.568 | |||
4,246 | swe_smith::train::36528 | swe_smith | train | 36,528 | lincolnloop__python-qrcode.456b01d4.combine_module__hb36urkx | swesmith/lincolnloop__python-qrcode.456b01d4 | lincolnloop/python-qrcode | python | null | # Multiple issues with QR code generation in SVG and styled PIL images
## Description
I've found several issues with QR code generation when using SVG image factory and styled PIL images with color masks. The code is completely broken in the latest version.
## Steps to Reproduce
### SVG Issues:
```python
import qr... | diff --git a/qrcode/image/styles/colormasks.py b/qrcode/image/styles/colormasks.py
index 43186b2..58a919d 100644
--- a/qrcode/image/styles/colormasks.py
+++ b/qrcode/image/styles/colormasks.py
@@ -25,7 +25,7 @@ class QRColorMask:
paint_color = back_color
def initialize(self, styledPilImage, image):
- ... | ["qrcode/tests/test_qrcode_pil.py::test_render_styled_Image", "qrcode/tests/test_qrcode_pil.py::test_render_styled_with_embeded_image", "qrcode/tests/test_qrcode_pil.py::test_render_styled_with_embeded_image_path", "qrcode/tests/test_qrcode_pil.py::test_render_styled_with_drawer[CircleModuleDrawer]", "qrcode/tests/test... | ["qrcode/tests/test_example.py::test_example", "qrcode/tests/test_qrcode.py::test_basic", "qrcode/tests/test_qrcode.py::test_large", "qrcode/tests/test_qrcode.py::test_invalid_version", "qrcode/tests/test_qrcode.py::test_invalid_border", "qrcode/tests/test_qrcode.py::test_overflow", "qrcode/tests/test_qrcode.py::test_a... | jyangballin/swesmith.x86_64.lincolnloop_1776_python-qrcode.456b01d4 | true | null | 2 | 34 | 25 | 1,904 | 0 | 0.6 | 1 | 0.75 | 1 | 0.430667 | 81.567 | |||
4,247 | swe_smith::train::30528 | swe_smith | train | 30,528 | gweis__isodate.17cb25eb.combine_module__hidommmj | swesmith/gweis__isodate.17cb25eb | gweis/isodate | python | null | Duration constructor swaps years and months parameters
#### Description
When creating a Duration object, the years and months parameters are being swapped internally. This causes incorrect behavior when performing date arithmetic and duration calculations.
#### Steps/Code to Reproduce
```python
from isodate import ... | diff --git a/src/isodate/duration.py b/src/isodate/duration.py
index 85241e4..2e78a1e 100644
--- a/src/isodate/duration.py
+++ b/src/isodate/duration.py
@@ -74,9 +74,9 @@ class Duration:
months = Decimal(str(months))
if not isinstance(years, Decimal):
years = Decimal(str(years))
- ... | ["tests/test_datetime.py::test_parse[19850412T1015-expected0-%Y%m%dT%H%M-19850412T1015]", "tests/test_datetime.py::test_parse[1985-04-12T10:15-expected1-%Y-%m-%dT%H:%M-1985-04-12T10:15]", "tests/test_datetime.py::test_parse[1985102T1015Z-expected2-%Y%jT%H%M%z-1985102T1015Z]", "tests/test_datetime.py::test_parse[1985-10... | ["tests/test_date.py::test_parse[4-19-expected0-%C]", "tests/test_date.py::test_parse[4-1985-expected1-%Y]", "tests/test_date.py::test_parse[4-1985-04-expected2-%Y-%m]", "tests/test_date.py::test_parse[4-198504-expected3-%Y%m]", "tests/test_date.py::test_parse[4-1985-04-12-expected4-%Y-%m-%d]", "tests/test_date.py::tes... | jyangballin/swesmith.x86_64.gweis_1776_isodate.17cb25eb | true | null | 2 | 79 | 141 | 1,002 | 0 | 0.6 | 1 | 0.75 | 1 | 0.430333 | 81.566 | |||
4,248 | swe_smith::train::24083 | swe_smith | train | 24,083 | sunpy__sunpy.f8edfd5c.func_pm_ctrl_shuffle__tp0i6xh1 | swesmith/sunpy__sunpy.f8edfd5c | sunpy/sunpy | python | null | GreatArc initialization fails with AttributeError: '_r' not defined
#### Description
When creating a GreatArc object, the initialization fails with an AttributeError because the `_r` attribute is being used before it's defined.
#### Steps/Code to Reproduce
```python
from sunpy.coordinates.utils import GreatArc
from... | diff --git a/sunpy/coordinates/utils.py b/sunpy/coordinates/utils.py
index 6f868af..07b133b 100644
--- a/sunpy/coordinates/utils.py
+++ b/sunpy/coordinates/utils.py
@@ -83,36 +83,34 @@ class GreatArc:
"""
def __init__(self, start, end, center=None, points=None):
-
- # Observer
- self.observer ... | ["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_width_height", "sunpy/coordinates/tests/... | jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c | true | null | 1 | 67 | 16 | 1,241 | 0 | 0.6 | 1 | 0.75 | 1 | 0.430167 | 81.5655 | |||
4,249 | swe_smith::train::24587 | swe_smith | train | 24,587 | marshmallow-code__marshmallow.9716fc62.combine_module__a0zj7oz1 | swesmith/marshmallow-code__marshmallow.9716fc62 | marshmallow-code/marshmallow | python | null | OneOf validator incorrectly rejects valid values
#### Description
The OneOf validator is rejecting values that should be valid. When a value is in the choices list, it raises a ValidationError instead of accepting it.
#### Steps/Code to Reproduce
```python
from marshmallow import validate
# This should pass but ra... | diff --git a/src/marshmallow/class_registry.py b/src/marshmallow/class_registry.py
index d41b112..076327d 100644
--- a/src/marshmallow/class_registry.py
+++ b/src/marshmallow/class_registry.py
@@ -27,45 +27,20 @@ _registry = {} # type: dict[str, list[SchemaType]]
def register(classname: str, cls: SchemaType) -> N... | ["tests/test_deserialization.py::TestSchemaDeserialization::test_deserialization_raises_with_errors", "tests/test_deserialization.py::TestSchemaDeserialization::test_deserialization_raises_with_errors_with_multiple_validators", "tests/test_registry.py::test_serializer_class_registry_register_same_classname_different_mo... | ["tests/test_decorators.py::test_decorated_processors[True]", "tests/test_decorators.py::test_decorated_processors[False]", "tests/test_decorators.py::test_decorated_processor_returning_none[exclude]", "tests/test_decorators.py::test_decorated_processor_returning_none[include]", "tests/test_decorators.py::test_decorate... | jyangballin/swesmith.x86_64.marshmallow-code_1776_marshmallow.9716fc62 | true | null | 2 | 55 | 19 | 1,480 | 0 | 0.6 | 1 | 0.75 | 1 | 0.43 | 81.565 | |||
4,250 | swe_smith::train::2585 | swe_smith | train | 2,585 | pdfminer__pdfminer.six.1a8bd2f7.lm_rewrite__295g9vu1 | swesmith/pdfminer__pdfminer.six.1a8bd2f7 | pdfminer/pdfminer.six | python | null | # PDFXRefStream.get_pos fails to correctly parse object references in PDF files
### Bug report
When trying to open certain PDF files with encryption (specifically AES-256 with revision 6), I'm getting errors. The issue appears to be in the `PDFXRefStream.get_pos` method which doesn't correctly parse object references... | diff --git a/pdfminer/pdfdocument.py b/pdfminer/pdfdocument.py
index 1c06335..8c7b68e 100644
--- a/pdfminer/pdfdocument.py
+++ b/pdfminer/pdfdocument.py
@@ -300,31 +300,32 @@ class PDFXRefStream(PDFBaseXRef):
yield start + i
def get_pos(self, objid: int) -> Tuple[Optional[int], int, int]:
- ... | ["tests/test_tools_pdf2txt.py::TestPdf2Txt::test_encryption_aes256_r6_user", "tests/test_tools_pdf2txt.py::TestPdf2Txt::test_encryption_aes256_r6_owner"] | ["tests/test_converter.py::TestPaintPath::test_paint_path", "tests/test_converter.py::TestPaintPath::test_paint_path_mlllh", "tests/test_converter.py::TestPaintPath::test_paint_path_multiple_mlllh", "tests/test_converter.py::TestPaintPath::test_paint_path_quadrilaterals", "tests/test_converter.py::TestPaintPath::test_p... | jyangballin/swesmith.x86_64.pdfminer_1776_pdfminer.six.1a8bd2f7 | true | null | 1 | 49 | 2 | 1,598 | 0 | 0.6 | 1 | 0.75 | 1 | 0.429667 | 81.564 | |||
4,251 | swe_smith::train::43726 | swe_smith | train | 43,726 | sloria__environs.73c372df.lm_rewrite__7xuboo30 | swesmith/sloria__environs.73c372df | sloria/environs | python | null | # TimeDelta parsing fails with empty string values
## Description
I'm experiencing an issue with the `timedelta` parser in environs. When trying to parse a timedelta from an empty string or a string with only whitespace, it fails with an error instead of raising a proper validation error.
## Steps to Reproduce
```pyt... | diff --git a/src/environs/__init__.py b/src/environs/__init__.py
index 00f6072..2290c12 100644
--- a/src/environs/__init__.py
+++ b/src/environs/__init__.py
@@ -410,22 +410,55 @@ class _LogLevelField(ma.fields.Integer):
class _TimeDeltaField(ma.fields.TimeDelta):
def _deserialize(self, value, *args, **kwargs) -... | ["tests/test_environs.py::TestCasting::test_timedelta_cast"] | ["tests/test_environs.py::TestCasting::test_call", "tests/test_environs.py::TestCasting::test_call_with_default", "tests/test_environs.py::TestCasting::test_basic", "tests/test_environs.py::TestCasting::test_empty_str", "tests/test_environs.py::TestCasting::test_int_cast", "tests/test_environs.py::TestCasting::test_inv... | jyangballin/swesmith.x86_64.sloria_1776_environs.73c372df | true | null | 1 | 61 | 1 | 1,358 | 0 | 0.6 | 1 | 0.75 | 1 | 0.429667 | 81.564 | |||
4,252 | swe_smith::train::45092 | swe_smith | train | 45,092 | mahmoud__glom.fb3c4e76.lm_rewrite__xgjlj18w | swesmith/mahmoud__glom.fb3c4e76 | mahmoud/glom | python | null | # Iter() no longer raises TypeError for non-iterable objects
I've found an issue with the `Iter` class in the streaming module. It seems that the error handling for non-iterable objects has been broken.
## Steps to reproduce
Consider the following example where we try to iterate over a non-iterable object or an obje... | diff --git a/glom/streaming.py b/glom/streaming.py
index 4da5fb5..62fa044 100644
--- a/glom/streaming.py
+++ b/glom/streaming.py
@@ -91,27 +91,33 @@ class Iter:
return iter(iterator)
def _iterate(self, target, scope):
- iterate = scope[TargetRegistry].get_handler('iterate', target, path=scope[Pat... | ["glom/test/test_streaming.py::test_faulty_iterate"] | ["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 | 48 | 1 | 1,615 | 0 | 0.6 | 1 | 0.75 | 1 | 0.429167 | 81.5625 | |||
4,253 | swe_bench::test::28 | swe_bench | test | 28 | astropy__astropy-13465 | astropy/astropy | astropy/astropy | python | 0f3e4a6549bc8bb3276184a021ecdd3482eb5d13 | rtol for FITSDiff not working as expected.
I have question about the rtol parameter for FITSDiff, when I create a report it appears that the numbers cited as being different are within the given relative tolerance. I couldn't figure out why so I thought this may be a bug, apologies if I'm missing something super obvio... | Welcome to Astropy 👋 and thank you for your first issue!
A project member will respond to you as soon as possible; in the meantime, please double-check the [guidelines for submitting issues](https://github.com/astropy/astropy/blob/main/CONTRIBUTING.md#reporting-issues) and make sure you've provided the requested deta... | diff --git a/astropy/io/fits/diff.py b/astropy/io/fits/diff.py
--- a/astropy/io/fits/diff.py
+++ b/astropy/io/fits/diff.py
@@ -1051,7 +1051,8 @@ def _report(self):
index = [x + 1 for x in reversed(index)]
self._writeln(f' Data differs at {index}:')
report_diff_values(values[0], va... | diff --git a/astropy/io/fits/tests/test_diff.py b/astropy/io/fits/tests/test_diff.py
--- a/astropy/io/fits/tests/test_diff.py
+++ b/astropy/io/fits/tests/test_diff.py
@@ -893,3 +893,35 @@ def test_fitsdiff_with_names(tmpdir):
diff = FITSDiff(path1, path2)
assert "Extension HDU 1:" in diff.report()
+
+
+def ... | ["astropy/io/fits/tests/test_diff.py::test_rawdatadiff_diff_with_rtol"] | ["astropy/io/fits/tests/test_diff.py::test_fitsdiff_hdu_name", "astropy/io/fits/tests/test_diff.py::test_fitsdiff_no_hdu_name", "astropy/io/fits/tests/test_diff.py::test_fitsdiff_with_names"] | null | true | 2022-07-19T08:36:06Z | 2 | 30 | 1 | 1,774 | 0 | 0.8 | 1 | 0.55 | 1 | 0.395667 | 81.562 | |
4,254 | swe_smith::train::38521 | swe_smith | train | 38,521 | amueller__word_cloud.ec24191c.func_pm_remove_loop__j89z8w8r | swesmith/amueller__word_cloud.ec24191c | amueller/word_cloud | python | null | WordCloud generation fails with "Couldn't find space to draw" error
#### Description
When trying to generate a word cloud, the process fails with a ValueError stating "Couldn't find space to draw. Either the Canvas size is too small or too much of the image is masked out." This happens even with simple text and defau... | diff --git a/wordcloud/wordcloud.py b/wordcloud/wordcloud.py
index 1622c03..ab3e9a6 100644
--- a/wordcloud/wordcloud.py
+++ b/wordcloud/wordcloud.py
@@ -484,77 +484,9 @@ class WordCloud(object):
frequencies.extend([(word, freq * downweight ** (i + 1))
for word, freq... | ["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_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", "test/test_wordcloud.py::te... | jyangballin/swesmith.x86_64.amueller_1776_word_cloud.ec24191c | true | null | 1 | 68 | 22 | 1,210 | 0 | 0.6 | 1 | 0.75 | 1 | 0.428333 | 81.56 | |||
4,255 | swe_smith::train::51488 | swe_smith | train | 51,488 | pydicom__pydicom.7d361b3d.combine_file__bhy7lj0w | swesmith/pydicom__pydicom.7d361b3d | pydicom/pydicom | python | null | Hook registration validation occurs after assignment instead of before
#### Description
When registering hooks using `register_callback()`, the validation checks for callable functions and valid hook names happen after the hook has already been assigned to the instance attributes. This means that if you pass an inval... | diff --git a/src/pydicom/hooks.py b/src/pydicom/hooks.py
index 106b001..5e06d2f 100644
--- a/src/pydicom/hooks.py
+++ b/src/pydicom/hooks.py
@@ -57,6 +57,15 @@ class Hooks:
self.raw_element_kwargs: dict[str, Any] = {}
def register_callback(self, hook: str, func: Callable) -> None:
+
+ if hook == ... | ["tests/test_config.py::TestSettings::test_reading_validation_mode_with_enforce_valid_values", "tests/test_dataelem.py::TestDataElement::test_private_tag_in_repeater_range", "tests/test_dataelem.py::TestDataElement::test_private_repeater_tag", "tests/test_dataelem.py::TestDataElement::test_reading_ds_with_known_tags_wi... | ["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 | 81 | 15 | 948 | 0 | 0.6 | 1 | 0.75 | 1 | 0.428 | 81.559 | |||
4,256 | swe_smith::train::21124 | swe_smith | train | 21,124 | tobymao__sqlglot.036601ba.lm_rewrite__ggbbx9bl | swesmith/tobymao__sqlglot.036601ba | tobymao/sqlglot | python | null | # Topological sort function returns incorrect order
## Description
The `tsort` function in `sqlglot/helper.py` is not correctly sorting nodes in topological order. When given a directed acyclic graph (DAG), it should return a list of nodes such that for every directed edge (u, v), node u comes before node v in the or... | diff --git a/sqlglot/helper.py b/sqlglot/helper.py
index c45de0f..bf238e7 100644
--- a/sqlglot/helper.py
+++ b/sqlglot/helper.py
@@ -233,30 +233,45 @@ def tsort(dag: t.Dict[T, t.Set[T]]) -> t.List[T]:
Returns:
A list that contains all of the graph's nodes in topological order.
"""
+ # Create a cop... | ["tests/test_helper.py::TestHelper::test_tsort"] | ["tests/test_helper.py::TestHelper::test_merge_ranges", "tests/test_helper.py::TestHelper::test_name_sequence"] | jyangballin/swesmith.x86_64.tobymao_1776_sqlglot.036601ba | true | null | 1 | 57 | 1 | 1,428 | 0 | 0.6 | 1 | 0.75 | 1 | 0.428 | 81.559 | |||
4,257 | swe_smith::train::31836 | swe_smith | train | 31,836 | davidhalter__parso.338a5760.combine_module__htnardau | swesmith/davidhalter__parso.338a5760 | davidhalter/parso | python | null | DiffParser returns incorrect values causing AttributeError crashes
#### Description
The DiffParser is returning incorrect types and values from several methods, causing widespread AttributeError crashes when trying to access attributes on None or integer values that should be node objects.
#### Steps/Code to Reprodu... | diff --git a/parso/python/diff.py b/parso/python/diff.py
index ba999fa..77ec595 100644
--- a/parso/python/diff.py
+++ b/parso/python/diff.py
@@ -65,11 +65,11 @@ def _get_next_leaf_if_indentation(leaf):
def _get_suite_indentation(tree_node):
- return _get_indentation(tree_node.children[1])
+ return _get_inden... | ["test/test_cache.py::test_cache_last_used_update[False-True]", "test/test_diff_parser.py::test_simple", "test/test_diff_parser.py::test_change_and_undo", "test/test_diff_parser.py::test_positions", "test/test_diff_parser.py::test_if_simple", "test/test_diff_parser.py::test_func_with_for_and_comment", "test/test_diff_p... | ["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 | 2 | 58 | 111 | 1,407 | 0 | 0.6 | 1 | 0.75 | 1 | 0.427833 | 81.5585 | |||
4,258 | swe_smith::train::45551 | swe_smith | train | 45,551 | alanjds__drf-nested-routers.6144169d.func_basic__p4jhi3sw | swesmith/alanjds__drf-nested-routers.6144169d | alanjds/drf-nested-routers | python | null | NestedSimpleRouter URL generation broken after recent changes
#### Description
The nested router is generating malformed URLs and throwing ValueError exceptions when trying to create nested routes. The URL patterns are not being constructed correctly, causing routing failures.
#### Steps/Code to Reproduce
```python... | diff --git a/rest_framework_nested/routers.py b/rest_framework_nested/routers.py
index ae826e6..0aca774 100644
--- a/rest_framework_nested/routers.py
+++ b/rest_framework_nested/routers.py
@@ -57,61 +57,42 @@ class NestedMixin:
) -> None:
self.parent_router = parent_router
self.parent_prefix = pa... | ["tests/serializers/test_serializers.py::TestSerializers::test_custom", "tests/serializers/test_serializers.py::TestSerializers::test_default", "tests/serializers/test_serializers.py::TestSerializers::test_multi_level", "tests/serializers/test_serializers.py::TestSerializers::test_multi_level_parent_ref", "tests/serial... | ["tests/serializers/test_serializers.py::TestSerializers::test_no_children", "tests/test_dynamic_routers.py::TestNestedSimpleRouter::test_dynamic_routes", "tests/test_routers.py::TestBadLookupValue::test_bad_lookup", "tests/test_viewsets.py::TestNestedSimpleRouter::test_get_queryset_for_children_resource"] | jyangballin/swesmith.x86_64.alanjds_1776_drf-nested-routers.6144169d | true | null | 1 | 47 | 19 | 1,626 | 0 | 0.6 | 1 | 0.75 | 1 | 0.427667 | 81.558 | |||
4,259 | swe_smith::train::45425 | swe_smith | train | 45,425 | dask__dask.5f61e423.lm_rewrite__k3duzgn1 | swesmith/dask__dask.5f61e423 | dask/dask | python | null | ### Issue: AttributeError in `convert_legacy_graph` Function
Hello Dask team,
I've encountered an issue with the `convert_legacy_graph` function after updating to the latest version. It seems that the function is not handling certain task specifications correctly, leading to an `AttributeError`.
#### Description
Wh... | diff --git a/dask/_task_spec.py b/dask/_task_spec.py
index 45e6c46..2adf058 100644
--- a/dask/_task_spec.py
+++ b/dask/_task_spec.py
@@ -260,22 +260,29 @@ def convert_legacy_task(
return task
-def convert_legacy_graph(
- dsk: Mapping,
- all_keys: Container | None = None,
-):
+def convert_legacy_graph... | ["dask/tests/test_task_spec.py::test_convert_legacy_dsk", "dask/tests/test_task_spec.py::test_avoid_cycles"] | ["dask/tests/test_task_spec.py::test_convert_legacy_dsk_skip_new", "dask/tests/test_task_spec.py::test_repr", "dask/tests/test_task_spec.py::test_task_eq", "dask/tests/test_task_spec.py::test_task_executable", "dask/tests/test_task_spec.py::test_task_nested_sequence", "dask/tests/test_task_spec.py::test_reference_remot... | jyangballin/swesmith.x86_64.dask_1776_dask.5f61e423 | true | null | 1 | 35 | 2 | 1,866 | 0 | 0.6 | 1 | 0.75 | 1 | 0.427667 | 81.558 | |||
4,260 | swe_smith::train::46381 | swe_smith | train | 46,381 | conan-io__conan.86f29e13.pr_16137 | swesmith/conan-io__conan.86f29e13 | conan-io/conan | python | null | Graph command not reporting errors correctly
I encountered an issue with the `graph` command where it doesn't seem to handle errors as expected. When running the command to compute a dependency graph, it fails to report errors in a clear manner. Here's a simple way to reproduce the issue:
```python
from conans import... | diff --git a/conan/cli/commands/graph.py b/conan/cli/commands/graph.py
index e493b51..00c484e 100644
--- a/conan/cli/commands/graph.py
+++ b/conan/cli/commands/graph.py
@@ -12,11 +12,11 @@ from conan.cli.formatters.graph.build_order_html import format_build_order_html
from conan.cli.formatters.graph.graph_info_text im... | ["test/integration/command/info/test_graph_info_graphical.py::InfoTest::test_graph", "test/integration/command/info/test_graph_info_graphical.py::InfoTest::test_graph_html", "test/integration/command/info/test_graph_info_graphical.py::test_user_templates", "test/integration/command/info/test_graph_info_graphical.py::te... | [] | jyangballin/swesmith.x86_64.conan-io_1776_conan.86f29e13 | true | null | 2 | 67 | 25 | 1,225 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4275 | 81.5575 | |||
4,261 | swe_smith::train::18032 | swe_smith | train | 18,032 | pyasn1__pyasn1.0f07d724.lm_rewrite__8i3u8ypy | swesmith/pyasn1__pyasn1.0f07d724 | pyasn1/pyasn1 | python | null | Boolean Decoder Fails with Empty and Overflow Inputs
I've encountered an issue with the Boolean decoder in the CER module. When attempting to decode certain byte sequences, the decoder does not behave as expected.
Here's how to reproduce the issue:
1. **Empty Input**: When decoding an empty Boolean payload, the deco... | diff --git a/pyasn1/codec/cer/decoder.py b/pyasn1/codec/cer/decoder.py
index d6890f0..2c8d9ed 100644
--- a/pyasn1/codec/cer/decoder.py
+++ b/pyasn1/codec/cer/decoder.py
@@ -19,34 +19,33 @@ SubstrateUnderrunError = error.SubstrateUnderrunError
class BooleanPayloadDecoder(decoder.AbstractSimplePayloadDecoder):
prot... | ["tests/codec/cer/test_decoder.py::BooleanDecoderTestCase::testEmpty", "tests/codec/cer/test_decoder.py::BooleanDecoderTestCase::testFalse", "tests/codec/cer/test_decoder.py::BooleanDecoderTestCase::testOverflow", "tests/codec/cer/test_decoder.py::BooleanDecoderTestCase::testTrue"] | ["tests/codec/ber/test_decoder.py::LargeTagDecoderTestCase::testLargeTag", "tests/codec/ber/test_decoder.py::LargeTagDecoderTestCase::testLongTag", "tests/codec/ber/test_decoder.py::LargeTagDecoderTestCase::testTagsEquivalence", "tests/codec/ber/test_decoder.py::DecoderCacheTestCase::testCache", "tests/codec/ber/test_d... | jyangballin/swesmith.x86_64.pyasn1_1776_pyasn1.0f07d724 | true | null | 1 | 51 | 4 | 1,544 | 0 | 0.6 | 1 | 0.75 | 1 | 0.427333 | 81.557 | |||
4,262 | swe_smith::train::39681 | swe_smith | train | 39,681 | tornadoweb__tornado.d5ac65c1.func_pm_class_rm_funcs__3xjkelsc | swesmith/tornadoweb__tornado.d5ac65c1 | tornadoweb/tornado | python | null | SSLIOStream missing essential methods after refactoring
#### Description
After some recent changes, `SSLIOStream` is missing several critical methods that were previously available. This breaks SSL functionality when trying to establish connections or wait for handshakes.
#### Steps/Code to Reproduce
```python
impo... | diff --git a/tornado/iostream.py b/tornado/iostream.py
index dd2111e..afaae48 100644
--- a/tornado/iostream.py
+++ b/tornado/iostream.py
@@ -1424,25 +1424,6 @@ class SSLIOStream(IOStream):
return
super()._handle_write()
- def connect(
- self, address: Tuple, server_hostname: Optional[s... | ["test_match (tornado.test.iostream_test.TestIOStreamCheckHostname)", "test_no_match (tornado.test.iostream_test.TestIOStreamCheckHostname)", "test_inline_read_error (tornado.test.iostream_test.TestIOStreamSSL)", "test_inline_read_error (tornado.test.iostream_test.TestIOStreamSSLContext)", "test_wait_for_handshake_alre... | ["Doctest: tornado.httputil.HTTPHeaders", "Doctest: tornado.httputil.HTTPHeaders.parse", "Doctest: tornado.httputil.HTTPHeaders.parse_line", "Doctest: tornado.httputil._encode_header", "Doctest: tornado.httputil._get_content_range", "Doctest: tornado.httputil._normalize_header", "Doctest: tornado.httputil._parse_header... | jyangballin/swesmith.x86_64.tornadoweb_1776_tornado.d5ac65c1 | true | null | 1 | 57 | 7 | 1,422 | 0 | 0.6 | 1 | 0.75 | 1 | 0.427 | 81.556 | |||
4,263 | swe_smith::train::18504 | swe_smith | train | 18,504 | HIPS__autograd.ac044f0d.lm_rewrite__0980jjjc | swesmith/HIPS__autograd.ac044f0d | hips/autograd | python | null | ### Unexpected Behavior in FFT Functions with Custom Axes and Sizes
#### Description
It seems there is an issue with the FFT functions when using custom axes and sizes. The problem arises when performing real FFT operations with specific configurations, leading to unexpected results. This might be related to the rece... | diff --git a/autograd/numpy/fft.py b/autograd/numpy/fft.py
index e401b4c..f369bb4 100644
--- a/autograd/numpy/fft.py
+++ b/autograd/numpy/fft.py
@@ -140,22 +140,42 @@ def make_rfft_factors(axes, resshape, facshape, normshape, norm):
"""make the compression factors and compute the normalization
for irfft and r... | ["tests/test_fft.py::test_rfftn_subset", "tests/test_fft.py::test_rfftn_axes", "tests/test_fft.py::test_rfft2_s", "tests/test_fft.py::test_irfftn", "tests/test_fft.py::test_irfft2_s", "tests/test_fft.py::test_irfftn_subset", "tests/test_fft.py::test_rfftn_s", "tests/test_fft.py::test_irfftn_s", "tests/test_fft.py::test... | ["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 | 56 | 20 | 1,440 | 0 | 0.6 | 1 | 0.75 | 1 | 0.426667 | 81.555 | |||
4,264 | swe_smith::train::3282 | swe_smith | train | 3,282 | pygments__pygments.27649ebb.combine_file__2119qs4x | swesmith/pygments__pygments.27649ebb | pygments/pygments | python | null | RTF formatter produces malformed output and crashes with AttributeError
#### Description
The RTF formatter is completely broken and produces malformed RTF output. When trying to format code with the RTF formatter, it crashes with AttributeError and generates incorrect RTF syntax.
#### Steps/Code to Reproduce
```pyt... | diff --git a/pygments/formatters/rtf.py b/pygments/formatters/rtf.py
index 7f8b7e4..f43ca02 100644
--- a/pygments/formatters/rtf.py
+++ b/pygments/formatters/rtf.py
@@ -153,9 +153,9 @@ class RtfFormatter(Formatter):
self.color_mapping = self._create_color_mapping()
def _escape(self, text):
- retu... | ["tests/test_rtf_formatter.py::test_hl_linenostart_lines_highlighted", "tests/test_rtf_formatter.py::test_rtf_footer", "tests/test_rtf_formatter.py::test_rtf_header", "tests/test_rtf_formatter.py::test_lineno_color_style_specify_hex", "tests/test_rtf_formatter.py::test_linenos_newline_characters", "tests/test_rtf_forma... | ["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_get_style_defs_contains_default_line_numbers_styles", "tests/test_html_formatter.py::test_ctags", "tests/test_html_formatter.py::test_external_css"... | jyangballin/swesmith.x86_64.pygments_1776_pygments.27649ebb | true | null | 1 | 56 | 28 | 1,440 | 0 | 0.6 | 1 | 0.75 | 1 | 0.426667 | 81.555 | |||
4,265 | swe_smith::train::47246 | swe_smith | train | 47,246 | python-trio__trio.cfbbe2c1.lm_rewrite__4ss5l5qu | swesmith/python-trio__trio.cfbbe2c1 | python-trio/trio | python | null | # Traceback concatenation fails to preserve the full chain
## Description
I found a bug in the `concat_tb` function that's used for concatenating tracebacks. The function is not correctly preserving the full chain of tracebacks when concatenating them.
## Steps to Reproduce
Here's a simple example that demonstrates... | diff --git a/src/trio/_core/_concat_tb.py b/src/trio/_core/_concat_tb.py
index a146961..ce42912 100644
--- a/src/trio/_core/_concat_tb.py
+++ b/src/trio/_core/_concat_tb.py
@@ -117,19 +117,31 @@ else:
# this is used for collapsing single-exception ExceptionGroups when using
# `strict_exception_groups=False`. Once tha... | ["src/trio/_core/_tests/test_exceptiongroup_gc.py::test_concat_tb"] | ["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 | 44 | 1 | 1,679 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4265 | 81.5545 | |||
4,266 | r2e_gym::train::5017 | r2e_gym | train | 5,017 | datalad__a5543a43bb554317ed59cdb44d002b8f0d797f38 | datalad | datalad/datalad | python | a5543a43bb554317ed59cdb44d002b8f0d797f38 | **Analysis:**
1. **Key Parts of Commit Details and Test Results:**
- **Commit Message:** "ENH: make @with_result_progress decorate properly generator functions"
- **Commit Changes:** Modified the `with_result_progress` decorator to correctly handle generator functions by preserving their generator nature.
- *... | diff --git a/datalad/log.py b/datalad/log.py
--- a/datalad/log.py
+++ b/datalad/log.py
@@ -8,6 +8,7 @@
# ## ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ##
from functools import partial
+import inspect
import logging
import os
import sys
@@ -351,7 +352,7 @@
pid = str(fn)
base... | diff --git a/datalad/tests/test_log.py b/datalad/tests/test_log.py
--- a/datalad/tests/test_log.py
+++ b/datalad/tests/test_log.py
@@ -8,6 +8,7 @@
# ## ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ### ##
"""Test logging facilities """
+import inspect
import logging
import os.path
from os.p... | null | null | namanjain12/datalad_final:a5543a43bb554317ed59cdb44d002b8f0d797f38 | true | null | 1 | 15 | null | 2,971 | 0 | 0.75 | 1 | 0.6375 | 1 | 0.545167 | 81.55425 | ||
4,267 | swe_smith::train::1178 | swe_smith | train | 1,178 | jd__tenacity.0d40e76f.lm_rewrite__z0ij0hwj | swesmith/jd__tenacity.0d40e76f | jd/tenacity | python | null | # `after_log` function in tenacity produces incorrect log message format
## Current problem
The `after_log` function in tenacity is producing a different log message format than expected. The log message format has changed from showing information about the finished call to showing retry attempt details.
## Reproduc... | diff --git a/tenacity/after.py b/tenacity/after.py
index aa3cc9d..f48c6cd 100644
--- a/tenacity/after.py
+++ b/tenacity/after.py
@@ -28,24 +28,21 @@ def after_nothing(retry_state: "RetryCallState") -> None:
"""After call strategy that does nothing."""
-def after_log(
- logger: "logging.Logger",
- log_lev... | ["tests/test_after.py::TestAfterLogFormat::test_01_default", "tests/test_after.py::TestAfterLogFormat::test_02_custom_sec_format"] | ["tests/test_asyncio.py::TestAsyncio::test_attempt_number_is_correct_for_interleaved_coroutines", "tests/test_asyncio.py::TestAsyncio::test_iscoroutinefunction", "tests/test_asyncio.py::TestAsyncio::test_repr", "tests/test_asyncio.py::TestAsyncio::test_retry", "tests/test_asyncio.py::TestAsyncio::test_retry_attributes"... | jyangballin/swesmith.x86_64.jd_1776_tenacity.0d40e76f | true | null | 1 | 33 | 2 | 1,897 | 0 | 0.6 | 1 | 0.75 | 1 | 0.426167 | 81.5535 | |||
4,268 | swe_smith::train::47407 | swe_smith | train | 47,407 | sqlfluff__sqlfluff.50a1c4b6.combine_file__dqwx762k | swesmith/sqlfluff__sqlfluff.50a1c4b6 | sqlfluff/sqlfluff | python | null | PythonTemplater process method broken after recent changes
#### Description
The PythonTemplater's `process` method appears to be broken and is causing `UnboundLocalError` when trying to template SQL strings. The method seems to have issues with variable scoping where `live_context` and other variables are not properl... | diff --git a/src/sqlfluff/core/templaters/python.py b/src/sqlfluff/core/templaters/python.py
index a2126a8..ab4d907 100644
--- a/src/sqlfluff/core/templaters/python.py
+++ b/src/sqlfluff/core/templaters/python.py
@@ -186,9 +186,11 @@ class PythonTemplater(RawTemplater):
"""
try:
- return ... | ["test/core/templaters/python_test.py::test__templater_python", "test/core/templaters/python_test.py::test__templater_python_error", "test/core/templaters/python_test.py::test__templater_python_large_file_check", "test/core/templaters/python_test.py::test__templater_python_dot_notation_variables[-]"] | ["test/core/templaters/python_test.py::test__templater_python_intermediate__trim[int_slice0-foo-head_test0-tail_test0-int_test0]", "test/core/templaters/python_test.py::test__templater_python_intermediate__trim[int_slice1-foo-head_test1-tail_test1-int_test1]", "test/core/templaters/python_test.py::test__templater_pytho... | jyangballin/swesmith.x86_64.sqlfluff_1776_sqlfluff.50a1c4b6 | true | null | 1 | 58 | 4 | 1,396 | 0 | 0.6 | 1 | 0.75 | 1 | 0.426 | 81.553 | |||
4,269 | swe_smith::train::18692 | swe_smith | train | 18,692 | seperman__deepdiff.ed252022.combine_file__wjvvghpu | swesmith/seperman__deepdiff.ed252022 | seperman/deepdiff | python | null | Delta operations failing with parameter swapping and incorrect type conversions
#### Description
When applying delta operations, the Delta class is experiencing multiple issues with parameter ordering and type handling that cause operations to fail unexpectedly.
#### Steps/Code to Reproduce
```python
from deepdiff ... | diff --git a/deepdiff/delta.py b/deepdiff/delta.py
index 8bafc9a..8e5d51d 100644
--- a/deepdiff/delta.py
+++ b/deepdiff/delta.py
@@ -211,10 +211,10 @@ class Delta:
return result
def _raise_or_log(self, msg, level='error'):
- if self.log_errors:
- getattr(logger, level)(msg)
if... | ["tests/test_delta.py::TestBasicsOfDelta::test_from_null_delta_json", "tests/test_delta.py::TestBasicsOfDelta::test_list_difference_add_delta", "tests/test_delta.py::TestBasicsOfDelta::test_multiple_delta", "tests/test_delta.py::TestBasicsOfDelta::test_list_difference_add_delta_when_index_not_valid", "tests/test_delta.... | ["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 | 53 | 47 | 1,495 | 0 | 0.6 | 1 | 0.75 | 1 | 0.425833 | 81.5525 | |||
4,270 | swe_smith::train::1755 | swe_smith | train | 1,755 | agronholm__typeguard.b6a7e438.func_basic__67y7py0l | swesmith/agronholm__typeguard.b6a7e438 | agronholm/typeguard | python | null | Protocol signature checking broken for classmethod/staticmethod detection
#### Description
Protocol signature compatibility checking is incorrectly handling classmethod and staticmethod decorators, causing valid protocol implementations to be rejected and invalid ones to be accepted.
#### Steps/Code to Reproduce
``... | diff --git a/src/typeguard/_checkers.py b/src/typeguard/_checkers.py
index 5e34036..bc7a324 100644
--- a/src/typeguard/_checkers.py
+++ b/src/typeguard/_checkers.py
@@ -653,60 +653,54 @@ def check_signature_compatible(subject: type, protocol: type, attrname: str) ->
protocol_type: typing.Literal["instance", "class... | ["tests/test_checkers.py::TestProtocol::test_success[typing-instance]", "tests/test_checkers.py::TestProtocol::test_success[typing-class]", "tests/test_checkers.py::TestProtocol::test_success[typing_extensions-instance]", "tests/test_checkers.py::TestProtocol::test_success[typing_extensions-class]", "tests/test_checker... | ["tests/mypy/test_type_annotations.py::test_positive", "tests/mypy/test_type_annotations.py::test_negative", "tests/test_checkers.py::TestAnyStr::test_valid[str]", "tests/test_checkers.py::TestAnyStr::test_valid[bytes]", "tests/test_checkers.py::TestAnyStr::test_bad_type", "tests/test_checkers.py::TestBytesLike::test_v... | jyangballin/swesmith.x86_64.agronholm_1776_typeguard.b6a7e438 | true | null | 1 | 63 | 12 | 1,295 | 0 | 0.6 | 1 | 0.75 | 1 | 0.425833 | 81.5525 | |||
4,271 | swe_smith::train::38297 | swe_smith | train | 38,297 | burnash__gspread.a8be3b96.func_pm_ctrl_shuffle__8j5numfa | swesmith/burnash__gspread.a8be3b96 | burnash/gspread | python | null | # Worksheet.freeze() method not working correctly
## Description of the bug
I've discovered an issue with the `freeze()` method in the Worksheet class. When trying to freeze rows or columns in a worksheet, the method doesn't work as expected and causes errors.
## How to reproduce
Here's a simple script to reproduce... | diff --git a/gspread/worksheet.py b/gspread/worksheet.py
index 883e3a2..a5c3ed0 100644
--- a/gspread/worksheet.py
+++ b/gspread/worksheet.py
@@ -2360,23 +2360,19 @@ class Worksheet:
def freeze(
self, rows: Optional[int] = None, cols: Optional[int] = None
) -> JSONResponse:
- """Freeze rows and... | ["tests/worksheet_test.py::WorksheetTest::test_freeze"] | ["tests/cell_test.py::CellTest::test_a1_value", "tests/cell_test.py::CellTest::test_define_named_range", "tests/cell_test.py::CellTest::test_delete_named_range", "tests/cell_test.py::CellTest::test_equality", "tests/cell_test.py::CellTest::test_merge_cells", "tests/cell_test.py::CellTest::test_numeric_value", "tests/ce... | jyangballin/swesmith.x86_64.burnash_1776_gspread.a8be3b96 | true | null | 1 | 29 | 1 | 1,974 | 0 | 0.6 | 1 | 0.75 | 1 | 0.425667 | 81.552 | |||
4,272 | swe_smith::train::1572 | swe_smith | train | 1,572 | Cog-Creators__Red-DiscordBot.33e0eac7.func_pm_class_rm_funcs__igtm7kyn | swesmith/Cog-Creators__Red-DiscordBot.33e0eac7 | cog-creators/red-discordbot | python | null | # Missing `set_install_path` method in CogManager
## Description
I've discovered that the `set_install_path` method is missing from the `CogManager` class. This method is critical for setting the install path for 3rd party cogs.
When trying to set a custom install path for cogs, I get an AttributeError because the m... | diff --git a/redbot/core/_cog_manager.py b/redbot/core/_cog_manager.py
index bd5f77f..7a53b1a 100644
--- a/redbot/core/_cog_manager.py
+++ b/redbot/core/_cog_manager.py
@@ -88,36 +88,6 @@ class CogManager:
"""
return list(map(Path, deduplicate_iterables(await self.config.paths())))
- async def se... | ["tests/core/test_cog_manager.py::test_install_path_set", "tests/core/test_cog_manager.py::test_install_path_set_bad", "tests/core/test_cog_manager.py::test_add_path_already_install_path"] | ["tests/cogs/test_alias.py::test_is_valid_alias_name", "tests/cogs/test_alias.py::test_empty_guild_aliases", "tests/cogs/test_alias.py::test_empty_global_aliases", "tests/cogs/test_alias.py::test_add_guild_alias", "tests/cogs/test_alias.py::test_translate_alias_message", "tests/cogs/test_alias.py::test_delete_guild_ali... | jyangballin/swesmith.x86_64.cog-creators_1776_red-discordbot.33e0eac7 | true | null | 1 | 71 | 3 | 1,133 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4255 | 81.5515 | |||
4,273 | swe_smith::train::6969 | swe_smith | train | 6,969 | cantools__cantools.0c6a7871.combine_file__asejbf2y | swesmith/cantools__cantools.0c6a7871 | cantools/cantools | python | null | ARXML ECU extract loader returns None messages causing AttributeError
#### Description
When loading ARXML files using the ECU extract loader, the database contains None values instead of proper Message objects, which causes an AttributeError when trying to access message properties.
#### Steps/Code to Reproduce
```... | 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..89b6432 100644
--- a/src/cantools/database/can/formats/arxml/ecu_extract_loader.py
+++ b/src/cantools/database/can/formats/arxml/ecu_extract_loader.py
@@ -61,7 +61,7 ... | ["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 | 71 | 1 | 1,132 | 0 | 0.6 | 1 | 0.75 | 1 | 0.425333 | 81.551 | |||
4,274 | swe_smith::train::49164 | swe_smith | train | 49,164 | mozilla__bleach.73871d76.combine_file__zepj0ggw | swesmith/mozilla__bleach.73871d76 | mozilla/bleach | python | null | URL parsing returns string instead of ParseResult object
#### Description
The `urlparse` function is returning a string representation instead of a proper `ParseResult` object, causing attribute access to fail.
#### Steps/Code to Reproduce
```python
from bleach._vendor.parse import urlparse
# This should return a ... | diff --git a/bleach/_vendor/parse.py b/bleach/_vendor/parse.py
index ac6e7a9..59d5a10 100644
--- a/bleach/_vendor/parse.py
+++ b/bleach/_vendor/parse.py
@@ -369,13 +369,13 @@ def urlparse(url, scheme='', allow_fragments=True):
(e.g. netloc is a single string) and we don't expand % escapes."""
url, scheme, _co... | ["tests/test_clean.py::test_html_is_lowercased", "tests/test_clean.py::test_disallowed_attr", "tests/test_clean.py::test_unquoted_event_handler_attr_value", "tests/test_clean.py::test_invalid_filter_attr", "tests/test_clean.py::test_poster_attribute", "tests/test_clean.py::test_attributes_wildcard", "tests/test_clean.p... | ["tests/test_callbacks.py::TestNofollowCallback::test_blank", "tests/test_callbacks.py::TestNofollowCallback::test_no_href", "tests/test_callbacks.py::TestNofollowCallback::test_basic", "tests/test_callbacks.py::TestNofollowCallback::test_mailto", "tests/test_callbacks.py::TestNofollowCallback::test_has_nofollow_alread... | jyangballin/swesmith.x86_64.mozilla_1776_bleach.73871d76 | true | null | 1 | 73 | 24 | 1,090 | 0 | 0.6 | 1 | 0.75 | 1 | 0.425 | 81.55 | |||
4,275 | swe_smith::train::52773 | swe_smith | train | 52,773 | pydicom__pydicom.7d361b3d.pr_2163 | swesmith/pydicom__pydicom.7d361b3d | pydicom/pydicom | python | null | Pickling `DataElement` fails due to `_skip_conversion`
**Describe the bug**
After upgrading to Pydicom 3.0 I encountered issues working with certain DICOMs in a multiprocessing (Pytorch DataLoader) environment. The cause seems to be the following nested function, which cannot be pickled: https://github.com/pydicom/pydi... | diff --git a/src/pydicom/dataelem.py b/src/pydicom/dataelem.py
index 431e294..9b3cbe0 100644
--- a/src/pydicom/dataelem.py
+++ b/src/pydicom/dataelem.py
@@ -94,18 +94,12 @@ def empty_value_for_VR(
if VR == VR_.PN:
return b"" if raw else PersonName("")
- # DS and IS are treated more like int/float tha... | ["tests/test_dataset.py::TestDataset::test_pickle_lut"] | ["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 | 15 | 1 | 2,250 | 0 | 0.6 | 1 | 0.75 | 1 | 0.425 | 81.55 | |||
4,276 | swe_smith::train::6892 | swe_smith | train | 6,892 | joke2k__faker.8b401a7d.lm_rewrite__vgc38bve | swesmith/joke2k__faker.8b401a7d | joke2k/faker | python | null | # `date_of_birth` method no longer validates input parameters
### Description
I've discovered an issue with the `date_of_birth` method in the date_time provider. The method no longer validates its input parameters, which can lead to unexpected behavior or silent failures when invalid values are provided.
Previously,... | diff --git a/faker/providers/date_time/__init__.py b/faker/providers/date_time/__init__.py
index f05538e..5cfbf2a 100644
--- a/faker/providers/date_time/__init__.py
+++ b/faker/providers/date_time/__init__.py
@@ -2550,12 +2550,8 @@ class Provider(BaseProvider):
"""
return zoneinfo.ZoneInfo(self.timezo... | ["tests/providers/test_date_time.py::DatesOfBirth::test_value_errors"] | ["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 | 44 | 1 | 1,669 | 0 | 0.6 | 1 | 0.75 | 1 | 0.424833 | 81.5495 | |||
4,277 | r2e_gym::train::6630 | r2e_gym | train | 6,630 | pillow__a2313be8946f2050165b0a9dcf42efad11540704 | pillow | python-pillow/pillow | python | a2313be8946f2050165b0a9dcf42efad11540704 | **Title:** `ModeDescriptor` Missing `typestr` Attribute Causes AttributeError
**Description:**
When retrieving a mode using `ImageMode.getmode`, the resulting `ModeDescriptor` object does not have the `typestr` attribute. Accessing this attribute leads to an `AttributeError`, causing related functionalities and tests ... | diff --git a/src/PIL/Image.py b/src/PIL/Image.py
--- a/src/PIL/Image.py
+++ b/src/PIL/Image.py
@@ -208,44 +208,14 @@
else:
_ENDIAN = ">"
-_MODE_CONV = {
- # official modes
- "1": "|b1", # Bits need to be extended to bytes
- "L": "|u1",
- "LA": "|u1",
- "I": _ENDIAN + "i4",
- "F": _ENDIAN + "f... | diff --git a/Tests/test_image_mode.py b/Tests/test_image_mode.py
--- a/Tests/test_image_mode.py
+++ b/Tests/test_image_mode.py
@@ -21,6 +21,7 @@
assert m.bands == ("1",)
assert m.basemode == "L"
assert m.basetype == "L"
+ assert m.typestr == "|b1"
for mode in (
"I;16",
@@ -45,6 +46,7 @... | null | null | namanjain12/pillow_final:a2313be8946f2050165b0a9dcf42efad11540704 | true | null | 2 | 122 | null | 821 | 0 | 0.75 | 1 | 0.6375 | 1 | 0.5435 | 81.54925 | ||
4,278 | swe_smith::train::38671 | swe_smith | train | 38,671 | erikrose__parsimonious.0d3f5f93.lm_rewrite__6g30ctc9 | swesmith/erikrose__parsimonious.0d3f5f93 | erikrose/parsimonious | python | null | # NodeVisitor.visit() breaks error handling for nested exceptions
When using the NodeVisitor class, exceptions that occur during visitation of child nodes are not being properly handled. This causes issues with error reporting and makes debugging difficult.
## How to reproduce
Here's a simple example that demonstrat... | diff --git a/parsimonious/nodes.py b/parsimonious/nodes.py
index 7839097..689b87b 100644
--- a/parsimonious/nodes.py
+++ b/parsimonious/nodes.py
@@ -206,24 +206,34 @@ class NodeVisitor(object, metaclass=RuleDecoratorMeta):
"""
method = getattr(self, 'visit_' + node.expr_name, self.generic_visit)
-
-... | ["parsimonious/tests/test_grammar.py::RuleVisitorTests::test_undefined_rule", "parsimonious/tests/test_grammar.py::GrammarTests::test_circular_toplevel_reference", "parsimonious/tests/test_grammar.py::test_inconsistent_string_types_in_grammar", "parsimonious/tests/test_nodes.py::SimpleTests::test_visitation_exception"] | ["parsimonious/tests/test_benchmarks.py::TestBenchmarks::test_call_vs_inline", "parsimonious/tests/test_benchmarks.py::TestBenchmarks::test_lists_vs_dicts", "parsimonious/tests/test_benchmarks.py::TestBenchmarks::test_startswith_vs_regex", "parsimonious/tests/test_expressions.py::LengthTests::test_not", "parsimonious/t... | jyangballin/swesmith.x86_64.erikrose_1776_parsimonious.0d3f5f93 | true | null | 1 | 42 | 4 | 1,707 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4245 | 81.5485 | |||
4,279 | swe_smith::train::33077 | swe_smith | train | 33,077 | django-money__django-money.835c1ab8.combine_module__0bmmc28a | swesmith/django-money__django-money.835c1ab8 | django-money/django-money | python | null | MoneyField validation and query expansion broken
#### Description
When working with MoneyField instances, several core functionalities are broken including field validation, query expansion, and manager operations. The issues manifest in multiple ways:
1. Currency validation logic is inverted - fields that should ac... | diff --git a/djmoney/models/fields.py b/djmoney/models/fields.py
index dc5f6ad..90785d0 100644
--- a/djmoney/models/fields.py
+++ b/djmoney/models/fields.py
@@ -110,14 +110,13 @@ class MoneyFieldProxy:
value is not None
and self.field._currency_field.null
and not isinstance(value,... | ["tests/test_models.py::TestVanillaMoneyField::test_comparison_lookup[Money0-filters8-2]", "tests/test_models.py::TestVanillaMoneyField::test_comparison_lookup[Money0-filters9-1]", "tests/test_models.py::TestVanillaMoneyField::test_comparison_lookup[Money0-filters10-2]", "tests/test_models.py::TestVanillaMoneyField::te... | ["tests/contrib/exchange/test_admin.py::test_last_update", "tests/contrib/exchange/test_backends.py::TestBackends::test_get_rates[setup0]", "tests/contrib/exchange/test_backends.py::TestBackends::test_get_rates[setup1]", "tests/contrib/exchange/test_backends.py::TestBackends::test_initial_update_rates[setup0]", "tests/... | jyangballin/swesmith.x86_64.django-money_1776_django-money.835c1ab8 | true | null | 2 | 52 | 45 | 1,506 | 0 | 0.6 | 1 | 0.75 | 1 | 0.424333 | 81.548 | |||
4,280 | swe_smith::train::639 | swe_smith | train | 639 | oauthlib__oauthlib.1fd52536.func_basic__v5uhrs3v | swesmith/oauthlib__oauthlib.1fd52536 | oauthlib/oauthlib | python | null | OAuth1 Client sign method returns incorrect values for various signature types
#### Description
The OAuth1 Client's sign method is not working correctly for different signature types. When using header-based authentication, the realm parameter is being ignored. For body-based signatures, the Content-Type header is be... | diff --git a/oauthlib/oauth1/rfc5849/__init__.py b/oauthlib/oauth1/rfc5849/__init__.py
index 85e0b90..f94f290 100644
--- a/oauthlib/oauth1/rfc5849/__init__.py
+++ b/oauthlib/oauth1/rfc5849/__init__.py
@@ -232,32 +232,22 @@ class Client:
If the formencode argument is True and the body contains parameters, it
... | ["tests/oauth1/rfc5849/test_client.py::ClientRealmTests::test_client_realm_sign_with_additional_realm", "tests/oauth1/rfc5849/test_client.py::ClientRealmTests::test_client_realm_sign_with_default_realm", "tests/oauth1/rfc5849/test_client.py::SignatureTypeTest::test_invalid_signature_type", "tests/oauth1/rfc5849/test_cl... | ["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 | 20 | 5 | 2,145 | 0 | 0.6 | 1 | 0.75 | 1 | 0.424167 | 81.5475 | |||
4,281 | swe_smith::train::8393 | swe_smith | train | 8,393 | pyupio__safety.7654596b.combine_file__f9rugwlz | swesmith/pyupio__safety.7654596b | pyupio/safety | python | null | # Bug: SafetyError class has swapped message and error_code parameters
## Description
I found a bug in the `SafetyError` class where the message and error_code parameters are swapped in the constructor. This causes unexpected behavior when creating error instances.
For example, when creating a `SafetyError` instance... | diff --git a/safety/errors.py b/safety/errors.py
index 65a5565..eb70e17 100644
--- a/safety/errors.py
+++ b/safety/errors.py
@@ -44,8 +44,8 @@ class SafetyError(Exception):
error_code (Optional[int]): The error code.
"""
def __init__(self, message: str = "Unhandled Safety generic error", error_code: ... | ["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_debug_flag", "tests/test_cli.py::TestSafetyCLI::test_validate_with_policy_file_using_invalid_keyword", "tests/test_safety.p... | ["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_continue_on_error", "tests/test_cli.py::TestSafetyCLI::test_check_ignore_format_backward_compatible", "tests/test_cli.py::TestSafetyCLI::t... | jyangballin/swesmith.x86_64.pyupio_1776_safety.7654596b | true | null | 1 | 10 | 5 | 2,341 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4235 | 81.5455 | |||
4,282 | swe_smith::train::713 | swe_smith | train | 713 | oauthlib__oauthlib.1fd52536.func_pm_class_rm_funcs__ogtftdvd | swesmith/oauthlib__oauthlib.1fd52536 | oauthlib/oauthlib | python | null | OAuth2Error missing __init__ method breaks error handling
#### Description
OAuth2Error instances cannot be properly initialized after recent changes. The class is missing its `__init__` method and several essential properties, causing failures when trying to create error objects.
#### Steps/Code to Reproduce
```pyt... | diff --git a/oauthlib/oauth2/rfc6749/errors.py b/oauthlib/oauth2/rfc6749/errors.py
index 3b41574..3f5c53d 100644
--- a/oauthlib/oauth2/rfc6749/errors.py
+++ b/oauthlib/oauth2/rfc6749/errors.py
@@ -15,84 +15,14 @@ class OAuth2Error(Exception):
status_code = 400
description = ''
- def __init__(self, descri... | ["tests/oauth2/rfc6749/endpoints/test_base_endpoint.py::BaseEndpointTest::test_error_catching", "tests/oauth2/rfc6749/endpoints/test_base_endpoint.py::BaseEndpointTest::test_unavailability", "tests/oauth2/rfc6749/endpoints/test_base_endpoint.py::BaseEndpointTest::test_wrapper", "tests/oauth2/rfc6749/endpoints/test_clie... | ["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 | 71 | 199 | 1,121 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4235 | 81.5455 | |||
4,283 | swe_smith::train::27496 | swe_smith | train | 27,496 | arrow-py__arrow.1d70d009.combine_file__8pbefy25 | swesmith/arrow-py__arrow.1d70d009 | arrow-py/arrow | python | null | # Incorrect timestamp normalization and ordinal validation
## Description
I've found two issues in the `arrow.util` module:
1. The `validate_ordinal` function is incorrectly checking the range with strict inequality (`<`) instead of inclusive inequality (`<=`). This means that valid ordinal values at the boundaries ... | diff --git a/arrow/util.py b/arrow/util.py
index f3eaa21..0af6347 100644
--- a/arrow/util.py
+++ b/arrow/util.py
@@ -66,19 +66,19 @@ def validate_ordinal(value: Any) -> None:
"""
if isinstance(value, bool) or not isinstance(value, int):
raise TypeError(f"Ordinal must be an integer (got type {type(val... | ["tests/test_factory.py::TestGet::test_one_arg_expanded_timestamp", "tests/test_parser.py::TestDateTimeParserParse::test_parse_expanded_timestamp", "tests/test_util.py::TestUtil::test_validate_ordinal", "tests/test_util.py::TestUtil::test_normalize_timestamp"] | ["tests/test_api.py::TestModule::test_get", "tests/test_api.py::TestModule::test_utcnow", "tests/test_api.py::TestModule::test_now", "tests/test_api.py::TestModule::test_factory", "tests/test_arrow.py::TestTestArrowInit::test_init_bad_input", "tests/test_arrow.py::TestTestArrowInit::test_init", "tests/test_arrow.py::Te... | jyangballin/swesmith.x86_64.arrow-py_1776_arrow.1d70d009 | true | null | 1 | 10 | 4 | 2,341 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4235 | 81.5455 | |||
4,284 | swe_smith::train::6596 | swe_smith | train | 6,596 | joke2k__faker.8b401a7d.combine_module__tsjlsxv2 | swesmith/joke2k__faker.8b401a7d | joke2k/faker | python | null | # Sphinx docstring processing broken after recent changes
## Description
After recent changes to the `faker/sphinx/docstring.py` and `faker/sphinx/validator.py` files, the docstring processing functionality is completely broken. There are several issues:
1. The `_log_warning` method was removed from `ProviderMethodD... | diff --git a/faker/sphinx/docstring.py b/faker/sphinx/docstring.py
index 350771e..982f4ba 100644
--- a/faker/sphinx/docstring.py
+++ b/faker/sphinx/docstring.py
@@ -80,9 +80,6 @@ class ProviderMethodDocstring:
self._parse()
self._generate_samples()
- def _log_warning(self, warning):
- logg... | ["tests/sphinx/test_docstring.py::TestProviderMethodDocstring::test_name_is_dotted_path_to_base_provider_method", "tests/sphinx/test_docstring.py::TestProviderMethodDocstring::test_name_is_dotted_path_to_standard_provider_method", "tests/sphinx/test_docstring.py::TestProviderMethodDocstring::test_name_is_dotted_path_to... | ["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 | 2 | 44 | 20 | 1,659 | 0 | 0.6 | 1 | 0.75 | 1 | 0.423167 | 81.5445 | |||
4,285 | swe_smith::train::47271 | swe_smith | train | 47,271 | python-trio__trio.cfbbe2c1.lm_rewrite__eb9vs7yc | swesmith/python-trio__trio.cfbbe2c1 | python-trio/trio | python | null | ### Unexpected Behavior in `run_sync_soon` with TrioToken
Hello Trio team,
I've encountered an issue with the `run_sync_soon` method when using `TrioToken`. It seems that when a synchronous callback raises an exception, the behavior is not as expected. This is particularly noticeable when the callback is supposed to ... | diff --git a/src/trio/_core/_entry_queue.py b/src/trio/_core/_entry_queue.py
index 0691de3..a09c5f0 100644
--- a/src/trio/_core/_entry_queue.py
+++ b/src/trio/_core/_entry_queue.py
@@ -56,35 +56,18 @@ class EntryQueue:
# https://bugs.python.org/issue13697#msg237140
assert self.lock.__class__.__mod... | ["src/trio/_core/_tests/test_run.py::test_TrioToken_run_sync_soon_crashes", "src/trio/_core/_tests/test_run.py::test_TrioToken_run_sync_soon_late_crash"] | ["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 | 37 | 2 | 1,798 | 0 | 0.6 | 1 | 0.75 | 1 | 0.423 | 81.544 | |||
4,286 | swe_smith::train::49014 | swe_smith | train | 49,014 | facebookresearch__hydra.0f03eb60.lm_rewrite__srwytdqb | swesmith/facebookresearch__hydra.0f03eb60 | facebookresearch/hydra | python | null | Shuffle Function Raises TypeError with Invalid Arguments
I encountered an issue with the `shuffle` function after updating to the latest version. When passing certain arguments to `shuffle`, it raises a `TypeError` instead of handling them gracefully. This behavior was not present in the previous version.
To reproduc... | diff --git a/hydra/_internal/grammar/grammar_functions.py b/hydra/_internal/grammar/grammar_functions.py
index 879b06b..f7fb3e1 100644
--- a/hydra/_internal/grammar/grammar_functions.py
+++ b/hydra/_internal/grammar/grammar_functions.py
@@ -278,36 +278,78 @@ def tag(*args: Union[str, Union[Sweep]], sweep: Optional[Swee... | ["tests/test_overrides_parser.py::test_value[shuffle(1,2,3)]", "tests/test_overrides_parser.py::test_value[shuffle(choice(1,2,3))]", "tests/test_overrides_parser.py::test_shuffle_sequence[x=shuffle:choice:simple]", "tests/test_overrides_parser.py::test_shuffle_sequence[shuffle:choice]", "tests/test_overrides_parser.py:... | ["build_helpers/test_helpers.py::test_find[none]", "build_helpers/test_helpers.py::test_find[all]", "build_helpers/test_helpers.py::test_find[filter_a]", "build_helpers/test_helpers.py::test_find[include_a]", "build_helpers/test_helpers.py::test_find[include_a,exclude_file1]", "build_helpers/test_helpers.py::test_find[... | jyangballin/swesmith.x86_64.facebookresearch_1776_hydra.0f03eb60 | true | null | 1 | 76 | 11 | 1,018 | 0 | 0.6 | 1 | 0.75 | 1 | 0.423 | 81.544 | |||
4,287 | swe_smith::train::33926 | swe_smith | train | 33,926 | pallets__click.fde47b4b.lm_rewrite__tw4devs2 | swesmith/pallets__click.fde47b4b | pallets/click | python | null | # make_pass_decorator fails to raise proper error when context object is missing
## Description
I found a bug in the `make_pass_decorator` function. When using a decorator created with `make_pass_decorator` and the specified object type doesn't exist in the context, it fails to raise a proper error message.
## Steps... | diff --git a/src/click/decorators.py b/src/click/decorators.py
index 901f831..bf9c523 100644
--- a/src/click/decorators.py
+++ b/src/click/decorators.py
@@ -49,9 +49,8 @@ def pass_obj(f: t.Callable[te.Concatenate[T, P], R]) -> t.Callable[P, R]:
return update_wrapper(new_func, f)
-def make_pass_decorator(
- ... | ["tests/test_context.py::test_get_context_objects_missing"] | ["tests/test_arguments.py::test_nargs_star", "tests/test_arguments.py::test_argument_unbounded_nargs_cant_have_default", "tests/test_arguments.py::test_nargs_tup", "tests/test_arguments.py::test_nargs_tup_composite[opts0]", "tests/test_arguments.py::test_nargs_tup_composite[opts1]", "tests/test_arguments.py::test_nargs... | jyangballin/swesmith.x86_64.pallets_1776_click.fde47b4b | true | null | 1 | 32 | 1 | 1,897 | 0 | 0.6 | 1 | 0.75 | 1 | 0.422833 | 81.5435 | |||
4,288 | swe_smith::train::46673 | swe_smith | train | 46,673 | python-trio__trio.cfbbe2c1.combine_file__ssuweh8x | swesmith/python-trio__trio.cfbbe2c1 | python-trio/trio | python | null | # Multiple issues with Path implementation in trio
## Bug description
I've found several issues with the Path implementation in trio that are causing problems:
1. Path operations are broken - paths are not being constructed correctly
2. Documentation for async methods is corrupted
3. Path comparison and division ope... | diff --git a/src/trio/_path.py b/src/trio/_path.py
index a58136b..0ddff18 100644
--- a/src/trio/_path.py
+++ b/src/trio/_path.py
@@ -36,14 +36,17 @@ def _wraps_async( # type: ignore[misc]
) -> Callable[[Callable[P, T]], Callable[P, Awaitable[T]]]:
def decorator(fn: Callable[P, T]) -> Callable[P, Awaitable[T]]:
... | ["src/trio/_tests/test_highlevel_open_unix_stream.py::test_open_unix_socket", "src/trio/_tests/test_path.py::test_instantiate_posix", "src/trio/_tests/test_path.py::test_open_is_async_context_manager", "src/trio/_tests/test_path.py::test_cmp_magic[Path-Path0]", "src/trio/_tests/test_path.py::test_cmp_magic[Path-Path1]"... | ["src/trio/_core/_tests/test_asyncgen.py::test_asyncgen_basics", "src/trio/_core/_tests/test_asyncgen.py::test_asyncgen_throws_during_finalization", "src/trio/_core/_tests/test_asyncgen.py::test_firstiter_after_closing", "src/trio/_core/_tests/test_asyncgen.py::test_interdependent_asyncgen_cleanup_order", "src/trio/_co... | jyangballin/swesmith.x86_64.python-trio_1776_trio.cfbbe2c1 | true | null | 1 | 21 | 21 | 2,115 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4225 | 81.5425 | |||
4,289 | swe_smith::train::3585 | swe_smith | train | 3,585 | pygments__pygments.27649ebb.combine_module__34577f4v | swesmith/pygments__pygments.27649ebb | pygments/pygments | python | null | RTF and LaTeX formatters broken after recent changes
#### Description
The RTF and LaTeX formatters are producing incorrect output and throwing errors. Multiple issues seem to have been introduced:
1. RTF formatter throws `TypeError: 'StyleMeta' object is not subscriptable`
2. LaTeX formatter throws `IndexError: stri... | diff --git a/pygments/formatters/latex.py b/pygments/formatters/latex.py
index 2f7971e..ae25c3f 100644
--- a/pygments/formatters/latex.py
+++ b/pygments/formatters/latex.py
@@ -282,11 +282,11 @@ class LatexFormatter(Formatter):
cp = self.commandprefix
def rgbcolor(col):
- if col:
+ ... | ["tests/test_rtf_formatter.py::test_hl_linenostart_lines_highlighted", "tests/test_rtf_formatter.py::test_rtf_footer", "tests/test_rtf_formatter.py::test_rtf_header", "tests/test_rtf_formatter.py::test_lineno_color_style_specify_hex", "tests/test_rtf_formatter.py::test_linenos_newline_characters", "tests/test_rtf_forma... | ["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_get_style_defs_contains_default_line_numbers_styles", "tests/test_html_formatter.py::test_ctags", "tests/test_html_formatter.py::test_external_css"... | jyangballin/swesmith.x86_64.pygments_1776_pygments.27649ebb | true | null | 2 | 59 | 33 | 1,353 | 0 | 0.6 | 1 | 0.75 | 1 | 0.422167 | 81.5415 | |||
4,290 | swe_smith::train::43787 | swe_smith | train | 43,787 | pydata__patsy.a5d16484.combine_file__ggjhfmm5 | swesmith/pydata__patsy.a5d16484 | pydata/patsy | python | null | B-spline boundary condition check is too strict
Description
I've discovered an issue with the B-spline implementation in patsy. The boundary condition check in `_eval_bspline_basis` is too strict, causing valid data points to be rejected.
Currently, the function checks:
```python
if np.min(x) < np.min(knots) or np.m... | diff --git a/patsy/splines.py b/patsy/splines.py
index a6735e5..192e04c 100644
--- a/patsy/splines.py
+++ b/patsy/splines.py
@@ -21,9 +21,6 @@ def _eval_bspline_basis(x, knots, degree):
from scipy.interpolate import splev
except ImportError: # pragma: no cover
raise ImportError("spline functiona... | ["patsy/mgcv_cubic_splines.py::test_te_1smooth", "patsy/splines.py::test__R_compat_quantile", "patsy/splines.py::test_bs_compat", "patsy/splines.py::test_bs_0degree", "patsy/splines.py::test_bs_errors"] | ["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 | 53 | 5 | 1,473 | 0 | 0.6 | 1 | 0.75 | 1 | 0.422167 | 81.5415 | |||
4,291 | swe_smith::train::45234 | swe_smith | train | 45,234 | dask__dask.5f61e423.combine_module__ibhv7crq | swesmith/dask__dask.5f61e423 | dask/dask | python | null | from_delayed divisions validation broken
When using `from_delayed` with explicit divisions, the function incorrectly validates the divisions length, causing it to fail even with correct input.
#### Steps/Code to Reproduce
```python
import pandas as pd
import numpy as np
from dask.delayed import delayed
from dask.dat... | diff --git a/dask/dataframe/dask_expr/_collection.py b/dask/dataframe/dask_expr/_collection.py
index 7aa07d4..e324442 100644
--- a/dask/dataframe/dask_expr/_collection.py
+++ b/dask/dataframe/dask_expr/_collection.py
@@ -3017,26 +3017,67 @@ class DataFrame(FrameBase):
)
@derived_from(pd.DataFrame)
- ... | ["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/tests/test_collection.py::test_drop_duplicates_meta", "dask/d... | ["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/tests/test_collection.py::test_del", "dask/dataframe/dask_expr/tests/test_collection.py::test_info[True-None-True]", "dask/datafram... | jyangballin/swesmith.x86_64.dask_1776_dask.5f61e423 | true | null | 2 | 79 | 5 | 953 | 0 | 0.6 | 1 | 0.75 | 1 | 0.422167 | 81.5415 | |||
4,292 | swe_smith::train::22969 | swe_smith | train | 22,969 | graphql-python__graphene.82903263.lm_rewrite__0ajumxnw | swesmith/graphql-python__graphene.82903263 | graphql-python/graphene | python | null | Connection Initialization Fails with Missing Node Assertion
Description
The recent changes to the `Connection` class initialization have introduced an issue where the node parameter is not being properly handled, leading to assertion errors. Specifically, when attempting to create a connection subclass without explic... | diff --git a/graphene/relay/connection.py b/graphene/relay/connection.py
index cc7d2da..6d8c7c7 100644
--- a/graphene/relay/connection.py
+++ b/graphene/relay/connection.py
@@ -89,47 +89,46 @@ class Connection(ObjectType):
abstract = True
@classmethod
- def __init_subclass_with_meta__(
- cls, ... | ["examples/starwars_relay/tests/test_connections.py::test_correct_fetch_first_ship_rebels", "examples/starwars_relay/tests/test_mutation.py::test_mutations", "examples/starwars_relay/tests/test_objectidentification.py::test_str_schema", "examples/starwars_relay/tests/test_objectidentification.py::test_correctly_fetches... | ["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 | 77 | 36 | 992 | 0 | 0.6 | 1 | 0.75 | 1 | 0.422 | 81.541 | |||
4,293 | swe_smith::train::43825 | swe_smith | train | 43,825 | pydata__patsy.a5d16484.combine_file__suf5a2c7 | swesmith/pydata__patsy.a5d16484 | pydata/patsy | python | null | Comments not properly handled in tokenizer
When using formulas with comments, the tokenizer incorrectly raises errors instead of properly handling them. This affects formula parsing throughout the library.
#### Steps/Code to Reproduce
```python
from patsy import dmatrix
# This should work but raises an error
data =... | diff --git a/patsy/tokens.py b/patsy/tokens.py
index 34d8efc..8ffd3f9 100644
--- a/patsy/tokens.py
+++ b/patsy/tokens.py
@@ -23,49 +23,35 @@ __all__ = ["python_tokenize", "pretty_untokenize", "normalize_token_spacing"]
# A convenience wrapper around tokenize.generate_tokens. yields tuples
# (tokenize type, token st... | ["patsy/desc.py::test_ModelDesc_from_formula", "patsy/desc.py::test_eval_formula", "patsy/desc.py::test_eval_formula_error_reporting", "patsy/desc.py::test_formula_factor_origin", "patsy/eval.py::test_EvalFactor_memorize_passes_needed", "patsy/eval.py::test_EvalFactor_end_to_end", "patsy/eval.py::test_annotated_tokens"... | ["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 | 75 | 36 | 1,030 | 0 | 0.6 | 1 | 0.75 | 1 | 0.421667 | 81.54 | |||
4,294 | swe_smith::train::27454 | swe_smith | train | 27,454 | tkrajina__gpxpy.09fc46b3.lm_rewrite__mkmq07zn | swesmith/tkrajina__gpxpy.09fc46b3 | tkrajina/gpxpy | python | null | # `reduce_points` function doesn't work when no parameters are provided
I found an issue with the `reduce_points` method in the GPX class. When calling the method without any parameters, it doesn't raise an error as expected.
## Current behavior:
```python
gpx = gpxpy.parse(open('test_files/gpx1.gpx'))
gpx.reduce_poi... | diff --git a/gpxpy/gpx.py b/gpxpy/gpx.py
index 73e2024..8e48dff 100644
--- a/gpxpy/gpx.py
+++ b/gpxpy/gpx.py
@@ -2020,7 +2020,7 @@ class GPX:
for track in self.tracks:
track.simplify(max_distance=max_distance)
- def reduce_points(self, max_points_no: Optional[float]=None, min_distance: Option... | ["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 | 68 | 1 | 1,168 | 0 | 0.6 | 1 | 0.75 | 1 | 0.421333 | 81.539 | |||
4,295 | swe_bench::test::1279 | swe_bench | test | 1,279 | pydata__xarray-6400 | pydata/xarray | pydata/xarray | python | 728b648d5c7c3e22fe3704ba163012840408bf66 | Very poor html repr performance on large multi-indexes
**What happened**:
We have catestrophic performance on the html repr of some long multi-indexed data arrays. Here's a case of it taking 12s.
**Minimal Complete Verifiable Example**:
```python
import xarray as xr
ds = xr.tutorial.load_dataset("air_temperature"... | I think it's some lazy calculation that kicks in. Because I can reproduce using np.asarray.
```python
import numpy as np
import xarray as xr
ds = xr.tutorial.load_dataset("air_temperature")
da = ds["air"].stack(z=[...])
coord = da.z.variable.to_index_variable()
# This is very slow:
a = np.asarray(coord)... | diff --git a/xarray/core/formatting.py b/xarray/core/formatting.py
--- a/xarray/core/formatting.py
+++ b/xarray/core/formatting.py
@@ -520,7 +520,11 @@ def short_numpy_repr(array):
# default to lower precision so a full (abbreviated) line can fit on
# one line with the default display_width
- options = {... | diff --git a/xarray/tests/test_formatting.py b/xarray/tests/test_formatting.py
--- a/xarray/tests/test_formatting.py
+++ b/xarray/tests/test_formatting.py
@@ -479,6 +479,12 @@ def test_short_numpy_repr() -> None:
num_lines = formatting.short_numpy_repr(array).count("\n") + 1
assert num_lines < 30
+ ... | ["xarray/tests/test_formatting.py::test_short_numpy_repr"] | ["xarray/tests/test_formatting.py::TestFormatting::test_get_indexer_at_least_n_items", "xarray/tests/test_formatting.py::TestFormatting::test_first_n_items", "xarray/tests/test_formatting.py::TestFormatting::test_last_n_items", "xarray/tests/test_formatting.py::TestFormatting::test_last_item", "xarray/tests/test_format... | null | true | 2022-03-22T12:57:37Z | 3 | 46 | 1 | 1,405 | 0 | 0.8 | 1 | 0.55 | 1 | 0.3875 | 81.5375 | |
4,296 | swe_smith::train::35490 | swe_smith | train | 35,490 | stanfordnlp__dspy.651a4c71.func_pm_ctrl_invert_if__uiftckei | swesmith/stanfordnlp__dspy.651a4c71 | stanfordnlp/dspy | python | null | # Callback handler for adapter parse method is incorrectly assigned
## Description
I found a bug in the callback handling for adapter parse methods. When using callbacks with adapters, the parse method incorrectly raises a ValueError instead of calling the appropriate callback handler.
## Steps to Reproduce
1. Crea... | diff --git a/dspy/utils/callback.py b/dspy/utils/callback.py
index 2753c8f..f5d43e0 100644
--- a/dspy/utils/callback.py
+++ b/dspy/utils/callback.py
@@ -381,12 +381,12 @@ def _get_on_end_handler(callback: BaseCallback, instance: Any, fn: Callable) ->
if fn.__name__ == "format":
return callback.on_... | ["tests/callback/test_callback.py::test_callback_complex_module", "tests/callback/test_callback.py::test_callback_async_module", "tests/signatures/test_adapter_image.py::test_pdf_url_support", "tests/signatures/test_adapter_image.py::test_different_mime_types", "tests/signatures/test_adapter_image.py::test_mime_type_fr... | ["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 | 6 | 6 | 2,405 | 0 | 0.6 | 1 | 0.75 | 1 | 0.420833 | 81.5375 | |||
4,297 | swe_smith::train::49642 | swe_smith | train | 49,642 | cool-RR__PySnooper.57472b46.lm_rewrite__xxcs25kj | swesmith/cool-RR__PySnooper.57472b46 | cool-rr/pysnooper | python | null | Custom representation for single type-handler pair fails in PySnooper
When using PySnooper with a single custom representation handler (not wrapped in a tuple of tuples), the tracer fails to initialize properly. This happens when passing a type and handler function directly as a pair.
For example, this code fails:
`... | diff --git a/pysnooper/tracer.py b/pysnooper/tracer.py
index 1b35154..e44447b 100644
--- a/pysnooper/tracer.py
+++ b/pysnooper/tracer.py
@@ -231,65 +231,60 @@ class Tracer:
@pysnooper.snoop(color=False)
'''
- def __init__(self, output=None, watch=(), watch_explode=(), depth=1,
- prefi... | ["tests/test_pysnooper.py::test_custom_repr_single[True]", "tests/test_pysnooper.py::test_custom_repr_single[False]"] | ["tests/test_chinese.py::test_chinese", "tests/test_mini_toolbox.py::test_output_capturer_doesnt_swallow_exceptions", "tests/test_multiple_files/test_multiple_files.py::test_multiple_files", "tests/test_not_implemented.py::test_rejecting_coroutine_functions", "tests/test_not_implemented.py::test_rejecting_async_generat... | jyangballin/swesmith.x86_64.cool-rr_1776_pysnooper.57472b46 | true | null | 1 | 73 | 2 | 1,065 | 0 | 0.6 | 1 | 0.75 | 1 | 0.420833 | 81.5375 | |||
4,298 | swe_smith::train::38182 | swe_smith | train | 38,182 | john-kurkowski__tldextract.3d1bf184.combine_file__tp7a1i3n | swesmith/john-kurkowski__tldextract.3d1bf184 | john-kurkowski/tldextract | python | null | # Issues with file handling and response processing in tldextract
## Description
I've encountered a couple of issues with the latest version of tldextract that are causing problems in my project:
1. When trying to clear the cache, I'm getting FileNotFoundError exceptions. It seems that the code is now re-raising Fil... | diff --git a/tldextract/cache.py b/tldextract/cache.py
index 83a87f0..25af364 100644
--- a/tldextract/cache.py
+++ b/tldextract/cache.py
@@ -143,11 +143,9 @@ class DiskCache:
try:
os.unlink(str(Path(root, filename)))
except FileNotFoundError:
- ... | ["tests/main_test.py::test_find_first_response_without_session", "tests/main_test.py::test_find_first_response_with_session", "tests/test_parallel.py::test_cache_cleared_by_other_process"] | ["tests/cli_test.py::test_cli_no_input", "tests/cli_test.py::test_cli_parses_args", "tests/cli_test.py::test_cli_posargs", "tests/cli_test.py::test_cli_namedargs", "tests/cli_test.py::test_cli_json_output", "tests/custom_suffix_test.py::test_private_extraction", "tests/custom_suffix_test.py::test_suffix_which_is_not_in... | jyangballin/swesmith.x86_64.john-kurkowski_1776_tldextract.3d1bf184 | true | null | 1 | 10 | 3 | 2,323 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4205 | 81.5365 | |||
4,299 | swe_smith::train::3477 | swe_smith | train | 3,477 | pygments__pygments.27649ebb.combine_file__qb9e913f | swesmith/pygments__pygments.27649ebb | pygments/pygments | python | null | ERB lexer broken after removing get_tokens_unprocessed method
#### Description
The ERB lexer and its subclasses (RhtmlLexer, CssErbLexer, JavascriptErbLexer, XmlErbLexer) are completely broken and raise `NotImplementedError` when trying to tokenize any input.
#### Steps/Code to Reproduce
```python
from pygments.lex... | diff --git a/pygments/lexers/templates.py b/pygments/lexers/templates.py
index e5adf34..e2cbe67 100644
--- a/pygments/lexers/templates.py
+++ b/pygments/lexers/templates.py
@@ -71,79 +71,10 @@ class ErbLexer(Lexer):
self.ruby_lexer = RubyLexer(**options)
Lexer.__init__(self, **options)
- def get_... | ["tests/test_basic_api.py::test_lexer_options[CssErbLexer]", "tests/test_basic_api.py::test_random_input[RhtmlLexer]", "tests/test_basic_api.py::test_random_input[ErbLexer]", "tests/test_basic_api.py::test_lexer_options[RhtmlLexer]", "tests/test_basic_api.py::test_lexer_options[XmlErbLexer]", "tests/test_basic_api.py::... | ["tests/test_rtf_formatter.py::test_hl_linenostart_lines_highlighted", "tests/test_rtf_formatter.py::test_rtf_footer", "tests/test_rtf_formatter.py::test_rtf_header", "tests/test_rtf_formatter.py::test_lineno_color_style_specify_hex", "tests/test_rtf_formatter.py::test_linenos_newline_characters", "tests/test_rtf_forma... | jyangballin/swesmith.x86_64.pygments_1776_pygments.27649ebb | true | null | 1 | 73 | 14 | 1,063 | 0 | 0.6 | 1 | 0.75 | 1 | 0.4205 | 81.5365 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.