Dataset Viewer
Auto-converted to Parquet Duplicate
instance_id
stringlengths
15
28
hints_text
stringlengths
0
14.4k
patch
stringlengths
296
7.36k
test_patch
stringlengths
377
27.2k
created_at
stringlengths
19
20
problem_statement
stringlengths
542
1.91M
repo
stringclasses
11 values
base_commit
stringlengths
40
40
version
stringlengths
3
7
PASS_TO_PASS
sequencelengths
0
2.84k
FAIL_TO_PASS
sequencelengths
1
17
getmoto__moto-5752
Here's the culprit: https://github.com/spulec/moto/blob/8f074b0799e4e5303f219549e177d52b016c2dfb/moto/ssm/models.py#L1612 That line returns True from the middle of the for loop. But that function is supposed to only return False from the for loop, and True at the end. A solution would be something like: ```...
diff --git a/moto/ssm/models.py b/moto/ssm/models.py --- a/moto/ssm/models.py +++ b/moto/ssm/models.py @@ -1606,22 +1606,26 @@ def _match_filters(self, parameter, filters=None): else: continue elif key.startswith("tag:"): - what = key[4:] or None - ...
diff --git a/tests/test_ssm/test_ssm_boto3.py b/tests/test_ssm/test_ssm_boto3.py --- a/tests/test_ssm/test_ssm_boto3.py +++ b/tests/test_ssm/test_ssm_boto3.py @@ -67,21 +67,14 @@ def test_delete_parameters(): def test_get_parameters_by_path(): client = boto3.client("ssm", region_name="us-east-1") - client.pu...
2022-12-10 20:23:01
=================================== FAILURES =================================== ___________________ test_describe_parameters__multiple_tags ____________________ self = <sure.AssertionBuilder object at 0x7f8710692d50>, args = (1,), kw = {} @wraps(func) def wrapper(self, *args, **kw): try: > ...
getmoto/moto
b2300f1eae1323e3e8bc45f97e530ce129dff12e
4.0
[ "tests/test_ssm/test_ssm_boto3.py::test_get_parameters_should_only_return_unique_requests", "tests/test_ssm/test_ssm_boto3.py::test_describe_parameters_attributes", "tests/test_ssm/test_ssm_boto3.py::test_describe_parameters_invalid_parameter_filters[filters6-The", "tests/test_ssm/test_ssm_boto3.py::test_desc...
[ "tests/test_ssm/test_ssm_boto3.py::test_describe_parameters__multiple_tags" ]
getmoto__moto-6178
I thought I could attach my example code to the ticket. Looks like that won't work. Instead here it is pasted inline: import boto3 import json import unittest from datetime import datetime, timedelta from moto import mock_dynamodb # Reported to the moto project on github as: # h...
diff --git a/moto/dynamodb/parsing/key_condition_expression.py b/moto/dynamodb/parsing/key_condition_expression.py --- a/moto/dynamodb/parsing/key_condition_expression.py +++ b/moto/dynamodb/parsing/key_condition_expression.py @@ -160,8 +160,10 @@ def parse_expression( if crnt_char == "(": # hashk...
diff --git a/tests/test_dynamodb/models/test_key_condition_expression_parser.py b/tests/test_dynamodb/models/test_key_condition_expression_parser.py --- a/tests/test_dynamodb/models/test_key_condition_expression_parser.py +++ b/tests/test_dynamodb/models/test_key_condition_expression_parser.py @@ -179,6 +179,24 @@ def ...
2023-04-05 01:41:06
=================================== FAILURES =================================== ____ TestHashAndRangeKey.test_brackets[job_id = :id and (start_date = :sk)] ____ self = <test_key_condition_expression_parser.TestHashAndRangeKey object at 0x7f7644cc95b0> expr = 'job_id = :id and (start_date = :sk)' @pytest.mark.par...
getmoto/moto
9f91ac0eb96b1868905e1555cb819757c055b652
4.1
[ "tests/test_dynamodb/models/test_key_condition_expression_parser.py::TestHashAndRangeKey::test_reverse_keys[begins_with(start_date,:sk)", "tests/test_dynamodb/models/test_key_condition_expression_parser.py::TestHashKey::test_unknown_hash_key", "tests/test_dynamodb/models/test_key_condition_expression_parser.py:...
[ "tests/test_dynamodb/models/test_key_condition_expression_parser.py::TestHashAndRangeKey::test_brackets[(job_id", "tests/test_dynamodb/models/test_key_condition_expression_parser.py::TestHashAndRangeKey::test_brackets[job_id" ]
getmoto__moto-5865
Thanks for raising this @Bharat23 - marking it as an enhancement to implement this validation. Just as an implementation note: the docs state that `If you do not specify a cluster, the default cluster is assumed.` Which means that the same error may be raised if you do not specify a cluster, and the `default` cluste...
diff --git a/moto/ecs/models.py b/moto/ecs/models.py --- a/moto/ecs/models.py +++ b/moto/ecs/models.py @@ -808,7 +808,7 @@ def default_vpc_endpoint_service(service_region, zones): service_region, zones, "ecs" ) - def _get_cluster(self, name): + def _get_cluster(self, name: str) -> Cluster:...
diff --git a/tests/test_ecs/test_ecs_boto3.py b/tests/test_ecs/test_ecs_boto3.py --- a/tests/test_ecs/test_ecs_boto3.py +++ b/tests/test_ecs/test_ecs_boto3.py @@ -701,6 +701,17 @@ def test_list_services(): cluster1_fargate_services["serviceArns"][0].should.equal(test_ecs_service2_arn) +@mock_ecs +@pytest.mark....
2023-01-22 11:05:01
=================================== FAILURES =================================== ______________________ test_list_unknown_service[no args] ______________________ args = {} @mock_ecs @pytest.mark.parametrize("args", [{}, {"cluster": "foo"}], ids=["no args", "unknown"]) def test_list_unknown_service(args): ...
getmoto/moto
90e63c1cb5178acaa49cfc301b2688dcaba12115
4.1
[ "tests/test_ecs/test_ecs_boto3.py::test_update_missing_service", "tests/test_ecs/test_ecs_boto3.py::test_start_task_with_tags", "tests/test_ecs/test_ecs_boto3.py::test_update_service", "tests/test_ecs/test_ecs_boto3.py::test_list_task_definitions_with_family_prefix", "tests/test_ecs/test_ecs_boto3.py::test_...
[ "tests/test_ecs/test_ecs_boto3.py::test_list_unknown_service[unknown]", "tests/test_ecs/test_ecs_boto3.py::test_list_unknown_service[no" ]
getmoto__moto-5545
Hi @hannes-ucsc, thanks for raising this and providing the fix! Much appreciated
diff --git a/moto/s3/models.py b/moto/s3/models.py --- a/moto/s3/models.py +++ b/moto/s3/models.py @@ -1421,6 +1421,18 @@ def __init__(self, region_name, account_id): "s3::keyrestore", transition={"progression": "immediate"} ) + def reset(self): + # For every key and multipart, Moto op...
diff --git a/tests/test_s3/test_s3_multipart.py b/tests/test_s3/test_s3_multipart.py --- a/tests/test_s3/test_s3_multipart.py +++ b/tests/test_s3/test_s3_multipart.py @@ -1,8 +1,10 @@ import boto3 import os +import gc import pytest import sure # noqa # pylint: disable=unused-import import requests +import warning...
2022-10-09 10:54:38
=================================== FAILURES =================================== ____________ test_reset_after_multipart_upload_closes_file_handles _____________ self = <sure.AssertionBuilder object at 0x7f5360f097c0> args = ([<class 'ResourceWarning'>],), kw = {} @wraps(func) def wrapper(self, *args, **kw): ...
getmoto/moto
1a8f93dce33f1c1c7983a8052ef54de30ff64407
4.0
[ "tests/test_s3/test_s3_multipart.py::test_head_object_returns_part_count", "tests/test_s3/test_s3_multipart.py::test_multipart_upload_should_return_part_10000", "tests/test_s3/test_s3_multipart.py::test_complete_multipart_with_empty_partlist", "tests/test_s3/test_s3_multipart.py::test_multipart_list_parts", ...
[ "tests/test_s3/test_s3_multipart.py::test_reset_after_multipart_upload_closes_file_handles" ]
getmoto__moto-4833
Hi @lynkfox, thanks for raising this. Looks like that's a bug on our side - we'll push out a fix shortly. This does work for classes that extend `unittest.TestCase`, where the setup-method should be called `setUp` (uppercase U), but not for plain classes where the `setup`-method should have a lowercase u.
diff --git a/moto/core/models.py b/moto/core/models.py --- a/moto/core/models.py +++ b/moto/core/models.py @@ -137,11 +137,15 @@ def decorate_class(self, klass): c for c in klass.__mro__ if c not in [unittest.TestCase, object] ] # Get a list of all userdefined methods - supermethod...
diff --git a/tests/test_core/test_decorator_calls.py b/tests/test_core/test_decorator_calls.py --- a/tests/test_core/test_decorator_calls.py +++ b/tests/test_core/test_decorator_calls.py @@ -109,8 +109,9 @@ def test_no_instance_sent_to_staticmethod(self): @mock_s3 -class TestWithSetup(unittest.TestCase): +class Te...
2022-02-04 23:14:17
=================================== FAILURES =================================== _______________ TestWithSetup_LowercaseU.test_should_find_bucket _______________ self = <tests.test_core.test_decorator_calls.TestWithSetup_LowercaseU object at 0x7f41be644b00> def test_should_find_bucket(self): s3 = boto3.cl...
getmoto/moto
bb6fb1200f8db61e0d39c9a4da5954469a403fb8
3.0
[ "tests/test_core/test_decorator_calls.py::TestWithNestedClasses::TestWithSetup::test_should_not_find_bucket_from_test_method", "tests/test_core/test_decorator_calls.py::TestSetUpInBaseClass::test_a_thing", "tests/test_core/test_decorator_calls.py::TestWithInvalidSetupMethod::test_should_not_find_bucket", "tes...
[ "tests/test_core/test_decorator_calls.py::TestWithSetup_LowercaseU::test_should_find_bucket", "tests/test_core/test_decorator_calls.py::TestWithSetupMethod::test_should_find_bucket" ]
getmoto__moto-7105
Hi @tzven0, can you share a reproducible test case? Hey, it might take some time, but i think i can. @tzven0 I've found one error scenario where the `submit_job` operation is called with the `arrayProperties` argument, but the test case does not wait for the execution of the job to finish. ``` def test_submit_job_a...
diff --git a/moto/batch/models.py b/moto/batch/models.py --- a/moto/batch/models.py +++ b/moto/batch/models.py @@ -1055,7 +1055,8 @@ def reset(self) -> None: if job.status not in (JobStatus.FAILED, JobStatus.SUCCEEDED): job.stop = True # Try to join - job.jo...
diff --git a/tests/test_batch/test_batch_jobs.py b/tests/test_batch/test_batch_jobs.py --- a/tests/test_batch/test_batch_jobs.py +++ b/tests/test_batch/test_batch_jobs.py @@ -1,15 +1,16 @@ import datetime import time +from unittest import SkipTest from uuid import uuid4 import botocore.exceptions import pytest ...
2023-12-09 23:39:02
=================================== FAILURES =================================== __________________________ test_submit_job_array_size __________________________ @mock_ec2 @mock_ecs @mock_iam @mock_batch @pytest.mark.network @requires_docker def test_submit_job_array_size(): # Setup...
getmoto/moto
85156f59396a85e83e83200c9df41b66d6f82b68
4.2
[ "tests/test_batch/test_batch_jobs.py::test_submit_job_by_name" ]
[ "tests/test_batch/test_batch_jobs.py::test_submit_job_with_timeout_set_at_definition", "tests/test_batch/test_batch_jobs.py::test_submit_job_with_timeout", "tests/test_batch/test_batch_jobs.py::test_register_job_definition_with_timeout", "tests/test_batch/test_batch_jobs.py::test_cancel_job_empty_argument_str...
getmoto__moto-6185
Appreciate the feedback @hidi-adouv, always good to hear that Moto is useful! When using the DynamoDB client, users have to manually set the type of their attributes - so in your example, with one Number-attribute and one String, that would result in this: `{'index': {'N': '0'}, 'S': {'S': 's'}}` Moto does some v...
diff --git a/moto/dynamodb/models/table.py b/moto/dynamodb/models/table.py --- a/moto/dynamodb/models/table.py +++ b/moto/dynamodb/models/table.py @@ -484,10 +484,12 @@ def _validate_key_sizes(self, item_attrs: Dict[str, Any]) -> None: if DynamoType(range_value).size() > RANGE_KEY_MAX_LENGTH: ...
diff --git a/tests/test_dynamodb/exceptions/test_dynamodb_exceptions.py b/tests/test_dynamodb/exceptions/test_dynamodb_exceptions.py --- a/tests/test_dynamodb/exceptions/test_dynamodb_exceptions.py +++ b/tests/test_dynamodb/exceptions/test_dynamodb_exceptions.py @@ -933,12 +933,21 @@ def test_put_item__string_as_intege...
2023-04-07 16:35:37
=================================== FAILURES =================================== ____________________ test_put_item__string_as_integer_value ____________________ @mock_dynamodb def test_put_item__string_as_integer_value(): if settings.TEST_SERVER_MODE: raise SkipTest("Unable to mock a sessi...
getmoto/moto
dc460a325839bc6797084a54afc297a2c9d87e63
4.1
[ "tests/test_dynamodb/exceptions/test_dynamodb_exceptions.py::test_query_gsi_with_wrong_key_attribute_names_throws_exception", "tests/test_dynamodb/exceptions/test_dynamodb_exceptions.py::test_update_primary_key", "tests/test_dynamodb/exceptions/test_dynamodb_exceptions.py::test_creating_table_with_0_local_index...
[ "tests/test_dynamodb/exceptions/test_dynamodb_exceptions.py::test_put_item__string_as_integer_value" ]
getmoto__moto-6212
Thanks for letting us know @dani-g1 - that is indeed a bug. Will raise a fix shortly.
"diff --git a/moto/athena/models.py b/moto/athena/models.py\n--- a/moto/athena/models.py\n+++ b/moto(...TRUNCATED)
"diff --git a/tests/test_athena/test_athena.py b/tests/test_athena/test_athena.py\n--- a/tests/test_(...TRUNCATED)
2023-04-14 19:13:35
"=================================== FAILURES ===================================\n_________________(...TRUNCATED)
getmoto/moto
8c0c688c7b37f87dfcc00dbf6318d4dd959f91f5
4.1
["tests/test_athena/test_athena.py::test_create_and_get_workgroup","tests/test_athena/test_athena.py(...TRUNCATED)
[ "tests/test_athena/test_athena.py::test_get_primary_workgroup" ]
getmoto__moto-6469
"@bblommers I can take a look\n@semyonestrin this appears to be the correct behaviour. Try this in a(...TRUNCATED)
"diff --git a/moto/secretsmanager/models.py b/moto/secretsmanager/models.py\n--- a/moto/secretsmanag(...TRUNCATED)
"diff --git a/tests/test_secretsmanager/test_secretsmanager.py b/tests/test_secretsmanager/test_secr(...TRUNCATED)
2023-06-30 21:22:44
"=================================== FAILURES ===================================\n______________ te(...TRUNCATED)
getmoto/moto
3e11578a7288122e7f2c2a0238c3338f56f8582f
4.1
["tests/test_secretsmanager/test_secretsmanager.py::test_get_secret_that_has_no_value","tests/test_s(...TRUNCATED)
["tests/test_secretsmanager/test_secretsmanager.py::test_delete_secret_recovery_window_invalid_value(...TRUNCATED)
getmoto__moto-7111
"Hi @omerls-pw, welcome to Moto, and thanks for raising this.\r\n\r\nIf PackageType is specified dur(...TRUNCATED)
"diff --git a/moto/awslambda/models.py b/moto/awslambda/models.py\n--- a/moto/awslambda/models.py\n+(...TRUNCATED)
"diff --git a/tests/test_awslambda/__init__.py b/tests/test_awslambda/__init__.py\n--- a/tests/test_(...TRUNCATED)
2023-12-10 19:42:21
"=================================== FAILURES ===================================\n_________________(...TRUNCATED)
getmoto/moto
90850bc57314b2c7fa62b4917577b1a24a528f25
4.2
["tests/test_awslambda/test_lambda.py::test_put_event_invoke_config[config0]","tests/test_awslambda/(...TRUNCATED)
["tests/test_awslambda/test_lambda.py::test_list_functions","tests/test_awslambda/test_lambda.py::te(...TRUNCATED)
End of preview. Expand in Data Studio
README.md exists but content is empty.
Downloads last month
21