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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1,400 | swe_gym::train::799 | swe_gym | train | 799 | iterative__dvc-4114 | iterative/dvc | iterative/dvc | python | ad306d7bf38582eda015d1708a4d7e25d236ee5a | version: redesign output
Current `dvc version` output is ugly, we could definitely do better:
```
DVC version: 0.89.0+9e96dd
Python version: 3.7.0
Platform: Linux-4.15.0-88-generic-x86_64-with-debian-buster-sid
Binary: False
Package: None
Supported remotes: azure, gdrive, gs, hdfs, http, https, s3, ssh, oss
Cache: ref... | maybe something like this yaml (btw need to look into possibly unifying analytics collection with this):
```
DVC: 0.89.0+9e96dd
Python: 3.7.0
Platform: Linux-4.15.0-88-generic-x86_64-with-debian-buster-sid
Binary: False ... | diff --git a/dvc/command/version.py b/dvc/command/version.py
--- a/dvc/command/version.py
+++ b/dvc/command/version.py
@@ -10,7 +10,7 @@
from dvc.exceptions import DvcException, NotDvcRepoError
from dvc.scm.base import SCMError
from dvc.system import System
-from dvc.utils import is_binary, relpath
+from dvc.utils i... | diff --git a/tests/func/test_version.py b/tests/func/test_version.py
--- a/tests/func/test_version.py
+++ b/tests/func/test_version.py
@@ -16,15 +16,10 @@ def test_info_in_repo(scm_init, tmp_dir, caplog):
assert main(["version"]) == 0
- assert re.search(r"DVC version: \d+\.\d+\.\d+", caplog.text)
- asser... | ["tests/func/test_version.py::test_fs_info_in_repo"] | ["tests/func/test_version.py::test_info_in_subdir", "tests/func/test_version.py::test_info_in_broken_git_repo", "tests/func/test_version.py::test_fs_info_outside_of_repo"] | null | true | 2020-06-25T15:55:44Z | 1 | 47 | 1 | 549 | 0 | 0.85 | 1 | 0.55 | 1 | 0.248167 | 82.0695 | |
1,401 | swe_bench_pro::test::166 | swe_bench_pro | test | 166 | instance_element-hq__element-web-ee13e23b156fbad9369d6a656c827b6444343d4f-vnan | element-hq/element-web | element-hq/element-web | javascript | 8ebdcab7d92f90422776c4390363338dcfd98ba5 | ## Title: `RoomHeaderButtons` can crash when thread notifications are unsupported or when the `room` prop is missing.
## Description:
When interacting with homeservers that don't support thread notifications, the component still attempts to access thread-related state, which can trigger runtime errors. Additionally, ... | ## Requirements
- The `RoomHeaderButtons` constructor must resolve and store the threads room notification state only when `props.room` exists and the homeserver does not support thread notifications; in every other case (no room, or thread notifications supported) the stored thread notification state must be left unse... | diff --git a/src/components/views/right_panel/RoomHeaderButtons.tsx b/src/components/views/right_panel/RoomHeaderButtons.tsx
index c6e012fff4c..0ba64c2f5e6 100644
--- a/src/components/views/right_panel/RoomHeaderButtons.tsx
+++ b/src/components/views/right_panel/RoomHeaderButtons.tsx
@@ -30,7 +30,6 @@ import { RightPan... | diff --git a/test/components/views/right_panel/RoomHeaderButtons-test.tsx b/test/components/views/right_panel/RoomHeaderButtons-test.tsx
index 5d873f4b86..62a3dbf34c 100644
--- a/test/components/views/right_panel/RoomHeaderButtons-test.tsx
+++ b/test/components/views/right_panel/RoomHeaderButtons-test.tsx
@@ -16,6 +16,... | ["test/components/views/right_panel/RoomHeaderButtons-test.tsx | RoomHeaderButtons-test.tsx | does not explode without a room", "test/components/views/right_panel/RoomHeaderButtons-test.tsx | RoomHeaderButtons-test.tsx | does not explode without a room when thread notifications are supported"] | ["test/components/views/settings/shared/SettingsSubsection-test.tsx | <SettingsSubsection /> | renders with plain text heading", "test/components/views/settings/shared/SettingsSubsection-test.tsx | <SettingsSubsection /> | renders with react element heading", "test/components/views/settings/shared/SettingsSubsection-te... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_element-hq__element-web-ee13e23b156fbad9369d6a656c827b6444343d4f-vnan | true | null | 1 | 40 | 2 | 882 | 0 | 0.95 | 1 | 0.55 | 1 | 0.280333 | 82.066 | |
1,402 | swe_bench_pro::test::123 | swe_bench_pro | test | 123 | instance_element-hq__element-web-27139ca68eb075a4438c18fca184887002a4ffbc-vnan | element-hq/element-web | element-hq/element-web | javascript | 29f9ccfb633dd2bac9082fff9016b90945a77b53 | ## Title: Selection restoration in the WYSIWYG composer is not available as a reusable utility
## Current Behavior
Logic to restore a text selection in the WYSIWYG composer through manual range manipulation is not exposed as a standalone, reusable utility. As a result, restoring a previously captured selection cannot... | ## Requirements
- A utility function named `setSelection` should allow restoring a text selection when provided with anchor and focus information.
- When valid anchor and focus information is provided, the current document selection should reflect the given start and end positions, so that inserting content afterward ... | diff --git a/src/components/views/rooms/wysiwyg_composer/hooks/useSelection.ts b/src/components/views/rooms/wysiwyg_composer/hooks/useSelection.ts
index 62d5d1a3cbe..2ae61790dbf 100644
--- a/src/components/views/rooms/wysiwyg_composer/hooks/useSelection.ts
+++ b/src/components/views/rooms/wysiwyg_composer/hooks/useSele... | diff --git a/test/components/views/rooms/wysiwyg_composer/SendWysiwygComposer-test.tsx b/test/components/views/rooms/wysiwyg_composer/SendWysiwygComposer-test.tsx
index bd080331a9..27cafe65f3 100644
--- a/test/components/views/rooms/wysiwyg_composer/SendWysiwygComposer-test.tsx
+++ b/test/components/views/rooms/wysiwyg... | ["test/components/views/rooms/wysiwyg_composer/SendWysiwygComposer-test.tsx | Emoji when { isRichTextEnabled: true } | Should add an emoji in an empty composer", "test/components/views/rooms/wysiwyg_composer/SendWysiwygComposer-test.tsx | Emoji when { isRichTextEnabled: true } | Should add an emoji in the middle of a w... | ["test/audio/Playback-test.ts | Playback | initialises correctly", "test/audio/Playback-test.ts | Playback | toggles playback on from stopped state", "test/audio/Playback-test.ts | Playback | toggles playback to paused from playing state", "test/audio/Playback-test.ts | Playback | stop playbacks", "test/audio/Playback-... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_element-hq__element-web-27139ca68eb075a4438c18fca184887002a4ffbc-vnan | true | null | 2 | 40 | 3 | 881 | 0 | 0.95 | 1 | 0.55 | 1 | 0.280167 | 82.0655 | |
1,403 | swe_bench_pro::test::516 | swe_bench_pro | test | 516 | instance_protonmail__webclients-0ec14e36ceb01ba45602a563e12352af8171ed39 | protonmail/webclients | protonmail/webclients | javascript | bf575a521f3789c0b7e99969ad22a15c78165991 | # Title: Expiration modal shows incorrect minimum time when using scheduling logic.
## Description:
The expiration time input in the self-destruct message modal currently relies on scheduling logic that was not designed for expiration. As a result, the minimum time constraint may not accurately reflect the intended r... | ## Requirements
- The expiration helpers should export a function named `getMinExpirationTime` that receives a `Date` and computes the minimal valid time for the expiration input.
- `getMinExpirationTime` should return `undefined` when the provided date is not the same local calendar day as “now”, so no minimum constr... | diff --git a/applications/mail/src/app/components/message/modals/CustomExpirationModal.tsx b/applications/mail/src/app/components/message/modals/CustomExpirationModal.tsx
index 78521d01a65..1d771732b95 100644
--- a/applications/mail/src/app/components/message/modals/CustomExpirationModal.tsx
+++ b/applications/mail/src... | diff --git a/applications/mail/src/app/helpers/expiration.test.ts b/applications/mail/src/app/helpers/expiration.test.ts
index bc4c367c1b1..62bb3f0a2b8 100644
--- a/applications/mail/src/app/helpers/expiration.test.ts
+++ b/applications/mail/src/app/helpers/expiration.test.ts
@@ -1,10 +1,10 @@
-import { addDays } from ... | ["src/app/helpers/expiration.test.ts | getMinExpirationTime should return undefined if date is not today", "src/app/helpers/expiration.test.ts | getMinExpirationTime should return a Date if date is today", "src/app/helpers/expiration.test.ts | getMinExpirationTime should return a Date with minutes set to 0 or 30", "src... | ["src/app/helpers/expiration.test.ts | canSetExpiration should return false if feature flag is false", "src/app/helpers/expiration.test.ts | canSetExpiration should return false if user is free", "src/app/helpers/expiration.test.ts | canSetExpiration should return true if feature flag is true and user is paid", "src/ap... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_protonmail__webclients-0ec14e36ceb01ba45602a563e12352af8171ed39 | true | null | 2 | 30 | 4 | 1,064 | 0 | 0.95 | 1 | 0.55 | 1 | 0.277333 | 82.057 | |
1,404 | swe_gym::train::1053 | swe_gym | train | 1,053 | pydantic__pydantic-6104 | pydantic/pydantic | pydantic/pydantic | python | 493be96bb627edc9a665be52569ee14d5febb374 | RootModel's `model_json_schema` miss field `title` and `description`
### Initial Checks
- [X] I confirm that I'm using Pydantic V2 installed directly from the `main` branch, or equivalent
### Description
`SelloutList` expects a title named `SelloutList`, but gets a `None`
By default, we should use the name of the c... | Thanks @luolingchun for reporting this.
I can confirm the problem. | diff --git a/pydantic/_internal/_generate_schema.py b/pydantic/_internal/_generate_schema.py
--- a/pydantic/_internal/_generate_schema.py
+++ b/pydantic/_internal/_generate_schema.py
@@ -156,6 +156,11 @@ def modify_model_json_schema(
"""Add title and description for model-like classes' JSON schema."""
json_sc... | diff --git a/tests/test_json_schema.py b/tests/test_json_schema.py
--- a/tests/test_json_schema.py
+++ b/tests/test_json_schema.py
@@ -1657,6 +1657,22 @@ class Outer(BaseModel):
}
+def test_model_subclass_metadata():
+ class A(BaseModel):
+ """A Model docstring"""
+
+ class B(A):
+ pass
+
+... | ["tests/test_json_schema.py::test_root_model", "tests/test_root_model.py::test_root_model_json_schema_meta"] | ["tests/test_json_schema.py::test_ipv6network_type", "tests/test_json_schema.py::test_schema_attributes", "tests/test_root_model.py::test_validate_assignment_false", "tests/test_json_schema.py::test_secrets_schema[min-max-constraints-SecretStr]", "tests/test_json_schema.py::test_dataclass_with_extra_ignore", "tests/tes... | null | true | 2023-06-13T08:18:56Z | 1 | 7 | 2 | 1,323 | 0 | 0.85 | 1 | 0.55 | 1 | 0.243833 | 82.0565 | |
1,405 | swe_bench_pro::test::179 | swe_bench_pro | test | 179 | instance_flipt-io__flipt-21a935ad7886cc50c46852be21b37f363a926af0 | flipt-io/flipt | flipt-io/flipt | go | 4e1cd36398ee73acf7d9235b517f05178651c464 | # Title
gRPC logging level cannot be configured via application config
## Description
The configuration currently has logging fields like `level`, `file`, and `encoding`, but there is no dedicated option to represent the gRPC logging level. As a result, users cannot declare a gRPC-specific verbosity in configuration, ... | ## Requirements
- `LogConfig` should include a new `grpc_level` field (string) that defaults to `"ERROR"` when unspecified; the default should be applied by `Default()`.
- The loaded runtime configuration produced for a configuration source should carry the gRPC logging level on `cfg.Log.GRPCLevel`, populated from the... | diff --git a/cmd/flipt/main.go b/cmd/flipt/main.go
index 1864011685..7e4a39241b 100644
--- a/cmd/flipt/main.go
+++ b/cmd/flipt/main.go
@@ -461,6 +461,16 @@ func run(ctx context.Context, logger *zap.Logger) error {
opentracing.SetGlobalTracer(tracer)
+ {
+ // forward internal gRPC logging to zap
+ grpcLogLev... | diff --git a/config/config_test.go b/config/config_test.go
index 4caefbe..37b48cf 100644
--- a/config/config_test.go
+++ b/config/config_test.go
@@ -240,9 +240,10 @@ func TestLoad(t *testing.T) {
expected: func() *Config {
cfg := Default()
cfg.Log = LogConfig{
- Level: "WARN",
- File: "test... | ["TestLogEncoding", "TestLoad", "TestLoad/grpc_level_provided", "TestValidate", "TestServeHTTP"] | [] | ghcr.io/scaleapi/swe-bench_pro-v2:instance_flipt-io__flipt-21a935ad7886cc50c46852be21b37f363a926af0 | true | null | 2 | 33 | 5 | 1,002 | 0 | 0.95 | 1 | 0.55 | 1 | 0.277 | 82.056 | |
1,406 | swe_bench_pro::test::623 | swe_bench_pro | test | 623 | instance_qutebrowser__qutebrowser-e34dfc68647d087ca3175d9ad3f023c30d8c9746-v363c8a7e5ccdf6968fc7ab84a2053ac78036691d | qutebrowser/qutebrowser | qutebrowser/qutebrowser | python | c984983bc4cf6f9148e16ea17369597f67774ff9 | ## Title
Address Bar Incorrectly Handles Search Terms with Special Characters and Spaces
## Description
When search terms containing spaces or special characters are typed in the address bar, the browser sometimes treats them as URLs instead of search queries. This causes navigation errors or unexpected behavior where... | ## Requirements
- Distinguish between valid search engine prefixes (those present in `url.searchengines`) and regular input; if a prefix is unrecognized, treat the whole string as the search term.
- When constructing a search URL, use the engine's template only if a query term is provided. Format the configured engine... | diff --git a/qutebrowser/utils/urlutils.py b/qutebrowser/utils/urlutils.py
index 0f06d0b15f3..c761ef3b056 100644
--- a/qutebrowser/utils/urlutils.py
+++ b/qutebrowser/utils/urlutils.py
@@ -67,7 +67,8 @@ def __init__(self, url: QUrl) -> None:
super().__init__(self.msg)
-def _parse_search_term(s: str) -> typ... | diff --git a/tests/unit/utils/test_urlutils.py b/tests/unit/utils/test_urlutils.py
index 6bc4c22b3e1..b6d73319db1 100644
--- a/tests/unit/utils/test_urlutils.py
+++ b/tests/unit/utils/test_urlutils.py
@@ -29,7 +29,7 @@
from qutebrowser.api import cmdutils
from qutebrowser.browser.network import pac
-from qutebrowse... | ["tests/unit/utils/test_urlutils.py::TestFuzzyUrl::test_invalid_url[True]", "tests/unit/utils/test_urlutils.py::test_get_search_url[test path-search-www.qutebrowser.org-q=path-search-True]", "tests/unit/utils/test_urlutils.py::test_is_url[dns-True-True-False-http://sharepoint/sites/it/IT%20Documentation/Forms/AllItems.... | ["tests/unit/utils/test_urlutils.py::TestFuzzyUrl::test_file_relative_cwd", "tests/unit/utils/test_urlutils.py::TestFuzzyUrl::test_file_relative", "tests/unit/utils/test_urlutils.py::TestFuzzyUrl::test_file_relative_os_error", "tests/unit/utils/test_urlutils.py::TestFuzzyUrl::test_file_absolute[/foo-expected0]", "tests... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_qutebrowser__qutebrowser-e34dfc68647d087ca3175d9ad3f023c30d8c9746-v363c8a7e5ccdf6968fc7ab84a2053ac78036691d | true | null | 1 | 58 | 11 | 497 | 0 | 0.95 | 1 | 0.55 | 1 | 0.276167 | 82.0535 | |
1,407 | swe_gym::train::2027 | swe_gym | train | 2,027 | Project-MONAI__MONAI-3782 | Project-MONAI/MONAI | project-monai/monai | python | 7c9fefb55e13007e798f04bccc560718b3b03dbb | ViT does not support torchscript
~~class `PatchEmbeddingBlock` does not support torchscript, due to the module `einops.layers.torch.Rearrange` used.~~
Update (02.09.2022) After Einops v0.4.0 released, it supports torchscript now, but the current ViT implementation still cannot support torchscript directly, some change... | see also #3428
Hi @yiheng-wang-nv
Maybe you look at this:
https://github.com/arogozhnikov/einops/blob/45e795f122840beec70f0e1970b1e37b5809a8e6/tests/test_layers.py#L188
torchscript works on Rearrange.
| diff --git a/monai/networks/blocks/patchembedding.py b/monai/networks/blocks/patchembedding.py
--- a/monai/networks/blocks/patchembedding.py
+++ b/monai/networks/blocks/patchembedding.py
@@ -80,7 +80,7 @@ def __init__(
if self.pos_embed == "perceptron" and m % p != 0:
raise ValueError("pat... | diff --git a/tests/test_vit.py b/tests/test_vit.py
--- a/tests/test_vit.py
+++ b/tests/test_vit.py
@@ -16,6 +16,7 @@
from monai.networks import eval_mode
from monai.networks.nets.vit import ViT
+from tests.utils import SkipIfBeforePyTorchVersion, test_script_save
TEST_CASE_Vit = []
for dropout_rate in [0.6]:
@@... | ["tests/test_vit.py::TestPatchEmbeddingBlock::test_script_13", "tests/test_vit.py::TestPatchEmbeddingBlock::test_script_05", "tests/test_vit.py::TestPatchEmbeddingBlock::test_script_12", "tests/test_vit.py::TestPatchEmbeddingBlock::test_script_11", "tests/test_vit.py::TestPatchEmbeddingBlock::test_script_09", "tests/te... | ["tests/test_vit.py::TestPatchEmbeddingBlock::test_shape_04", "tests/test_vit.py::TestPatchEmbeddingBlock::test_shape_01", "tests/test_vit.py::TestPatchEmbeddingBlock::test_shape_03", "tests/test_vit.py::TestPatchEmbeddingBlock::test_shape_07", "tests/test_vit.py::TestPatchEmbeddingBlock::test_shape_14", "tests/test_vi... | null | true | 2022-02-09T09:07:29Z | 3 | 17 | 16 | 1,102 | 0 | 0.85 | 1 | 0.55 | 1 | 0.240333 | 82.046 | |
1,408 | swe_gym::train::2363 | swe_gym | train | 2,363 | modin-project__modin-6951 | modin-project/modin | modin-project/modin | python | 4704751c4440574ce59b9948e88e6991e1d3183b | Poor Performance on TPC-H Queries
In a benchmark project ([link](https://github.com/hesamshahrokhi/modin_tpch_benchmark)), I tried to compare the performance of Pandas and Modin (on Ray and Dask) on simple TPC-H queries (Q1 and Q6) written in Pandas. The results ([link](https://github.com/hesamshahrokhi/modin_tpch_benc... | Hi @hesamshahrokhi! Thanks for the question!
The method you use to initialize dask is not intended for Modin:
https://github.com/hesamshahrokhi/modin_tpch_benchmark/blob/e7cf88cf5d6152c32593193a94c837f5fde4f298/tpch_dask.py#L12C17-L12C32. The `processes` parameter should be `True`. Could I also ask why you initiali... | diff --git a/modin/pandas/groupby.py b/modin/pandas/groupby.py
--- a/modin/pandas/groupby.py
+++ b/modin/pandas/groupby.py
@@ -22,6 +22,7 @@
import pandas.core.common as com
import pandas.core.groupby
from pandas._libs import lib
+from pandas.api.types import is_scalar
from pandas.core.apply import reconstruct_func... | diff --git a/modin/pandas/test/test_groupby.py b/modin/pandas/test/test_groupby.py
--- a/modin/pandas/test/test_groupby.py
+++ b/modin/pandas/test/test_groupby.py
@@ -3087,6 +3087,60 @@ def test_groupby_named_aggregation():
)
+def test_groupby_several_column_partitions():
+ # see details in #6948
+ colum... | ["modin/pandas/test/test_groupby.py::test_groupby_several_column_partitions"] | ["modin/pandas/test/test_groupby.py::test_agg_func_None_rename[False-by_and_agg_dict0]", "modin/pandas/test/test_groupby.py::test_validate_by", "modin/pandas/test/test_groupby.py::test_simple_row_groupby[col1_category=True-as_index=False-by5]", "modin/pandas/test/test_groupby.py::test_not_str_by[True-by4]", "modin/pand... | null | true | 2024-02-20T17:41:50Z | 1 | 32 | 1 | 794 | 0 | 0.85 | 1 | 0.55 | 1 | 0.239 | 82.042 | |
1,409 | swe_bench_pro::test::84 | swe_bench_pro | test | 84 | instance_ansible__ansible-a1569ea4ca6af5480cf0b7b3135f5e12add28a44-v0f01c69f1e2528b935359cfe578530722bca2c59 | ansible/ansible | ansible/ansible | python | f10d11bcdc54c9b7edc0111eb38c59a88e396d0a | ## Title: iptables chain creation should not add a default rule
### Description
When the iptables module creates a new chain with chain management and no rule parameters, it also adds a default rule to that chain.
The module should only create the chain, like the iptables command-line tool. After the chain exists, rul... | ## Requirements
- When `state: present` and there are no rule arguments, the `main` function should check the existence of the specified chain using `check_chain_present` and set `changed = True` only if the chain does not exist.
- If the chain does not exist, chain management is enabled, and it is not check mode, the... | diff --git a/changelogs/fragments/80257-iptables-chain-creation-does-not-populate-a-rule.yml b/changelogs/fragments/80257-iptables-chain-creation-does-not-populate-a-rule.yml
new file mode 100644
index 00000000000000..a449d5c2231962
--- /dev/null
+++ b/changelogs/fragments/80257-iptables-chain-creation-does-not-populat... | diff --git a/test/integration/targets/iptables/tasks/chain_management.yml b/test/integration/targets/iptables/tasks/chain_management.yml
index 035512289d2075..dae4103a2ca3d4 100644
--- a/test/integration/targets/iptables/tasks/chain_management.yml
+++ b/test/integration/targets/iptables/tasks/chain_management.yml
@@ -4... | ["test/units/modules/test_iptables.py::TestIptables::test_append_rule", "test/units/modules/test_iptables.py::TestIptables::test_append_rule_check_mode", "test/units/modules/test_iptables.py::TestIptables::test_chain_creation", "test/units/modules/test_iptables.py::TestIptables::test_chain_creation_check_mode", "test/u... | ["test/units/modules/test_iptables.py::TestIptables::test_chain_deletion", "test/units/modules/test_iptables.py::TestIptables::test_chain_deletion_check_mode", "test/units/modules/test_iptables.py::TestIptables::test_comment_position_at_end", "test/units/modules/test_iptables.py::TestIptables::test_destination_ports", ... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_ansible__ansible-a1569ea4ca6af5480cf0b7b3135f5e12add28a44-v0f01c69f1e2528b935359cfe578530722bca2c59 | true | null | 2 | 59 | 6 | 454 | 0 | 0.95 | 1 | 0.55 | 1 | 0.272333 | 82.042 | |
1,410 | swe_gym::train::1030 | swe_gym | train | 1,030 | dask__dask-6980 | dask/dask | dask/dask | python | 781b3eb5626f3cc74c7b4c69187f5cd941513a39 | Setting a sorted index drops rows
**What happened**:
Setting a sorted column with `object` dtype as index with argument `sorted=True` drops some rows from the data.
**What you expected to happen**:
I expect that setting an index does not drop rows.
**Minimal Complete Verifiable Example**:
```python
import dask.da... | Thanks for raising this @FilippoBovo ! I can definitely reproduce the problem. I'll try to figure out the cause soon.
I have been thinking through this, and the fix is proving to be a bit tricky.
In Dask-Dataframe, partitions are expected to be "non-overlapping." For your example, a "correctly" partitioned result... | diff --git a/dask/dataframe/shuffle.py b/dask/dataframe/shuffle.py
--- a/dask/dataframe/shuffle.py
+++ b/dask/dataframe/shuffle.py
@@ -1226,11 +1226,27 @@ def fix_overlap(ddf, overlap):
n = len(ddf.divisions) - 1
dsk = {(name, i): (ddf._name, i) for i in range(n)}
+ frames = []
for i in overlap:
- ... | diff --git a/dask/dataframe/tests/test_shuffle.py b/dask/dataframe/tests/test_shuffle.py
--- a/dask/dataframe/tests/test_shuffle.py
+++ b/dask/dataframe/tests/test_shuffle.py
@@ -1030,6 +1030,20 @@ def test_set_index_overlap():
assert_eq(a, b)
+def test_set_index_overlap_2():
+ data = pd.DataFrame(
+ ... | ["dask/dataframe/tests/test_shuffle.py::test_set_index_overlap_2"] | ["dask/dataframe/tests/test_shuffle.py::test_dataframe_shuffle_on_tasks_api[4-id-None]", "dask/dataframe/tests/test_shuffle.py::test_shuffle_from_one_partition_to_one_other[tasks]", "dask/dataframe/tests/test_shuffle.py::test_set_index_sorts", "dask/dataframe/tests/test_shuffle.py::test_set_index_sorted_single_partitio... | null | true | 2020-12-16T04:00:12Z | 1 | 20 | 1 | 1,033 | 0 | 0.85 | 1 | 0.55 | 1 | 0.238833 | 82.0415 | |
1,411 | swe_bench_pro::test::428 | swe_bench_pro | test | 428 | instance_internetarchive__openlibrary-91efee627df01e32007abf2d6ebf73f9d9053076-vbee42ad1b72fb23c6a1c874868a720b370983ed2 | internetarchive/openlibrary | internetarchive/openlibrary | python | ab62fa4d63d15b7bc1b9a856ae9acd74df1f1f93 | # Add a year-agnostic date-range check utility
## Description
There is currently no way in the date utility module to determine whether a date falls within a recurring month-and-day window while ignoring the year. Such a check is needed for seasonal logic, where a range may sit entirely inside one calendar year, wrap... | ## Requirements
- Introduce a new public function `within_date_range` in the date utility module that determines whether a given date, or the current date when none is supplied, falls within a specified month-and-day range, comparing only month and day and ignoring the year.
- The function must accept the range as fou... | diff --git a/openlibrary/templates/account/books.html b/openlibrary/templates/account/books.html
index 51990c13ee8..264fa1f6dda 100644
--- a/openlibrary/templates/account/books.html
+++ b/openlibrary/templates/account/books.html
@@ -61,7 +61,9 @@
$ component_times['Yearly Goal Banner'] = time()
$ year = g... | diff --git a/openlibrary/utils/tests/test_dateutil.py b/openlibrary/utils/tests/test_dateutil.py
index c6922d1840e..a87128c3f7f 100644
--- a/openlibrary/utils/tests/test_dateutil.py
+++ b/openlibrary/utils/tests/test_dateutil.py
@@ -43,3 +43,44 @@ def test_parse_daterange():
datetime.date(2010, 2, 3),
... | ["openlibrary/utils/tests/test_dateutil.py::test_within_date_range"] | ["openlibrary/utils/tests/test_dateutil.py::test_parse_date", "openlibrary/utils/tests/test_dateutil.py::test_nextday", "openlibrary/utils/tests/test_dateutil.py::test_nextmonth", "openlibrary/utils/tests/test_dateutil.py::test_nextyear", "openlibrary/utils/tests/test_dateutil.py::test_parse_daterange"] | ghcr.io/scaleapi/swe-bench_pro-v2:instance_internetarchive__openlibrary-91efee627df01e32007abf2d6ebf73f9d9053076-vbee42ad1b72fb23c6a1c874868a720b370983ed2 | true | null | 2 | 33 | 1 | 936 | 0 | 0.95 | 1 | 0.55 | 1 | 0.266 | 82.023 | |
1,412 | swe_gym::train::334 | swe_gym | train | 334 | getmoto__moto-5255 | getmoto/moto | getmoto/moto | python | 6d68a5176bfb6efec6ba1c6b6f4db45973a35191 | Pass kwargs to create_multipart_upload
Hi 👋
We have some kwargs going into [`create_multipart_upload`](https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/s3.html#S3.Client.create_multipart_upload) (using `smart_open` [under the hood](https://github.com/ddelange/pypicloud/blob/cb97fcb6a3f31cd27... | Hi @ddelange, looks like the ACL-parameter is currently not supported, not. Will raise a PR to fix this shortly. | diff --git a/moto/s3/models.py b/moto/s3/models.py
--- a/moto/s3/models.py
+++ b/moto/s3/models.py
@@ -351,11 +351,12 @@ def is_locked(self):
class FakeMultipart(BaseModel):
- def __init__(self, key_name, metadata, storage=None, tags=None):
+ def __init__(self, key_name, metadata, storage=None, tags=None, ac... | 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
@@ -193,29 +193,48 @@ def test_multipart_upload_out_of_order():
def test_multipart_upload_with_headers():
s3 = boto3.resource("s3", region_name=DEF... | ["tests/test_s3/test_s3_multipart.py::test_multipart_upload_with_headers"] | ["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_multipart_version", "tests/test_s3/test_s3_... | null | true | 2022-06-22 22:14:44 | 2 | 20 | 1 | 988 | 0 | 0.85 | 1 | 0.55 | 1 | 0.231333 | 82.019 | |
1,413 | swe_gym::train::573 | swe_gym | train | 573 | python__mypy-11448 | python/mypy | python/mypy | python | 7a5c6f0bdbd50757ffe0a826bd758f0d44780607 | Better error messages for some `TypeVar` init cases
While working on https://github.com/python/mypy/issues/11379 I found several error message that I don't quite understand:
```python
A = TypeVar('A', covariant=False, contravariant=True)
# E: TypeVar 'covariant' may only be 'True'
B = TypeVar('B', covariant=True, con... | Btw, this message is not tested.
I think that I am going to change the logic a bit as well. Because this is valid python:
```python
>>> from typing import TypeVar
>>> A = TypeVar('A', contravariant=False)
```
No need to forbid that 👍 | diff --git a/mypy/message_registry.py b/mypy/message_registry.py
--- a/mypy/message_registry.py
+++ b/mypy/message_registry.py
@@ -152,6 +152,9 @@ def format(self, *args: object, **kwargs: object) -> "ErrorMessage":
INVALID_TYPEVAR_AS_TYPEARG: Final = 'Type variable "{}" not valid as type argument value for "{}"'
INV... | diff --git a/test-data/unit/semanal-errors.test b/test-data/unit/semanal-errors.test
--- a/test-data/unit/semanal-errors.test
+++ b/test-data/unit/semanal-errors.test
@@ -1030,11 +1030,13 @@ a = TypeVar() # E: Too few arguments for TypeVar()
b = TypeVar(x='b') # E: TypeVar() expects a string literal as first ar... | ["mypy/test/testsemanal.py::SemAnalSuite::testTypevarWithFalseVariance", "mypy/test/testsemanal.py::SemAnalErrorSuite::testInvalidTypevarValues", "mypy/test/testtransform.py::TransformSuite::testTypevarWithFalseVariance"] | ["mypy/test/testtransform.py::TransformSuite::testTypevarWithBound", "mypy/test/testsemanal.py::SemAnalSuite::testTypevarWithBound", "mypy/test/testsemanal.py::SemAnalErrorSuite::testMoreInvalidTypevarArguments"] | null | true | 2021-11-03T16:32:52Z | 2 | 37 | 3 | 629 | 0 | 0.85 | 1 | 0.55 | 1 | 0.228167 | 82.0095 | |
1,414 | swe_gym::train::339 | swe_gym | train | 339 | getmoto__moto-6107 | getmoto/moto | getmoto/moto | python | 53603b01c7b76ca166788ec6dca460614a883a96 | [S3] `x-amz-bucket-region` is missing on S3 HeadBucket
* `x-amz-bucket-region` header is missing on the response from `head_bucket`.
* This was mentioned as an issue in a downstream library as well https://github.com/localstack/localstack/issues/4205
* This is referenced in the S3 Documentation https://docs.aws.amazon.... | Thanks for raising this @ijrsvt - marking it as an enhancement to add this header. | diff --git a/moto/s3/models.py b/moto/s3/models.py
--- a/moto/s3/models.py
+++ b/moto/s3/models.py
@@ -1615,7 +1615,7 @@ def get_bucket(self, bucket_name) -> FakeBucket:
except KeyError:
raise MissingBucket(bucket=bucket_name)
- def head_bucket(self, bucket_name):
+ def head_bucket(self, b... | diff --git a/tests/test_s3/test_server.py b/tests/test_s3/test_server.py
--- a/tests/test_s3/test_server.py
+++ b/tests/test_s3/test_server.py
@@ -66,6 +66,10 @@ def test_s3_server_bucket_create(key_name):
content.should.be.a(dict)
content["Key"].should.equal(key_name)
+ res = test_client.head("http://fo... | ["tests/test_s3/test_server.py::test_s3_server_bucket_create[bar+baz]", "tests/test_s3/test_server.py::test_s3_server_bucket_create[bar_baz]", "tests/test_s3/test_server.py::test_s3_server_bucket_create[baz"] | ["tests/test_s3/test_server.py::test_s3_server_post_without_content_length", "tests/test_s3/test_server.py::test_s3_server_post_to_bucket", "tests/test_s3/test_server.py::test_s3_server_get", "tests/test_s3/test_server.py::test_s3_server_post_unicode_bucket_key", "tests/test_s3/test_server.py::test_s3_server_post_cors_... | null | true | 2023-03-22 21:09:54 | 2 | 6 | 3 | 1,249 | 0 | 0.85 | 1 | 0.55 | 1 | 0.228167 | 82.0095 | |
1,415 | swe_bench_pro::test::532 | swe_bench_pro | test | 532 | instance_protonmail__webclients-6f8916fbadf1d1f4a26640f53b5cf7f55e8bedb7 | protonmail/webclients | protonmail/webclients | javascript | 2099c5070b15ba5984cd386f63811e4321a27611 | ## Title: Folder fails to load correctly when share is locked or soft-deleted.
## Description
When attempting to load a folder in the Drive application, the system does not properly handle cases where the associated share is locked or has been soft-deleted. This can cause navigation or access issues for users who try... | ## Requirements
- `useDefaultShare` should expose a function named `isShareAvailable` that is awaitable and takes two arguments in this order: an abort signal first and a share identifier second; it should return whether the share is available.
- `isShareAvailable` should call `getShare` with the provided abort signal... | diff --git a/applications/drive/src/app/containers/FolderContainer.tsx b/applications/drive/src/app/containers/FolderContainer.tsx
index ff6b7833f6c..c431a5b285c 100644
--- a/applications/drive/src/app/containers/FolderContainer.tsx
+++ b/applications/drive/src/app/containers/FolderContainer.tsx
@@ -16,7 +16,7 @@ expor... | diff --git a/applications/drive/src/app/store/_shares/useDefaultShare.test.tsx b/applications/drive/src/app/store/_shares/useDefaultShare.test.tsx
index b54b7266d0c..31f7f20d19a 100644
--- a/applications/drive/src/app/store/_shares/useDefaultShare.test.tsx
+++ b/applications/drive/src/app/store/_shares/useDefaultShare.... | ["src/app/store/_shares/useDefaultShare.test.tsx | useDefaultShare says share is available by default", "src/app/store/_shares/useDefaultShare.test.tsx | useDefaultShare says share is not available if locked", "src/app/store/_shares/useDefaultShare.test.tsx | useDefaultShare says share is not available if soft deleted"... | ["src/app/store/_shares/useDefaultShare.test.tsx | useDefaultShare creates a volume if existing shares are locked/soft deleted", "src/app/store/_shares/useDefaultShare.test.tsx | useDefaultShare creates a volume if no shares exist", "src/app/store/_shares/useDefaultShare.test.tsx | useDefaultShare creates a volume if d... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_protonmail__webclients-6f8916fbadf1d1f4a26640f53b5cf7f55e8bedb7 | true | null | 2 | 26 | 3 | 1,046 | 0 | 0.95 | 1 | 0.55 | 1 | 0.261 | 82.008 | |
1,416 | swe_gym::train::564 | swe_gym | train | 564 | python__mypy-11292 | python/mypy | python/mypy | python | e6b91bdc5c253cefba940b0864a8257d833f0d8b | stubgen remove quotes in an argument definition that has a literal type
With the following `test.py` file:
```python
import typing
def test(x: typing.Literal['abc', 'def']) -> int:
...
```
stubgen removes the quotes around `abc` in the output `pyi` file:
```
$ stubgen test.py
Processed 1 modules
Generated out/test.... | This also happens for this code:
```python
import typing
def test(x: typing.Literal['sys']) -> int:
...
```
I'd like to give it a shot if possible
@0x000A go ahead!
This also happens for this code:
```python
import typing
def test(x: typing.Literal['sys']) -> int:
...
```
I'd like to give it a sho... | diff --git a/mypy/stubgen.py b/mypy/stubgen.py
--- a/mypy/stubgen.py
+++ b/mypy/stubgen.py
@@ -255,7 +255,7 @@ def visit_unbound_type(self, t: UnboundType) -> str:
s = t.name
self.stubgen.import_tracker.require_name(s)
if t.args:
- s += '[{}]'.format(self.list_str(t.args))
+ ... | diff --git a/test-data/unit/stubgen.test b/test-data/unit/stubgen.test
--- a/test-data/unit/stubgen.test
+++ b/test-data/unit/stubgen.test
@@ -64,6 +64,25 @@ def g(x: Foo = Foo()) -> Bar: ...
def f(x: Foo) -> Bar: ...
def g(x: Foo = ...) -> Bar: ...
+[case testPreserveFunctionAnnotationWithArgs]
+def f(x: foo['x'])... | ["mypy/test/teststubgen.py::StubgenPythonSuite::testPreserveFunctionAnnotationWithArgs"] | ["mypy/test/teststubgen.py::StubgenPythonSuite::testPreserveVarAnnotationWithoutQuotes", "mypy/test/teststubgen.py::StubgenPythonSuite::testPreserveVarAnnotation"] | null | true | 2021-10-07T23:54:24Z | 1 | 18 | 1 | 1,005 | 0 | 0.85 | 1 | 0.55 | 1 | 0.2275 | 82.0075 | |
1,417 | swe_gym::train::265 | swe_gym | train | 265 | getmoto__moto-5718 | getmoto/moto | getmoto/moto | python | 672c95384a55779799e843b5dfcf0e81c8c2da80 | DynamoDB BatchGetItem should return UnprocessedKeys when response exceeds 16MB
**What I expect to happen:**
A BatchGetItem call to a moto dynamodb instance which would return > 16 MB of data should only return a partial result, with any unprocessed keys being returned under a separate key in the response.
**What is ha... | Thanks for raising this @sirrus233 - will mark it as an enhancement to implement this validation.
If this is something you'd like to contribute yourself, PR's are always welcome! | diff --git a/moto/dynamodb/responses.py b/moto/dynamodb/responses.py
--- a/moto/dynamodb/responses.py
+++ b/moto/dynamodb/responses.py
@@ -531,6 +531,7 @@ def batch_get_item(self):
"Too many items requested for the BatchGetItem call"
)
+ result_size: int = 0
for table_nam... | diff --git a/tests/test_dynamodb/test_dynamodb.py b/tests/test_dynamodb/test_dynamodb.py
--- a/tests/test_dynamodb/test_dynamodb.py
+++ b/tests/test_dynamodb/test_dynamodb.py
@@ -2459,170 +2459,6 @@ def test_query_by_non_exists_index():
)
-@mock_dynamodb
-def test_batch_items_returns_all():
- dynamodb = _cr... | ["tests/test_dynamodb/test_dynamodb_batch_get_item.py::test_batch_items_should_return_16mb_max"] | ["tests/test_dynamodb/test_dynamodb.py::test_remove_list_index__remove_existing_nested_index", "tests/test_dynamodb/test_dynamodb.py::test_basic_projection_expressions_using_query_with_attr_expression_names", "tests/test_dynamodb/test_dynamodb.py::test_transact_write_items_put_conditional_expressions_return_values_on_c... | null | true | 2022-11-28 23:14:55 | 1 | 13 | 1 | 1,102 | 0 | 0.85 | 1 | 0.55 | 1 | 0.227 | 82.006 | |
1,418 | swe_bench_pro::test::4 | swe_bench_pro | test | 4 | instance_NodeBB__NodeBB-0c81642997ea1d827dbd02c311db9d4976112cd4-vf2cf3cbd463b7ad942381f1c6d077626485a1e9e | NodeBB/NodeBB | nodebb/nodebb | javascript | 03a98f4de484f16d038892a0a9d2317a45e79df1 | **Title: Unable to accept post in post queue when the topic get merged**
**Description:** This issue occurs because queued posts remain linked to the original topic ID even after the topic is merged. When attempting to approve these posts, the system fails to locate the associated topic, resulting in a \"topic-deleted\... | ## Requirements
- A new method `posts.updateQueuedPostsTopic(newTid, tids)` should be implemented. This method should find all queued posts whose `data.tid` matches any of the topic IDs in the `tids` array, update their `data.tid` to `newTid`, and persist the updated queued-post data.
- When a topic is merged into ano... | diff --git a/src/posts/queue.js b/src/posts/queue.js
index d523420e437b..6ed1af9c479e 100644
--- a/src/posts/queue.js
+++ b/src/posts/queue.js
@@ -48,9 +48,14 @@ module.exports = function (Posts) {
}
// Filter by tid if present
- if (isFinite(filter.tid)) {
+ if (utils.isNumber(filter.tid)) {
const tid = ... | diff --git a/test/posts.js b/test/posts.js
index fe94f3ba1225..53c4b5bfa85f 100644
--- a/test/posts.js
+++ b/test/posts.js
@@ -1147,13 +1147,31 @@ describe('Post\'s', () => {
});
});
- it('should bypass post queue if user is in exempt group', (done) => {
+ it('should bypass post queue if user is in exempt gr... | ["test/posts.js | Post's post queue should update queued post's topic if target topic is merged"] | ["test/posts.js | Post's should update category teaser properly", "test/posts.js | Post's should change owner of post and topic properly", "test/posts.js | Post's should fail to change owner if new owner does not exist", "test/posts.js | Post's should fail to change owner if user is not authorized", "test/posts.js | Po... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_NodeBB__NodeBB-0c81642997ea1d827dbd02c311db9d4976112cd4-vf2cf3cbd463b7ad942381f1c6d077626485a1e9e | true | null | 3 | 32 | 1 | 921 | 0 | 0.95 | 1 | 0.55 | 1 | 0.260167 | 82.0055 | |
1,419 | swe_gym::train::846 | swe_gym | train | 846 | iterative__dvc-1882 | iterative/dvc | iterative/dvc | python | 75b4d0e483cdb782d92717df08025eecfa352106 | Add command to present locked DVC stages
I wish that I could get a list of locked DVC stages in my DVC pipeline,
Something with a simular output as given by `grep -r 'locked: true'` *.dvc. See also https://discordapp.com/channels/485586884165107732/485596304961962003/565456202541301770
Possible DVC command could be:
*... | Working on this. Will post updates here.
Expect a PR soon
@rpip Thank you very much!
Should this also display the lock files when printing commands and output files? If that's the case, then I think `dvc pipeline show --locked` is the best approach as it works nicely with the existing options.
Alternatively, we ... | diff --git a/dvc/command/pipeline.py b/dvc/command/pipeline.py
--- a/dvc/command/pipeline.py
+++ b/dvc/command/pipeline.py
@@ -14,7 +14,7 @@
class CmdPipelineShow(CmdBase):
- def _show(self, target, commands, outs):
+ def _show(self, target, commands, outs, locked):
import networkx
from dvc... | diff --git a/tests/test_pipeline.py b/tests/test_pipeline.py
--- a/tests/test_pipeline.py
+++ b/tests/test_pipeline.py
@@ -1,3 +1,5 @@
+import logging
+
from dvc.main import main
from tests.basic_env import TestDvc
@@ -150,6 +152,19 @@ def test_non_existing(self):
ret = main(["pipeline", "show", "non-exist... | ["tests/test_pipeline.py::TestPipelineShow::test_print_locked_stages"] | ["tests/test_pipeline.py::TestPipelineShowSingle::test", "tests/test_pipeline.py::TestPipelineShowSingle::test_ascii_commands", "tests/test_pipeline.py::TestPipelineShowDeep::test_ascii_commands", "tests/test_pipeline.py::TestPipelineShowDeep::test", "tests/test_pipeline.py::TestPipelineShowDeep::test_outs", "tests/tes... | null | true | 2019-04-13T09:59:09Z | 1 | 24 | 1 | 878 | 0 | 0.85 | 1 | 0.55 | 1 | 0.226333 | 82.004 | |
1,420 | swe_bench_pro::test::55 | swe_bench_pro | test | 55 | instance_ansible__ansible-3b823d908e8a5d17674f8c26d337d3114b7493b1-v0f01c69f1e2528b935359cfe578530722bca2c59 | ansible/ansible | ansible/ansible | python | 92df66480613d0f3c1f11ab27146e3162d2a5bd5 | ## Title: “More efficient vars file reads” regression causing performance issues
## Summary
Disabling the file cache mechanism during variable file loading has introduced significant performance regressions. In setups with many vaulted variable files, the same files are repeatedly read and decrypted, which greatly in... | ## Requirements
- The function `DataLoader.load_from_file` must accept a `cache` parameter with at least the values `'none'` and `'vaulted'`.
- When called with `cache='none'`, the function must return the parsed contents of the given file and must not add any entry to the internal file cache.
- When called with `cache... | diff --git a/changelogs/fragments/81995-enable_file_cache.yml b/changelogs/fragments/81995-enable_file_cache.yml
new file mode 100644
index 00000000000000..6e631cbf3e0519
--- /dev/null
+++ b/changelogs/fragments/81995-enable_file_cache.yml
@@ -0,0 +1,2 @@
+bugfixes:
+ - Enable file cache for vaulted files during vars ... | diff --git a/test/integration/targets/rel_plugin_loading/subdir/inventory_plugins/notyaml.py b/test/integration/targets/rel_plugin_loading/subdir/inventory_plugins/notyaml.py
index 50e1e2bf6dddf9..4242e2e95f0e32 100644
--- a/test/integration/targets/rel_plugin_loading/subdir/inventory_plugins/notyaml.py
+++ b/test/inte... | ["test/units/parsing/test_dataloader.py::TestDataLoaderWithVault::test_parse_from_vault_1_1_file"] | ["test/units/parsing/test_dataloader.py::TestDataLoader::test__is_role", "test/units/parsing/test_dataloader.py::TestDataLoader::test_get_file_contents_non_existent_path", "test/units/parsing/test_dataloader.py::TestDataLoader::test_get_file_contents_none_path", "test/units/parsing/test_dataloader.py::TestDataLoader::t... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_ansible__ansible-3b823d908e8a5d17674f8c26d337d3114b7493b1-v0f01c69f1e2528b935359cfe578530722bca2c59 | true | null | 7 | 45 | 1 | 2,552 | 0 | 0.95 | 1 | 0.85 | 0.6 | 0.575333 | 82.001 | |
1,421 | swe_bench_pro::test::114 | swe_bench_pro | test | 114 | instance_ansible__ansible-ed6581e4db2f1bec5a772213c3e186081adc162d-v0f01c69f1e2528b935359cfe578530722bca2c59 | ansible/ansible | ansible/ansible | python | c819c1725de510fb41e8bdc38e68c2ac1df81ced | ## Title: Importing a collection module can stop with an error
### Description
Currently, importing a module that lives in a collection can end in a traceback instead of resolving. When the loader delegates a lookup to the finder that the import machinery provides for an ordinary directory on disk, it passes along an ... | ## Requirements
- A lookup for a name that cannot be accounted for, such as `missing`, should come back empty rather than raising, on both the current resolution route and the older fallback route.
- When no underlying finder is available for a name, both routes should come back empty without delegating any further.
... | diff --git a/lib/ansible/utils/collection_loader/_collection_finder.py b/lib/ansible/utils/collection_loader/_collection_finder.py
index 70e2d1038e1466..5f5f9476d265d7 100644
--- a/lib/ansible/utils/collection_loader/_collection_finder.py
+++ b/lib/ansible/utils/collection_loader/_collection_finder.py
@@ -43,6 +43,13 @... | diff --git a/test/units/utils/collection_loader/test_collection_loader.py b/test/units/utils/collection_loader/test_collection_loader.py
index 425f770c7726bb..1aa8eccf7fea27 100644
--- a/test/units/utils/collection_loader/test_collection_loader.py
+++ b/test/units/utils/collection_loader/test_collection_loader.py
@@ -9... | ["test/units/utils/collection_loader/test_collection_loader.py::test_find_module_py3"] | ["test/units/utils/collection_loader/test_collection_loader.py::test_finder_setup", "test/units/utils/collection_loader/test_collection_loader.py::test_finder_not_interested", "test/units/utils/collection_loader/test_collection_loader.py::test_finder_ns", "test/units/utils/collection_loader/test_collection_loader.py::t... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_ansible__ansible-ed6581e4db2f1bec5a772213c3e186081adc162d-v0f01c69f1e2528b935359cfe578530722bca2c59 | true | null | 1 | 44 | 1 | 669 | 0 | 0.95 | 1 | 0.55 | 1 | 0.258167 | 81.9995 | |
1,422 | swe_gym::train::873 | swe_gym | train | 873 | iterative__dvc-2130 | iterative/dvc | iterative/dvc | python | f36162d6133974e11d2dffbff29211a39c140a67 | dvc: move updater out of repo
It looks like this now:
```python
ipdb> repo = Repo()
+-------------------------------------------+
| |
| Update available 0.40.2 -> 0.40.7 |
| Run pip install dvc --upgrade |
| |
+-----... | As a workaround, you could silence logger for `dvc`. | diff --git a/dvc/command/base.py b/dvc/command/base.py
--- a/dvc/command/base.py
+++ b/dvc/command/base.py
@@ -38,10 +38,13 @@ def append_doc_link(help_message, path):
class CmdBase(object):
def __init__(self, args):
from dvc.repo import Repo
+ from dvc.updater import Updater
self.repo ... | diff --git a/tests/func/test_diff.py b/tests/func/test_diff.py
--- a/tests/func/test_diff.py
+++ b/tests/func/test_diff.py
@@ -1,7 +1,6 @@
from __future__ import unicode_literals
import os
-from mock import patch, Mock
from dvc.main import main
@@ -65,34 +64,28 @@ def test(self):
class TestDiffCmdLine(TestD... | ["tests/func/test_diff.py::TestDiffCmdMessage::test"] | ["tests/unit/test_updater.py::test_fetch", "tests/func/test_diff.py::TestDiffDirRepoDeletedFile::test", "tests/func/test_updater.py::test_check_version_equal", "tests/func/test_diff.py::TestDiffDir::test", "tests/func/test_diff.py::TestDiffRepo::test", "tests/func/test_updater.py::test_check_version_outdated", "tests/f... | null | true | 2019-06-13T20:59:06Z | 3 | 47 | 1 | 408 | 0 | 0.85 | 1 | 0.55 | 1 | 0.224667 | 81.999 | |
1,423 | swe_gym::train::856 | swe_gym | train | 856 | iterative__dvc-3794 | iterative/dvc | iterative/dvc | python | d81b56978fd2206c6e7e7056ac18ab350cb9a6c8 | remote modify: add `name` param?
So you can change the name of a remote e.g.
```console
$ dvc remote add myremote some/path
$ dvc remote list
myremote some/path
$ dvc remote modify myremote name supercoolremote
$ dvc remote list
supercoolremote some/path
```
The workaround rn is to just add the remote again and remov... | BTW if you actually run my example command to modify the inexistent `name` param, it gets written to .dvc/config, which causes an error output whenever you try to change the config later:
```
ERROR: configuration error - config file error:
extra keys not allowed @ data['remote']['myremote']['name']
```
You hav... | diff --git a/dvc/command/remote.py b/dvc/command/remote.py
--- a/dvc/command/remote.py
+++ b/dvc/command/remote.py
@@ -108,6 +108,35 @@ def run(self):
return 0
+class CmdRemoteRename(CmdRemote):
+ def _rename_default(self, conf):
+ if conf["core"].get("remote") == self.args.name:
+ con... | diff --git a/tests/func/test_remote.py b/tests/func/test_remote.py
--- a/tests/func/test_remote.py
+++ b/tests/func/test_remote.py
@@ -285,3 +285,74 @@ def test_remote_modify_default(dvc):
assert repo_config["core"]["remote"] == remote_repo
assert local_config["core"]["remote"] == remote_local
+
+
+def test... | ["tests/func/test_remote.py::test_remote_default", "tests/func/test_remote.py::test_remote_rename", "tests/func/test_remote.py::test_remote_duplicated"] | ["tests/func/test_remote.py::test_dir_checksum_should_be_key_order_agnostic", "tests/func/test_remote.py::TestRemote::test_relative_path", "tests/func/test_remote.py::TestRemoteDefault::test", "tests/func/test_remote.py::test_remote_modify_validation", "tests/func/test_remote.py::TestRemote::test_referencing_other_remo... | null | true | 2020-05-13T14:06:51Z | 1 | 40 | 3 | 531 | 0 | 0.85 | 1 | 0.55 | 1 | 0.221833 | 81.9905 | |
1,424 | swe_bench_verified::test::112 | swe_bench_verified | test | 112 | django__django-13406 | django/django | django/django | python | 84609b3205905097d7d3038d32e6101f012c0619 | Queryset with values()/values_list() crashes when recreated from a pickled query.
Description
I am pickling query objects (queryset.query) for later re-evaluation as per https://docs.djangoproject.com/en/2.2/ref/models/querysets/#pickling-querysets. However, when I tried to rerun a query that combines values and anno... | It seems that I have found the culprit. The queryset has an attribute _iterable_class, which in case of a .objects.all() type of query is ModelIterable, but when .values() is used, it should be ValuesIterable. Unfortunately, this is an attribute of the queryset, not of the query and thus it does not get pickled and unp... | diff --git a/django/db/models/query.py b/django/db/models/query.py
--- a/django/db/models/query.py
+++ b/django/db/models/query.py
@@ -210,6 +210,8 @@ def query(self):
@query.setter
def query(self, value):
+ if value.values_select:
+ self._iterable_class = ValuesIterable
self._que... | diff --git a/tests/queryset_pickle/tests.py b/tests/queryset_pickle/tests.py
--- a/tests/queryset_pickle/tests.py
+++ b/tests/queryset_pickle/tests.py
@@ -11,7 +11,7 @@
class PickleabilityTestCase(TestCase):
@classmethod
def setUpTestData(cls):
- Happening.objects.create() # make sure the defaults ar... | ["test_annotation_values (queryset_pickle.tests.PickleabilityTestCase)", "test_annotation_values_list (queryset_pickle.tests.PickleabilityTestCase)", "test_annotation_with_callable_default (queryset_pickle.tests.PickleabilityTestCase)"] | ["test_in_lookup_query_evaluation (queryset_pickle.tests.InLookupTests)", "test_in_lookup_queryset_evaluation (queryset_pickle.tests.InLookupTests)", "test_datetime_callable_default_all (queryset_pickle.tests.PickleabilityTestCase)", "test_datetime_callable_default_filter (queryset_pickle.tests.PickleabilityTestCase)",... | null | true | 2020-09-10T12:38:11Z | 1 | 2 | 3 | 3,082 | 0 | 1 | 1 | 0.92 | 0.4 | 0.506667 | 81.99 | |
1,425 | swe_gym::train::16 | swe_gym | train | 16 | getmoto__moto-5154 | getmoto/moto | getmoto/moto | python | 12843c4eaedcfc524538eb43483fbb011bf05c85 | Add support for EC2 state 'OutOfService' in moto ELB 'describe_instance_health'
Add support for instance state 'OutOfService' in moto ELB 'describe_instance_health'
https://github.com/spulec/moto/blob/master/moto/elb/responses.py#L260
mocking doesn't have support for 'OutOfService', once an instance is registered to a... | Thanks for opening. I am tagging this as a feature request. | diff --git a/moto/ec2/models/instances.py b/moto/ec2/models/instances.py
--- a/moto/ec2/models/instances.py
+++ b/moto/ec2/models/instances.py
@@ -353,6 +353,9 @@ def stop(self):
"Client.UserInitiatedShutdown",
)
+ def is_running(self):
+ return self._state.name == "running"
+
def... | diff --git a/tests/test_elb/test_elb.py b/tests/test_elb/test_elb.py
--- a/tests/test_elb/test_elb.py
+++ b/tests/test_elb/test_elb.py
@@ -868,30 +868,69 @@ def test_connection_settings_attribute():
def test_describe_instance_health():
elb = boto3.client("elb", region_name="us-east-1")
ec2 = boto3.client("ec... | ["tests/test_elb/test_elb.py::test_describe_instance_health__with_instance_ids"] | ["tests/test_elb/test_elb.py::test_create_duplicate_listener_different_protocols[http-TCP]", "tests/test_elb/test_elb.py::test_connection_draining_attribute", "tests/test_elb/test_elb.py::test_create_elb_in_multiple_region", "tests/test_elb/test_elb.py::test_create_load_balancer_with_no_listeners_defined", "tests/test_... | null | true | 2022-05-21 22:15:00 | 3 | 41 | 1 | 507 | 0 | 0.85 | 1 | 0.55 | 1 | 0.221167 | 81.9885 | |
1,426 | swe_bench_pro::test::354 | swe_bench_pro | test | 354 | instance_gravitational__teleport-b1bcd8b90c474a35bb11cc3ef4cc8941e1f8eab2-vee9b09fb20c43af7e520f57e9239bbcf46b7113d | gravitational/teleport | gravitational/teleport | go | b054261bc1cce536d307cbdad358f7c6c941b851 | # Title: Incorrect counting of authenticated HTTP connections in ingress reporter metrics
### Description
The ingress reporter counts every HTTP connection as authenticated regardless of whether it presents a TLS client certificate, so connections without a client certificate are wrongly reported with an authenticated... | ## Requirements
- The connection state reporter `HTTPConnStateReporter` should start accounting for a connection once it reaches its active state, counting it as one accepted connection and one active connection so both reflect the live connection.
- A connection should be considered authenticated only when it present... | diff --git a/lib/srv/ingress/reporter.go b/lib/srv/ingress/reporter.go
index cbf552d1628d5..df4b216e465c5 100644
--- a/lib/srv/ingress/reporter.go
+++ b/lib/srv/ingress/reporter.go
@@ -17,8 +17,10 @@ limitations under the License.
package ingress
import (
+ "crypto/tls"
"net"
"net/http"
+ "sync"
"github.com... | diff --git a/lib/srv/ingress/reporter_test.go b/lib/srv/ingress/reporter_test.go
index fd03728f2c341..cfdb02150be57 100644
--- a/lib/srv/ingress/reporter_test.go
+++ b/lib/srv/ingress/reporter_test.go
@@ -17,6 +17,7 @@ limitations under the License.
package ingress
import (
+ "crypto/tls"
"net"
"net/http"
"te... | ["TestHTTPConnStateReporter/without_client_certs", "TestHTTPConnStateReporter"] | ["TestHTTPConnStateReporter/with_client_certs"] | ghcr.io/scaleapi/swe-bench_pro-v2:instance_gravitational__teleport-b1bcd8b90c474a35bb11cc3ef4cc8941e1f8eab2-vee9b09fb20c43af7e520f57e9239bbcf46b7113d | true | null | 1 | 56 | 2 | 394 | 0 | 0.95 | 1 | 0.55 | 1 | 0.252333 | 81.982 | |
1,427 | swe_bench_pro::test::130 | swe_bench_pro | test | 130 | instance_element-hq__element-web-494d9de6f0a94ffb491e74744d2735bce02dc0ab-vnan | element-hq/element-web | element-hq/element-web | javascript | 28f7aac9a5970d27ff3757875b464a5a58a1eb1a | **Title: Widget Room Buttons Do Not Display or Update Correctly **
**Steps to reproduce**
1. Start in a room that has custom widgets with associated buttons (e.g., rooms where integrations or apps expose buttons).
2. Navigate away from the room and then return to it. Alternatively, open Element Web and switch direct... | ## Requirements
- The public `Action` enum must include a new member `RoomLoaded` with the exact value `""room_loaded""`.
- After a room finishes its initial load, `RoomView` must dispatch exactly the payload `{ action: Action.RoomLoaded }` via the global dispatcher.
- The private method `setViewRoomOpts()` on `RoomV... | diff --git a/src/components/structures/RoomView.tsx b/src/components/structures/RoomView.tsx
index ff1d61a259d..db4a5e752fc 100644
--- a/src/components/structures/RoomView.tsx
+++ b/src/components/structures/RoomView.tsx
@@ -687,7 +687,7 @@ export class RoomView extends React.Component<IRoomProps, IRoomState> {
... | diff --git a/test/components/structures/RoomView-test.tsx b/test/components/structures/RoomView-test.tsx
index 066f8b38a2..916e8a8225 100644
--- a/test/components/structures/RoomView-test.tsx
+++ b/test/components/structures/RoomView-test.tsx
@@ -711,4 +711,10 @@ describe("RoomView", () => {
await expect(pro... | ["test/stores/RoomViewStore-test.ts | Action.RoomLoaded | updates viewRoomOpts", "test/stores/RoomViewStore-test.ts | Action.RoomLoaded | does not update viewRoomOpts on Action.ViewRoom", "test/components/structures/RoomView-test.tsx | RoomView | fires Action.RoomLoaded"] | ["test/settings/handlers/RoomDeviceSettingsHandler-test.ts | RoomDeviceSettingsHandler | should write/read/clear the value for \u00bbRightPanel.phases\u00ab", "test/settings/handlers/RoomDeviceSettingsHandler-test.ts | RoomDeviceSettingsHandler | should write/read/clear the value for \u00bbblacklistUnverifiedDevices\u0... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_element-hq__element-web-494d9de6f0a94ffb491e74744d2735bce02dc0ab-vnan | true | null | 3 | 29 | 3 | 931 | 0 | 0.95 | 1 | 0.55 | 1 | 0.251833 | 81.9805 | |
1,428 | swe_gym::train::150 | swe_gym | train | 150 | getmoto__moto-5885 | getmoto/moto | getmoto/moto | python | 67197cb8a566ee5d598905f836c90de8ee9399e1 | EKS DescribeNodegroup not returning id or name launch template attribute in response
The boto3 EKS DescribeNodegroup response returns the following for LaunchTemplate:
`'launchTemplate': {
'name': 'string',
'version': 'string',
'id': 'string'
},`
However, the moto response f... | Thanks for raising this @andypaterson40 - looks like we're not doing anything with the `launchTemplate` at the moment, we just store it as is. Will mark it as an enhancement to actually verify it exists and retrieve the corresponding name/id. | diff --git a/moto/eks/models.py b/moto/eks/models.py
--- a/moto/eks/models.py
+++ b/moto/eks/models.py
@@ -284,6 +284,25 @@ def __init__(
self.tags = tags
self.taints = taints
+ # Determine LaunchTemplateId from Name (and vice versa)
+ try:
+ from moto.ec2.models import ec2_... | diff --git a/tests/test_eks/test_eks_ec2.py b/tests/test_eks/test_eks_ec2.py
new file mode 100644
--- /dev/null
+++ b/tests/test_eks/test_eks_ec2.py
@@ -0,0 +1,73 @@
+import boto3
+
+from moto import mock_ec2, mock_eks
+from .test_eks_constants import NODEROLE_ARN_VALUE, SUBNET_IDS
+
+
+@mock_eks
+def test_passing_an_u... | ["tests/test_eks/test_eks_ec2.py::test_passing_a_known_launchtemplate_by_name", "tests/test_eks/test_eks_ec2.py::test_passing_a_known_launchtemplate_by_id"] | ["tests/test_eks/test_eks_ec2.py::test_passing_an_unknown_launchtemplate_is_supported"] | null | true | 2023-01-30 23:06:51 | 1 | 19 | 2 | 922 | 0 | 0.85 | 1 | 0.55 | 1 | 0.217 | 81.976 | |
1,429 | swe_bench_pro::test::451 | swe_bench_pro | test | 451 | instance_internetarchive__openlibrary-e8084193a895d8ee81200f49093389a3887479ce-ve8c8d62a2b60610a3c4631f5f23ed866bada9818 | internetarchive/openlibrary | internetarchive/openlibrary | python | 8d41b319745228044947e039f629c44a5da08a09 | # Title: Retain Common Publisher Abbreviation [s.n.] in MARC Records
## Description
When parsing MARC publication data, the output for the unknown publisher abbreviation is not following the standard presentation. For “sine nomine” (unknown publisher), our records should show the value inside square brackets to indica... | ## Requirements
- When the MARC record’s publisher is \"s.n.\", the output must include exactly \"[s.n.]\" inside the \"publishers\" list.
## Interface
No new interfaces are introduced.
| diff --git a/openlibrary/catalog/marc/parse.py b/openlibrary/catalog/marc/parse.py
index 0dcd0a02f82..3248cc28891 100644
--- a/openlibrary/catalog/marc/parse.py
+++ b/openlibrary/catalog/marc/parse.py
@@ -322,14 +322,29 @@ def read_languages(rec: MarcBase, lang_008: Optional[str] = None) -> list[str]:
def read_pub... | diff --git a/openlibrary/catalog/marc/tests/test_parse.py b/openlibrary/catalog/marc/tests/test_parse.py
index bd8e3a3fa..986c31b3c 100644
--- a/openlibrary/catalog/marc/tests/test_parse.py
+++ b/openlibrary/catalog/marc/tests/test_parse.py
@@ -3,6 +3,7 @@ import pytest
from openlibrary.catalog.marc.parse import (
... | ["openlibrary/catalog/marc/tests/test_parse.py::TestParseMARCBinary::test_read_publisher_sine_nomine_brackets"] | ["openlibrary/catalog/marc/tests/test_parse.py::TestParseMARCXML::test_xml[39002054008678.yale.edu]", "openlibrary/catalog/marc/tests/test_parse.py::TestParseMARCXML::test_xml[flatlandromanceo00abbouoft]", "openlibrary/catalog/marc/tests/test_parse.py::TestParseMARCXML::test_xml[nybc200247]", "openlibrary/catalog/marc/... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_internetarchive__openlibrary-e8084193a895d8ee81200f49093389a3887479ce-ve8c8d62a2b60610a3c4631f5f23ed866bada9818 | true | null | 1 | 29 | 1 | 903 | 0 | 0.95 | 1 | 0.55 | 1 | 0.247167 | 81.9665 | |
1,430 | swe_bench_pro::test::521 | swe_bench_pro | test | 521 | instance_protonmail__webclients-2f66db85455f4b22a47ffd853738f679b439593c | protonmail/webclients | protonmail/webclients | javascript | 85560278585cd2d6f6f022112c912d03a79b2da7 | ## Title: Content that follows a blockquote is treated as part of the quoted section
### Description
When a message body is split into the part the sender wrote and the quoted section beneath it, content that appears after a blockquote is misclassified. Text or an image that follows a quote is absorbed into the quote... | ## Requirements
- When any non-empty text follows a blockquote in the remaining message content, `locateBlockquote` must not select that blockquote as the quoted section.
- When an element matching `.proton-image-anchor` follows a blockquote in the remaining message content, `locateBlockquote` must not select that bloc... | diff --git a/applications/mail/src/app/helpers/message/messageBlockquote.ts b/applications/mail/src/app/helpers/message/messageBlockquote.ts
index e7f634af635..0c5670001f3 100644
--- a/applications/mail/src/app/helpers/message/messageBlockquote.ts
+++ b/applications/mail/src/app/helpers/message/messageBlockquote.ts
@@ ... | diff --git a/applications/mail/src/app/helpers/message/messageBlockquote.test.ts b/applications/mail/src/app/helpers/message/messageBlockquote.test.ts
index 79fb19c01cd..74993c4f508 100644
--- a/applications/mail/src/app/helpers/message/messageBlockquote.test.ts
+++ b/applications/mail/src/app/helpers/message/messageBl... | ["src/app/helpers/message/messageBlockquote.test.ts | messageBlockquote should take the last element containing an image in case of siblings blockquotes", "src/app/helpers/message/messageBlockquote.test.ts | messageBlockquote should display nothing in blockquote when there is text after blockquotes", "src/app/helpers/m... | ["src/app/helpers/message/messageBlockquote.test.ts | messageBlockquote should find the blockquote in the mail proton1", "src/app/helpers/message/messageBlockquote.test.ts | messageBlockquote should find the blockquote in the mail proton2", "src/app/helpers/message/messageBlockquote.test.ts | messageBlockquote should f... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_protonmail__webclients-2f66db85455f4b22a47ffd853738f679b439593c | true | null | 1 | 33 | 3 | 818 | 0 | 0.95 | 1 | 0.55 | 1 | 0.246333 | 81.964 | |
1,431 | swe_gym::train::237 | swe_gym | train | 237 | getmoto__moto-5189 | getmoto/moto | getmoto/moto | python | b96eafb3c3e4c2e40c4ca62a3b555a51296cc6e3 | Moto allows syntactically invalid update expressions for DynamoDB
When using the DynamoDB `UpdateItem` API, it is necessary to provide an `UpdateExpression` describing which attributes to update, and the new values. Multiple updates in the same expression are separated by commas. The real DynamoDB does not allow this e... | Thanks for raising this and providing the test case, @sirrus233! | diff --git a/moto/dynamodb/parsing/expressions.py b/moto/dynamodb/parsing/expressions.py
--- a/moto/dynamodb/parsing/expressions.py
+++ b/moto/dynamodb/parsing/expressions.py
@@ -555,6 +555,9 @@ def _parse(self):
self.skip_white_space()
if self.get_next_token_type() == Token.COMMA:
... | 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
@@ -599,3 +599,29 @@ def test_put_item_empty_set():
... | ["tests/test_dynamodb/exceptions/test_dynamodb_exceptions.py::test_update_expression_with_trailing_comma"] | ["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_hash_key_can_only_use_equals_operations[<]", "tests/test_dynamodb/exceptions/test_dynamodb_exceptions.py::test_creating_table_w... | null | true | 2022-06-02 21:09:35 | 1 | 3 | 1 | 2,166 | 0 | 0.85 | 1 | 0.7 | 0.8 | 0.371 | 81.963 | |
1,432 | swe_gym::train::415 | swe_gym | train | 415 | python__mypy-15876 | python/mypy | python/mypy | python | b49be105d2940e3a0607f5ec76f519931b0d0a08 | Docs: confirm that use of None-typed function return value is disallowed
Regarding an example provided by @jdban:
```
from typing import List
def get_first_elem(the_list): # type:(List[int]) -> int
return the_list[0]
myList = [1, 2, 3] # type: List[int]
print get_first_elem(myList.append(0) or myList) # mypy... | The example is a horrible hack and I'm glad mypy rejects it. Agreed that (2) and (3) are worth fixing.
I think this behavior is incorrect, regardless of how one feels about the hackiness of the example. Consider (apologies for the length of the code below, but I wanted to work up to a relatively sane example that mypy ... | diff --git a/mypy/messages.py b/mypy/messages.py
--- a/mypy/messages.py
+++ b/mypy/messages.py
@@ -1021,18 +1021,11 @@ def duplicate_argument_value(self, callee: CallableType, index: int, context: Co
def does_not_return_value(self, callee_type: Type | None, context: Context) -> None:
"""Report an error ... | diff --git a/test-data/unit/check-errorcodes.test b/test-data/unit/check-errorcodes.test
--- a/test-data/unit/check-errorcodes.test
+++ b/test-data/unit/check-errorcodes.test
@@ -553,15 +553,15 @@ from typing import Callable
def f() -> None: pass
-x = f() # E: "f" does not return a value [func-returns-value]
+x ... | ["mypy/test/testcheck.py::TypeCheckSuite::check-inference.test::testForStatementInferenceWithVoid", "mypy/test/testcheck.py::TypeCheckSuite::check-expressions.test::testConditionalExpressionWithEmptyCondition", "mypy/test/testcheck.py::TypeCheckSuite::check-expressions.test::testNoneReturnTypeWithExpressions", "mypy/te... | ["mypy/test/testcheck.py::TypeCheckSuite::check-statements.test::testEmptyReturnInNoneTypedGenerator", "mypy/test/testcheck.py::TypeCheckSuite::check-errorcodes.test::testErrorCodeInstantiateAbstract", "mypy/test/testcheck.py::TypeCheckSuite::check-expressions.test::testYieldExpressionWithNone", "mypy/test/testcheck.py... | null | true | 2023-08-15T11:18:33Z | 1 | 15 | 6 | 974 | 0 | 0.85 | 1 | 0.55 | 1 | 0.212333 | 81.962 | |
1,433 | swe_bench_pro::test::443 | swe_bench_pro | test | 443 | instance_internetarchive__openlibrary-c8996ecc40803b9155935fd7ff3b8e7be6c1437c-ve8fc82d8aae8463b752a211156c5b7b59f349237 | internetarchive/openlibrary | internetarchive/openlibrary | python | f0341c0ba81c790241b782f5103ce5c9a6edf8e3 | **Title:** Only apply “too-old” publication-year limits to Amazon/BWB sources
**Problem**
A global “too old” check was rejecting records before a hard cutoff, even for trusted archival sources (e.g., Internet Archive). This over-blocked valid historical works.
**Expected behavior**
Source-aware validation should ap... | ## Requirements
- Publication-year enforcement should key off `source_records` prefixes; a record is subject to the stricter year check only when at least one of its `source_records` entries has a colon-delimited prefix identifying a bookseller source that requires additional validation, such as `amazon`.
- A seller-s... | diff --git a/openlibrary/catalog/add_book/__init__.py b/openlibrary/catalog/add_book/__init__.py
index dd493d9ce6d..c2e1ce6a27f 100644
--- a/openlibrary/catalog/add_book/__init__.py
+++ b/openlibrary/catalog/add_book/__init__.py
@@ -45,7 +45,7 @@
needs_isbn_and_lacks_one,
publication_year_too_old,
publis... | diff --git a/openlibrary/catalog/add_book/tests/test_add_book.py b/openlibrary/catalog/add_book/tests/test_add_book.py
index e4454050362..9798849dbe9 100644
--- a/openlibrary/catalog/add_book/tests/test_add_book.py
+++ b/openlibrary/catalog/add_book/tests/test_add_book.py
@@ -1196,14 +1196,24 @@ def test_add_identifier... | ["openlibrary/catalog/add_book/tests/test_add_book.py::test_validate_record[But 1400 CE+ can be imported-rec1-None-None]", "openlibrary/tests/catalog/test_utils.py::test_publication_year_too_old[1399 is acceptable for an IA source-rec3-False]", "openlibrary/tests/catalog/test_utils.py::test_publication_year_too_old[139... | ["openlibrary/catalog/add_book/tests/test_add_book.py::Test_From_MARC::test_author_from_700", "openlibrary/catalog/add_book/tests/test_add_book.py::Test_From_MARC::test_from_marc[coursepuremath00hardrich]", "openlibrary/catalog/add_book/tests/test_add_book.py::Test_From_MARC::test_from_marc[roadstogreatness00gall]", "o... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_internetarchive__openlibrary-c8996ecc40803b9155935fd7ff3b8e7be6c1437c-ve8fc82d8aae8463b752a211156c5b7b59f349237 | true | null | 2 | 35 | 7 | 769 | 0 | 0.95 | 1 | 0.55 | 1 | 0.244833 | 81.9595 | |
1,434 | swe_gym::train::769 | swe_gym | train | 769 | iterative__dvc-4566 | iterative/dvc | iterative/dvc | python | 36935bdce28d8e7708e25aff217f7a95da46cc4d | Use a DVC command, but without having to change directories (like git -C <dir>)
Similar to: [ Starting git 1.8.5 (Q4 2013)](https://github.com/git/git/blob/5fd09df3937f54c5cfda4f1087f5d99433cce527/Documentation/RelNotes/1.8.5.txt#L115-L116), you will be able to "use a Git command, but without having to change director... | Hi @dchichkov !
Great request! We actually have one `-C` in `dvc repro`. It has been there for a long time, but we haven't heard any requests about other commands (nor about that one, really) ever, so it is interesting to get this feature request :slightly_smiling_face: The implementation should be pretty simple: we... | diff --git a/dvc/cli.py b/dvc/cli.py
--- a/dvc/cli.py
+++ b/dvc/cli.py
@@ -1,6 +1,7 @@
"""DVC command line interface"""
import argparse
import logging
+import os
import sys
from .command import (
@@ -191,6 +192,14 @@ def get_main_parser():
help="Show program's version.",
)
+ parser.add_argumen... | diff --git a/tests/func/test_cli.py b/tests/func/test_cli.py
--- a/tests/func/test_cli.py
+++ b/tests/func/test_cli.py
@@ -160,8 +160,22 @@ def test(self):
class TestFindRoot(TestDvc):
def test(self):
- os.chdir("..")
+ class Cmd(CmdBase):
+ def run(self):
+ pass
+
+ ... | ["tests/func/test_cli.py::TestFindRoot::test", "tests/func/test_cli.py::TestCd::test"] | ["tests/func/test_cli.py::TestStatus::test", "tests/func/test_cli.py::TestAdd::test", "tests/func/test_cli.py::test_unknown_command_help", "tests/func/test_cli.py::TestGCMultipleDvcRepos::test", "tests/func/test_cli.py::TestCheckout::test", "tests/func/test_cli.py::TestRun::test", "tests/func/test_cli.py::TestArgParse:... | null | true | 2020-09-13T02:34:05Z | 3 | 20 | 2 | 864 | 0 | 0.85 | 1 | 0.55 | 1 | 0.210667 | 81.957 | |
1,435 | swe_gym::train::1996 | swe_gym | train | 1,996 | Project-MONAI__MONAI-4638 | Project-MONAI/MONAI | project-monai/monai | python | 4ddd2bc3870a86fb0a300c20e680de48886bbfc1 | convert_to_numpy issue
**Describe the bug**
```py
>>> from monai.utils import convert_to_numpy
>>> import torch
>>> import numpy as np
>>> convert_to_numpy(data=torch.zeros((2,2),dtype=torch.long), dtype=np.uint16)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "monai/utils/type_convers... | diff --git a/monai/data/meta_tensor.py b/monai/data/meta_tensor.py
--- a/monai/data/meta_tensor.py
+++ b/monai/data/meta_tensor.py
@@ -15,13 +15,15 @@
from copy import deepcopy
from typing import Any, Sequence
+import numpy as np
import torch
from monai.config.type_definitions import NdarrayTensor
from monai.d... | diff --git a/tests/test_arraydataset.py b/tests/test_arraydataset.py
--- a/tests/test_arraydataset.py
+++ b/tests/test_arraydataset.py
@@ -23,15 +23,15 @@
from monai.transforms import AddChannel, Compose, LoadImage, RandAdjustContrast, RandGaussianNoise, Spacing
TEST_CASE_1 = [
- Compose([LoadImage(), AddChannel... | ["tests/test_meta_affine.py::TestAffineConsistencyITK::test_linear_consistent_dict_02_CropForegroundd", "tests/test_meta_affine.py::TestAffineConsistencyITK::test_linear_consistent_dict_21_RandZoomd", "tests/test_meta_affine.py::TestAffineConsistencyITK::test_linear_consistent_07_RandScaleCrop", "tests/test_meta_affine... | ["tests/test_meta_tensor.py::TestMetaTensor::test_construct_with_pre_applied_transforms", "tests/test_image_rw.py::TestLoadSaveNifti::test_2d_2", "tests/test_nifti_saver.py::TestNiftiSaver::test_saved_3d_no_resize_content", "tests/test_image_rw.py::TestLoadSavePNG::test_2d_1", "tests/test_meta_tensor.py::TestMetaTensor... | null | true | 2022-07-06T07:59:37Z | 6 | 102 | 51 | 1,793 | 0 | 0.85 | 1 | 0.7 | 0.85 | 0.638833 | 81.954 | ||
1,436 | swe_bench_pro::test::245 | swe_bench_pro | test | 245 | instance_flipt-io__flipt-ee02b164f6728d3227c42671028c67a4afd36918 | flipt-io/flipt | flipt-io/flipt | go | e38e41543f08b762904ed8a08969d0b6aba67166 | # Release/update checking is not reusable, and '-rc' builds are misclassified as proper releases
# Description
Version logic for release detection and update availability is implemented inline rather than as a reusable, independently testable unit. This coupling reduces testability and reuse. In addition, builds whos... | ## Requirements
- Add a `release` package whose exported `Is` function accepts a version `string` and returns a `bool` indicating whether the version represents a proper release. Versions whose string ends with a 'dev', 'snapshot', or 'rc' identifier (including forms such as 'rc1' and 'rc.1') must return `false`; any o... | diff --git a/cmd/flipt/main.go b/cmd/flipt/main.go
index b36de540f0..2c8b2f0f5a 100644
--- a/cmd/flipt/main.go
+++ b/cmd/flipt/main.go
@@ -10,19 +10,17 @@ import (
"os/signal"
"path/filepath"
"runtime"
- "strings"
"sync"
"syscall"
"text/template"
"time"
- "github.com/blang/semver/v4"
"github.com/fatih... | diff --git a/internal/release/check_test.go b/internal/release/check_test.go
new file mode 100644
index 0000000000..60b8b3aa9f
--- /dev/null
+++ b/internal/release/check_test.go
@@ -0,0 +1,115 @@
+package release
+
+import (
+ "context"
+ "testing"
+
+ "github.com/google/go-github/v32/github"
+ "github.com/stretchr/tes... | ["TestCheck", "TestIs"] | [] | ghcr.io/scaleapi/swe-bench_pro-v2:instance_flipt-io__flipt-ee02b164f6728d3227c42671028c67a4afd36918 | true | null | 3 | 205 | 2 | 1,779 | 0 | 0.95 | 1 | 0.7 | 0.75 | 0.7965 | 81.952 | |
1,437 | swe_bench_pro::test::252 | swe_bench_pro | test | 252 | instance_future-architect__vuls-0ec945d0510cdebf92cdd8999f94610772689f14 | future-architect/vuls | future-architect/vuls | go | d3bf2a6f26e8e549c0732c26fdcc82725d3c6633 | # Title: Incorrect parsing of `rpm -qa` output when release is empty and source RPM filenames use non-standard patterns
## Description
When Vuls parses `rpm -qa` output, some packages have an empty release field. The line can contain two spaces in a row between version and architecture. The parser does not preserve th... | ## Requirements
- `parseInstalledPackagesLine` must split each `rpm -qa` line on single spaces without collapsing consecutive spaces, so an empty release field stays as an empty token and later fields (architecture, source RPM filename) keep the correct position.
- When the release token is empty, `parseInstalledPacka... | diff --git a/scanner/redhatbase.go b/scanner/redhatbase.go
index 1b749f37fe..e4148be7d9 100644
--- a/scanner/redhatbase.go
+++ b/scanner/redhatbase.go
@@ -523,7 +523,7 @@ func (o *redhatBase) parseInstalledPackages(stdout string) (models.Packages, mod
case constant.Amazon:
switch strings.Fields(o.getDistro().Rel... | diff --git a/scanner/redhatbase_test.go b/scanner/redhatbase_test.go
index 19e6d5cf5f..85c19b985b 100644
--- a/scanner/redhatbase_test.go
+++ b/scanner/redhatbase_test.go
@@ -419,7 +419,7 @@ func Test_redhatBase_parseInstalledPackagesLine(t *testing.T) {
},
},
{
- name: "invalid source package",
+ name: "... | ["Test_redhatBase_parseInstalledPackagesLine", "Test_redhatBase_parseInstalledPackagesLine/not_standard_rpm_style_source_package", "Test_redhatBase_parseInstalledPackagesLine/not_standard_rpm_style_source_package_2", "Test_redhatBase_parseInstalledPackagesLine/not_standard_rpm_style_source_package_3", "Test_redhatBase_... | ["Test_redhatBase_parseInstalledPackagesLine/old:_package_1", "Test_redhatBase_parseInstalledPackagesLine/epoch_in_source_package", "Test_redhatBase_parseInstalledPackagesLine/new:_package_1", "Test_redhatBase_parseInstalledPackagesLine/new:_package_2", "Test_redhatBase_parseInstalledPackagesLine/modularity:_package_1"... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_future-architect__vuls-0ec945d0510cdebf92cdd8999f94610772689f14 | true | null | 1 | 33 | 6 | 777 | 0 | 0.95 | 1 | 0.55 | 1 | 0.2395 | 81.9435 | |
1,438 | swe_bench_pro::test::412 | swe_bench_pro | test | 412 | instance_internetarchive__openlibrary-6afdb09df692223c3a31df65cfa92f15e5614c01-v08d8e8889ec945ab821fb156c04c7d2e2810debb | internetarchive/openlibrary | internetarchive/openlibrary | python | 1a3fab3f0b319e0df49dd742ce2ffa0d747d1b44 | ## Title: Add support for `Path` and typed lists in `FnToCLI` arguments
### Problem / Opportunity
The `FnToCLI` utility, which converts Python functions into CLI commands, does not support `pathlib.Path` arguments or the list parameter types `list[int]`, `list[float]`, and `list[Path]`. Functions that require file pa... | ## Requirements
- The `FnToCLI` class must accept functions with parameters annotated with `Path` from `pathlib` and convert the corresponding CLI string arguments into `Path` objects.
- The `FnToCLI` class must accept functions with parameters annotated as `list[int]`, `list[float]`, or `list[Path]`, and parse multip... | diff --git a/scripts/solr_builder/solr_builder/fn_to_cli.py b/scripts/solr_builder/solr_builder/fn_to_cli.py
index 289062c1341..9f32f120658 100644
--- a/scripts/solr_builder/solr_builder/fn_to_cli.py
+++ b/scripts/solr_builder/solr_builder/fn_to_cli.py
@@ -1,4 +1,5 @@
import asyncio
+from pathlib import Path
import t... | diff --git a/scripts/solr_builder/tests/test_fn_to_cli.py b/scripts/solr_builder/tests/test_fn_to_cli.py
index 13995235e..163b9d2ef 100644
--- a/scripts/solr_builder/tests/test_fn_to_cli.py
+++ b/scripts/solr_builder/tests/test_fn_to_cli.py
@@ -1,4 +1,4 @@
-from argparse import BooleanOptionalAction
+from pathlib impor... | ["scripts/solr_builder/tests/test_fn_to_cli.py::TestFnToCLI::test_lists", "scripts/solr_builder/tests/test_fn_to_cli.py::TestFnToCLI::test_paths", "scripts/solr_builder/tests/test_fn_to_cli.py::TestFnToCLI::test_run_returns_async_result", "scripts/solr_builder/tests/test_fn_to_cli.py::TestFnToCLI::test_scalar_path", "s... | ["scripts/solr_builder/tests/test_fn_to_cli.py::TestFnToCLI::test_full_flow", "scripts/solr_builder/tests/test_fn_to_cli.py::TestFnToCLI::test_parse_docs", "scripts/solr_builder/tests/test_fn_to_cli.py::TestFnToCLI::test_type_to_argparse", "scripts/solr_builder/tests/test_fn_to_cli.py::TestFnToCLI::test_is_optional"] | ghcr.io/scaleapi/swe-bench_pro-v2:instance_internetarchive__openlibrary-6afdb09df692223c3a31df65cfa92f15e5614c01-v08d8e8889ec945ab821fb156c04c7d2e2810debb | true | null | 1 | 30 | 5 | 832 | 0 | 0.95 | 1 | 0.55 | 1 | 0.238667 | 81.941 | |
1,439 | swe_gym::train::446 | swe_gym | train | 446 | python__mypy-9625 | python/mypy | python/mypy | python | ecec8bbf98ea1f78e61133312bee20e88de021fe | Type alias for Annotated[some_type, non_type] not supported
The following code:
```py
from typing_extensions import Annotated
class Positive:...
PositiveInt = Annotated[int, Positive()]
```
triggers the following error:
```
test.py:3: error: Invalid type alias: expression is not a valid type
```
Mypy version: mypy 0... | I'd recommend changing the issue topic to "Type alias for Annotated[some_type, non_type] not supported".
Because `A = Annotated[int, Positive]` works, and so does `x: Annotated[int, Positive()]`, but indeed `B = Annotated[int, Positive()]` does not.
I'd like to try fixing this bug 😊 Can I get some hints on where to... | diff --git a/mypy/exprtotype.py b/mypy/exprtotype.py
--- a/mypy/exprtotype.py
+++ b/mypy/exprtotype.py
@@ -3,7 +3,7 @@
from typing import Optional
from mypy.nodes import (
- Expression, NameExpr, MemberExpr, IndexExpr, TupleExpr, IntExpr, FloatExpr, UnaryExpr,
+ Expression, NameExpr, MemberExpr, IndexExpr, Re... | diff --git a/test-data/unit/check-annotated.test b/test-data/unit/check-annotated.test
--- a/test-data/unit/check-annotated.test
+++ b/test-data/unit/check-annotated.test
@@ -116,3 +116,13 @@ Alias = Annotated[Union[T, str], ...]
x: Alias[int]
reveal_type(x) # N: Revealed type is 'Union[builtins.int, builtins.str]'
... | ["mypy/test/testcheck.py::TypeCheckSuite::testAnnotatedSecondParamNonType"] | [] | null | true | 2020-10-22T00:20:58Z | 1 | 14 | 1 | 939 | 0 | 0.85 | 1 | 0.55 | 1 | 0.203167 | 81.9345 | |
1,440 | swe_gym::train::1891 | swe_gym | train | 1,891 | facebookresearch__hydra-1655 | facebookresearch/hydra | facebookresearch/hydra | python | cf353eb51b62105d81807923f21d5a8270ebdfd3 | possible to print `$CONFIG` in hydra help with interpolation resolved?
Hi, thank you for the brilliant library once again!
I am using `--help` functionality following the [docs](https://hydra.cc/docs/configure_hydra/app_help), and wondering if the values printed with `$CONFIG` can be 'resolved.
For example, what I get... | Hi @hwijeen!
> Is there a way to get hydra:runtime.cwd resolved to an actual path?
No. as of now, when you use the `--help` flag, only the values in the `hydra/help` config group will be resolved in the message.
> p.s. Is there a functional equivalence of python argparse's variable-wise help?
we have an o... | diff --git a/hydra/_internal/hydra.py b/hydra/_internal/hydra.py
--- a/hydra/_internal/hydra.py
+++ b/hydra/_internal/hydra.py
@@ -300,7 +300,11 @@ def format_config_groups(
return s
def get_help(
- self, help_cfg: DictConfig, cfg: DictConfig, args_parser: ArgumentParser
+ self,
+ h... | diff --git a/tests/test_hydra.py b/tests/test_hydra.py
--- a/tests/test_hydra.py
+++ b/tests/test_hydra.py
@@ -496,16 +496,22 @@ def test_cfg_resolve_interpolation(tmpdir: Path, resolve: bool, expected: str) -
assert_text_same(result, expected)
-def test_resolve_flag_without_cfg_flag(tmpdir: Path) -> None:
+@m... | ["tests/test_hydra.py::test_resolve_flag_errmsg[None]", "tests/test_hydra.py::test_resolve_flag_errmsg[--info]", "tests/test_hydra.py::test_resolve_flag_errmsg[--multirun]", "tests/test_hydra.py::test_resolve_flag_errmsg[--run]", "tests/test_hydra.py::test_help[overriding_help_template:$CONFIG,interp,yes_resolve]", "te... | ["tests/test_hydra.py::test_hydra_main_rerun[None-tests.test_apps.hydra_main_rerun.my_app]", "tests/test_hydra.py::test_module_env_override[FB_PAR_MAIN_MODULE]", "tests/test_hydra.py::test_hydra_main_rerun[tests/test_apps/hydra_main_rerun/my_app.py-None]", "tests/test_hydra.py::test_config_name_and_path_overrides[cfg2-... | null | true | 2021-06-08T06:04:30Z | 2 | 24 | 7 | 720 | 0 | 0.85 | 1 | 0.55 | 1 | 0.2 | 81.925 | |
1,441 | swe_gym::train::163 | swe_gym | train | 163 | getmoto__moto-5614 | getmoto/moto | getmoto/moto | python | b17a792f1cf3aa96f9b44a5c793793b8577df9f7 | Cloudwatch tag_resource only works if tags already exist
The moto cloudwatch `tag_resource` function only works if tags were added to the alarm when it was created. If they do not exist, then a `ResourceNotFoundException` is raised ([here](https://github.com/spulec/moto/blob/03f551870325fdce1c789bc43c286486cdddb13d/mot... | Thanks for raising this and providing the test case @bellmatt! | diff --git a/moto/cloudwatch/models.py b/moto/cloudwatch/models.py
--- a/moto/cloudwatch/models.py
+++ b/moto/cloudwatch/models.py
@@ -665,7 +665,10 @@ def list_tags_for_resource(self, arn):
return self.tagger.get_tag_dict_for_resource(arn)
def tag_resource(self, arn, tags):
- if arn not in self.... | diff --git a/tests/test_cloudwatch/test_cloudwatch_tags.py b/tests/test_cloudwatch/test_cloudwatch_tags.py
--- a/tests/test_cloudwatch/test_cloudwatch_tags.py
+++ b/tests/test_cloudwatch/test_cloudwatch_tags.py
@@ -102,6 +102,28 @@ def test_tag_resource():
)
+@mock_cloudwatch
+def test_tag_resource_on_resource... | ["tests/test_cloudwatch/test_cloudwatch_tags.py::test_tag_resource_on_resource_without_tags"] | ["tests/test_cloudwatch/test_cloudwatch_tags.py::test_untag_resource_error_not_exists", "tests/test_cloudwatch/test_cloudwatch_tags.py::test_list_tags_for_resource_with_unknown_resource", "tests/test_cloudwatch/test_cloudwatch_tags.py::test_untag_resource", "tests/test_cloudwatch/test_cloudwatch_tags.py::test_tag_resou... | null | true | 2022-10-27 19:51:47 | 1 | 5 | 1 | 2,047 | 0 | 0.85 | 1 | 0.7 | 0.8 | 0.357833 | 81.9235 | |
1,442 | swe_gym::train::2306 | swe_gym | train | 2,306 | Project-MONAI__MONAI-2937 | Project-MONAI/MONAI | project-monai/monai | python | 8651b622df76b75a9477538e985a14896f827150 | remove the hard-coded 3d constraint for resnet
**Is your feature request related to a problem? Please describe.**
the resnet implementation is hardcoded for 3d only while the network API support both 2d and 3d
https://github.com/Project-MONAI/MONAI/blob/62425d7d8809d129b4f35a51f425d02d325bd816/monai/networks/nets/resne... | Hi @Douwe-Spaanderman , could you please help for this task? I do not understand the parameter `shortcut_type`. | diff --git a/monai/networks/nets/resnet.py b/monai/networks/nets/resnet.py
--- a/monai/networks/nets/resnet.py
+++ b/monai/networks/nets/resnet.py
@@ -14,9 +14,10 @@
import torch
import torch.nn as nn
-import torch.nn.functional as F
from monai.networks.layers.factories import Conv, Norm, Pool
+from monai.networ... | diff --git a/tests/test_resnet.py b/tests/test_resnet.py
--- a/tests/test_resnet.py
+++ b/tests/test_resnet.py
@@ -42,14 +42,26 @@
(2, 3),
]
+TEST_CASE_2_A = [ # 2D, batch 2, 1 input channel, shortcut type A
+ {"pretrained": False, "spatial_dims": 2, "n_input_channels": 1, "num_classes": 3, "shortcut_type":... | ["tests/test_resnet.py::TestResNet::test_resnet_shape_24", "tests/test_resnet.py::TestResNet::test_resnet_shape_29", "tests/test_resnet.py::TestResNet::test_resnet_shape_30", "tests/test_resnet.py::TestResNet::test_resnet_shape_32", "tests/test_resnet.py::TestResNet::test_resnet_shape_23", "tests/test_resnet.py::TestRe... | ["tests/test_resnet.py::TestResNet::test_resnet_shape_16", "tests/test_resnet.py::TestResNet::test_resnet_shape_15", "tests/test_resnet.py::TestResNet::test_script_2", "tests/test_resnet.py::TestResNet::test_resnet_shape_14", "tests/test_resnet.py::TestResNet::test_resnet_shape_03", "tests/test_resnet.py::TestResNet::t... | null | true | 2021-09-13T12:47:16Z | 1 | 39 | 14 | 414 | 0 | 0.85 | 1 | 0.55 | 1 | 0.199 | 81.922 | |
1,443 | swe_gym::train::896 | swe_gym | train | 896 | iterative__dvc-3760 | iterative/dvc | iterative/dvc | python | fc42ca721c25bdd24875c999e37fb4f589ecd63c | update: add `-R, --recursive` flag
`dvc update -R/--recursive` should recursively find & update all DVC-files which are updateable (and be incompatible with `--rev`).
Allows replacing:
```
dvc update <long list of files> && dvc repro -P
```
with:
```
dvc update -R && dvc repro -P
``` | Let's not take `-a`, as we use it for `--all-branches` in othe rplaces already. Let's just use `--all` for now.
It'd be symmetrical with push/pull/add if we used `--recursive/-R` instead.
I'd like to implement it. May I?
في ثلاثاء، 5 مايو، 2020 في 1:05 م، كتب nik123 <notifications@github.com>:
> I'd like to implement ... | diff --git a/dvc/command/update.py b/dvc/command/update.py
--- a/dvc/command/update.py
+++ b/dvc/command/update.py
@@ -10,12 +10,15 @@
class CmdUpdate(CmdBase):
def run(self):
ret = 0
- for target in self.args.targets:
- try:
- self.repo.update(target, self.args.rev)
- ... | diff --git a/tests/func/test_repro.py b/tests/func/test_repro.py
--- a/tests/func/test_repro.py
+++ b/tests/func/test_repro.py
@@ -956,12 +956,12 @@ def test(self, mock_prompt):
self.assertNotEqual(self.dvc.status(), {})
- self.dvc.update(import_stage.path)
+ self.dvc.update([import_stage.pat... | ["tests/unit/command/test_update.py::test_update"] | [] | null | true | 2020-05-07T17:23:44Z | 2 | 45 | 1 | 285 | 0 | 0.85 | 1 | 0.55 | 1 | 0.1975 | 81.9175 | |
1,444 | swe_gym::train::592 | swe_gym | train | 592 | python__mypy-16074 | python/mypy | python/mypy | python | 49419835045b09c98b545171abb10384b6ecf6a9 | @overload - mypy thinks function signatures overlap
Hello,
I'm in the middle of introducing mypy to a medium-size codebase. Here's a simplified overload situation:
```
from typing import overload, List, Dict, Optional, Sequence, Union, Tuple
@overload
def f(a: List[Dict]) -> List[int]:
...
@overload
def f(a: Li... | I think the issue is that eg, it's unclear what type `foo({})` should be, which could lead to unsoundness. Closing, since I don't think this is a bug.
If you find the docs unclear, how would you feel about:
> All of the arguments of the first variant are potentially compatible with the second.
People often tend to ... | diff --git a/mypy/errorcodes.py b/mypy/errorcodes.py
--- a/mypy/errorcodes.py
+++ b/mypy/errorcodes.py
@@ -262,8 +262,8 @@ def __hash__(self) -> int:
# This is a catch-all for remaining uncategorized errors.
MISC: Final = ErrorCode("misc", "Miscellaneous other checks", "General")
-UNSAFE_OVERLOAD: Final[ErrorCode] ... | diff --git a/test-data/unit/check-errorcodes.test b/test-data/unit/check-errorcodes.test
--- a/test-data/unit/check-errorcodes.test
+++ b/test-data/unit/check-errorcodes.test
@@ -1077,7 +1077,7 @@ x = 1 # type: ignore # E: Unused "type: ignore" comment [unused-ignore]
from typing import overload, Union
@overload... | ["mypy/test/testcheck.py::TypeCheckSuite::check-errorcodes.test::testErrorCodeUnsafeOverloadError"] | ["mypy/test/testcheck.py::TypeCheckSuite::check-modules.test::testErrorInPassTwo1", "mypy/test/testcheck.py::TypeCheckSuite::check-modules.test::testSubmoduleMixingLocalAndQualifiedNames", "mypy/test/testtypegen.py::TypeExportSuite::typexport-basic.test::testLambdaAndHigherOrderFunctionAndKeywordArgs", "mypy/test/tests... | null | true | 2023-09-09T06:36:23Z | 3 | 8 | 1 | 1,007 | 0 | 0.85 | 1 | 0.55 | 1 | 0.1945 | 81.9085 | |
1,445 | swe_gym::train::109 | swe_gym | train | 109 | getmoto__moto-5940 | getmoto/moto | getmoto/moto | python | 418c69f477add62271938fbf4c1b8117087f4cd8 | Incorect response when calling glue.get_table_versions
## Reporting Bugs
The current implementation of glue.get_table_versions, see [here](https://github.com/getmoto/moto/blob/78840fd71c365bb40214f59a9d7c5f5f3d00b850/moto/glue/responses.py#L73-L85)
it's different from the actual response from boto3. Specifically `Ver... | Hey @nicor88, thanks for raising this. The `VersionId` should actually be returned twice, according to the AWS docs: once as part of the key of Table, and one separate. :confused:
Marking it as a bug.
@bblommers ah I see, as mentioned above also UpdateTime seems missing. | diff --git a/moto/glue/models.py b/moto/glue/models.py
--- a/moto/glue/models.py
+++ b/moto/glue/models.py
@@ -130,7 +130,7 @@ def create_table(self, database_name, table_name, table_input):
database.tables[table_name] = table
return table
- def get_table(self, database_name, table_name):
+ de... | diff --git a/tests/test_glue/test_datacatalog.py b/tests/test_glue/test_datacatalog.py
--- a/tests/test_glue/test_datacatalog.py
+++ b/tests/test_glue/test_datacatalog.py
@@ -339,11 +339,13 @@ def test_get_table_versions():
for n, ver in enumerate(vers):
n = str(n + 1)
ver["VersionId"].should.equ... | ["tests/test_glue/test_datacatalog.py::test_get_table_versions"] | ["tests/test_glue/test_datacatalog.py::test_delete_database", "tests/test_glue/test_datacatalog.py::test_create_partition_already_exist", "tests/test_glue/test_datacatalog.py::test_get_partitions_empty", "tests/test_glue/test_datacatalog.py::test_create_database", "tests/test_glue/test_datacatalog.py::test_batch_get_pa... | null | true | 2023-02-16 23:00:33 | 2 | 22 | 1 | 722 | 0 | 0.85 | 1 | 0.55 | 1 | 0.193667 | 81.906 | |
1,446 | swe_bench_pro::test::378 | swe_bench_pro | test | 378 | instance_internetarchive__openlibrary-08ac40d050a64e1d2646ece4959af0c42bf6b7b5-v0f5aece3601a5b4419f7ccec1dbda2071be28ee4 | internetarchive/openlibrary | internetarchive/openlibrary | python | 1e32ae3ec085dc3ab8611b88b56baf6354fa0762 | ## Title: Author roles from MARC records are not normalized or carried into work entries
### Description
MARC catalog import ignores the `$4` relator code subfield entirely, and the relator term it reads from the `$e` subfield is carried through as the raw catalog abbreviation instead of a readable role name. Work ent... | ## Requirements
- A `ROLES` mapping must translate MARC 21 relator codes taken from the `$4` subfield and common relator-term abbreviations taken from the `$e` subfield, such as `ed.` and `comp.`, into human-readable role names.
- Values recognized by the `ROLES` mapping must normalize to the exact strings `Editor`, `C... | diff --git a/openlibrary/catalog/add_book/__init__.py b/openlibrary/catalog/add_book/__init__.py
index 35ac34c0458..fac5d4a3087 100644
--- a/openlibrary/catalog/add_book/__init__.py
+++ b/openlibrary/catalog/add_book/__init__.py
@@ -240,7 +240,7 @@ def build_author_reply(authors_in, edits, source):
return (authors... | diff --git a/openlibrary/catalog/add_book/tests/test_add_book.py b/openlibrary/catalog/add_book/tests/test_add_book.py
index 86cc6ac2b9f..3683931fc23 100644
--- a/openlibrary/catalog/add_book/tests/test_add_book.py
+++ b/openlibrary/catalog/add_book/tests/test_add_book.py
@@ -492,6 +492,32 @@ def test_author_from_700(s... | ["openlibrary/catalog/marc/tests/test_parse.py::TestParseMARCXML::test_xml[warofrebellionco1473unit]", "openlibrary/catalog/marc/tests/test_parse.py::TestParseMARCXML::test_xml[00schlgoog]", "openlibrary/catalog/marc/tests/test_parse.py::TestParseMARCBinary::test_binary[memoirsofjosephf00fouc_meta.mrc]", "openlibrary/c... | ["openlibrary/catalog/marc/tests/test_parse.py::TestParseMARCXML::test_xml[39002054008678_yale_edu]", "openlibrary/catalog/marc/tests/test_parse.py::TestParseMARCXML::test_xml[flatlandromanceo00abbouoft]", "openlibrary/catalog/marc/tests/test_parse.py::TestParseMARCXML::test_xml[nybc200247]", "openlibrary/catalog/marc/... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_internetarchive__openlibrary-08ac40d050a64e1d2646ece4959af0c42bf6b7b5-v0f5aece3601a5b4419f7ccec1dbda2071be28ee4 | true | null | 2 | 41 | 7 | 536 | 0 | 0.95 | 1 | 0.55 | 1 | 0.226 | 81.903 | |
1,447 | swe_gym::train::813 | swe_gym | train | 813 | iterative__dvc-9825 | iterative/dvc | iterative/dvc | python | c71b07b99622ab37138d6d63f611a532c1dda142 | Path with `~` in config breaks repo parsing
An entry like this:
```ini
[cache]
dir = ~/Projects
```
Breaks DVC into a weird error (and breaks at the moment Studio parsing, which is a separate issue a bit - we need to make resilient to this, but changes here would help us):
<details>
</summary>DVC verbose output<... | @shcheklein Thanks for the report. You are spot on, we are using `isabs` there, but we really just need to do an expanduser somewhere there.
Will take a look. | diff --git a/dvc/config.py b/dvc/config.py
--- a/dvc/config.py
+++ b/dvc/config.py
@@ -250,21 +250,30 @@ def load_one(self, level):
return conf
@staticmethod
- def _load_paths(conf, filename):
- abs_conf_dir = os.path.abspath(os.path.dirname(filename))
+ def _resolve(conf_dir, path):
+ ... | diff --git a/tests/func/test_config.py b/tests/func/test_config.py
--- a/tests/func/test_config.py
+++ b/tests/func/test_config.py
@@ -265,14 +265,16 @@ def test_load_relative_paths(dvc, field, remote_url):
# check if written paths are correct
dvc_dir = dvc.config.dvc_dir
- assert dvc.config["remote"]["t... | ["tests/unit/test_config.py::test_resolve[ssh://some/path-ssh://some/path]", "tests/func/test_config.py::test_load_relative_paths[cert_path-webdavs://example.com/files/USERNAME/]", "tests/unit/test_config.py::test_resolve[../cache-/testbed/cache]", "tests/unit/test_config.py::test_resolve[/testbed-/testbed]", "tests/un... | ["tests/func/test_config.py::test_list_bad_args[args2]", "tests/func/test_config.py::test_list_bad_args[args1]", "tests/func/test_config.py::test_config_get[args3-0-iterative]", "tests/func/test_config.py::test_set_invalid_key", "tests/unit/test_config.py::test_load_unicode_error", "tests/func/test_config.py::test_conf... | null | true | 2023-08-09T21:17:26Z | 2 | 50 | 13 | 6,328 | 0 | 0.85 | 1 | 0.5 | 1 | 0.666667 | 81.9 | |
1,448 | swe_gym::train::872 | swe_gym | train | 872 | iterative__dvc-9647 | iterative/dvc | iterative/dvc | python | 90b919325043b3ab95e17253065f4cba9170ad9e | Don't fail because of extra keys in dvc file
With version changes, we break the schema for the various dvc files (`dvc.yaml`, `dvc.lock`, `.dvc` files, and `config`). This makes repos break when changing versions even though extra keys will at worst be ignored. Can we warn instead of failing for this error? | It also means old commits cannot be read in Studio
@skshetry WDYT, can we relax those?
> It also means old commits cannot be read in Studio
Bumping to p0 because of the Studio impact. It's making some Studio users' projects broken for their entire history.
> @skshetry WDYT, can we relax those?
Not possible withou... | diff --git a/dvc/parsing/__init__.py b/dvc/parsing/__init__.py
--- a/dvc/parsing/__init__.py
+++ b/dvc/parsing/__init__.py
@@ -232,6 +232,18 @@ def __init__(
self.definition = definition
self.where = where
+ def _resolve_wdir(
+ self, context: Context, name: str, wdir: Optional[str] = None... | diff --git a/tests/func/parsing/test_errors.py b/tests/func/parsing/test_errors.py
--- a/tests/func/parsing/test_errors.py
+++ b/tests/func/parsing/test_errors.py
@@ -9,6 +9,7 @@
from dvc.parsing import ResolveError
from dvc.parsing.context import Context
from dvc.parsing.interpolate import embrace
+from dvc.utils.h... | ["tests/func/parsing/test_errors.py::test_item_key_in_generated_stage_vars[True-redefine2]", "tests/func/parsing/test_errors.py::test_item_key_in_generated_stage_vars[False-redefine1]", "tests/func/parsing/test_errors.py::test_item_key_in_generated_stage_vars[False-redefine3]", "tests/func/parsing/test_errors.py::test_... | ["tests/func/parsing/test_resolver.py::test_load_vars_from_file", "tests/func/parsing/test_foreach.py::test_params_file_tracked_for_composite_list", "tests/func/parsing/test_foreach.py::test_foreach_data_is_only_resolved_once", "tests/func/parsing/test_foreach.py::test_foreach_interpolated_simple_list", "tests/func/par... | null | true | 2023-06-22T12:50:18Z | 2 | 42 | 31 | 308 | 0 | 0.85 | 1 | 0.55 | 1 | 0.191333 | 81.899 | |
1,449 | swe_bench_pro::test::337 | swe_bench_pro | test | 337 | instance_gravitational__teleport-645afa051b65d137654fd0d2d878a700152b305a-vee9b09fb20c43af7e520f57e9239bbcf46b7113d | gravitational/teleport | gravitational/teleport | go | ec6c5eafcec27adb503ff9ead7e42d2be4374fac | ### EC2 availability check is unreliable, causing incorrect node identification
### Description
The current method for detecting if Teleport is running on an EC2 instance is unreliable and can produce false positives. The system performs a simple HTTP GET to the EC2 metadata endpoint without validating the response c... | ## Requirements
- Update `NewInstanceMetadataClient` to accept optional configuration parameters that allow modifying the internal behavior of the created client during instantiation.
- Support passing configuration options as functional arguments during client creation to customize internal client dependencies or beh... | diff --git a/lib/utils/ec2.go b/lib/utils/ec2.go
index c44ff4831a749..c94ebc6d12eec 100644
--- a/lib/utils/ec2.go
+++ b/lib/utils/ec2.go
@@ -20,24 +20,20 @@ import (
"context"
"fmt"
"io"
- "net/http"
"regexp"
"strings"
"time"
"github.com/aws/aws-sdk-go-v2/config"
"github.com/aws/aws-sdk-go-v2/feature/... | diff --git a/lib/utils/ec2_test.go b/lib/utils/ec2_test.go
index 0d1dd5611a97b..02fb2375f6008 100644
--- a/lib/utils/ec2_test.go
+++ b/lib/utils/ec2_test.go
@@ -17,10 +17,16 @@ limitations under the License.
package utils
import (
+ "context"
+ "net/http"
+ "net/http/httptest"
+ "os"
"testing"
+ "github.com/aws... | ["TestEC2IsInstanceMetadataAvailable/response_with_new_id_format", "TestEC2IsInstanceMetadataAvailable/response_with_old_id_format", "TestEC2IsInstanceMetadataAvailable/mistake_some_other_service_for_instance_metadata", "TestEC2IsInstanceMetadataAvailable/not_available", "TestEC2IsInstanceMetadataAvailable"] | [] | ghcr.io/scaleapi/swe-bench_pro-v2:instance_gravitational__teleport-645afa051b65d137654fd0d2d878a700152b305a-vee9b09fb20c43af7e520f57e9239bbcf46b7113d | true | null | 1 | 59 | 5 | 8,010 | 0 | 0.95 | 1 | 0.5 | 1 | 0.696667 | 81.89 | |
1,450 | swe_gym::train::1044 | swe_gym | train | 1,044 | dask__dask-9378 | dask/dask | dask/dask | python | 8b95f983c232c1bd628e9cba0695d3ef229d290b | Mask preserving *_like functions
It would be useful to have versions of `ones_like`, `zeros_like` and `empty_like` that preserve masks when applied to masked dask arrays. Currently (version 2022.7.1) we have
```python
import dask.array as da
array = da.ma.masked_array([2, 3, 4], mask=[0, 0, 1])
print(da.ones_like(a... | @rcomer Thanks for reporting!
> If it really is that simple, I'd be happy to open a PR.
I think this should mostly work.
However, I'd first like to confirm that this isn't related to `https://github.com/numpy/numpy/issues/15200` -- what do you think about this?
cc @jsignell for visibility
Thanks @pavithra... | diff --git a/dask/array/ma.py b/dask/array/ma.py
--- a/dask/array/ma.py
+++ b/dask/array/ma.py
@@ -190,3 +190,21 @@ def count(a, axis=None, keepdims=False, split_every=None):
split_every=split_every,
out=None,
)
+
+
+@derived_from(np.ma.core)
+def ones_like(a, **kwargs):
+ a = asanyarray(a)
+ ... | diff --git a/dask/array/tests/test_masked.py b/dask/array/tests/test_masked.py
--- a/dask/array/tests/test_masked.py
+++ b/dask/array/tests/test_masked.py
@@ -427,3 +427,22 @@ def test_count():
res = da.ma.count(dx, axis=axis)
sol = np.ma.count(x, axis=axis)
assert_eq(res, sol, check_dtype=sy... | ["dask/array/tests/test_masked.py::test_like_funcs[empty_like]", "dask/array/tests/test_masked.py::test_like_funcs[zeros_like]", "dask/array/tests/test_masked.py::test_like_funcs[ones_like]"] | ["dask/array/tests/test_masked.py::test_mixed_concatenate[<lambda>4]", "dask/array/tests/test_masked.py::test_basic[<lambda>1]", "dask/array/tests/test_masked.py::test_mixed_random[<lambda>12]", "dask/array/tests/test_masked.py::test_basic[<lambda>0]", "dask/array/tests/test_masked.py::test_basic[<lambda>7]", "dask/arr... | null | true | 2022-08-12T16:25:22Z | 1 | 18 | 3 | 768 | 0 | 0.85 | 1 | 0.55 | 1 | 0.188 | 81.889 | |
1,451 | swe_gym::train::2107 | swe_gym | train | 2,107 | Project-MONAI__MONAI-4738 | Project-MONAI/MONAI | project-monai/monai | python | 71c66ef79fe83d570adef2ba3b08b2652dc2ab6e | support block type strings in resnet
**Is your feature request related to a problem? Please describe.**
from https://github.com/Project-MONAI/MONAI/discussions/4678, the resnet input args should be able to understand strings in addition to the class types, the corresponding docstrings should be revised https://github.c... | Hi @yiheng-wang-nv ,
Could you please help update the ResNet for it?
Thanks in advance.
Hi @Nic-Ma , sure. Also for `SENet`. | diff --git a/monai/networks/nets/resnet.py b/monai/networks/nets/resnet.py
--- a/monai/networks/nets/resnet.py
+++ b/monai/networks/nets/resnet.py
@@ -150,6 +150,9 @@ class ResNet(nn.Module):
Args:
block: which ResNet block to use, either Basic or Bottleneck.
+ ResNet block class or str.
+ ... | diff --git a/tests/test_resnet.py b/tests/test_resnet.py
--- a/tests/test_resnet.py
+++ b/tests/test_resnet.py
@@ -16,7 +16,8 @@
from parameterized import parameterized
from monai.networks import eval_mode
-from monai.networks.nets import resnet10, resnet18, resnet34, resnet50, resnet101, resnet152, resnet200
+from... | ["tests/test_resnet.py::TestResNet::test_resnet_shape_35", "tests/test_resnet.py::TestResNet::test_resnet_shape_37", "tests/test_senet.py::TestSENET::test_senet_shape_6"] | ["tests/test_resnet.py::TestResNet::test_resnet_shape_32", "tests/test_resnet.py::TestResNet::test_resnet_shape_29", "tests/test_senet.py::test_is_quick", "tests/test_resnet.py::TestResNet::test_resnet_shape_33", "tests/test_resnet.py::TestResNet::test_resnet_shape_16", "tests/test_resnet.py::TestResNet::test_resnet_sh... | null | true | 2022-07-21T06:53:15Z | 2 | 35 | 3 | 428 | 0 | 0.85 | 1 | 0.55 | 1 | 0.188 | 81.889 | |
1,452 | swe_gym::train::1973 | swe_gym | train | 1,973 | Project-MONAI__MONAI-3340 | Project-MONAI/MONAI | project-monai/monai | python | e148cfdb0b0ad90db2cc247e6d27cb5124d30cdb | unit test error from `python -m tests.clang_format_utils`
**Describe the bug**
error from `python -m tests.clang_format_utils`
```
2021-11-14 22:26:15,861 - INFO - Downloaded: /__w/MONAI/MONAI/.clang-format-bin/clang-format
2021-11-14 22:26:15,864 - ERROR - check_hash failed 938869fb71b05f5ba345ab36dfbbc4388f53a550.
cl... | Thanks for your report, I also saw this error in PR: https://github.com/Project-MONAI/MONAI/pull/3325/.
| diff --git a/monai/apps/__init__.py b/monai/apps/__init__.py
--- a/monai/apps/__init__.py
+++ b/monai/apps/__init__.py
@@ -11,4 +11,4 @@
from .datasets import CrossValidation, DecathlonDataset, MedNISTDataset
from .mmars import MODEL_DESC, RemoteMMARKeys, download_mmar, get_model_spec, load_from_mmar
-from .utils i... | diff --git a/tests/clang_format_utils.py b/tests/clang_format_utils.py
--- a/tests/clang_format_utils.py
+++ b/tests/clang_format_utils.py
@@ -34,8 +34,8 @@
# This dictionary maps each platform to a relative path to a file containing its reference hash.
# github/pytorch/pytorch/tree/63d62d3e44a0a4ec09d94f30381d49b78c... | ["tests/test_check_hash.py::TestCheckMD5::test_hash_type_error"] | ["tests/test_check_hash.py::TestCheckMD5::test_result_1_abcdefg", "tests/test_check_hash.py::TestCheckMD5::test_result_4_b4dc3c246b298eae37cefdfdd2a50b091ffd5e69", "tests/test_check_hash.py::TestCheckMD5::test_result_2", "tests/test_check_hash.py::TestCheckMD5::test_result_3", "tests/test_check_hash.py::TestCheckMD5::t... | null | true | 2021-11-15T08:30:34Z | 2 | 19 | 1 | 735 | 0 | 0.85 | 1 | 0.55 | 1 | 0.185833 | 81.8825 | |
1,453 | swe_gym::train::869 | swe_gym | train | 869 | iterative__dvc-4309 | iterative/dvc | iterative/dvc | python | fcf2e3522c4775e8bd7b50581a15c1693e30d124 | remote local config does not see existing remote
## Bug Report
### Please provide information about your setup
**Output of `dvc version`:**
```console
DVC version: 1.1.10+1c9588
Python version: 3.8.4
Platform: macOS-10.15.4-x86_64-i386-64bit
Binary: False
Package: None
Supported remotes: azure, gdrive, gs, hdfs, htt... | This one is a known issue since the config refactor. Workaround is to simply first do:
```
dvc remote add storage s3://storage --local
```
just to let you know this breaks all the docs/examples | diff --git a/dvc/command/remote.py b/dvc/command/remote.py
--- a/dvc/command/remote.py
+++ b/dvc/command/remote.py
@@ -3,7 +3,7 @@
from dvc.command.base import append_doc_link, fix_subparsers
from dvc.command.config import CmdConfig
-from dvc.config import ConfigError
+from dvc.config import ConfigError, merge
fro... | diff --git a/tests/func/test_remote.py b/tests/func/test_remote.py
--- a/tests/func/test_remote.py
+++ b/tests/func/test_remote.py
@@ -232,6 +232,24 @@ def test_modify_missing_remote(tmp_dir, dvc):
assert main(["remote", "modify", "myremote", "user", "xxx"]) == 251
+def test_remote_modify_local_on_repo_config(... | ["tests/func/test_remote.py::test_remote_modify_local_on_repo_config"] | ["tests/func/test_remote.py::TestRemote::test_relative_path", "tests/func/test_remote.py::TestRemoteDefault::test", "tests/func/test_remote.py::test_remote_modify_validation", "tests/func/test_remote.py::TestRemote::test_referencing_other_remotes", "tests/func/test_remote.py::TestRemote::test_overwrite", "tests/func/te... | null | true | 2020-07-31T01:13:06Z | 2 | 17 | 1 | 767 | 0 | 0.85 | 1 | 0.55 | 1 | 0.1845 | 81.8785 | |
1,454 | swe_gym::train::729 | swe_gym | train | 729 | iterative__dvc-6273 | iterative/dvc | iterative/dvc | python | 2485779d59143799d4a489b42294ee6b7ce52a80 | doctor: should dvc doctor show remote-required dependency versions
Something that we've been experiencing lately is asking for an extra question regarding the version of their used remote dependency. We could try to annotate the dvc doctor's output with the stuff that we can get (optional). Something like this
```
$ d... | CC: @iterative/dvc
This would be amazing! :fire: Should we bump the priority?
One thing that is a bit problematic is when the all remotes are installed. Normally instead of listing everything, DVC only prints All remotes;
```
$ dvc doctor
DVC version: 2.4.3+ce45ec.mod
---------------------------------
Platform:... | diff --git a/dvc/fs/http.py b/dvc/fs/http.py
--- a/dvc/fs/http.py
+++ b/dvc/fs/http.py
@@ -31,6 +31,7 @@ class HTTPFileSystem(BaseFileSystem): # pylint:disable=abstract-method
PATH_CLS = HTTPURLInfo
PARAM_CHECKSUM = "etag"
CAN_TRAVERSE = False
+ REQUIRES = {"requests": "requests"}
SESSION_RETR... | diff --git a/tests/func/test_version.py b/tests/func/test_version.py
--- a/tests/func/test_version.py
+++ b/tests/func/test_version.py
@@ -1,7 +1,7 @@
import re
from dvc.main import main
-from tests.unit.test_info import PYTHON_VERSION_REGEX
+from tests.unit.test_info import PYTHON_VERSION_REGEX, find_supported_rem... | ["tests/unit/test_info.py::test_info_outside_of_repo", "tests/unit/test_info.py::test_fs_info_outside_of_repo"] | [] | null | true | 2021-07-02T10:29:19Z | 3 | 29 | 2 | 525 | 0 | 0.85 | 1 | 0.55 | 1 | 0.184167 | 81.8775 | |
1,455 | swe_gym::train::2349 | swe_gym | train | 2,349 | modin-project__modin-5940 | modin-project/modin | modin-project/modin | python | e1d42410c3900f93be420303e745de29c1e6bda1 | BUG: passing connection object to to_sql causes "can not pickle" error
### System information
- **OS Platform and Distribution (e.g., Linux Ubuntu 16.04)**: windows server
- **Modin version** (`modin.__version__`): 0.12.1
- **Python version**:3.8.12
- **Code we can use to reproduce**: may be
### Describe the problem
... | Hi @EnderWuBinHao!
Thanks for reporting! I can reproduce your issue using Postgresql DBMS, see reproducer below:
```
import modin.pandas as pd
from sqlalchemy import create_engine
table_name = "test_table"
conn_str = "postgresql://username:password@localhost/db_name"
conn = create_engine(conn_str)
df = pd.D... | diff --git a/modin/core/io/sql/sql_dispatcher.py b/modin/core/io/sql/sql_dispatcher.py
--- a/modin/core/io/sql/sql_dispatcher.py
+++ b/modin/core/io/sql/sql_dispatcher.py
@@ -110,6 +110,17 @@ def _read(cls, sql, con, index_col=None, **kwargs):
new_frame.synchronize_labels(axis=0)
return cls.query_comp... | diff --git a/modin/pandas/test/test_io.py b/modin/pandas/test/test_io.py
--- a/modin/pandas/test/test_io.py
+++ b/modin/pandas/test/test_io.py
@@ -2344,12 +2344,17 @@ def test_read_sql_with_chunksize(self, make_sql_connection):
df_equals(modin_df, pandas_df)
@pytest.mark.parametrize("index", [False,... | ["modin/pandas/test/test_io.py::TestSql::test_to_sql[sqlalchemy+connect-True]", "modin/pandas/test/test_io.py::TestSql::test_to_sql[sqlalchemy-True]", "modin/pandas/test/test_io.py::TestSql::test_to_sql[sqlalchemy+connect-False]", "modin/pandas/test/test_io.py::TestSql::test_to_sql[sqlalchemy-False]"] | ["modin/pandas/test/test_io.py::TestCsv::test_read_csv_parsing_2[latin1-None-None-skiprows5-infer]", "modin/pandas/test/test_io.py::TestParquet::test_read_parquet_directory[rows_per_file0-1000-columns1-pyarrow]", "modin/pandas/test/test_io.py::TestCsv::test_read_csv_parse_dates[None-infer-5-nonexistent_string_column-st... | null | true | 2023-04-05T13:56:04Z | 1 | 22 | 4 | 664 | 0 | 0.85 | 1 | 0.55 | 1 | 0.184 | 81.877 | |
1,456 | swe_gym::train::502 | swe_gym | train | 502 | python__mypy-11814 | python/mypy | python/mypy | python | 578898dabae9a6c91b8f1081630c91cbe7e6f5be | crash when extending `typing_extensions.Annotated`
```py
from typing_extensions import Annotated
class A(Annotated): pass
```
```
Sandpit\Test.py:172: error: INTERNAL ERROR -- Please try using mypy master on Github:
https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
analyzer.re... | Fix is on its way! Thanks for the report! 👍 | diff --git a/mypy/typeanal.py b/mypy/typeanal.py
--- a/mypy/typeanal.py
+++ b/mypy/typeanal.py
@@ -1291,7 +1291,9 @@ def visit_unbound_type(self, t: UnboundType) -> TypeVarLikeList:
return []
elif node and node.fullname in ('typing_extensions.Literal', 'typing.Literal'):
return []
- ... | diff --git a/test-data/unit/semanal-errors.test b/test-data/unit/semanal-errors.test
--- a/test-data/unit/semanal-errors.test
+++ b/test-data/unit/semanal-errors.test
@@ -1435,3 +1435,10 @@ TP = ParamSpec('?') # E: String argument 1 "?" to ParamSpec(...) does not match
TP2: int = ParamSpec('TP2') # E: Cannot declare... | ["mypy/test/testsemanal.py::SemAnalErrorSuite::semanal-errors.test::testBaseClassAnnotatedWithoutArgs"] | [] | null | true | 2021-12-21T22:24:44Z | 1 | 4 | 1 | 1,955 | 0 | 0.85 | 1 | 0.7 | 0.8 | 0.339167 | 81.8675 | |
1,457 | swe_gym::train::1 | swe_gym | train | 1 | getmoto__moto-6920 | getmoto/moto | getmoto/moto | python | 2021e564fafcdaa701b53de49bd580c8691a5fcc | Lambda publish_layer_version function failed due to the wrong implementation
## Reporting Bugs
When you run ``publish_layer_version``
```
lambda_client.publish_layer_version(
LayerName="my_layer",
Content=dict(
S3Bucket="my-bucket",
S3Key="my-key.zip",
)
)
```
It raises this error:
```
... | Hi @MacHu-GWU, that attribute should be calculated inside the `LayerVersion`-class:
https://github.com/getmoto/moto/blob/368fa07ec35aa6806c839a1f4883426159179127/moto/awslambda/models.py#L371
If the S3 file exists, it will use that information.
If it does not exist, it will throw an error (`The specified bucket d... | diff --git a/moto/awslambda/models.py b/moto/awslambda/models.py
--- a/moto/awslambda/models.py
+++ b/moto/awslambda/models.py
@@ -371,6 +371,11 @@ def __init__(self, spec: Dict[str, Any], account_id: str, region: str):
self.code_sha_256,
self.code_digest,
) = ... | diff --git a/tests/test_awslambda/test_lambda_layers.py b/tests/test_awslambda/test_lambda_layers.py
--- a/tests/test_awslambda/test_lambda_layers.py
+++ b/tests/test_awslambda/test_lambda_layers.py
@@ -1,10 +1,12 @@
import boto3
+import os
import pytest
from botocore.exceptions import ClientError
from freezegun ... | ["tests/test_awslambda/test_lambda_layers.py::test_publish_layer_with_unknown_s3_file"] | ["tests/test_awslambda/test_lambda_layers.py::test_get_layer_version__unknown", "tests/test_awslambda/test_lambda_layers.py::test_publish_lambda_layers__without_content", "tests/test_awslambda/test_lambda_layers.py::test_get_lambda_layers", "tests/test_awslambda/test_lambda_layers.py::test_get_layer_version", "tests/te... | null | true | 2023-10-15 20:33:23 | 1 | 5 | 1 | 1,930 | 0 | 0.85 | 1 | 0.7 | 0.8 | 0.338333 | 81.865 | |
1,458 | swe_gym::train::347 | swe_gym | train | 347 | python__mypy-16154 | python/mypy | python/mypy | python | 3d3e482e03c1efeaca9a1033acf06f56c1dfdf86 | Incorrect Error with NamedTuple slices ?
Assuming the following file:
```
$ cat foo.py
from typing import NamedTuple, List, Tuple, Sequence
from typing import NamedTuple, List, Sequence
class NT(NamedTuple):
matched_text: str
matches: Sequence[str] # Sequence will not match List below
matches_origin: in... | Hello Sir, I want to start contributing in open source.
Can i fix this issue?
This error is worse than just invalid error reporting, mypy thinks a sliced NamedTuple is still an instance of the NamedTuple rather than a plain tuple:
eg it considers this valid:
```python
from typing import NamedTuple
class Exampl... | diff --git a/mypy/checkexpr.py b/mypy/checkexpr.py
--- a/mypy/checkexpr.py
+++ b/mypy/checkexpr.py
@@ -4271,7 +4271,7 @@ def visit_tuple_slice_helper(self, left_type: TupleType, slic: SliceExpr) -> Typ
items: list[Type] = []
for b, e, s in itertools.product(begin, end, stride):
- item = l... | diff --git a/test-data/unit/check-literal.test b/test-data/unit/check-literal.test
--- a/test-data/unit/check-literal.test
+++ b/test-data/unit/check-literal.test
@@ -1872,8 +1872,9 @@ reveal_type(tup2[idx3]) # N: Revealed type is "__main__.D"
reveal_type(tup2[idx4]) # N: Revealed type is "__main__.E"
rev... | ["mypy/test/testcheck.py::TypeCheckSuite::check-tuples.test::testTupleSubclassSlice"] | ["mypy/test/testcheck.py::TypeCheckSuite::check-literal.test::testLiteralIntelligentIndexingTypedDictUnions", "mypy/test/testcheck.py::TypeCheckSuite::check-literal.test::testLiteralIntelligentIndexingTypedDict"] | null | true | 2023-09-21T13:32:32Z | 2 | 11 | 1 | 836 | 0 | 0.85 | 1 | 0.55 | 1 | 0.176 | 81.853 | |
1,459 | swe_gym::train::1093 | swe_gym | train | 1,093 | pydantic__pydantic-9287 | pydantic/pydantic | pydantic/pydantic | python | 77b0e1ccd775c101be28b5dfa56bc36f1eed7eca | Possible problem with dataclasses.dataclass and calling model_json_schema()
### Initial Checks
- [X] I confirm that I'm using Pydantic V2
### Description
I experience a crash when running the code example below with Pydantic version 2.7.0. Resulting in this exception:
```bash
pydantic.errors.PydanticUserError: Cann... | Relevant code:
https://github.com/pydantic/pydantic/blob/b844ea7ae652b88fd002ef040d606ae3262c1010/pydantic/json_schema.py#L2042-L2048
This could be fixed in two ways:
- Allow `TypeAdapter` to take types that supports config (i.e. `BaseModel`, dataclasses and `TypedDict`) with the `config` kw argument provided, e... | diff --git a/pydantic/json_schema.py b/pydantic/json_schema.py
--- a/pydantic/json_schema.py
+++ b/pydantic/json_schema.py
@@ -2037,13 +2037,13 @@ def encode_default(self, dft: Any) -> Any:
Returns:
The encoded default value.
"""
- from .type_adapter import TypeAdapter
+ fro... | diff --git a/tests/test_json_schema.py b/tests/test_json_schema.py
--- a/tests/test_json_schema.py
+++ b/tests/test_json_schema.py
@@ -1,3 +1,4 @@
+import dataclasses
import json
import math
import re
@@ -6030,3 +6031,108 @@ class Model(BaseModel):
schema = Model.model_json_schema()
assert schema == expe... | ["tests/test_json_schema.py::test_pydantic_types_as_default_values[builtin-dataclass]"] | ["tests/test_json_schema.py::test_ipv6network_type", "tests/test_json_schema.py::test_typeddict_with__callable_json_schema_extra", "tests/test_json_schema.py::test_schema_attributes", "tests/test_json_schema.py::test_secrets_schema[min-max-constraints-SecretStr]", "tests/test_json_schema.py::test_dataclass_with_extra_i... | null | true | 2024-04-19T15:54:50Z | 1 | 4 | 1 | 1,920 | 0 | 0.85 | 1 | 0.7 | 0.8 | 0.333333 | 81.85 | |
1,460 | swe_bench_pro::test::542 | swe_bench_pro | test | 542 | instance_protonmail__webclients-944adbfe06644be0789f59b78395bdd8567d8547 | protonmail/webclients | protonmail/webclients | javascript | 7c7e668956cf9df0f51d401dbb00b7e1d445198b | # Title: API error metrics
## Description
#### What would you like to do?
May like to begin measuring the error that the API throws. Whether it is a server- or client-based error, or if there is another type of failure.
#### Why would you like to do it?
It is needed to get insights about the issues that we are hav... | ## Requirements
- A function named `observeApiError` should be included in the public API of the `@proton/metrics` package as the default export of its module file, so that it can be imported via a default import.
- The `observeApiError` function should take two parameters: `error` of any type, and `metricObserver`, a... | diff --git a/packages/metrics/index.ts b/packages/metrics/index.ts
index 5009ed0b722..dd2f2db49ec 100644
--- a/packages/metrics/index.ts
+++ b/packages/metrics/index.ts
@@ -18,6 +18,9 @@ import { WebCoreSignupReferralStepPlanSelectionTotal } from './types/web_core_si
import { WebCoreSignupUpsellStepPlanSelectionTotal ... | diff --git a/packages/metrics/tests/observeApiError.test.ts b/packages/metrics/tests/observeApiError.test.ts
new file mode 100644
index 000000000..135593dc1
--- /dev/null
+++ b/packages/metrics/tests/observeApiError.test.ts
@@ -0,0 +1,76 @@
+import observeApiError from '../lib/observeApiError';
+
+const metricObserver ... | ["tests/observeApiError.test.ts | returns failure if error is undefined", "tests/observeApiError.test.ts | returns failure if error is null", "tests/observeApiError.test.ts | returns failure if error is not an object", "tests/observeApiError.test.ts | returns failure if error does not contain a status property", "tests... | [] | ghcr.io/scaleapi/swe-bench_pro-v2:instance_protonmail__webclients-944adbfe06644be0789f59b78395bdd8567d8547 | true | null | 2 | 20 | 10 | 849 | 0 | 0.95 | 1 | 0.55 | 1 | 0.208167 | 81.8495 | |
1,461 | swe_gym::train::355 | swe_gym | train | 355 | python__mypy-15184 | python/mypy | python/mypy | python | 13f35ad0915e70c2c299e2eb308968c86117132d | assert_type: Use fully qualified types when names are ambiguous
On current master, this code:
```python
from typing import TypeVar
import typing
import typing_extensions
U = TypeVar("U", int, typing_extensions.SupportsIndex)
def f(si: U) -> U:
return si
def caller(si: typing.SupportsIndex):
typing_extension... | I don't know if this is the exact same bug or not, but I just discovered that this code:
```python
from typing_extensions import assert_type
assert_type(42, int)
```
fails to typecheck with mypy (both 0.960 and commit 1636a0549670e1b75e2987c16ef26ebf91dfbde9) with the following message:
```
assert-type01... | diff --git a/mypy/messages.py b/mypy/messages.py
--- a/mypy/messages.py
+++ b/mypy/messages.py
@@ -1656,12 +1656,8 @@ def redundant_cast(self, typ: Type, context: Context) -> None:
)
def assert_type_fail(self, source_type: Type, target_type: Type, context: Context) -> None:
- self.fail(
- ... | diff --git a/test-data/unit/check-assert-type-fail.test b/test-data/unit/check-assert-type-fail.test
new file mode 100644
--- /dev/null
+++ b/test-data/unit/check-assert-type-fail.test
@@ -0,0 +1,28 @@
+[case testAssertTypeFail1]
+import typing
+import array as arr
+class array:
+ pass
+def f(si: arr.array[int]):
+ ... | ["mypy/test/testcheck.py::TypeCheckSuite::check-assert-type-fail.test::testAssertTypeFail1", "mypy/test/testcheck.py::TypeCheckSuite::check-assert-type-fail.test::testAssertTypeFail2"] | ["mypy/test/testcheck.py::TypeCheckSuite::check-assert-type-fail.test::testAssertTypeFail3"] | null | true | 2023-05-04T15:43:32Z | 1 | 8 | 2 | 887 | 0 | 0.85 | 1 | 0.55 | 1 | 0.1745 | 81.8485 | |
1,462 | swe_bench_pro::test::43 | swe_bench_pro | test | 43 | instance_ansible__ansible-164881d871964aa64e0f911d03ae270acbad253c-v390e508d27db7a51eece36bb6d9698b63a5b638a | ansible/ansible | ansible/ansible | python | e80f8048ee027ab0c7c8b5912fb6c69c44fb877a | # Title `wrap_var` does not mark binary values as unsafe
## Description
When `wrap_var` receives a binary (`bytes`) value, it may return ordinary bytes instead of an `AnsibleUnsafeBytes` instance. This leaves binary data without Ansible's unsafe marker and makes its handling inconsistent with unsafe text values.
Bina... | ## Requirements
- `wrap_var` must return an existing `AnsibleUnsafe` value unchanged, including `AnsibleUnsafeText` and `AnsibleUnsafeBytes` instances.
- When given a text value, `wrap_var` must return an `AnsibleUnsafeText` instance that preserves the original content.
- When given a binary (`bytes`) value, `wrap_va... | diff --git a/lib/ansible/executor/task_executor.py b/lib/ansible/executor/task_executor.py
index 7e7000563bdbbf..3e524afc064beb 100644
--- a/lib/ansible/executor/task_executor.py
+++ b/lib/ansible/executor/task_executor.py
@@ -28,7 +28,7 @@
from ansible.template import Templar
from ansible.utils.collection_loader imp... | diff --git a/test/units/utils/test_unsafe_proxy.py b/test/units/utils/test_unsafe_proxy.py
index 04f54d4f49b1fb..c2a9f861c53945 100644
--- a/test/units/utils/test_unsafe_proxy.py
+++ b/test/units/utils/test_unsafe_proxy.py
@@ -6,30 +6,28 @@
__metaclass__ = type
from ansible.module_utils.six import PY3
-from ansible... | ["test/units/utils/test_unsafe_proxy.py::test_wrap_var_bytes"] | ["test/units/utils/test_unsafe_proxy.py::test_wrap_var_text", "test/units/utils/test_unsafe_proxy.py::test_wrap_var_string", "test/units/utils/test_unsafe_proxy.py::test_wrap_var_dict", "test/units/utils/test_unsafe_proxy.py::test_wrap_var_dict_None", "test/units/utils/test_unsafe_proxy.py::test_wrap_var_list", "test/u... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_ansible__ansible-164881d871964aa64e0f911d03ae270acbad253c-v390e508d27db7a51eece36bb6d9698b63a5b638a | true | null | 3 | 38 | 1 | 479 | 0 | 0.95 | 1 | 0.55 | 1 | 0.2065 | 81.8445 | |
1,463 | swe_bench_pro::test::566 | swe_bench_pro | test | 566 | instance_qutebrowser__qutebrowser-0833b5f6f140d04200ec91605f88704dd18e2970-v059c6fdc75567943479b23ebca7c07b5e9a7f34c | qutebrowser/qutebrowser | qutebrowser/qutebrowser | python | def864adc8b19bdbc506919270d8ff1408b4faac | ## Title:
Error signal in WebKit `NetworkReply` uses deprecated `error` instead of `errorOccurred`.
### Description
In the WebKit backend, the `NetworkReply` implementation still emits the legacy `error` signal when an error reply is constructed. Recent versions of Qt have replaced this with the `errorOccurred` signa... | ## Requirements
- In the WebKit `NetworkReply` implementation, the initial error emission should use the `errorOccurred` signal with the error code, instead of the legacy `error` signal.
## Interface
No new interfaces are introduced.
| diff --git a/qutebrowser/browser/qtnetworkdownloads.py b/qutebrowser/browser/qtnetworkdownloads.py
index 46d51d9300d..d889bed83c9 100644
--- a/qutebrowser/browser/qtnetworkdownloads.py
+++ b/qutebrowser/browser/qtnetworkdownloads.py
@@ -125,7 +125,13 @@ def _do_die(self):
return
self._reply.downlo... | diff --git a/tests/unit/browser/webkit/network/test_networkreply.py b/tests/unit/browser/webkit/network/test_networkreply.py
index 5de31bf0f09..fc400c1b297 100644
--- a/tests/unit/browser/webkit/network/test_networkreply.py
+++ b/tests/unit/browser/webkit/network/test_networkreply.py
@@ -78,7 +78,7 @@ def test_error_ne... | ["tests/unit/browser/webkit/network/test_networkreply.py::test_error_network_reply"] | ["tests/unit/browser/webkit/network/test_networkreply.py::TestFixedDataNetworkReply::test_attributes", "tests/unit/browser/webkit/network/test_networkreply.py::TestFixedDataNetworkReply::test_data[]", "tests/unit/browser/webkit/network/test_networkreply.py::TestFixedDataNetworkReply::test_data[foobar]", "tests/unit/bro... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_qutebrowser__qutebrowser-0833b5f6f140d04200ec91605f88704dd18e2970-v059c6fdc75567943479b23ebca7c07b5e9a7f34c | true | null | 3 | 30 | 1 | 633 | 0 | 0.95 | 1 | 0.55 | 1 | 0.2055 | 81.8415 | |
1,464 | swe_gym::train::255 | swe_gym | train | 255 | getmoto__moto-4969 | getmoto/moto | getmoto/moto | python | 2d18ec5a7be69145de6e11d171acfb11ad614ef5 | ECR batch_delete_image incorrectly adding failures to reponse
https://github.com/spulec/moto/blob/eed32a5f72fbdc0d33c4876d1b5439dfd1efd5d8/moto/ecr/models.py#L634-L651
This block of code appears to be indented one level too far and is running for each iteration of the for loop that begins on line 593 instead of only r... | Hi @jmeyer42, this looks OK to me, actually. It tries to delete a batch of images, and per image, if it can't be found, it will add a `failureResponse` to the response.
Do you have a test case (ideally using boto3) that clarifies what is wrong about this logic?
Below is some code and a corresponding test case that i... | diff --git a/moto/ecr/models.py b/moto/ecr/models.py
--- a/moto/ecr/models.py
+++ b/moto/ecr/models.py
@@ -631,24 +631,24 @@ def batch_delete_image(self, repository_name, registry_id=None, image_ids=None):
else:
repository.images.remove(image)
- if not imag... | diff --git a/tests/test_ecr/test_ecr_boto3.py b/tests/test_ecr/test_ecr_boto3.py
--- a/tests/test_ecr/test_ecr_boto3.py
+++ b/tests/test_ecr/test_ecr_boto3.py
@@ -1249,6 +1249,40 @@ def test_batch_delete_image_with_mismatched_digest_and_tag():
)
+@mock_ecr
+def test_delete_batch_image_with_multiple_images():
+... | ["tests/test_ecr/test_ecr_boto3.py::test_delete_batch_image_with_multiple_images"] | ["tests/test_ecr/test_ecr_boto3.py::test_delete_repository_with_force", "tests/test_ecr/test_ecr_boto3.py::test_start_image_scan_error_repo_not_exists", "tests/test_ecr/test_ecr_boto3.py::test_get_lifecycle_policy", "tests/test_ecr/test_ecr_boto3.py::test_create_repository_with_non_default_config", "tests/test_ecr/test... | null | true | 2022-03-25 14:29:15 | 1 | 30 | 1 | 432 | 0 | 0.85 | 1 | 0.55 | 1 | 0.172 | 81.841 | |
1,465 | swe_gym::train::1867 | swe_gym | train | 1,867 | facebookresearch__hydra-1456 | facebookresearch/hydra | facebookresearch/hydra | python | 7e7832f72664b40ee04834ac8956e7146a3d37fb | [Bug] AssertionError triggered with multiple configs from a Config Group specified at CLI
# 🐛 Bug
## Description
An assertion error is raised if the CLI is used to select multiple options from a Config Group:
```python
$ cat my_app.py
import hydra
from omegaconf import OmegaConf
@hydra.main()
def my_app(cfg):
pr... | > Note that there is no error if we remove the db directory:
Removing the db directory changes from from a statement overriding the config group db to a list of two configs, into a list of two values (which is a completely different beast). | diff --git a/hydra/_internal/config_loader_impl.py b/hydra/_internal/config_loader_impl.py
--- a/hydra/_internal/config_loader_impl.py
+++ b/hydra/_internal/config_loader_impl.py
@@ -230,7 +230,7 @@ def _load_configuration_impl(
defaults_list = create_defaults_list(
repo=caching_repo,
... | diff --git a/tests/defaults_list/__init__.py b/tests/defaults_list/__init__.py
--- a/tests/defaults_list/__init__.py
+++ b/tests/defaults_list/__init__.py
@@ -16,6 +16,7 @@
def create_repo() -> IConfigRepository:
csp = ConfigSearchPathImpl()
csp.append(provider="test", path="file://tests/defaults_list/data")... | ["tests/defaults_list/test_defaults_tree.py::test_experiment_overriding_hydra_group[experiment_overriding_hydra_group]", "tests/defaults_list/test_defaults_tree.py::test_none_config_with_hydra[none_config]", "tests/defaults_list/test_defaults_tree.py::test_select_multi[append_new_list_to_a_config_without_a_defaults_lis... | ["tests/defaults_list/test_defaults_tree.py::test_deprecated_package_header_keywords[deprecated_headers/group_foo]", "tests/defaults_list/test_defaults_list.py::test_set_package_header_with_parent_pkg[gd:_group_]", "tests/defaults_list/test_defaults_tree.py::test_interpolation[interpolation_with_nested_defaults_list_wi... | null | true | 2021-03-06T00:38:08Z | 2 | 57 | 11 | 3,253 | 0.0625 | 0.85 | 1 | 0.62 | 1 | 0.69 | 81.83225 | |
1,466 | swe_gym::train::50 | swe_gym | train | 50 | getmoto__moto-6755 | getmoto/moto | getmoto/moto | python | c59fee5d352e429309ddce7f8350ef70f2003593 | Bug: can't call SetIdentityMailFromDomain with Email address
Stack:
localstack 2.2.0 docker image
go 1.21.0
aws-sdk-go-v2
Code:
```
_, err = client.SetIdentityMailFromDomain(ctx, &ses.SetIdentityMailFromDomainInput{
Identity: aws.String("test@foo.com"),
BehaviorOnMXFailure: types.BehaviorOnMXFailureUseD... | Thanks for raising this with us @luoxiaojun1992 - will open a PR with a fix shortly.
Welcome to Moto! | diff --git a/moto/ses/models.py b/moto/ses/models.py
--- a/moto/ses/models.py
+++ b/moto/ses/models.py
@@ -165,7 +165,7 @@ def _is_verified_address(self, source: str) -> bool:
return True
if address in self.email_addresses:
return True
- _, host = address.split("@", 1)
+ ... | diff --git a/tests/test_ses/test_ses_boto3.py b/tests/test_ses/test_ses_boto3.py
--- a/tests/test_ses/test_ses_boto3.py
+++ b/tests/test_ses/test_ses_boto3.py
@@ -1472,6 +1472,22 @@ def test_set_identity_mail_from_domain():
assert actual_attributes["BehaviorOnMXFailure"] == behaviour_on_mx_failure
assert actu... | ["tests/test_ses/test_ses_boto3.py::test_set_identity_mail_from_domain"] | ["tests/test_ses/test_ses_boto3.py::test_create_configuration_set", "tests/test_ses/test_ses_boto3.py::test_send_email_when_verify_source", "tests/test_ses/test_ses_boto3.py::test_create_receipt_rule", "tests/test_ses/test_ses_boto3.py::test_get_identity_verification_attributes", "tests/test_ses/test_ses_boto3.py::test... | null | true | 2023-09-01 18:25:54 | 1 | 8 | 1 | 852 | 0 | 0.85 | 1 | 0.55 | 1 | 0.168667 | 81.831 | |
1,467 | swe_gym::train::2223 | swe_gym | train | 2,223 | Project-MONAI__MONAI-1690 | Project-MONAI/MONAI | project-monai/monai | python | 380f042dec9c55ba1a5ab241ae6b1a7b3e2b07fb | Pycharm can not find declarication to go
In `https://github.com/Project-MONAI/tutorials/tree/master/3d_segmentation/challenge_baseline`, Pycharm can not track the usage of some submodules.
To be specific, when I use "Ctrl+ LeftClick" to try to jump to the source file of `monai.engines.SupervisedEvaluator`, Pycharm sho... | Hi @wyli ,
Did you see this issue in your env before? Or it's known question?
Thanks.
this is a valid issue, pycharm doesn't know how to resolve the module imported with `optional_import`. for now I don't know how to fix it, let's keep this ticket open. I marked it contribution wanted
@wyli Why do we need `optio... | diff --git a/monai/__init__.py b/monai/__init__.py
--- a/monai/__init__.py
+++ b/monai/__init__.py
@@ -44,3 +44,19 @@
# load all modules, this will trigger all export decorations
load_submodules(sys.modules[__name__], True, exclude_pattern=excludes)
+
+__all__ = [
+ "apps",
+ "config",
+ "data",
+ "engi... | diff --git a/tests/test_module_list.py b/tests/test_module_list.py
new file mode 100644
--- /dev/null
+++ b/tests/test_module_list.py
@@ -0,0 +1,38 @@
+# Copyright 2020 - 2021 MONAI Consortium
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the L... | ["tests/test_module_list.py::TestAllImport::test_public_api"] | [] | null | true | 2021-03-04T14:13:45Z | 1 | 16 | 1 | 680 | 0 | 0.85 | 1 | 0.55 | 1 | 0.166667 | 81.825 | |
1,468 | swe_bench_verified::test::291 | swe_bench_verified | test | 291 | psf__requests-1724 | psf/requests | psf/requests | python | 1ba83c47ce7b177efe90d5f51f7760680f72eda0 | Unicode method names cause UnicodeDecodeError for some requests in Python 2.7.2
The following example works fine:
```
files = {u'file': open(u'/usr/bin/diff', u'rb')}
response = requests.request(method='POST', url=u'http://httpbin.org/post', files=files)
```
But the following example (using `method=u'POST'` instead o... | diff --git a/requests/sessions.py b/requests/sessions.py
--- a/requests/sessions.py
+++ b/requests/sessions.py
@@ -12,7 +12,7 @@
from collections import Mapping
from datetime import datetime
-from .compat import cookielib, OrderedDict, urljoin, urlparse, urlunparse
+from .compat import cookielib, OrderedDict, urljo... | diff --git a/test_requests.py b/test_requests.py
--- a/test_requests.py
+++ b/test_requests.py
@@ -433,6 +433,11 @@ def test_unicode_multipart_post_fieldnames(self):
prep = r.prepare()
assert b'name="stuff"' in prep.body
assert b'name="b\'stuff\'"' not in prep.body
+
+ def test_unicode... | ["test_requests.py::RequestsTestCase::test_DIGEST_AUTH_RETURNS_COOKIE", "test_requests.py::RequestsTestCase::test_DIGEST_HTTP_200_OK_GET", "test_requests.py::RequestsTestCase::test_different_encodings_dont_break_post", "test_requests.py::RequestsTestCase::test_generic_cookiejar_works", "test_requests.py::RequestsTestCa... | ["test_requests.py::RequestsTestCase::test_BASICAUTH_TUPLE_HTTP_200_OK_GET", "test_requests.py::RequestsTestCase::test_DIGESTAUTH_WRONG_HTTP_401_GET", "test_requests.py::RequestsTestCase::test_DIGEST_AUTH_SETS_SESSION_COOKIES", "test_requests.py::RequestsTestCase::test_DIGEST_STREAM", "test_requests.py::RequestsTestCas... | null | true | 2013-11-04T09:37:00Z | 1 | 5 | 6 | 7,474 | 0 | 1 | 1 | 0.65 | 0.8 | 0.516667 | 81.825 | ||
1,469 | swe_gym::train::624 | swe_gym | train | 624 | conan-io__conan-14177 | conan-io/conan | conan-io/conan | python | b43eb83956f053a47cc3897cfdd57b9da13a16e6 | [feature] Verbose option for apply_conandata_patches()
### What is your suggestion?
I'd like to have this...
```diff
-def apply_conandata_patches(conanfile):
+def apply_conandata_patches(conanfile, verbose=False):
```
...which does this when `verbose=True`...
```diff
======== Installing packages ========
zlib/1.2.13... | Hi @iskunk
Actually I think that listing by default the patches being applied should be the default behavior. This is an important information that should be in the logs by default, not as an opt-in, don't you think? Would you like to contribute that PR? Thanks for your offer to contribute this.
Sounds good. The `v... | diff --git a/conan/tools/files/patches.py b/conan/tools/files/patches.py
--- a/conan/tools/files/patches.py
+++ b/conan/tools/files/patches.py
@@ -39,7 +39,7 @@ def patch(conanfile, base_path=None, patch_file=None, patch_string=None, strip=0
:param kwargs: Extra parameters that can be added and will contribute to ... | diff --git a/conans/test/unittests/tools/files/test_patches.py b/conans/test/unittests/tools/files/test_patches.py
--- a/conans/test/unittests/tools/files/test_patches.py
+++ b/conans/test/unittests/tools/files/test_patches.py
@@ -121,7 +121,7 @@ def test_single_patch_description(mock_patch_ng):
conanfile = Co... | ["conans/test/unittests/tools/files/test_patches.py::test_multiple_with_version", "conans/test/unittests/tools/files/test_patches.py::test_single_patch_description", "conans/test/unittests/tools/files/test_patches.py::test_multiple_no_version"] | ["conans/test/unittests/tools/files/test_patches.py::test_single_patch_arguments", "conans/test/unittests/tools/files/test_patches.py::test_single_apply_fail", "conans/test/unittests/tools/files/test_patches.py::test_single_patch_type", "conans/test/unittests/tools/files/test_patches.py::test_single_patch_file_from_for... | null | true | 2023-06-27T18:55:10Z | 1 | 9 | 3 | 816 | 0 | 0.85 | 1 | 0.55 | 1 | 0.166 | 81.823 | |
1,470 | swe_bench_pro::test::360 | swe_bench_pro | test | 360 | instance_gravitational__teleport-bb69574e02bd62e5ccd3cebb25e1c992641afb2a | gravitational/teleport | gravitational/teleport | go | e9b7a25d6a5bb89eff86349d7e695afec04be7d0 | # Title: String literals are not accepted as valid expressions
## Description
Currently, a plain string value is not recognized as a valid expression and is rejected instead of being understood on its own, forcing extra special handling in the surrounding logic. | ## Requirements
- A value that is not written as a templated reference should still be accepted by `Variable` as a valid expression instead of being refused; the resulting expression should be classified under `LiteralNamespace` and should keep the original text unchanged, and no error should be surfaced for it.
- Whe... | diff --git a/lib/services/role.go b/lib/services/role.go
index 9ece3f2bdd455..b8d3532c19d72 100644
--- a/lib/services/role.go
+++ b/lib/services/role.go
@@ -385,12 +385,9 @@ func ApplyTraits(r Role, traits map[string][]string) Role {
// at least one value in case if return value is nil
func applyValueTraits(val strin... | diff --git a/lib/utils/parse/parse_test.go b/lib/utils/parse/parse_test.go
index bb09b27f2e2cd..dd458ed4c8e18 100644
--- a/lib/utils/parse/parse_test.go
+++ b/lib/utils/parse/parse_test.go
@@ -72,6 +72,11 @@ func TestRoleVariable(t *testing.T) {
in: `{{internal["foo"]}}`,
out: Expression{namespace: "intern... | ["TestRoleVariable", "TestRoleVariable/string_literal", "TestInterpolate", "TestInterpolate/literal_expression"] | [] | ghcr.io/scaleapi/swe-bench_pro-v2:instance_gravitational__teleport-bb69574e02bd62e5ccd3cebb25e1c992641afb2a | true | null | 3 | 46 | 4 | 263 | 0 | 0.95 | 1 | 0.55 | 1 | 0.197167 | 81.8165 | |
1,471 | swe_gym::train::431 | swe_gym | train | 431 | python__mypy-10508 | python/mypy | python/mypy | python | 58aef054dccb1b49acd1f6769ac2a18c2525dd63 | Mypy daemon suggests using "mypy --install-types" but it doesn't work
Here's what happened:
```
$ dmypy run -- t/t.py
Daemon started
t/t.py:1: error: Library stubs not installed for "requests" (or incompatible with Python 3.8)
t/t.py:1: note: Hint: "python3 -m pip install types-requests"
t/t.py:1: note: (or run "mypy -... | Experiencing the same problem within the VS code when running

any news on the workaround/solution?
@KantiCodes you're probably using a version of mypy that doesn't support the new option yet.
@Jelle... | diff --git a/mypy/build.py b/mypy/build.py
--- a/mypy/build.py
+++ b/mypy/build.py
@@ -2546,7 +2546,8 @@ def module_not_found(manager: BuildManager, line: int, caller_state: State,
blocker=True)
errors.raise_error()
else:
- msg, notes = reason.error_message_templates()
+ ... | diff --git a/test-data/unit/fine-grained-modules.test b/test-data/unit/fine-grained-modules.test
--- a/test-data/unit/fine-grained-modules.test
+++ b/test-data/unit/fine-grained-modules.test
@@ -2185,3 +2185,21 @@ x = 'x'
[out]
==
+
+[case testLibraryStubsNotInstalled]
+import a
+[file a.py]
+import waitress
+[file... | ["mypy/test/testfinegrained.py::FineGrainedSuite::testLibraryStubsNotInstalled"] | [] | null | true | 2021-05-19T13:04:38Z | 2 | 13 | 1 | 717 | 0 | 0.85 | 1 | 0.55 | 1 | 0.162833 | 81.8135 | |
1,472 | swe_gym::train::274 | swe_gym | train | 274 | getmoto__moto-4792 | getmoto/moto | getmoto/moto | python | 05f5bbc568b3e1b9de402d194b3e93a39b6b2c27 | Cloudfront - get_distribution() does not return same config passed to create_distribution()
When passing in a fully-formed Cloudfront Distribution Configuration, the response back from `create_distribution()` does not contain all of the information passed in. Calling `get_distribution()` with the Id passed back from `... | Hi @pll, the Cloudfront implementation only supports a subset of input parameters for now. I'll mark it as an enhancement to also implement the others.
Considering the sheer number of parameters available, this might be a staggered effort - are the `DistributionConfig.Comment` and `Aliases.Items` fields the only one... | diff --git a/moto/cloudfront/models.py b/moto/cloudfront/models.py
--- a/moto/cloudfront/models.py
+++ b/moto/cloudfront/models.py
@@ -100,6 +100,8 @@ def __init__(self, origin):
class DistributionConfig:
def __init__(self, config):
self.config = config
+ self.aliases = config.get("Aliases", {}).g... | diff --git a/tests/test_cloudfront/test_cloudfront_distributions.py b/tests/test_cloudfront/test_cloudfront_distributions.py
--- a/tests/test_cloudfront/test_cloudfront_distributions.py
+++ b/tests/test_cloudfront/test_cloudfront_distributions.py
@@ -121,7 +121,9 @@ def test_create_distribution_s3_minimum():
con... | ["tests/test_cloudfront/test_cloudfront_distributions.py::test_create_distribution_s3_minimum", "tests/test_cloudfront/test_cloudfront_distributions.py::test_create_distribution_with_additional_fields"] | ["tests/test_cloudfront/test_cloudfront_distributions.py::test_delete_distribution_random_etag", "tests/test_cloudfront/test_cloudfront_distributions.py::test_create_distribution_with_invalid_s3_bucket", "tests/test_cloudfront/test_cloudfront_distributions.py::test_create_distribution_with_mismatched_originid", "tests/... | null | true | 2022-01-25 17:13:47 | 2 | 5 | 2 | 1,827 | 0 | 0.85 | 1 | 0.7 | 0.8 | 0.321167 | 81.8135 | |
1,473 | swe_gym::train::1920 | swe_gym | train | 1,920 | facebookresearch__hydra-1551 | facebookresearch/hydra | facebookresearch/hydra | python | 36f125ab76dee432db7e2fc9af0bba5e450a4056 | [Bug] Cannot use experiment pattern when using overrides in main config file
# 🐛 Bug
When using any override in main config, e.g. for color logging or sweeper:
```yaml
defaults:
- override hydra/hydra_logging: colorlog
- override hydra/job_logging: colorlog
```
Then the experiment configs can't be loaded:
```... | Thanks for reporting.
For now, try this as a workaround:
```yaml
defaults:
- experiment: null
- override hydra/hydra_logging: colorlog
- override hydra/job_logging: colorlog
``` | diff --git a/hydra/_internal/defaults_list.py b/hydra/_internal/defaults_list.py
--- a/hydra/_internal/defaults_list.py
+++ b/hydra/_internal/defaults_list.py
@@ -464,7 +464,14 @@ def _create_defaults_tree_impl(
self_added = _validate_self(containing_node=parent, defaults=defaults_list)
if is_root_confi... | diff --git a/tests/defaults_list/test_defaults_tree.py b/tests/defaults_list/test_defaults_tree.py
--- a/tests/defaults_list/test_defaults_tree.py
+++ b/tests/defaults_list/test_defaults_tree.py
@@ -2161,6 +2161,28 @@ def test_none_config_with_hydra(
),
id="defaults_with_override_only",
... | ["tests/defaults_list/test_defaults_tree.py::test_defaults_with_overrides_only[defaults_with_override_only1]"] | ["tests/defaults_list/test_defaults_tree.py::test_deprecated_package_header_keywords[deprecated_headers/group_foo]", "tests/defaults_list/test_defaults_tree.py::test_interpolation[interpolation_with_nested_defaults_list_with_override]", "tests/defaults_list/test_defaults_tree.py::test_simple_defaults_tree_cases[empty]"... | null | true | 2021-04-13T19:28:49Z | 1 | 9 | 1 | 790 | 0 | 0.85 | 1 | 0.55 | 1 | 0.161667 | 81.81 | |
1,474 | swe_gym::train::407 | swe_gym | train | 407 | python__mypy-11717 | python/mypy | python/mypy | python | e0a89b75fbefc48bb82c924979a8e1c52d65818e | Type inference regression with "and" and strict optional disabled
This generates a false positive:
```py
# mypy: no-strict-optional
from typing import Tuple, Dict, Optional, NamedTuple
class C(NamedTuple):
x: int
t: Optional[C]
d: Dict[C, bytes]
x = t and d[t]
if x:
x.startswith(b'x') # Item "C" of "Union... | The problem is that `t and d[t]` is revealed as `Union[Tuple[builtins.int, fallback=ex.C], builtins.bytes*]`. But, it should be revealed as `Optional[bytes]`
I will try to solve it.
Let's test it: https://github.com/python/mypy/pull/11717 | diff --git a/mypy/checker.py b/mypy/checker.py
--- a/mypy/checker.py
+++ b/mypy/checker.py
@@ -4550,17 +4550,16 @@ def has_no_custom_eq_checks(t: Type) -> bool:
self._check_for_truthy_type(original_vartype, node)
vartype = try_expanding_sum_type_to_union(original_vartype, "builtins.bool")
- i... | diff --git a/test-data/unit/check-inference.test b/test-data/unit/check-inference.test
--- a/test-data/unit/check-inference.test
+++ b/test-data/unit/check-inference.test
@@ -3210,3 +3210,33 @@ def test(seq: List[Union[Iterable, Any]]) -> None:
k = [k]
reveal_type(k) # N: Revealed type is "bu... | ["mypy/test/testcheck.py::TypeCheckSuite::check-inference.test::testRegression11705_NoStrict"] | ["mypy/test/testcheck.py::TypeCheckSuite::check-inference.test::testRegression11705_Strict"] | null | true | 2021-12-11T21:39:40Z | 2 | 18 | 1 | 600 | 0 | 0.85 | 1 | 0.55 | 1 | 0.16 | 81.805 | |
1,475 | swe_bench_pro::test::547 | swe_bench_pro | test | 547 | instance_protonmail__webclients-c5a2089ca2bfe9aa1d85a664b8ad87ef843a1c9c | protonmail/webclients | protonmail/webclients | javascript | 83c2b47478a5224db61c6557ad326c2bbda18645 | ## Title: Repeated link fetch attempts call the API again after a prior failure
### Description
When `getLink` fails to fetch a link from the API for a given share and link ID, a subsequent `getLink` call for the same share and link ID sends another API request instead of reusing the outcome of the earlier attempt. E... | ## Requirements
- The `fetchLink` callback passed into `useLinkInner` must remember a rejected result for a given `shareId` and `linkId` pair when the failure reports that the link does not exist, is not permitted, or carries an invalid identifier.
- A failure that reports any other condition must not be remembered, an... | diff --git a/applications/drive/src/app/store/_links/useLink.ts b/applications/drive/src/app/store/_links/useLink.ts
index a049a1fd6c0..b0b5502ad5a 100644
--- a/applications/drive/src/app/store/_links/useLink.ts
+++ b/applications/drive/src/app/store/_links/useLink.ts
@@ -1,9 +1,12 @@
+import { useRef } from 'react';
+... | diff --git a/applications/drive/src/app/store/_links/useLink.test.ts b/applications/drive/src/app/store/_links/useLink.test.ts
index 42500cdcaf3..0e4e1a8403c 100644
--- a/applications/drive/src/app/store/_links/useLink.test.ts
+++ b/applications/drive/src/app/store/_links/useLink.test.ts
@@ -1,5 +1,6 @@
import { act, ... | ["src/app/store/_links/useLink.test.ts | useLink skips failing fetch if already attempted before", "src/app/store/_links/useLink.test.ts | useLink skips load of already cached thumbnail", "src/app/store/_links/useLink.test.ts | useLink loads link thumbnail using cached link thumbnail info", "src/app/store/_links/useLin... | ["src/app/store/_links/useLink.test.ts | useLink returns decrypted version from the cache", "src/app/store/_links/useLink.test.ts | useLink decrypts when missing decrypted version in the cache", "src/app/store/_links/useLink.test.ts | useLink decrypts link with parent link", "src/app/store/_links/useLink.test.ts | useL... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_protonmail__webclients-c5a2089ca2bfe9aa1d85a664b8ad87ef843a1c9c | true | null | 1 | 33 | 6 | 488 | 0 | 0.95 | 1 | 0.55 | 1 | 0.191333 | 81.799 | |
1,476 | swe_gym::train::459 | swe_gym | train | 459 | python__mypy-12741 | python/mypy | python/mypy | python | 4f07c79aea0fef61ab649d6acedf01186f1054eb | Crash on definition of TypedDict method
I'm not sure if this is a bug or a feature, but I was considering migrating from NamedTuple to TypedDict, and ran into a problem where **methods** don't seem to be supported on TypedDicts.
```python
class User(TypedDict):
id: str
firstName: str
lastName: str
pass... | Also, when used as a var-keyword param, TypedDict doesn't work as I'd expect it to:
```python
class LoginParams(TypedDict):
emailAddress: str
password: str
async def resolve_login(
root: None, info: GraphQLResolveInfo, ctx: Context, **params: LoginParams
) -> typing.Optional[UserType]:
user ... | diff --git a/mypy/types.py b/mypy/types.py
--- a/mypy/types.py
+++ b/mypy/types.py
@@ -14,7 +14,7 @@
import mypy.nodes
from mypy.state import state
from mypy.nodes import (
- INVARIANT, SymbolNode, FuncDef,
+ INVARIANT, SymbolNode, FuncDef, FakeInfo,
ArgKind, ARG_POS, ARG_STAR, ARG_STAR2,
)
from mypy.ut... | diff --git a/test-data/unit/check-typeddict.test b/test-data/unit/check-typeddict.test
--- a/test-data/unit/check-typeddict.test
+++ b/test-data/unit/check-typeddict.test
@@ -221,6 +221,17 @@ reveal_type(d) # N: Revealed type is "TypedDict('__main__.D', {'y': builtins.in
[builtins fixtures/dict.pyi]
[typing fixtures... | ["mypy/test/testcheck.py::TypeCheckSuite::check-typeddict.test::testTypedDictWithClassmethodAlternativeConstructorDoesNotCrash"] | ["mypy/test/testcheck.py::TypeCheckSuite::check-typeddict.test::testCanCreateTypedDictTypeWithUnderscoreItemName"] | null | true | 2022-05-07T11:36:59Z | 1 | 9 | 1 | 763 | 0 | 0.85 | 1 | 0.55 | 1 | 0.157167 | 81.7965 | |
1,477 | swe_gym::train::1032 | swe_gym | train | 1,032 | dask__dask-9148 | dask/dask | dask/dask | python | 0b876af35b5e49e1f9f0084db4b4d63d9d0ce432 | normalize_token does not raise warning for function with non-deterministic hash
```
import dask.config
from dask.base import tokenize
a,b = (
lambda a: a,
lambda a: a,
)
with dask.config.set({"tokenize.ensure-deterministic":True}):
print(tokenize(a)==tokenize(b))
str(a),str(b)
```
Gives:
```
False
('<functi... | @LunarLanding Welcome to Dask, and thanks for reporting!
I took a look at this with @ian-r-rose, and this seems to be because cloudpickle isn't always deterministic: https://github.com/cloudpipe/cloudpickle/issues/385
I agree we can raise a warning/runtime error here. I can open a PR. :)
Reproducer:
```python
... | diff --git a/dask/base.py b/dask/base.py
--- a/dask/base.py
+++ b/dask/base.py
@@ -1061,12 +1061,19 @@ def _normalize_function(func: Callable) -> tuple | str | bytes:
return result
except Exception:
pass
- try:
- import cloudpickle
+ if not config.get("tok... | diff --git a/dask/tests/test_base.py b/dask/tests/test_base.py
--- a/dask/tests/test_base.py
+++ b/dask/tests/test_base.py
@@ -255,6 +255,16 @@ def test_tokenize_object():
normalize_token(o)
+def test_tokenize_function_cloudpickle():
+ a, b = (lambda x: x, lambda x: x)
+ # No error by default
+ ... | ["dask/tests/test_base.py::test_tokenize_function_cloudpickle"] | ["dask/tests/test_base.py::test_normalize_function_dataclass_field_no_repr", "dask/tests/test_base.py::test_tokenize_object", "dask/tests/test_base.py::test_tokenize_datetime_date", "dask/tests/test_base.py::test_tokenize_numpy_array_on_object_dtype", "dask/tests/test_base.py::test_custom_collection", "dask/tests/test_... | null | true | 2022-05-31T20:15:02Z | 1 | 17 | 1 | 584 | 0 | 0.85 | 1 | 0.55 | 1 | 0.154 | 81.787 | |
1,478 | swe_bench_pro::test::212 | swe_bench_pro | test | 212 | instance_flipt-io__flipt-aebaecd026f752b187f11328b0d464761b15d2ab | flipt-io/flipt | flipt-io/flipt | go | 1d550f0c0d693844b6f4b44fd7859254ef3569c0 | **Title:** Git backend fails to poll when a reference no longer exists
**Bug Description:**
During regular polling intervals (30 seconds), Flipt’s Git backend encounters failures when previously used remote references have been deleted. The cache still contains entries for those removed references and attempts to proc... | ## Requirements
- A public method `Delete(ref string) error` should exist on `SnapshotCache` in `internal/storage/fs/cache.go` and be invokable by tests.
- The cache should maintain a notion of **fixed references** provided at cache construction time; this set includes the repository's configured "main" reference from... | diff --git a/go.work.sum b/go.work.sum
index 083def5149..1398947131 100644
--- a/go.work.sum
+++ b/go.work.sum
@@ -51,55 +51,69 @@ cloud.google.com/go v0.112.1/go.mod h1:+Vbu+Y1UU+I1rjmzeMOb/8RfkKJK2Gyxi1X6jJCZL
cloud.google.com/go v0.112.2/go.mod h1:iEqjp//KquGIJV/m+Pk3xecgKNhV+ry+vVTsy4TbDms=
cloud.google.com/go v0... | diff --git a/internal/storage/fs/cache_test.go b/internal/storage/fs/cache_test.go
index ddb1659293..4fa8abc96c 100644
--- a/internal/storage/fs/cache_test.go
+++ b/internal/storage/fs/cache_test.go
@@ -222,6 +222,35 @@ func Test_SnapshotCache_Concurrently(t *testing.T) {
assert.GreaterOrEqual(t, builder.builds[revis... | ["Test_SnapshotCache", "Test_SnapshotCache_Concurrently", "Test_SnapshotCache_Delete", "TestSnapshotFromFS_Invalid", "TestFS_Empty_Features_File", "TestFS_YAML_Stream"] | [] | ghcr.io/scaleapi/swe-bench_pro-v2:instance_flipt-io__flipt-aebaecd026f752b187f11328b0d464761b15d2ab | true | null | 3 | 243 | 6 | 1,443 | 0 | 0.95 | 1 | 0.7 | 0.75 | 0.7405 | 81.784 | |
1,479 | swe_gym::train::243 | swe_gym | train | 243 | getmoto__moto-5213 | getmoto/moto | getmoto/moto | python | 8a8eaff5476a7e80b10c9255eb23a4c094337a71 | Lambda KeyError: 'Handler'
# Background
The following works in "real" AWS, but throws an error when using moto.
I expect this to just pass and the lambda be created, but instead an exception is thrown:
```python
from moto import mock_lambda
import boto3
@mock_lambda
def make_lambda():
lambda_client = boto3.client... | Hi @lkev, welcome to Moto, and thanks for raising this! We only support PackageType=ZIP at the moment - will mark it as an enhancement to also support Image.
Do you also need to invoke the function afterwards, or do you only want to create it?
Cheers @bblommers.
Nope - don't need to invoke the function at the mom... | diff --git a/moto/awslambda/models.py b/moto/awslambda/models.py
--- a/moto/awslambda/models.py
+++ b/moto/awslambda/models.py
@@ -380,9 +380,9 @@ def __init__(self, spec, region, version=1):
self.region = region
self.code = spec["Code"]
self.function_name = spec["FunctionName"]
- self... | diff --git a/tests/test_awslambda/test_lambda.py b/tests/test_awslambda/test_lambda.py
--- a/tests/test_awslambda/test_lambda.py
+++ b/tests/test_awslambda/test_lambda.py
@@ -213,6 +213,37 @@ def test_create_function__with_tracingmode(tracing_mode):
result.should.have.key("TracingConfig").should.equal({"Mode": out... | ["tests/test_awslambda/test_lambda.py::test_create_function_from_image"] | ["tests/test_awslambda/test_lambda.py::test_publish_version_unknown_function[bad_function_name]", "tests/test_awslambda/test_lambda.py::test_create_function_from_zipfile", "tests/test_awslambda/test_lambda.py::test_create_function_with_already_exists", "tests/test_awslambda/test_lambda.py::test_get_function_configurati... | null | true | 2022-06-10 12:53:34 | 1 | 38 | 1 | 10,888 | 0 | 0.85 | 1 | 0.5 | 1 | 0.626667 | 81.78 | |
1,480 | swe_gym::train::566 | swe_gym | train | 566 | python__mypy-10053 | python/mypy | python/mypy | python | 11d4fb25a8af7a3eff5f36328a11d68e82d33017 | Use double quotes in error messages for more consistent colors
Some messages use double quotes for quoting while other use single quotes. Maybe we should move to double quotes since the colored output only highlights double quoted strings.
Examples where this happens:
```
t.py:14: note: Revealed type is 'builtins.lis... | Some more examples:
```
Cannot redefine 'a' as a NewType
Cannot redefine 'T' as a type variable
Unsupported type Type["Tuple[int]"] # this one is especially weird
Cannot determine type of 'blah'
Cannot determine type of 'foo' in base class 'B'
Cannot instantiate abstract class 'A'
TypedDict key 'x' cannot be ... | diff --git a/mypy/messages.py b/mypy/messages.py
--- a/mypy/messages.py
+++ b/mypy/messages.py
@@ -687,7 +687,7 @@ def deleted_as_rvalue(self, typ: DeletedType, context: Context) -> None:
if typ.source is None:
s = ""
else:
- s = " '{}'".format(typ.source)
+ s = ' "{... | diff --git a/test-data/unit/check-attr.test b/test-data/unit/check-attr.test
--- a/test-data/unit/check-attr.test
+++ b/test-data/unit/check-attr.test
@@ -76,10 +76,10 @@ A(1, [2], '3', 4, 5) # E: Too many arguments for "A"
import attr
@attr.s
class A:
- a = attr.ib() # E: Need type annotation for 'a'
- _b =... | ["mypy/test/testcheck.py::TypeCheckSuite::testLocalPartialTypesWithGlobalInitializedToEmptyDict3", "mypy/test/testcheck.py::TypeCheckSuite::testEmptyCollectionAssignedToVariableTwiceIncremental", "mypy/test/testcheck.py::TypeCheckSuite::testInferListInitializedToEmptyAndReadBeforeAppendInFunction", "mypy/test/testfineg... | ["mypy/test/testcheck.py::TypeCheckSuite::testDelStatementWithAssignmentClass", "mypy/test/testcheck.py::TypeCheckSuite::testInferAttributeInitializedToEmptyAndAssignedItem", "mypy/test/testcheck.py::TypeCheckSuite::testPartialTypeErrorSpecialCase3", "mypy/test/testfinegrainedcache.py::FineGrainedCacheSuite::testSkippe... | null | true | 2021-02-09T16:36:04Z | 1 | 26 | 55 | 384 | 0 | 0.85 | 1 | 0.55 | 1 | 0.150667 | 81.777 | |
1,481 | swe_gym::train::735 | swe_gym | train | 735 | iterative__dvc-4166 | iterative/dvc | iterative/dvc | python | 520e01f11305aba1994df354adef86e6d90180de | .dvcignore is broken on negation when blacklisting all
## Bug Report
### Please provide information about your setup
I am not sure how far this extends to, but a lot of trials for `.dvcignore` failed when I blacklisted all and tried to whitelist some:
```
*
!scripts
```
```
*
!/scripts
```
```
/*
!/scripts/
```
`... | CC @pared is this expected?
Considering that we have been designing `.dvcignore` to comply with `.gitignore`, I will refer to original:
It seems to me that we have some disrepancies in behaviour between `git` and `dvc`. I prepared a script to illustrate that:
```
#!/bin/bash
rm -rf repo
mkdir repo
pushd repo
... | diff --git a/dvc/ignore.py b/dvc/ignore.py
--- a/dvc/ignore.py
+++ b/dvc/ignore.py
@@ -44,11 +44,11 @@ def __init__(self, ignore_file_path, tree):
def __call__(self, root, dirs, files):
files = [f for f in files if not self.matches(root, f)]
- dirs = [d for d in dirs if not self.matches(root, d)]... | diff --git a/tests/func/test_ignore.py b/tests/func/test_ignore.py
--- a/tests/func/test_ignore.py
+++ b/tests/func/test_ignore.py
@@ -173,3 +173,66 @@ def test_ignore_blank_line(tmp_dir, dvc):
tmp_dir.gen(DvcIgnore.DVCIGNORE_FILE, "foo\n\ndir/ignored")
assert _files_set("dir", dvc.tree) == {"dir/other"}
+
... | ["tests/func/test_ignore.py::test_ignore_file_in_parent_path[data_struct2-pattern_list2-result_set2]"] | ["tests/unit/test_ignore.py::test_match_ignore_from_file[path/to_ignore.txt-patterns36-False]", "tests/unit/test_ignore.py::test_match_ignore_from_file[data/file-patterns12-False]", "tests/unit/test_ignore.py::test_match_ignore_from_file[/full/path/to/ignore/file/to_ignore-patterns15-True]", "tests/unit/test_ignore.py:... | null | true | 2020-07-04T07:07:26Z | 1 | 20 | 1 | 495 | 0 | 0.85 | 1 | 0.55 | 1 | 0.149167 | 81.7725 | |
1,482 | swe_gym::train::862 | swe_gym | train | 862 | iterative__dvc-9395 | iterative/dvc | iterative/dvc | python | c75a5583b3840ba90a8e800a0f42c1cb120916db | Make that `dvc repro --pull` pulls all missing files.
According to help for `dvc repro`:
```
--pull Try automatically pulling missing cache for outputs
restored from the run-cache.
```
and that's what it does. Pulls missing files that are **outputs restored from the run-cache**.... | Hi @peper0 !
It is the plan :slightly_smiling_face: For now it is limited to run-cache, but we'll add support for data sources soon. Stay tuned! :slightly_smiling_face:
Comments from https://github.com/iterative/dvc/issues/4871:
> Currently the `--pull` flag have no impact when used together with the `--downstre... | diff --git a/dvc/repo/reproduce.py b/dvc/repo/reproduce.py
--- a/dvc/repo/reproduce.py
+++ b/dvc/repo/reproduce.py
@@ -76,7 +76,7 @@ def _track_stage(stage: "Stage") -> None:
@locked
@scm_context
-def reproduce( # noqa: C901
+def reproduce( # noqa: C901, PLR0912
self: "Repo",
targets=None,
recursiv... | diff --git a/tests/func/test_repro_multistage.py b/tests/func/test_repro_multistage.py
--- a/tests/func/test_repro_multistage.py
+++ b/tests/func/test_repro_multistage.py
@@ -10,6 +10,7 @@
from dvc.exceptions import CyclicGraphError, ReproductionError
from dvc.stage import PipelineStage
from dvc.stage.exceptions imp... | ["tests/func/test_run_cache.py::test_restore_pull", "tests/func/test_repro_multistage.py::test_repro_pulls_mising_data_source"] | ["tests/func/test_repro_multistage.py::test_repro_when_new_out_overlaps_others_stage_outs", "tests/func/test_run_cache.py::test_outs_no_cache_deactivate_run_cache[metrics_no_cache-True]", "tests/func/test_repro_multistage.py::test_repro_frozen", "tests/func/test_run_cache.py::test_memory_for_multiple_runs_of_same_stage... | null | true | 2023-05-03T12:59:26Z | 1 | 10 | 2 | 690 | 0 | 0.85 | 1 | 0.55 | 1 | 0.148333 | 81.77 | |
1,483 | swe_gym::train::1947 | swe_gym | train | 1,947 | bokeh__bokeh-13198 | bokeh/bokeh | bokeh/bokeh | python | 47e69a5288727fbfc7b04cb72b32c78bd298536c | [BUG] select(CategoricalColorMapper) returns an empty array
### Software versions
Python version : 3.8.16 | packaged by conda-forge | (default, Feb 1 2023, 16:01:55)
IPython version : 8.11.0
Tornado version : 6.2
Bokeh version : 3.1.0
BokehJS static path : /home/[user]/git/chartify/.conda/lib/... | @mattpap it seems possible that when `Field` was added, that `select` etc were not taught how to handle them, since in the above code:
```python
In [17]: p.renderers[0].glyph.fill_color
Out[17]: Field(field='species', transform=CategoricalColorMapper(id='p1049', ...), units=Unspecified)
```
tentatively triaged... | diff --git a/src/bokeh/model/util.py b/src/bokeh/model/util.py
--- a/src/bokeh/model/util.py
+++ b/src/bokeh/model/util.py
@@ -25,6 +25,7 @@
# Bokeh imports
from ..core.has_props import HasProps, Qualified
+from ..util.dataclasses import entries, is_dataclass
if TYPE_CHECKING:
from ..core.types import ID
@@... | diff --git a/tests/unit/bokeh/model/test_util_model.py b/tests/unit/bokeh/model/test_util_model.py
--- a/tests/unit/bokeh/model/test_util_model.py
+++ b/tests/unit/bokeh/model/test_util_model.py
@@ -16,8 +16,22 @@
# Imports
#-----------------------------------------------------------------------------
+# Standard l... | ["tests/unit/bokeh/model/test_util_model.py::test_collect_models"] | ["tests/unit/bokeh/model/test_util_model.py::TestHasDocumentRef::test_init", "tests/unit/bokeh/model/test_util_model.py::TestHasDocumentRef::test_setter", "tests/unit/bokeh/model/test_util_model.py::Test_visit_value_and_its_immediate_references::test_scalar[float]", "tests/unit/bokeh/model/test_util_model.py::Test_visi... | null | true | 2023-06-09T19:12:58Z | 1 | 4 | 1 | 1,756 | 0 | 0.85 | 1 | 0.7 | 0.8 | 0.306 | 81.768 | |
1,484 | swe_gym::train::744 | swe_gym | train | 744 | iterative__dvc-3715 | iterative/dvc | iterative/dvc | python | 22c60dd6083a53b9cccb8abb569fc3f155b15247 | dvc remote default accepts anything
```
dvc remote add -d test test
dvc remote default
# prints test
dvc remote default anything
dvc remote default
# prints anything
```
Should indicate an error if the default remote is not in the list
**Please provide information about your setup**
DVC version: 0.87.0
Python version:... | I'm looking into this issue , but got some difficulty.
Currently, the DVC would take a validation on every change of the configuation. There are two types of validation, one is of data type ( core.no_scm must be boolen, timeout and port of a ssh mus be int) another is of logic ( like #3470 core.remote must be in ... | diff --git a/dvc/command/remote.py b/dvc/command/remote.py
--- a/dvc/command/remote.py
+++ b/dvc/command/remote.py
@@ -85,7 +85,18 @@ def run(self):
if self.args.unset:
conf["core"].pop("remote", None)
else:
- conf["core"]["remote"] = self.args.n... | diff --git a/tests/func/test_remote.py b/tests/func/test_remote.py
--- a/tests/func/test_remote.py
+++ b/tests/func/test_remote.py
@@ -121,6 +121,7 @@ def test(self):
def test_show_default(dvc, capsys):
+ assert main(["remote", "add", "foo", "s3://bucket/name"]) == 0
assert main(["remote", "default", "foo"... | ["tests/func/test_remote.py::test_remote_modify_default"] | ["tests/func/test_remote.py::test_dir_checksum_should_be_key_order_agnostic", "tests/func/test_remote.py::TestRemote::test_relative_path", "tests/func/test_remote.py::TestRemoteDefault::test", "tests/func/test_remote.py::test_remote_modify_validation", "tests/func/test_remote.py::TestRemote::test_referencing_other_remo... | null | true | 2020-05-01T07:49:58Z | 2 | 19 | 1 | 492 | 0 | 0.85 | 1 | 0.55 | 1 | 0.145333 | 81.761 | |
1,485 | swe_gym::train::767 | swe_gym | train | 767 | iterative__dvc-9071 | iterative/dvc | iterative/dvc | python | 37761a2627c1e41c35c03e55cd5284d2f4f1386d | dvc checkout --ignore-missing; build workspace even if some data is missing in local cache
Currently 'dvc checkout' will fail with an error if the local cache does not contain all of the data specified by the repository and it will not construct any workspace directories.
For situations when having a partial subset ... | Worth nothing that we likely need this same behavior internally for checkpoint experiments, so it would not be too difficult to just add the `dvc checkout` command option once the checkpoints work is completed.
@pmrowla Now that checkpoint experiments have been implemented for awhile, what is the level of effort to add... | diff --git a/dvc/commands/data_sync.py b/dvc/commands/data_sync.py
--- a/dvc/commands/data_sync.py
+++ b/dvc/commands/data_sync.py
@@ -40,6 +40,7 @@ def run(self):
recursive=self.args.recursive,
run_cache=self.args.run_cache,
glob=self.args.glob,
+ allow... | diff --git a/tests/func/test_data_cloud.py b/tests/func/test_data_cloud.py
--- a/tests/func/test_data_cloud.py
+++ b/tests/func/test_data_cloud.py
@@ -7,6 +7,7 @@
import dvc_data
from dvc.cli import main
+from dvc.exceptions import CheckoutError
from dvc.external_repo import clean_repos
from dvc.stage.exceptions ... | ["tests/unit/command/test_data_sync.py::test_pull", "tests/func/test_data_cloud.py::test_pull_allow_missing"] | ["tests/func/test_data_cloud.py::test_push_stats[fs0-2", "tests/func/test_data_cloud.py::test_target_remote", "tests/func/test_data_cloud.py::test_hash_recalculation", "tests/func/test_data_cloud.py::test_warn_on_outdated_stage", "tests/func/test_data_cloud.py::test_push_pull_fetch_pipeline_stages", "tests/func/test_da... | null | true | 2023-02-23T10:54:38Z | 2 | 9 | 2 | 671 | 0 | 0.85 | 1 | 0.55 | 1 | 0.141833 | 81.7505 | |
1,486 | swe_gym::train::699 | swe_gym | train | 699 | iterative__dvc-4075 | iterative/dvc | iterative/dvc | python | a2f1367a9a75849ef6ad7ee23a5bacc18580f102 | Implement `--no-exec` option for `import-url` command
`dvc import-url` creates new `.dvc` file, just as `dvc run`. Sometimes files which would be imported are already present locally and it's quite inconvenient that they should be downloaded again in order to create a pipeline step.
Because of that it would be great t... | Context: https://discordapp.com/channels/485586884165107732/485596304961962003/690194007816798243
taking a look | diff --git a/dvc/command/imp_url.py b/dvc/command/imp_url.py
--- a/dvc/command/imp_url.py
+++ b/dvc/command/imp_url.py
@@ -12,7 +12,10 @@ class CmdImportUrl(CmdBase):
def run(self):
try:
self.repo.imp_url(
- self.args.url, out=self.args.out, fname=self.args.file
+ ... | diff --git a/tests/func/test_import_url.py b/tests/func/test_import_url.py
--- a/tests/func/test_import_url.py
+++ b/tests/func/test_import_url.py
@@ -103,3 +103,12 @@ def test_import_stage_accompanies_target(tmp_dir, dvc, erepo_dir):
def test_import_url_nonexistent(dvc, erepo_dir):
with pytest.raises(DependencyD... | ["tests/unit/command/test_imp_url.py::test_import_url_no_exec", "tests/unit/command/test_imp_url.py::test_import_url"] | ["tests/unit/command/test_imp_url.py::test_failed_import_url", "tests/func/test_import_url.py::TestCmdImport::test_unsupported"] | null | true | 2020-06-20T02:43:19Z | 2 | 20 | 2 | 440 | 0 | 0.85 | 1 | 0.55 | 1 | 0.14 | 81.745 | |
1,487 | swe_bench_promax::test::143 | swe_bench_promax | test | 143 | angular__angular-64903 | angular/angular | angular/angular | typescript | 194b41199b3c98ce2282603aaa889de63555525c | When working with Angular's reactive forms API, developers frequently encounter scenarios where form structures—particularly nested form groups representing object-shaped data—need to be dynamically inspected or iterated. A common pattern involves using standard JavaScript utilities like `Object.keys()`, `Object.entrie... | diff --git a/goldens/public-api/forms/signals/index.api.md b/goldens/public-api/forms/signals/index.api.md
--- a/goldens/public-api/forms/signals/index.api.md
+++ b/goldens/public-api/forms/signals/index.api.md
@@ -487,6 +487,8 @@ export class StandardSchemaValidationError extends _NgValidationError {
// @public
expo... | diff --git a/packages/forms/signals/test/node/field_proxy.spec.ts b/packages/forms/signals/test/node/field_proxy.spec.ts
--- a/packages/forms/signals/test/node/field_proxy.spec.ts
+++ b/packages/forms/signals/test/node/field_proxy.spec.ts
@@ -31,4 +31,64 @@ describe('FieldTree proxy', () => {
// @ts-expect-error
... | null | null | key4127/refactor-dockerhub:angular__angular-64903 | true | 1762444288 | 3 | 36 | null | 2,215 | 0 | 0.9 | 1 | 0.55 | 1 | 0.489167 | 81.7425 | ||
1,488 | swe_gym::train::808 | swe_gym | train | 808 | iterative__dvc-4872 | iterative/dvc | iterative/dvc | python | eeba5677740508285ef5f9e09b4c869bdce691bc | Pushing artifacts via WebDAV results in a 411 Length Required response
## Bug Report
I am trying to connect to a remote via WebDAV. I can correctly setup user and password along with the url, but when I try to push the artifacts I get a ```411 Length Required``` response. How can I solve the missing header problem?
#... | Hi @LucaButera
Please show full log for `dvc push -v`.
```
2020-10-27 18:30:54,485 DEBUG: Check for update is enabled.
2020-10-27 18:30:54,487 DEBUG: fetched: [(3,)]
2020-10-27 18:30:54,487 DEBUG: Checking if stage 'as' is in 'dvc.yaml'
2020-10-27 18:30:54,494 DEBUG: Assuming '/Users/lucabutera/bolt_datasets/.d... | diff --git a/dvc/config.py b/dvc/config.py
--- a/dvc/config.py
+++ b/dvc/config.py
@@ -103,6 +103,7 @@ class RelPath(str):
REMOTE_COMMON = {
"url": str,
"checksum_jobs": All(Coerce(int), Range(1)),
+ "jobs": All(Coerce(int), Range(1)),
Optional("no_traverse"): Bool, # obsoleted
"verify": Bool,
... | diff --git a/tests/unit/remote/test_remote.py b/tests/unit/remote/test_remote.py
--- a/tests/unit/remote/test_remote.py
+++ b/tests/unit/remote/test_remote.py
@@ -16,6 +16,17 @@ def test_remote_with_hash_jobs(dvc):
assert tree.hash_jobs == 100
+def test_remote_with_jobs(dvc):
+ dvc.config["remote"]["with_jo... | ["tests/unit/remote/test_remote.py::test_remote_with_jobs"] | ["tests/unit/remote/test_remote.py::test_remote_without_hash_jobs_default", "tests/unit/remote/test_remote.py::test_makedirs_not_create_for_top_level_path[GSTree]", "tests/unit/remote/test_remote.py::test_remote_without_hash_jobs", "tests/unit/remote/test_remote.py::test_makedirs_not_create_for_top_level_path[S3Tree]",... | null | true | 2020-11-10T15:57:06Z | 2 | 11 | 1 | 612 | 0 | 0.85 | 1 | 0.55 | 1 | 0.138667 | 81.741 | |
1,489 | swe_gym::train::760 | swe_gym | train | 760 | iterative__dvc-4817 | iterative/dvc | iterative/dvc | python | 92752e039209680a510e930eb7dc7c1953b28c6c | import: support --no-exec
What's the point of `import-url --no-exec`?
Our [docs](https://dvc.org/doc/command-reference/import-url#options) read "E.g. if the file or directory already exist it can be used to skip download. dvc commit <out>.dvc should be used to calculate the URL and data hash, update the .dvc files, an... | Please transfer to dvc.org if this is mainly a matter of re-explaining the option's motivation. But it seems inconsistent that `import` doesn't also have it so we could keep this one as a request to add it there.
@jorgeorpinel, a contributor asked for it, here's the motivation: #3513.
I see. Shouldn't it be in `import`... | diff --git a/dvc/command/imp.py b/dvc/command/imp.py
--- a/dvc/command/imp.py
+++ b/dvc/command/imp.py
@@ -17,6 +17,7 @@ def run(self):
out=self.args.out,
fname=self.args.file,
rev=self.args.rev,
+ no_exec=self.args.no_exec,
)
excep... | diff --git a/tests/func/test_import.py b/tests/func/test_import.py
--- a/tests/func/test_import.py
+++ b/tests/func/test_import.py
@@ -465,3 +465,13 @@ def test_try_import_complete_repo(tmp_dir, dvc, erepo_dir):
with pytest.raises(IsADVCRepoError) as exc_info:
dvc.imp(os.fspath(erepo_dir), os.curdir, out=... | ["tests/unit/command/test_imp.py::test_import", "tests/unit/command/test_imp.py::test_import_no_exec"] | [] | null | true | 2020-10-31T17:33:28Z | 2 | 13 | 2 | 567 | 0 | 0.85 | 1 | 0.55 | 1 | 0.137833 | 81.7385 | |
1,490 | swe_gym::train::48 | swe_gym | train | 48 | getmoto__moto-5343 | getmoto/moto | getmoto/moto | python | c0ce38dba888af7abccec7edec629747f5e15e21 | Jinja2 template name must be string or Template type
Moto [creates template names based on the Python memory `id()`](https://github.com/spulec/moto/blob/c0ce38dba888af7abccec7edec629747f5e15e21/moto/core/responses.py#L112), causing them to be set as integers. Newer versions of [Jinja specify that the name must be a str... | Thanks for raising this and linking the docs @TimothyLoyer - marking it as a bug. | diff --git a/moto/core/responses.py b/moto/core/responses.py
--- a/moto/core/responses.py
+++ b/moto/core/responses.py
@@ -108,8 +108,17 @@ def environment(self):
def contains_template(self, template_id):
return self.environment.loader.contains(template_id)
+ @classmethod
+ def _make_template_id(c... | diff --git a/tests/test_core/test_responses.py b/tests/test_core/test_responses.py
--- a/tests/test_core/test_responses.py
+++ b/tests/test_core/test_responses.py
@@ -184,20 +184,24 @@ class ResponseB(BaseResponse):
source_1 = "template"
source_2 = "amother template"
- assert not resp_a.contains_template... | ["tests/test_core/test_responses.py::test_response_environment_preserved_by_type"] | ["tests/test_core/test_responses.py::test_get_dict_list_params", "tests/test_core/test_responses.py::test_get_params", "tests/test_core/test_responses.py::test_parse_qs_unicode_decode_error"] | null | true | 2022-07-29 15:35:23 | 1 | 11 | 1 | 607 | 0 | 0.85 | 1 | 0.55 | 1 | 0.137833 | 81.7385 | |
1,491 | swe_gym::train::1105 | swe_gym | train | 1,105 | pydantic__pydantic-9450 | pydantic/pydantic | pydantic/pydantic | python | 7bdfac37dae746d6ee81cfec256657351074ff79 | Cannot use `str` as argument to PlainSerializer
### Initial Checks
- [X] I confirm that I'm using Pydantic V2
### Description
[`PlainSerializer`](https://docs.pydantic.dev/2.7/api/functional_serializers/#pydantic.functional_serializers.PlainSerializer) does not accept the built-in object [`str`](https://docs.python.... | Unlike `float`, `str` (and a bunch of builtin types) doesn't have a `__text_signature__` attribute. I'll look into this issue soon | diff --git a/pydantic/_internal/_decorators.py b/pydantic/_internal/_decorators.py
--- a/pydantic/_internal/_decorators.py
+++ b/pydantic/_internal/_decorators.py
@@ -593,7 +593,12 @@ def inspect_annotated_serializer(serializer: Callable[..., Any], mode: Literal['
Returns:
info_arg
"""
- sig = sig... | diff --git a/tests/test_decorators.py b/tests/test_decorators.py
--- a/tests/test_decorators.py
+++ b/tests/test_decorators.py
@@ -1,3 +1,5 @@
+import platform
+
import pytest
from pydantic import PydanticUserError
@@ -41,8 +43,40 @@ def validator3(arg1, arg2, arg3):
assert e.value.code == 'validator-signature... | ["tests/test_decorators.py::test_inspect_annotated_serializer[str-plain-False]", "tests/test_serialize.py::test_plain_serializer_with_std_type", "tests/test_decorators.py::test_inspect_annotated_serializer[int-plain-False]"] | ["tests/test_serialize.py::test_serialize_decorator_self_no_info", "tests/test_serialize.py::test_serialize_decorator_json", "tests/test_decorators.py::test_inspect_validator_error_wrap", "tests/test_serialize.py::test_forward_ref_for_serializers[plain-True]", "tests/test_serialize.py::test_serialize_decorator_unless_n... | null | true | 2024-05-17T15:27:52Z | 2 | 12 | 3 | 5,718 | 0.125 | 0.85 | 1 | 0.77 | 1 | 0.54 | 81.725438 | |
1,492 | swe_gym::train::357 | swe_gym | train | 357 | python__mypy-11585 | python/mypy | python/mypy | python | 4996d571272adde83a3de2689c0147ca1be23f2c | generic mutable class attributes introduce a vent in the type system
```py
from typing import Generic, TypeVar
T = TypeVar("T")
class A(Generic[T]):
shared_attr: list[T] = []
a1 = A[str]()
a1.shared_attr.append("AMONGUS")
a2 = A[int]()
a2.shared_attr.append(1)
value = a2.class_attr[0]
reveal_type(value) # rev... | Thanks.
I'm guessing part of this is the legacy of pre-PEP 526 days, but it looks like we also don't reject the following:
```
class A(Generic[T]):
shared_attr: ClassVar[list[T]] = []
```
PEP 526 is actually quite clear about this:
> Note that a ClassVar parameter cannot include any type variables, regardle... | diff --git a/mypy/message_registry.py b/mypy/message_registry.py
--- a/mypy/message_registry.py
+++ b/mypy/message_registry.py
@@ -204,6 +204,10 @@ def format(self, *args: object, **kwargs: object) -> "ErrorMessage":
'Cannot override class variable (previously declared on base class "{}") with instance '
"var... | diff --git a/mypy/test/testsemanal.py b/mypy/test/testsemanal.py
--- a/mypy/test/testsemanal.py
+++ b/mypy/test/testsemanal.py
@@ -20,20 +20,22 @@
# Semantic analyzer test cases: dump parse tree
# Semantic analysis test case description files.
-semanal_files = ['semanal-basic.test',
- 'semanal-expre... | ["mypy/test/testsemanal.py::SemAnalSuite::testClassVarWithTypeVariable"] | [] | null | true | 2021-11-21T09:41:09Z | 2 | 14 | 1 | 512 | 0 | 0.85 | 1 | 0.55 | 1 | 0.132 | 81.721 | |
1,493 | swe_bench_pro::test::75 | swe_bench_pro | test | 75 | instance_ansible__ansible-83fb24b923064d3576d473747ebbe62e4535c9e3-vba6da65a0f3baefda7a058ebbd0a8dcafb8512f5 | ansible/ansible | ansible/ansible | python | 0044091a055dd9cd448f7639a65b7e8cc3dacbf1 | ## Title Support multiple destination ports in iptables rules
## Description
The Ansible iptables module does not provide a way to specify multiple destination ports in a single rule. Users must create separate rules for each port, which makes configurations more complex and less efficient.
There should be a parameter... | ## Requirements
- Add a `destination_ports` parameter that accepts a list of ports or port ranges and defaults to an empty list.
- When `destination_ports` is non-empty, use `append_match` and `append_csv` to generate `-m multiport --dports <comma-separated-ports>`.
- Place the multiport arguments after `-j <jump>` a... | diff --git a/changelogs/fragments/72928_adding_multiport_support.yml b/changelogs/fragments/72928_adding_multiport_support.yml
new file mode 100644
index 00000000000000..4476e6ba3caf62
--- /dev/null
+++ b/changelogs/fragments/72928_adding_multiport_support.yml
@@ -0,0 +1,2 @@
+minor_changes:
+- Module iptables multipor... | diff --git a/test/units/modules/test_iptables.py b/test/units/modules/test_iptables.py
index 25a157e552c17e..7326b6563ca349 100644
--- a/test/units/modules/test_iptables.py
+++ b/test/units/modules/test_iptables.py
@@ -917,3 +917,39 @@ def test_comment_position_at_end(self):
'this is a comment'
])... | ["test/units/modules/test_iptables.py::TestIptables::test_destination_ports"] | ["test/units/modules/test_iptables.py::TestIptables::test_flush_table_without_chain", "test/units/modules/test_iptables.py::TestIptables::test_insert_rule_with_wait", "test/units/modules/test_iptables.py::TestIptables::test_policy_table_changed_false", "test/units/modules/test_iptables.py::TestIptables::test_policy_tab... | ghcr.io/scaleapi/swe-bench_pro-v2:instance_ansible__ansible-83fb24b923064d3576d473747ebbe62e4535c9e3-vba6da65a0f3baefda7a058ebbd0a8dcafb8512f5 | true | null | 2 | 22 | 1 | 545 | 0 | 0.95 | 1 | 0.55 | 1 | 0.164167 | 81.7175 | |
1,494 | swe_gym::train::639 | swe_gym | train | 639 | conan-io__conan-14760 | conan-io/conan | conan-io/conan | python | 5353d85bcf18fd3ed2ece151fe8577abfe08bc1b | [feature] conan remove should have a --dry-run option
### What is your suggestion?
`conan remove` asks for every package if it really should be deleted. This is really bothersome when removing many packages (e.g. when removing all but the last revision with `conan remove '*#!latest'`).
However, it would be nice to se... | Hi @fschoenm thanks for your request.
Do you know about the packages lists feature? ([Release blog here](https://blog.conan.io/2023/06/28/Conan-bulk-package-operations.html))
It's a way to have the output of some commands be the input of a few others. [See here for an example of your use case](https://docs.conan.... | diff --git a/conan/cli/commands/remove.py b/conan/cli/commands/remove.py
--- a/conan/cli/commands/remove.py
+++ b/conan/cli/commands/remove.py
@@ -9,8 +9,8 @@
def summary_remove_list(results):
- """ Do litte format modification to serialized
- list bundle so it looks prettier on text output
+ """ Do a lit... | diff --git a/conans/test/integration/command/remove_test.py b/conans/test/integration/command/remove_test.py
--- a/conans/test/integration/command/remove_test.py
+++ b/conans/test/integration/command/remove_test.py
@@ -11,7 +11,6 @@
from conans.test.utils.tools import NO_SETTINGS_PACKAGE_ID, TestClient, TestServer, Ge... | ["conans/test/integration/command/remove_test.py::TestRemoveWithoutUserChannel::test_local_dryrun_output[True]", "conans/test/integration/command/remove_test.py::TestRemoveWithoutUserChannel::test_local[True]", "conans/test/integration/command/remove_test.py::TestRemoveWithoutUserChannel::test_local_dryrun_output[False... | ["conans/test/integration/command/remove_test.py::test_new_remove_recipe_revisions_expressions[data3-True]", "conans/test/integration/command/remove_test.py::test_new_remove_package_expressions[data7-True]", "conans/test/integration/command/remove_test.py::test_new_remove_package_expressions[data3-False]", "conans/test... | null | true | 2023-09-17T23:23:37Z | 1 | 12 | 4 | 531 | 0 | 0.85 | 1 | 0.55 | 1 | 0.1285 | 81.7105 | |
1,495 | swe_bench_promax::test::148 | swe_bench_promax | test | 148 | angular__angular-c_4f8ab4f | angular/angular | angular/angular | typescript | a99e724c604412baa7739a2132679d3eaedb391a | When building forms with Angular's reactive validation system, developers frequently encounter scenarios where numeric input originates from text-based fields—such as HTML `<input type="text">` elements—or optional fields that may be left empty. In these cases, form control values often arrive as strings (e.g., `"75"`)... | diff --git a/goldens/public-api/forms/signals/index.api.md b/goldens/public-api/forms/signals/index.api.md
--- a/goldens/public-api/forms/signals/index.api.md
+++ b/goldens/public-api/forms/signals/index.api.md
@@ -274,7 +274,7 @@ export type MapToErrorsFn<TValue, TResult, TPathKind extends PathKind = PathKind
export ... | diff --git a/packages/forms/signals/test/node/api/validators/max.spec.ts b/packages/forms/signals/test/node/api/validators/max.spec.ts
--- a/packages/forms/signals/test/node/api/validators/max.spec.ts
+++ b/packages/forms/signals/test/node/api/validators/max.spec.ts
@@ -59,7 +59,7 @@ describe('max validator', () => {
... | null | null | key4127/refactor-dockerhub:angular__angular-c_4f8ab4f | true | 1763157418 | 3 | 28 | null | 2,293 | 0 | 0.9 | 1 | 0.55 | 1 | 0.4755 | 81.7015 | ||
1,496 | swe_gym::train::351 | swe_gym | train | 351 | python__mypy-11417 | python/mypy | python/mypy | python | 28d57b13ab5ea765728bde534eda2877f8d92b4b | PEP 647 support mishandles higher-order functions
See #9865 for the initial PEP 647 support (type guards).
I did not manage to get this to work right for higher-order functions, notably combined with overloads.
There's a test that fails: [testTypeGuardOverload](https://github.com/python/mypy/blob/fffbe88fc54807c8b10a... | @sobolevn want to take a look at this? The (skipped) test is improved after #11314, but still isn't fully passing.
Possibly related to #1317 and friends. There are some places in applytype / expandtype where we lose track of type variables.
Sure! Will do today 👍
Thanks for letting me know.
Yeap, it still fails:
... | diff --git a/mypy/checkexpr.py b/mypy/checkexpr.py
--- a/mypy/checkexpr.py
+++ b/mypy/checkexpr.py
@@ -3560,6 +3560,12 @@ def infer_lambda_type_using_context(self, e: LambdaExpr) -> Tuple[Optional[Calla
callable_ctx = get_proper_type(replace_meta_vars(ctx, ErasedType()))
assert isinstance(callable_ctx... | diff --git a/test-data/unit/check-typeguard.test b/test-data/unit/check-typeguard.test
--- a/test-data/unit/check-typeguard.test
+++ b/test-data/unit/check-typeguard.test
@@ -247,7 +247,7 @@ def main1(a: object) -> None:
[builtins fixtures/tuple.pyi]
-[case testTypeGuardOverload-skip]
+[case testTypeGuardOverload]... | ["mypy/test/testcheck.py::TypeCheckSuite::testTypeGuardOverload"] | [] | null | true | 2021-10-31T12:07:03Z | 1 | 6 | 1 | 630 | 0 | 0.85 | 1 | 0.55 | 1 | 0.125 | 81.7 | |
1,497 | swe_gym::train::2303 | swe_gym | train | 2,303 | Project-MONAI__MONAI-6090 | Project-MONAI/MONAI | project-monai/monai | python | 958aac78ab8130517638a47175571e081ae03aee | `ORIGINAL_CHANNEL_DIM` datatype for collate
**Describe the bug**
the `ORIGINAL_CHANNEL_DIM` field currently allows different datatypes
https://github.com/Project-MONAI/MONAI/blob/68074f07e4c04657f975cff2269ebe937f50e619/monai/data/image_reader.py#L307-L309
and this causes errors when collating multiple metatensors: ht... | diff --git a/monai/data/image_reader.py b/monai/data/image_reader.py
--- a/monai/data/image_reader.py
+++ b/monai/data/image_reader.py
@@ -27,6 +27,7 @@
from monai.data.utils import (
affine_to_spacing,
correct_nifti_header_if_necessary,
+ is_no_channel,
is_supported_format,
orientation_ras_lps,... | diff --git a/tests/test_splitdim.py b/tests/test_splitdim.py
--- a/tests/test_splitdim.py
+++ b/tests/test_splitdim.py
@@ -40,13 +40,12 @@ def test_correct_shape(self, shape, keepdim, im_type):
arr[0, 0, 0, 0] *= 2
self.assertEqual(arr.flatten()[0], out[0].flatten()[0])
- def test_error(s... | ["tests/test_splitdimd.py::TestSplitDimd::test_singleton", "tests/test_splitdim.py::TestSplitDim::test_singleton"] | ["tests/test_splitdimd.py::TestSplitDimd::test_correct_06", "tests/test_splitdimd.py::TestSplitDimd::test_correct_17", "tests/test_splitdimd.py::TestSplitDimd::test_correct_23", "tests/test_splitdimd.py::TestSplitDimd::test_correct_08", "tests/test_splitdimd.py::TestSplitDimd::test_correct_21", "tests/test_splitdimd.py... | null | true | 2023-03-01T21:59:03Z | 4 | 66 | 2 | 1,994 | 0 | 0.85 | 1 | 0.7 | 0.85 | 0.552333 | 81.6945 | ||
1,498 | swe_gym::train::958 | swe_gym | train | 958 | dask__dask-8040 | dask/dask | dask/dask | python | 4a59a6827578fdf8e105d1fb7e9d50d428c9d5fa | Regression: poor memory management in threads and sync schedulers
Reopen after triage from https://github.com/pydata/xarray/issues/5165
```python
import dask.array as da
d = da.random.random((15000, 250000), chunks=(1, -1)).sum()
d.compute(optimize_graph=False)
```
Peak RAM usage:
Before #6322 (2021.3.1): 200 MiB
Afte... | Also cc @mrocklin @jrbourbeau . IMHO this should be treated as very high priority as it is something that is very likely to hit in the face a newbie user when he plays around with dask.array or dask.dataframe for the very first time.
Hi,
I'm also experiencing increased memory usage since ad0e5d140dfc934d94583f8ce50d... | diff --git a/dask/local.py b/dask/local.py
--- a/dask/local.py
+++ b/dask/local.py
@@ -181,7 +181,7 @@ def start_state_from_dask(dsk, cache=None, sortkey=None):
waiting_data = dict((k, v.copy()) for k, v in dependents.items() if v)
ready_set = set([k for k, v in waiting.items() if not v])
- ready = sorte... | diff --git a/dask/tests/test_local.py b/dask/tests/test_local.py
--- a/dask/tests/test_local.py
+++ b/dask/tests/test_local.py
@@ -1,3 +1,5 @@
+import pytest
+
import dask
from dask.local import finish_task, get_sync, sortkey, start_state_from_dask
from dask.order import order
@@ -170,3 +172,22 @@ def append(i):
... | ["dask/tests/test_order.py::test_local_parents_of_reduction[abcde]", "dask/tests/test_order.py::test_local_parents_of_reduction[edcba]", "dask/tests/test_local.py::test_complex_ordering"] | ["dask/tests/test_order.py::test_stacklimit[abcde]", "dask/tests/test_order.py::test_type_comparisions_ok[abcde]", "dask/tests/test_order.py::test_avoid_broker_nodes[abcde]", "dask/tests/test_order.py::test_order_empty", "dask/tests/test_local.py::TestGetAsync::test_data_not_in_dict_is_ok", "dask/tests/test_local.py::T... | null | true | 2021-08-14T16:00:22Z | 1 | 13 | 3 | 477 | 0 | 0.85 | 1 | 0.55 | 1 | 0.122833 | 81.6935 | |
1,499 | swe_gym::train::2044 | swe_gym | train | 2,044 | Project-MONAI__MONAI-5428 | Project-MONAI/MONAI | project-monai/monai | python | 5b35cc2a4985d24f2f849341dd1462797d2f5268 | KeyError: 'label' monai/apps/auto3dseg/data_analyzer.py
**Describe the bug**
running `python -m monai.apps.auto3dseg DataAnalyzer get_all_case_stats` with ` --label_key=None`
there's a `KeyError: 'label'` with this line:
https://github.com/Project-MONAI/MONAI/blob/6e77d57938a4253353265616b54ab8be3f2d5ab3/monai/apps/a... | @wyli Sure I can fix this.
There is a test for CPU case but not GPU case. I will add it in the `SIM_GPU_TEST_CASES`
https://github.com/Project-MONAI/MONAI/blob/6e77d57938a4253353265616b54ab8be3f2d5ab3/tests/test_auto3dseg.py#L73 | diff --git a/monai/apps/auto3dseg/data_analyzer.py b/monai/apps/auto3dseg/data_analyzer.py
--- a/monai/apps/auto3dseg/data_analyzer.py
+++ b/monai/apps/auto3dseg/data_analyzer.py
@@ -76,8 +76,8 @@ class DataAnalyzer:
image_key: a string that user specify for the image. The DataAnalyzer will look it up in the
... | diff --git a/tests/test_auto3dseg.py b/tests/test_auto3dseg.py
--- a/tests/test_auto3dseg.py
+++ b/tests/test_auto3dseg.py
@@ -71,12 +71,13 @@
[{"sim_dim": (32, 32, 32), "label_key": "label"}],
[{"sim_dim": (32, 32, 32, 2), "label_key": "label"}],
[{"sim_dim": (32, 32, 32), "label_key": None}],
+ [{"s... | ["tests/test_auto3dseg.py::TestDataAnalyzer::test_data_analyzer_cpu_3"] | ["tests/test_auto3dseg.py::TestDataAnalyzer::test_filename_case_analyzer_image_only", "tests/test_auto3dseg.py::TestDataAnalyzer::test_transform_analyzer_class", "tests/test_auto3dseg.py::TestDataAnalyzer::test_fg_image_stats_summary_analyzer", "tests/test_auto3dseg.py::TestDataAnalyzer::test_basic_analyzer_class", "te... | null | true | 2022-10-28T13:46:38Z | 1 | 14 | 1 | 452 | 0 | 0.85 | 1 | 0.55 | 1 | 0.122 | 81.691 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.