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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Kinto__kinto__1735 | Kinto/kinto | 1,735 | defect | c4199ed16b83fb798e1d4ccdb6869a9a52e3f96b | c8847da9064bb253f40e1734504788a503d1e777 | Raise error if accounts is misconfigured (fixes #1734) | Fixes #1734 | diff --git a/CHANGELOG.rst b/CHANGELOG.rst
index 3da38dc63..8627c108b 100644
--- a/CHANGELOG.rst
+++ b/CHANGELOG.rst
@@ -11,6 +11,12 @@ This document describes changes between each past release.
- Include Python 3.7 support.
+**Bug fixes**
+
+- Raise a configuration error if the ``kinto.plugin.accounts`` is includ... | 1 | 1 | 0 | [{"id": "G0", "claim": "The comment typo 'mentionned' should be corrected and 'in docs' should read 'in config', since the check inspects settings rather than documentation.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
Kinto__kinto__1752 | Kinto/kinto | 1,752 | defect | 983a003b2e37fcf3bab1aaf81f0d7a83390fa354 | 22d38c7d7471478941479b8d994767844711ea24 | #1647: Deleting a collection doesn't delete access_control_entrries for its children | Fixes #1647
- [ ] Add documentation.
- [x] Add tests.
- [ ] Add a changelog entry.
- [x] Add your name in the contributors file.
- [ ] If you changed the HTTP API, update the [API_VERSION](https://github.com/Kinto/kinto/blob/master/kinto/__init__.py#L15) constant and add an API changelog entry [in the docs](http... | diff --git a/kinto/views/collections.py b/kinto/views/collections.py
index 8c3528d0e..e27388b89 100644
--- a/kinto/views/collections.py
+++ b/kinto/views/collections.py
@@ -56,4 +56,4 @@ def on_collections_deleted(event):
with_deleted=False)
storage.purge_deleted(collection_id=None,... | 4 | 3 | 0 | [{"id": "G0", "claim": "The test should create and delete the data within the test function itself rather than relying on setUp to do it.", "category": "testing", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The tests should also make sure that the collection's own permissions ... | null |
Kinto__kinto__1787 | Kinto/kinto | 1,787 | defect | 2a4b42832134cbd71e198ae2f3be06058f4fe255 | 40e3851ebc4ea10412d3ef0f614f834049c820ed | Raises 400 invalid request when field parameters contain a NUL character | Fixes #1704
- [x] Add tests.
- [ ] Add a changelog entry.
- [ ] Add your name in the contributors file.
As suggested I discussed I implemented a fix for the null char.
I did however not include this in the
``` native_value() ```
function as this function is never called on the query parameters, and in... | diff --git a/kinto/core/resource/__init__.py b/kinto/core/resource/__init__.py
index 6d2f391b5..cf5e32bfc 100644
--- a/kinto/core/resource/__init__.py
+++ b/kinto/core/resource/__init__.py
@@ -1022,6 +1022,9 @@ def _extract_filters(self):
if has_invalid_value:
raise_invalid(self.re... | 4 | 4 | 1 | [{"id": "G0", "claim": "The NUL check added in _extract_filters guards only the field name, so a NUL character in the query value would not be rejected.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The new tests should not involve PostgreSQLTest s... | null |
Kinto__kinto__1814 | Kinto/kinto | 1,814 | defect | 127def80fdb6af3168c04b4506fab3d953929a5b | e07e996c3bf9da622b1db9af23175c39f2713442 | Fix record_create_principals settings not taken into account | Fixes #1813
- [x] Add tests.
- [x] Add a changelog entry.
| diff --git a/kinto/core/authorization.py b/kinto/core/authorization.py
index 73ec8840c..364226045 100644
--- a/kinto/core/authorization.py
+++ b/kinto/core/authorization.py
@@ -171,7 +171,10 @@ def check_permission(self, principals, bound_perms):
if not bound_perms:
bound_perms = [(self.resource_n... | 2 | 2 | 1 | [{"id": "G0", "claim": "A specific test should be added to cover the pull request's change (its code coverage should not rely on incidental paths).", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The change should also handle permissions like `account:cr... | null |
Kinto__kinto__1925 | Kinto/kinto | 1,925 | defect | f9374e931e1f73c5f6e1417364d5ce13c5cd87b9 | 2a72a655a3af7188b6a062f938ce65d848f7fdda | Remove resource.mapping support | Fixes #1904
- [ ] Add documentation.
- [ ] Add tests.
- [x] Add a changelog entry.
- [ ] Add your name in the contributors file.
- [ ] If you changed the HTTP API, update the [API_VERSION](https://github.com/Kinto/kinto/blob/master/kinto/__init__.py#L15) constant and add an API changelog entry [in the docs](htt... | diff --git a/CHANGELOG.rst b/CHANGELOG.rst
index 9d803efc7..3bd105ecb 100644
--- a/CHANGELOG.rst
+++ b/CHANGELOG.rst
@@ -12,6 +12,7 @@ This document describes changes between each past release.
**Internal changes**
+- Remove depreciation warning for `mapping` (#1904)
- Fix depreciated warn method (#1903)
- Use f... | 1 | 1 | 1 | [{"id": "G0", "claim": "The deprecated `.mapping` fallback should be removed too — the PR should stop supporting the `.mapping` attribute on the resource class, not just remove the deprecation warning.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}] | null |
Kinto__kinto__1943 | Kinto/kinto | 1,943 | defect | 11fec5470a485ed7f673163af6d6592156365ca7 | cc00f88afdf3e386add41392e8735c2b536b9a7d | Add cache flush command (fixes #1785) | Fixes #1785
- [x] Add documentation.
- [x] Add tests.
- [x] Add a changelog entry.
- [x] Add your name in the contributors file.
this is supposed to fix #1785 , still in the works, opened for maintainer reference. | diff --git a/kinto/__main__.py b/kinto/__main__.py
index 880d74b90..ac252f7a5 100644
--- a/kinto/__main__.py
+++ b/kinto/__main__.py
@@ -29,6 +29,7 @@ def main(args=None):
"start",
"migrate",
"delete-collection",
+ "flush",
"version",
"rebuild-quotas",
"creat... | 8 | 7 | 4 | [{"id": "G0", "claim": "The new command should be named `flush-cache` rather than `flush` in the commands tuple, the subcommand dispatch, and the `which_command` branch.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Remove the commented-out `#action=\".... | null |
Kinto__kinto__1988 | Kinto/kinto | 1,988 | defect | dc84b2bf2dcf61e8a25d796bffac7506e678f3c8 | 658aac6a4a919c2b649ce378fd6387c99be71872 | Encode token in base64 for url safety. | Refs: https://github.com/Kinto/kinto-admin/pull/715
Encode the openid payload as base64 in order to make it URL-safe
- [x] Add documentation.
- [x] Add tests.
- [x] Add a changelog entry. | diff --git a/CHANGELOG.rst b/CHANGELOG.rst
index 2dfa6758f..05568b41e 100644
--- a/CHANGELOG.rst
+++ b/CHANGELOG.rst
@@ -6,7 +6,7 @@ This document describes changes between each past release.
12.1.0 (unreleased)
-------------------
-- Nothing changed yet.
+- Update Kinto OpenID plugin to redirect with a base64 JSON... | 1 | 1 | 1 | [{"id": "G0", "claim": "The changelog entry the PR added should note that the redirect change is breaking and at least mention the minimum required version of kinto-admin.", "category": "documentation", "verdict": "supported", "priority": "P1", "scope": "introduced"}] | null |
Kinto__kinto__1994 | Kinto/kinto | 1,994 | defect | a4cd7c6413d1d7809fe02670c0224959390dc25d | 4c8f9271cae715bcc825114c1dbe1620bd1932c1 | Fix modification of mutable default value | Hi,
I came across what I think is a bug when looking at the alerts for this project on [LGTM.com](https://LGTM.com) (full disclosure: I work on the Python analysis there).
Essentially, default parameter values in Python are shared between all invocations of a function. This means that if a default value is mutabl... | diff --git a/kinto/schema_validation.py b/kinto/schema_validation.py
index dfcefe375..db7f09748 100644
--- a/kinto/schema_validation.py
+++ b/kinto/schema_validation.py
@@ -68,7 +68,9 @@ def validate(data, schema):
return _schema_cache[cache_key].validate(data)
-def validate_schema(data, schema, id_field, igno... | 2 | 2 | 0 | [{"id": "G0", "claim": "Add a CHANGELOG entry for the fix (and later also update the CONTRIBUTORS file).", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The tests never exercise validate_schema's default ignore_fields; either add a test that uses i... | null |
Kinto__kinto__2220 | Kinto/kinto | 2,220 | defect | f27adfb76778fc929299bceaa2a661c897a5dd3c | 1f609c19724634e7c972e2d84e6d5609fe09d976 | If Content-Type cannot be read, it leads to a CORS error. | https://developer.mozilla.org/en-US/docs/Web/HTTP/Cross-Origin_Resource_Policy_(CORP)
Allow CORS to read Content-Type
- [x] Add documentation.
- [x] Add tests.
- [x] Add a changelog entry.
- [x] Add your name in the contributors file.
- [x] If you changed the HTTP API, update the [API_VERSION](https://github.... | diff --git a/CHANGELOG.rst b/CHANGELOG.rst
index 4a2643775..a8981ee61 100644
--- a/CHANGELOG.rst
+++ b/CHANGELOG.rst
@@ -9,6 +9,7 @@ This document describes changes between each past release.
**Bug fixes**
- Fix unexpected exception in ``/__version__`` endpoint
+- Add ``Content-Type`` to default_cors_headers (fixes... | 1 | 1 | 0 | [{"id": "G0", "claim": "The changelog entry should not use \"fixes\" to refer to the issue, since #2220 is this pull request's own number.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
Kinto__kinto__2307 | Kinto/kinto | 2,307 | defect | 2247cb781396c1a5f936681951e8e71e9fd244e4 | 4560882c0c4048b9c32375e11c3613b959b0d7b6 | Add ``Content-Security-Policy`` header and report URI (fixes #2303) | fixes #2303 | diff --git a/CHANGELOG.rst b/CHANGELOG.rst
index c414a9dde..746702a38 100644
--- a/CHANGELOG.rst
+++ b/CHANGELOG.rst
@@ -6,6 +6,10 @@ This document describes changes between each past release.
13.6.0 (unreleased)
-------------------
+**New Features**
+
+- Add ``Content-Security-Policy`` header and report URI (fixes... | 2 | 2 | 0 | [{"id": "G0", "claim": "The CSP policy string in setup_csp_headers is built as implicit concatenation of string fragments with trailing spaces and could simply be one plain string literal.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The allow... | null |
Kinto__kinto__2392 | Kinto/kinto | 2,392 | defect | 91d4833505d8f2e28e599f5e4b53de8a09038ba0 | 47521da8850792d93b6503c66bc830e5f9e53f87 | Parse large exponents as strings | Fixes #2312
- [ ] Add documentation.
- [x] Add tests.
- [x] Add a changelog entry.
- [ ] Add your name in the contributors file.
- [ ] If you changed the HTTP API, update the [API_VERSION](https://github.com/Kinto/kinto/blob/master/kinto/__init__.py#L15) constant and add an API changelog entry [in the docs](htt... | diff --git a/CHANGELOG.rst b/CHANGELOG.rst
index fb8d3dfde..d251ad5dc 100644
--- a/CHANGELOG.rst
+++ b/CHANGELOG.rst
@@ -10,6 +10,7 @@ This document describes changes between each past release.
- History entries datetimes now carry timezone information
- Fix ``kinto init`` command (#2375)
+- Fix issue parsing certa... | 1 | 1 | 0 | [{"id": "G0", "claim": "The changelog entry should read \"Fix float strings parsing in certain URL query parameters. (#2392)\" instead of \"Fix issue parsing certain strings in URL query parameters\".", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
Kinto__kinto__2615 | Kinto/kinto | 2,615 | defect | 87e357ae3c6a3d4694e130305990d729fae361a9 | 5ea7d6048b3a090c7de7521154d87216e25f04a3 | Distinguish readonly errors in storage backend | While working on https://github.com/Kinto/kinto-changes/pull/210 I realized we didn't have specific exceptions for the readonly errors. | diff --git a/CHANGELOG.rst b/CHANGELOG.rst
index ed321b1d8..9b21d7e37 100644
--- a/CHANGELOG.rst
+++ b/CHANGELOG.rst
@@ -6,7 +6,9 @@ This document describes changes between each past release.
14.0.2 (unreleased)
-------------------
-- Nothing changed yet.
+**Internal Changes**
+
+- Distinguish readonly errors in st... | 3 | 3 | 1 | [{"id": "G0", "claim": "The ValueError(\"poppp\") call must be removed from Model.timestamp — it is leftover debugging code.", "category": "correctness", "verdict": "supported", "priority": "P0", "scope": "introduced"}, {"id": "G1", "claim": "While touching this code, merge the adjacent string-literal pair \"Cannot ini... | null |
Kinto__kinto__2647 | Kinto/kinto | 2,647 | defect | ae11af12383cc70377d7b30c613184de504cb93d | 2383d6795dc0d9b1601a37d58c300c57331f2724 | Default bucket salt | Fixes https://github.com/Kinto/kinto/issues/1535 and #881
- [x] Add documentation.
- [x] Add tests.
- [x] Add a changelog entry.
- [x] Add your name in the contributors file.
- [x] If you changed the HTTP API, update the [API_VERSION](https://github.com/Kinto/kinto/blob/master/kinto/__init__.py#L15) constant and... | diff --git a/CONTRIBUTORS.rst b/CONTRIBUTORS.rst
index f42d11d2a..0ad6c7701 100644
--- a/CONTRIBUTORS.rst
+++ b/CONTRIBUTORS.rst
@@ -104,3 +104,4 @@ Contributors
* Jeff Schobelock <jswhatnot15@gmail.com>
* Victor Zhuang <coal143@hotmail.com>
* Shivasheesh Yadav <shivasheeshyadav@gmail.com>
+* Fabian Chong <@feiming>... | 4 | 4 | 3 | [{"id": "G0", "claim": "The setting name in tests/test_configuration/test.ini should be `kinto.default_bucket_id_salt` (lowercase id) to match the setting being renamed.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "In tests/plugins/test_default_bu... | null |
Kinto__kinto__2981 | Kinto/kinto | 2,981 | defect | 6d04c7eda2fbfc485e4f648eba5656c6e2b2fef6 | 0cd05def11ae19592f5ceee089bf401854882829 | Prevents merging of `ResourceChanged` events if they are emitted in cascade | This wlil change the way cascading events are grouped together.
Before, we would group all cascading events together, as long as they were for the same (resource name, parent id, action). When grouping events, some information is lost (we keep only payload and merge the list of impacted objects), including the `use... | diff --git a/CHANGELOG.rst b/CHANGELOG.rst
index b242661e4..3dc64c32c 100644
--- a/CHANGELOG.rst
+++ b/CHANGELOG.rst
@@ -6,7 +6,10 @@ This document describes changes between each past release.
14.7.2 (unreleased)
-------------------
-- Nothing changed yet.
+**Bug Fixes**
+
+- Prevents merging of `ResourceChanged` e... | 1 | 1 | 0 | [{"id": "G0", "claim": "The docstring should say the event_dict key is a quadruple rather than a triple now that cascade_level was added to it.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
Kinto__kinto__3453 | Kinto/kinto | 3,453 | defect | 9f8ed40f3597ce2489e16bf51919b1bef6a86436 | da01395984e81e526ccbc80e7a9f664387c91ff1 | Add prometheus support (Fixes #3407) | Fixes #3407
- [x] Basic setup
- [x] Unit tests
- [x] Test with resource manipulation tests with prometheus enabled
- [x] Documentation | diff --git a/constraints.in b/constraints.in
index 1a2c98377..4ee0747dc 100644
--- a/constraints.in
+++ b/constraints.in
@@ -25,6 +25,7 @@ psycopg2
zope.sqlalchemy
# monitoring
newrelic
+prometheus-client
sentry-sdk[sqlalchemy]
statsd
werkzeug
diff --git a/constraints.txt b/constraints.txt
index 85938a6de..e5b434... | 2 | 2 | 0 | [{"id": "G0", "claim": "The docs sentence should read \"in the Pyramid ecosystem\" instead of \"in Pyramid ecosystem\".", "category": "documentation", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The leftover \"# TODO app info\" comment with commented-out prometheus_client In... | null |
Kinto__kinto__3566 | Kinto/kinto | 3,566 | defect | f4da0160f7eec83b5571548954ab64c59d63695a | 52e03f86e655a0a725e03fd87af5819e7e8253b9 | Implement metrics for cache hit ratio | Fixes #3538
## Summary
Added `cache_hits` and `cache_misses` metrics to calculate cache hit ratio.
## Changes
- Add instrumentation to `cache_backend.get()` by wrapping it on application startup.
- Add tests.
## Checklist
- [x] Add tests.
- [x] Add your name in the contributors file.
- [x] Add documen... | diff --git a/CONTRIBUTORS.rst b/CONTRIBUTORS.rst
index 36a0d6117..47dea9c3b 100644
--- a/CONTRIBUTORS.rst
+++ b/CONTRIBUTORS.rst
@@ -112,3 +112,4 @@ Contributors
* Dan Milgram <danm@intervivo.com>
* Dex Devlon <@bxff>
* Varun Koranne <@varun-dhruv>
+* Robin Sharma <robinrythm123@gmail.com>
\ No newline at end of fil... | 3 | 2 | 1 | [{"id": "G0", "claim": "The startup monkeypatching of cache.get (rewiring code on startup) should be replaced by a composition design in which the cache backend has a metrics attribute set during initialization and used internally in get().", "category": "design", "verdict": "supported", "priority": "P1", "scope": "int... | null |
Kinto__kinto__3595 | Kinto/kinto | 3,595 | defect | c2dc356e960b56e35ed37bebb6b9ffcd542734df | 7a7475c614933c4bce7d2498672fbcead9cc6f10 | Fix performance of history trimming | Before (`list_all()` + `delete_all()` > 1sec):
```
2025-10-31 18:20:05.365 CET [67005] LOG: duration: 482.272 ms statement:
SELECT id, as_epoch(last_modified) AS last_modified, data
FROM objects
WHERE parent_id = '/buckets/main-workspace'
AND resource_name =... | diff --git a/kinto/core/storage/__init__.py b/kinto/core/storage/__init__.py
index 00150d7d8..81a9676cf 100644
--- a/kinto/core/storage/__init__.py
+++ b/kinto/core/storage/__init__.py
@@ -385,6 +385,28 @@ def collection_timestamp(self, collection_id, parent_id):
warnings.warn(message, DeprecationWarning)
... | 1 | 1 | 1 | [{"id": "G0", "claim": "The schema-version check in the unit tests needs fixing: the PostgreSQL storage schema_version was left at 23 while schema.sql and the new migration file were bumped to 24.", "category": "correctness", "verdict": "supported", "priority": "P0", "scope": "introduced"}] | null |
Kinto__kinto__3645 | Kinto/kinto | 3,645 | defect | e57fe60494a812520b68507e4f281203de23ca3a | 371fcbe36fdce58c1aad8ee77d9a0da0cf18290a | Enable index range scans for last_modified queries (100x speedup in some cases) | ## Problem
Kinto has an excellent composite index `(parent_id, resource_name, last_modified DESC)` that can satisfy filtered listings, pagination, and sorting from a single B-tree scan. However, `last_modified` is wrapped in `as_epoch()` in WHERE and ORDER BY clauses, which prevents PostgreSQL from using this index fo... | diff --git a/kinto/core/storage/postgresql/__init__.py b/kinto/core/storage/postgresql/__init__.py
index 43aa9c75d..c63b901f0 100644
--- a/kinto/core/storage/postgresql/__init__.py
+++ b/kinto/core/storage/postgresql/__init__.py
@@ -79,7 +79,7 @@ class Storage(StorageBase, MigratorMixin):
# MigratorMixin attribu... | 3 | 3 | 0 | [{"id": "G0", "claim": "The new is_modified_field tracking flag is more complex than needed; the condition could simply read `if filtr.field == modified_field and filtr.operator not in (COMPARISON.IN, COMPARISON.EXCLUDE):`.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"... | null |
Kinto__kinto__3646 | Kinto/kinto | 3,646 | defect | e57fe60494a812520b68507e4f281203de23ca3a | 64bafaac9f1a3721ebb7364ed6a34025659f4a66 | Use JSONB containment for GIN-friendly EQ filters | ## Summary
- Rewrites `_format_conditions` to emit `data @> '{"field": value}'` (JSONB containment) instead of `data->'field' = 'value'::jsonb` for **EQ filters on scalar** data fields (str, int, float, bool, None)
- Rewrites **CONTAINS filters** to use top-level containment (`data @> '{"field": [values]}'`) instead o... | diff --git a/kinto/core/storage/postgresql/__init__.py b/kinto/core/storage/postgresql/__init__.py
index 43aa9c75d..aa95ae5ec 100644
--- a/kinto/core/storage/postgresql/__init__.py
+++ b/kinto/core/storage/postgresql/__init__.py
@@ -75,6 +75,86 @@ class Storage(StorageBase, MigratorMixin):
recommended to allow... | 11 | 9 | 0 | [{"id": "G0", "claim": "Kinto should create the GIN index in a migration like previous migrations did, with just a warning in the release notes, instead of asking users to create it manually.", "category": "design", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Kinto should pin ... | null |
Kinto__kinto__3651 | Kinto/kinto | 3,651 | defect | a8644e3cc458582d6225e710cdc9a867eea465d1 | 2787a44cf470e65bd2700953e17081a5e0e6b590 | Ref #360: Add a counters plugin to ease storage inspection | Ref https://github.com/Kinto/kinto/issues/360
In the recent weeks, I connected to our production database several times to count objects and tombstones by resource name. Having an endpoint exposing this would be helpful (with private URL pattern like others internal endpoint if blocking external access is required) | diff --git a/docs/api/1.x/counters.rst b/docs/api/1.x/counters.rst
new file mode 100644
index 000000000..dbb056b67
--- /dev/null
+++ b/docs/api/1.x/counters.rst
@@ -0,0 +1,59 @@
+.. _api-counters:
+
+
+Counters Endpoint
+#################
+
+
+The Counters endpoint exposes the number of objects per resource in storage.... | 1 | 1 | 0 | [{"id": "G0", "claim": "The docs sentence reads 'You can enable it including kinto.plugins.counters' and should say 'by including'.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
Kistler-Group__sdbus-cpp__166 | Kistler-Group/sdbus-cpp | 166 | defect | a649a0225e0fe4de2c9253b24c6d86035294ed0e | 0e5dad84d8c9ccaa314472e497898e177cce1bea | fix: minor documentation and test improvements | This PR:
* removes unnecessary `releaseName()` calls in integration tests,
* adds a custom gtest message if a connection test fails, pointing the user to the potential cause of the issue,
* adds more documentation on how to test sdbus-c++ build.
Fixes #162
Fixes #155 | diff --git a/README.md b/README.md
index 064b1c22..70c6c086 100644
--- a/README.md
+++ b/README.md
@@ -40,7 +40,7 @@ $ sudo make install
* `BUILD_TESTS` [boolean]
- Option for building sdbus-c++ unit and integration tests, invokable by `make test`. That incorporates downloading and building static libraries of Go... | 2 | 2 | 2 | [{"id": "G0", "claim": "The README BUILD_TESTS option documentation should invoke tests via CMake (`cmake --build . --target test`) instead of `make test`, since `make` examples assume the Makefile generator and other generators like ninja exist.", "category": "documentation", "verdict": "supported", "priority": "P1", ... | null |
Kistler-Group__sdbus-cpp__180 | Kistler-Group/sdbus-cpp | 180 | defect | b0a72cbe9256fc11127ba19c151b4c16b09e6935 | e3967c9378950d6d74cb7bb03217d29296a45de5 | Enable default construction of PendingAsyncCall | This is helpful in use cases where a user defined class wants to store a `PendingAsyncCall` as a member variable, or in a STL container.
I mentioned this change here: https://github.com/Kistler-Group/sdbus-cpp/discussions/169 | diff --git a/include/sdbus-c++/IProxy.h b/include/sdbus-c++/IProxy.h
index aaff2132..deab31a2 100644
--- a/include/sdbus-c++/IProxy.h
+++ b/include/sdbus-c++/IProxy.h
@@ -286,6 +286,8 @@ namespace sdbus {
class PendingAsyncCall
{
public:
+ PendingAsyncCall() = default;
+
/*!
* @... | 1 | 1 | 0 | [{"id": "G0", "claim": "Split the combined test into two test cases, each with a single responsibility, named to reveal the behaviors under test and following an arrange-act-assert structure.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
Kistler-Group__sdbus-cpp__182 | Kistler-Group/sdbus-cpp | 182 | defect | 118faa58f6e706fd99922f8ddb775e05dcb0ed1e | 481744fd7db51febd4f3b2bd0c5d4eb41f9e18b6 | Add createDefaultBusConnection() | This internally calls `sd_bus_open()`, which automatically selects the system or session bus connection based on the presence and content of a `DBUS_STARTER_BUS_TYPE` environment variable and whether the calling process has root privileges.
This option is very helpful when creating services and clients that will use... | diff --git a/include/sdbus-c++/IConnection.h b/include/sdbus-c++/IConnection.h
index cd0ed29d..efa3341a 100644
--- a/include/sdbus-c++/IConnection.h
+++ b/include/sdbus-c++/IConnection.h
@@ -265,6 +265,27 @@ namespace sdbus {
*/
[[nodiscard]] std::unique_ptr<sdbus::IConnection> createConnection(const std::st... | 1 | 1 | 1 | [{"id": "G0", "claim": "The overload createDefaultBusConnection(const std::string& name) should call createDefaultBusConnection() rather than createConnection() to obtain the connection before requesting the name.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}] | null |
Kistler-Group__sdbus-cpp__223 | Kistler-Group/sdbus-cpp | 223 | defect | dc0f487751690999aaa61e507bbd16bdf111949d | 06708b03436f87dfc71ac98d8b638dab293f3d4d | Fix #214: Add means to unregister signal handler | Summary:
I implemented your second approach as follows:
- Add `void IProxy::unregisterSignalHandler(const std::string& interfaceName, const std::string& signalName)` method.
- Add new auxiliary class `SignalUnsubscriber`.
- Add `SignalUnsubscriber IProxy::muteSignal(const std::string& signalName)` method.
- Extend... | diff --git a/include/sdbus-c++/ConvenienceApiClasses.h b/include/sdbus-c++/ConvenienceApiClasses.h
index 37e8f8b2..e5334421 100644
--- a/include/sdbus-c++/ConvenienceApiClasses.h
+++ b/include/sdbus-c++/ConvenienceApiClasses.h
@@ -216,6 +216,17 @@ namespace sdbus {
std::string interfaceName_;
};
+ cl... | 1 | 1 | 1 | [{"id": "G0", "claim": "Use `at()` or `find()` instead of `operator[]` in `unregisterSignalHandler()`, since unregistering should never add a new entry to `interfaces_`.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}] | null |
Kistler-Group__sdbus-cpp__264 | Kistler-Group/sdbus-cpp | 264 | defect | b5aee6d019a8150c8de3fdddc17964fe0122c8d2 | 4917512271ce1cef1fa8d62ceaed12d4b477045b | feat: add support for match rules | This implements support for synchronous installation of D-Bus match rules. See [D-Bus specification](https://dbus.freedesktop.org/doc/dbus-specification.html) for more info on match rules. | diff --git a/include/sdbus-c++/IConnection.h b/include/sdbus-c++/IConnection.h
old mode 100644
new mode 100755
index 58f39cd3..742b1362
--- a/include/sdbus-c++/IConnection.h
+++ b/include/sdbus-c++/IConnection.h
@@ -27,6 +27,7 @@
#ifndef SDBUS_CXX_ICONNECTION_H_
#define SDBUS_CXX_ICONNECTION_H_
+#include <sdbus-c++... | 2 | 2 | 2 | [{"id": "G0", "claim": "The pull request should also add the second addMatch() overload (the library-owned/floating-slot variant) so clients can register a match rule without owning the returned slot.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "Proxy:... | null |
Kistler-Group__sdbus-cpp__342 | Kistler-Group/sdbus-cpp | 342 | defect | 29c877a89acebe121db11aa870655fcc3ad6e978 | 9b7252006f6f02cb9d393d50e9c9c24049528d43 | feat: support serialization of array, span and unordered_map | Add support for `std::array`, `std::span` and `std::unordered_map` in D-Bus message serialization/deserialization API.
TBD: Extending codegen XML to allow clients to choose from STL containers to use in C++ bindings? | diff --git a/include/sdbus-c++/Message.h b/include/sdbus-c++/Message.h
index 742d4e33..91f613cf 100755
--- a/include/sdbus-c++/Message.h
+++ b/include/sdbus-c++/Message.h
@@ -31,7 +31,12 @@
#include <sdbus-c++/Error.h>
#include <string>
#include <vector>
+#include <array>
+#if __cplusplus >= 202002L
+#include <span>... | 3 | 2 | 0 | [{"id": "G0", "claim": "The std::tuple serialization operators should not be allowed; the prior agreement was to not allow std::tuple and use sdbus::Struct instead.", "category": "design", "verdict": "opposed", "priority": "P2", "scope": "pre_existing"}, {"id": "G1", "claim": "The documentation (docs/using-sdbus-c++.md... | null |
Kistler-Group__sdbus-cpp__39 | Kistler-Group/sdbus-cpp | 39 | defect | 84b15776a3daa1a4575df638d2f832fe02508a26 | ac5b5dc6c2d7f3061312244137ababef72f75573 | Testing | I encapsulated sd_bus_* calls in IDbus interface, so it can be injected in constructor, e.g Connection class.
Pros:
1. There is possibility for unit tests now, IDbus interface can be easily mocked.
2. Clients of Connection class don't see the difference
Cons:
1. Dependency injection, more complicated class h... | diff --git a/src/Connection.cpp b/src/Connection.cpp
index e5815d7f..56324a79 100755
--- a/src/Connection.cpp
+++ b/src/Connection.cpp
@@ -34,9 +34,10 @@
namespace sdbus { namespace internal {
-Connection::Connection(Connection::BusType type)
+Connection::Connection(Connection::BusType type, std::unique_ptr<IDbus>... | 21 | 21 | 1 | [{"id": "G0", "claim": "The Connection constructor should take the injected interface by r-value reference (std::unique_ptr<...>&&) for idiomatic move-only semantics, in both the declaration and the definition.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim... | null |
Kistler-Group__sdbus-cpp__491 | Kistler-Group/sdbus-cpp | 491 | defect | 48ea775531523ac290abec91107c628f00156543 | 3daf683dce096aea6905ffd5bd8c236029dbc752 | feat: Add sd_bus_message_get_cookie (#490) | Add `sd_bus_message_get_cookie()` and `sd_bus_message_get_reply_cookie()` as `Message::getCookie()` and `Message::getReplyCookie()`. | diff --git a/include/sdbus-c++/Message.h b/include/sdbus-c++/Message.h
index d2ed4a99..89ebb2fc 100644
--- a/include/sdbus-c++/Message.h
+++ b/include/sdbus-c++/Message.h
@@ -215,6 +215,8 @@ namespace sdbus {
const char* getSender() const;
const char* getPath() const;
const char* getDestinati... | 2 | 2 | 2 | [{"id": "G0", "claim": "getReplyCookie() only makes sense for method reply messages, so it should be defined in the MethodReply class instead of in Message.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "A new (integration) test case should be added veri... | null |
Kistler-Group__sdbus-cpp__517 | Kistler-Group/sdbus-cpp | 517 | defect | 7fbfcec455a2af6efe3910baa3089ecba48a9d6d | 70cf302ab058d322c85f84118b430134ee91cd8a | fix: create sdbus::Error correctly when errno is 0 | Create an empty (invalid) `sdbus::Error` instance when errno is 0, instead of segfaulting or throwing an exception by `std::string`. Improve robustness of `sdbus::createError()` in general. Add more tests.
Fixes #516 | diff --git a/include/sdbus-c++/Error.h b/include/sdbus-c++/Error.h
index c52dbc18..4f6e2e9d 100644
--- a/include/sdbus-c++/Error.h
+++ b/include/sdbus-c++/Error.h
@@ -64,7 +64,7 @@ namespace sdbus {
}
Error(Name name, std::string message)
- : std::runtime_error("[" + name + "] " + message... | 3 | 3 | 1 | [{"id": "G0", "claim": "The `#include <cassert>` added to src/Error.cpp is not required and should be removed.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The ternary in the message construction should be formatted with a space before the `?`... | null |
Kistler-Group__sdbus-cpp__72 | Kistler-Group/sdbus-cpp | 72 | defect | 8dea11bac682456cc1e3c861c9415b1082e4f829 | 150497e97c00ecbd50d1af3ee474820a1fab7cd0 | Added support to specify custom timeout value for async DBus client call | Currently there is no possibility to specify the timeout value for asynchronous call. This pull request extends the functionality to add support for specifying custom timeout values for asynchronous calls. | diff --git a/include/sdbus-c++/ConvenienceApiClasses.h b/include/sdbus-c++/ConvenienceApiClasses.h
index 3faf6a9b..175913e0 100644
--- a/include/sdbus-c++/ConvenienceApiClasses.h
+++ b/include/sdbus-c++/ConvenienceApiClasses.h
@@ -180,7 +180,7 @@ namespace sdbus {
class AsyncMethodInvoker
{
public:
- ... | 9 | 9 | 6 | [{"id": "G0", "claim": "Instead of passing the timeout through the AsyncMethodInvoker constructor, add a dedicated fluent member function `AsyncMethodInvoker& withTimeout(uint64_t timeout)` that sets a `timeout_` member, so calls read like proxy.callMethod(\"doFoo\").withTimeout(2000000).onInterface(iface).", "category... | null |
Kistler-Group__sdbus-cpp__91 | Kistler-Group/sdbus-cpp | 91 | defect | 9b8a15339e9def4af00f49caaf4f9250c844556c | ef6b5ea1384172bf0266a06e1fdea58e07bd3941 | Fix #88: Timeout handling. | * Despite what is documented in sd_bus_get_timeout(3), the timeout
returned is actually an absolute time point of Linux's CLOCK_MONOTONIC
clock. Hence, we first have to subtract the current time from the
timeout in order to get a relative time that can be passed to poll.
* For async call timeouts to reliabl... | diff --git a/include/sdbus-c++/IConnection.h b/include/sdbus-c++/IConnection.h
index efa3341a..1847dc45 100644
--- a/include/sdbus-c++/IConnection.h
+++ b/include/sdbus-c++/IConnection.h
@@ -31,6 +31,7 @@
#include <memory>
#include <chrono>
#include <cstdint>
+#include <optional>
namespace sdbus {
@@ -47,11 +48... | 9 | 5 | 1 | [{"id": "G0", "claim": "sd_bus_get_poll_data should not return a relative timeout, since that is a breaking change for users of the public PollData API.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The timeout-comparison code in sd_bus_call_async lacks... | null |
Kitware__VolView__288 | Kitware/VolView | 288 | defect | 271d297cb9ba5542fb7071caab9b4af325ece3a2 | 70c5b4b9883ddee493ddf1c828093984b0ce999d | Remote state | ### New Features
- Loads a `session.volview.zip` state file if in `files` URL parameter.
- Fetch remotely loaded datasets from URLs in state file, rather than zipping in all files.
### How
- Introduce `DatasetFile` type with copyleft `{ url, remoteFilename }` properties.
- Files downloaded from url parameters,... | diff --git a/src/components/App.vue b/src/components/App.vue
index a67b43ded..1b2be7162 100644
--- a/src/components/App.vue
+++ b/src/components/App.vue
@@ -221,9 +221,9 @@ import {
DICOMLoadSuccess,
FileLoadFailure,
DICOMLoadFailure,
- DataSelection,
} from '../store/datasets';
import { useImageStore } fro... | 8 | 8 | 4 | [{"id": "G0", "claim": "Dropping the `?? []` from `wrapInArray(params.names)` is wrong: when `params.names` is undefined, `names` becomes `[undefined]`, so `params.names ?? []` is still needed.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The `pat... | null |
Kitware__VolView__358 | Kitware/VolView | 358 | defect | f1adb694d4fcf3d4ba773b0ee94b9935f904c40f | e8e4459a38c3bca88dd8da9aebeac5985031ff5f | Tool Labels: Add, Edit, Delete | Adds edit label and add label buttons to label list card:

Clicking the pencil button pops a modal:

closes #347 | diff --git a/package-lock.json b/package-lock.json
index 8d25fc3c0..63e28b773 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -64,12 +64,12 @@
"kw-doc": "3.1.2",
"lint-staged": "10.5.4",
"patch-package": "^6.4.7",
- "prettier": "2.6.2",
+ "prettier": "2.8.8",
... | 6 | 6 | 0 | [{"id": "G0", "claim": "The rest of schema.ts should be converted to use the `satisfies` pattern (which gives the same type safety while allowing ZodObject.extend).", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "standardizeColor should accept `M... | null |
Kitware__kwiver__1024 | Kitware/kwiver | 1,024 | defect | 19b73ebb949ce06b127dbc9790a9be1bfc64253a | af425c7059a60c59fbac05098270dba5253a0e2a | Dev/finish activity serialization | This PR adds protobuf serialization for the vital type "activity". Tests for the JSON and protobuf serialization are also added.
In order for the JSON tests to pass, the implementations of load and save for an activity were modified. Activity has two fields that are pointers, and in the previous implementation, it w... | diff --git a/arrows/serialize/json/load_save.cxx b/arrows/serialize/json/load_save.cxx
index 72a6a0c054..bb804562b3 100644
--- a/arrows/serialize/json/load_save.cxx
+++ b/arrows/serialize/json/load_save.cxx
@@ -624,10 +624,15 @@ void save( cereal::JSONOutputArchive& archive,
archive( ::cereal::make_nvp( "id", acti... | 7 | 5 | 0 | [{"id": "G0", "claim": "Per the style guide, single-statement if/else blocks in arrows/serialize/json/load_save.cxx (and other places) need curly braces.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "In load(), when the optional field is absent... | null |
Kitware__kwiver__1243 | Kitware/kwiver | 1,243 | defect | 7efe73fd6303a4d2cb1e49f462a89687814d10c1 | c4c1f76e3f3a3f5bf02145af78fffc024fecca1c | Add json serialization of metadata maps | This is code which was internally reviewed [here](https://kwgitlab.kitware.com/computer-vision/KWIVER/-/merge_requests/248). It adds the ability to read and write video metadata as a json. Also, it updates `dump_klv` to have the option to write out the metadata.
I then rebased the internal changes onto `master`, cle... | diff --git a/arrows/core/applets/dump_klv.cxx b/arrows/core/applets/dump_klv.cxx
index dfb3eac889..f206937c51 100644
--- a/arrows/core/applets/dump_klv.cxx
+++ b/arrows/core/applets/dump_klv.cxx
@@ -18,16 +18,22 @@
#include <vital/util/get_paths.h>
#include <vital/util/wrap_text_block.h>
+#include <vital/algo/seria... | 50 | 45 | 1 | [{"id": "G0", "claim": "The newly added local variables in dump_klv's run() (caps, detail, quiet, log) could be declared const.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The metadata_map.h include should be sorted before metadata_traits.h s... | null |
Kitware__kwiver__1359 | Kitware/kwiver | 1,359 | defect | 0dc3f67c58df77909f463864f18068db6e645679 | 6efff72dc93c0f3fa1f7b613c9457265f68d6d05 | Create Colmap arrow | Created a colmap arrow with a build configuration for colmap and a small test to verify that the library links properly | diff --git a/arrows/CMakeLists.txt b/arrows/CMakeLists.txt
index 0eb23c4880..606c212eed 100644
--- a/arrows/CMakeLists.txt
+++ b/arrows/CMakeLists.txt
@@ -102,3 +102,6 @@ if( KWIVER_ENABLE_VTK)
endif()
add_subdirectory( serialize )
+
+# Register the colmap arrow with CMake.
+add_subdirectory( colmap )
diff --git a/... | 11 | 10 | 4 | [{"id": "G0", "claim": "The pull request is missing all the files in the 'colmap' subdirectory and should not include the template-arrow commit; it should only add the colmap arrow.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The header should us... | null |
Kitware__kwiver__1382 | Kitware/kwiver | 1,382 | defect | ef12afb416653d7f268e5b38f0a5768a486f7e44 | 4c00d08cb5c95da6e8390c9623291ac2b590db8b | Add KLV read / write for IMAP format | IMAP format is a method of encoding a floating-point number between defined upper and lower limits into an integer for concise transmission. Defined by [MISB ST1201](https://gwg.nga.mil/misb/docs/standards/ST1201.4.pdf), IMAP is a standardized series of calculations which map an integer of variable byte length such tha... | diff --git a/arrows/klv/CMakeLists.txt b/arrows/klv/CMakeLists.txt
index ce5faf5022..32eb717651 100644
--- a/arrows/klv/CMakeLists.txt
+++ b/arrows/klv/CMakeLists.txt
@@ -11,6 +11,7 @@ set( sources
klv_data.cxx
klv_key.cxx
klv_parse.cxx
+ klv_read_write.cxx
klv_0601.cxx
klv_0104.cxx
misp_time.cxx
dif... | 14 | 13 | 0 | [{"id": "G0", "claim": "The separate _imap_pos_infinity/_imap_neg_infinity (and NaN) helpers would make more sense as a single _imap_infinity( bool signbit, size_t length ), which is more symmetric with how decoding is accomplished and should optimize to one fewer conditional jump.", "category": "design", "verdict": "s... | null |
Kitware__kwiver__1387 | Kitware/kwiver | 1,387 | defect | 2a4d26f5bf82e8eab596b8746ec94d55aabaa4b3 | 98423f8423238e4866e19bd4c188659074c8b43e | Implement read/write for KLV float | The "float" format in KLV is just a big-endian serialized [ IEEE-754 ](https://en.wikipedia.org/wiki/IEEE_754#Basic_and_interchange_formats) single- or double-precision floating-point number, same as is standard for most systems to operate on internally (like `float` and `double` in C/C++). It is one of three ways MISB... | diff --git a/arrows/klv/klv_read_write.h b/arrows/klv/klv_read_write.h
index 429afc949c..546e61ba33 100644
--- a/arrows/klv/klv_read_write.h
+++ b/arrows/klv/klv_read_write.h
@@ -207,6 +207,40 @@ KWIVER_ALGO_KLV_EXPORT
size_t
klv_ber_oid_length( T value );
+// -------------------------------------------------------... | 4 | 4 | 1 | [{"id": "G0", "claim": "The Doxygen comments for klv_read_float/klv_write_float should indent continuation lines under \\param (or use the nested style) and prefer \"as-is\" over \"as is\".", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The adde... | null |
Kitware__kwiver__1505 | Kitware/kwiver | 1,505 | defect | 9b8d069f010c0b47abf2740702adafcc735464f9 | 2c8b728229700a1586efc6df3bb270089b981fff | Add FFmpeg video writer | Create a proof-of-concept FFmpeg video writer. There are several features/functions/cases that are unimplemented, but the basic structure and core functionality is there. It writes a sequence of images into a single video file, but cannot handle metadata yet. Credit to Matt Woehlke for the `video_output` algorithm inte... | diff --git a/arrows/ffmpeg/CMakeLists.txt b/arrows/ffmpeg/CMakeLists.txt
index a0ea1f673e..0f318dcb0f 100644
--- a/arrows/ffmpeg/CMakeLists.txt
+++ b/arrows/ffmpeg/CMakeLists.txt
@@ -20,6 +20,7 @@ endif()
set(ffmpeg_headers_public
ffmpeg_init.h
ffmpeg_video_input.h
+ ffmpeg_video_output.h
ffmpeg_video_settin... | 1 | 1 | 0 | [{"id": "G0", "claim": "The final `{` of the ffmpeg_video_output constructor body should be placed on its own line to satisfy the project's formatting style.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}] | null |
Kitware__kwiver__1541 | Kitware/kwiver | 1,541 | defect | 5ff157254a257f6298ec3bced5ecf772e245b626 | 690a537e09e41721f807a0072f70bf2659de6976 | Add interval_map::weak_set() | Add a `weak_set()` method for the `interval_map` class. This is a variation on the existing `set()` method, which sets the map's value for some period of time, replacing any value(s) already present during that time. `weak_set()` similarly sets the maps' value, but does not replace any existing values, instead only set... | diff --git a/vital/util/interval_map.h b/vital/util/interval_map.h
index dd8356c6fa..a15da30f0c 100644
--- a/vital/util/interval_map.h
+++ b/vital/util/interval_map.h
@@ -15,6 +15,7 @@
#include <initializer_list>
#include <iterator>
#include <map>
+#include <vector>
namespace kwiver {
@@ -265,7 +266,7 @@ class ... | 1 | 1 | 1 | [{"id": "G0", "claim": "In the 'Point interval - outside' test block, the call should be weak_set instead of set, so the new method is exercised with a point interval outside the map.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}] | null |
Kitware__kwiver__1580 | Kitware/kwiver | 1,580 | defect | a2a162215f09a34a83bac6291972b872c73ea137 | 2c5114b4cd87927e6b61c35f8e574b453dee6a8d | Add api and vxl implementation for KDTree search tree | Added a simple api for the KDTree search algorithm along with a basic implementation in the vxl arrow. This can be expanded on by exposing some options in the vxl implementation and potentially add implementations from other arrows such as OpenCV and VTK. | diff --git a/arrows/vxl/CMakeLists.txt b/arrows/vxl/CMakeLists.txt
index a768e6419a..2460305b89 100644
--- a/arrows/vxl/CMakeLists.txt
+++ b/arrows/vxl/CMakeLists.txt
@@ -27,6 +27,7 @@ set(vxl_headers_public
high_pass_filter.h
image_container.h
image_io.h
+ kd_tree.h
match_features_constrained.h
morphol... | 2 | 2 | 1 | [{"id": "G0", "claim": "The abstract algorithm should be named `nearest_neighbors` instead of `kd_tree`, with the vxl implementation still called `kd_tree` under the plugin name \"vxl_kd_tree\", since a kd-tree is only one specific nearest-neighbors algorithm and a generic base allows bundling other algorithms.", "cate... | null |
Kitware__kwiver__1653 | Kitware/kwiver | 1,653 | defect | ac5058f8a0c7573166fb14f1b658f4eb494f1b33 | 89e84d5c4ad980f0cab81affdbd335d9abc061ca | Add CUDA/NVENC video encoders | This PR adds the ability to use NVidia's NVenc H.264 and H.265 hardware video encoders on CUDA-enabled devices. Similarly to the CUDA decoders, getting the CUDA encoders to actually work requires a fletch PR, which has not been uploaded yet due to existing PR dependencies.
@hdefazio | diff --git a/arrows/ffmpeg/ffmpeg_cuda.cxx b/arrows/ffmpeg/ffmpeg_cuda.cxx
index a6f8c01100..5aa4543110 100644
--- a/arrows/ffmpeg/ffmpeg_cuda.cxx
+++ b/arrows/ffmpeg/ffmpeg_cuda.cxx
@@ -34,6 +34,12 @@ kv::logger_handle_t logger()
return kv::get_logger( "cuda" );
}
+// --------------------------------------------... | 1 | 1 | 0 | [{"id": "G0", "claim": "The extra braces wrapping the CUDA device-name logging block in ffmpeg_cuda.cxx seem unnecessary and the reviewer asks why they are there.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}] | null |
Kitware__kwiver__428 | Kitware/kwiver | 428 | defect | 138edcdde7dc41456c17f5b0d25296302cb11e01 | b500d4280f4044144f9f98bbc1564bc243b07602 | Add base set class and proliferate use | Created a ``kwiver::vital::set`` template mixin class (header only) that inherits from ``kwiver::vital::iterable``. This ``set`` mixin class was then applied to the ``*_set`` classes within vital.
---
This is a work in progress because:
* [x] Depends on PR #345. | diff --git a/arrows/core/associate_detections_to_tracks_threshold.cxx b/arrows/core/associate_detections_to_tracks_threshold.cxx
index fafa56e943..3a5f62ccba 100644
--- a/arrows/core/associate_detections_to_tracks_threshold.cxx
+++ b/arrows/core/associate_detections_to_tracks_threshold.cxx
@@ -1,5 +1,5 @@
/*ckwg +29
-... | 5 | 2 | 1 | [{"id": "G0", "claim": "The new file image_container_set_simple.cxx (and .h) defines a class named simple_image_container_set, and the mismatch between the file name and the class name is confusing when looking for code, so the class name should be changed to match the file.", "category": "maintainability", "verdict": ... | null |
Kitware__kwiver__589 | Kitware/kwiver | 589 | defect | bcad276e626cfb4d584a6e25929cf90ebc57a390 | 3927a268e2e49bb006a7ba4522541427991caac5 | Adding embedded pipeline extensions | Add plugin support for embedded pipeline extensions (EPX) that allow external conditions to be checked before running the pipeline. | diff --git a/doc/manuals/sprokit/embedded_pipeline.rst b/doc/manuals/sprokit/embedded_pipeline.rst
new file mode 100644
index 0000000000..30784af871
--- /dev/null
+++ b/doc/manuals/sprokit/embedded_pipeline.rst
@@ -0,0 +1,47 @@
+Embedded Pipeline
+=================
+
+The embedded pipeline class provides a way to insta... | 18 | 15 | 3 | [{"id": "G0", "claim": "The new documentation misspells 'there are' as 'therare' in the EPX section.", "category": "documentation", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The intro should say the GUI 'runs' a pipeline instead of 'needs to run' one.", "category": "docume... | null |
Kitware__kwiver__617 | Kitware/kwiver | 617 | defect | 832262278b92c4edb21428d35dd53d634ab6e79e | af1658f01955162a7397a28bdea84be8bf363247 | Add image serialization | Rebase on master to get latest serialization message approach.
Updated serializers to new API.
Added serialize pipe example. | diff --git a/arrows/ocv/image_container.cxx b/arrows/ocv/image_container.cxx
index 8a6b8b3db5..723a47b4dc 100644
--- a/arrows/ocv/image_container.cxx
+++ b/arrows/ocv/image_container.cxx
@@ -124,6 +124,11 @@ ::ocv_to_vital(const cv::Mat& img, ColorMode cm)
{
memory = std::make_shared<mat_image_memory>(img);
... | 1 | 1 | 0 | [{"id": "G0", "claim": "The protobuf serialize-image test should populate the image with dummy data, like the json test case does, instead of serializing an empty image.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
Kitware__kwiver__628 | Kitware/kwiver | 628 | defect | f18d45929a2fea6da67675966ab5e35a46ba6d5e | 60760e6cc57f55fec1109371fc886b3a17ed538c | Added local implementation optional data type. (deboostify) | This is a replacement for boost::optional and will stand as a
placeholder until we can use std::optional | diff --git a/sprokit/src/sprokit/pipeline/edge.cxx b/sprokit/src/sprokit/pipeline/edge.cxx
index e281e90df0..7f794a88a8 100644
--- a/sprokit/src/sprokit/pipeline/edge.cxx
+++ b/sprokit/src/sprokit/pipeline/edge.cxx
@@ -35,6 +35,7 @@
#include "types.h"
#include <vital/logger/logger.h>
+#include <vital/optional.h>
... | 1 | 1 | 0 | [{"id": "G0", "claim": "boost/variant should also be tackled and removed from pipe_declaration_types.h, to get boost out of that header.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "pre_existing"}] | null |
Kitware__kwiver__667 | Kitware/kwiver | 667 | defect | 133709a63890aa768e37b53dc3982b7d7e5838ce | e401fdcafc996ddc33210b41cda78afbc6927bec | Update depth map rendering | @mleotta Please have a look.
Main changes:
- add a triangle scan iterator type
- update render_mesh_depth_map to use it
- add render_mesh_height_map
- update tests
| diff --git a/arrows/core/render_mesh_depth_map.cxx b/arrows/core/render_mesh_depth_map.cxx
index 1d58f3860a..51ec2965c4 100644
--- a/arrows/core/render_mesh_depth_map.cxx
+++ b/arrows/core/render_mesh_depth_map.cxx
@@ -40,175 +40,121 @@
#include <vital/types/vector.h>
-namespace {
-
-/// Helper function to check i... | 7 | 6 | 3 | [{"id": "G0", "claim": "This branch introduces several new compiler warnings of comparison between signed and unsigned integer expressions.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The special case of perspective correction should be handl... | null |
Kitware__kwiver__668 | Kitware/kwiver | 668 | defect | 133709a63890aa768e37b53dc3982b7d7e5838ce | 710e331f0577d0dcc2ca20cfd32d38d4027e0480 | Add mesh parameterization | This adds a mesh parameterization algo interface in vital and an implementation in core.
@mleotta Please have a look. | diff --git a/arrows/core/CMakeLists.txt b/arrows/core/CMakeLists.txt
index 5b0c0fe66a..98f611e94a 100644
--- a/arrows/core/CMakeLists.txt
+++ b/arrows/core/CMakeLists.txt
@@ -32,6 +32,7 @@ set( plugin_core_headers
match_features_fundamental_matrix.h
match_features_homography.h
match_tracks.h
+ parameterize_me... | 9 | 8 | 4 | [{"id": "G0", "claim": "The algorithm should be named uv_unwrap_mesh, since the standard name for the process is UV unwrapping.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The parameterize() API should not return the texture width and height; the text... | null |
Kitware__kwiver__727 | Kitware/kwiver | 727 | defect | d2ab65b76ea4827619b7b3e31b7bb6e5cf55c90e | de472f5b819105f7cf5601e0da9df3f67aa07264 | Dev/fix image serializer | Fix issue where serializer did not handle image containers that did not own the image memory. | diff --git a/arrows/gdal/image_container.cxx b/arrows/gdal/image_container.cxx
index 09f9fcf209..710b76006c 100644
--- a/arrows/gdal/image_container.cxx
+++ b/arrows/gdal/image_container.cxx
@@ -227,7 +227,7 @@ ::get_image() const
// Loop over bands and copy data
CPLErr err;
- for (int i = 1; i <= depth(); ++i... | 5 | 5 | 3 | [{"id": "G0", "claim": "The closing brace of the new else block is not indented to match its block (or at least renders that way on GitHub).", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "Set `vital_image = local_image;` after the copy so the co... | null |
Kitware__kwiver__852 | Kitware/kwiver | 852 | defect | 8d524cb0fe7c9c0f5d78e2cd7dc3dc0d008bbb75 | 30f8757662b9327ad74ce7edbe4e34166aee1aa7 | Fix geo point build error | @aaron-bray
This patch fixes the ambiguous calls to the geo_point constructor. It was introduced when a second constructor was added. The calls in the serialization test code were creating geo_point objects by just passing {42.50, 73.54} into the first argument. I resolved it by creating actual objects and passing ... | diff --git a/.travis.yml b/.travis.yml
index 6719fc1139..af6afe4fab 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -47,6 +47,8 @@ script:
-DKWIVER_ENABLE_PROJ=ON
-DKWIVER_ENABLE_PROCESSES=ON
-DKWIVER_ENABLE_PYTHON=ON
+ -DKWIVER_ENABLE_SERIALIZE_JSON=ON
+ -DKWIVER_ENABLE... | 6 | 5 | 3 | [{"id": "G0", "claim": "The JSON save code needs to save the third coordinate and the load code needs to restore it instead of always reading a hardcoded 0.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The load_save.cxx geo_point tests should exer... | null |
Kitware__kwiver__980 | Kitware/kwiver | 980 | defect | c8c7b0a693e6677e9dcf5489ba6a13a8bed8f985 | 901fcfc414c7f01dd9edca15c1e33bb29e39297d | Dev/update geo mgrs | This PR makes a few changes to the kwiver vital type geo_MGRS:
1.) In the header file for the type, VITAL_EXPORT calls were added in the class declaration and before the insertion operator. Previously, using the type in any code outside the header and implementation files would cause linker errors, which is solved b... | diff --git a/vital/tests/CMakeLists.txt b/vital/tests/CMakeLists.txt
index 69bf99eb5a..151b9f1389 100644
--- a/vital/tests/CMakeLists.txt
+++ b/vital/tests/CMakeLists.txt
@@ -30,6 +30,7 @@ kwiver_discover_gtests(vital essential_matrix LIBRARIES ${test_lib
kwiver_discover_gtests(vital estimate_similarity_... | 1 | 1 | 0 | [{"id": "G0", "claim": "The copyright header of the newly added vital/tests/test_geo_MGRS.cxx carries the wrong years (2016-2017 instead of 2020) and should be corrected.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
KjellKod__g3log__248 | KjellKod/g3log | 248 | defect | f2b860a2b49323d2c00c0b6896698b6880145855 | 122387b4bd92e5838c2857c01057cda12c6223db | G3log placeholder thread ID formatting | 1. Enable custom formattting of log entries.
2. See also g3sinks enabling of this feature https://github.com/KjellKod/g3sinks/pull/53
3. See also updated API.markdownt](https://github.com/KjellKod/g3log/blob/g3log-placeholder-threadid-formatting/API.markdown) | diff --git a/API.markdown b/API.markdown
index 8e903740c..94a6a5648 100644
--- a/API.markdown
+++ b/API.markdown
@@ -7,6 +7,12 @@ Most of the API that you need for using g3log is described in this readme. For m
* disable/enabled levels at runtime
* custom logging levels
* Sink [creation](#sink_creation) and util... | 1 | 1 | 1 | [{"id": "G0", "claim": "The API.markdown snippet for adding thread ID to the log formatting should reference `FullLogDetailsToString(...)` instead of `DefaultLogDetailsToString(...)`.", "category": "documentation", "verdict": "supported", "priority": "P1", "scope": "introduced"}] | null |
KjellKod__g3log__254 | KjellKod/g3log | 254 | defect | 14db37ad2313292e4d950fb0c959e92f3182ca48 | 84770d830f6f7d1e1ec5b4453de182a40f7a94ac | restore original sigaction in restoreSignalHandler | - Save original sigactions in a map called gSavedSigActions
- In restoreSignalHandler, do nothing if there is no saved sigaction.
If there is a saved sigaction, then re-install it.
- Fixes issue #253
| diff --git a/src/crashhandler_unix.cpp b/src/crashhandler_unix.cpp
index 3e1b7fe6a..e9732c699 100644
--- a/src/crashhandler_unix.cpp
+++ b/src/crashhandler_unix.cpp
@@ -48,7 +48,7 @@ namespace {
};
std::map<int, std::string> gSignals = kSignals;
-
+ std::map<int, struct sigaction> gSavedSigActions;
bo... | 2 | 2 | 2 | [{"id": "G0", "claim": "The error-handling code for `sigaction() < 0` is untested and hard to test as written; the reviewer suggests breaking that logic out into its own function so it can be tested.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "When `... | null |
KjellKod__g3log__392 | KjellKod/g3log | 392 | defect | 2fca06ff6da5c67465b591f4d45e8fd14d531142 | 9c41698ead261167be8080188e300b358cf18708 | Replace std::result_of with std::invoke_result | C++17 deprecates `std::result_of<T>` and C++20 completely removes it from the spec in favor of `std::invoke_result<T>`, preventing compilation of g3log if using C++20-level features.
This is the simplest fix which merely replaces all instances of the former with the latter, but it will break compilation on C++14 or ... | diff --git a/.vscode/settings.json b/.vscode/settings.json
new file mode 100644
index 000000000..0115e5c59
--- /dev/null
+++ b/.vscode/settings.json
@@ -0,0 +1,7 @@
+{
+ "files.associations": {
+ "SConscript": "python",
+ "*.md.html": "markdown",
+ "type_traits": "cpp"
+ }
+}
\ No newline at ... | 1 | 1 | 0 | [{"id": "G0", "claim": "Remove the .vscode/settings.json file the PR adds.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
Kludex__python-multipart__120 | Kludex/python-multipart | 120 | defect | c9895359ae91d4b488172c449eadde99528b46a1 | 359b12d9f05951853431db622ff00b4608af4da0 | Remove `slow_test` pytest marker | Get rid of the warning emitted by pytest due to slow_test not being a registered mark. | diff --git a/pyproject.toml b/pyproject.toml
index 6a424bb..269eec3 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -70,6 +70,11 @@ packages = ["multipart"]
[tool.hatch.build.targets.sdist]
include = ["/multipart", "/tests"]
+[tool.pytest.ini_options]
+markers = [
+ "slow_test: marks tests as slow (deselect ... | 2 | 2 | 0 | [{"id": "G0", "claim": "The tests should import pytest directly (`import pytest`) instead of `from pytest import mark`.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The slow_test marker may serve no real purpose since the tests are not particu... | null |
Kludex__python-multipart__166 | Kludex/python-multipart | 166 | defect | 5303590e767c8f6125729912923cddedb1cc0946 | 6896813c8724210ef14810e183edfa76d2edfa64 | refactor: rename import to python_multipart | This renames the import to `python_multipart`, and installs a custom Finder that allows legacy code to continue to work unless the PyPI `multipart` package is installed, in which case the custom Finder no longer does anything. A warning is shown asking the user to `import python_multipart` instead of `import multipart`... | diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml
index 2fbd796..fdeed33 100644
--- a/.github/workflows/main.yml
+++ b/.github/workflows/main.yml
@@ -33,6 +33,9 @@ jobs:
- name: Run tests
run: scripts/test
+ - name: Run rename test
+ run: uvx nox -s rename -P ${{ matrix.... | 3 | 3 | 1 | [{"id": "G0", "claim": "The FutureWarning message in _python_multipart_loader.py should end with a period.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The new import scheme breaks `import multipart` for real downstream users (Google Colab insta... | null |
Kludex__python-multipart__196 | Kludex/python-multipart | 196 | defect | 3e909f52a774365b8817a52d4312db4ba8061d07 | d6476c2b9205e4596a7bef82ca88349b3de2b9c6 | Remove unused `trust_x_headers` parameter and `X-File-Name` fallback | Use the boolean.
Note that this changes the default behavior but makes it consistent with what the function documentation was declaring.
If we want to maintain behaviour, we may want to expose this in option in `parse_form`. | diff --git a/python_multipart/multipart.py b/python_multipart/multipart.py
index f26a815..55a92fe 100644
--- a/python_multipart/multipart.py
+++ b/python_multipart/multipart.py
@@ -1241,7 +1241,7 @@ def data_callback(name: CallbackName, end_i: int, remaining: bool = False) -> No
elif state == MultipartStat... | 5 | 2 | 1 | [{"id": "G0", "claim": "It is questionable whether removing the trust_x_headers parameter from create_form_parser actually makes sense.", "category": "design", "verdict": "opposed", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The X-File-Name fallback should also be removed because it is not really ... | null |
Kludex__starlette__1041 | Kludex/starlette | 1,041 | defect | c566fc6c819f0d565f8cff432351fe009e83d866 | f625437d2e8fe4555de612806240728716ea97cd | fix 793: allow custom async iterator | When a custom async iterator is passed to `StreamingResponse`, the type of object is determined by `inspect.isasyncgen`. This method does an `isinstance` check against the default python iterator and therefore does not work on custom objects implementing the async iterator protocol. (Closes #793)
| diff --git a/starlette/responses.py b/starlette/responses.py
index 24dfb2c84..c5172220c 100644
--- a/starlette/responses.py
+++ b/starlette/responses.py
@@ -204,7 +204,7 @@ def __init__(
media_type: str = None,
background: BackgroundTask = None,
) -> None:
- if inspect.isasyncgen(content):... | 2 | 2 | 2 | [{"id": "G0", "claim": "The `hasattr(content, '__aiter__') and hasattr(content, '__anext__')` check misses objects that implement `__aiter__` but not `__anext__` (such as async generator objects), and the check should instead be `isinstance(content, typing.AsyncIterable)`.", "category": "correctness", "verdict": "suppo... | null |
Kludex__starlette__1106 | Kludex/starlette | 1,106 | defect | e4307065ea6dbe708fba9643d14fe7adfff06d46 | 3d51c63603cb360fdf415655e77282bced7b3d59 | Fix functools.partial async handlers for classmethods | This was my fault for not properly checking all of the cases when I added #984. Apparently, on Python 3.8, partials of classmethods are still not correctly identified as coroutines.
An attempt to fix #1107 | diff --git a/starlette/routing.py b/starlette/routing.py
index ce5e4d192..b30e1ee4c 100644
--- a/starlette/routing.py
+++ b/starlette/routing.py
@@ -2,7 +2,6 @@
import functools
import inspect
import re
-import sys
import traceback
import typing
from enum import Enum
@@ -33,11 +32,10 @@ class Match(Enum):
def is... | 1 | 1 | 0 | [{"id": "G0", "claim": "The docstring of iscoroutinefunction_or_partial should describe what the function does rather than how it works, using the suggested wording 'including those wrapped in functools.partial objects.' instead of 'by unwrapping functools.partial objects.'", "category": "documentation", "verdict": "su... | null |
Kludex__starlette__1147 | Kludex/starlette | 1,147 | defect | 23e15789bf6b879b455f1249e47a43d4c752b3ed | c73f00cb02d520992e18423f06bf6a776eb4a75b | Make session cookie use ASGI root path | Fixes #233 | diff --git a/starlette/middleware/sessions.py b/starlette/middleware/sessions.py
index d1b1d5a0f..76663eb5a 100644
--- a/starlette/middleware/sessions.py
+++ b/starlette/middleware/sessions.py
@@ -49,14 +49,17 @@ async def __call__(self, scope: Scope, receive: Receive, send: Send) -> None:
async def send_wra... | 4 | 4 | 3 | [{"id": "G0", "claim": "The PR's change of the session cookie path behaviour needs a test case.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "scope[\"root_path\"] could fail with a KeyError because root_path is Optional in the ASGI spec; use scope.get(... | null |
Kludex__starlette__1240 | Kludex/starlette | 1,240 | defect | 537ab6afd110b79dca95f3c8ecc6980710b1de1c | 2e720d862ba9eec9d2e66a35c406800d0ce10557 | Add union operators to MutableHeaders | Fix for issue #1239
Edit by @Kludex: Closes #1239 | diff --git a/starlette/datastructures.py b/starlette/datastructures.py
index 5149a6e2e5..15f3e64c2d 100644
--- a/starlette/datastructures.py
+++ b/starlette/datastructures.py
@@ -604,6 +604,21 @@ def __delitem__(self, key: str) -> None:
for idx in reversed(pop_indexes):
del self._list[idx]
+ ... | 4 | 4 | 2 | [{"id": "G0", "claim": "Implement __ior__ and __or__ in terms of update() instead of hand-rolling the loop and typechecking the operand.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G2", "claim": "The deliberate non-mapping operand literals in test_mutable_headers_me... | null |
Kludex__starlette__1349 | Kludex/starlette | 1,349 | defect | f12c92a21500d484b3d48f965bb605c1bbe193bc | 0e0e2c73c0e944851b5c8ab310a0b7322c2d881a | Raise a more obvious exception when form data is missing "boundary". | The best strategy is to let KeyError raise when parsing request with missing boundary parameter, so end-user can process KeyError exception in their code.
Closes #1125
Related to #1303 | diff --git a/starlette/formparsers.py b/starlette/formparsers.py
index decaf0bfd..fd1949229 100644
--- a/starlette/formparsers.py
+++ b/starlette/formparsers.py
@@ -159,7 +159,7 @@ async def parse(self) -> FormData:
charset = params.get(b"charset", "utf-8")
if type(charset) == bytes:
char... | 5 | 5 | 0 | [{"id": "G0", "claim": "Add a blank line after the newly added `import pytest` to separate it from the starlette imports.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "Use double quotes in the pytest.raises pattern, i.e. match=\"boundary\", ins... | null |
Kludex__starlette__1353 | Kludex/starlette | 1,353 | defect | f53faba229e3fa2844bc3753e233d9c1f54cca52 | 29b69426fbb102ea64c1ff20c2e14b1e2d104795 | Add Mypy checks to tests | Closes #1045.
Adds Mypy checks to the tests.
I'll add a few comments where it can be confusing to review this. | diff --git a/setup.cfg b/setup.cfg
index 20c2588a1..09ecda353 100644
--- a/setup.cfg
+++ b/setup.cfg
@@ -8,8 +8,7 @@ ignore_missing_imports = True
[mypy-tests.*]
disallow_untyped_defs = False
-# https://github.com/encode/starlette/issues/1045
-# check_untyped_defs = True
+check_untyped_defs = True
[tool:isort]
... | 3 | 3 | 0 | [{"id": "G0", "claim": "The `q.update(None) # type: ignore` case in test_multidict is stale since MultiDict.update no longer accepts None, and the test case should be removed (or the call replaced with `q.update()`).", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1"... | null |
Kludex__starlette__1395 | Kludex/starlette | 1,395 | defect | 0081d46d85c71e8a8e35852104488d36e0e577fc | d8fcbfeedebf79ac81c4eec247dc2610074997b4 | Don't omit `Content-Length` header for `Content-Length: 0` cases | This PR adds the `content-length` header by default, if not already included. For more information, please check on #1099 and the referred RFC.
Next step would be to add a conditional to check if `status_code` < 200 and `status_code` != (204, 304)`
Closes #1099 | diff --git a/starlette/responses.py b/starlette/responses.py
index 1f9c43a21..8905acf18 100644
--- a/starlette/responses.py
+++ b/starlette/responses.py
@@ -70,8 +70,8 @@ def init_headers(self, headers: typing.Mapping[str, str] = None) -> None:
populate_content_length = b"content-length" not in keys
... | 2 | 2 | 2 | [{"id": "G0", "claim": "The reviewer asks to revert the FileResponse change from direct assignment to setdefault on content-length, since StreamingResponse and FileResponse will fail under the new assumption; revert first and sort out the failures once the test cases are identified.", "category": "correctness", "verdic... | null |
Kludex__starlette__1417 | Kludex/starlette | 1,417 | defect | fcc4c705ff69182ebd663bc686cb55c242d32683 | 6fa1401f0bf97b607188c111fef33bbfa0ca7557 | Add reason to WebSocket closure | Closes #991.
According to the ASGI spec [here](https://asgi.readthedocs.io/en/latest/specs/www.html#close-send-event) `reason` can be included in `websocket.close` which is an optional string.
<del>I think what @Kludex mentioned [here](https://github.com/encode/starlette/pull/1339#pullrequestreview-812914693) mak... | diff --git a/docs/websockets.md b/docs/websockets.md
index 43406aced..192162931 100644
--- a/docs/websockets.md
+++ b/docs/websockets.md
@@ -75,7 +75,7 @@ Use `websocket.receive_json(data, mode="binary")` to receive JSON over binary da
### Closing the connection
-* `await websocket.close(code=1000)`
+* `await webs... | 5 | 4 | 1 | [{"id": "G0", "claim": "The docs example should read `await websocket.close(code=1000, reason=None)` instead of hardcoding `reason=\"Normal Closure\"`.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Keep the default close code at 1000 instead of c... | null |
Kludex__starlette__1444 | Kludex/starlette | 1,444 | defect | 199fc703f3078bd5b0e1aca0e9f4ab236b03f029 | 636a26f6afe679b1dd1326eff46ed8af83a0e13f | Improve detection of async callables | - Closes #886
- Related to #1256
References:
- https://github.com/django/asgiref/issues/251
- https://github.com/django/asgiref/blob/3554e05def93e086690d19e9f38e593f1b5b7b61/asgiref/sync.py#L28-L40
- https://gitlab.com/pgjones/quart/-/blob/main/src/quart/utils.py#L102-128 | diff --git a/starlette/_utils.py b/starlette/_utils.py
new file mode 100644
index 000000000..7049c69c4
--- /dev/null
+++ b/starlette/_utils.py
@@ -0,0 +1,12 @@
+import asyncio
+import functools
+import typing
+
+
+def iscoroutinefunction(obj: typing.Any) -> bool:
+ while isinstance(obj, functools.partial):
+ ... | 5 | 3 | 0 | [{"id": "G0", "claim": "The new helper should use inspect.iscoroutinefunction instead of asyncio.iscoroutinefunction, since asyncio's version only adds a check for the deprecated @coroutine decorator.", "category": "design", "verdict": "uncertain", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "A test... | null |
Kludex__starlette__1459 | Kludex/starlette | 1,459 | defect | 84820a25f2237c7c8fe7911f4fea2394f02994e8 | 6d848bbf206b1b1e4a3d339568afb1934404bbb8 | Prevent BaseHTTPMiddleware from hiding errors of StreamingResponse | The issue is observed when:
* an application uses a BaseHTTPMiddleware subclass;
* it provides StreamingResponse;
* there is an exception raised inside the generator wrapped with StreamingResponse.
Prior to v0.17.0 the exception was raised and the traceback was printed to the server logs. Now it is silently ... | diff --git a/starlette/middleware/base.py b/starlette/middleware/base.py
index 423f40777..f7cf1cce1 100644
--- a/starlette/middleware/base.py
+++ b/starlette/middleware/base.py
@@ -47,11 +47,16 @@ async def coro() -> None:
assert message["type"] == "http.response.start"
async def body_stream... | 3 | 2 | 0 | [{"id": "G0", "claim": "The `nonlocal app_exc` statement inside `body_stream` shouldn't be necessary since nothing assigns to `app_exc` there.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The PR should add a test showing that an exception rais... | null |
Kludex__starlette__1472 | Kludex/starlette | 1,472 | defect | a6d3d8f0179cb1c2ac283bb5db779f6075854a66 | 7004dd72d3a9865b5c65199130ffda4191c15e88 | Replace WebSocket assertions with RuntimeError | Fixes #1471.
Switching public facing WebSocket assertions to RuntimeError. | diff --git a/starlette/websockets.py b/starlette/websockets.py
index da7406047..58eb23c4b 100644
--- a/starlette/websockets.py
+++ b/starlette/websockets.py
@@ -34,13 +34,20 @@ async def receive(self) -> Message:
if self.client_state == WebSocketState.CONNECTING:
message = await self._receive()
... | 1 | 1 | 0 | [{"id": "G0", "claim": "The four RuntimeError messages should be styled as f-strings of the form 'Expected ASGI message \"websocket.connect\", but got {message_type!r}' instead of the static 'WebSocket is not connected. Need to call \"accept\" first.' texts.", "category": "maintainability", "verdict": "supported", "pri... | null |
Kludex__starlette__1617 | Kludex/starlette | 1,617 | defect | a3a3c4f6d31791ad6b8b2e2eb6543a8a8355c1d1 | 4f1679d113254966db20d17742408a3a7e92bc84 | Add 400 response when `boundary` is missing | - Closes #1588
- Related to #1303 (I've not included it on this PR for now...)
- Replaces #1593 (monologue about possible solutions from there is important)
Behavior of this PR:
- Custom exception in case `"app" not in scope`.
- `HTTPException(status_code=400)` in case `"app" in scope`.
Changes:
- Move `HTTP... | diff --git a/starlette/exceptions.py b/starlette/exceptions.py
index 61039c5980..affb9793e2 100644
--- a/starlette/exceptions.py
+++ b/starlette/exceptions.py
@@ -1,31 +1,13 @@
import asyncio
-import http
import typing
from starlette.concurrency import run_in_threadpool
+from starlette.http_exception import HTTPEx... | 6 | 2 | 0 | [{"id": "G0", "claim": "Moving HTTPException out of starlette/exceptions.py into a new starlette/http_exception.py module is questioned - why is the move needed?", "category": "design", "verdict": "opposed", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "MultiPartException defines a custom __init__ wh... | null |
Kludex__starlette__1648 | Kludex/starlette | 1,648 | defect | 7b9fcaf31d4d23f91ca96181188f5440c3f63201 | ef329ba0a22864c65ab76bfabf778bd464d4b571 | Remove converter from path when generating `OpenAPI` schema | - Closes https://github.com/encode/starlette/issues/1646
- Closes #746
To be more correct, I'd have to add the information about the type of the path parameter... | diff --git a/starlette/schemas.py b/starlette/schemas.py
index 6ca764fdc..4f91f5ae9 100644
--- a/starlette/schemas.py
+++ b/starlette/schemas.py
@@ -1,4 +1,5 @@
import inspect
+import re
import typing
from starlette.requests import Request
@@ -49,10 +50,11 @@ def get_endpoints(
for route in routes:
... | 1 | 1 | 0 | [{"id": "G0", "claim": "Add an example to the `_remove_converter` docstring making the intent clear: a route like `Route(\"/users/{id:int}\", endpoint=get_user, methods=[\"GET\"])` should be represented as `/users/{id}` in the OpenAPI schema.", "category": "documentation", "verdict": "supported", "priority": "P2", "sco... | null |
Kludex__starlette__2334 | Kludex/starlette | 2,334 | defect | 93494a46ee0f2e8b1eeafd12e466ebac15037b41 | e4174085437c7598d420514a6cbc79c9ea0db958 | Take weak ETags in consideration on `StaticFiles` | <!-- Thanks for contributing to Starlette! 💚
Given this is a project maintained by volunteers, please read this template to not waste your time, or ours! 😁 -->
# Summary
fix #2298.
# Checklist
- [x] I understand that this PR may be closed in case there was no previous discussion. (This doesn't apply to t... | diff --git a/starlette/responses.py b/starlette/responses.py
index bc8b23f1c..e531806c7 100644
--- a/starlette/responses.py
+++ b/starlette/responses.py
@@ -305,7 +305,7 @@ def set_stat_headers(self, stat_result: os.stat_result) -> None:
content_length = str(stat_result.st_size)
last_modified = format... | 1 | 1 | 0 | [{"id": "G0", "claim": "The new regex-based If-None-Match comparison in is_not_modified should be simplified to avoid regexes where they are not required, e.g. matching the suggested split/strip line.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
Kludex__starlette__2501 | Kludex/starlette | 2,501 | defect | a766a58d14007f07c0b5782fa78cdc370b892796 | 6228330a9068416ce277f668676e27ee97580e51 | feat: add partitioned attribute to cookie | <!-- Thanks for contributing to Starlette! 💚
Given this is a project maintained by volunteers, please read this template to not waste your time, or ours! 😁 -->
# Summary
<!-- Write a small summary about what is happening here. -->
Added the `partitioned` attribute.
See https://github.com/encode/starlette/d... | diff --git a/docs/responses.md b/docs/responses.md
index a19f77018..d2e3dc153 100644
--- a/docs/responses.md
+++ b/docs/responses.md
@@ -31,7 +31,7 @@ async def app(scope, receive, send):
Starlette provides a `set_cookie` method to allow you to set cookies on the response object.
-Signature: `Response.set_cookie(k... | 3 | 3 | 2 | [{"id": "G0", "claim": "Setting `partitioned` on Python <3.14 fails because SimpleCookie rejects the attribute; the change should not raise an error on older Python versions.", "category": "correctness", "verdict": "supported", "priority": "P0", "scope": "introduced"}, {"id": "G1", "claim": "An error should be raised w... | null |
Kludex__starlette__2620 | Kludex/starlette | 2,620 | defect | 5a1bec33f8d6a669a3670f51034de83292d19408 | dcfff2f07756c5b6cd0f06b8baf73ad2f9873c11 | Don't poll for disconnects in BaseHTTPMiddleware via StreamingResponse | Fixes #2516 | diff --git a/starlette/middleware/base.py b/starlette/middleware/base.py
index 4e5054d7a..0d5ccd902 100644
--- a/starlette/middleware/base.py
+++ b/starlette/middleware/base.py
@@ -6,9 +6,8 @@
from anyio.abc import ObjectReceiveStream, ObjectSendStream
from starlette._utils import collapse_excgroups
-from starlette... | 4 | 3 | 2 | [{"id": "G0", "claim": "The new `sleepy` test endpoint in the stacked-middlewares test should declare its return type as `Response`.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "It may be worth adding a section to the Starlette middleware docs... | null |
Kludex__starlette__2671 | Kludex/starlette | 2,671 | defect | c78c9aac17a4d68e0647252310044502f1b7da71 | ddfc5c0bff75315f62284e6c7f350985064c891e | Add support for ASGI `pathsend` extension | # Summary
As per title, this adds support for [ASGI pathsend](https://asgi.readthedocs.io/en/latest/extensions.html#path-send) extension on `FileResponse` class for servers implementing it.
This is a re-work of #2435 combined with parts of #2616, as discussed in #2613 with @Kludex.
# Checklist
- [x] I under... | diff --git a/docs/middleware.md b/docs/middleware.md
index 9e5601819f..23f0eeb840 100644
--- a/docs/middleware.md
+++ b/docs/middleware.md
@@ -264,6 +264,7 @@ around explicitly, rather than mutating the middleware instance.
Currently, the `BaseHTTPMiddleware` has some known limitations:
- Using `BaseHTTPMiddleware`... | 1 | 1 | 1 | [{"id": "G0", "claim": "The PR should edit `BaseHTTPMiddleware` (now that it has its own Response class) so the ASGI pathsend extension works through it, instead of only documenting in the docs that pathsend does not work with this middleware.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "... | null |
Kludex__starlette__2752 | Kludex/starlette | 2,752 | defect | c2e3a39b09a613553ee03586589ed9cd0fbf07f3 | 4303e102f993e9f280d3851b0ba5a46d3bccbb13 | Fix issue with middleware args passing | # Summary
A feature introduced in #2381 doesn't allow to pass args inside middleware, here is an example:
```py
from starlette.applications import Starlette
from starlette.types import ASGIApp, Receive, Scope, Send
from starlette.testclient import TestClient
class Middleware:
def __init__(self, app: AS... | diff --git a/starlette/applications.py b/starlette/applications.py
index 0feae72e4..aae38f588 100644
--- a/starlette/applications.py
+++ b/starlette/applications.py
@@ -10,7 +10,7 @@
from typing_extensions import ParamSpec
from starlette.datastructures import State, URLPath
-from starlette.middleware import Mid... | 4 | 1 | 0 | [{"id": "G0", "claim": "Accessing self.cls.__name__ directly in Middleware.__repr__ may error for callables without __name__, so it should use getattr(self.cls, \"__name__\", \"\") (or alternatively add __name__ to the protocol) to make sure it never errors.", "category": "correctness", "verdict": "supported", "priorit... | null |
Kludex__starlette__2806 | Kludex/starlette | 2,806 | defect | 827de43b97ad58c7b8daae12ad17c1848a4f1341 | cbc7f8783f3926c40d9a37e6cfc4acc1a16f3d4b | Make UUID path parameter conversion more flexible | <!-- Thanks for contributing to Starlette! 💚
Given this is a project maintained by volunteers, please read this template to not waste your time, or ours! 😁 -->
# Summary
Based on @adriangb suggestion made in this [discussion thread](https://github.com/encode/starlette/discussions/2802#discussioncomment-1158384... | diff --git a/starlette/convertors.py b/starlette/convertors.py
index 2d8ab53beb..84df87a586 100644
--- a/starlette/convertors.py
+++ b/starlette/convertors.py
@@ -67,7 +67,7 @@ def to_string(self, value: float) -> str:
class UUIDConvertor(Convertor[uuid.UUID]):
- regex = "[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-... | 1 | 1 | 0 | [{"id": "G0", "claim": "Keep test_default_float_convertor unchanged and add a separate new test for the uuid convertor instead of merging the float test into one combined parameterized test.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
Kludex__starlette__2808 | Kludex/starlette | 2,808 | defect | f884b6649ea7e0b019443a265db7ff62ebe7914b | a13b42d4752572887ad5bdba666000d4b4052b39 | Remove deprecated `allow_redirects` argument from `TestClient` | # Summary
As discussed in #2805 and related to #2783 .
Remove the deprecated `allow_redirects` argument from `TestClient`, and update the tests and `pyproject.toml`.
# Checklist
- [x] I understand that this PR may be closed in case there was no previous discussion. (This doesn't apply to typos!)
- [ ] I'... | diff --git a/pyproject.toml b/pyproject.toml
index f27646083..18b954c84 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -87,7 +87,6 @@ filterwarnings = [
"ignore: Async generator 'starlette.requests.Request.stream' was garbage collected before it had been exhausted.*:ResourceWarning",
"ignore: path is dep... | 1 | 1 | 0 | [{"id": "G0", "claim": "The class-level `redirect` attribute added to TestClient is redundant because `redirect` is already a parameter of `__init__`.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
Kludex__starlette__2810 | Kludex/starlette | 2,810 | defect | 4e625bb9793f36a1ff9d30f935d7bc83513c71fe | d6b8106a40c188fd53d475c48adfbed100533789 | Add `client` parameter to `TestClient` | # Summary
Fixes https://github.com/encode/starlette/issues/2295
Added client and port parameter to TestClient
| diff --git a/starlette/testclient.py b/starlette/testclient.py
index 2c096aa22..63eb8259f 100644
--- a/starlette/testclient.py
+++ b/starlette/testclient.py
@@ -234,6 +234,8 @@ def __init__(
raise_server_exceptions: bool = True,
root_path: str = "",
*,
+ client: str,
+ port: int... | 2 | 2 | 1 | [{"id": "G0", "claim": "The new `client` parameter should be typed as `tuple[str, int]` (with default `(\"testclient\", 5000)` in `TestClient.__init__`) instead of `str` plus a separate `port` parameter.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The... | null |
Kludex__starlette__2814 | Kludex/starlette | 2,814 | defect | ea7ce8a5b04669d02bd4911ff53ab6b4cef7c835 | 3fde98b8002e23422beb2c18410489e9f120ec2e | collect errors more reliably from websocket test client | …iddleware' children
Co-authored-by: Thomas Grainger <413772+graingert@users.noreply.github.com>
Co-authored-by: Nikita Gashkov <8746283+nikitagashkov@users.noreply.github.com><!-- Thanks for contributing to Starlette! 💚
Given this is a project maintained by volunteers, please read this template to not waste your... | diff --git a/starlette/testclient.py b/starlette/testclient.py
index 2c096aa22..69a930bad 100644
--- a/starlette/testclient.py
+++ b/starlette/testclient.py
@@ -1,6 +1,7 @@
from __future__ import annotations
import contextlib
+import enum
import inspect
import io
import json
@@ -16,10 +17,9 @@
import anyio
imp... | 3 | 1 | 1 | [{"id": "G0", "claim": "Restore the `from anyio.abc import ObjectReceiveStream, ObjectSendStream` import that the pull request removed, since the names are still needed.", "category": "correctness", "verdict": "supported", "priority": "P0", "scope": "introduced"}, {"id": "G2", "claim": "Consider using an `if sys.versio... | null |
Kludex__starlette__2815 | Kludex/starlette | 2,815 | defect | ea7ce8a5b04669d02bd4911ff53ab6b4cef7c835 | e32c078d2d3f3a2bf0839699ae5050850eaf56c8 | Add `max_part_size` parameter to `MultiPartParser` | Fixes #2785
Also addresses issue discussed in [FastAPI Repo](https://github.com/fastapi/fastapi/discussions/12961#discussioncomment-11336476). | diff --git a/starlette/formparsers.py b/starlette/formparsers.py
index 82e2ad195..bfcd1f473 100644
--- a/starlette/formparsers.py
+++ b/starlette/formparsers.py
@@ -122,9 +122,6 @@ async def parse(self) -> FormData:
class MultiPartParser:
- max_file_size = 1024 * 1024 # 1MB
- max_part_size = 1024 * 1024 # ... | 4 | 3 | 2 | [{"id": "G0", "claim": "The constructor's own default for max_part_size should be removed and the default kept only at the top-most function.", "category": "design", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The pull request should make only max_part_size configurable, not b... | null |
Kludex__starlette__2865 | Kludex/starlette | 2,865 | defect | a7d0b14c7378aa2e95b0b13583fe0dadace363be | 614fab9842a5cd59f052489071fb9d0510a0fed9 | fix(gzip): Make sure Vary header is always added if a response can be compressed | Fixes #2863
<!-- Thanks for contributing to Starlette! 💚
Given this is a project maintained by volunteers, please read this template to not waste your time, or ours! 😁 -->
# Summary
<!-- Write a small summary about what is happening here. -->
Since the presense or absense of the `Accept-Encoding` header ca... | diff --git a/starlette/middleware/gzip.py b/starlette/middleware/gzip.py
index b677063da3..a36e303d9f 100644
--- a/starlette/middleware/gzip.py
+++ b/starlette/middleware/gzip.py
@@ -13,32 +13,36 @@ def __init__(self, app: ASGIApp, minimum_size: int = 500, compresslevel: int = 9
self.compresslevel = compressle... | 3 | 2 | 1 | [{"id": "G0", "claim": "The pull request could avoid the huge diff by simply moving the add_vary_header call up instead of the large responder refactor.", "category": "design", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "apply_compression flushes the gzip file on every chunk, ... | null |
Kludex__starlette__2939 | Kludex/starlette | 2,939 | defect | 4acf1d1ca3e8aa767567cb4e6e12f093f066553b | db042b16bce1c37ecd5e4ad616d4df27543915aa | feat: implement rfc9110 http status names | # Summary
rfc9110 obsoletes the earlier rfc 7231. This document also includes some status codes that were previously only used for WebDAV and assigns more generic names to these status codes.
ref: https://www.rfc-editor.org/rfc/rfc9110.html#name-changes-from-rfc-7231
The status code constants are updated to re... | diff --git a/starlette/status.py b/starlette/status.py
index 54c1fb7d0..ddcf5865a 100644
--- a/starlette/status.py
+++ b/starlette/status.py
@@ -3,7 +3,7 @@
See HTTP Status Code Registry:
https://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml
-And RFC 2324 - https://tools.ietf.org/html/rfc2324
+... | 1 | 1 | 1 | [{"id": "G0", "claim": "The renamed RFC 9110 status names should be kept backwards compatible via a module-level __getattr__ deprecation shim (as in the referenced starlette commit) instead of plain alias assignments.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}] | null |
Kludex__starlette__2962 | Kludex/starlette | 2,962 | defect | fa5355442753f794965ae1af0f87f9fec1b9a3de | f14ee57f3ad4659a0496e509f9fa9ef08baf5697 | Make UploadFile check for future rollover | <!-- Thanks for contributing to Starlette! 💚
Given this is a project maintained by volunteers, please read this template to not waste your time, or ours! 😁 -->
# Summary
This PR ensures that during multi-part form parsing any slow disk IO happens in a background. This specifically fixes a case where a file wou... | diff --git a/starlette/datastructures.py b/starlette/datastructures.py
index 70dacd024..e032d2642 100644
--- a/starlette/datastructures.py
+++ b/starlette/datastructures.py
@@ -428,6 +428,11 @@ def __init__(
self.size = size
self.headers = headers or Headers()
+ # Capture max size from Spoole... | 2 | 1 | 1 | [{"id": "G0", "claim": "The new large-file test passes on master, so the pull request needs a condition that proves it actually solves the issue.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "In a future PR (not this one) the rollover logic could be mo... | null |
Kludex__starlette__2996 | Kludex/starlette | 2,996 | defect | 1ee8f857048368b3603f32f91a1214390e79d614 | 3b30b1182839a04eb51381323c888530fade2804 | Set encodings when reading config files | <!-- Thanks for contributing to Starlette! 💚 Given this is a project maintained by volunteers, please read this template to not waste your time, or ours! 😁 -->
# Summary
Fixes UnicodeDecodeError by allowing explicit encoding selection when reading .env files.
Resolves https://github.com/encode/starlette/discussi... | diff --git a/starlette/config.py b/starlette/config.py
index 091f857f3..3f9243bbf 100644
--- a/starlette/config.py
+++ b/starlette/config.py
@@ -107,9 +107,9 @@ def get(
return self._perform_cast(key, default, cast)
raise KeyError(f"Config '{key}' is missing, and has no default.")
- def _read... | 2 | 2 | 1 | [{"id": "G0", "claim": "The Config class must accept an `encoding` argument and pass it to `_read_file`, otherwise the encoding used to read environment files can never be different from utf-8.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The `encoding... | null |
Kludex__starlette__3065 | Kludex/starlette | 3,065 | defect | 4941b4a04993d087dea66e9287fe9472babee879 | dc830b27837d0c2ae10856946c4183f35d5c7102 | Add `allow_private_network` in `CORSMiddleware` | - Closes https://github.com/Kludex/starlette/issues/3064
Reference used for this PR:
- https://github.com/Kludex/starlette/pull/2621/
- https://github.com/adamchainz/django-cors-headers/pull/833/
- https://developer.chrome.com/blog/private-network-access-preflight | diff --git a/starlette/middleware/cors.py b/starlette/middleware/cors.py
index ffd8aefc6..be421a1d7 100644
--- a/starlette/middleware/cors.py
+++ b/starlette/middleware/cors.py
@@ -21,6 +21,7 @@ def __init__(
allow_headers: Sequence[str] = (),
allow_credentials: bool = False,
allow_origin_reg... | 4 | 1 | 0 | [{"id": "G0", "claim": "Remove the bare 'Handle Private Network Access' comment (raised via an empty suggestion block).", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Expand the 'Handle Private Network Access' comment to explain the behavior: al... | null |
Kludex__starlette__488 | Kludex/starlette | 488 | defect | 2d88c4cd295967bffb9828a7cd39eaade4a84bbc | 997bb591e6f15a53ba23ca70423944234b2af4ac | Send lifespan.startup.failed if exception occurs during startup | Fixes #486.
Note: requires https://github.com/encode/uvicorn/pull/350 to work. With the current state of uvicorn (0.7.0), the `ASGI 'lifespan' protocol appears unsupported.` message is still displayed and startup does not abort.
With:
```python
# app.py
from starlette.applications import Starlette
app = S... | diff --git a/starlette/routing.py b/starlette/routing.py
index d013591b0..dbc4dca96 100644
--- a/starlette/routing.py
+++ b/starlette/routing.py
@@ -1,6 +1,7 @@
import asyncio
import inspect
import re
+import traceback
import typing
from enum import Enum
@@ -469,8 +470,14 @@ async def shutdown(self) -> None:
... | 5 | 5 | 2 | [{"id": "G0", "claim": "In the failure case the test client should wait for the None sentinel message and then call self.task.result() so startup errors actually surface, verified by a test.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "Run scripts... | null |
Kludex__starlette__761 | Kludex/starlette | 761 | defect | 199fc703f3078bd5b0e1aca0e9f4ab236b03f029 | 93608f999baf8dcb37e770e57b450fc5f0c5eb3f | Make error handler run always | EDIT by @Kludex : Closes #739 | diff --git a/starlette/middleware/errors.py b/starlette/middleware/errors.py
index 30f5570ca..38c92b400 100644
--- a/starlette/middleware/errors.py
+++ b/starlette/middleware/errors.py
@@ -158,20 +158,23 @@ async def _send(message: Message) -> None:
try:
await self.app(scope, receive, _send)
... | 4 | 3 | 1 | [{"id": "G0", "claim": "A test should be added that checks the error handler is still called when a response has already started.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The new behaviour — the installed error handler runs even after the response... | null |
Kludex__starlette__933 | Kludex/starlette | 933 | defect | 152a05ac3ddba5456ee05fb81d0f2ea3eaf17c2b | bb15192285e13b540feda5b2c83aab0d31aff818 | Thread pool is no longer used for files in memory | Closes #819
Here I made a judgment, when the file is in memory, no longer use the thread pool to operate. This can save a lot of thread switching time. | diff --git a/requirements.txt b/requirements.txt
index dc18d7897..4061b3955 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -16,6 +16,7 @@ isort
mypy
pytest
pytest-cov
+pytest-asyncio
# Documentation
mkdocs
diff --git a/starlette/datastructures.py b/starlette/datastructures.py
index bbfd93ea5..218e5edf9 ... | 4 | 4 | 2 | [{"id": "G0", "claim": "The new `in_memory` property should probably not be public API on `UploadFile`.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The `in_memory` check could be changed to `rolled_to_disk = getattr(self.file, '_rolled', True)` follow... | null |
Kludex__uvicorn__1300 | Kludex/uvicorn | 1,300 | defect | 66e22f86ca2fcce4a9bc1489b6c28afaa0ad9dbd | d54ad4251d919fe93caa677e43c8303e7f1bff00 | allow configurable websocket per-message-deflate setting | closes #1298
please take a look, thanks! | diff --git a/tests/protocols/test_websocket.py b/tests/protocols/test_websocket.py
index b444b3ffca..63def17854 100644
--- a/tests/protocols/test_websocket.py
+++ b/tests/protocols/test_websocket.py
@@ -120,6 +120,35 @@ async def open_connection(url):
assert "permessage-deflate" in extension_names
+@pytest... | 1 | 1 | 0 | [{"id": "G0", "claim": "The CI lint check is failing; the author should run `scripts/lint` to satisfy CI before merge.", "category": "process", "verdict": "supported", "priority": "P3", "scope": "unclear"}] | null |
Kludex__uvicorn__1600 | Kludex/uvicorn | 1,600 | defect | fedf67e68d3f81c846bf3740c8ae21fa133000a4 | 38047d16c7cbeb955630c2658ce70af78e04e5d8 | Cooperative signal handling | * [x] I understand that this PR may be closed in case there was no previous discussion. (This doesn't apply to typos!)
* [x] I've added a test for each change that was introduced, and I tried as much as possible to make a single atomic change.
* [x] I've updated the documentation accordingly.
------------------... | diff --git a/setup.cfg b/setup.cfg
index 33c3e95a3f..716d9fa9ee 100644
--- a/setup.cfg
+++ b/setup.cfg
@@ -82,7 +82,7 @@ plugins =
[coverage:report]
precision = 2
-fail_under = 97.69
+fail_under = 97.10
show_missing = true
skip_covered = true
exclude_lines =
diff --git a/tests/test_server.py b/tests/test_server.... | 12 | 4 | 2 | [{"id": "G0", "claim": "A test covering SIGTERM signal handling should be added.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The coverage gate should not be lowered; strategic '# pragma's should be used instead.", "category": "testing", "verdict": "s... | null |
Kludex__uvicorn__1639 | Kludex/uvicorn | 1,639 | defect | f258adf947c1edb3d533328d7bfb29aea309a0a2 | 73b1215b807435b731416f51b22c141711c0005f | Use updated headers from server state | - Closes #1618
The idea here is to use the `ServerState` object instead of passing the `server_state.default_headers` to the `<protocol>.default_headers` attribute.
## How to test it?
- Use the same snippet provided on #1618. | diff --git a/uvicorn/protocols/http/h11_impl.py b/uvicorn/protocols/http/h11_impl.py
index 5fff70bb7..f9974c182 100644
--- a/uvicorn/protocols/http/h11_impl.py
+++ b/uvicorn/protocols/http/h11_impl.py
@@ -92,7 +92,6 @@ def __init__(
self.server_state = server_state
self.connections = server_state.conn... | 2 | 1 | 1 | [{"id": "G0", "claim": "A regression test covering the discussed date-header refresh behaviour should be added so the fix stays covered.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "A note referring to on_tick should be added so the limitation that he... | null |
Kludex__uvicorn__1825 | Kludex/uvicorn | 1,825 | defect | fcc3be545c7d81dbdf48816b20fd99ffa573af2d | dc1366b7de7e59271b70e8e71e5bf8caf28614fd | Replace current WSGIMiddleware implementation by a2wsgi one | Hello!
This should fix issue #371
And this is also a continuation of PR #1303
Edit by @Kludex:
- Closes #371
- Relates to #177
- Relates to #1303 | diff --git a/pyproject.toml b/pyproject.toml
index 13a02b7b6e..cf1a29281f 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -36,6 +36,7 @@ dependencies = [
[project.optional-dependencies]
standard = [
+ "a2wsgi>=1.6.0,<2.0.0",
"colorama>=0.4;sys_platform == 'win32'",
"httptools>=0.5.0",
"python-... | 11 | 10 | 3 | [{"id": "G0", "claim": "Add a2wsgi as a uvicorn (base) dependency and document that Uvicorn is also a WSGI server, as previously discussed in encode/uvicorn#1303.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "Kludex asks to restructure the pull request:... | null |
Kludex__uvicorn__1916 | Kludex/uvicorn | 1,916 | defect | b127fa8eac45b11cd973e7bdcb74f7f071cd5a3f | ba53520bfb038c48f23767fee1b6277dc74c4612 | Support the WebSocket Denial Response ASGI extension | uvicorn now can return a response from websocket apps that choose to reject a connection with a custom response.
See https://github.com/encode/starlette/pull/2041/files for related work.
This is a re-submission of pr #1907 | diff --git a/tests/protocols/test_websocket.py b/tests/protocols/test_websocket.py
index 22afeffad..a8fb57c0b 100644
--- a/tests/protocols/test_websocket.py
+++ b/tests/protocols/test_websocket.py
@@ -6,6 +6,7 @@
import pytest
from tests.protocols.test_http import HTTP_PROTOCOLS
+from tests.response import Response... | 3 | 2 | 1 | [{"id": "G0", "claim": "The reviewer asks why the new response_started guards around send_500_response are necessary and what the behavior would be without them.", "category": "design", "verdict": "opposed", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "Move the response_started check into send_500_r... | null |
Kludex__uvicorn__1950 | Kludex/uvicorn | 1,950 | defect | 87387273945624452c1f0e797bcf2a539b0c9211 | 4b703e3ae19b04c80d780318ba2e6c225f7abb2c | Add `--timeout-graceful-shutdown` parameter | # Summary
This is a continuation of #1824, which intend to close:
- close #451
- close #675
# Checklist
- [x] I understand that this PR may be closed in case there was no previous discussion. (This doesn't apply to typos!)
- [x] I've added a test for each change that was introduced, and I tried as muc... | diff --git a/docs/deployment.md b/docs/deployment.md
index b65c4319e..65163b526 100644
--- a/docs/deployment.md
+++ b/docs/deployment.md
@@ -104,6 +104,9 @@ Options:
--timeout-keep-alive INTEGER Close Keep-Alive connections if no new data
is received within this timeout. [defau... | 4 | 3 | 1 | [{"id": "G0", "claim": "Remove the version-specific branch around `t.cancel()` (the `if sys.version_info < (3, 9)` block duplicating the cancel call) in the shutdown loop.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "In the graceful-shutdown t... | null |
Kludex__uvicorn__2033 | Kludex/uvicorn | 2,033 | defect | 59f0ddb16a1f20fb14a95e549c1997e1e6e2546d | 33953858df0a345179a998adc9bf481614c3f547 | Add `--ws-max-queue` parameter | allows configuring implementation detail of "websocket": maximum length of the queue that holds incoming messages
<!-- Thanks for contributing to Uvicorn! 💚
Given this is a project maintained by volunteers, please read this template to not waste your time, or ours! 😁 -->
# Summary
draft implementation for h... | diff --git a/docs/deployment.md b/docs/deployment.md
index b7c2e6fabb..ae7d4312e7 100644
--- a/docs/deployment.md
+++ b/docs/deployment.md
@@ -65,6 +65,8 @@ Options:
[default: auto]
--ws-max-size INTEGER WebSocket max size message in bytes
... | 2 | 2 | 0 | [{"id": "G0", "claim": "The help text of the --ws-max-queue click option should be reworded to \"The maximum length of the WebSocket message queue.\"", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The docs/settings.md entry for --ws-max-queue shou... | null |
Kludex__uvicorn__2145 | Kludex/uvicorn | 2,145 | defect | 07c2b36455b5475ff7edfa54068ff2c0581a2be1 | a670b3b67a83731b3ae3f3e36e7b1ef8c802c415 | Fix Ctrl+C hang on Python 3.12 when connections are open | # Summary
The asyncio.Server.wait_closed() method was a no-op in versions of Python earlier than 3.12. The intention of this method was to block until all existing connections are closed, but due to a bug in its implementation, it wouldn't actually wait. This bug was fixed in Python 3.12, which exposed uvicorn's dep... | diff --git a/tests/protocols/test_websocket.py b/tests/protocols/test_websocket.py
index 17f2a92d1..9f98e3c7b 100644
--- a/tests/protocols/test_websocket.py
+++ b/tests/protocols/test_websocket.py
@@ -109,6 +109,30 @@ async def open_connection(url):
assert is_open
+@pytest.mark.anyio
+@pytest.mark.parametr... | 4 | 2 | 1 | [{"id": "G0", "claim": "The fix has not been verified on Python 3.12, the platform this PR targets.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "On Windows Terminal + PowerShell, Uvicorn does not respond to Ctrl+C or Ctrl+Break at all, even with much ... | null |
Kludex__uvicorn__2213 | Kludex/uvicorn | 2,213 | defect | ebcd996c6959a293851034ee1560706efe6f829a | e2d3ac77f60f086db73b9771da5f25776fe778d3 | ♻️ Update `root_path` handling (from `--root-path` CLI option) to include the root path prefix in the full ASGI `path` as per the ASGI spec | <!-- Thanks for contributing to Uvicorn! 💚
Given this is a project maintained by volunteers, please read this template to not waste your time, or ours! 😁 -->
# Summary
♻️ Update `root_path` handling (from `--root-path` CLI option) to include the root path prefix in the full ASGI `path` as per the ASGI spec, eq... | diff --git a/tests/middleware/test_wsgi.py b/tests/middleware/test_wsgi.py
index 34730ec92..6d9c17d29 100644
--- a/tests/middleware/test_wsgi.py
+++ b/tests/middleware/test_wsgi.py
@@ -122,11 +122,11 @@ def test_build_environ_encoding() -> None:
scope: "HTTPScope" = {
"asgi": {"version": "3.0", "spec_vers... | 2 | 2 | 0 | [{"id": "G0", "claim": "The commented-out assertion line `# assert b\"Path: /app/\" in protocol.transport.buffer` left in test_root_path should be removed.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "In httptools_impl.py the raw path should be built ... | null |
Kludex__uvicorn__2218 | Kludex/uvicorn | 2,218 | defect | 99fafb3c3b15e32dbaa504993161cb0c6898227f | bf13088dd7d7eb531cfbc02ee907f76103c4fa7a | Raise `Disconnect` on `send()` when client disconnected | - Comply with https://github.com/django/asgiref/pull/431. | diff --git a/tests/conftest.py b/tests/conftest.py
index a405c3175..6ee34b11a 100644
--- a/tests/conftest.py
+++ b/tests/conftest.py
@@ -253,8 +253,12 @@ def unused_tcp_port() -> int:
marks=pytest.mark.skipif(
not importlib.util.find_spec("wsproto"), reason="wsproto not installed."
... | 3 | 2 | 1 | [{"id": "G0", "claim": "The new exception class added in uvicorn/protocols/utils.py should be named `ClientDisconnected` rather than `Disconnected`.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The reviewer asked whether the http protocols wil... | null |
Kludex__uvicorn__2220 | Kludex/uvicorn | 2,220 | defect | 2ff704b91c8a3888eae7bfc3b053168dc59bd66e | fd088ffe5b38dfe9cb0fccfc5041918b01e4e17f | Raise `ClientDisconnected` on `send()` when client disconnected | ~We need to clarify this on https://github.com/django/asgiref/commit/3f0147dc79bae052113b31a02db4f2bdfffc7d4e before merging it.~
👆 Clarified.
Also, tests are missing here. | diff --git a/tests/protocols/test_http.py b/tests/protocols/test_http.py
index 8a00f38dc6..446b33967b 100644
--- a/tests/protocols/test_http.py
+++ b/tests/protocols/test_http.py
@@ -876,8 +876,8 @@ async def asgi(receive: ASGIReceiveCallable, send: ASGISendCallable):
@pytest.mark.parametrize(
"asgi2or3_app, expe... | 3 | 2 | 1 | [{"id": "G0", "claim": "The new `except ClientDisconnected` handler in httptools_impl may need to call `self.transport.close()` to close the connection when the client disconnects.", "category": "correctness", "verdict": "opposed", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "Replace `...` with `pas... | null |
Kludex__uvicorn__2360 | Kludex/uvicorn | 2,360 | defect | 5bf788f0eb0fc771f5c4eed8f282c7ec256565d2 | 07000797afb44a64362cf7edb37825b42ecb6ef0 | fix: upgrade is not websocket and dependencies are installed, should not warning | <!-- Thanks for contributing to Uvicorn! 💚
Given this is a project maintained by volunteers, please read this template to not waste your time, or ours! 😁 -->
# Summary
When I upgraded uvicorn to standard, I found that I encountered a lot of `Unsupported upgrade request.` prompts in the logs, so I debugged locall... | diff --git a/tests/protocols/test_http.py b/tests/protocols/test_http.py
index 45ccc1d23..99ed3569c 100644
--- a/tests/protocols/test_http.py
+++ b/tests/protocols/test_http.py
@@ -133,6 +133,18 @@
b"".join([b"x" * 32 * 1024 + b"\r\n", b"\r\n", b"\r\n"]),
]
+UPGRADE_REQUEST_ERROR_FIELD = b"\r\n".join(
+ [
+ ... | 3 | 3 | 0 | [{"id": "G0", "claim": "With httptools the unsupported-upgrade warnings are printed multiple times for one request; there should be only one warning prompt.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "pre_existing"}, {"id": "G1", "claim": "_should_upgrade should be simplified to a s... | null |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.