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
6,300
swe_smith::train::4909
swe_smith
train
4,909
bottlepy__bottle.a8dfef30.func_pm_class_rm_funcs__u9a4jqq4
swesmith/bottlepy__bottle.a8dfef30
bottlepy/bottle
python
null
Template search method missing causes AttributeError #### Description When using template engines like Jinja2 or SimpleTemplate with file-based templates, an AttributeError is raised because the `search` method is missing from the BaseTemplate class. #### Steps/Code to Reproduce ```python import bottle from bottle ...
diff --git a/bottle.py b/bottle.py index 286b5bc..cc8550d 100755 --- a/bottle.py +++ b/bottle.py @@ -4067,26 +4067,6 @@ class BaseTemplate(object): raise TemplateError('No template specified.') self.prepare(**self.settings) - @classmethod - def search(cls, name, lookup=None): - """ ...
["test/test_jinja2.py::TestJinja2Template::test_file", "test/test_jinja2.py::TestJinja2Template::test_inherit", "test/test_jinja2.py::TestJinja2Template::test_name", "test/test_stpl.py::TestSimpleTemplate::test_file", "test/test_stpl.py::TestSimpleTemplate::test_include", "test/test_stpl.py::TestSimpleTemplate::test_na...
["test/test_app.py::TestApplicationObject::test_setattr", "test/test_auth.py::TestBasicAuth::test__header", "test/test_config.py::TestConfDict::test_gc_overlays", "test/test_config.py::TestConfDict::test_isadict", "test/test_config.py::TestConfDict::test_load_dict", "test/test_config.py::TestConfDict::test_load_module"...
jyangballin/swesmith.x86_64.bottlepy_1776_bottle.a8dfef30
true
null
1
21
11
1,150
0
0.6
1
0.75
1
0.261667
81.06
6,301
swe_smith::train::29009
swe_smith
train
29,009
tox-dev__pipdeptree.c31b6418.combine_file__dq4sga6r
swesmith/tox-dev__pipdeptree.c31b6418
tox-dev/pipdeptree
python
null
PackageDAG.reverse() returns dict instead of ReversedPackageDAG #### Description When calling `reverse()` on a PackageDAG instance, the method returns a plain dict instead of a ReversedPackageDAG object. This breaks functionality that expects the reversed DAG to have the same interface as the original DAG. #### Step...
diff --git a/src/pipdeptree/_models/dag.py b/src/pipdeptree/_models/dag.py index 2f5df60..eb98ba1 100644 --- a/src/pipdeptree/_models/dag.py +++ b/src/pipdeptree/_models/dag.py @@ -110,9 +110,9 @@ class PackageDAG(Mapping[DistPackage, List[ReqPackage]]): """ try: - return self._index[node...
["tests/_models/test_dag.py::test_package_dag_filter_fnmatch_include_a", "tests/_models/test_dag.py::test_package_dag_filter_fnmatch_include_b", "tests/_models/test_dag.py::test_package_dag_filter_fnmatch_exclude_c", "tests/_models/test_dag.py::test_package_dag_reverse", "tests/render/test_mermaid.py::test_render_merma...
["tests/_models/test_dag.py::test_package_dag_get_node_as_parent", "tests/_models/test_dag.py::test_package_dag_filter_fnmatch_exclude_a", "tests/_models/test_dag.py::test_package_dag_filter_include_exclude_both_used", "tests/_models/test_dag.py::test_package_dag_filter_nonexistent_packages", "tests/_models/test_dag.py...
jyangballin/swesmith.x86_64.tox-dev_1776_pipdeptree.c31b6418
true
null
1
17
12
1,230
0
0.6
1
0.75
1
0.261667
81.06
6,302
swe_smith::train::18158
swe_smith
train
18,158
pndurette__gTTS.dbcda4f3.func_pm_ctrl_shuffle__rosorglz
swesmith/pndurette__gTTS.dbcda4f3
pndurette/gtts
python
null
gTTS object missing text attribute after initialization When creating a gTTS object, the `text` attribute is not accessible immediately after initialization, causing AttributeError when trying to access it. #### Steps/Code to Reproduce ```python from gtts import gTTS # This should work but raises AttributeError tts...
diff --git a/gtts/tts.py b/gtts/tts.py index eae351f..763e31f 100644 --- a/gtts/tts.py +++ b/gtts/tts.py @@ -123,21 +123,16 @@ class gTTS: timeout=None, ): + # Translate URL top-level domain + self.tld = tld + + self.timeout = timeout + # Debug for k, v in dict(loc...
["gtts/tests/test_cli.py::test_text_empty", "gtts/tests/test_cli.py::test_lang_nocheck", "gtts/tests/test_cli.py::test_params_set", "gtts/tests/test_cli.py::test_stdin_text", "gtts/tests/test_cli.py::test_stdin_text_unicode", "gtts/tests/test_cli.py::test_stdin_file", "gtts/tests/test_cli.py::test_stdin_file_unicode", ...
["gtts/tests/test_cli.py::test_text_no_text_or_file", "gtts/tests/test_cli.py::test_text_text_and_file", "gtts/tests/test_cli.py::test_file_not_exists", "gtts/tests/test_cli.py::test_all", "gtts/tests/test_cli.py::test_lang_not_valid", "gtts/tests/test_lang.py::test_main_langs", "gtts/tests/test_lang.py::test_deprecate...
jyangballin/swesmith.x86_64.pndurette_1776_gtts.dbcda4f3
true
null
1
31
82
950
0
0.6
1
0.75
1
0.261667
81.06
6,303
r2e_gym::train::5318
r2e_gym
train
5,318
aiohttp__e15c602b08cc943f5078a6284449f8e949cbb230
aiohttp
aio-libs/aiohttp
python
e15c602b08cc943f5078a6284449f8e949cbb230
**Title:** Incorrect Calculation of Next Cleanup Run Timing Causes Test Failures **Description** After updating the connector's cleanup scheduling logic, certain cleanup tasks are being scheduled at incorrect times. Specifically, the tests that verify the timing of the next cleanup run are failing because the schedule...
diff --git a/aiohttp/connector.py b/aiohttp/connector.py --- a/aiohttp/connector.py +++ b/aiohttp/connector.py @@ -161,15 +161,21 @@ now = self._loop.time() connections = {} + timeout = self._keepalive_timeout + for key, conns in self._conns.items(): alive = [] ...
diff --git a/tests/test_connector.py b/tests/test_connector.py --- a/tests/test_connector.py +++ b/tests/test_connector.py @@ -417,7 +417,26 @@ self.assertIsNotNone(conn._cleanup_handle) loop.call_at.assert_called_with( - 311, conn._cleanup) + 310, conn._cleanup) + conn....
null
null
namanjain12/aiohttp_final:e15c602b08cc943f5078a6284449f8e949cbb230
true
null
1
14
null
2,002
0
0.75
1
0.6375
1
0.380333
81.05975
6,304
swe_smith::train::10056
swe_smith
train
10,056
paramiko__paramiko.23f92003.combine_file__47ddhck9
swesmith/paramiko__paramiko.23f92003
paramiko/paramiko
python
null
DSS key operations broken after recent changes I'm having issues with DSS (DSA) key operations that seem to have started recently. When trying to use DSS keys for SSH connections or key operations, I'm getting various errors. #### Steps to Reproduce ```python from paramiko import DSSKey # Try to load a DSS key key ...
diff --git a/paramiko/dsskey.py b/paramiko/dsskey.py index 5215d28..56ffbf1 100644 --- a/paramiko/dsskey.py +++ b/paramiko/dsskey.py @@ -85,11 +85,11 @@ class DSSKey(PKey): def asbytes(self): m = Message() m.add_string(self.name) - m.add_mpint(self.p) m.add_mpint(self.q) + ...
["tests/auth.py::AuthHandler_::multipart_auth", "tests/test_client.py::SSHClientTest::test_certs_allowed_as_key_filename_values", "tests/test_client.py::SSHClientTest::test_certs_implicitly_loaded_alongside_key_filename_keys", "tests/test_client.py::SSHClientTest::test_client_dsa", "tests/test_client.py::SSHClientTest:...
["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
20
12
1,169
0
0.6
1
0.75
1
0.2615
81.0595
6,305
swe_smith::train::31434
swe_smith
train
31,434
benoitc__gunicorn.bacbf8aa.combine_module__ibw5nppq
swesmith/benoitc__gunicorn.bacbf8aa
benoitc/gunicorn
python
null
Config initialization fails with TypeError when creating BaseApplication #### Description When creating a BaseApplication instance, the configuration initialization fails with a TypeError due to incorrect parameter order in the Config constructor call. #### Steps/Code to Reproduce ```python from gunicorn.app.base i...
diff --git a/gunicorn/app/base.py b/gunicorn/app/base.py index 9bf7a4f..37efd62 100644 --- a/gunicorn/app/base.py +++ b/gunicorn/app/base.py @@ -31,16 +31,14 @@ class BaseApplication: Loads the configuration """ try: - self.load_default_config() self.load_config() - ...
["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
34
43
889
0
0.6
1
0.75
1
0.2615
81.0595
6,306
swe_smith::train::6952
swe_smith
train
6,952
cantools__cantools.0c6a7871.combine_file__7bt91bzz
swesmith/cantools__cantools.0c6a7871
cantools/cantools
python
null
SYM format parsing fails with "could not convert string to float: '='" error #### Description When loading SYM files, the parser fails with a conversion error trying to convert the string '=' to a float. This appears to affect multiple SYM file operations including loading, converting, and dumping. #### Steps/Code t...
diff --git a/src/cantools/database/can/formats/sym.py b/src/cantools/database/can/formats/sym.py index 4bdc121..9390129 100644 --- a/src/cantools/database/can/formats/sym.py +++ b/src/cantools/database/can/formats/sym.py @@ -291,13 +291,13 @@ def _load_enums(tokens): for _, _, name, _, values, _, _ in section: ...
["tests/test_convert.py::CanToolsConvertFullTest::test_sym_to_dbc__compare_databases", "tests/test_convert.py::CanToolsConvertFullTest::test_sym_to_dbc__compare_files", "tests/test_database.py::CanToolsDatabaseTest::test_comments_hex_and_motorola_sym", "tests/test_database.py::CanToolsDatabaseTest::test_extended_id_sym...
["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
23
13
1,109
0
0.6
1
0.75
1
0.2615
81.0595
6,307
swe_smith::train::40849
swe_smith
train
40,849
scanny__python-pptx.278b47b1.func_basic__bbk1ujln
swesmith/scanny__python-pptx.278b47b1
scanny/python-pptx
python
null
ST_TargetMode validation accepts invalid values and rejects valid ones #### Description The ST_TargetMode validation is behaving incorrectly - it's accepting invalid target mode values and rejecting valid ones like "Internal" and "External". #### Steps/Code to Reproduce ```python from pptx.oxml.simpletypes import S...
diff --git a/src/pptx/oxml/simpletypes.py b/src/pptx/oxml/simpletypes.py index 6ceb06f..224f03c 100644 --- a/src/pptx/oxml/simpletypes.py +++ b/src/pptx/oxml/simpletypes.py @@ -623,9 +623,9 @@ class ST_TargetMode(XsdString): @classmethod def validate(cls, value): - cls.validate_string(value) - ...
["tests/opc/test_oxml.py::DescribeCT_Relationship::and_it_constructs_an_external_relationship_when_target_mode_EXTERNAL_is_specified", "tests/opc/test_oxml.py::DescribeCT_Relationships::it_can_build_rels_element_incrementally", "tests/opc/test_package.py::Describe_Relationships::it_can_serialize_itself_to_XML"]
["tests/chart/test_axis.py::Describe_BaseAxis::it_provides_access_to_its_title[c:catAx]", "tests/chart/test_axis.py::Describe_BaseAxis::it_provides_access_to_its_title[c:dateAx]", "tests/chart/test_axis.py::Describe_BaseAxis::it_provides_access_to_its_title[c:valAx]", "tests/chart/test_axis.py::Describe_BaseAxis::it_pr...
jyangballin/swesmith.x86_64.scanny_1776_python-pptx.278b47b1
true
null
1
6
3
1,449
0
0.6
1
0.75
1
0.2615
81.0595
6,308
swe_smith::train::29007
swe_smith
train
29,007
tox-dev__pipdeptree.c31b6418.combine_file__bb0r8mlb
swesmith/tox-dev__pipdeptree.c31b6418
tox-dev/pipdeptree
python
null
PackageDAG.reverse() returns dict instead of ReversedPackageDAG instance #### Description When calling `reverse()` on a PackageDAG instance, it returns a plain dict instead of a ReversedPackageDAG instance. This breaks functionality that expects the reversed tree to maintain the same interface as the original DAG. #...
diff --git a/src/pipdeptree/_models/dag.py b/src/pipdeptree/_models/dag.py index 2f5df60..3ae3876 100644 --- a/src/pipdeptree/_models/dag.py +++ b/src/pipdeptree/_models/dag.py @@ -110,9 +110,9 @@ class PackageDAG(Mapping[DistPackage, List[ReqPackage]]): """ try: - return self._index[node...
["tests/_models/test_dag.py::test_package_dag_filter_fnmatch_include_a", "tests/_models/test_dag.py::test_package_dag_filter_fnmatch_include_b", "tests/_models/test_dag.py::test_package_dag_filter_fnmatch_exclude_c", "tests/_models/test_dag.py::test_package_dag_filter_packages_uses_pep503normalize", "tests/_models/test...
["tests/_models/test_dag.py::test_package_dag_get_node_as_parent", "tests/_models/test_dag.py::test_package_dag_filter_fnmatch_exclude_a", "tests/_models/test_dag.py::test_package_dag_filter_include_exclude_both_used", "tests/_models/test_dag.py::test_package_dag_filter_nonexistent_packages", "tests/_models/test_dag.py...
jyangballin/swesmith.x86_64.tox-dev_1776_pipdeptree.c31b6418
true
null
1
23
31
1,109
0
0.6
1
0.75
1
0.2615
81.0595
6,309
swe_smith::train::2388
swe_smith
train
2,388
pdfminer__pdfminer.six.1a8bd2f7.func_pm_class_rm_funcs__k1grpymw
swesmith/pdfminer__pdfminer.six.1a8bd2f7
pdfminer/pdfminer.six
python
null
CMapDB.get_cmap method missing after refactoring #### Description After a recent change, the `CMapDB.get_cmap` method appears to have been removed, causing `AttributeError: type object 'CMapDB' has no attribute 'get_cmap'` when trying to process PDF files that require character mapping. #### Steps/Code to Reproduce ...
diff --git a/pdfminer/cmapdb.py b/pdfminer/cmapdb.py index 87d9870..4e2b19f 100644 --- a/pdfminer/cmapdb.py +++ b/pdfminer/cmapdb.py @@ -248,24 +248,6 @@ class CMapDB: gzfile.close() raise CMapDB.CMapNotFound(name) - @classmethod - def get_cmap(cls, name: str) -> CMapBase: - ...
["tests/test_converter.py::TestColorSpace::test_do_rg", "tests/test_highlevel_extracttext.py::TestExtractText::test_issue_495_pdfobjref_iterable", "tests/test_highlevel_extracttext.py::TestExtractText::test_issue_566_cid_range", "tests/test_highlevel_extracttext.py::TestExtractText::test_issue_566_cmap_bytes", "tests/t...
["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
19
35
1,189
0
0.6
1
0.75
1
0.2615
81.0595
6,310
swe_smith::train::48178
swe_smith
train
48,178
sqlfluff__sqlfluff.50a1c4b6.func_pm_ctrl_shuffle__0fqxmvtn
swesmith/sqlfluff__sqlfluff.50a1c4b6
sqlfluff/sqlfluff
python
null
Config file loading broken after recent changes #### Description The linter is failing to load configuration files properly. When trying to lint files, I'm getting errors related to undefined variables in the config loading function. #### Steps/Code to Reproduce ```python from sqlfluff import Linter # Try to lint ...
diff --git a/src/sqlfluff/core/linter/discovery.py b/src/sqlfluff/core/linter/discovery.py index eb68e44..adccba1 100644 --- a/src/sqlfluff/core/linter/discovery.py +++ b/src/sqlfluff/core/linter/discovery.py @@ -76,20 +76,8 @@ def _load_ignorefile(dirpath: str, filename: str) -> IgnoreSpecRecord: def _load_config...
["test/core/linter/discovery_test.py::test__linter__path_from_paths__dir", "test/core/linter/discovery_test.py::test__linter__path_from_paths__default", "test/core/linter/discovery_test.py::test__linter__path_from_paths__exts", "test/core/linter/discovery_test.py::test__linter__path_from_paths__file", "test/core/linter...
["test/core/linter/discovery_test.py::test__linter__path_from_paths__not_exist", "test/core/linter/discovery_test.py::test__linter__path_from_paths__not_exist_ignore", "test/core/linter/discovery_test.py::test__linter__load_specs_from_lines[12345]", "test/core/linter/discovery_test.py::test__linter__load_specs_from_lin...
jyangballin/swesmith.x86_64.sqlfluff_1776_sqlfluff.50a1c4b6
true
null
1
27
36
1,029
0
0.6
1
0.75
1
0.2615
81.0595
6,311
swe_smith::train::24998
swe_smith
train
24,998
pylint-dev__astroid.b114f6b5.combine_file__7phy4f6m
swesmith/pylint-dev__astroid.b114f6b5
pylint-dev/astroid
python
null
Exception handling broken in ResolveError and MroError constructors #### Description The exception constructors for `ResolveError` and `MroError` are not properly handling their parameters, causing various inference and MRO-related operations to fail with `AttributeError` or `NameError` exceptions. #### Steps/Code t...
diff --git a/astroid/exceptions.py b/astroid/exceptions.py index 126acb9..47cae15 100644 --- a/astroid/exceptions.py +++ b/astroid/exceptions.py @@ -167,8 +167,8 @@ class ResolveError(AstroidError): def __init__( self, message: str = "", context: InferenceContext | None = None, **kws: Any ) -> None: ...
["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_mul...
["tests/brain/numpy/test_core_function_base.py::BrainNumpyCoreFunctionBaseTest::test_numpy_function_calls_inferred_as_ndarray", "tests/brain/numpy/test_core_multiarray.py::BrainNumpyCoreMultiarrayTest::test_numpy_function_calls_inferred_as_bool", "tests/brain/numpy/test_core_multiarray.py::BrainNumpyCoreMultiarrayTest:...
jyangballin/swesmith.x86_64.pylint-dev_1776_astroid.b114f6b5
true
null
1
12
52
1,329
0
0.6
1
0.75
1
0.2615
81.0595
6,312
swe_smith::train::31445
swe_smith
train
31,445
benoitc__gunicorn.bacbf8aa.combine_module__occh34tv
swesmith/benoitc__gunicorn.bacbf8aa
benoitc/gunicorn
python
null
ChunkedReader initialization fails with string buffer #### Description When initializing ChunkedReader, the buffer is incorrectly initialized with a string instead of bytes, causing TypeError when trying to process chunked HTTP requests. #### Steps/Code to Reproduce ```python from gunicorn.http.body import ChunkedR...
diff --git a/gunicorn/http/body.py b/gunicorn/http/body.py index d7ee29e..a18bee4 100644 --- a/gunicorn/http/body.py +++ b/gunicorn/http/body.py @@ -11,9 +11,9 @@ from gunicorn.http.errors import (NoMoreData, ChunkMissingTerminator, class ChunkedReader: def __init__(self, req, unreader): - self.req = req...
["tests/test_http.py::test_readline_zero_size", "tests/test_http.py::test_readline_new_line_before_size", "tests/test_http.py::test_readline_new_line_after_size", "tests/test_http.py::test_readline_no_new_line", "tests/test_http.py::test_readline_buffer_loaded", "tests/test_http.py::test_readline_buffer_loaded_with_siz...
["tests/test_arbiter.py::test_arbiter_stop_closes_listeners", "tests/test_arbiter.py::test_arbiter_stop_child_does_not_unlink_listeners", "tests/test_arbiter.py::test_arbiter_stop_parent_does_not_unlink_listeners", "tests/test_arbiter.py::test_arbiter_stop_does_not_unlink_systemd_listeners", "tests/test_arbiter.py::tes...
jyangballin/swesmith.x86_64.benoitc_1776_gunicorn.bacbf8aa
true
null
2
25
55
1,069
0
0.6
1
0.75
1
0.2615
81.0595
6,313
swe_smith::train::9398
swe_smith
train
9,398
jaraco__inflect.c079a96a.lm_rewrite__ciewwy3k
swesmith/jaraco__inflect.c079a96a
jaraco/inflect
python
null
Handling of compound words and prepositional phrases broken After updating to the latest version, I'm encountering issues with compound words and prepositional phrases. The inflect library is no longer correctly handling these cases. Example Code: ```python import inflect p = inflect.engine() # These all fail with ...
diff --git a/inflect/__init__.py b/inflect/__init__.py index 3eef486..6eb8108 100644 --- a/inflect/__init__.py +++ b/inflect/__init__.py @@ -2991,17 +2991,20 @@ class engine: >>> engine._handle_prepositional_phrase("man of war", str.upper, ' ') 'MAN of war' """ - parts = phrase.split(s...
["tests/test_compounds.py::test_compound_1", "tests/test_compounds.py::test_compound_2", "tests/test_compounds.py::test_compound_3", "tests/test_compounds.py::test_compound_4"]
["inflect/__init__.py::inflect.bysize", "inflect/__init__.py::inflect.engine._handle_long_compounds", "inflect/__init__.py::inflect.engine._handle_prepositional_phrase", "inflect/__init__.py::inflect.engine.compare", "inflect/__init__.py::inflect.engine.ordinal", "inflect/__init__.py::inflect.engine.singular_noun", "in...
jyangballin/swesmith.x86_64.jaraco_1776_inflect.c079a96a
true
null
1
25
4
1,069
0
0.6
1
0.75
1
0.2615
81.0595
6,314
swe_smith::train::21826
swe_smith
train
21,826
life4__textdistance.c3aca916.combine_module__3mnyuz7e
swesmith/life4__textdistance.c3aca916
life4/textdistance
python
null
Text distance algorithms returning incorrect results #### Description Several text distance algorithms are producing unexpected results. The bag distance algorithm is returning 3 instead of 0 for identical strings, and other token-based algorithms like Jaccard, Cosine, and Overlap are also failing to compute correct ...
diff --git a/textdistance/algorithms/base.py b/textdistance/algorithms/base.py index 5ce8cc7..ff14a2a 100644 --- a/textdistance/algorithms/base.py +++ b/textdistance/algorithms/base.py @@ -145,9 +145,9 @@ class Base: return intersection def _union_counters(self, *sequences: Counter[T]) -> Counter[T]: - ...
["tests/test_common.py::test_normalization_range[alg10]", "tests/test_common.py::test_normalization_by_one[alg10]", "tests/test_common.py::test_normalization_same[alg0]", "tests/test_common.py::test_normalization_monotonic[alg10]", "tests/test_common.py::test_no_common_chars[alg10]", "tests/test_common.py::test_unequal...
["tests/test_common.py::test_normalization_range[alg0]", "tests/test_common.py::test_normalization_range[alg1]", "tests/test_common.py::test_normalization_range[alg2]", "tests/test_common.py::test_normalization_range[alg3]", "tests/test_common.py::test_normalization_range[alg4]", "tests/test_common.py::test_normalizati...
jyangballin/swesmith.x86_64.life4_1776_textdistance.c3aca916
true
null
2
22
22
1,128
0
0.6
1
0.75
1
0.261333
81.059
6,315
swe_smith::train::9957
swe_smith
train
9,957
google__textfsm.c31b6007.combine_file__bgk6tlx2
swesmith/google__textfsm.c31b6007
google/textfsm
python
null
CliTable methods return incorrect values after recent changes #### Description After some recent changes to the CliTable class, several methods are now returning unexpected values or raising TypeErrors. The issue appears to be related to how the decorator wrapper function handles return values and method calls. ####...
diff --git a/textfsm/clitable.py b/textfsm/clitable.py index c7ad7a7..4dc3812 100755 --- a/textfsm/clitable.py +++ b/textfsm/clitable.py @@ -180,11 +180,12 @@ class CliTable(texttable.TextTable): # pylint: disable=E0213 def Wrapper(main_obj, *args, **kwargs): - main_obj._lock.acquire() # pylint: disab...
["tests/clitable_test.py::UnitTestCliTable::testAddKey", "tests/clitable_test.py::UnitTestCliTable::testCliCompile", "tests/clitable_test.py::UnitTestCliTable::testCompletion", "tests/clitable_test.py::UnitTestCliTable::testCopy", "tests/clitable_test.py::UnitTestCliTable::testKeyValue", "tests/clitable_test.py::UnitTe...
["tests/clitable_test.py::UnitTestIndexTable::testCopy", "tests/clitable_test.py::UnitTestIndexTable::testGetRowMatch", "tests/clitable_test.py::UnitTestIndexTable::testParseIndex", "tests/terminal_test.py::TerminalTest::testAnsiCmd", "tests/terminal_test.py::TerminalTest::testAnsiText", "tests/terminal_test.py::Termin...
jyangballin/swesmith.x86_64.google_1776_textfsm.c31b6007
true
null
1
17
14
1,228
0
0.6
1
0.75
1
0.261333
81.059
6,316
swe_smith::train::12800
swe_smith
train
12,800
python-openxml__python-docx.0cf6d71f.combine_file__9dxwven8
swesmith/python-openxml__python-docx.0cf6d71f
python-openxml/python-docx
python
null
TabStops object initialization broken - accessing tab stops fails #### Description When working with TabStops objects, accessing individual tab stops by index or iterating over them fails with AttributeError. The TabStops object appears to be improperly initialized, causing all operations that depend on the internal ...
diff --git a/src/docx/text/tabstops.py b/src/docx/text/tabstops.py index 824085d..4957ec1 100644 --- a/src/docx/text/tabstops.py +++ b/src/docx/text/tabstops.py @@ -14,8 +14,9 @@ class TabStops(ElementProxy): """ def __init__(self, element): - super(TabStops, self).__init__(element, None) - se...
["tests/text/test_tabstops.py::DescribeTabStops::it_knows_its_length[len_fixture0]", "tests/text/test_tabstops.py::DescribeTabStops::it_knows_its_length[len_fixture1]", "tests/text/test_tabstops.py::DescribeTabStops::it_can_iterate_over_its_tab_stops[iter_fixture0]", "tests/text/test_tabstops.py::DescribeTabStops::it_c...
["tests/dml/test_color.py::DescribeColorFormat::it_knows_its_color_type[type_fixture0]", "tests/dml/test_color.py::DescribeColorFormat::it_knows_its_color_type[type_fixture1]", "tests/dml/test_color.py::DescribeColorFormat::it_knows_its_color_type[type_fixture2]", "tests/dml/test_color.py::DescribeColorFormat::it_knows...
jyangballin/swesmith.x86_64.python-openxml_1776_python-docx.0cf6d71f
true
null
1
9
23
1,388
0
0.6
1
0.75
1
0.261333
81.059
6,317
swe_smith::train::31887
swe_smith
train
31,887
davidhalter__parso.338a5760.func_basic__67mjrr7d
swesmith/davidhalter__parso.338a5760
davidhalter/parso
python
null
Normalizer add_issue method broken after recent changes #### Description The normalizer's `add_issue` method seems to have some issues with parameter handling. When trying to parse Python code with syntax errors, I'm getting unexpected `AttributeError` and `TypeError` exceptions instead of proper error reporting. ##...
diff --git a/parso/normalizer.py b/parso/normalizer.py index a95f029..0617f3e 100644 --- a/parso/normalizer.py +++ b/parso/normalizer.py @@ -166,14 +166,14 @@ class Rule: return message def add_issue(self, node, code=None, message=None): - if code is None: + if code is not None: # Logical...
["parso/__init__.py::parso", "test/test_normalizer_issues_files.py::test_normalizer_issue[E27.py]", "test/test_normalizer_issues_files.py::test_normalizer_issue[E12_not_second.py]", "test/test_normalizer_issues_files.py::test_normalizer_issue[allowed_syntax.py]", "test/test_python_errors.py::test_python_exception_match...
["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_used_update[False-False]", "...
jyangballin/swesmith.x86_64.davidhalter_1776_parso.338a5760
true
null
1
8
44
1,408
0
0.6
1
0.75
1
0.261333
81.059
6,318
swe_smith::train::9974
swe_smith
train
9,974
google__textfsm.c31b6007.func_basic__4x3xqv1w
swesmith/google__textfsm.c31b6007
google/textfsm
python
null
# Indentation error in KeyValue method breaks table sorting and key value retrieval ## Description There appears to be an indentation error in the `KeyValue` method in `clitable.py`. The method is defined at the module level instead of as a class method, causing issues when trying to access it through a `CliTable` in...
diff --git a/textfsm/clitable.py b/textfsm/clitable.py index c7ad7a7..8596f53 100755 --- a/textfsm/clitable.py +++ b/textfsm/clitable.py @@ -388,20 +388,20 @@ class CliTable(texttable.TextTable): sorted_list.append(header) return sorted_list - def KeyValue(self, row=None): +def KeyValue(self, row=None)...
["tests/clitable_test.py::UnitTestCliTable::testKeyValue", "tests/clitable_test.py::UnitTestCliTable::testTableSort"]
["tests/clitable_test.py::UnitTestIndexTable::testCopy", "tests/clitable_test.py::UnitTestIndexTable::testGetRowMatch", "tests/clitable_test.py::UnitTestIndexTable::testParseIndex", "tests/clitable_test.py::UnitTestCliTable::testAddKey", "tests/clitable_test.py::UnitTestCliTable::testCliCompile", "tests/clitable_test.p...
jyangballin/swesmith.x86_64.google_1776_textfsm.c31b6007
true
null
1
10
2
1,368
0
0.6
1
0.75
1
0.261333
81.059
6,319
swe_smith::train::29634
swe_smith
train
29,634
django__channels.a144b4b8.lm_rewrite__ewpl2a1m
swesmith/django__channels.a144b4b8
django/channels
python
null
TypeError when using URLRouter with non-URLResolver instances Description After updating the URLRouter class, it seems that the new implementation requires all routes to be instances of URLResolver. This change has introduced a TypeError when non-URLResolver instances are passed to the URLRouter. The error message in...
diff --git a/channels/routing.py b/channels/routing.py index f48c4d3..1a67990 100644 --- a/channels/routing.py +++ b/channels/routing.py @@ -67,27 +67,14 @@ class URLRouter: _path_routing = True def __init__(self, routes): + """ + Takes a list of Django URL patterns. + """ self...
["tests/test_testing.py::test_websocket_application", "tests/test_routing.py::test_url_router", "tests/test_routing.py::test_url_router_nesting", "tests/test_routing.py::test_url_router_nesting_path", "tests/test_routing.py::test_url_router_path", "tests/test_routing.py::test_path_remaining", "tests/test_routing.py::te...
["tests/test_database.py::ConnectionClosingTests::test_http", "tests/test_database.py::ConnectionClosingTests::test_websocket", "tests/test_generic_websocket.py::test_websocket_consumer", "tests/test_generic_websocket.py::test_multiple_websocket_consumers_with_sessions", "tests/test_generic_websocket.py::test_websocket...
jyangballin/swesmith.x86_64.django_1776_channels.a144b4b8
true
null
1
25
7
1,068
0
0.6
1
0.75
1
0.261333
81.059
6,320
swe_smith::train::49054
swe_smith
train
49,054
facebookresearch__hydra.0f03eb60.pr_2200
swesmith/facebookresearch__hydra.0f03eb60
facebookresearch/hydra
python
null
# TargetConf no longer raises TypeError in Hydra 1.2 I noticed that the `TargetConf` class in `hydra/types.py` is not properly enforcing its deprecation policy. According to the documentation, `TargetConf` should be unsupported in Hydra 1.2, but it's not raising the expected error. ## Current Behavior When using Hyd...
diff --git a/hydra/types.py b/hydra/types.py index 0050a77..06abefd 100644 --- a/hydra/types.py +++ b/hydra/types.py @@ -5,8 +5,6 @@ from typing import TYPE_CHECKING, Any, Callable from omegaconf import MISSING -from hydra import version - from ._internal.deprecation_warning import deprecation_warning TaskFunc...
["tests/instantiate/test_instantiate.py::test_targetconf_disabled"]
["tests/instantiate/test_instantiate.py::test_class_instantiate[instantiate2-dict-class-not_recursive]", "tests/instantiate/test_instantiate.py::test_class_instantiate[instantiate2-dict-class-recursive]", "tests/instantiate/test_instantiate.py::test_class_instantiate[instantiate2-dict-class+partial-not_recursive]", "te...
jyangballin/swesmith.x86_64.facebookresearch_1776_hydra.0f03eb60
true
null
1
12
1
1,328
0
0.6
1
0.75
1
0.261333
81.059
6,321
swe_smith::train::48353
swe_smith
train
48,353
sqlfluff__sqlfluff.50a1c4b6.func_pm_remove_assign__80l3r3qw
swesmith/sqlfluff__sqlfluff.50a1c4b6
sqlfluff/sqlfluff
python
null
JinjaTemplater process_with_variants raises NameError for undefined variables #### Description When using the JinjaTemplater's `process_with_variants` method, a `NameError` is raised for undefined variables that should be accessible within the method scope. #### Steps/Code to Reproduce ```python from sqlfluff.core....
diff --git a/src/sqlfluff/core/templaters/jinja.py b/src/sqlfluff/core/templaters/jinja.py index 934ded3..203d51f 100644 --- a/src/sqlfluff/core/templaters/jinja.py +++ b/src/sqlfluff/core/templaters/jinja.py @@ -947,9 +947,6 @@ class JinjaTemplater(PythonTemplater): # those. variant_raw_str =...
["test/core/templaters/jinja_test.py::test__templater_lint_unreached_code[simple_if_true]", "test/core/templaters/jinja_test.py::test__templater_lint_unreached_code[simple_if_false]", "test/core/templaters/jinja_test.py::test__templater_lint_unreached_code[if_elif_else]", "test/core/templaters/jinja_test.py::test__temp...
["test/core/templaters/jinja_test.py::test__templater_jinja[simple]", "test/core/templaters/jinja_test.py::test__templater_jinja[unboundlocal_bugfix]", "test/core/templaters/jinja_test.py::test__templater_jinja_slices[basic_block]", "test/core/templaters/jinja_test.py::test__templater_jinja_slices[strip_left_block]", "...
jyangballin/swesmith.x86_64.sqlfluff_1776_sqlfluff.50a1c4b6
true
null
1
11
7
1,347
0
0.6
1
0.75
1
0.261167
81.0585
6,322
swe_smith::train::108
swe_smith
train
108
oauthlib__oauthlib.1fd52536.combine_file__obz0sc2v
swesmith/oauthlib__oauthlib.1fd52536
oauthlib/oauthlib
python
null
Grant type validation logic inverted causing authorization failures #### Description OAuth2 grant type validation is failing for valid clients due to inverted boolean logic in the validation check. When a client should be authorized to use a specific grant type, the system incorrectly raises an `UnauthorizedClientErr...
diff --git a/oauthlib/oauth2/rfc6749/grant_types/base.py b/oauthlib/oauth2/rfc6749/grant_types/base.py index d96a2db..5dfca2c 100644 --- a/oauthlib/oauth2/rfc6749/grant_types/base.py +++ b/oauthlib/oauth2/rfc6749/grant_types/base.py @@ -155,8 +155,8 @@ class GrantTypeBase: :type request: oauthlib.common.Reques...
["tests/oauth2/rfc6749/endpoints/test_client_authentication.py::ClientAuthenticationTest::test_basicauth_backend", "tests/oauth2/rfc6749/endpoints/test_client_authentication.py::ClientAuthenticationTest::test_basicauth_legacy", "tests/oauth2/rfc6749/endpoints/test_client_authentication.py::ClientAuthenticationTest::tes...
["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
12
167
1,327
0
0.6
1
0.75
1
0.261167
81.0585
6,323
swe_smith::train::5031
swe_smith
train
5,031
bottlepy__bottle.a8dfef30.lm_rewrite__9lbwn35v
swesmith/bottlepy__bottle.a8dfef30
bottlepy/bottle
python
null
RouteBuildError when building URL with non-integer value I encountered an issue when trying to build a URL using a named route with an integer filter. The URL construction fails with a `RouteBuildError` if a non-integer value is provided. Here's a minimal example to reproduce the issue: ```python from bottle import R...
diff --git a/bottle.py b/bottle.py index 286b5bc..77ef45a 100755 --- a/bottle.py +++ b/bottle.py @@ -447,16 +447,32 @@ class Router(object): def build(self, _name, *anons, **query): """ Build an URL by filling the wildcards in a rule. """ builder = self.builder.get(_name) - if not builder:...
["test/test_router.py::TestRouter::testBuildFilter", "test/test_router.py::TestRouterInCGIMode::testBuildFilter"]
["test/test_app.py::TestApplicationObject::test_setattr", "test/test_auth.py::TestBasicAuth::test__header", "test/test_config.py::TestConfDict::test_gc_overlays", "test/test_config.py::TestConfDict::test_isadict", "test/test_config.py::TestConfDict::test_load_dict", "test/test_config.py::TestConfDict::test_load_module"...
jyangballin/swesmith.x86_64.bottlepy_1776_bottle.a8dfef30
true
null
1
36
2
847
0
0.6
1
0.75
1
0.261167
81.0585
6,324
swe_smith::train::20166
swe_smith
train
20,166
kurtmckee__feedparser.cad965a3.lm_rewrite__kvel4jlk
swesmith/kurtmckee__feedparser.cad965a3
kurtmckee/feedparser
python
null
KeyError when parsing GML elements with missing 'where' context ### Description I've encountered an issue when parsing GML elements using the `feedparser` library. It seems that the recent changes to the `_parse_srs_attrs` method in `georss.py` are causing a `KeyError` when the 'where' context is not initialized befo...
diff --git a/feedparser/namespaces/georss.py b/feedparser/namespaces/georss.py index 5e9e958..507066e 100644 --- a/feedparser/namespaces/georss.py +++ b/feedparser/namespaces/georss.py @@ -83,17 +83,15 @@ class Namespace: _start_georss_where = _start_where def _parse_srs_attrs(self, attrs_d): - srs_n...
["tests/test_well_formed.py::test_strict_parser[info1160]", "tests/test_well_formed.py::test_loose_parser[info1162]", "tests/test_well_formed.py::test_loose_parser[info1165]", "tests/test_well_formed.py::test_strict_parser[info1162]", "tests/test_well_formed.py::test_loose_parser[info1160]", "tests/test_well_formed.py:...
["tests/test_temporary_behavior.py::test_issue_328_fallback_behavior", "tests/test_make_safe_absolute_uri.py::test_catch_value_error[http://bad]test/]", "tests/test_feedparser_dict.py::test_single_mapping_target_2", "tests/test_feedparser_dict.py::test_license", "tests/test_feedparser_dict.py::test_category", "tests/te...
jyangballin/swesmith.x86_64.kurtmckee_1776_feedparser.cad965a3
true
null
1
18
7
1,207
0
0.6
1
0.75
1
0.261167
81.0585
6,325
swe_bench::test::1522
swe_bench
test
1,522
scikit-learn__scikit-learn-10982
scikit-learn/scikit-learn
scikit-learn/scikit-learn
python
ca436e7017ae069a29de19caf71689e9b9b9c452
[RandomizedSearchCV] Do not enforce that n_iter is less than or equal to size of search space #### Description Instantiating `RandomizedSearchCV` with `n_iter` greater than the size of `param_distributions` (i.e. the product of the length of each distribution/array in the grid) will fail with an exception at [this lin...
I think it's safe enough to change this to a warning without a parameter. There are too many parameters in any case, and the warning can be turned into an error if the user wishes. On 1 April 2018 at 16:34, James Ko <notifications@github.com> wrote: > Description > > Instantiating RandomizedSearchCV with n_iter great...
diff --git a/sklearn/model_selection/_search.py b/sklearn/model_selection/_search.py --- a/sklearn/model_selection/_search.py +++ b/sklearn/model_selection/_search.py @@ -242,13 +242,16 @@ def __iter__(self): # look up sampled parameter settings in parameter grid param_grid = ParameterGrid(sel...
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 @@ -1385,10 +1385,18 @@ def test_grid_search_failing_classifier_raise(): def test_parameters_sampler_replace...
["sklearn/model_selection/tests/test_search.py::test_parameters_sampler_replacement"]
["sklearn/model_selection/tests/test_search.py::test_parameter_grid", "sklearn/model_selection/tests/test_search.py::test_grid_search", "sklearn/model_selection/tests/test_search.py::test_grid_search_with_fit_params", "sklearn/model_selection/tests/test_search.py::test_random_search_with_fit_params", "sklearn/model_sel...
null
true
2018-04-15T23:28:27Z
1
17
1
1,026
0
0.8
1
0.55
1
0.227667
81.058
6,326
swe_smith::train::20611
swe_smith
train
20,611
tobymao__sqlglot.036601ba.func_pm_ctrl_shuffle__bx442vqa
swesmith/tobymao__sqlglot.036601ba
tobymao/sqlglot
python
null
CTE parsing fails with UnboundLocalError #### Description When parsing SQL queries containing CTEs (Common Table Expressions), the parser raises an `UnboundLocalError: local variable 'cte' referenced before assignment`. This affects various SQL operations that use CTEs. #### Steps/Code to Reproduce ```python import...
diff --git a/sqlglot/parser.py b/sqlglot/parser.py index 248a128..c9bc5b3 100644 --- a/sqlglot/parser.py +++ b/sqlglot/parser.py @@ -3248,18 +3248,11 @@ class Parser(metaclass=_Parser): ) def _parse_cte(self) -> t.Optional[exp.CTE]: - index = self._index - - alias = self._parse_table_alias...
["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_quoting", "tests/dialects/test_bigquery.py::TestBigQuery::test_bigquery", "tests/dialects/test_bigquery.py::TestBigQuery::test_pushdown_cte_column_n...
["tests/dialects/test_athena.py::TestAthena::test_athena", "tests/dialects/test_athena.py::TestAthena::test_ctas", "tests/dialects/test_athena.py::TestAthena::test_dml", "tests/dialects/test_bigquery.py::TestBigQuery::test_annotate_timestamps", "tests/dialects/test_bigquery.py::TestBigQuery::test_convert", "tests/diale...
jyangballin/swesmith.x86_64.tobymao_1776_sqlglot.036601ba
true
null
1
29
85
986
0
0.6
1
0.75
1
0.261
81.058
6,327
swe_smith::train::52589
swe_smith
train
52,589
pydicom__pydicom.7d361b3d.func_pm_remove_cond__kinm1qak
swesmith/pydicom__pydicom.7d361b3d
pydicom/pydicom
python
null
EncapsulatedBuffer.seek() allows invalid operations without validation #### Description The `EncapsulatedBuffer.seek()` method is missing validation checks that should prevent invalid seek operations. Specifically, it no longer validates the `whence` parameter or prevents negative offset values when seeking from the ...
diff --git a/src/pydicom/encaps.py b/src/pydicom/encaps.py index 3493808..76f40a4 100644 --- a/src/pydicom/encaps.py +++ b/src/pydicom/encaps.py @@ -893,14 +893,9 @@ class EncapsulatedBuffer(BufferedIOBase): relative to the position indicated by `whence` and return the new absolute position. ...
["tests/test_encaps.py::TestEncapsulatedBuffer::test_seek_tell"]
["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
6
1
1,446
0
0.6
1
0.75
1
0.261
81.058
6,328
swe_smith::train::43718
swe_smith
train
43,718
sloria__environs.73c372df.func_pm_remove_cond__3liu6ama
swesmith/sloria__environs.73c372df
sloria/environs
python
null
# Bug: Environment variables not validated when missing ## Description I've discovered a bug in the `environs` package where environment variables that are not set are not being properly validated. This is causing unexpected behavior when using the deferred validation feature. ## Steps to reproduce ```python from e...
diff --git a/src/environs/__init__.py b/src/environs/__init__.py index 00f6072..b57d88a 100644 --- a/src/environs/__init__.py +++ b/src/environs/__init__.py @@ -184,21 +184,9 @@ def _func2method(func: typing.Callable[..., _T], method_name: str) -> typing.Any default: typing.Any = ma.missing, **kwargs,...
["tests/test_environs.py::TestCustomTypes::test_parser_for", "tests/test_environs.py::TestDeferredValidation::test_custom_parser_not_called_after_seal", "tests/test_environs.py::TestDeferredValidation::test_dj_db_url_with_deferred_validation_missing", "tests/test_environs.py::TestDeferredValidation::test_dj_email_url_w...
["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
13
6
1,306
0
0.6
1
0.75
1
0.261
81.058
6,329
swe_smith::train::39427
swe_smith
train
39,427
pallets__jinja.ada0a9a6.func_pm_ctrl_shuffle__1relab5k
swesmith/pallets__jinja.ada0a9a6
pallets/jinja
python
null
Parser initialization order causes AttributeError when accessing extensions #### Description When creating a Jinja2 parser, accessing the `extensions` attribute during initialization fails with an AttributeError. This appears to be related to the order of attribute initialization in the Parser constructor. #### Step...
diff --git a/src/jinja2/parser.py b/src/jinja2/parser.py index 817abec..27a8332 100644 --- a/src/jinja2/parser.py +++ b/src/jinja2/parser.py @@ -58,21 +58,20 @@ class Parser: filename: t.Optional[str] = None, state: t.Optional[str] = None, ) -> None: - self.environment = environment - ...
["tests/test_ext.py::TestExtensions::test_loop_controls", "tests/test_ext.py::TestExtensions::test_do", "tests/test_ext.py::TestExtensions::test_extension_nodes", "tests/test_ext.py::TestExtensions::test_contextreference_node_passes_context", "tests/test_ext.py::TestExtensions::test_contextreference_node_can_pass_local...
["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
17
39
1,226
0
0.6
1
0.75
1
0.261
81.058
6,330
swe_smith::train::28636
swe_smith
train
28,636
encode__starlette.db5063c2.func_basic__m3g83tv1
swesmith/encode__starlette.db5063c2
encode/starlette
python
null
TestClient constructor parameters inverted causing unexpected behavior #### Description When creating a TestClient, the `raise_server_exceptions` parameter is being inverted and the `root_path` parameter is getting an unwanted trailing slash appended. This causes server exceptions to be raised when they should be sup...
diff --git a/starlette/testclient.py b/starlette/testclient.py index 645ca10..b58bd94 100644 --- a/starlette/testclient.py +++ b/starlette/testclient.py @@ -237,11 +237,11 @@ class _TestClientTransport(httpx.BaseTransport): *, app_state: dict[str, typing.Any], ) -> None: - self.app = app -...
["tests/middleware/test_base.py::test_custom_middleware[asyncio]", "tests/middleware/test_base.py::test_read_request_stream_in_dispatch_after_app_calls_stream[asyncio]", "tests/middleware/test_base.py::test_read_request_stream_in_dispatch_after_app_calls_body[asyncio]", "tests/middleware/test_base.py::test_custom_middl...
["tests/middleware/test_base.py::test_state_data_across_multiple_middlewares[asyncio]", "tests/middleware/test_base.py::test_app_middleware_argument[asyncio]", "tests/middleware/test_base.py::test_fully_evaluated_response[asyncio]", "tests/middleware/test_base.py::test_contextvars[asyncio-CustomMiddlewareWithoutBaseHTT...
jyangballin/swesmith.x86_64.encode_1776_starlette.db5063c2
true
null
1
8
114
1,405
0
0.6
1
0.75
1
0.260833
81.0575
6,331
swe_smith::train::8905
swe_smith
train
8,905
pyupio__safety.7654596b.func_pm_remove_assign__3azerwwy
swesmith/pyupio__safety.7654596b
pyupio/safety
python
null
NameError in get_report_brief_info function after recent changes #### Description After recent changes to the `get_report_brief_info` function in `safety/output_utils.py`, several variables are being referenced but not defined, causing NameError exceptions when the function is called. #### Steps/Code to Reproduce `...
diff --git a/safety/output_utils.py b/safety/output_utils.py index 0ebb928..ee3c92b 100644 --- a/safety/output_utils.py +++ b/safety/output_utils.py @@ -899,14 +899,6 @@ def get_report_brief_info(as_dict: bool = False, report_type: int = 1, **kwargs: account = context.account key = context.key - db = con...
["tests/test_cli.py::TestSafetyCLI::test_announcements_if_is_not_tty", "tests/test_cli.py::TestSafetyCLI::test_basic_html_output_pass", "tests/test_cli.py::TestSafetyCLI::test_check_ignore_unpinned_requirements", "tests/test_cli.py::TestSafetyCLI::test_check_vulnerabilities_found_default", "tests/test_cli.py::TestSafet...
["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::test_check_with_fix_does_verify_api_key", "tests/test_cli.py::TestSafetyCLI::test_check_with_fix_only_works_with_files", "tests/test_cli...
jyangballin/swesmith.x86_64.pyupio_1776_safety.7654596b
true
null
1
21
9
1,145
0
0.6
1
0.75
1
0.260833
81.0575
6,332
swe_smith::train::34846
swe_smith
train
34,846
mozillazg__python-pinyin.e42dede5.lm_rewrite__dcat8xq7
swesmith/mozillazg__python-pinyin.e42dede5
mozillazg/python-pinyin
python
null
# TypeError when using custom style conversion in pypinyin ## Description When trying to convert Chinese characters to pinyin with a custom style, I'm getting a TypeError about multiple values for keyword argument 'default'. ## Steps to Reproduce ```python from pypinyin import pinyin, Style # Simple example that fa...
diff --git a/pypinyin/converter.py b/pypinyin/converter.py index 13c3bcf..98b28f9 100644 --- a/pypinyin/converter.py +++ b/pypinyin/converter.py @@ -101,23 +101,19 @@ class DefaultConverter(Converter): :return: 按拼音风格转换处理后的拼音 """ - pre_data = self.pre_convert_style( - han, orig_piny...
["tests/test_core_cls.py::test_to_fixed_for_compatibly"]
["pypinyin/core.py::pypinyin.core.lazy_pinyin", "pypinyin/core.py::pypinyin.core.pinyin", "pypinyin/core.py::pypinyin.core.slug", "pypinyin/style/_tone_convert.py::pypinyin.style._tone_convert.to_finals", "pypinyin/style/_tone_convert.py::pypinyin.style._tone_convert.to_finals_tone", "pypinyin/style/_tone_convert.py::p...
jyangballin/swesmith.x86_64.mozillazg_1776_python-pinyin.e42dede5
true
null
1
24
1
1,085
0
0.6
1
0.75
1
0.260833
81.0575
6,333
swe_smith::train::44343
swe_smith
train
44,343
pydata__patsy.a5d16484.func_pm_ctrl_shuffle__p93vnmwg
swesmith/pydata__patsy.a5d16484
pydata/patsy
python
null
`demo_data` function is broken ```python In [1]: from patsy.user_util import demo_data ...: data = demo_data("a", "b", "x") UnboundLocalError: local variable 'balanced_design_size' referenced before assignment ``` The issue is in the `demo_data` function where the code execution order has been rearranged. The fun...
diff --git a/patsy/user_util.py b/patsy/user_util.py index 080af84..9a5be6e 100644 --- a/patsy/user_util.py +++ b/patsy/user_util.py @@ -92,6 +92,18 @@ def test_balanced(): def demo_data(*names, **kwargs): + if kwargs: + raise TypeError("unexpected keyword arguments %r" % (kwargs,)) + for name in sort...
["patsy/user_util.py::test_demo_data"]
["patsy/build.py::test__max_allowed_dim", "patsy/build.py::test__eval_factor_numerical", "patsy/build.py::test__eval_factor_categorical", "patsy/build.py::test__column_combinations", "patsy/build.py::test__subterm_column_names_iter_and__build_subterm", "patsy/build.py::test__factors_memorize", "patsy/build.py::test__ex...
jyangballin/swesmith.x86_64.pydata_1776_patsy.a5d16484
true
null
1
35
1
865
0
0.6
1
0.75
1
0.260833
81.0575
6,334
r2e_gym::train::4727
r2e_gym
train
4,727
numpy__2aab65415843c8a8c662ddb5d33536dc95671076
numpy
numpy/numpy
python
2aab65415843c8a8c662ddb5d33536dc95671076
**Title:** `linspace` Does Not Match `arange` Results for Equivalent Integer Parameters **Description:** When using `numpy.linspace` with integer parameters intended to replicate `numpy.arange` behavior, the resulting arrays do not match as expected. Specifically, `linspace` sometimes generates duplicate values and s...
diff --git a/numpy/core/function_base.py b/numpy/core/function_base.py --- a/numpy/core/function_base.py +++ b/numpy/core/function_base.py @@ -3,7 +3,7 @@ __all__ = ['logspace', 'linspace'] from . import numeric as _nx -from .numeric import array, result_type +from .numeric import array, result_type, NaN def l...
diff --git a/numpy/core/tests/test_function_base.py b/numpy/core/tests/test_function_base.py --- a/numpy/core/tests/test_function_base.py +++ b/numpy/core/tests/test_function_base.py @@ -1,7 +1,8 @@ from __future__ import division, absolute_import, print_function from numpy.testing import * -from numpy import logsp...
null
null
namanjain12/numpy_final:2aab65415843c8a8c662ddb5d33536dc95671076
true
null
1
44
null
1,397
0
0.75
1
0.6375
1
0.3795
81.05725
6,335
swe_smith::train::39834
swe_smith
train
39,834
tornadoweb__tornado.d5ac65c1.func_pm_remove_assign__04nr21m5
swesmith/tornadoweb__tornado.d5ac65c1
tornadoweb/tornado
python
null
IOStream connection close detection broken when read buffer is empty #### Description When an IOStream connection is closed by the remote peer and the read buffer is empty, the stream doesn't properly detect the connection closure. This causes read operations to hang indefinitely instead of raising a StreamClosedErro...
diff --git a/tornado/iostream.py b/tornado/iostream.py index dd2111e..b34f838 100644 --- a/tornado/iostream.py +++ b/tornado/iostream.py @@ -696,7 +696,6 @@ class BaseIOStream: if self.closed(): return if events & self.io_loop.ERROR: - self.error = self.get_fd_e...
["test_read_until_with_close_after_second_packet (tornado.test.iostream_test.TestIOStreamSSL)", "test_read_until_with_close_after_second_packet (tornado.test.iostream_test.TestIOStreamSSLContext)"]
["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
8
2
1,404
0
0.6
1
0.75
1
0.260667
81.057
6,336
swe_smith::train::32728
swe_smith
train
32,728
pydantic__pydantic.acb0f10f.func_pm_remove_loop__gtgrcvki
swesmith/pydantic__pydantic.acb0f10f
pydantic/pydantic
python
null
V1 validator signature validation removed causing unexpected behavior #### Description V1 validators with invalid signatures are no longer properly validated, allowing validators with unsupported parameters to be created without raising appropriate errors. #### Steps/Code to Reproduce ```python from pydantic import...
diff --git a/pydantic/_internal/_decorators_v1.py b/pydantic/_internal/_decorators_v1.py index 3427377..82c2d6e 100644 --- a/pydantic/_internal/_decorators_v1.py +++ b/pydantic/_internal/_decorators_v1.py @@ -68,26 +68,6 @@ def make_generic_v1_field_validator(validator: V1Validator) -> core_schema.WithI needs_va...
["tests/test_validators.py::test_v1_validator_deprecated", "tests/test_validators.py::test_v1_validator_signature_kwargs_not_allowed", "tests/test_validators.py::test_v1_validator_signature_kwargs1", "tests/test_validators.py::test_v1_validator_signature_kwargs2", "tests/test_validators.py::test_v1_validator_signature_...
["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
21
14
1,144
0
0.6
1
0.75
1
0.260667
81.057
6,337
swe_smith::train::634
swe_smith
train
634
oauthlib__oauthlib.1fd52536.func_basic__ub4ntmqq
swesmith/oauthlib__oauthlib.1fd52536
oauthlib/oauthlib
python
null
OpenID Connect implicit flow incorrectly accepts None nonce values #### Description The OpenID Connect implicit flow validation is not properly rejecting requests with `None` nonce values. According to the OpenID Connect specification, the nonce parameter is required for implicit flows, but the current validation log...
diff --git a/oauthlib/openid/connect/core/grant_types/implicit.py b/oauthlib/openid/connect/core/grant_types/implicit.py index a4fe604..4e44fc6 100644 --- a/oauthlib/openid/connect/core/grant_types/implicit.py +++ b/oauthlib/openid/connect/core/grant_types/implicit.py @@ -34,16 +34,16 @@ class ImplicitGrant(GrantTypeBa...
["tests/openid/connect/core/grant_types/test_implicit.py::OpenIDImplicitTest::test_required_nonce", "tests/openid/connect/core/grant_types/test_implicit.py::OpenIDImplicitNoAccessTokenTest::test_required_nonce"]
["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
6
2
1,444
0
0.6
1
0.75
1
0.260667
81.057
6,338
swe_smith::train::31284
swe_smith
train
31,284
scrapy__scrapy.35212ec5.func_pm_ctrl_shuffle__zve6d9v1
swesmith/scrapy__scrapy.35212ec5
scrapy/scrapy
python
null
`scrapy startproject` fails with NameError: name 'ignored_names' is not defined #### Description When running `scrapy startproject`, the command fails with a NameError because the variable `ignored_names` is referenced before it's defined in the `_copytree` method. #### Steps/Code to Reproduce ```python import subp...
diff --git a/scrapy/commands/startproject.py b/scrapy/commands/startproject.py index 1adc153..73ae18f 100644 --- a/scrapy/commands/startproject.py +++ b/scrapy/commands/startproject.py @@ -59,20 +59,8 @@ class Command(ScrapyCommand): return False def _copytree(self, src: Path, dst: Path) -> None: - ...
["tests/test_commands.py::StartprojectTest::test_existing_project_dir", "tests/test_commands.py::StartprojectTest::test_startproject", "tests/test_commands.py::StartprojectTest::test_startproject_with_project_dir", "tests/test_commands.py::StartprojectTemplatesTest::test_startproject_permissions_from_read_only", "tests...
["tests/test_commands.py::CommandSettings::test_help_formatter", "tests/test_commands.py::CommandSettings::test_settings_json_string", "tests/test_commands.py::GenspiderStandaloneCommandTest::test_generate_standalone_spider", "tests/test_commands.py::GenspiderStandaloneCommandTest::test_same_name_as_existing_file", "te...
jyangballin/swesmith.x86_64.scrapy_1776_scrapy.35212ec5
true
null
1
25
52
1,064
0
0.6
1
0.75
1
0.260667
81.057
6,339
swe_smith::train::24429
swe_smith
train
24,429
sunpy__sunpy.f8edfd5c.lm_rewrite__na0jljgu
swesmith/sunpy__sunpy.f8edfd5c
sunpy/sunpy
python
null
### Bug report **Bug summary** There seems to be an issue with the coordinate frame representation in SunPy. When using certain frames, the distance calculations are not behaving as expected, leading to unit conversion errors. **Code for reproduction** Here's a minimal example to reproduce the issue: ```python from...
diff --git a/sunpy/coordinates/frames.py b/sunpy/coordinates/frames.py index 8e1efd5..97a5b1a 100644 --- a/sunpy/coordinates/frames.py +++ b/sunpy/coordinates/frames.py @@ -174,9 +174,13 @@ class SunPyBaseCoordinateFrame(BaseCoordinateFrame): @property def _is_2d(self): - return (self._data is not No...
["sunpy/coordinates/tests/test_frames.py::test_hpr_distance", "sunpy/coordinates/tests/test_frames.py::test_skycoord_hpc[args3-kwargs3]", "sunpy/coordinates/tests/test_frames.py::test_skycoord_hpc[args4-kwargs4]", "sunpy/coordinates/tests/test_frames.py::test_skycoord_hpc[args5-kwargs5]"]
["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
10
4
1,364
0
0.6
1
0.75
1
0.260667
81.057
6,340
swe_smith::train::23415
swe_smith
train
23,415
pyparsing__pyparsing.533adf47.combine_file__v85k9sj4
swesmith/pyparsing__pyparsing.533adf47
pyparsing/pyparsing
python
null
ParseException error location and message formatting broken #### Description ParseException is reporting incorrect character positions and has garbled error message formatting. The error location seems to be off by one, and the column/character position information in error messages is swapped. #### Steps/Code to Re...
diff --git a/pyparsing/exceptions.py b/pyparsing/exceptions.py index 57a1579..4969f1a 100644 --- a/pyparsing/exceptions.py +++ b/pyparsing/exceptions.py @@ -54,13 +54,13 @@ class ParseBaseException(Exception): elem=None, ): if msg is None: - msg, pstr = pstr, "" + pstr, msg ...
["tests/test_simple_unit.py::TestLiteral::runTest", "tests/test_simple_unit.py::TestRepetition::runTest", "tests/test_simple_unit.py::TestWhitespaceMethods::runTest", "tests/test_unit.py::Test02_WithoutPackrat::testEachWithParseFatalException", "tests/test_unit.py::Test02_WithoutPackrat::testEnableDebugOnExpressionWith...
["examples/test_bibparse.py::TestBibparse::test_bib1", "examples/test_bibparse.py::TestBibparse::test_bibfile", "examples/test_bibparse.py::TestBibparse::test_comments", "examples/test_bibparse.py::TestBibparse::test_entry", "examples/test_bibparse.py::TestBibparse::test_macro", "examples/test_bibparse.py::TestBibparse...
jyangballin/swesmith.x86_64.pyparsing_1776_pyparsing.533adf47
true
null
1
12
79
1,324
0
0.6
1
0.75
1
0.260667
81.057
6,341
swe_smith::train::49426
swe_smith
train
49,426
mozilla__bleach.73871d76.func_pm_ctrl_invert_if__vivlyneb
swesmith/mozilla__bleach.73871d76
mozilla/bleach
python
null
# HTML elements in foreign content (SVG/MathML) not properly handled ## Description When using HTML elements inside SVG or MathML content, the parser is incorrectly handling these elements. This creates a security vulnerability where certain HTML elements inside SVG or MathML tags aren't properly sanitized. ## Steps...
diff --git a/bleach/_vendor/html5lib/html5parser.py b/bleach/_vendor/html5lib/html5parser.py index 5427b7d..2807141 100644 --- a/bleach/_vendor/html5lib/html5parser.py +++ b/bleach/_vendor/html5lib/html5parser.py @@ -2487,16 +2487,6 @@ def getPhases(debug): if (token["name"] in self.breakoutElements or ...
["tests/test_clean.py::test_svg_attr_val_allows_ref"]
["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
20
1
1,164
0
0.6
1
0.75
1
0.260667
81.057
6,342
swe_smith::train::42807
swe_smith
train
42,807
python-jsonschema__jsonschema.93e0caa5.lm_rewrite__2qmnnsx1
swesmith/python-jsonschema__jsonschema.93e0caa5
python-jsonschema/jsonschema
python
null
### Bug: Incorrect JSON Path Representation in ValidationError #### Description After the recent changes, the `json_path` property in the `ValidationError` class is not generating the expected JSON path format. The current implementation returns a JSON pointer format instead of the expected dot notation path. #### S...
diff --git a/jsonschema/exceptions.py b/jsonschema/exceptions.py index 3dcd296..4283a12 100644 --- a/jsonschema/exceptions.py +++ b/jsonschema/exceptions.py @@ -147,15 +147,16 @@ class _Error(Exception): return path @property - def json_path(self) -> str: - path = "$" - for elem in self...
["jsonschema/tests/test_validators.py::TestValidationErrorDetails::test_additionalItems", "jsonschema/tests/test_validators.py::TestValidationErrorDetails::test_additionalItems_with_items", "jsonschema/tests/test_validators.py::TestValidationErrorDetails::test_additionalProperties", "jsonschema/tests/test_validators.py...
["jsonschema/tests/test_cli.py::TestCLI::test_custom_error_format", "jsonschema/tests/test_cli.py::TestCLI::test_custom_error_format_applies_to_schema_errors", "jsonschema/tests/test_cli.py::TestCLI::test_instance_does_not_exist", "jsonschema/tests/test_cli.py::TestCLI::test_instance_does_not_exist_pretty_output", "jso...
jyangballin/swesmith.x86_64.python-jsonschema_1776_jsonschema.93e0caa5
true
null
1
19
20
1,183
0
0.6
1
0.75
1
0.2605
81.0565
6,343
swe_smith::train::1700
swe_smith
train
1,700
agronholm__typeguard.b6a7e438.combine_module__72dmf0wo
swesmith/agronholm__typeguard.b6a7e438
agronholm/typeguard
python
null
NameError when using typechecked decorator #### Description When using the `@typechecked` decorator, functions fail with `NameError` for undefined variables like `module_code`, `value`, and `closure`. This appears to affect the instrumentation process that adds runtime type checking to decorated functions. #### Step...
diff --git a/src/typeguard/_decorators.py b/src/typeguard/_decorators.py index a6c20cb..5f0666a 100644 --- a/src/typeguard/_decorators.py +++ b/src/typeguard/_decorators.py @@ -73,8 +73,6 @@ def instrument(f: T_CallableOrType) -> FunctionType | str: if not instrumentor.target_node or instrumentor.target_lineno i...
["tests/test_checkers.py::TestAnyStr::test_bad_type", "tests/test_checkers.py::TestBytesLike::test_fail", "tests/test_checkers.py::TestFloat::test_bad_type", "tests/test_checkers.py::TestComplexNumber::test_bad_type", "tests/test_checkers.py::TestCallable::test_bad_type", "tests/test_checkers.py::TestCallable::test_too...
["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::TestBytesLike::test_valid[bytes]", "tests/test_checkers.py::TestBytesLike:...
jyangballin/swesmith.x86_64.agronholm_1776_typeguard.b6a7e438
true
null
2
26
200
1,043
0
0.6
1
0.75
1
0.2605
81.0565
6,344
swe_smith::train::28425
swe_smith
train
28,425
encode__starlette.db5063c2.combine_module__dr2ku83e
swesmith/encode__starlette.db5063c2
encode/starlette
python
null
ExceptionMiddleware debug flag inverted and handlers swapped When initializing ExceptionMiddleware, the debug flag behavior is inverted and exception handlers are incorrectly swapped. This causes unexpected behavior in error handling and debug mode functionality. #### Steps/Code to Reproduce ```python from starlette...
diff --git a/starlette/middleware/errors.py b/starlette/middleware/errors.py index 76ad776..178c00c 100644 --- a/starlette/middleware/errors.py +++ b/starlette/middleware/errors.py @@ -257,4 +257,4 @@ class ServerErrorMiddleware: return PlainTextResponse(content, status_code=500) def error_response(self...
["tests/middleware/test_base.py::test_fully_evaluated_response[asyncio]", "tests/middleware/test_base.py::test_fully_evaluated_response[trio]", "tests/test_applications.py::test_400[asyncio]", "tests/test_applications.py::test_websocket_raise_websocket_exception[asyncio]", "tests/test_applications.py::test_websocket_ra...
["tests/middleware/test_base.py::test_custom_middleware[asyncio]", "tests/middleware/test_base.py::test_state_data_across_multiple_middlewares[asyncio]", "tests/middleware/test_base.py::test_app_middleware_argument[asyncio]", "tests/middleware/test_base.py::test_contextvars[asyncio-CustomMiddlewareWithoutBaseHTTPMiddle...
jyangballin/swesmith.x86_64.encode_1776_starlette.db5063c2
true
null
2
10
60
1,363
0
0.6
1
0.75
1
0.2605
81.0565
6,345
swe_smith::train::24055
swe_smith
train
24,055
sunpy__sunpy.f8edfd5c.func_pm_ctrl_shuffle__oh4a8f7q
swesmith/sunpy__sunpy.f8edfd5c
sunpy/sunpy
python
null
MapSequence animation fails with UnboundLocalError when using clip_interval #### Description When creating animations from MapSequence with `clip_interval` parameter, the animation fails with `UnboundLocalError: cannot access local variable 'norm' where it is not associated with value`. #### Steps/Code to Reproduce ...
diff --git a/sunpy/map/mapsequence.py b/sunpy/map/mapsequence.py index c875ad6..c5a7e5a 100644 --- a/sunpy/map/mapsequence.py +++ b/sunpy/map/mapsequence.py @@ -362,28 +362,27 @@ class MapSequence: im = ani_data[0].plot(axes=axes, **kwargs) def updatefig(i, im, annotate, ani_data, removes): - ...
["sunpy/map/tests/test_mapsequence.py::test_mapsequence_plot_uint8_norm_clip_interval", "sunpy/map/tests/test_mapsequence.py::test_mapsequence_plot_set_norm_pass_vmin_vmax"]
["sunpy/map/tests/test_mapsequence.py::test_deprecations", "sunpy/map/tests/test_mapsequence.py::test_as_array_different_shapes", "sunpy/map/tests/test_mapsequence.py::test_as_array_no_masks", "sunpy/map/tests/test_mapsequence.py::test_as_array_all_masks", "sunpy/map/tests/test_mapsequence.py::test_as_array_some_masks"...
jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c
true
null
1
19
2
1,183
0
0.6
1
0.75
1
0.2605
81.0565
6,346
swe_smith::train::2065
swe_smith
train
2,065
pdfminer__pdfminer.six.1a8bd2f7.func_basic__5l4ptru2
swesmith/pdfminer__pdfminer.six.1a8bd2f7
pdfminer/pdfminer.six
python
null
PSParser number parsing broken after recent changes #### Description The PSParser is failing to parse numbers correctly, causing widespread failures across PDF processing. When parsing numeric tokens, the parser appears to be returning incorrect values or types, leading to TypeError exceptions throughout the codebase...
diff --git a/pdfminer/psparser.py b/pdfminer/psparser.py index b486956..012a1ce 100755 --- a/pdfminer/psparser.py +++ b/pdfminer/psparser.py @@ -382,15 +382,15 @@ class PSBaseParser: m = END_NUMBER.search(s, i) if not m: self._curtoken += s[i:] - return len(s) - j = m.st...
["tests/test_converter.py::TestPaintPath::test_paint_path_quadrilaterals", "tests/test_converter.py::TestColorSpace::test_do_rg", "tests/test_font_size.py::test_font_size", "tests/test_highlevel_extracttext.py::TestExtractText::test_issue_495_pdfobjref_iterable", "tests/test_highlevel_extracttext.py::TestExtractText::t...
["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_beziers", "tests/test_converter.py::TestPaintPath::test_paint_pa...
jyangballin/swesmith.x86_64.pdfminer_1776_pdfminer.six.1a8bd2f7
true
null
1
12
53
1,323
0
0.6
1
0.75
1
0.2605
81.0565
6,347
swe_smith::train::44958
swe_smith
train
44,958
mahmoud__glom.fb3c4e76.func_pm_ctrl_shuffle__ws6jhs71
swesmith/mahmoud__glom.fb3c4e76
mahmoud/glom
python
null
flatten() function broken due to variable reference before assignment #### Description The `flatten()` function in `glom/reduction.py` is currently broken and raises an `UnboundLocalError` when called. The function tries to use variables before they are defined. #### Steps/Code to Reproduce ```python from glom.redu...
diff --git a/glom/reduction.py b/glom/reduction.py index b400ce0..e83db7a 100644 --- a/glom/reduction.py +++ b/glom/reduction.py @@ -187,6 +187,21 @@ class Flatten(Fold): def flatten(target, **kwargs): + if levels < 0: + raise ValueError('expected levels >= 0, not %r' % levels) + if kwargs: + r...
["glom/test/test_reduction.py::test_flatten_func"]
["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
31
1
942
0
0.6
1
0.75
1
0.260333
81.056
6,348
swe_smith::train::45157
swe_smith
train
45,157
modin-project__modin.8c7799fd.func_pm_remove_assign__kx3vab5j
swesmith/modin-project__modin.8c7799fd
modin-project/modin
python
null
# String data processing in DataFrame Protocol is broken ## Description There appears to be an issue with the string column processing in the DataFrame Protocol implementation. When working with string data, especially categorical data, the conversion process fails due to missing variable definitions and improper han...
diff --git a/modin/core/dataframe/pandas/interchange/dataframe_protocol/from_dataframe.py b/modin/core/dataframe/pandas/interchange/dataframe_protocol/from_dataframe.py index b7cd9de..b0f3dee 100644 --- a/modin/core/dataframe/pandas/interchange/dataframe_protocol/from_dataframe.py +++ b/modin/core/dataframe/pandas/inte...
["modin/tests/interchange/dataframe_protocol/pandas/test_protocol.py::test_categorical_from_dataframe"]
["modin/tests/interchange/dataframe_protocol/base/test_sanity.py::test_sanity", "modin/tests/interchange/dataframe_protocol/base/test_sanity.py::test_basic_io", "modin/tests/interchange/dataframe_protocol/base/test_utils.py::test_dtype_to_arrow_c[pandas_dtype0-b]", "modin/tests/interchange/dataframe_protocol/base/test_...
jyangballin/swesmith.x86_64.modin-project_1776_modin.8c7799fd
true
null
1
12
1
1,322
0
0.6
1
0.75
1
0.260333
81.056
6,349
swe_smith::train::44648
swe_smith
train
44,648
mahmoud__glom.fb3c4e76.func_basic__6iswtet8
swesmith/mahmoud__glom.fb3c4e76
mahmoud/glom
python
null
S() constructor signature changed unexpectedly #### Description The `S()` constructor now requires positional arguments instead of keyword arguments, breaking existing code that uses `S()` with keyword arguments. #### Steps/Code to Reproduce ```python from glom import S, T, glom # This used to work but now fails t...
diff --git a/glom/core.py b/glom/core.py index cee71a3..6f149fe 100644 --- a/glom/core.py +++ b/glom/core.py @@ -1438,12 +1438,12 @@ class TType: def __call__(self, *args, **kwargs): if self is S: - if args: - raise TypeError(f'S() takes no positional arguments, got: {args!r}')...
["glom/test/test_basic.py::test_call_and_target", "glom/test/test_basic.py::test_python_native", "glom/test/test_check.py::test_check_basic", "glom/test/test_cli.py::test_main_python_full_spec_python_target", "glom/test/test_grouping.py::test_corner_cases", "glom/test/test_match.py::test_pattern_matching", "glom/test/t...
["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
10
17
1,361
0
0.6
1
0.75
1
0.260167
81.0555
6,350
swe_smith::train::36649
swe_smith
train
36,649
lincolnloop__python-qrcode.456b01d4.func_pm_class_rm_funcs__i2sijd4c
swesmith/lincolnloop__python-qrcode.456b01d4
lincolnloop/python-qrcode
python
null
PilImage.new_image method missing causes AttributeError when creating QR codes When trying to create QR codes using the PIL image factory, I'm getting an AttributeError because the `new_image` method is missing from the PilImage class. #### Steps/Code to Reproduce ```python import qrcode # Basic QR code creation fa...
diff --git a/qrcode/image/pil.py b/qrcode/image/pil.py index 57ee13a..67c3925 100644 --- a/qrcode/image/pil.py +++ b/qrcode/image/pil.py @@ -9,40 +9,6 @@ class PilImage(qrcode.image.base.BaseImage): kind = "PNG" - def new_image(self, **kwargs): - if not Image: - raise ImportError("PIL libr...
["qrcode/tests/test_example.py::test_example", "qrcode/tests/test_qrcode_pil.py::test_render_pil", "qrcode/tests/test_qrcode_pil.py::test_render_pil_background[TransParent]", "qrcode/tests/test_qrcode_pil.py::test_render_pil_background[red]", "qrcode/tests/test_qrcode_pil.py::test_render_pil_background[back_color2]", "...
["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_add_qrdata", "qrcode/tests/test_qrcode.py::test...
jyangballin/swesmith.x86_64.lincolnloop_1776_python-qrcode.456b01d4
true
null
1
36
13
841
0
0.6
1
0.75
1
0.260167
81.0555
6,351
swe_smith::train::48170
swe_smith
train
48,170
sqlfluff__sqlfluff.50a1c4b6.func_pm_ctrl_invert_if__w8e3m8ag
swesmith/sqlfluff__sqlfluff.50a1c4b6
sqlfluff/sqlfluff
python
null
# Parallel linting fails with DelayedException handling ## Bug description When running SQLFluff with parallel processing, it fails to properly handle exceptions. The issue is in the `ParallelRunner` class where the condition for handling `DelayedException` is reversed. When linting SQL files in parallel mode, the l...
diff --git a/src/sqlfluff/core/linter/runner.py b/src/sqlfluff/core/linter/runner.py index 3ebe1db..2ecc1bf 100644 --- a/src/sqlfluff/core/linter/runner.py +++ b/src/sqlfluff/core/linter/runner.py @@ -150,11 +150,6 @@ class ParallelRunner(BaseRunner): self.iter_partials(fnames, fix=fix), ...
["test/core/linter/linter_test.py::test__linter__linting_result_get_violations[2]", "test/core/linter/linter_test.py::test__linter__linting_parallel_thread[False]", "test/core/linter/linter_test.py::test__linter__linting_parallel_thread[True]"]
["test/core/linter/discovery_test.py::test__linter__path_from_paths__dir", "test/core/linter/discovery_test.py::test__linter__path_from_paths__default", "test/core/linter/discovery_test.py::test__linter__path_from_paths__exts", "test/core/linter/discovery_test.py::test__linter__path_from_paths__file", "test/core/linter...
jyangballin/swesmith.x86_64.sqlfluff_1776_sqlfluff.50a1c4b6
true
null
1
11
3
1,340
0
0.6
1
0.75
1
0.26
81.055
6,352
swe_smith::train::31388
swe_smith
train
31,388
benoitc__gunicorn.bacbf8aa.combine_file__lstvdl5x
swesmith/benoitc__gunicorn.bacbf8aa
benoitc/gunicorn
python
null
Config validation broken for list string values #### Description When setting configuration values that expect list strings, the validation is returning `None` instead of an empty list for empty values, causing `TypeError: 'NoneType' object is not iterable` errors throughout the application. #### Steps/Code to Repro...
diff --git a/gunicorn/config.py b/gunicorn/config.py index 402a26b..0fe9a1b 100644 --- a/gunicorn/config.py +++ b/gunicorn/config.py @@ -37,10 +37,9 @@ def make_settings(ignore=None): def auto_int(_, x): - # for compatible with octal numbers in python3 - if re.match(r'0(\d)', x, re.IGNORECASE): + if re.ma...
["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_callable_validation_for_string", "tests/test_http.py::test_method_pattern", "tests/test_http.py::test_readline_empty_body", "tests/test_http.py::test_readline_zero_size", "tests/test_http.py::test_readline_new_line_before_size", "tests/test_http.py::test_readline_new_line_after_size", "test...
jyangballin/swesmith.x86_64.benoitc_1776_gunicorn.bacbf8aa
true
null
1
16
170
1,240
0
0.6
1
0.75
1
0.26
81.055
6,353
swe_smith::train::51621
swe_smith
train
51,621
pydicom__pydicom.7d361b3d.combine_module__kg02aoks
swesmith/pydicom__pydicom.7d361b3d
pydicom/pydicom
python
null
Pixel data decoder validation logic inverted causing incorrect error messages #### Description The pixel data decoder validation is throwing errors when it should succeed and succeeding when it should throw errors. This affects both transfer syntax validation and pixel data element validation. #### Steps/Code to Rep...
diff --git a/src/pydicom/pixels/decoders/base.py b/src/pydicom/pixels/decoders/base.py index 268f0d4..320248a 100644 --- a/src/pydicom/pixels/decoders/base.py +++ b/src/pydicom/pixels/decoders/base.py @@ -650,7 +650,7 @@ class DecodeRunner(RunnerBase): file_meta = getattr(ds, "file_meta", {}) if tsy...
["tests/pixels/test_decoder_base.py::TestDecodeRunner::test_set_source_dataset", "tests/pixels/test_decoder_base.py::TestDecoder::test_buffer", "tests/pixels/test_encoder_base.py::TestDatasetCompress::test_compress_inplace", "tests/pixels/test_encoder_base.py::TestDatasetCompress::test_encapsulate_extended", "tests/pix...
["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
2
14
8
1,280
0
0.6
1
0.75
1
0.26
81.055
6,354
swe_smith::train::3445
swe_smith
train
3,445
pygments__pygments.27649ebb.combine_file__nwtu3cpo
swesmith/pygments__pygments.27649ebb
pygments/pygments
python
null
GroffFormatter broken after recent changes #### Description The GroffFormatter is completely broken and throws TypeError when trying to format code. It seems like there are issues with the class inheritance and internal data structures. #### Steps/Code to Reproduce ```python from pygments import highlight from pygm...
diff --git a/pygments/formatters/groff.py b/pygments/formatters/groff.py index a9e0711..191182e 100644 --- a/pygments/formatters/groff.py +++ b/pygments/formatters/groff.py @@ -15,7 +15,7 @@ from pygments.util import get_bool_opt, get_int_opt __all__ = ['GroffFormatter'] -class GroffFormatter(Formatter): +class Gr...
["tests/test_groff_formatter.py::test_inheritance_custom_tokens", "tests/test_groff_formatter.py::test_basic", "tests/test_basic_api.py::test_formatter_unicode_handling[GroffFormatter]", "tests/test_basic_api.py::test_formatter_public_api[GroffFormatter]"]
["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
30
4
960
0
0.6
1
0.75
1
0.26
81.055
6,355
swe_smith::train::10984
swe_smith
train
10,984
rsalmei__alive-progress.35853799.combine_file__kg17wlp0
swesmith/rsalmei__alive-progress.35853799
rsalmei/alive-progress
python
null
Configuration validation broken for boolean and float parameters #### Description The configuration system is not properly validating boolean and float parameters. Boolean values are being inverted and float validation is returning invalid values instead of rejecting them. #### Steps/Code to Reproduce ```python fro...
diff --git a/alive_progress/core/configuration.py b/alive_progress/core/configuration.py index b36d671..8bb01ac 100644 --- a/alive_progress/core/configuration.py +++ b/alive_progress/core/configuration.py @@ -16,13 +16,13 @@ ERROR = object() # represents a config value not accepted. def _spinner_input_factory(default...
["tests/core/test_configuration.py::test_bool_input_factory[False-False]", "tests/core/test_configuration.py::test_bool_input_factory[0-False]", "tests/core/test_configuration.py::test_bool_input_factory[-False]", "tests/core/test_configuration.py::test_bool_input_factory[None-False]", "tests/core/test_configuration.py...
["tests/animations/test_bars.py::test_bar_tip_background[--0.5-False-|0123456789|]", "tests/animations/test_bars.py::test_bar_tip_background[=--0.5-False-|0123456789|]", "tests/animations/test_bars.py::test_bar_tip_background[_-=--0.5-False-|0123456789|]", "tests/animations/test_bars.py::test_bar_tip_background[-0.0-Fa...
jyangballin/swesmith.x86_64.rsalmei_1776_alive-progress.35853799
true
null
1
14
88
1,279
0
0.6
1
0.75
1
0.259833
81.0545
6,356
swe_smith::train::40201
swe_smith
train
40,201
scanny__python-pptx.278b47b1.combine_file__sxj8sm76
swesmith/scanny__python-pptx.278b47b1
scanny/python-pptx
python
null
Chart point initialization parameters swapped causing AttributeError #### Description When accessing chart point properties like `format`, `marker`, or `data_label`, an AttributeError is raised due to incorrect parameter assignment during Point object initialization. #### Steps/Code to Reproduce ```python from pptx...
diff --git a/src/pptx/chart/point.py b/src/pptx/chart/point.py index 2d42436..99885b5 100644 --- a/src/pptx/chart/point.py +++ b/src/pptx/chart/point.py @@ -17,8 +17,8 @@ class _BasePoints(Sequence): def __init__(self, ser): super(_BasePoints, self).__init__() - self._element = ser - self....
["tests/chart/test_point.py::Describe_BasePoints::it_supports_indexed_access", "tests/chart/test_point.py::Describe_BasePoints::it_raises_on_indexed_access_out_of_range", "tests/chart/test_point.py::DescribeBubblePoints::it_supports_len[len_fixture0]", "tests/chart/test_point.py::DescribeBubblePoints::it_supports_len[l...
["tests/chart/test_axis.py::Describe_BaseAxis::it_provides_access_to_its_title[c:catAx]", "tests/chart/test_axis.py::Describe_BaseAxis::it_provides_access_to_its_title[c:dateAx]", "tests/chart/test_axis.py::Describe_BaseAxis::it_provides_access_to_its_title[c:valAx]", "tests/chart/test_axis.py::Describe_BaseAxis::it_pr...
jyangballin/swesmith.x86_64.scanny_1776_python-pptx.278b47b1
true
null
1
10
21
1,359
0
0.6
1
0.75
1
0.259833
81.0545
6,357
swe_smith::train::33025
swe_smith
train
33,025
pydantic__pydantic.acb0f10f.pr_9495
swesmith/pydantic__pydantic.acb0f10f
pydantic/pydantic
python
null
# Missing context parameter in TypeAdapter.dump and dump_json methods Previously, the TypeAdapter class had a `context` parameter in its `dump` and `dump_json` methods that allowed passing additional context to serializers. This parameter has been removed, breaking functionality for models that use context-aware seria...
diff --git a/pydantic/type_adapter.py b/pydantic/type_adapter.py index a6cdaba..6e60c8d 100644 --- a/pydantic/type_adapter.py +++ b/pydantic/type_adapter.py @@ -545,7 +545,6 @@ class TypeAdapter(Generic[T]): warnings: bool | Literal['none', 'warn', 'error'] = True, fallback: Callable[[Any], Any] | Non...
["tests/test_serialize.py::test_type_adapter_dump_with_context"]
["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
8
1
1,399
0
0.6
1
0.75
1
0.259833
81.0545
6,358
swe_smith::train::48555
swe_smith
train
48,555
sqlfluff__sqlfluff.50a1c4b6.func_pm_remove_wrapper__4xum16y1
swesmith/sqlfluff__sqlfluff.50a1c4b6
sqlfluff/sqlfluff
python
null
NameError: name 'res' is not defined in rule evaluation #### Description When running sqlfluff linting, encountering a `NameError: name 'res' is not defined` error during rule evaluation. This appears to be affecting multiple rules and causing the linter to fail. #### Steps/Code to Reproduce ```python from sqlfluff...
diff --git a/src/sqlfluff/core/rules/base.py b/src/sqlfluff/core/rules/base.py index 1f00fb3..af39ffd 100644 --- a/src/sqlfluff/core/rules/base.py +++ b/src/sqlfluff/core/rules/base.py @@ -519,43 +519,6 @@ class BaseRule(metaclass=RuleMetaclass): memory = root_context.memory context = root_context ...
["test/core/rules/docstring_test.py::test_backtick_replace", "test/core/rules/noqa_test.py::test__linter__raises_malformed_noqa", "test/core/rules/noqa_test.py::test_linter_noqa", "test/core/rules/noqa_test.py::test_linter_noqa_with_templating", "test/core/rules/noqa_test.py::test_linter_noqa_tmp", "test/core/rules/noq...
["test/core/rules/docstring_test.py::test_content_count[\\\\*\\\\*Anti-pattern\\\\*\\\\*-1]", "test/core/rules/docstring_test.py::test_keyword_anti_before_best", "test/core/rules/functional/raw_file_slices_test.py::test_slices_all[input0-True]", "test/core/rules/functional/raw_file_slices_test.py::test_slices_all[input...
jyangballin/swesmith.x86_64.sqlfluff_1776_sqlfluff.50a1c4b6
true
null
1
38
10
799
0
0.6
1
0.75
1
0.259833
81.0545
6,359
swe_bench::test::1731
swe_bench
test
1,731
sphinx-doc__sphinx-10325
sphinx-doc/sphinx
sphinx-doc/sphinx
python
7bdc11e87c7d86dcc2a087eccb7a7c129a473415
inherited-members should support more than one class **Is your feature request related to a problem? Please describe.** I have two situations: - A class inherits from multiple other classes. I want to document members from some of the base classes but ignore some of the base classes - A module contains several class de...
+1: Acceptable change. >A class inherits from multiple other classes. I want to document members from some of the base classes but ignore some of the base classes For example, there is a class that inherits multiple base classes: ``` class MyClass(Parent1, Parent2, Parent3, ...): pass ``` and ``` .. aut...
diff --git a/sphinx/ext/autodoc/__init__.py b/sphinx/ext/autodoc/__init__.py --- a/sphinx/ext/autodoc/__init__.py +++ b/sphinx/ext/autodoc/__init__.py @@ -109,12 +109,14 @@ def exclude_members_option(arg: Any) -> Union[object, Set[str]]: return {x.strip() for x in arg.split(',') if x.strip()} -def inherited_me...
diff --git a/tests/roots/test-ext-autodoc/target/inheritance.py b/tests/roots/test-ext-autodoc/target/inheritance.py --- a/tests/roots/test-ext-autodoc/target/inheritance.py +++ b/tests/roots/test-ext-autodoc/target/inheritance.py @@ -15,3 +15,8 @@ class Derived(Base): def inheritedmeth(self): # no docstr...
["tests/test_ext_autodoc_automodule.py::test_automodule_inherited_members"]
["tests/test_ext_autodoc_automodule.py::test_empty_all", "tests/test_ext_autodoc_automodule.py::test_automodule", "tests/test_ext_autodoc_automodule.py::test_automodule_undoc_members", "tests/test_ext_autodoc_automodule.py::test_automodule_special_members", "tests/test_ext_autodoc_automodule.py::test_subclass_of_mocked...
null
true
2022-04-02T17:05:02Z
1
12
1
1,118
0
0.8
1
0.55
1
0.226333
81.054
6,360
swe_smith::train::3000
swe_smith
train
3,000
Suor__funcy.207a7810.combine_file__n10h9w68
swesmith/Suor__funcy.207a7810
suor/funcy
python
null
CacheMemory returns expired values instead of raising KeyError #### Description The CacheMemory class is returning expired cached values instead of properly expiring them and raising KeyError when accessed after timeout. #### Steps/Code to Reproduce ```python from funcy import cache import time @cache(timeout=1) d...
diff --git a/funcy/calc.py b/funcy/calc.py index 2966bdd..fa90ffe 100644 --- a/funcy/calc.py +++ b/funcy/calc.py @@ -83,11 +83,11 @@ class CacheMemory(dict): self._expires.append(expires_at) def __getitem__(self, key): - value, expires_at = dict.__getitem__(self, key) - if expires_at <= ti...
["tests/test_calc.py::test_make_lookuper", "tests/test_calc.py::test_make_lookuper_nested", "tests/test_calc.py::test_silent_lookuper", "tests/test_calc.py::test_silnent_lookuper_nested", "tests/test_calc.py::test_cache[int]", "tests/test_calc.py::test_cache[timedelta]", "tests/test_calc.py::test_cache_timedout", "test...
["tests/test_calc.py::test_memoize", "tests/test_calc.py::test_memoize_args_kwargs", "tests/test_calc.py::test_memoize_skip", "tests/test_calc.py::test_memoize_memory", "tests/test_calc.py::test_memoize_key_func", "tests/test_calc.py::test_cache_mixed_args", "tests/test_colls.py::test_empty", "tests/test_colls.py::test...
jyangballin/swesmith.x86_64.suor_1776_funcy.207a7810
true
null
1
16
8
1,238
0
0.6
1
0.75
1
0.259667
81.054
6,361
swe_smith::train::5557
swe_smith
train
5,557
PyCQA__flake8.cf1542ce.func_pm_ctrl_shuffle__r34zlxln
swesmith/PyCQA__flake8.cf1542ce
pycqa/flake8
python
null
Config loading fails with UnboundLocalError when config file is specified #### Description When using flake8 with a specified config file, the configuration loading process fails with an `UnboundLocalError` for variables that are referenced before assignment. #### Steps/Code to Reproduce ```python import tempfile i...
diff --git a/src/flake8/options/config.py b/src/flake8/options/config.py index b51949c..5dbaa37 100644 --- a/src/flake8/options/config.py +++ b/src/flake8/options/config.py @@ -59,6 +59,8 @@ def load_config( *, isolated: bool = False, ) -> tuple[configparser.RawConfigParser, str]: + + cfg = configparser.R...
["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_main.py::test_form_feed_line_split", "tests/integration/test_main.py::test_e101_inde...
["tests/integration/test_checker.py::test_handle_file_plugins[PluginClass]", "tests/integration/test_checker.py::test_handle_file_plugins[plugin_func_gen]", "tests/integration/test_checker.py::test_handle_file_plugins[plugin_func_list]", "tests/integration/test_checker.py::test_line_check_results[plugin_func_physical_r...
jyangballin/swesmith.x86_64.pycqa_1776_flake8.cf1542ce
true
null
1
19
46
1,178
0
0.6
1
0.75
1
0.259667
81.054
6,362
swe_smith::train::2966
swe_smith
train
2,966
Suor__funcy.207a7810.combine_file__3u9hti2d
swesmith/Suor__funcy.207a7810
suor/funcy
python
null
# Broken curry and compose functions in funcy ## Description I've discovered that the `curry` and `compose` functions in funcy are not working correctly after a recent update. ## How to reproduce Here's a simple script that demonstrates the issue: ```python from funcy import curry, compose # Curry example def add...
diff --git a/funcy/funcs.py b/funcy/funcs.py index 0a235bb..e1674a1 100644 --- a/funcy/funcs.py +++ b/funcy/funcs.py @@ -42,14 +42,14 @@ def rpartial(func, *args, **kwargs): def curry(func, n=EMPTY): """Curries func into a chain of one argument functions.""" if n is EMPTY: - n = get_spec(func).max_n +...
["tests/test_funcs.py::test_curry", "tests/test_funcs.py::test_curry_funcy", "tests/test_funcs.py::test_compose", "tests/test_funcs.py::test_rcompose"]
["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
16
4
1,238
0
0.6
1
0.75
1
0.259667
81.054
6,363
swe_smith::train::3472
swe_smith
train
3,472
pygments__pygments.27649ebb.combine_file__pxsysw8k
swesmith/pygments__pygments.27649ebb
pygments/pygments
python
null
PythonConsoleLexer constructor arguments swapped causing delegation issues #### Description The PythonConsoleLexer is not working correctly due to swapped constructor arguments in the DelegatingLexer initialization. This affects syntax highlighting for Python console sessions and tracebacks. #### Steps/Code to Repro...
diff --git a/pygments/lexers/python.py b/pygments/lexers/python.py index 670d03f..de88827 100644 --- a/pygments/lexers/python.py +++ b/pygments/lexers/python.py @@ -406,8 +406,8 @@ class PythonLexer(RegexLexer): } def analyse_text(text): - return shebang_matches(text, r'pythonw?(3(\.\d)?)?') or \ - ...
["tests/test_cmdline.py::test_C_opt", "tests/test_basic_api.py::test_get_lexers", "tests/snippets/pycon/unterminated_tb.txt::", "tests/examplefiles/pycon/pycon_ctrlc_traceback::", "tests/snippets/pycon/broken_tb.txt::", "tests/snippets/pycon/multiple_tb.txt::", "tests/examplefiles/pycon/pycon_test.pycon::", "tests/test...
["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
14
8
1,278
0
0.6
1
0.75
1
0.259667
81.054
6,364
swe_smith::train::49163
swe_smith
train
49,163
mozilla__bleach.73871d76.combine_file__z49oq7ub
swesmith/mozilla__bleach.73871d76
mozilla/bleach
python
null
urlparse function returns string instead of ParseResult object #### Description The `urlparse` function in `bleach._vendor.parse` is returning a string representation instead of a `ParseResult` object, breaking code that expects to access attributes like `.scheme`, `.netloc`, `.path`, etc. #### Steps/Code to Reprodu...
diff --git a/bleach/_vendor/parse.py b/bleach/_vendor/parse.py index ac6e7a9..7c9fe32 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
28
24
998
0
0.6
1
0.75
1
0.259667
81.054
6,365
swe_smith::train::26490
swe_smith
train
26,490
pylint-dev__astroid.b114f6b5.func_pm_remove_loop__wvyl3rh1
swesmith/pylint-dev__astroid.b114f6b5
pylint-dev/astroid
python
null
Missing builtin types in astroid builtin module after bootstrapping changes #### Description After recent changes to the bootstrapping process, several builtin types are no longer available in the astroid builtin module. This causes inference issues when trying to access attributes of exception instances and other bu...
diff --git a/astroid/raw_building.py b/astroid/raw_building.py index c1f7ec1..943edc3 100644 --- a/astroid/raw_building.py +++ b/astroid/raw_building.py @@ -698,25 +698,6 @@ def _astroid_bootstrapping() -> None: types.ModuleType, types.TracebackType, ) - for _type in builtin_types: - if...
["tests/test_object_model.py::ExceptionModelTest::test_valueerror_py3"]
["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
21
1
1,138
0
0.6
1
0.75
1
0.259667
81.054
6,366
swe_smith::train::24914
swe_smith
train
24,914
marshmallow-code__marshmallow.9716fc62.lm_rewrite__5ue0iqa9
swesmith/marshmallow-code__marshmallow.9716fc62
marshmallow-code/marshmallow
python
null
[Bug]: Nested validation data is lost when validation fails ### Bug summary When using nested schemas, valid data is lost when validation fails. This affects partial loading and nested validation scenarios. ### Code for reproduction ```python from marshmallow import Schema, fields, ValidationError class SchemaA(Sc...
diff --git a/src/marshmallow/schema.py b/src/marshmallow/schema.py index e21768e..f35502d 100644 --- a/src/marshmallow/schema.py +++ b/src/marshmallow/schema.py @@ -494,14 +494,10 @@ class Schema(base.SchemaABC, metaclass=SchemaMeta): otherwise `None`. """ try: - value = getter...
["tests/test_deserialization.py::TestValidation::test_nested_data_is_stored_when_validation_fails", "tests/test_deserialization.py::TestValidation::test_nested_partial_load", "tests/test_deserialization.py::TestValidation::test_deeply_nested_partial_load", "tests/test_schema.py::TestNestedSchema::test_all_errors_on_man...
["tests/test_decorators.py::test_decorated_processors[True]", "tests/test_decorators.py::test_decorated_processors[False]", "tests/test_decorators.py::test_decorated_processor_returning_none[exclude]", "tests/test_decorators.py::test_decorated_processor_returning_none[include]", "tests/test_decorators.py::test_decorate...
jyangballin/swesmith.x86_64.marshmallow-code_1776_marshmallow.9716fc62
true
null
1
8
4
1,397
0
0.6
1
0.75
1
0.2595
81.0535
6,367
swe_smith::train::11312
swe_smith
train
11,312
rsalmei__alive-progress.35853799.lm_rewrite__q1f32l7g
swesmith/rsalmei__alive-progress.35853799
rsalmei/alive-progress
python
null
Title rendering issue with NoneType It seems there's a problem with the title rendering function when handling `None` values. When a title is not provided, the function should return an empty string or a space, depending on the configuration. However, it currently raises a `TypeError` instead. To reproduce this issue...
diff --git a/alive_progress/core/progress.py b/alive_progress/core/progress.py index a0e266a..621c5be 100644 --- a/alive_progress/core/progress.py +++ b/alive_progress/core/progress.py @@ -459,21 +459,22 @@ def _create_spinner_player(config): def _render_title(config, title=None): - title, length = to_cells(tit...
["tests/core/test_progress_util.py::test_render_title[0-None-]", "tests/core/test_progress_util.py::test_render_title[0--]", "tests/core/test_progress_util.py::test_render_title[0-c-c]", "tests/core/test_progress_util.py::test_render_title[1-c-c]", "tests/core/test_progress_util.py::test_render_title[1-\\U0001f63a-\\u2...
["tests/animations/test_bars.py::test_bar_tip_background[--0.5-False-|0123456789|]", "tests/animations/test_bars.py::test_bar_tip_background[=--0.5-False-|0123456789|]", "tests/animations/test_bars.py::test_bar_tip_background[_-=--0.5-False-|0123456789|]", "tests/animations/test_bars.py::test_bar_tip_background[-0.0-Fa...
jyangballin/swesmith.x86_64.rsalmei_1776_alive-progress.35853799
true
null
1
31
6
937
0
0.6
1
0.75
1
0.2595
81.0535
6,368
swe_smith::train::26245
swe_smith
train
26,245
pylint-dev__astroid.b114f6b5.func_pm_ctrl_invert_if__ky9ca2iv
swesmith/pylint-dev__astroid.b114f6b5
pylint-dev/astroid
python
null
Super() calls with ClassDef as type argument fail to resolve correctly #### Description When using `super()` with a ClassDef as the type argument (e.g., `super(MyClass, MyClass)`), the super object fails to properly resolve its MRO and attributes. This affects class methods and other scenarios where `super(type, type...
diff --git a/astroid/objects.py b/astroid/objects.py index 9f638d4..375064c 100644 --- a/astroid/objects.py +++ b/astroid/objects.py @@ -97,10 +97,6 @@ class Super(node_classes.NodeNG): ) if isinstance(self.type, scoped_nodes.ClassDef): - # `super(type, type)`, most likely in a class ...
["tests/test_objects.py::SuperTests::test_super_bound_model", "tests/test_objects.py::SuperTests::test_super_complex_mro", "tests/test_objects.py::SuperTests::test_super_data_model", "tests/test_objects.py::SuperTests::test_super_getattr_single_inheritance", "tests/test_objects.py::SuperTests::test_super_invalid_types"...
["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
9
6
1,377
0
0.6
1
0.75
1
0.2595
81.0535
6,369
swe_smith::train::32786
swe_smith
train
32,786
pydantic__pydantic.acb0f10f.lm_rewrite__g2mxbof1
swesmith/pydantic__pydantic.acb0f10f
pydantic/pydantic
python
null
JSON schema generation fails with TypeError for complex types #### Description When generating JSON schemas for models containing certain complex types, the schema generation process crashes with a `TypeError` about unsupported types for JSON hashable conversion. #### Steps/Code to Reproduce ```python from pydantic...
diff --git a/pydantic/json_schema.py b/pydantic/json_schema.py index ca031ea..6e671cc 100644 --- a/pydantic/json_schema.py +++ b/pydantic/json_schema.py @@ -2424,13 +2424,26 @@ def _deduplicate_schemas(schemas: Iterable[JsonDict]) -> list[JsonDict]: def _make_json_hashable(value: JsonValue) -> _HashableJsonValue: ...
["tests/test_docs.py::test_docstrings_examples[pydantic/json_schema.py:2586-2620]"]
["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
23
1
1,097
0
0.6
1
0.75
1
0.2595
81.0535
6,370
swe_smith::train::8862
swe_smith
train
8,862
pyupio__safety.7654596b.func_pm_ctrl_shuffle__y9onak6l
swesmith/pyupio__safety.7654596b
pyupio/safety
python
null
get_final_brief function returns early causing undefined variable errors #### Description The `get_final_brief` function in `safety/output_utils.py` has a premature return statement that causes several variables to be undefined when the function tries to use them later in the code. #### Steps/Code to Reproduce ```p...
diff --git a/safety/output_utils.py b/safety/output_utils.py index 0ebb928..6c9fa46 100644 --- a/safety/output_utils.py +++ b/safety/output_utils.py @@ -534,6 +534,14 @@ def build_remediation_section(remediations: Dict[str, Any], only_text: bool = Fa def get_final_brief(total_vulns_found: int, remediations: Dict[s...
["tests/test_cli.py::TestSafetyCLI::test_announcements_if_is_not_tty", "tests/test_cli.py::TestSafetyCLI::test_check_ignore_unpinned_requirements", "tests/test_cli.py::TestSafetyCLI::test_check_vulnerabilities_found_default", "tests/test_cli.py::TestSafetyCLI::test_check_vulnerabilities_found_with_outputs", "tests/test...
["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::test_check_vulnerabilities_not_found_default", "tests/test_cli.py::Test...
jyangballin/swesmith.x86_64.pyupio_1776_safety.7654596b
true
null
1
25
5
1,056
0
0.6
1
0.75
1
0.259333
81.053
6,371
swe_smith::train::47883
swe_smith
train
47,883
sqlfluff__sqlfluff.50a1c4b6.func_basic__g60edlwi
swesmith/sqlfluff__sqlfluff.50a1c4b6
sqlfluff/sqlfluff
python
null
Config file loading fails with FileNotFoundError and IsADirectoryError #### Description When trying to load configuration files, the config loader is failing to find files and throwing various path-related errors. This appears to be affecting multiple configuration file formats including .cfg, .toml, and nested confi...
diff --git a/src/sqlfluff/core/config/loader.py b/src/sqlfluff/core/config/loader.py index 4b4fdd4..3c93051 100644 --- a/src/sqlfluff/core/config/loader.py +++ b/src/sqlfluff/core/config/loader.py @@ -94,11 +94,10 @@ def load_config_file( Returns: :obj:`ConfigMappingType`: A nested dictionary of config va...
["test/core/config/loader_test.py::test__config__load_file_dir", "test/core/config/loader_test.py::test__config__load_file_f", "test/core/config/loader_test.py::test__config__load_nested", "test/core/config/loader_test.py::test__config__load_parent", "test/core/config/loader_test.py::test__config__load_toml", "test/cor...
["test/core/config/loader_test.py::test__config__load_from_string", "test/core/config/loader_test.py::test__config__load_user_appdir_config"]
jyangballin/swesmith.x86_64.sqlfluff_1776_sqlfluff.50a1c4b6
true
null
1
7
7
1,416
0
0.6
1
0.75
1
0.259333
81.053
6,372
swe_smith::train::10179
swe_smith
train
10,179
paramiko__paramiko.23f92003.combine_file__rhkm81e9
swesmith/paramiko__paramiko.23f92003
paramiko/paramiko
python
null
PublicBlob key type validation broken after recent changes #### Description After some recent changes, public key loading and validation is completely broken. When trying to load keys or work with PublicBlob objects, I'm getting `ValueError: Not enough fields` errors and key type validation is failing. #### Steps/Co...
diff --git a/paramiko/pkey.py b/paramiko/pkey.py index f0b2d6d..c62b1e9 100644 --- a/paramiko/pkey.py +++ b/paramiko/pkey.py @@ -846,17 +846,17 @@ class PKey: that is for the server to decide if it is good enough to authenticate successfully. """ - if isinstance(value, Message): + ...
["tests/agent.py::AgentKey_::signing_data[sign_kwargs0-0]", "tests/agent.py::AgentKey_::signing_data[sign_kwargs1-2]", "tests/agent.py::AgentKey_::signing_data[sign_kwargs2-4]", "tests/agent.py::AgentKey_::signing_data[sign_kwargs3-2]", "tests/agent.py::AgentKey_::signing_data[sign_kwargs4-4]", "tests/auth.py::AuthOnly...
["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_::fields::defaults_to_get_name_and_blob", "tests/agent.py::AgentK...
jyangballin/swesmith.x86_64.paramiko_1776_paramiko.23f92003
true
null
1
15
23
1,256
0
0.6
1
0.75
1
0.259333
81.053
6,373
swe_smith::train::24492
swe_smith
train
24,492
sunpy__sunpy.f8edfd5c.combine_module__cjeldg50
swesmith/sunpy__sunpy.f8edfd5c
sunpy/sunpy
python
null
# VSO client fails to handle queries and build response tables **Describe the bug** I'm trying to use the VSO client to query solar data, but I'm encountering two separate issues: 1. When trying to check if the VSO client can handle a query, I get an error about accessing a local variable 'required' where it's not a...
diff --git a/sunpy/net/vso/legacy_response.py b/sunpy/net/vso/legacy_response.py index ff54c6a..a6887ac 100644 --- a/sunpy/net/vso/legacy_response.py +++ b/sunpy/net/vso/legacy_response.py @@ -78,8 +78,6 @@ class QueryResponse(BaseQueryResponse): """ keywords = ['Start Time', 'End Time', 'Source', 'In...
["sunpy/net/vso/tests/test_vso.py::test_can_handle_query[query0-True]", "sunpy/net/vso/tests/test_vso.py::test_can_handle_query[query1-False]", "sunpy/net/vso/tests/test_vso.py::test_can_handle_query[query2-True]", "sunpy/net/vso/tests/test_vso.py::test_can_handle_query[query3-False]", "sunpy/net/vso/tests/test_vso.py:...
["sunpy/net/vso/tests/test_vso.py::test_str", "sunpy/net/vso/tests/test_vso.py::test_repr", "sunpy/net/vso/tests/test_vso.py::test_show", "sunpy/net/vso/tests/test_vso.py::test_non_str_instrument", "sunpy/net/vso/tests/test_vso.py::test_iter_sort_response", "sunpy/net/vso/tests/test_vso.py::test_from_zeep_response", "s...
jyangballin/swesmith.x86_64.sunpy_1776_sunpy.f8edfd5c
true
null
2
6
5
1,436
0
0.6
1
0.75
1
0.259333
81.053
6,374
swe_smith::train::17711
swe_smith
train
17,711
pyasn1__pyasn1.0f07d724.func_basic__nyqjp16q
swesmith/pyasn1__pyasn1.0f07d724
pyasn1/pyasn1
python
null
CER time encoder incorrectly validates time zone specifier position #### Description The CER time encoder is checking for the "Z" time zone specifier at the wrong position in the time string, causing valid UTC time values to be rejected with "Missing 'Z' time zone specifier" errors. #### Steps/Code to Reproduce ```...
diff --git a/pyasn1/codec/cer/encoder.py b/pyasn1/codec/cer/encoder.py index e16e9ec..b33abf1 100644 --- a/pyasn1/codec/cer/encoder.py +++ b/pyasn1/codec/cer/encoder.py @@ -43,57 +43,43 @@ class TimeEncoderMixIn(object): MAX_LENGTH = 19 def encodeValue(self, value, asn1Spec, encodeFun, **options): - ...
["tests/codec/cer/test_encoder.py::GeneralizedTimeEncoderTestCase::testWithMinutes", "tests/codec/cer/test_encoder.py::GeneralizedTimeEncoderTestCase::testWithSeconds", "tests/codec/cer/test_encoder.py::GeneralizedTimeEncoderTestCase::testWithSubseconds", "tests/codec/cer/test_encoder.py::GeneralizedTimeEncoderTestCase...
["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
30
9
956
0
0.6
1
0.75
1
0.259333
81.053
6,375
swe_smith::train::22514
swe_smith
train
22,514
tweepy__tweepy.91a41c6e.func_pm_remove_cond__gr3qnodb
swesmith/tweepy__tweepy.91a41c6e
tweepy/tweepy
python
null
**User attributes not being set correctly** **Describe the bug** After updating the code, it seems that user attributes are not being set correctly when parsing user data. This results in several operations failing due to missing or improperly set attributes. **To Reproduce** 1. Attempt to retrieve a user by screen n...
diff --git a/tweepy/models.py b/tweepy/models.py index f29361e..b57e1ab 100644 --- a/tweepy/models.py +++ b/tweepy/models.py @@ -372,20 +372,8 @@ class User(Model, HashableID): user = cls(api) setattr(user, '_json', json) for k, v in json.items(): - if k == 'created_at': - ...
["tests/test_api.py::TweepyAPITests::test_indicate_direct_message_typing", "tests/test_api.py::TweepyAPITests::testcachedifferentqueryparameters", "tests/test_api.py::TweepyAPITests::testcreatedestroyfriendship", "tests/test_api.py::TweepyAPITests::testgetuser", "tests/test_api.py::TweepyAPITests::testsendanddeletedire...
["tests/test_api.py::TweepyAPITests::testaddremovelistmember", "tests/test_api.py::TweepyAPITests::testaddremovelistmembers", "tests/test_api.py::TweepyAPITests::testcachedresult", "tests/test_api.py::TweepyAPITests::testcreatedestroyblock", "tests/test_api.py::TweepyAPITests::testcreatedestroyfavorite", "tests/test_ap...
jyangballin/swesmith.x86_64.tweepy_1776_tweepy.91a41c6e
true
null
1
14
9
1,275
0
0.6
1
0.75
1
0.259167
81.0525
6,376
swe_smith::train::35105
swe_smith
train
35,105
django__daphne.32ac73e1.func_basic__9x5p0khl
swesmith/django__daphne.32ac73e1
django/daphne
python
null
WebSocket connections timing out prematurely after server changes I'm experiencing an issue where WebSocket connections are being terminated unexpectedly after some recent changes. The connections seem to be timing out even when they should remain active. #### Steps to Reproduce ```python import time from daphne.tes...
diff --git a/daphne/server.py b/daphne/server.py index a6d3819..d0d6c1a 100755 --- a/daphne/server.py +++ b/daphne/server.py @@ -272,7 +272,7 @@ class Server: # too long to close up if ( disconnected - and time.time() - disconnected > self.application_close_time...
["tests/test_websocket.py::TestWebsocket::test_http_timeout"]
["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
8
1
1,395
0
0.6
1
0.75
1
0.259167
81.0525
6,377
swe_smith::train::22304
swe_smith
train
22,304
tweepy__tweepy.91a41c6e.func_basic__88x3uug7
swesmith/tweepy__tweepy.91a41c6e
tweepy/tweepy
python
null
### Issue: Incorrect Parameter Handling in `get_users` Method #### What happened? When attempting to retrieve user information using the `get_users` method with a list of usernames, a `TypeError` is raised. This occurs when the method is called with the `usernames` parameter, which should be valid input. #### What d...
diff --git a/tweepy/client.py b/tweepy/client.py index d463129..d1b52ed 100644 --- a/tweepy/client.py +++ b/tweepy/client.py @@ -2403,21 +2403,21 @@ class Client(BaseClient): https://developer.twitter.com/en/docs/twitter-api/users/lookup/api-reference/get-users https://developer.twitter.com/en/docs/tw...
["tests/test_client.py::TweepyClientTests::test_get_users"]
["tests/test_api.py::TweepyAPITests::test_indicate_direct_message_typing", "tests/test_api.py::TweepyAPITests::testaddremovelistmember", "tests/test_api.py::TweepyAPITests::testaddremovelistmembers", "tests/test_api.py::TweepyAPITests::testcachedifferentqueryparameters", "tests/test_api.py::TweepyAPITests::testcachedre...
jyangballin/swesmith.x86_64.tweepy_1776_tweepy.91a41c6e
true
null
1
12
1
1,315
0
0.6
1
0.75
1
0.259167
81.0525
6,378
swe_smith::train::17850
swe_smith
train
17,850
pyasn1__pyasn1.0f07d724.func_pm_class_rm_funcs__ca6rpn68
swesmith/pyasn1__pyasn1.0f07d724
pyasn1/pyasn1
python
null
BitString methods missing after recent changes #### Description Several BitString methods appear to be missing, causing AttributeError when trying to use basic functionality like iteration and octet conversion. #### Steps/Code to Reproduce ```python from pyasn1.type import univ # Create a BitString bs = univ.BitSt...
diff --git a/pyasn1/type/univ.py b/pyasn1/type/univ.py index 9aff5e6..1bdd6cd 100644 --- a/pyasn1/type/univ.py +++ b/pyasn1/type/univ.py @@ -491,12 +491,6 @@ class BitString(base.SimpleAsn1Type): raise IndexError('bit index out of range') return (self._value >> (length - i)) & 1 - def...
["tests/codec/ber/test_decoder.py::BitStringDecoderTestCase::testDefMode", "tests/codec/ber/test_decoder.py::BitStringDecoderTestCase::testDefModeChunked", "tests/codec/ber/test_decoder.py::BitStringDecoderTestCase::testIndefMode", "tests/codec/ber/test_decoder.py::BitStringDecoderTestCase::testIndefModeChunked", "test...
["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
39
36
775
0
0.6
1
0.75
1
0.259167
81.0525
6,379
swe_smith::train::25020
swe_smith
train
25,020
pylint-dev__astroid.b114f6b5.combine_file__b1t19sxq
swesmith/pylint-dev__astroid.b114f6b5
pylint-dev/astroid
python
null
NamedExpr inference returns None instead of raising InferenceError #### Description When trying to infer a NamedExpr (walrus operator) node that doesn't match the target, the inference returns `None` instead of raising an `InferenceError` as expected. This breaks the inference chain and causes various issues througho...
diff --git a/astroid/protocols.py b/astroid/protocols.py index 8a837b8..c12ba8b 100644 --- a/astroid/protocols.py +++ b/astroid/protocols.py @@ -250,10 +250,6 @@ def _resolve_looppart(parts, assign_path, context): assign_path = assign_path[:] index = assign_path.pop(0) for part in parts: - if isin...
["tests/brain/numpy/test_core_einsumfunc.py::test_numpy_function_calls_inferred_as_ndarray", "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/n...
["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_function_base.py::BrainNumpyCoreFunctionBaseTest::test_numpy_function_calls_inferred_as_ndarray...
jyangballin/swesmith.x86_64.pylint-dev_1776_astroid.b114f6b5
true
null
1
31
25
935
0
0.6
1
0.75
1
0.259167
81.0525
6,380
swe_smith::train::24671
swe_smith
train
24,671
marshmallow-code__marshmallow.9716fc62.func_basic__aggsb2q2
swesmith/marshmallow-code__marshmallow.9716fc62
marshmallow-code/marshmallow
python
null
URL validator parameters swapped causing validation failures #### Description The URL validator is not working correctly - it's rejecting valid URLs and accepting invalid ones. When creating a URL validator with `relative=True`, it seems to be behaving as if `relative=False` was set, and vice versa. Also getting `Typ...
diff --git a/src/marshmallow/validate.py b/src/marshmallow/validate.py index e4536d8..71a4836 100644 --- a/src/marshmallow/validate.py +++ b/src/marshmallow/validate.py @@ -189,11 +189,11 @@ class URL(Validator): raise ValueError( "URL validation cannot set both relative and absolute to Fa...
["tests/test_deserialization.py::TestFieldDeserialization::test_url_field_deserialization", "tests/test_deserialization.py::TestFieldDeserialization::test_url_field_non_list_validators", "tests/test_deserialization.py::TestFieldDeserialization::test_url_field_schemes_argument", "tests/test_options.py::TestFieldOrdering...
["tests/test_decorators.py::test_decorated_processors[True]", "tests/test_decorators.py::test_decorated_processors[False]", "tests/test_decorators.py::test_decorated_processor_returning_none[exclude]", "tests/test_decorators.py::test_decorated_processor_returning_none[include]", "tests/test_decorators.py::test_decorate...
jyangballin/swesmith.x86_64.marshmallow-code_1776_marshmallow.9716fc62
true
null
1
10
78
1,355
0
0.6
1
0.75
1
0.259167
81.0525
6,381
r2e_gym::train::4541
r2e_gym
train
4,541
numpy__0e8d3bb76aa5d854942b584bc6b508c3be225e01
numpy
numpy/numpy
python
0e8d3bb76aa5d854942b584bc6b508c3be225e01
**Title:** Error When Constructing Masked Array from ndarray with Padding Fields **Description:** Attempting to create a masked array from a NumPy ndarray that includes padding fields in its dtype results in a `ValueError`. This occurs because the construction process does not correctly handle the padding, leading to ...
diff --git a/numpy/ma/core.py b/numpy/ma/core.py --- a/numpy/ma/core.py +++ b/numpy/ma/core.py @@ -371,24 +371,61 @@ raise TypeError(errmsg) -def _recursive_set_default_fill_value(dtypedescr): +def _recursive_set_default_fill_value(dt): + """ + Create the default fill value for a structured dtype. + ...
diff --git a/numpy/ma/tests/test_core.py b/numpy/ma/tests/test_core.py --- a/numpy/ma/tests/test_core.py +++ b/numpy/ma/tests/test_core.py @@ -211,6 +211,12 @@ data = array((x, x[::-1])) assert_equal(data, [[0, 1, 2, 3, 4], [4, 3, 2, 1, 0]]) self.assertTrue(data.mask is nomask) + + def tes...
null
null
namanjain12/numpy_final:0e8d3bb76aa5d854942b584bc6b508c3be225e01
true
null
1
65
null
967
0
0.75
1
0.6375
1
0.377833
81.05225
6,382
swe_smith::train::36504
swe_smith
train
36,504
lincolnloop__python-qrcode.456b01d4.combine_module__5fpvl29p
swesmith/lincolnloop__python-qrcode.456b01d4
lincolnloop/python-qrcode
python
null
QRCode styled image generation fails with AttributeError on paint_color #### Description When generating QR codes with styled PIL images using color masks or module drawers, the code fails with an AttributeError because it's trying to access `paint_color` from the wrong object. #### Steps/Code to Reproduce ```pytho...
diff --git a/qrcode/image/styles/colormasks.py b/qrcode/image/styles/colormasks.py index 43186b2..c226a34 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
16
24
1,234
0
0.6
1
0.75
1
0.259
81.052
6,383
swe_smith::train::51933
swe_smith
train
51,933
pydicom__pydicom.7d361b3d.func_basic__dlczixcu
swesmith/pydicom__pydicom.7d361b3d
pydicom/pydicom
python
null
Planar configuration property returns incorrect default value for uncompressed transfer syntaxes #### Description The `planar_configuration` property in `RunnerBase` is returning an incorrect default value of 1 for uncompressed transfer syntaxes when no explicit value has been set. According to the DICOM standard, un...
diff --git a/src/pydicom/pixels/common.py b/src/pydicom/pixels/common.py index 10a4a93..930bb82 100644 --- a/src/pydicom/pixels/common.py +++ b/src/pydicom/pixels/common.py @@ -480,16 +480,13 @@ class RunnerBase: @property def planar_configuration(self) -> int: """Return the expected planar configura...
["tests/pixels/test_common.py::TestRunnerBase::test_planar_configuration"]
["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_set_number_of_frames", "tests/pixels/test_common.py::TestRunnerBase::test_s...
jyangballin/swesmith.x86_64.pydicom_1776_pydicom.7d361b3d
true
null
1
9
1
1,374
0
0.6
1
0.75
1
0.259
81.052
6,384
swe_smith::train::24578
swe_smith
train
24,578
marshmallow-code__marshmallow.9716fc62.combine_file__qm86nytg
swesmith/marshmallow-code__marshmallow.9716fc62
marshmallow-code/marshmallow
python
null
OneOf validator raises error for valid values #### Description The OneOf validator is incorrectly raising ValidationError for values that should be valid. When a value is present in the choices list, it should pass validation, but instead it's throwing an error saying the value must be one of the allowed choices. ##...
diff --git a/src/marshmallow/validate.py b/src/marshmallow/validate.py index e4536d8..39abd15 100644 --- a/src/marshmallow/validate.py +++ b/src/marshmallow/validate.py @@ -163,12 +163,12 @@ class URL(Validator): def __call__( self, relative: bool, absolute: bool, require_tld: bool ) -> t...
["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_schema.py::TestLoadOnly::test_url_field_requre_tld_false", "tests/test_validate....
["tests/test_decorators.py::test_decorated_processors[True]", "tests/test_decorators.py::test_decorated_processors[False]", "tests/test_decorators.py::test_decorated_processor_returning_none[exclude]", "tests/test_decorators.py::test_decorated_processor_returning_none[include]", "tests/test_decorators.py::test_decorate...
jyangballin/swesmith.x86_64.marshmallow-code_1776_marshmallow.9716fc62
true
null
1
20
14
1,154
0
0.6
1
0.75
1
0.259
81.052
6,385
swe_smith::train::2475
swe_smith
train
2,475
pdfminer__pdfminer.six.1a8bd2f7.func_pm_op_break_chains__4i60d2xd
swesmith/pdfminer__pdfminer.six.1a8bd2f7
pdfminer/pdfminer.six
python
null
# Run-length decoding fails with IndexError for certain inputs ## Description I've encountered an issue with the run-length decoding function in pdfminer. When processing certain PDF files, the decoder fails with an IndexError. This happens when trying to decode run-length encoded data streams. ## To Reproduce The is...
diff --git a/pdfminer/runlength.py b/pdfminer/runlength.py index 2774e2a..2d644e4 100644 --- a/pdfminer/runlength.py +++ b/pdfminer/runlength.py @@ -27,13 +27,13 @@ def rldecode(data: bytes) -> bytes: break if length >= 0 and length < 128: - for j in range(i + 1, (i + 1) + (length + 1...
["tests/test_pdfminer_crypto.py::TestRunlength::test_rldecode"]
["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
6
1
1,434
0
0.6
1
0.75
1
0.259
81.052
6,386
swe_smith::train::3162
swe_smith
train
3,162
Suor__funcy.207a7810.func_basic__r5a1c8wn
swesmith/Suor__funcy.207a7810
suor/funcy
python
null
limit_error_rate decorator fails to reset error count after successful calls #### Description The `limit_error_rate` decorator doesn't properly reset the failure counter when a function call succeeds, causing it to incorrectly block subsequent calls even after successful executions. #### Steps/Code to Reproduce ```...
diff --git a/funcy/flow.py b/funcy/flow.py index 85c5a8e..c2021ad 100644 --- a/funcy/flow.py +++ b/funcy/flow.py @@ -144,20 +144,21 @@ def limit_error_rate(fails, timeout, exception=ErrorRateExceeded): @wraps(func) def wrapper(*args, **kwargs): if wrapper.blocked: - if date...
["tests/test_flow.py::test_limit_error_rate"]
["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
11
1
1,333
0
0.6
1
0.75
1
0.258833
81.0515
6,387
swe_smith::train::49100
swe_smith
train
49,100
mozilla__bleach.73871d76.combine_file__803795tr
swesmith/mozilla__bleach.73871d76
mozilla/bleach
python
null
TreeWalker class inheritance broken after refactoring #### Description After some recent changes, the TreeWalker class in the etree treewalker is no longer properly inheriting from base.NonRecursiveTreeWalker, causing it to fail initialization when instantiated. #### Steps/Code to Reproduce ```python import bleach ...
diff --git a/bleach/_vendor/html5lib/treewalkers/etree.py b/bleach/_vendor/html5lib/treewalkers/etree.py index a9d9450..1e11ca3 100644 --- a/bleach/_vendor/html5lib/treewalkers/etree.py +++ b/bleach/_vendor/html5lib/treewalkers/etree.py @@ -15,7 +15,7 @@ def getETreeBuilder(ElementTreeImplementation): ElementTree ...
["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_content_has_no_html", "tests/test_clean.py::test_html_is_lowercased", "tests/test_clean.py::test_comments[<!--comment-->text-True-text]"...
["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
32
183
913
0
0.6
1
0.75
1
0.258833
81.0515
6,388
swe_smith::train::33048
swe_smith
train
33,048
django-money__django-money.835c1ab8.combine_file__balze8su
swesmith/django-money__django-money.835c1ab8
django-money/django-money
python
null
MoneyField saves incorrect values to database #### Description When saving Money objects to the database, the values are being doubled and incorrect validation logic is causing issues with nullable currency fields. #### Steps/Code to Reproduce ```python from djmoney import Money from myapp.models import ModelWithVa...
diff --git a/djmoney/models/fields.py b/djmoney/models/fields.py index dc5f6ad..dfbf682 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_form.py::test_save", "tests/test_form.py::test_default_currency", "tests/test_models.py::TestVanillaMoneyField::test_create_defaults[ModelWithVanillaMoneyField-kwargs0-expected0]", "tests/test_models.py::TestVanillaMoneyField::test_create_defaults[ModelWithVanillaMoneyField-kwargs1-expected1]", "tests/test...
["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
9
139
1,373
0
0.6
1
0.75
1
0.258833
81.0515
6,389
swe_smith::train::978
swe_smith
train
978
pytest-dev__iniconfig.16793ead.combine_file__rca5g2oy
swesmith/pytest-dev__iniconfig.16793ead
pytest-dev/iniconfig
python
null
# get() method in IniConfig and SectionWrapper swaps convert and default parameters ## Bug description When using the `get()` method in either `IniConfig` or `SectionWrapper`, the `convert` and `default` parameters are swapped, causing unexpected behavior. ## Reproduction ```python from iniconfig import IniConfig ...
diff --git a/src/iniconfig/__init__.py b/src/iniconfig/__init__.py index 3c40bc9..741a7f3 100644 --- a/src/iniconfig/__init__.py +++ b/src/iniconfig/__init__.py @@ -84,7 +84,7 @@ class SectionWrapper: default: _D | None = None, convert: Callable[[str], _T] | None = None, ) -> _D | _T | str | None...
["testing/test_iniconfig.py::test_iniconfig_get_convert", "testing/test_iniconfig.py::test_section_get"]
["testing/test_iniconfig.py::test_tokenize[comment]", "testing/test_iniconfig.py::test_tokenize[comment2]", "testing/test_iniconfig.py::test_tokenize[section]", "testing/test_iniconfig.py::test_tokenize[value]", "testing/test_iniconfig.py::test_parse_empty", "testing/test_iniconfig.py::test_ParseError", "testing/test_i...
jyangballin/swesmith.x86_64.pytest-dev_1776_iniconfig.16793ead
true
null
1
9
2
1,372
0
0.6
1
0.75
1
0.258667
81.051
6,390
swe_smith::train::49080
swe_smith
train
49,080
pwaller__pyfiglet.f8c5f35b.func_pm_ctrl_shuffle__n7wjcwpl
swesmith/pwaller__pyfiglet.f8c5f35b
pwaller/pyfiglet
python
null
# Font installation fails in pyfiglet ## Description I found a bug in pyfiglet when trying to install custom fonts. When attempting to install a font file, the installation fails because the code tries to copy the file to a location that hasn't been defined yet. ## Steps to reproduce 1. Create a custom font file (e...
diff --git a/pyfiglet/__init__.py b/pyfiglet/__init__.py index 9ff838b..63569fd 100755 --- a/pyfiglet/__init__.py +++ b/pyfiglet/__init__.py @@ -229,18 +229,6 @@ class FigletFont(object): """ Install the specified font file to this system. """ - if hasattr(importlib.resources.files('py...
["pyfiglet/tests/test_cli.py::test_strip_strange_font"]
["pyfiglet/tests/test_cli.py::test_strip", "pyfiglet/tests/test_cli.py::test_normalize"]
jyangballin/swesmith.x86_64.pwaller_1776_pyfiglet.f8c5f35b
true
null
1
23
1
1,092
0
0.6
1
0.75
1
0.258667
81.051
6,391
swe_smith::train::5118
swe_smith
train
5,118
agronholm__exceptiongroup.0b4f4937.combine_module__yj0e8azl
swesmith/agronholm__exceptiongroup.0b4f4937
agronholm/exceptiongroup
python
null
# ExceptionGroup.subgroup() returns incorrect exceptions ## Description When using the `subgroup()` method on an ExceptionGroup, it returns the wrong exceptions. The method seems to be filtering out exceptions that should be included and including exceptions that should be filtered out. Here's a simple reproduction ...
diff --git a/src/exceptiongroup/_exceptions.py b/src/exceptiongroup/_exceptions.py index a4a7ace..09a2e55 100644 --- a/src/exceptiongroup/_exceptions.py +++ b/src/exceptiongroup/_exceptions.py @@ -155,9 +155,9 @@ class BaseExceptionGroup(BaseException, Generic[_BaseExceptionT_co]): if subgroup is not e...
["tests/test_exceptions.py::ExceptionGroupSubgroupTests::test_basics_subgroup_by_predicate__match", "tests/test_exceptions.py::ExceptionGroupSubgroupTests::test_basics_subgroup_by_predicate__no_match", "tests/test_exceptions.py::ExceptionGroupSubgroupTests::test_basics_subgroup_by_type__match", "tests/test_exceptions.p...
["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
7
14
1,412
0
0.6
1
0.75
1
0.258667
81.051
6,392
swe_smith::train::37998
swe_smith
train
37,998
kayak__pypika.1c9646f0.lm_rewrite__z28zlqjw
swesmith/kayak__pypika.1c9646f0
kayak/pypika
python
null
# MSSQL TOP clause validation issues Hi, I found a bug in the MSSQL query builder's TOP clause implementation. There are two validation issues: 1. When using the `top()` method with a non-integer value, it raises a `ValueError` instead of a `QueryException` as expected. 2. The percent validation is completely missi...
diff --git a/pypika/dialects.py b/pypika/dialects.py index 57955d8..57f85d1 100644 --- a/pypika/dialects.py +++ b/pypika/dialects.py @@ -704,7 +704,8 @@ class MSSQLQueryBuilder(FetchNextAndOffsetRowsQueryBuilder): self._top_percent: bool = False @builder - def top(self, value: Union[str, int], percen...
["pypika/tests/dialects/test_mssql.py::SelectTests::test_top_percent_invalid_range", "pypika/tests/dialects/test_mssql.py::SelectTests::test_top_select_non_int"]
["pypika/tests/clickhouse/test_array.py::TestArray::test_get_sql_0__ridley_scott_jimi_hendrix_", "pypika/tests/clickhouse/test_array.py::TestArray::test_get_sql_1__1_2_3_4_", "pypika/tests/clickhouse/test_array.py::TestArray::test_get_sql_2__toInt64_1_toInt64_2_toInt64_3_toInt64_4_", "pypika/tests/clickhouse/test_array...
jyangballin/swesmith.x86_64.kayak_1776_pypika.1c9646f0
true
null
1
16
2
1,232
0
0.6
1
0.75
1
0.258667
81.051
6,393
swe_smith::train::18176
swe_smith
train
18,176
msiemens__tinydb.10644a0e.combine_file__07uxvexn
swesmith/msiemens__tinydb.10644a0e
msiemens/tinydb
python
null
LRUCache get method breaks cache ordering and __len__ returns incorrect value #### Description The LRUCache implementation has issues with the `get` method and `__len__` method that cause cache operations to fail. #### Steps/Code to Reproduce ```python from tinydb.utils import LRUCache # Test 1: get method breaks ...
diff --git a/tinydb/utils.py b/tinydb/utils.py index e1f01fb..cb9fd37 100644 --- a/tinydb/utils.py +++ b/tinydb/utils.py @@ -66,7 +66,7 @@ class LRUCache(abc.MutableMapping, Generic[K, V]): self.cache.clear() def __len__(self) -> int: - return self.length + return self.length - 1 de...
["tests/test_tables.py::test_query_cache_with_mutable_callable[memory]", "tests/test_tables.py::test_query_cache_with_mutable_callable[json]", "tests/test_tables.py::test_zero_cache_size[memory]", "tests/test_tables.py::test_zero_cache_size[json]", "tests/test_tables.py::test_query_cache_size[memory]", "tests/test_tabl...
["tests/test_middlewares.py::test_caching", "tests/test_middlewares.py::test_caching_read", "tests/test_middlewares.py::test_caching_write_many", "tests/test_middlewares.py::test_caching_flush", "tests/test_middlewares.py::test_caching_flush_manually", "tests/test_middlewares.py::test_caching_write", "tests/test_middle...
jyangballin/swesmith.x86_64.msiemens_1776_tinydb.10644a0e
true
null
1
16
17
1,231
0
0.6
1
0.75
1
0.2585
81.0505
6,394
swe_smith::train::45872
swe_smith
train
45,872
conan-io__conan.86f29e13.pr_10343
swesmith/conan-io__conan.86f29e13
conan-io/conan
python
null
**Unexpected Behavior with Profile Environment Handling** **Describe the bug** It seems there's an issue with how the `ProfileEnvironment` class processes certain profile entries. Specifically, when using the `(sep=@)` and `(path)` qualifiers, the behavior is not as expected. The combination of these qualifiers should...
diff --git a/conan/tools/env/environment.py b/conan/tools/env/environment.py index b5ef89f..ee9b1c2 100644 --- a/conan/tools/env/environment.py +++ b/conan/tools/env/environment.py @@ -636,26 +636,12 @@ class ProfileEnvironment: pattern, name = pattern_name else: ...
["test/integration/environment/test_env.py::test_profile_build_env_spaces", "test/unittests/tools/env/test_env.py::test_profile", "test/unittests/tools/env/test_env.py::TestProfileEnvRoundTrip::test_define", "test/unittests/tools/env/test_env.py::TestProfileEnvRoundTrip::test_append", "test/unittests/tools/env/test_env...
["test/integration/environment/test_env.py::test_complete[True]", "test/integration/environment/test_env.py::test_complete[False]", "test/integration/environment/test_env.py::test_profile_included_multiple", "test/integration/environment/test_env.py::test_profile_buildenv", "test/integration/environment/test_env.py::te...
jyangballin/swesmith.x86_64.conan-io_1776_conan.86f29e13
true
null
1
18
7
1,191
0
0.6
1
0.75
1
0.2585
81.0505
6,395
swe_smith::train::39642
swe_smith
train
39,642
tornadoweb__tornado.d5ac65c1.combine_file__93691q65
swesmith/tornadoweb__tornado.d5ac65c1
tornadoweb/tornado
python
null
Option parsing broken for multiple integer ranges and config files #### Description When using multiple integer options with range syntax (e.g., `1:5,10:15`) or parsing config files with non-string values, the option parser fails with type errors. #### Steps/Code to Reproduce ```python from tornado.options import O...
diff --git a/tornado/options.py b/tornado/options.py index b6578bb..9d016f8 100644 --- a/tornado/options.py +++ b/tornado/options.py @@ -292,13 +292,13 @@ class OptionParser: file_name = "" if type is None: if not multiple and default is not None: - type = default.__cla...
["test_dash_underscore_cli (tornado.test.options_test.OptionsTest)", "test_dash_underscore_file (tornado.test.options_test.OptionsTest)", "test_dash_underscore_introspection (tornado.test.options_test.OptionsTest)", "test_group_dict (tornado.test.options_test.OptionsTest)", "test_mock_patch (tornado.test.options_test.O...
["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
19
12
1,171
0
0.6
1
0.75
1
0.2585
81.0505
6,396
swe_smith::train::5092
swe_smith
train
5,092
agronholm__exceptiongroup.0b4f4937.combine_module__9lvhskem
swesmith/agronholm__exceptiongroup.0b4f4937
agronholm/exceptiongroup
python
null
ExceptionGroup.derive() modifies message and reverses exception order #### Description When using `ExceptionGroup.derive()` to create a new exception group, the method unexpectedly modifies the original message by converting it to uppercase and reverses the order of exceptions in the sequence. #### Steps/Code to Rep...
diff --git a/src/exceptiongroup/_exceptions.py b/src/exceptiongroup/_exceptions.py index a4a7ace..138c0ed 100644 --- a/src/exceptiongroup/_exceptions.py +++ b/src/exceptiongroup/_exceptions.py @@ -253,7 +253,7 @@ class BaseExceptionGroup(BaseException, Generic[_BaseExceptionT_co]): def derive( self, __exc...
["tests/test_catch.py::test_catch_group", "tests/test_catch.py::test_catch_nested_group", "tests/test_exceptions.py::ExceptionGroupSubgroupTests::test_basics_subgroup_by_predicate__match", "tests/test_exceptions.py::ExceptionGroupSubgroupTests::test_basics_subgroup_by_type__match", "tests/test_exceptions.py::ExceptionG...
["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
8
24
1,391
0
0.6
1
0.75
1
0.2585
81.0505
6,397
swe_smith::train::32456
swe_smith
train
32,456
pydantic__pydantic.acb0f10f.combine_module__z1fhh5gn
swesmith/pydantic__pydantic.acb0f10f
pydantic/pydantic
python
null
@validate_arguments decorator breaks with positional argument error calculation #### Description When using the `@validate_arguments` decorator, the error message for too many positional arguments shows an incorrect count. The error message displays a negative number instead of the actual number of arguments provided...
diff --git a/pydantic/deprecated/class_validators.py b/pydantic/deprecated/class_validators.py index ad92864..452bd21 100644 --- a/pydantic/deprecated/class_validators.py +++ b/pydantic/deprecated/class_validators.py @@ -246,11 +246,9 @@ def root_validator( wrap = partial(_decorators_v1.make_v1_generic_root_valida...
["tests/test_deprecated.py::test_deprecated_module", "tests/test_deprecated_validate_arguments.py::test_args", "tests/test_deprecated_validate_arguments.py::test_wrap", "tests/test_deprecated_validate_arguments.py::test_kwargs", "tests/test_deprecated_validate_arguments.py::test_untyped", "tests/test_deprecated_validat...
["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
20
20
1,150
0
0.6
1
0.75
1
0.258333
81.05
6,398
swe_smith::train::44555
swe_smith
train
44,555
pydata__patsy.a5d16484.pr_90
swesmith/pydata__patsy.a5d16484
pydata/patsy
python
null
LinearConstraint with all-zero coefficient rows should raise ValueError #### Description When creating a LinearConstraint with coefficient rows that are all zeros, the constructor should raise a ValueError with the message "can't test a constant constraint". Currently, this validation is missing and such constraints ...
diff --git a/patsy/constraint.py b/patsy/constraint.py index 6c04414..a22e272 100644 --- a/patsy/constraint.py +++ b/patsy/constraint.py @@ -65,6 +65,8 @@ class LinearConstraint(object): raise ValueError("must have at least one row in constraint matrix") if self.coefs.shape[0] != self.constants.sh...
["patsy/constraint.py::test_LinearConstraint"]
["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
31
1
930
0
0.6
1
0.75
1
0.258333
81.05
6,399
swe_smith::train::17263
swe_smith
train
17,263
kennethreitz__records.5941ab27.combine_file__6me5ci4d
swesmith/kennethreitz__records.5941ab27
kennethreitz/records
python
null
RecordCollection indexing and slicing returns wrong type and values #### Description When accessing RecordCollection items by index or slice, the behavior is inconsistent and returns unexpected results. Single item access returns the wrong record, and slicing returns a raw list instead of a RecordCollection. #### St...
diff --git a/records.py b/records.py index b5b6766..c92db41 100644 --- a/records.py +++ b/records.py @@ -36,7 +36,7 @@ class Record(object): def keys(self): """Returns the list of column names from the query.""" - return self._keys + return self._keys[::-1] def values(self): ...
["tests/test_105.py::test_issue105[sqlite_memory]", "tests/test_records.py::TestRecordCollection::test_slice_iter", "tests/test_records.py::TestRecordCollection::test_first_returns_a_single_record", "tests/test_records.py::TestRecordCollection::test_first_default_is_overridable", "tests/test_records.py::TestRecordColle...
["tests/test_69.py::test_issue69[sqlite_memory]", "tests/test_records.py::TestRecordCollection::test_iter", "tests/test_records.py::TestRecordCollection::test_next", "tests/test_records.py::TestRecordCollection::test_iter_and_next", "tests/test_records.py::TestRecordCollection::test_multiple_iter", "tests/test_records....
jyangballin/swesmith.x86_64.kennethreitz_1776_records.5941ab27
true
null
1
11
20
1,329
0
0.6
1
0.75
1
0.258167
81.0495