instance_id
stringlengths
10
65
repo
stringlengths
5
59
pr_number
int64
1
313k
task_type
stringclasses
1 value
base_commit
stringlengths
40
40
review_commit
stringlengths
40
40
title
stringlengths
2
282
body
stringlengths
7
3k
patch
stringlengths
202
204k
n_defects
int64
1
72
n_supported
int64
1
65
n_major
int64
0
32
defects
stringlengths
140
18.8k
certifier_count
int64
spack__spack__50909
spack/spack
50,909
defect
9da34f27d49d5af21733d3fc97c5d028ce9116d4
bd826b15909b7efb8e4958c0617a0f1e79215696
find: report in groups by compilers (not compiler)
This PR was inspired by a discussion in the `Spack General` meeting on June 18, 2025. In the spirit of recent compiler changes, it might be helpful to start grouping installed packages by `compilers` instead of `compiler`. This PR changes the output, which seems fine for a "fresh" clone/installs BUT not so nice for ...
diff --git a/lib/spack/spack/cmd/__init__.py b/lib/spack/spack/cmd/__init__.py index afd390eb1f2e54..f58fa1e6bccb34 100644 --- a/lib/spack/spack/cmd/__init__.py +++ b/lib/spack/spack/cmd/__init__.py @@ -370,9 +370,9 @@ def display_specs_as_json(specs, deps=False): def iter_groups(specs, indent, all_headers): - ...
2
2
0
[{"id": "G0", "claim": "The compilers cleanup line should use `strip()` (or `lstrip()` if only the left side is needed) instead of only dropping a leading space.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The header should pass `compilers_in...
null
spack__spack__50935
spack/spack
50,935
defect
c702f5b89eea1950c76472fbf8f0919ad12880a6
72e7562b764be824cbc2e0ff8530107077ec80f5
`get_pkg_class`: improve reporting of import error resulting from repo mismatch
Debugging #50934 required additional information about the reason the error was raised, which turned out to be a problem with the package assuming access to the `builtin_mock` repository. Given support for multiple package repositories, it is important that the error messages associated with import errors related to...
diff --git a/lib/spack/spack/repo.py b/lib/spack/spack/repo.py index 3c37ed28c31312..dc21061c65a3f3 100644 --- a/lib/spack/spack/repo.py +++ b/lib/spack/spack/repo.py @@ -1400,7 +1400,9 @@ def get_pkg_class(self, pkg_name: str) -> Type["spack.package_base.PackageBase"] try: module = importlib.impo...
2
2
1
[{"id": "G0", "claim": "The code should distinguish between a package that does not exist and an error that occurs while loading or executing the package module, instead of raising UnknownPackageError with suggestions when the real issue is a syntax error or an incorrect import statement in package.py.", "category": "c...
null
spack__spack__50950
spack/spack
50,950
defect
fbadf557433ae3d8cb8a2b63a81303de42a9fd6f
4a71da85402f7a37985fa33929964910c9fd9e85
tests: fix leaky `spack_repo.builtin_mock` in `sys.modules`
Add an auto-use fixture which deletes `spack_repo.*` from `sys.modules`. This ensures that tests don't rely on mock packages being imported in another test. * Fix a few issues that showed up as a result of that: `MockRepositoryBuilder` now generates a builder (with a unique name). * Add a fixture `repo_builder`, in...
diff --git a/lib/spack/spack/repo.py b/lib/spack/spack/repo.py index 3c37ed28c31312..abd89dc74e3bb1 100644 --- a/lib/spack/spack/repo.py +++ b/lib/spack/spack/repo.py @@ -13,11 +13,9 @@ import inspect import itertools import os -import random import re import shutil import stat -import string import sys import ...
5
3
0
[{"id": "G0", "claim": "Fix the typo in the comment added in setup_build_environment of the cmake mock package: 'avaiable' should be spelled 'available'.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G2", "claim": "Remove any leading whitespace on the import li...
null
spack__spack__50994
spack/spack
50,994
defect
2392f747559d3a69f795882728af4af4a8d8e795
393e82f246e20d193ef9bfcd2d3e9fdd7108b670
allow managed environments to be organized into folders
Spack currently forces environments to have simple names. This forces a flat folder structure for all managed environments. This PR relaxes this restriction and allows a folder structure to help organize environments. This would allow pointing Spack to a known environment root for a project which may be organized this ...
diff --git a/lib/spack/spack/environment/environment.py b/lib/spack/spack/environment/environment.py index 4a03b57ef1eade..d2c9ff89684a86 100644 --- a/lib/spack/spack/environment/environment.py +++ b/lib/spack/spack/environment/environment.py @@ -88,9 +88,10 @@ def environment_name(path: Union[str, pathlib.Path]) -> st...
1
1
1
[{"id": "G0", "claim": "The nested-environment feature should be documented in the environments docs and covered by a unit test so future changes cannot break it.", "category": "documentation", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
spack__spack__51120
spack/spack
51,120
defect
15e7b9edaeb516faab4512f95fa16d12eb412b90
ab31b0cea8713c84d130aa904f928a25702ef01a
oci: allow http with `oci+http://` scheme
Until now, Spack only supported the OCI Distribution API over https, which complicates testing on localhost: ``` docker run -p 5000:5000 registry ``` With this commit, users can force Spack to use `http://` using the `oci+http://` scheme for the build cache: ``` spack mirror add local-registry oci+http://...
diff --git a/lib/spack/spack/mirrors/mirror.py b/lib/spack/spack/mirrors/mirror.py index 0db5ac4f47ae9a..9fe9715319edd9 100644 --- a/lib/spack/spack/mirrors/mirror.py +++ b/lib/spack/spack/mirrors/mirror.py @@ -358,6 +358,13 @@ def get_profile(self, direction: str) -> Optional[str]: def get_endpoint_url(self, dire...
2
1
1
[{"id": "G0", "claim": "The __eq__ method does not compare the insecure field, so two ImageReference objects with different insecure settings could be considered equal, which could lead to incorrect behavior when comparing image references.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope":...
null
spack__spack__51190
spack/spack
51,190
defect
348e00301b18d01888970bae1a1d2af411ae622c
db06f87b41c97ca44660dc14aa6593619555843b
solver: ensure commit variants enter dag hash
Resolves #51167 by moving the commit variant population before specs are finalized. <!-- Remember that `spackbot` can help with your PR in multiple ways: - `@spackbot help` shows all the commands that are currently available - `@spackbot fix style` tries to push a commit to fix style issues in this PR - `@spac...
diff --git a/lib/spack/spack/package_base.py b/lib/spack/spack/package_base.py index 780bf78a898c70..3a3770da25bf1c 100644 --- a/lib/spack/spack/package_base.py +++ b/lib/spack/spack/package_base.py @@ -1042,24 +1042,20 @@ def needs_commit(cls, version) -> bool: return False - def resolve_binary_provena...
5
3
3
[{"id": "G0", "claim": "The regression test marked xfail (test_commit_variant_enters_the_hash, PR 51182) should be unmarked as xfail.", "category": "testing", "verdict": "opposed", "priority": "P2", "scope": "pre_existing"}, {"id": "G1", "claim": "There might still be a bug in the commit resolution for the mirror case,...
null
spack__spack__51191
spack/spack
51,191
defect
7554d2a4a3bd3ac67075277cc34c1fd02193e0dd
89ef4137cb2f803adf1486de71e0eb493dc4e29d
Includes: support git includes
This PR allows the use of git options, like those supported for `repos.yaml`, in `include.yaml`. This has been tested manually using configuration files from `https://github.com/spack/spack-configs/tree/main/USC/config`. Example (from the updated docs): ``` include: - git: https://github.com/spack/spack-conf...
diff --git a/lib/spack/docs/include_yaml.rst b/lib/spack/docs/include_yaml.rst index bb4515aeaaf9b3..773e8cbb05f5fe 100644 --- a/lib/spack/docs/include_yaml.rst +++ b/lib/spack/docs/include_yaml.rst @@ -14,9 +14,25 @@ Include Settings (include.yaml) Spack allows you to include configuration files through ``include.y...
6
6
0
[{"id": "G0", "claim": "The caller should not branch on whether the returned object has a path attribute; make included_path() always return a list of paths so the hasattr check disappears.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Avoid another lev...
null
spack__spack__51218
spack/spack
51,218
defect
8ecf3a4c2d6da3b58620f903cbb04b2f6c114ae3
6cbd61b57a41079e69ec8c14e8617d8729001e5d
solver: fix error with flags when a package appears multiple times in the DAG
fixes #51209 Compiler flags from the command line are evaluated as part of the ASP problem, so they are already in the output, but: 1. They might have the wrong order, or 2. They might be conflated on a single node, when they come from duplicates of the same package In this PR we fix those issues, just by reord...
diff --git a/lib/spack/spack/solver/asp.py b/lib/spack/spack/solver/asp.py index 314fe0aceebf9c..a224165e6a0a3b 100644 --- a/lib/spack/spack/solver/asp.py +++ b/lib/spack/spack/solver/asp.py @@ -277,6 +277,30 @@ def extend_flag_list(flag_list, new_flags): flag_list.append(flag) +def _reorder_flags(flag_lis...
2
2
0
[{"id": "G0", "claim": "Add a comment in `_reorder_flags` explaining that once the flag_group is known there is no need to iterate over the flag_list because the group represents all of them.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Add a co...
null
spack__spack__51219
spack/spack
51,219
defect
f71acf94f0c1cb114aba5b683f47ba25d241bdf9
ec9c2ab01b676b6624e2052a330ffbee7157dd68
Enable gitlab ci
In order to enable running the spack-packages CI from spack/spack we need to be able to run the `.ci/gitlab/gitlab-ci.yml` found in spack-packages, and the associated stack environments, a number of changes are required in spack and in spack-packages. This PR implements the CI configuration and updates to how `ci ge...
diff --git a/.ci/gitlab-ci.yml b/.ci/gitlab-ci.yml new file mode 100644 index 00000000000000..100b7ea0cd56ce --- /dev/null +++ b/.ci/gitlab-ci.yml @@ -0,0 +1,48 @@ +# Gitlab configuraiton for spack/spack + +stages: + - packages + +variables: + SPACK_PACKAGES_CHECKOUT_VERSION: refs/pull/342/head + +.clone_packages: &c...
5
3
0
[{"id": "G0", "claim": "The leftover debug `print` statements (e.g. `checking_include`) in the include-fixing loop should be dropped or converted to `tty.debug` instead of printing to stdout.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The mu...
null
spack__spack__51259
spack/spack
51,259
defect
167b55a7c7bd24d6317c95e2116c7df26488ea6d
4095aecafb7ab05ca285560b029f0eb5f126e0f0
when: deal with `%` vs. `^` correctly
builds on #51256 #51256 solves the most common bug in the `when` context manager, i.e. the case of a single `%` used in a constraint spec, but doesn't do anything for other, less common, cases where `%` is treated incorrectly. Here we fix those cases too, by removing the ad-hoc `merge_abstract_anonymous_specs` ...
diff --git a/lib/spack/spack/directives_meta.py b/lib/spack/spack/directives_meta.py index 66d15105e2a383..79f0b7f81e37e6 100644 --- a/lib/spack/spack/directives_meta.py +++ b/lib/spack/spack/directives_meta.py @@ -184,8 +184,10 @@ def _wrapper(*args, **_kwargs): ] if kwargs.ge...
3
3
1
[{"id": "G0", "claim": "The change cannot be backported because it extends the package API, so `def satisfies(...)` etc. should remain as is and instead call a private `_satisfies(..., resolve_virtuals=True)`.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim"...
null
spack__spack__51282
spack/spack
51,282
defect
f71acf94f0c1cb114aba5b683f47ba25d241bdf9
752a16542ab364476e8076d13b3a18946fa3f51d
solver: requirements on virtual can influence provider weights
fixes #51267 Before this change, provider weights were determined just by package preferences. This could cause issues in cases where the preferred, or required, provider is not the "default" provider. This PR changes the ASP setup to take into account the most common cases of requirements and strong preferences,...
diff --git a/lib/spack/spack/solver/asp.py b/lib/spack/spack/solver/asp.py index 455f743f83caf8..0d219f6d1d2b2c 100644 --- a/lib/spack/spack/solver/asp.py +++ b/lib/spack/spack/solver/asp.py @@ -2043,34 +2043,45 @@ def package_splice_rules(self, pkg): self.gen.newline() - def virtual_preferences(sel...
4
2
1
[{"id": "G0", "claim": "The loop over requirement rules should build `preferred` in an `else` branch instead of using an early `continue`, since filling `preferred` is one of the two outcomes of the loop rather than an exit condition.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "...
null
spack__spack__51445
spack/spack
51,445
defect
856a3032fbc83e3435b16faa3633c5e6e3314b6c
d440d925c5bce32fa71c2ccd46628ef0dc29ea6e
Resolve commit SHA look up failures for annotated tags
Using `git ls-remote` and `git rev-parse` on an annotated tag provide the annotated tag's SHA and not the associated commit SHA. This PR is to correctly handle annotated tags so we are still ending up with the commit SHA. Updated ref_list to include annotated tag's commit. <!-- Remember that `spackbot` can hel...
diff --git a/lib/spack/spack/fetch_strategy.py b/lib/spack/spack/fetch_strategy.py index a6d4505dc925b2..935e446c6c3e8c 100644 --- a/lib/spack/spack/fetch_strategy.py +++ b/lib/spack/spack/fetch_strategy.py @@ -885,6 +885,7 @@ def cachable(self): def source_id(self): # TODO: tree-hash would secure downl...
5
5
2
[{"id": "G0", "claim": "The TODO comment and the archive-provenance approach could be totally wrong, so it should be reworked rather than trusted.", "category": "correctness", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The length-only check misidentifies 40-character tags a...
null
spack__spack__51461
spack/spack
51,461
defect
e250ec0fc81130b708a8abe1894f0cc926880210
2c61f14e2e8df79c93aeda0253d15c5a19e1ec8b
Configuration scopes: fix severe ordering issue when `-C` and `-e` are used together
Fixes #51459. #50853 attempted to make configuration (envs and config scopes) specified on the CLI merge in CLI order, but did not quite succeed. Environments, when loaded, would still appear out of order in the scope stack. This fixes the issues and establishes, after much discussion, the ordering we want for conf...
diff --git a/lib/spack/docs/configuration.rst b/lib/spack/docs/configuration.rst index a9938ab0aca387..47c069e8fd5d85 100644 --- a/lib/spack/docs/configuration.rst +++ b/lib/spack/docs/configuration.rst @@ -81,13 +81,13 @@ From lowest to highest precedence: #. **user**: Stored in the home directory: ``~/.spack/``. ...
3
1
0
[{"id": "G0", "claim": "The _ENV handling in add_command_line_scopes could probably be simplified now that environments enter configuration at a single priority, though the simplification can wait if this is the best way to get the bug fixed for now.", "category": "maintainability", "verdict": "supported", "priority": ...
null
spack__spack__51483
spack/spack
51,483
defect
0cf69025c88c85a7aa4e2dbeb3eb69c0b0690127
b82081e4f41503f30901d932edf8b3507a598327
Skip resource downloads when an existing directory is passed to develop
<!-- Remember that `spackbot` can help with your PR in multiple ways: - `@spackbot help` shows all the commands that are currently available - `@spackbot fix style` tries to push a commit to fix style issues in this PR - `@spackbot re-run pipeline` runs the pipelines again, if you have write access to the reposit...
diff --git a/lib/spack/spack/package_base.py b/lib/spack/spack/package_base.py index 1ac55e52bb3515..207a83126a61ae 100644 --- a/lib/spack/spack/package_base.py +++ b/lib/spack/spack/package_base.py @@ -1669,7 +1669,11 @@ def do_stage(self, mirror_only=False): self.stage.create() # Fetch/expand any ...
3
2
2
[{"id": "G0", "claim": "The Windows CI tests fail on the new mock_resource_fetch fixture because its lambdas cannot be pickled under Windows spawn multiprocessing; move the lambdas to file-scope-level functions (or move the fixture local with @pytest.mark.not_on_windows).", "category": "correctness", "verdict": "suppor...
null
spack__spack__51506
spack/spack
51,506
defect
4b9d4a74be13ac7a5776dfc85035ed81a3f75628
0c84f3f3b031f4809913897511921fbb4e8bd878
solver: fix a bug in the initialization of the static analyzer
In some cases the static analyzer might need to access self.store before it's set. Fix this by moving the call to super() after self.store initialization. Also, adds unit tests <!-- Remember that `spackbot` can help with your PR in multiple ways: - `@spackbot help` shows all the commands that are currently av...
diff --git a/lib/spack/spack/solver/input_analysis.py b/lib/spack/spack/solver/input_analysis.py index c6275da923b8ae..ace30ac3fb7d44 100644 --- a/lib/spack/spack/solver/input_analysis.py +++ b/lib/spack/spack/solver/input_analysis.py @@ -259,9 +259,9 @@ def __init__( store: spack.store.Store, binary_...
2
1
0
[{"id": "G0", "claim": "The last spack.yaml entry in the test_static_analysis_in_environments parametrize list should not be indented relative to the other entries.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The explicit `reuse: true` settin...
null
spack__spack__51540
spack/spack
51,540
defect
e61534c5bd0efd1bda43da6c33d8065d64ca3b28
a1cae3e4abf57702b765476d08bfdc990492fc66
spack change: allow modifications to concrete specs
This PR adds an option to the ``spack change`` command to modify concrete specs. This option bypasses all guardrails, and can result in incompatible specs -- it is expected to be useful primarily to package developers who understand the compatibilities of their packages. Example: In a concretized environment w...
diff --git a/lib/spack/docs/environments.rst b/lib/spack/docs/environments.rst index 8047e61aa65a4d..fe4f2cce808754 100644 --- a/lib/spack/docs/environments.rst +++ b/lib/spack/docs/environments.rst @@ -438,6 +438,42 @@ The supplied location will become the build-directory for that package in all fu For example, mo...
7
5
2
[{"id": "G0", "claim": "Changing concrete specs currently requires supplying --no-abstract and --concrete together, which is awkward, so the option set should be redesigned (e.g. --no-abstract|--abstract and --concrete|--no-concrete, or three flags --abstract --concrete --both) so that targeting concrete specs is the e...
null
spack__spack__51555
spack/spack
51,555
defect
1962a3ecc56c890c223a2341b0177eda8d1bb06f
af2551426a70f77881a54dfaec80bb204569f260
solver: do a precheck for non-existing and deprecated versions
The solver can report errors for versions that do not exist, but it's easier and often faster to check for these beforehand. Also the solver doesn't know about deprecated versions, so we can generate a much clearer error message with a pre-pass. - [x] Create a method, `input_spec_version_check`, that checks input s...
diff --git a/lib/spack/spack/solver/asp.py b/lib/spack/spack/solver/asp.py index e8d0d31fd3767c..0d10658742b137 100644 --- a/lib/spack/spack/solver/asp.py +++ b/lib/spack/spack/solver/asp.py @@ -2971,6 +2971,43 @@ def define_concrete_input_specs(self, specs, possible): if spec.concrete: ...
6
2
1
[{"id": "G0", "claim": "Spack should again allow installing versions not explicitly listed in any package.py (as it used to via URL extrapolation), e.g. behind an install flag like --try that warns about unknown versions by default.", "category": "design", "verdict": "uncertain", "priority": "P2", "scope": "pre_existin...
null
spack__spack__51592
spack/spack
51,592
defect
5b6751e2e98a47199a85ead50721b015f625af8a
85ec2ab256ee20476384f57e5da4583c88e7f6dd
jobserver: add tests
Generated by Claude Sonnet 4.5, and various manual changes to reduce verbosity and make it more to my liking. <details> <summary>Prompts</summary> ``` Consider #file:new_installer.py:343-425 and #file:new_installer.py:492-550. I wanna test this in #file:jobserver.py. Before blindly writing tests, I want to do a...
diff --git a/lib/spack/spack/new_installer.py b/lib/spack/spack/new_installer.py index 2a26c3cd5c983c..8e7766b02dbe76 100644 --- a/lib/spack/spack/new_installer.py +++ b/lib/spack/spack/new_installer.py @@ -489,9 +489,13 @@ def reap_children( return to_delete -def get_jobserver_config() -> Optional[Union[str, ...
2
1
0
[{"id": "G0", "claim": "Skip the module at the module level with the standard marker used in other test modules (pytestmark = pytest.mark.not_on_windows(\"does not run on windows\")) instead of the inline sys.platform check with pytest.skip.", "category": "maintainability", "verdict": "uncertain", "priority": "P2", "sc...
null
spack__spack__51635
spack/spack
51,635
defect
c116bbdbbfeff45ce520ad48efd4fd552151ef19
0922a73375688af08f666ceeb7e489d4af6f8066
Bugfix: List the component prefix not the root
Recursively listing a buildcache from the root will result in finding components in other buildcaches that may also exist under that same root. This can lead to degraded performance and errors for many build cache operations. <!-- Remember that `spackbot` can help with your PR in multiple ways: - `@spackbot help...
diff --git a/lib/spack/spack/url_buildcache.py b/lib/spack/spack/url_buildcache.py index bf14c7da3aaef3..2b580957040ef9 100644 --- a/lib/spack/spack/url_buildcache.py +++ b/lib/spack/spack/url_buildcache.py @@ -1099,7 +1099,6 @@ def _entries_from_cache_aws_cli( aws = which("aws") cache_class = get_url_build...
1
1
1
[{"id": "G0", "claim": "The pull request should add a test, e.g. creating an unreadable directory/file and asserting the resulting error appears in the output, to cover the changed mirror-listing behaviour.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
spack__spack__51641
spack/spack
51,641
defect
2ebf7112ea0c05d392bc6253c40284469ceb12eb
8babb3713478f7872c620530a5031f317c37fccf
new_installer.py: implement spack install -pN
Closes #51633 In the new installer, `-j` is a global number of jobs shared by concurrent package builds. The `-p` flag was so far not implemented, and parallelism was effectively only limited by `-j`. Sometimes though, it's useful to limit the number of concurrent package builds when disk space in the stage d...
diff --git a/etc/spack/defaults/base/config.yaml b/etc/spack/defaults/base/config.yaml index 43936bb7ec1e7f..b26ca97cc213e9 100644 --- a/etc/spack/defaults/base/config.yaml +++ b/etc/spack/defaults/base/config.yaml @@ -150,27 +150,28 @@ config: # If set to 'urllib', Spack will use python built-in libs to fetch ur...
3
1
0
[{"id": "G0", "claim": "Documenting a default of 1 that the new installer ignores is a confusing hack; concurrent_packages should default to 0 meaning automatic (new installer: set automatically by build_jobs; old installer: 1 package at a time).", "category": "design", "verdict": "supported", "priority": "P2", "scope"...
null
spack__spack__51674
spack/spack
51,674
defect
8bfbf6d4d13a1676b18803d78514960e9498df22
b25721fa70f36678064e4b8c561ea42924e50691
Add an option to highlight non-default versions and variants
closes #41150 This PR adds an option to `Spec.format` to highlight non-default versions and variants. The definitions of non-default values are solely based on the `package.py` recipe. This allows us to keep the implementation simple and to account for repo updates. For instance, we can ``` $ spack spec --n...
diff --git a/lib/spack/spack/cmd/common/arguments.py b/lib/spack/spack/cmd/common/arguments.py index 839e1f1a66ae27..2a41e782e998b1 100644 --- a/lib/spack/spack/cmd/common/arguments.py +++ b/lib/spack/spack/cmd/common/arguments.py @@ -464,6 +464,16 @@ def no_install_status(): ) +@arg +def show_non_defaults(): ...
3
3
1
[{"id": "G0", "claim": "The docstring for `highlight_variant_fn` should read \"on variants that need\" instead of \"on variants that needs\".", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The docstring for `highlight_variant_fn` in `Spec.format` ...
null
spack__spack__51680
spack/spack
51,680
defect
85bae78aecfe15ed09201055c292ffa89ca64b52
277c4d63e47260f65aa06b857a426e5cfb8b910e
concretizer: parallel concretization on darwin/win32/linux-python3.14
Now that we serialize environments and specs using pickling, we can safely enable parallel concretization on Darwin and macOS and reenable on Linux with Python 3.14. The only change now is to actually serialize the active environment when spawning or forkservering a subprocess. Also, add a monkeypatch autouse ...
diff --git a/lib/spack/spack/concretize.py b/lib/spack/spack/concretize.py index b66a407ae308ff..549bf20d79db28 100644 --- a/lib/spack/spack/concretize.py +++ b/lib/spack/spack/concretize.py @@ -138,11 +138,10 @@ def concretize_separately( ] # Solve the environment in parallel on Linux - # TODO: supp...
1
1
1
[{"id": "G0", "claim": "The PR should not leave the suite with nowhere that exercises parallel execution for the things that run in parallel in production; the reviewer asks for a fix, suggesting a tagged set of parallel tests run in a separate CI task without the disabling fixture and without xdist.", "category": "tes...
null
spack__spack__51700
spack/spack
51,700
defect
671925bbb8b070ac8c917dd6d28da01718f46c71
a266703083de2ef64ba1929b67e008b0e825ddb9
Allow specifying included scopes on the command line if corresponding directories/files do not exists
Previous efforts to add include scopes added behavior in `spack.config.OptionalInclude`, that, when including config scopes from a config scope being processed, checks for the existence of the file or directory of representing the included config scope. If the path does not exist, the included scope is skipped in the r...
diff --git a/lib/spack/spack/cmd/bootstrap.py b/lib/spack/spack/cmd/bootstrap.py index 4e1ce1fab9ef9d..0253e48c430675 100644 --- a/lib/spack/spack/cmd/bootstrap.py +++ b/lib/spack/spack/cmd/bootstrap.py @@ -111,7 +111,12 @@ def setup_parser(subparser: argparse.ArgumentParser) -> None: ) list = sp.add_parser...
10
9
2
[{"id": "G0", "claim": "The heuristic deciding whether a nonexistent include path is a file or a directory is naive (e.g. 'file.txt' would be treated as a directory), and the author asks for review on a better heuristic or a yaml-extension requirement.", "category": "design", "verdict": "supported", "priority": "P2", "...
null
spack__spack__51746
spack/spack
51,746
defect
0154734bd44cb9230fcadecf2e6567c9d22ce5ab
f58db94acb10749fc28ed29127bb1d7409f93899
ci: fix an edge case where multiple versions share the same checksum
If someone accidentally submits a package with two versions with the same sha256 we might not catch it in the CI/CD checks depending on the version ordering. This is because the dictionary will squash two versions with the same checksum. This PR adds a check to ensure versions are not squashed and we rightly report ...
diff --git a/lib/spack/spack/cmd/ci.py b/lib/spack/spack/cmd/ci.py index d7c80f7f3aa630..625860be2e3c6f 100644 --- a/lib/spack/spack/cmd/ci.py +++ b/lib/spack/spack/cmd/ci.py @@ -111,8 +111,7 @@ def setup_parser(subparser: argparse.ArgumentParser) -> None: action="store_true", dest="prune_externals", ...
2
1
0
[{"id": "G0", "claim": "Pass the version-to-checksum mappings as tuples instead of dictionaries, since the methods called here are not used anywhere else and it is fine to change their signatures.", "category": "design", "verdict": "opposed", "priority": "P2", "scope": "pre_existing"}, {"id": "G1", "claim": "The verify...
null
spack__spack__51777
spack/spack
51,777
defect
87168d91d38d90ac8c95ea5efb21677d2db5a8ce
f7cf28dd51ed984f900cdd4a0bcb036a36b50a66
Authentication schemes are case-insensitive (RFC 7235)
[RFC 7235](https://datatracker.ietf.org/doc/html/rfc7235) specifies that HTTP > uses a case-insensitive token as a means to identify the authentication scheme This PR modifies the authentication challenge matching logic to be case-insensitive for the authentication schemes "Bearer" and "Basic".
diff --git a/lib/spack/spack/oci/opener.py b/lib/spack/spack/oci/opener.py index ad100d69ab973d..0bfc38f32fab0c 100644 --- a/lib/spack/spack/oci/opener.py +++ b/lib/spack/spack/oci/opener.py @@ -97,6 +97,14 @@ def __eq__(self, other: object) -> bool: and self.params == other.params ) + def ma...
6
6
2
[{"id": "G0", "claim": "The case-insensitive scheme matching should be covered by test_parse_www_authenticate (add a test for it there).", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "It would be better to apply .lower() in parse_www_authenticate so tha...
null
spack__spack__51796
spack/spack
51,796
defect
88231381b0170ec567dd360c318cd9f653b00d44
a937a9e686d5870331323e6ddae6f6ffec50a996
`compiler_mixing:` config option applies per-language
If you set ``` concretizer: compiler_mixing: false ``` then it should allow using different compilers for C and Fortran. As it was, https://github.com/spack/spack/pull/51135 was forcing all dependencies to use the same compiler for all languages. This also updates the error generation to provide more info...
diff --git a/lib/spack/spack/solver/concretize.lp b/lib/spack/spack/solver/concretize.lp index 884f8cae9b804e..a8418b5b65ad95 100644 --- a/lib/spack/spack/solver/concretize.lp +++ b/lib/spack/spack/solver/concretize.lp @@ -1748,9 +1748,16 @@ unification_set_compiler("root", node(CompilerHash, Compiler), Language) :- #...
2
2
1
[{"id": "G0", "claim": "The error(0, ...) rule should be removed because an error with weight 0 is equivalent to no error under the objective and adds no value.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The error rule should say which language ...
null
spack__spack__51816
spack/spack
51,816
defect
182c615df98bda5d3c1e26513e3a52c40b4efbec
41e4cd7c58ef6e6659188d4ef3a03771576d1b69
directives.py: reduce allocations
Every call to a direct (`version(...)`, etc) creates a closure which captures tons of variables, making them `cell` objects which are heap allocated. Both the closures and variable captures are redundant, as we can forward arguments to "static" functions with `partial(...)`. The general pattern is: ```python d...
diff --git a/lib/spack/spack/directives.py b/lib/spack/spack/directives.py index a8659bf550db77..ac988baa5389be 100644 --- a/lib/spack/spack/directives.py +++ b/lib/spack/spack/directives.py @@ -35,6 +35,7 @@ class OpenMpi(Package): import os import re import warnings +from functools import partial from typing impo...
2
2
0
[{"id": "G0", "claim": "The comment block left in _wrapper belongs with the _remove_directives function that this PR moved out, so the comment should be relocated to go with the function.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "A comment sh...
null
spack__spack__51817
spack/spack
51,817
defect
744e44a96cd153f99285e326e63546e6234fbc02
87b7da890168e00c78b1a3993b69f2d0b6b9a4fe
CI: Add an environment option for build cache index update behavior
<!-- Remember that `spackbot` can help with your PR in multiple ways: - `@spackbot help` shows all the commands that are currently available - `@spackbot fix style` tries to push a commit to fix style issues in this PR - `@spackbot re-run pipeline` runs the pipelines again, if you have write access to the reposit...
diff --git a/lib/spack/spack/ci/__init__.py b/lib/spack/spack/ci/__init__.py index 8906e9aa6d966c..a77df6ef0f77ce 100644 --- a/lib/spack/spack/ci/__init__.py +++ b/lib/spack/spack/ci/__init__.py @@ -255,7 +255,7 @@ def rebuild_filter(s: spack.spec.Spec) -> RebuildDecision: if not spec_locations: r...
4
3
0
[{"id": "G0", "claim": "Fix the misspelled mirror name in the CI warning message (\"buildache-destination\" should be \"buildcache-destination\").", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Correct the misspellings in the __format__ docstring ...
null
spack__spack__51824
spack/spack
51,824
defect
59b4e440391d5f58a665041ca365d9feb5caf472
d71df7f11892994c92af9228bbd57317e01adff9
lmod layout: support non-virtuals in hierarchy
Several users have requested the ability to have `python` or other non-virtual packages as elements in the lmod hierarchy, to better isolate builds with different versions / features. This PR eliminates the restriction that hierarchy components must be virtual packages or compilers. Includes test and documentatio...
diff --git a/lib/spack/docs/module_file_support.rst b/lib/spack/docs/module_file_support.rst index 86036db649b1c3..b6f70ad27017d6 100644 --- a/lib/spack/docs/module_file_support.rst +++ b/lib/spack/docs/module_file_support.rst @@ -447,7 +447,7 @@ When specifying module names by projection for Lmod modules, we recommend...
6
6
1
[{"id": "G0", "claim": "The now-unused NonVirtualInHierarchyError exception class definition can be deleted, since it is not used anywhere else.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Reviewer asks for the reason the compiler-requirement...
null
spack__spack__51896
spack/spack
51,896
defect
e2c49f2b3a7aabc324a2d54f6c8319b854191bd4
ee801dd00426f9ed4884c153ff35a5c9844828a1
remote include path: cache under enclosing scope ({spack|include}.yaml) path or tempdir (from #50207)
Depends on #51895 Cache remote include paths under the enclosing scope's path, where that scope is the scope of the `include.yaml` (or `spack.yaml`) file that defines the remote include. If it has no path (is this possible anymore?) or the path is unwritable, the file will be cached under a temporary directory. ...
diff --git a/lib/spack/docs/include_yaml.rst b/lib/spack/docs/include_yaml.rst index 4e19dbb19d3b4a..c607b15d552d55 100644 --- a/lib/spack/docs/include_yaml.rst +++ b/lib/spack/docs/include_yaml.rst @@ -44,24 +44,31 @@ The same conditions and variables in :ref:`Spec List References <spec-list-refer Remote file URLs ~...
8
8
5
[{"id": "G0", "claim": "Remote include files are downloaded into $user_cache_path rather than under the enclosing scope's path as the PR description states, because only env: scopes use the enclosing path (and the hash-suffix handling is inconsistent).", "category": "correctness", "verdict": "supported", "priority": "P...
null
spack__spack__51899
spack/spack
51,899
defect
efa80217c53f248c5a40f6267fcfb6357e17f1ec
39d487e4943dea9a58e8c8a8e1ae3ccbf35d8b6e
Include environments prep: rename include concrete+ (from #50207)
Extracted from #50207 This PR extracts "low hanging fruit" related to "include_concrete" in preparation for unifying them under the "include" key. Also removed unnecessary extra imports in test/cmd/env.py.
diff --git a/lib/spack/spack/cmd/env.py b/lib/spack/spack/cmd/env.py index 5f75d1b328084d..c4572c1102df11 100644 --- a/lib/spack/spack/cmd/env.py +++ b/lib/spack/spack/cmd/env.py @@ -141,15 +141,15 @@ def _env_create( """Create a new environment, with an optional yaml description. Arguments: - name_o...
1
1
0
[{"id": "G0", "claim": "The two \"(DEPRECATED) include concrete\" comments added in this prep PR should be removed here and kept in the upstream PR instead (empty suggestion blocks proposing deletion of both comment lines).", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"...
null
spack__spack__51900
spack/spack
51,900
defect
341772bbab8673059dfc10913bd3ad5092050c8f
73342daab2e481de9ff41200a68fc1c8409fac36
include environments prep #2: include concrete unification (from #50207), git include URL expansion
~Depends on #51899~ Extracted from https://github.com/spack/spack/pull/50207. Adds variable expansion for `git` for #51956 This PR unifies inclusion of concrete environments (`spack.lock`) under the `include` heading in configuration files. - [x] Supports inclusion of concrete environment `spack.lock` files un...
diff --git a/lib/spack/docs/environments.rst b/lib/spack/docs/environments.rst index fc1683fdab918c..dd7444ece34efa 100644 --- a/lib/spack/docs/environments.rst +++ b/lib/spack/docs/environments.rst @@ -278,16 +278,16 @@ Adding Abstract Specs An abstract spec is the user-specified spec before Spack applies defaults ...
8
6
5
[{"id": "G0", "claim": "The check that ignores included lock files in _scope is too broad because it matches every path ending in .lock; it should match only the basename spack.lock.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The os import insid...
null
spack__spack__51914
spack/spack
51,914
defect
124b9686d153a7e6d6eb9eed7fb318d7fc65272f
d033afbc97c9d4369f78c82ba3460617b9311a0f
Bugfix/cmd list: return proper path for json and html output
@johnwparent UPDATE: Also modified the handling to support `ssh`, local, and non-spack package repositories. This means it uses `git` commands to check the remote origin URL and the relative path to the package to build a suitable package URL or, if unsupported, it returns the local file path. Problem: `spack li...
diff --git a/lib/spack/spack/cmd/list.py b/lib/spack/spack/cmd/list.py index eaa63f3ebeb02f..fcc57d1580c10f 100644 --- a/lib/spack/spack/cmd/list.py +++ b/lib/spack/spack/cmd/list.py @@ -10,14 +10,17 @@ import re import sys from html import escape -from typing import Type +from typing import Optional, Type import...
2
1
1
[{"id": "G0", "claim": "The new test asserts a forward-slash URI against a value containing an OS-native (backslash on Windows) filepath, so the assertion fails on Windows; wrap the expected result (e.g. canonicalize_path, ultimately as_uri) before comparing.", "category": "correctness", "verdict": "supported", "priori...
null
spack__spack__51939
spack/spack
51,939
defect
0178f8998af38a1304656f3fc0d80627ef80302a
c93c54ebe2cf0e8f0b38ffe4804d562ae3f40b29
Support named git includes
This PR adds support for specifying the `name` of a `git` include (https://spack.readthedocs.io/en/latest/include_yaml.html#named-configuration-scopes). It also changes paths for SingleFileScopes reported using `spack config scopes -p` so they do NOT end with the path separator. It does NOT change the current defaul...
diff --git a/lib/spack/docs/include_yaml.rst b/lib/spack/docs/include_yaml.rst index aa090ef2711f6e..48d179341a6f32 100644 --- a/lib/spack/docs/include_yaml.rst +++ b/lib/spack/docs/include_yaml.rst @@ -13,6 +13,8 @@ Include Settings (include.yaml) =============================== Spack allows you to include configu...
7
7
0
[{"id": "G0", "claim": "Asks what the benefit is of reformatting the invalid-scope error message to list the scope keys explicitly.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "Move the relative-prefix removal below the windows sanitization bl...
null
spack__spack__51960
spack/spack
51,960
defect
db75cddc2aa9285a563ac71afef69db416303f86
fd55bcbdbd2db31bf6a24969f3cd1b0d418b97e6
new_installer.py: always pivot prefix, decouple from `--overwrite`
Previously the `--overwrite` flag was passed on all the way to the build process, where it was used to decide whether to error if the install prefix exists prior to the build. That would lead to hard to overcome install failures if an initial build didn't clear its prefix on failure (which was the case due to `SIGT...
diff --git a/lib/spack/spack/new_installer.py b/lib/spack/spack/new_installer.py index 05debb91811a58..eda9d50e452b59 100644 --- a/lib/spack/spack/new_installer.py +++ b/lib/spack/spack/new_installer.py @@ -243,20 +243,17 @@ def install_from_buildcache( class PrefixPivoter: """Manages the installation prefix duri...
2
1
0
[{"id": "G0", "claim": "Decoupling the prefix pivot from --overwrite will make adding per-package locking for the new installer very difficult; each call to worker_function would need to know whether it is an overwrite build and when it was labelled as such, so that it can accept if another process already overwrote in...
null
spack__spack__51985
spack/spack
51,985
defect
18ea99c92cc4c5b49405c068f0fb3e24399de19a
5bf6faabf505ae3f0f15a9b9624c33524e63c856
new_installer.py: initial multi-process support
Allow multi-process concurrency, additionally to per-process package parallelism. Basic idea is as follows. If there are pending builds in this Spack process: * Take a read lock on the database (if this fails, re-enter event loop) * Take a prefix write lock on the to-be-installed spec (if this fails, try th...
diff --git a/lib/spack/spack/new_installer.py b/lib/spack/spack/new_installer.py index 7c4a67ed93478a..0fa9ae5ac94d63 100644 --- a/lib/spack/spack/new_installer.py +++ b/lib/spack/spack/new_installer.py @@ -117,6 +117,7 @@ def __init__( self.control_w_conn = control_w_conn self.log_path = log_path ...
2
1
1
[{"id": "G0", "claim": "The schedule_builds docstring says ``blocked`` is True if any pending builds were blocked on locks, and the reviewer suggests it should say all pending (i.e. blocked is only True when every attempt hit a lock held by another process).", "category": "documentation", "verdict": "uncertain", "prior...
null
spack__spack__51991
spack/spack
51,991
defect
7ab5c181a2605467217614288e411301f51d8a53
d4ed380348fcc2d2bf762db83ae7e7b0f7cf2296
Mirror all skip placeholder packages
Fixes #51971 Placeholder packages such as egl, opengl, and openglu raise InstallError from their fetcher property in `package.py`. This causes spack mirror create --all to fail. This PR catches that error and skips the package with a warning instead of counting it as an error.
diff --git a/lib/spack/spack/mirrors/utils.py b/lib/spack/spack/mirrors/utils.py index ac720a1b96d11f..72d75a850adac8 100644 --- a/lib/spack/spack/mirrors/utils.py +++ b/lib/spack/spack/mirrors/utils.py @@ -15,6 +15,7 @@ from spack.error import MirrorError from spack.llnl.util.filesystem import mkdirp from spack.mir...
1
1
0
[{"id": "G0", "claim": "Skipping a placeholder package should not emit a warning, since a package with no code clearly should not be fetched.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
spack__spack__51997
spack/spack
51,997
defect
c9e77cd2dff815adc6eaa3624655c7d12b571ff9
0926df545868dafe3b708e9a4cf41fc0ec8c5615
new_installer.py: dynamic --jobs
When you run `spack install -j 4` the number of jobs is `4` from start to finish. In the new installer we can make this dynamic with `+` and `-` keyboard input, provided that we are the owner of the jobserver. * On `+`: write a byte to `jobserver.w` * On `-`: eventually read a byte from `jobserver.r` So, `+...
diff --git a/lib/spack/spack/new_installer.py b/lib/spack/spack/new_installer.py index 3b321f3b27b7a9..20857b73df7a51 100644 --- a/lib/spack/spack/new_installer.py +++ b/lib/spack/spack/new_installer.py @@ -508,7 +508,14 @@ class JobServer: def __init__(self, num_jobs: int) -> None: #: Keep track of how m...
3
1
0
[{"id": "G0", "claim": "The `#:` comment on `self.num_jobs` should read 'The number of jobs to run concurrently' instead of 'The number of jobs we want to run concurrently', because saying 'we want' about a number that can differ from the target number is confusing.", "category": "documentation", "verdict": "supported"...
null
spack__spack__52004
spack/spack
52,004
defect
18ea99c92cc4c5b49405c068f0fb3e24399de19a
d9410ad4fe4d67ff7ded1f2328fb8ce5dc65aab1
lock.py: re-affirm POSIX lock to support forking
When doing `acquire_write`, `fork`, `acquire_write`, the forked process currently does not error, because the `_writes` counter is `1` after the fork. But forking does not inherit locks, because it's a different pid. With this change, on a nested lock, we always do the lock syscall, which is a no-op for the proce...
diff --git a/lib/spack/spack/llnl/util/lock.py b/lib/spack/spack/llnl/util/lock.py index 7424dcbf145d30..cd2ec4a3b733a3 100644 --- a/lib/spack/spack/llnl/util/lock.py +++ b/lib/spack/spack/llnl/util/lock.py @@ -381,9 +381,7 @@ def _lock(self, op: int, timeout: Optional[float] = None) -> Tuple[float, int]: ...
2
1
0
[{"id": "G0", "claim": "The lock release calls at the end of the new fork test should be wrapped in a finally block so the locks are released even if an assertion fails midway.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The PR must guarantee the par...
null
spack__spack__52012
spack/spack
52,012
defect
b67fc8162421055c4c08b80a9da7f230481f0a44
1306a83c134d9222f3b69e6599b32c078c4d9760
new_installer.py: read locks on installed deps
After writing a spec to the DB, downgrade the prefix write lock to a read lock rather than releasing it. Accumulate these read locks in retained_read_locks and release them only at the end of the install session. This prevents another process from uninstalling a package that is still needed as a build dependency. ...
diff --git a/lib/spack/spack/new_installer.py b/lib/spack/spack/new_installer.py index 0fe30ccdbcc11c..7d5fad09e792dc 100644 --- a/lib/spack/spack/new_installer.py +++ b/lib/spack/spack/new_installer.py @@ -1259,14 +1259,22 @@ def schedule_builds( capacity: int, needs_jobserver_token: bool, jobserver: Jo...
4
3
1
[{"id": "G0", "claim": "The schedule_builds docstring could be written as bullet points, which may be friendlier for human readers than prose.", "category": "documentation", "verdict": "opposed", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The schedule_builds return type could use a NamedTuple inst...
null
spack__spack__52021
spack/spack
52,021
defect
2bbb9d1d12a3cf3b2553f03cb2b141ba9f244be2
6443111b6e1c46bd57bafa2db21594ebb44f3e16
solver: fix rule for virtuals that are provided together
fixes #51512 Sometimes a unified environment has roots compiled with different compilers. In those cases the rule to ensure that virtuals that need to be provided together ARE provided together was wrong. In this PR we fix it, and we add a test case to avoid regression. <!-- Remember that `spackbot` can hel...
diff --git a/lib/spack/spack/solver/concretize.lp b/lib/spack/spack/solver/concretize.lp index 82676874977ecc..41f0e472b30c1c 100644 --- a/lib/spack/spack/solver/concretize.lp +++ b/lib/spack/spack/solver/concretize.lp @@ -988,12 +988,10 @@ error(100, "Package '{0}' needs to provide both '{1}' and '{2}' together, but p...
1
1
0
[{"id": "G0", "claim": "becker33 suggests rewriting the rule so the other provider node comes from the same virtual_on_edge atom instead of introducing ID2/Package2, saying the increased expressiveness seems unnecessary, and asks whether the change would have any effect on performance.", "category": "performance", "ver...
null
spack__spack__52070
spack/spack
52,070
defect
5a8a79390c5a8dad8015897f9dc4d6d0b0921293
a8dbff654c2b7c7ef51f511c86d3ad31b5832abf
solver: prefer best provider above one with no penalty on variants
Before this commit there were cases where a default provider was not selected because it had penalty on variants. Instead, the second-best provider was selected. Here we tweak optimization priorities to ensure that the provider choice is above variant penalty. **Example** Using a configuration like: ```yaml...
diff --git a/lib/spack/spack/solver/concretize.lp b/lib/spack/spack/solver/concretize.lp index 0f7ffefe721e2f..01f1a50d8ffcdc 100644 --- a/lib/spack/spack/solver/concretize.lp +++ b/lib/spack/spack/solver/concretize.lp @@ -2178,24 +2178,13 @@ opt_criterion(55, "default values of variants not being used (roots)"). ...
2
2
2
[{"id": "G0", "claim": "With the PR's new criterion order, concretization toggles netlib-lapack from ~external-blas to +external-blas and takes amdblis, the second-best blas provider from the default config [openblas, amdblis], which the reviewer finds confusing.", "category": "correctness", "verdict": "supported", "pr...
null
spack__spack__52076
spack/spack
52,076
defect
54135ed30a7eb50f3b6bbf070981a4cdd8ee61a6
b4d292d82bddb106a3fc0d1df50af53054df5557
spec_parser.py: extract toolchain expansion from SpecParser
Co-developed with Claude Opus 4.6 Toolchain references are now parsed as regular dependencies and expanded in a separate post-parse step via `expand_toolchains`. Toolchain expansion now happens in these entry points: - SpecList/SpecListParser for environment YAML - RequirementParser for packages.yaml requireme...
diff --git a/lib/spack/spack/cmd/__init__.py b/lib/spack/spack/cmd/__init__.py index d642711a1820b9..989cef3ff16ce4 100644 --- a/lib/spack/spack/cmd/__init__.py +++ b/lib/spack/spack/cmd/__init__.py @@ -182,7 +182,8 @@ def parse_specs( args = [args] if isinstance(args, str) else args arg_string = " ".join([qu...
4
3
2
[{"id": "G0", "claim": "The `name` parameter of `_parse_toolchain_config` is never used and should be dropped.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Parsing inside `_parse_toolchain_config` (e.g. `Spec(when)`) should happen without tool...
null
spack__spack__52101
spack/spack
52,101
defect
cd9f9d3d396f9413467afe48630e748f511557f4
befe313fbd8c2f1fadfdea54c6b9d653fb823bcf
new_installer.py: suspend, background, foreground
Before this, on <kbd>Ctrl+Z</kbd> the parent process was stopped by `SIGTSTP` but its build subprocesses kept running, consuming CPU and (if verbose) filling log pipes until they blocked on write. If not blocked by full buffers, the builds would complete, but are only written to the database later as the parent pro...
diff --git a/lib/spack/spack/new_installer.py b/lib/spack/spack/new_installer.py index f10d2cff4c910d..8208318bb27bb6 100644 --- a/lib/spack/spack/new_installer.py +++ b/lib/spack/spack/new_installer.py @@ -80,6 +80,7 @@ import spack.util.environment import spack.util.lock from spack.installer import _do_fake_instal...
7
6
1
[{"id": "G0", "claim": "The old SIGTSTP/SIGWINCH handlers should not be recorded both in __init__ and in setup.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "If termios.tcgetattr fails in enter_foreground, old_stdin_settings should be set to so...
null
spack__spack__52120
spack/spack
52,120
defect
0714f2f90645d167742f6401e534b06c3f559ae0
0317a304870ac97f32a5585f17ac989e0e876c2f
new_installer: mark explicit also if already installed implicit
When you run `spack install` and `x` in the DAG, already installed, but implicit in the db; it should then be updated to explicit. The idea is to use the installer event loop to "schedule" the save to db instead of doing ad-hoc database updates. That way, we benefit from batched db writes and it's less likely to hav...
diff --git a/lib/spack/spack/new_installer.py b/lib/spack/spack/new_installer.py index 348b8c8f465780..d61ad749946ddf 100644 --- a/lib/spack/spack/new_installer.py +++ b/lib/spack/spack/new_installer.py @@ -107,6 +107,18 @@ OVERWRITE_GARBAGE_SUFFIX = ".garbage" +class MarkExplicitAction: + """Action to mark an ...
2
2
1
[{"id": "G0", "claim": "The duck-typed protocol that MarkExplicitAction shares with ChildInfo should be made explicit (e.g. via a base class) rather than left implicit.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "It would be more correct to persist Ma...
null
spack__spack__52123
spack/spack
52,123
defect
041eeb25c3e7e5860db18dadd3a7bd854a2bd7c9
47ae3e61c3f7faba66dbd5bc129ab6441708efb7
new_installer.py: support --until
Add support for `spack install --until` in the new installer. Add support for the new installer in `spack dev-build`. This is much cleaner than in the old installer, signalling with exit codes instead of mutating `pkg`.
diff --git a/lib/spack/spack/new_installer.py b/lib/spack/spack/new_installer.py index 7b084327c3cf69..6a73282103e0cf 100644 --- a/lib/spack/spack/new_installer.py +++ b/lib/spack/spack/new_installer.py @@ -106,6 +106,9 @@ #: Suffix for temporary cleanup during failed install OVERWRITE_GARBAGE_SUFFIX = ".garbage" +...
4
4
3
[{"id": "G0", "claim": "EXIT_STOPPED_AT_PHASE is set to 2, which is reserved for misuse of shell builtins, and this exit code needs to be in the 3-63 range reserved for user-defined codes.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The tests do ...
null
spack__spack__52133
spack/spack
52,133
defect
96cae55e9b09e12cf82326541b020a06f372deb4
bd1a6de0b19fb1c94d7d9f601f7672fed7213346
Bugfix: Compiler flags dropped when `packages:all:require` sets a target in some cases
If you add compiler flags to a compiler definition they are not applied in the following circumstances: - The user sets `packages:all:require:[target=x]` - The default target for a system does not match x - The compiler definition does not include a target I think this is because - `reuse.py` uses `extract_d...
diff --git a/lib/spack/spack/compilers/config.py b/lib/spack/spack/compilers/config.py index f34551180b42c9..0b5216e7730cf3 100644 --- a/lib/spack/spack/compilers/config.py +++ b/lib/spack/spack/compilers/config.py @@ -20,7 +20,7 @@ import spack.platforms import spack.repo import spack.spec -from spack.externals imp...
5
5
1
[{"id": "G0", "claim": "Move the test to the end of the file and describe the use case it tests in a docstring.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Remove the comment explaining that expressing require as - spec: \"target=x86_64_v3\" ...
null
spack__spack__52142
spack/spack
52,142
defect
33d863b55e0572c0934d8e1661fd432c68464820
1a1cc693866d80eee7bdca0ab85f47a6f5152797
requirements.py: warn on `prefer:all:[%foo]`
Closes #52141 Since `packages:all:prefer:[%c=gcc]` and similar typically don't mean what the user intended, issue a warning when concretizing. ``` ==> Warning: /path/to/spack.yaml:7: 'packages: all: prefer: ["%c,cxx=gcc"]' applies a dependency constraint to all packages. This can lead to unexpected concretizati...
diff --git a/lib/spack/spack/solver/requirements.py b/lib/spack/spack/solver/requirements.py index 9b2598f5b7c8eb..8d95d94f5de8d4 100644 --- a/lib/spack/spack/solver/requirements.py +++ b/lib/spack/spack/solver/requirements.py @@ -2,7 +2,8 @@ # # SPDX-License-Identifier: (Apache-2.0 OR MIT) import enum -from typing ...
3
3
1
[{"id": "G0", "claim": "The parametrized `section` fixture is never used because the config passed to update_packages_config is hard-coded to `prefer:`, so the `require` case of the parametrization is never actually exercised.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"...
null
spack__spack__52157
spack/spack
52,157
defect
a5b4056c9019d27d7d38885d37f3be4446b48dd8
fe790478fa4d71adc3c15e7994da01b872949e39
repo: improve patch lookup speed
Part of #52155 and a companion PR to #52143 to avoid hitting the 8k stat call penalty when looking up patch files and metadata. When looking up patches by shasum with an existing repo cache file, the current strategy is: * check cache validity (8k stat calls) * lookup the patch by shasum in cache With this ...
diff --git a/lib/spack/spack/cmd/resource.py b/lib/spack/spack/cmd/resource.py index 1792b7e3e9f99b..657d1789a80cf4 100644 --- a/lib/spack/spack/cmd/resource.py +++ b/lib/spack/spack/cmd/resource.py @@ -28,7 +28,7 @@ def setup_parser(subparser: argparse.ArgumentParser) -> None: def _show_patch(sha256): """Show ...
3
3
0
[{"id": "G0", "claim": "The code should pass the cached owner name directly to get_pkg_class instead of splitting off its last dot-separated component.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The `if stale_cache is not None:` check in get_patches_...
null
spack__spack__52250
spack/spack
52,250
defect
6775e4e6d81c4d59fce6baf09640babedcc88bde
2664b472c8b96395edd034cadbabb9a96aa4ccab
externals: fix parsing single-valued variants
fixes #52179 When an external spec string like is parsed from `packages.yaml`, `VariantValue.from_string_or_bool` creates either Boolean variants or multi-valued variants. For the `build_system` variants this is an issue because `.value` returns a single value for single-valued variants and a tuple for multi-valu...
diff --git a/lib/spack/spack/externals.py b/lib/spack/spack/externals.py index aa1c66d9a15050..a2769b7edb3fbd 100644 --- a/lib/spack/spack/externals.py +++ b/lib/spack/spack/externals.py @@ -115,6 +115,16 @@ def complete_variants_and_architecture(node: spack.spec.Spec) -> None: if name not in node.vari...
1
1
0
[{"id": "G0", "claim": "Preserving the existing variant's propagate setting on the corrected variant makes no sense, because propagation shouldn't happen in the first place for externals, so that line should not be there.", "category": "correctness", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
sparckles__Robyn__1002
sparckles/Robyn
1,002
defect
deea29aec9348a96d4e2d4c9207c7a2ceb0bdbce
f4027c4880825fc3e1b7b8086afc960d7d5d38ff
feat: openapi config override
## Description This PR fixes #961 ## Summary This PR does add openapi config override feat ## PR Checklist Please ensure that: - [x] The PR contains a descriptive title - [x] The PR contains a descriptive summary of the changes - [x] You build and test your changes before submitting a PR. - [x] You...
diff --git a/docs_src/src/pages/documentation/api_reference/openapi.mdx b/docs_src/src/pages/documentation/api_reference/openapi.mdx index b732fc154..a67465ea0 100644 --- a/docs_src/src/pages/documentation/api_reference/openapi.mdx +++ b/docs_src/src/pages/documentation/api_reference/openapi.mdx @@ -11,6 +11,10 @@ Out ...
8
5
2
[{"id": "G0", "claim": "Merging the pull request degrades benchmark performance by about 11% on four request/lifecycle benchmarks, and these performance issues should be fixed or acknowledged.", "category": "performance", "verdict": "uncertain", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The param...
null
sparckles__Robyn__1272
sparckles/Robyn
1,272
defect
3a3a19a1f896a7991555d3010c7b5bf04f35df01
c8e4fee456f90e20666180927b660d1b0c1c156e
fix: correct openapi path parameter generation for nested routes
## Description This PR fixes #1270 ## Summary This PR fixes a bug in the OpenAPI generation where nested path parameters (e.g., /users/:id/posts/:post_id) were incorrectly parsed as a single parameter (e.g., id/posts). The logic was updated to use a non-greedy regular expression to accurately identify Roby...
diff --git a/robyn/openapi.py b/robyn/openapi.py index 0e0050d76..5ddbc89eb 100644 --- a/robyn/openapi.py +++ b/robyn/openapi.py @@ -1,5 +1,6 @@ import inspect import json +import re import typing from dataclasses import asdict, dataclass, field from importlib import resources @@ -275,27 +276,21 @@ def get_path_ob...
3
2
0
[{"id": "G0", "claim": "The loop variable `name` shadows the function parameter `name` in get_path_obj, which is fragile if future code after the loop references `name`; rename it (e.g. to `param_name`).", "category": "maintainability", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "cla...
null
sparckles__Robyn__1287
sparckles/Robyn
1,287
defect
7a6d224aaaeb3137e68b08ed09823a07217e1445
7e275e5fd01927540a957e8796d35a3c636f9559
fix: SSEResponse duplicate CORS headers issue
Fixes #1239 ### Problem SSEResponse was hardcoding Access-Control-Allow-Origin: * in the StreamingResponse class. When users configured CORS using ALLOW_CORS(), this resulted in duplicate CORS headers being sent: Access-Control-Allow-Origin: *, http://localhost:8910 This violates the CORS specifi...
diff --git a/CHANGELOG.md b/CHANGELOG.md index 10a6944c2..16407a54c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,10 @@ [Full Changelog](https://github.com/sparckles/robyn/compare/v0.26.1...HEAD) +**Implemented enhancements:** + +- Allow empty returns on websocket handling [\#1263](https://github.com/spa...
2
2
2
[{"id": "G0", "claim": "The new test_sse_custom_cors_headers test only repeats the custom-header check and does not actually verify the no-default-CORS behaviour, so explicit assertions that Access-Control-Allow-Origin and Access-Control-Allow-Headers are absent should be added.", "category": "testing", "verdict": "sup...
null
sparckles__Robyn__1292
sparckles/Robyn
1,292
defect
7f24505d103b299ce3d2d25773b4f33251605af1
3444510a4e30aca361471d9e9501e59b87db8a86
fix: cookies
## Description This PR fixes #1226 ## Summary This PR fixes cookies. <!-- Thank you for contributing to Robyn! --> ## PR Checklist Please ensure that: - [x] The PR contains a descriptive title - [x] The PR contains a descriptive summary of the changes - [x] You build and test your changes be...
diff --git a/integration_tests/base_routes.py b/integration_tests/base_routes.py index becffa93a..6cf22a2a1 100644 --- a/integration_tests/base_routes.py +++ b/integration_tests/base_routes.py @@ -562,6 +562,37 @@ def cookie(): return response +@app.get("/cookie/multiple") +def multiple_cookies(): + respons...
3
1
1
[{"id": "G0", "claim": "Cookie name and value are not sanitized in to_header_value, so special characters (';', '=', ',', control characters) can break or inject additional attributes into the Set-Cookie header, and RFC 6265 requires validation or percent-encoding.", "category": "security", "verdict": "supported", "pri...
null
sparckles__Robyn__1309
sparckles/Robyn
1,309
defect
5b1e77fece7a70d198c51449516399530abcaff9
0a6f5cbaf21c078618333fd5d6f3c1252cf46f01
feat: add easy access query/path params with type coercion for HTTP and WebSocket handlers
## Description This PR fixes #289 ## Summary This PR adds easy access query/path params with type coercion for HTTP and WebSocket handlers <!-- Thank you for contributing to Robyn! --> ## PR Checklist Please ensure that: - [ ] The PR contains a descriptive title - [ ] The PR contains a de...
diff --git a/Cargo.lock b/Cargo.lock index ae7801fd4..91c17a350 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1514,7 +1514,7 @@ checksum = "2b15c43186be67a4fd63bee50d0303afffcef381492ebe2c5d87f324e1b8815c" [[package]] name = "robyn" -version = "0.77.0" +version = "0.78.0" dependencies = [ "actix", "actix-files"...
13
4
2
[{"id": "G0", "claim": "The test's WS_BASE_URL hardcodes port 8080 and will be stale if ROBYN_PORT is overridden; derive it from ROBYN_PORT or a shared constant.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "For a required List[T] parameter with no val...
null
sparckles__Robyn__1347
sparckles/Robyn
1,347
defect
a54ff962f62f60377286a3140b5fec2db492ddc2
0854ade5670e58d3cd95bde5d1e3979decbe5bfb
fix: prevent CORS header duplication on middleware early-return responses
## Summary - Fixes the regression where `ALLOW_CORS` breaks browser preflight (OPTIONS) requests in 0.82.0 - The 0.82.0 performance commit changed the response finalization path to unconditionally `extend` global headers onto every response, including early-return responses from before-middleware. When `ALLOW_CORS` is...
diff --git a/integration_tests/cors_app.py b/integration_tests/cors_app.py new file mode 100644 index 000000000..a46b9958a --- /dev/null +++ b/integration_tests/cors_app.py @@ -0,0 +1,39 @@ +""" +Standalone Robyn app with ALLOW_CORS enabled, used by CORS integration tests. +Runs on a separate port (8083) so it doesn't ...
5
2
2
[{"id": "G0", "claim": "The readiness loop should check process.poll() so a dead or replaced listener on the port cannot make the test think the spawned server started.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "All requests HTTP calls in the new te...
null
sparckles__Robyn__288
sparckles/Robyn
288
defect
549723a89c0845472b58acf2039ba2af22c58ef2
5c201316089311e9350cdef54c466e0a2e380d1b
testing env support
**Description** This PR tests the parser function in env_populator.py from the previous PR, and also tests if variables are set correctly This PR fixes #287
diff --git a/integration_tests/test_env_populator.py b/integration_tests/test_env_populator.py new file mode 100644 index 000000000..0ab6adea0 --- /dev/null +++ b/integration_tests/test_env_populator.py @@ -0,0 +1,31 @@ +from robyn.env_populator import load_vars, parser +import pathlib +import os + +# content of test_t...
4
4
1
[{"id": "G0", "claim": "The new tests depend on the execution order of tests; a pytest fixture with setup/teardown should be used instead.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The single-letter variable names (d, p) in the tests should be chan...
null
sparckles__Robyn__333
sparckles/Robyn
333
defect
a99e8ccc45df0e8eaee0b90f71aca0e04cddd752
3c53aa667e2ccde4251da71456541459e1116a03
fix: header in const request bug and improve code architecture
**Description** This PR fixes #323 This is my suggestion for fixing the issue as well as improving the request handling - Add a `Response` struct created from the hashmap returned by the python functions in `execute_http_request`. I would have liked to return a `Response` directly from the py function by mappin...
diff --git a/integration_tests/base_routes.py b/integration_tests/base_routes.py index d7ed5a725..6b6239584 100644 --- a/integration_tests/base_routes.py +++ b/integration_tests/base_routes.py @@ -63,6 +63,16 @@ async def const_request_json(): return jsonify({"hello": "world"}) +@app.get("/const_request_header...
1
1
0
[{"id": "G0", "claim": "The crate types should be imported together as a single `use crate::types::{Request, Response}` line instead of being split across separate imports (a nit).", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}]
null
sparckles__Robyn__349
sparckles/Robyn
349
defect
e4cfe9a62f5106d2d629bc884f5ccae5979a8c29
c83101831c076c127d92bee3c57086cc2264d9d6
fix: better handling of route return type
**Description** I figured there are issues when you try to return something other than a string or a dict in a route. With this PR, you can return anything and most notably directly a `Response`. We may want to add it to the doc if it seems relevant to you @sansyrox ?
diff --git a/integration_tests/base_routes.py b/integration_tests/base_routes.py index 9d6b1f2a1..fd047417a 100644 --- a/integration_tests/base_routes.py +++ b/integration_tests/base_routes.py @@ -1,4 +1,5 @@ from robyn import Robyn, serve_file, jsonify, WS, serve_html +from robyn.robyn import Response from robyn.t...
1
1
0
[{"id": "G0", "claim": "The PR's new route return-type behaviour has no documentation yet, and the reviewer asks where it will be documented.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
sparckles__Robyn__375
sparckles/Robyn
375
defect
14af5d3ff78b50553703ea2a38e9117655d95e90
15f77baf0310b3c5e196922c38b9c47dccd206dd
Changed Response to use body: bytes
**Description** - Added ActixBytesWrapper to conform to pyclass and MessageBody This PR fixes #374 I know that my code is not optimal, but I wanted to see what the problem was and if i could get it to work. I don't have a lot of experience with Rust or Maturin / pyo3 and I get really confused on the lifetime...
diff --git a/integration_tests/base_routes.py b/integration_tests/base_routes.py index 48ed13c32..fae42c0bc 100644 --- a/integration_tests/base_routes.py +++ b/integration_tests/base_routes.py @@ -234,7 +234,7 @@ async def redirect_route(request): @app.get("/types/response") def response_type(request): - return ...
5
5
1
[{"id": "G0", "claim": "The Response constructor only accepts PyBytes, breaking compatibility with handlers that return str; its signature must change to take &PyAny and return PyResult, with ActixBytesWrapper::new downcasting to handle both bytes and str.", "category": "correctness", "verdict": "supported", "priority"...
null
sparckles__Robyn__377
sparckles/Robyn
377
defect
f163df950030a8db333dfe295cf5af448f3b4474
49da0a230445e6ea2f9222b38a02fa8ee4ef11b9
test: organize and add tests
**Description** I felt like the tests needed to be better organized, so it would be easier to write new tests and to check the unit test coverage. This PR does the following to achieve those goals: - Add a `utils.py` file that helps with requesting endpoints, and checks the status code and global headers of the res...
diff --git a/integration_tests/base_routes.py b/integration_tests/base_routes.py index 29ec66ebb..7758483a0 100644 --- a/integration_tests/base_routes.py +++ b/integration_tests/base_routes.py @@ -1,34 +1,32 @@ -import asyncio -import logging import os import pathlib from robyn import WS, Robyn, jsonify, serve_fil...
5
3
0
[{"id": "G0", "claim": "The new helper file should not be named `utils` because such files become a dump of unplaceable functions; rename it (e.g. to `http_methods_helpers` or `http_methods_testing_helpers`).", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1",...
null
sparckles__Robyn__382
sparckles/Robyn
382
defect
ef659202abeabf6483c47b9fa5b28eab21dd0991
b22c8f6139ded042b965eb033d792721301d8ee4
fix: return 500 status code when route raise
**Description** This PR fixes #381
diff --git a/integration_tests/base_routes.py b/integration_tests/base_routes.py index 48ed13c32..29ec66ebb 100644 --- a/integration_tests/base_routes.py +++ b/integration_tests/base_routes.py @@ -276,6 +276,16 @@ def file_download_async(): return serve_file(file_path) +@app.get("/sync/raise") +def sync_raise(...
1
1
0
[{"id": "G0", "claim": "Split the combined test_500_internal_server_error into two separate tests (one for the sync route, one for the async route) so the test logs are easier to read and the tests can be filtered with pytest -k.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
sparckles__Robyn__441
sparckles/Robyn
441
defect
b75350010e22ec92b7e5570956930845e103f1ca
74741bc312e222859bcabb23b2240e5a0dd4b7ee
feat: expose request/connection info
**Description** Implemented access of request information: method, path, host:port and protocol. In generally, it needs to implement more complicated logic in middlewares. <!-- Thank you for contributing to Robyn! Contributing Conventions: 1. Include descriptive PR titles. 2. Build and test your changes be...
diff --git a/integration_tests/base_routes.py b/integration_tests/base_routes.py index da0107731..ccad1d611 100644 --- a/integration_tests/base_routes.py +++ b/integration_tests/base_routes.py @@ -204,6 +204,45 @@ async def async_param(request): return id +@app.get("/sync/extra/*extra") +def sync_param_extra(r...
2
2
0
[{"id": "G0", "claim": "Create the Python strings/keys for the request-info dictionary using pyo3's intern! macro so they are built without reallocations.", "category": "performance", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G2", "claim": "Consider storing a custom struct (extending has...
null
sparckles__Robyn__497
sparckles/Robyn
497
defect
ec8cc7176d42e7a26e87a4d9732a52bbed3295b4
70f77372247aefec7293c23daa79d833fcd93c35
Routers
**Description** Adding routers to Robyn so it can be modularized This PR fixes #453 <!-- Thank you for contributing to Robyn! Contributing Conventions: 1. Include descriptive PR titles. 2. Build and test your changes before submitting a PR. Pre-Commit Instructions: Please ensure that you have run th...
diff --git a/robyn/__init__.py b/robyn/__init__.py index 7ca6af7a5..02ae36069 100644 --- a/robyn/__init__.py +++ b/robyn/__init__.py @@ -280,6 +280,16 @@ def inner(handler): return inner + def include_router(self, router): + self.router.routes.extend(router.router.routes) + self.middleware...
4
2
1
[{"id": "G0", "claim": "Write integration tests in the base_routes folder to demonstrate the working of the new subrouter concept.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The integration tests added on the branch do not work on Windows for an unk...
null
sparckles__Robyn__510
sparckles/Robyn
510
defect
54f6413d8a49a334684137da61f9d4cdf690d047
e02896678f2e25fa8a7b4ebc1e76b9119d4d051e
feat: add app.exception decorator to handle errors
**Description** This PR fixes #480 This PR adds the optional `app.exception` decorator under the Robyn app in order to allow catching exceptions raised in the routes and handle them gracefully. Example usage added in `base_routes.py` ```python @app.exception def handle_exception(error): return {"sta...
diff --git a/integration_tests/base_routes.py b/integration_tests/base_routes.py index ed0bfca35..ef4254702 100644 --- a/integration_tests/base_routes.py +++ b/integration_tests/base_routes.py @@ -586,6 +586,19 @@ async def post(request: Request): return {"status_code": 200, "body": body} +# ==== Exception...
2
2
2
[{"id": "G0", "claim": "The new app.exception feature should have integration tests added in the integration_tests folder.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The exception-handling tests should also cover async handlers and methods with requ...
null
sparckles__Robyn__530
sparckles/Robyn
530
defect
7dc232f4b8431baf3f7e27d6a2989d1c6b83e606
11ca437399350f8d075ce67146d24c632ee705ef
feat: add ip_addr field to Request object
**Description** This PR contributes towards #524 by adding the client's IP address to the request object. By having the client's IP address we can later on implement rate limiting per IP address. An example assert was added to the middleware base routes. <!-- Thank you for contributing to Robyn! Contribut...
diff --git a/integration_tests/base_routes.py b/integration_tests/base_routes.py index 56c8911af..d7db210ba 100644 --- a/integration_tests/base_routes.py +++ b/integration_tests/base_routes.py @@ -99,6 +99,7 @@ def sync_after_request(response: Response): def sync_middlewares(request: Request): assert "before" in ...
3
3
0
[{"id": "G0", "claim": "ip_addr should be initialized inside Request::from_actix_request rather than being assigned in the index handler in src/server.rs.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "ip_addr should be an Option<String> (exposed as None...
null
sparckles__Robyn__534
sparckles/Robyn
534
defect
65adc4d89d349fc99aab87297badbe7382c3c8bf
df379def3a9853b9011ee9e504cd717e814d0166
feat: allow before middlewares to return Response objects
**Description** This PR fixes #500
diff --git a/integration_tests/base_routes.py b/integration_tests/base_routes.py index ecff18b5c..ee6ad1a0a 100644 --- a/integration_tests/base_routes.py +++ b/integration_tests/base_routes.py @@ -123,6 +123,16 @@ async def async_middlewares(request: Request): return "async middlewares" +@app.before_request("/...
2
2
0
[{"id": "G0", "claim": "Add a docstring explaining what `should_check_response` does, and keep the http_method helpers homogeneous by adding the same parameter to all the helper function definitions.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G2", "claim": "...
null
sparckles__Robyn__580
sparckles/Robyn
580
defect
c1b354befbbeab54551c0a100cf2e5ac8d0ec0da
11288657fce691b85ed9b3c81bc9d24ffaa4c727
Description parameter
**Description** This replace the `body` parameter in the `response` object for `description` parameter. This PR fixes #552 <!-- Thank you for contributing to Robyn! Contributing Conventions: 1. Include descriptive PR titles. 2. Build and test your changes before submitting a PR. Pre-Commit Instruction...
diff --git a/integration_tests/base_routes.py b/integration_tests/base_routes.py index 696b96009..4eeea0344 100644 --- a/integration_tests/base_routes.py +++ b/integration_tests/base_routes.py @@ -125,7 +125,7 @@ def sync_before_request(request: Request): @app.after_request("/sync/middlewares") def sync_after_request...
1
1
0
[{"id": "G0", "claim": "The documentation in the docs folder (and the docs website) should be updated to match this pull request's body-to-description rename, since docs/features.md examples still call Response with the removed `body` parameter.", "category": "documentation", "verdict": "supported", "priority": "P2", "...
null
sparckles__Robyn__592
sparckles/Robyn
592
defect
2ffd591906c3e2715b3e922a8bc0e60e5bbc1b8d
e95906c6be8871b87fc523f7dfd68aa9c7d9fcc9
feat: allow adding routes without using decorator
**Description** This PR fixes #587 by making add_route public, while adding tests to validate the behavior. <!-- Thank you for contributing to Robyn! Contributing Conventions: 1. Include descriptive PR titles. 2. Build and test your changes before submitting a PR. Pre-Commit Instructions: Please ens...
diff --git a/integration_tests/base_routes.py b/integration_tests/base_routes.py index 696b96009..62d0a5baa 100644 --- a/integration_tests/base_routes.py +++ b/integration_tests/base_routes.py @@ -4,7 +4,16 @@ from collections import defaultdict from typing import Optional -from robyn import WS, Robyn, Request, Res...
3
2
0
[{"id": "G0", "claim": "Robyn's existing views feature may already serve a similar purpose, so the reviewer asks whether the new non-decorator add_route API is redundant.", "category": "design", "verdict": "uncertain", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "Since add_route is being exposed as ...
null
sparckles__Robyn__614
sparckles/Robyn
614
defect
565caa96621f38944e59ff922f3d40e1f47c7509
c36a99a3e887e07704efb7b35e55203814cf345b
Replace `url` parameter in the `app.start`
**Description** Replacing `url` parameter for `host` parameter in the `start` method. This PR fixes #613 <!-- Thank you for contributing to Robyn! Contributing Conventions: 1. Include descriptive PR titles. 2. Build and test your changes before submitting a PR. Pre-Commit Instructions: Please ensure...
diff --git a/robyn/__init__.py b/robyn/__init__.py index ca54a5e2f..3c8cc597b 100644 --- a/robyn/__init__.py +++ b/robyn/__init__.py @@ -159,24 +159,24 @@ def startup_handler(self, handler: Callable) -> None: def shutdown_handler(self, handler: Callable) -> None: self._add_event_handler(Events.SHUTDOWN, h...
4
3
0
[{"id": "G0", "claim": "No changes are showing up in the diff, which the reviewer flags as unexpected.", "category": "correctness", "verdict": "uncertain", "priority": "P3", "scope": "unclear"}, {"id": "G1", "claim": "Documentation covering the url-to-host change should be added, including the new_docs/documentation fo...
null
sparckles__Robyn__746
sparckles/Robyn
746
defect
a097fc7ccaef003b5bc6c7cead1fc5d4c1ae3a94
28607dfbc1a8526d0dbfa79c1e1c5141c2e8bd6e
chore: fix pyproject and poetry run test_server command
**Description** Hi, I came back to the project after some time and found a few things that didn't work, here is a fix for : - the `poetry run test_server` command, which failed because the `di_subrouter` import path was absolute and not relative - links in the `pyproject.toml` file, this should make the links app...
diff --git a/integration_tests/base_routes.py b/integration_tests/base_routes.py index 585cd40f8..611eaeb9d 100644 --- a/integration_tests/base_routes.py +++ b/integration_tests/base_routes.py @@ -820,6 +820,9 @@ def main(): class BasicAuthHandler(AuthenticationHandler): def authenticate(self, request: Re...
2
1
1
[{"id": "G0", "claim": "sansyrox asks whether the added call to set_token in BasicAuthHandler.authenticate would break production scenarios.", "category": "correctness", "verdict": "opposed", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The new __setitem__ method on Headers requires a documentation ...
null
sparckles__Robyn__870
sparckles/Robyn
870
defect
a37005d32af62f28b51e090e15c7c71eb80c5a29
9dc85cdd482f5bc0dbfcfa5ddc08202537c53611
feat: implement `set_cookie` function
**Description** This PR fixes #854
diff --git a/integration_tests/test_get_requests.py b/integration_tests/test_get_requests.py index a9ea1b67f..ba7accd8c 100644 --- a/integration_tests/test_get_requests.py +++ b/integration_tests/test_get_requests.py @@ -3,6 +3,8 @@ from requests import Response from integration_tests.helpers.http_methods_helpers i...
4
4
3
[{"id": "G0", "claim": "The pull request should include an end-to-end integration test that creates a new endpoint and checks the response, rather than only exercising Response.set_cookie in-process.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "set_co...
null
sparckles__Robyn__886
sparckles/Robyn
886
defect
2a68864a0da62007d5daa6feaa9f141b8c12c346
4bbc0a546d9bbcbdd7efea8a3c93bcc5bb4d34ac
feat: add QueryParams to WebSocket
**Description** This PR fixes #526
diff --git a/docs_src/src/pages/documentation/api_reference/websockets.mdx b/docs_src/src/pages/documentation/api_reference/websockets.mdx index 370f69895..c111d154a 100644 --- a/docs_src/src/pages/documentation/api_reference/websockets.mdx +++ b/docs_src/src/pages/documentation/api_reference/websockets.mdx @@ -182,6 +...
1
1
0
[{"id": "G0", "claim": "The docstring of the WebSocketConnector class should be updated to document the newly added query_params attribute.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
sparckles__Robyn__960
sparckles/Robyn
960
defect
e6872af923f4962bd61a3e6d9d429cd37b62283d
86fbaec60cf83f5545ebe085a81c6c4d7ffd17d9
feat: openapi response schema
## Description This PR fixes #930 ## Summary This PR does add the openapi response schema ## PR Checklist Please ensure that: - [x] The PR contains a descriptive title - [x] The PR contains a descriptive summary of the changes - [x] You build and test your changes before submitting a PR. - [ ] You ...
diff --git a/integration_tests/base_routes.py b/integration_tests/base_routes.py index 777907471..b72af29a6 100644 --- a/integration_tests/base_routes.py +++ b/integration_tests/base_routes.py @@ -858,7 +858,7 @@ class CreateItemBody(TypedDict): @app.post("/openapi_request_body") -def create_item(request, body=Cre...
1
1
0
[{"id": "G0", "claim": "Import TypedDict directly from the typing module in robyn/types.py rather than accessing it through the typing module namespace.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
sparklemotion__nokogiri__3166
sparklemotion/nokogiri
3,166
defect
da098df18b603a2703c57826529721fd14888fcc
3feca057554388d13c31b55ee325a6952cdb5a84
Fix typos
<!-- -- Thank you for contributing to Nokogiri! To help us prioritize, please take care to answer the -- questions below when you submit this pull request. -- -- The Nokogiri core team work off of `main`, so please submit all PRs based on the `main` -- branch. We generally will cherry-pick relevant bug fixes o...
diff --git a/CHANGELOG.md b/CHANGELOG.md index bdf46c8725a..c00ba6e7d32 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2178,7 +2178,7 @@ Repackaging of 1.5.1 with a gemspec that is compatible with older Rubies. [#631, * `XML::Node#namespace=` takes nil as a parameter * `XML::Node#xpath` returns things other than `N...
3
2
0
[{"id": "G0", "claim": "The pull request should not modify test/files/tlm.html, a test artifact used by tests, and its changes to that file should be removed.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The warning text changed to 'GC compact...
null
sparklemotion__nokogiri__3316
sparklemotion/nokogiri
3,316
defect
0df9227672759dfe312a02638589a446fa6551bf
238a58625a35c41be4569eb3340ce2a5f1290284
Make available the XPath path of the node where a SyntaxError occurred during Schema validation
**What problem is this PR intended to solve?** When validating an XML document with a schema it is difficult to impossible to know where the error happened in the document. With the path on the error, we can identify where in the document the error occurred. **Have you included adequate test coverage?** I beli...
diff --git a/ext/nokogiri/xml_syntax_error.c b/ext/nokogiri/xml_syntax_error.c index 0ccf43985dd..d0a3bf8d17e 100644 --- a/ext/nokogiri/xml_syntax_error.c +++ b/ext/nokogiri/xml_syntax_error.c @@ -44,6 +44,7 @@ noko__error_raise(void *ctx, xmlErrorConstPtr error) VALUE noko_xml_syntax_error__wrap(xmlErrorConstPtr err...
6
6
4
[{"id": "G0", "claim": "The new assertion in the file-validation test expects non-nil error paths, but error->node is NULL in that case, so a test case should be crafted where error->node is actually present.", "category": "testing", "verdict": "supported", "priority": "P0", "scope": "introduced"}, {"id": "G1", "claim"...
null
sparklemotion__nokogiri__3393
sparklemotion/nokogiri
3,393
defect
fdfb6dfc3eb05afd00594fe966f57e1e895284f0
26115995eee0d4e14390f3b923c80f087b084ab4
perf: html5 attribute parsing
## What problem is this PR intended to solve? Addressing quadratic performance of HTML5 attribute parsing as described in #2568 and https://github.com/rubys/nokogumbo/issues/144. Closes #2568 ### Some benchmarks <details><summary>Here is the benchmark script.</summary> ```ruby #!/usr/bin/env ruby r...
diff --git a/ext/nokogiri/extconf.rb b/ext/nokogiri/extconf.rb index 70e2fe0cc9b..bf3010d334a 100644 --- a/ext/nokogiri/extconf.rb +++ b/ext/nokogiri/extconf.rb @@ -1133,6 +1133,7 @@ def compile have_func("xmlCtxtSetOptions") # introduced in libxml2 2.13.0 have_func("xmlCtxtGetOptions") # introduced in libxml2 2.14.0...
3
1
1
[{"id": "G0", "claim": "append_property does not handle allocation failures (xmlMalloc, the name strdup/dict lookup, xmlNewDocText) the way libxml2's xmlNewNsProp does, so it should detect failure, free the newly allocated attribute and return NULL.", "category": "correctness", "verdict": "supported", "priority": "P1",...
null
sparsehash__sparsehash-c11__12
sparsehash/sparsehash-c11
12
defect
1748d7d691c5c0c7b473f9b2c0e6165191ca3fde
1553563f131c8452a51b0dfc1353745bb0f12164
Add dense_hashtable move assignment operator
This adds lacking move assignment operator based on `swap` method for `dense_hastable`. With that, compiler will generate corresponding operators for `dense_hash_set` and `dense_hash_map`.
diff --git a/sparsehash/internal/densehashtable.h b/sparsehash/internal/densehashtable.h index 537ec52..3348f46 100644 --- a/sparsehash/internal/densehashtable.h +++ b/sparsehash/internal/densehashtable.h @@ -779,6 +779,12 @@ class dense_hashtable { return *this; } + dense_hashtable& operator=(dense_hashtabl...
1
1
0
[{"id": "G0", "claim": "The self-assignment guard in the new move assignment operator can never be true because `ht` is an rvalue, so it should be replaced by an assert.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
sparsemat__sprs__252
sparsemat/sprs
252
defect
2932664855fb59382ed621fccd5267dcc4874129
f2a3fe810de0bd065540b0b2ef1e0f355056f564
More ergonomic slicing
As mentionned in #250, the slicing of middle matrices along the outer dimension is quite cumbersome to use, which is particularly visible in the matrix product implementation in `smmp.rs`. This PR tries to propose a more ergonomic API.
diff --git a/src/lib.rs b/src/lib.rs index 0bdc76fa..70f2c1f2 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -79,6 +79,7 @@ pub mod errors; pub mod indexing; pub mod io; pub mod num_kinds; +mod range; mod sparse; pub mod stack; diff --git a/src/range.rs b/src/range.rs new file mode 100644 index 00000000..1083ce9b -...
4
4
1
[{"id": "G0", "claim": "The new Range abstraction leaves out `RangeInclusive` and `RangeToInclusive`, with no reason given for excluding them.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The slicing methods are duplicated across the matrix types and t...
null
sparsemat__sprs__260
sparsemat/sprs
260
defect
be902d6ffeee6e69f01dee66f5c0c6a7b35ba0b8
eef715219b9888a677a95527086248f688572f25
Fix serde serialization
As noted in #256, there was a failure when serializing with bincode. This PR should fix it by implementing `Serialize` manually. See https://github.com/servo/bincode/issues/245 for the source of the issue.
diff --git a/sprs-tests/tests/tests.rs b/sprs-tests/tests/tests.rs index f1cec5e3..d5caa01a 100644 --- a/sprs-tests/tests/tests.rs +++ b/sprs-tests/tests/tests.rs @@ -45,6 +45,15 @@ mod serde_tests { let _mat: CsMat<u8> = serde_json::from_str(&json_mat).unwrap(); } + #[test] + fn roundtrip_matrix(...
1
1
1
[{"id": "G0", "claim": "The length hint passed to `serialize_struct(\"CsMatBase\", 3)` is 3 while six fields are serialized, so it should be 6.", "category": "correctness", "verdict": "supported", "priority": "P0", "scope": "introduced"}]
null
spastorino__dynosaur__72
spastorino/dynosaur
72
defect
8823e23254c94978dba1cbc9ee1dafb149686786
6c59e6bcb2f4e4030a3dc9078bc30c8f0481e886
Add new arced rced
r? @tmandry Closes #65
diff --git a/dynosaur/examples/default_trait.rs b/dynosaur/examples/default_trait.rs index 3d50369..40dbe57 100644 --- a/dynosaur/examples/default_trait.rs +++ b/dynosaur/examples/default_trait.rs @@ -26,9 +26,9 @@ fn static_dispatch(f: impl Foo) { } fn main() { - dyn_dispatch(&mut DynFoo::boxed(1)); + dyn_di...
1
1
0
[{"id": "G0", "claim": "The doc-comment example of the generated inherent impl is missing the newly added constructors (new_arc/new_rc).", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
spdk__spdk__41
spdk/spdk
41
defect
6c5f05f177c793bcb53bdd3542a6a0ee03ad8dbc
fa1497eb5a9c8298c7e4def2f63d89f2ea570d25
Fix some cppcheck errors on lib/bdev & lib/iscsi & lib/scsi.
Fixed error types: 1 nullPointerRedundantCheck; 2 unsignedLessThanZero; 3 arithOperationsOnVoidPointer; 4 invalidPrintfArgType_sint; 5 arrayIndexThenCheck
diff --git a/lib/bdev/malloc/blockdev_malloc.c b/lib/bdev/malloc/blockdev_malloc.c index 5d6081a1500..136b582cc70 100644 --- a/lib/bdev/malloc/blockdev_malloc.c +++ b/lib/bdev/malloc/blockdev_malloc.c @@ -126,7 +126,7 @@ blockdev_malloc_read(struct malloc_disk *mdisk, struct copy_task *copy_req, SPDK_TRACELOG(SPDK_TR...
1
1
0
[{"id": "G0", "claim": "The void pointer arithmetic in blockdev_malloc.c should not be rewritten as explicit casts, because the pattern is an intentional GCC extension used throughout the code and changing it in just this file makes the code harder to read — split out the blockdev_malloc.c changes so the rest can be me...
null
spdx__tools-java__174
spdx/tools-java
174
defect
76a2dfac221c962cc7b09bf8f2a59bb8237b9fc1
75387b976a6302cfb0939a8e7c3f32262c8f3845
Remove unused code + add asserts in OwlToXSDTest.java test case
- Remove unused imports and debug code in src/test/java/org/spdx/tools/schema/OwlToXSDTest.java - Add few test assertions - Rename spdx-2-2-revision-8-onotology.owl.xml ("onotology") -> spdx-2-2-revision-8-ontology.owl.xml ("ontology")
diff --git a/src/test/java/org/spdx/tools/schema/OwlToXSDTest.java b/src/test/java/org/spdx/tools/schema/OwlToXSDTest.java index 9ed73f5..20219df 100644 --- a/src/test/java/org/spdx/tools/schema/OwlToXSDTest.java +++ b/src/test/java/org/spdx/tools/schema/OwlToXSDTest.java @@ -2,7 +2,6 @@ import java.io.File; import...
1
1
0
[{"id": "G0", "claim": "The leftover debugging code should be removed entirely — the whole try statement (lines 39-43) that writes the result to a StringWriter, not just its two unused variable lines.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "pre_existing"}]
null
spec-first__connexion__1075
spec-first/connexion
1,075
defect
67f48ae24da7d868a12dcfde6cfe6e1df4cbd75e
9104ccecfc33db23fb4df69ca4a5fd818961b433
enable empty security definition
This allows to use optional authentication and provide different responses to authenticated users via the same API-Endpoint. Fixes #1036 Changes proposed in this pull request: - Enable optimal authentication - Provide different information to logged in customers via the same API endpoint
diff --git a/connexion/decorators/security.py b/connexion/decorators/security.py index 5ce399ebf..41880455b 100644 --- a/connexion/decorators/security.py +++ b/connexion/decorators/security.py @@ -287,6 +287,17 @@ def wrapper(request, required_scopes): return wrapper +def verify_none(): + """ + :rtype: t...
2
1
0
[{"id": "G0", "claim": "The typo \"propper\" in the openapi.yaml and swagger.yaml test fixtures should be corrected to \"proper\".", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The author should point to a section in the OpenAPI or Swagger specif...
null
spec-first__connexion__1077
spec-first/connexion
1,077
defect
67f48ae24da7d868a12dcfde6cfe6e1df4cbd75e
9534ebb8d4cfc5cea9bb8bea0dd79016ec9c498f
Pop apiKey from query parameters in security decorator to fix #470
Fixes: Fixes Bad Request error when ApiKey authentication is used with the apiKey query parameter, and strict validation is enabled. The corresponding open issue is https://github.com/zalando/connexion/issues/470. Changes proposed in this pull request: - Pop apiKey from the query parameters before validation.
diff --git a/connexion/operations/abstract.py b/connexion/operations/abstract.py index f009f5991..6a19da6bf 100644 --- a/connexion/operations/abstract.py +++ b/connexion/operations/abstract.py @@ -1,5 +1,6 @@ import abc import logging +from copy import deepcopy import six from connexion.operations.secure import S...
2
2
2
[{"id": "G0", "claim": "The security scheme name 'ApiKeyAuth' should not be hardcoded, because it is a user-supplied name for a securityScheme of type apiKey.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "Adding the apikey parameter to the spec fro...
null
spec-first__connexion__1088
spec-first/connexion
1,088
defect
67f48ae24da7d868a12dcfde6cfe6e1df4cbd75e
0e0ab41ab2837a07ca8d32e69dff914a1f141213
Fixed mocking function not working with examples under numeric status…
… codes (e.g., 200) , due to status code string being casted as integer and not raising a ValueError. Included tests that break without the patch (it was testing for 'default' only, but not for numeric codes like '200') Fixes #1087 . Changes proposed in this pull request: - Adding check on `examples` s...
diff --git a/connexion/utils.py b/connexion/utils.py index 72c80390e..8d626f40e 100644 --- a/connexion/utils.py +++ b/connexion/utils.py @@ -70,7 +70,11 @@ def deep_get(obj, keys): if not keys: return obj try: - return deep_get(obj[int(keys[0])], keys[1:]) + if type(obj) == dict: + ...
3
3
0
[{"id": "G0", "claim": "Use `isinstance(obj, dict)` instead of `type(obj) == dict` in deep_get.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The try/except ValueError fallback in deep_get is no longer needed now that the new code branches expl...
null
spec-first__connexion__1130
spec-first/connexion
1,130
defect
ab430afaf51e2ad901b1a5afe0cf9fbeb42c304c
376f2090a6a5b33f87e39f275e3cf9b73b960dce
match all but whitespaces inside object keys
Fixes #1129 . Changes proposed in this pull request: - inside of a exploded `deepObject`, the keys can be any character. Especially dots need to be allowed. sanitation does not apply, because it will result in an object key, not a python var name.
diff --git a/connexion/decorators/uri_parsing.py b/connexion/decorators/uri_parsing.py index 4ed665d01..7590abe06 100644 --- a/connexion/decorators/uri_parsing.py +++ b/connexion/decorators/uri_parsing.py @@ -188,7 +188,7 @@ def _make_deep_object(k, v): root_key = k.split("[", 1)[0] if k == root_key: ...
3
3
2
[{"id": "G0", "claim": "The new pattern needs at least two characters between the brackets (one non-space plus one or more others), so one-character keys like [h] that matched before the change no longer match.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "...
null
spec-first__connexion__1170
spec-first/connexion
1,170
defect
ea45242604255799ed6fca6539a59f1df53e435c
e70f6e5a56d9f6bdc98c1527490d1ea9b0dea9e3
openapi: remove JSON body second validation and type casting
JSON body is already validated using jsonschema. There was also some type casting but it was wrong: e.g. not recurring deeply into dicts and lists, relying on existence of "type" in schema (which is not true e.g. if oneOf is used). Anyway, the only reason why types should be casted is converting integer values to f...
diff --git a/connexion/operations/openapi.py b/connexion/operations/openapi.py index 7f5d0de3a..176eb9669 100644 --- a/connexion/operations/openapi.py +++ b/connexion/operations/openapi.py @@ -9,6 +9,7 @@ from connexion.operations.abstract import AbstractOperation from ..decorators.uri_parsing import OpenAPIURIPars...
2
1
1
[{"id": "G0", "claim": "Why is the schema-based typed-value conversion still applied for form content types when the pull request removed it for JSON bodies?", "category": "design", "verdict": "uncertain", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "Convert the oneOf example application into a test...
null
spec-first__connexion__126
spec-first/connexion
126
defect
bbe7a44606cb85bcc552f606c39cbc9fd2c8a7bd
8a3c38177f307f5f0aa353462d5030bf1f1e4d31
Added support for circular references and additionalProperties
Connexion doesn't currently support references in many places explicitly supported by the spec. A reference in a typed map (e.g. the example under Model with Map/Dictionary Properties at http://swagger.io/specification/) would fail. Also, circular references, like those used in a tree structure, would also fail. Tho...
diff --git a/connexion/decorators/response.py b/connexion/decorators/response.py index 769f897f7..f5f295f81 100644 --- a/connexion/decorators/response.py +++ b/connexion/decorators/response.py @@ -45,10 +45,11 @@ def validate_response(self, data, status_code, headers, mimetype): if not response_definitions: ...
5
3
0
[{"id": "G0", "claim": "The check_references method is not immediately clear and needs a docstring explaining what it does.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "More unit tests are needed that really test the schema logic itself, i.e. no...
null
spec-first__connexion__1306
spec-first/connexion
1,306
defect
443bd200873d1a49d5f06767cb57e8226edfd447
b07197f2001deb68fcb106cc1eb4d9f95a591996
More liberal flask number converters for float and int in paths
This change installs more liberal flask converters for `float` and `int`. These don't try to enforce a "single representation" of paths but instead try to convert the numbers that callers pass in. This is the minimal change to get this effect and installs the custom number converters where the custom JSON converter ...
diff --git a/connexion/apps/flask_app.py b/connexion/apps/flask_app.py index a92e7f4ca..835670345 100644 --- a/connexion/apps/flask_app.py +++ b/connexion/apps/flask_app.py @@ -27,6 +27,8 @@ def __init__(self, import_name, server='flask', **kwargs): def create_app(self): app = flask.Flask(self.import_name...
2
2
0
[{"id": "G0", "claim": "The test handlers test_get_someint and test_get_somefloat should use Python f-strings instead of the '%s %g' %-format returns in tests/fakeapi/hello/__init__.py.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The request ...
null
spec-first__connexion__1388
spec-first/connexion
1,388
defect
df7ec12f4548438636ce5a5a6704fccce2dbc2dc
95c0538d18b35ad3188a9832d0fa50621f01ac7e
Upgrade isort==5.9.1
Fixes #1382 Fixes #1384 Fixes #1387 https://pypi.org/project/isort
diff --git a/connexion/decorators/parameter.py b/connexion/decorators/parameter.py index 2cdb5a0f5..463d39e49 100644 --- a/connexion/decorators/parameter.py +++ b/connexion/decorators/parameter.py @@ -11,7 +11,6 @@ from ..lifecycle import ConnexionRequest # NOQA from ..utils import all_json - logger = logging.get...
2
2
2
[{"id": "G0", "claim": "isort is failing in the tests because it treats aiohttp as local (due to the tests/aiohttp directory); passing aiohttp as a --thirdparty can fix this.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The pull request's import c...
null
spec-first__connexion__1408
spec-first/connexion
1,408
defect
2229831e80f55e1f8bfb536f73bc77013566df21
795ad0a0db29bce64f3a1961fb24c7f83e04414a
fix-square bracket : V1
Fixes # . Fix square bracket in query params. Example : `orderBy[eq]`. Its a quick fix to permit square bracket in query params, if they are define in the schema. For query params who are not in the schema. Do default computation for deep object. Changes proposed in this pull request: - Modify `sanitiz...
diff --git a/connexion/decorators/parameter.py b/connexion/decorators/parameter.py index 98cc3b843..730f3810f 100644 --- a/connexion/decorators/parameter.py +++ b/connexion/decorators/parameter.py @@ -65,7 +65,7 @@ def parameter_to_arg(operation, function, pythonic_params=False, consumes = operation.consumes ...
4
4
2
[{"id": "G0", "claim": "The PR should add a test that shows the expected behavior for parsing parameters with square brackets.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The import in tests/decorators/test_uri_parsing.py is not in alphabetic order a...
null
spec-first__connexion__1415
spec-first/connexion
1,415
defect
69e289bb77c39a2d668fd4858df77aff30fe5722
b13fb10bed1f635b9202f3d625210e1b412e2c48
#1256 AioHttpAPP.get_root_path return Path object
Fixes #1256 Changes proposed in this pull request: - update AioHTTPAPP get_root_path from str to Path - Added unit tests
diff --git a/connexion/apps/aiohttp_app.py b/connexion/apps/aiohttp_app.py index a92044dc1..2db800fb6 100644 --- a/connexion/apps/aiohttp_app.py +++ b/connexion/apps/aiohttp_app.py @@ -4,6 +4,7 @@ import logging import os.path +import pathlib import pkgutil import sys @@ -29,7 +30,8 @@ def create_app(self): ...
2
2
0
[{"id": "G0", "claim": "In both branches of AioHttpAPP.get_root_path, use the pathlib idiom (pathlib.Path(...).resolve().parent) instead of building the path with os.path.dirname(os.path.abspath(...)) and wrapping it in pathlib.Path.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "i...
null
spec-first__connexion__1425
spec-first/connexion
1,425
defect
2dfd57dafbedff99c0a32616079f80c21b9de6d9
bbde2b45039ac4939001a03c93d0d88aa0b3b599
#1424: add keywords to the list of pythonic words
Fixes #1424 . Changes proposed in this pull request: - Add Python's keywords to the list of reserved words for underscoring.
diff --git a/connexion/decorators/parameter.py b/connexion/decorators/parameter.py index 98cc3b843..23db1f743 100644 --- a/connexion/decorators/parameter.py +++ b/connexion/decorators/parameter.py @@ -5,6 +5,7 @@ import builtins import functools import inspect +import keyword import logging import re from typing ...
1
1
0
[{"id": "G0", "claim": "Use the keyword.iskeyword() function instead of building an all_reserved list, checking snake membership in builtins.__dict__ or via keyword.iskeyword().", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
spec-first__connexion__147
spec-first/connexion
147
defect
43cc1cf5a64c9ecd92cd97890195e04be7e00cc8
b2caf7e9fc45daf6b86b91df21b4c978568315ed
#146 allow using TOKENINFO_URL env var (OAuth2 token info)
Fixes #146
diff --git a/.gitignore b/.gitignore index 2d8a3eb3c..0289d191c 100644 --- a/.gitignore +++ b/.gitignore @@ -8,3 +8,4 @@ htmlcov/ *.pyc .eggs .cache/ +*.swp diff --git a/README.rst b/README.rst index 83ae43c85..e01e97f99 100644 --- a/README.rst +++ b/README.rst @@ -147,7 +147,7 @@ Authentication and Authorization I...
1
1
0
[{"id": "G0", "claim": "When HTTP_TOKENINFO_URL is set, a warning message should be logged notifying the user that they should use TOKENINFO_URL instead.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
spec-first__connexion__1474
spec-first/connexion
1,474
defect
40d9dad984e13113accade2ef44c90fe5ed00e79
da1905b715320826cd0c768df5cfe9387c59f335
Rework required_scopes checking
Fixes #1423 . Moves the required_scopes argument as current approach assumes there is one possible set of scopes per operation/security object. I have changed the tested behaviour for [this test](https://github.com/spec-first/connexion/blob/main/tests/api/test_secure_api.py#L99). If there is optional auth, if a...
diff --git a/connexion/operations/secure.py b/connexion/operations/secure.py index bc16cb914..5dbd90d91 100644 --- a/connexion/operations/secure.py +++ b/connexion/operations/secure.py @@ -75,7 +75,6 @@ def security_decorator(self): return self._api.security_handler_factory.security_passthrough ...
5
4
3
[{"id": "G0", "claim": "Remove the TODO comments this pull request adds to connexion/security/security_handler_factory.py (the OR-fashion OAuth note and the which-errors-to-catch note).", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "verify_securit...
null
spec-first__connexion__1497
spec-first/connexion
1,497
defect
41c19c11272b2878ca58a4b2a6c44b67e3d10c8c
f0485fe407695a56c07a5b12d6e8945309a8fafd
Add routing middleware
Part of https://github.com/spec-first/connexion/issues/1489 This PR adds a routing middleware, which adds the connexion operation to the scope passed to the next middlewares. The middleware is implemented with a starlette router on which the api endpoints are registered. For all other routes, the router acts ass ...
diff --git a/connexion/apis/__init__.py b/connexion/apis/__init__.py index e7d0778bd..da5a4bfdc 100644 --- a/connexion/apis/__init__.py +++ b/connexion/apis/__init__.py @@ -13,4 +13,5 @@ """ -from .abstract import AbstractAPI, AbstractSwaggerUIAPI # NOQA +from .abstract import (AbstractAPI, AbstractMinimalAPI, #...
6
5
3
[{"id": "G0", "claim": "Subclassing starlette.BaseHTTPMiddleware has known problems, as documented in the linked starlette issue and PR, so the middleware should avoid it.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "unclear"}, {"id": "G1", "claim": "The argument docstrings of AbstractMin...
null
spec-first__connexion__1502
spec-first/connexion
1,502
defect
ca70b16ff5e5f9c1a321c629db771968d94e8f0d
f5d7a8b9b5a17fbdc839b69c4a7154c2a006eb65
Add empty connexion middleware
Accidentally merged #1492 by rebasing on the wrong branch and pushing. Reverted the previous merge, and opening this PR instead.
diff --git a/.github/workflows/pipeline.yml b/.github/workflows/pipeline.yml index 413197ef1..6d85a4c77 100644 --- a/.github/workflows/pipeline.yml +++ b/.github/workflows/pipeline.yml @@ -9,7 +9,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: [3.6, 3.7, 3.8, 3.9] + ...
2
1
0
[{"id": "G0", "claim": "The docstring typo \"list o middlewares\" in the new ConnexionMiddleware class should read \"list of middlewares\" (requested directly by M001 and via a suggestion block by M004).", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim...
null
spec-first__connexion__1568
spec-first/connexion
1,568
defect
64f42547dc76316c09d53ce57484beb03206a38a
0a200c23ffbc2f82f3237edae6a00602b4130985
Removed internal variable pass_context_arg_name
Fixes #1532 . Changes proposed in this pull request: - I removed the parameter _pass_context_arg_name_ passed internally as asked from the various constructors, and left in the _SecurityHandlerFactory_ a constant called **_context_kw_**, following the same pattern of _required_scopes_kw_. I don't know if...
diff --git a/connexion/apis/abstract.py b/connexion/apis/abstract.py index 31e12d4af..ab74d8f87 100644 --- a/connexion/apis/abstract.py +++ b/connexion/apis/abstract.py @@ -134,22 +134,16 @@ def __init__( *args, resolver_error_handler: t.Optional[t.Callable] = None, debug: bool = False, - ...
5
4
3
[{"id": "G0", "claim": "The failing tests should be updated so that they pass.", "category": "testing", "verdict": "supported", "priority": "P0", "scope": "introduced"}, {"id": "G1", "claim": "A test should be added covering a view function that has a parameter called `context`, which collides with the new context kwar...
null
spec-first__connexion__1653
spec-first/connexion
1,653
defect
969c1460e653bb2948c1643a80141c565c1038a2
184f1aed6c722061981255108457dd647c6a0b87
Create abstract validator classes
As promised, an `AbstractRequestBodyValidator` class. This has 2 advantages: - Groups all common code - Provides a base for custom validators Looking at the remaining logic in the subclasses, I'm quite happy with the current abstraction. A lot of the complexity comes from substituting the default body when no body...
diff --git a/connexion/json_schema.py b/connexion/json_schema.py index 1cf26aa96..6ab214fa7 100644 --- a/connexion/json_schema.py +++ b/connexion/json_schema.py @@ -107,6 +107,13 @@ def _do_resolve(node): return res +def format_error_with_path(exception: ValidationError) -> str: + """Format a `ValidationErr...
4
1
1
[{"id": "G0", "claim": "A similar base class should be provided for the `ResponseBodyValidator`s.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The `__init__` arguments for the validators are fixed in `request_validation`, so it does not really make sen...
null