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
AutoMaker-Org__automaker__562
AutoMaker-Org/automaker
562
defect
044c3d50d1cd7b6942e8d0506eba937c32254207
5b1e0105f4b6441d0e6e2d9e4b846c4583228a73
refactor: standardize PR state representation across the application
- Closes #560
diff --git a/apps/server/src/lib/worktree-metadata.ts b/apps/server/src/lib/worktree-metadata.ts index 3f7ea60dd..ab0ba67c9 100644 --- a/apps/server/src/lib/worktree-metadata.ts +++ b/apps/server/src/lib/worktree-metadata.ts @@ -9,11 +9,15 @@ import * as path from 'path'; /** Maximum length for sanitized branch names ...
3
3
2
[{"id": "G0", "claim": "The `existingPr.state` value coming from the external GitHub API is not validated against the allowed PRState values before being stored in metadata, so any unexpected string could be stored; validate it against the known states.", "category": "correctness", "verdict": "supported", "priority": "...
null
AutoMaker-Org__automaker__573
AutoMaker-Org/automaker
573
defect
327aef89a22cd53482d80cc5f5012989106e86f6
2e57553639e8428921ddf1f61214f675b3417c1d
fix: resolve data directory persistence between Electron and Web modes
## Summary This PR fixes critical data persistence issues between Electron and Web modes, implements E2E test selector fixes, and enhances docstring coverage. Projects and settings created in one mode now correctly sync to the other mode, even after stopping and restarting either mode separately. **Key Issues Resolve...
diff --git a/apps/server/src/index.ts b/apps/server/src/index.ts index d90c7a364..259a19000 100644 --- a/apps/server/src/index.ts +++ b/apps/server/src/index.ts @@ -91,6 +91,9 @@ const PORT = parseInt(process.env.PORT || '3008', 10); const HOST = process.env.HOST || '0.0.0.0'; const HOSTNAME = process.env.HOSTNAME ||...
16
1
0
[{"id": "G0", "claim": "Falling back to the length of current.trashedProjects when sanitizedUpdates.trashedProjects is absent can misclassify an update that sends projects: [] without a trashedProjects field as a legitimate removal, allowing an accidental wipe that could lose data.", "category": "correctness", "verdict...
null
AutoMaker-Org__automaker__578
AutoMaker-Org/automaker
578
defect
327aef89a22cd53482d80cc5f5012989106e86f6
ef2dcbacd4b2e428d24e99c3ac81580a6f2f5ede
fix: improve project-switcher data-testid for uniqueness and special chars
## Summary - Combines stable `project.id` with sanitized name for unique, deterministic test IDs - Expands sanitization to properly handle special characters (removes non-alphanumeric except hyphens) - Updates E2E tests to use ends-with selector pattern for matching This addresses the CodeRabbitAI feedback on PR #574 ...
diff --git a/apps/ui/src/components/layout/project-switcher/components/project-switcher-item.tsx b/apps/ui/src/components/layout/project-switcher/components/project-switcher-item.tsx index c1a2fa261..d269001ee 100644 --- a/apps/ui/src/components/layout/project-switcher/components/project-switcher-item.tsx +++ b/apps/ui...
4
2
1
[{"id": "G0", "claim": "The E2E tests build their ends-with selectors from the raw project name instead of the sanitized/lowercased form the component uses, so the tests can fail for names containing uppercase letters, spaces or special characters.", "category": "correctness", "verdict": "supported", "priority": "P1", ...
null
AutoMaker-Org__automaker__667
AutoMaker-Org/automaker
667
defect
900bbb5e8045d6d48e5ae8a4045dee6e4b877e26
5a3dac1533914b72cfcbed31ad38bebe115919e1
feat: Add ideation context settings
- Add settings popover to the ideation view (right of the "Generate" button) - Migrate previous context to popover toggles (memory, context, features, ideas) - Add app specifications as new context option, reusing the existing app specs <img width="350" height="476" alt="image" src="https://github.com/user-attachm...
diff --git a/apps/server/src/routes/ideation/routes/suggestions-generate.ts b/apps/server/src/routes/ideation/routes/suggestions-generate.ts index 8add2af52..1aa7487b5 100644 --- a/apps/server/src/routes/ideation/routes/suggestions-generate.ts +++ b/apps/server/src/routes/ideation/routes/suggestions-generate.ts @@ -4,6...
1
1
0
[{"id": "G0", "claim": "Remove the redundant re-sanitization of the count parameter in parseSuggestionsFromResponse and parseTextResponse (count is already sanitized to [1,20] by generateSuggestions) and use count directly, also dropping the unneeded default value in the signatures.", "category": "maintainability", "ve...
null
AutoMaker-Org__automaker__682
AutoMaker-Org/automaker
682
defect
d8fa5c4cd1fd5e42ee785027e29cd149c5eebf1f
92b1fb37254f0e20b064393fc16320eea20cf4ea
fix: Add structured output fallback for non-Claude models in app spec generation
## Summary This PR fixes the app spec generation failing for non-Claude models (Cursor, Gemini, OpenCode, Copilot) that don't support structured output capabilities. - Add `supportsStructuredOutput()` centralized utility function - Add explicit JSON instructions for non-Claude models in feature generation - Add JSON ...
diff --git a/apps/server/src/routes/app-spec/generate-features-from-spec.ts b/apps/server/src/routes/app-spec/generate-features-from-spec.ts index 56058cb76..e614113ad 100644 --- a/apps/server/src/routes/app-spec/generate-features-from-spec.ts +++ b/apps/server/src/routes/app-spec/generate-features-from-spec.ts @@ -8,1...
2
2
1
[{"id": "G0", "claim": "The else block passes raw text to parseAndCreateFeatures when pre-extraction fails, but parseAndCreateFeatures uses the same extractJsonWithArray utility so it will also fail, making a redundant extraction attempt; throw an explicit error there instead.", "category": "maintainability", "verdict"...
null
AutoMaker-Org__automaker__699
AutoMaker-Org/automaker
699
defect
ebf2fcadd638e7b0cc1e84b87e0db01da5fb8227
011ac404bbb32792cb99282054d9375c3e9ab04e
fix: Prevent features from getting stuck in in_progress after server restart
## Summary - Fixes features getting stuck in `in_progress` status after server restart, making them unresumable - Implements graceful shutdown that marks running features as `interrupted` before exit - Adds orphan detection to identify features whose branches no longer exist - Adds idempotent checks to prevent race con...
diff --git a/apps/server/src/index.ts b/apps/server/src/index.ts index a5f7cbcb1..06040100d 100644 --- a/apps/server/src/index.ts +++ b/apps/server/src/index.ts @@ -326,7 +326,10 @@ app.get('/api/health/detailed', createDetailedHandler()); app.use('/api/fs', createFsRoutes(events)); app.use('/api/agent', createAgentR...
3
3
1
[{"id": "G0", "claim": "The try...catch block around autoModeService.markAllRunningFeaturesInterrupted in gracefulShutdown is redundant because the method handles its own errors internally and never rejects, and can be removed for cleaner code.", "category": "maintainability", "verdict": "supported", "priority": "P2", ...
null
AutoMaker-Org__automaker__776
AutoMaker-Org/automaker
776
defect
2805c0ea531563d2c27de1b0728e473d519951c9
416ef3a3940c7cdd4d8bcc4c9ad80e8313bd1b12
feat: Add error handling to auto-mode facade and implement followUp f…
…eature. Fix Claude weekly usage indicator. Fix mobile card drag <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Weekly usage pace markers and pace labels added to usage bars/cards; optional Claude usage surfaced to auto-mode; facade-level run...
diff --git a/apps/server/src/services/auto-mode/compat.ts b/apps/server/src/services/auto-mode/compat.ts index cece24750..2c713c011 100644 --- a/apps/server/src/services/auto-mode/compat.ts +++ b/apps/server/src/services/auto-mode/compat.ts @@ -13,6 +13,7 @@ import { GlobalAutoModeService } from './global-service.js'; ...
8
1
1
[{"id": "G0", "claim": "Persisting imagePaths by mutating the in-memory feature and calling updateFeatureStatus loses the imagePaths because updateFeatureStatus re-reads the feature from disk, so they should be written directly or passed through executeFeature's options; also p.split('/').pop() mishandles Windows paths...
null
AutoMaker-Org__automaker__778
AutoMaker-Org/automaker
778
defect
30fce3f7469bbd9ab04d2ae85be2dabb769df23e
aa940d44ff0692357633f5d1f6bcb2cf5071520f
feat: Add task retry logic and improve max turns limit
Features are moving to completed before all tasks complete <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Automatic retry mechanism for incomplete tasks (up to 3 retries) with continuation prompts and progress events * Enhanced completion ...
diff --git a/apps/server/src/services/agent-executor.ts b/apps/server/src/services/agent-executor.ts index 0d9c23998..cbf9e401f 100644 --- a/apps/server/src/services/agent-executor.ts +++ b/apps/server/src/services/agent-executor.ts @@ -331,7 +331,7 @@ export class AgentExecutor { userFeedback ); ...
4
1
1
[{"id": "G0", "claim": "The literal 3 used as the maximum number of task retry attempts should be defined as a named constant at the top of execution-service.ts instead of a magic number inside the method.", "category": "maintainability", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "c...
null
AutoMaker-Org__automaker__797
AutoMaker-Org/automaker
797
defect
91bff21d58f5d0a5555b9a28b36ded27e46cd3ab
abd075b73a34f4e5f67c50c26c0904a0f17c5ee9
Fix Codex CLI timeout handling and improve CI workflows
## Summary - Add timeout extension for Codex model feature generation and improve timeout calculation for reasoning efforts <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Refactor** * Reduced unnecessary component subscriptions in board view hooks to improve...
diff --git a/apps/server/src/providers/codex-provider.ts b/apps/server/src/providers/codex-provider.ts index 10146591c..1359d37af 100644 --- a/apps/server/src/providers/codex-provider.ts +++ b/apps/server/src/providers/codex-provider.ts @@ -33,7 +33,6 @@ import { supportsReasoningEffort, validateBareModelId, c...
2
1
0
[{"id": "G0", "claim": "The variable `useWorktreesEnabled` should be renamed to `worktreesEnabled` (and its call sites updated) because its `use` prefix makes a plain boolean look like a React hook.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": ...
null
AutoMaker-Org__automaker__823
AutoMaker-Org/automaker
823
defect
1c3d6434a855b56dde4714e4134d324da999a470
8180055be2bffe95223ee188f092886366f3dfc4
fix: E2E test stability and UI performance improvements
## Summary Fixes E2E test flakiness and improves UI performance in the dev server logs panel. ### E2E Test Fixes - **Sandbox warning dialog**: Dismiss the sandbox warning dialog in `agent-output-modal-responsive` and `success-log-contrast` specs — it was blocking pointer events and causing test failures - **Project s...
diff --git a/apps/ui/src/components/views/board-view/hooks/use-board-effects.ts b/apps/ui/src/components/views/board-view/hooks/use-board-effects.ts index d697f2cb81..ae63d38764 100644 --- a/apps/ui/src/components/views/board-view/hooks/use-board-effects.ts +++ b/apps/ui/src/components/views/board-view/hooks/use-board-...
4
3
1
[{"id": "G0", "claim": "Truncating with slice(-MAX_LOG_BUFFER_SIZE) can cut a line in the middle and break multi-byte characters or ANSI escape sequences, corrupting the start of the log buffer; it should slice from the first newline after the truncation point.", "category": "correctness", "verdict": "supported", "prio...
null
AutoMaker-Org__automaker__825
AutoMaker-Org/automaker
825
defect
54d69e907bc8410340c0ff9bf0e26d7f697c56d9
7c8787dc4f094d5ccad0834d629741b113534db4
Fix board view crash when feature status lags during race conditions
## Summary - Fixed React error #185 (maximum update depth exceeded) that caused infinite spinner crash when features transitioned to in_progress in board view - Removed duplicate WebSocket event handling in `useBoardFeatures` that triggered cascading re-renders through DndContext - Added memoization to KanbanBoard comp...
diff --git a/apps/server/src/services/spec-parser.ts b/apps/server/src/services/spec-parser.ts index 1c9f527ed3..295246fbfb 100644 --- a/apps/server/src/services/spec-parser.ts +++ b/apps/server/src/services/spec-parser.ts @@ -214,10 +214,13 @@ export function extractSummary(text: string): string | null { } // ...
7
5
1
[{"id": "G0", "claim": "The stale-status condition (backlog/ready/interrupted/merge_conflict) is repeated between row-actions.tsx and board-view.tsx; extract a shared helper function to avoid duplication and ensure consistency.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introdu...
null
AutoMaker-Org__automaker__828
AutoMaker-Org/automaker
828
defect
b2915f4de1230dbece571a84047d257d095fc8d8
fc6c69f03d8e185c1f97a1d086c47bfb97f94b86
Fix dev server hang by reducing log spam and event frequency
## Summary - Reduces WebSocket event logging to prevent progressive memory growth and browser slowdown - Increases output throttling from 4ms to 100ms (~250fps to 10fps) to keep WebSocket traffic manageable - Batches rapid dev server log updates using requestAnimationFrame to prevent excessive React re-renders - Extend...
diff --git a/apps/server/src/index.ts b/apps/server/src/index.ts index 2b48f662f8..cc0c3fbc16 100644 --- a/apps/server/src/index.ts +++ b/apps/server/src/index.ts @@ -598,24 +598,23 @@ wss.on('connection', (ws: WebSocket) => { // Subscribe to all events and forward to this client const unsubscribe = events.subs...
9
4
4
[{"id": "G0", "claim": "Stale pendingOutputRef content can survive a worktree switch or a dev-server:started reset and flush into the new session's logs, so the pending RAF buffer should be reset (in clearLogs, on dev-server:started, and on unmount), not only cancelled on unmount.", "category": "correctness", "verdict"...
null
AutoMaker-Org__automaker__836
AutoMaker-Org/automaker
836
defect
26b73df09750d30a802642453c5e33ed7c1502fc
b1be9670a6e2390c1cb35f84bbb951fbde4f1c01
Preserve pipeline work by using waiting_approval on post-completion errors
## Summary - Track pipeline completion state and use `waiting_approval` instead of `backlog` when errors occur after pipeline steps finish - Prevents loss of completed pipeline work when post-completion operations fail - Applies to both normal execution and resume-from-step code paths ## Changes - **execution-service....
diff --git a/apps/server/src/services/execution-service.ts b/apps/server/src/services/execution-service.ts index dc0555c5a..80d85d6d8 100644 --- a/apps/server/src/services/execution-service.ts +++ b/apps/server/src/services/execution-service.ts @@ -179,6 +179,7 @@ ${feature.spec} const abortController = tempRunnin...
2
1
1
[{"id": "G0", "claim": "The new post-pipeline fallback in the error handlers can overwrite an already-set terminal `merge_conflict` status with `waiting_approval`/`backlog` on late errors, hiding unresolved conflicts.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": ...
null
AutoMaker-Org__automaker__90
AutoMaker-Org/automaker
90
defect
ebc4f1422add64b680093ecbfe58ffcbf9ce0bc5
5a1fe23ddb8d1c058ed4055d94cadefed07b1a6f
feat: implement SDK session ID handling for conversation continuity
- Added support for resuming conversations using the Claude SDK session ID. - Updated the ClaudeProvider to conditionally resume sessions based on the presence of a session ID and conversation history. - Enhanced the AgentService to capture and store the SDK session ID from incoming messages, ensuring continuity in c...
diff --git a/apps/server/src/providers/claude-provider.ts b/apps/server/src/providers/claude-provider.ts index cb44811dd..b1fe281a3 100644 --- a/apps/server/src/providers/claude-provider.ts +++ b/apps/server/src/providers/claude-provider.ts @@ -7,10 +7,6 @@ import { query, type Options } from "@anthropic-ai/claude-a...
1
1
1
[{"id": "G0", "claim": "The captured sdkSessionId is only stored in the in-memory session object and is not persisted, so conversation continuity is lost if the server restarts; the ID should be persisted when captured, added to SessionMetadata, and loaded in startConversation.", "category": "correctness", "verdict": "...
null
AutoPas__AutoPas__1030
AutoPas/AutoPas
1,030
defect
bd5766df2ef7cb6859f8aee30ce8b5311b537de9
8f6e6e77fa07a0fe940fff3a728bf778e1e9b5af
Dynamic rf estimation bachelor thesis
# Description New approach to estimate the mean rebuild frequency for the following non-tuning phase in dynamic containers. The method relies on the maximum velocity during the last sample of the first configuration to calculate an estimate using the following formula: `estimated_rf = skin/deltaT/vmax/2` . Where sk...
diff --git a/examples/md-flexible/src/Simulation.cpp b/examples/md-flexible/src/Simulation.cpp index c48a0864fb..ee746e2a57 100644 --- a/examples/md-flexible/src/Simulation.cpp +++ b/examples/md-flexible/src/Simulation.cpp @@ -171,6 +171,7 @@ Simulation::Simulation(const MDFlexConfig &configuration, _autoPasContaine...
7
6
1
[{"id": "G0", "claim": "getVelocityMethodEstimate should be reworked to move the AUTOPAS_ENABLE_DYNAMIC_CONTAINERS guard inside the function and use ArrayMath::dot, std::max and const parameters, for consistency with similar functions.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": ...
null
AutoPas__AutoPas__1044
AutoPas/AutoPas
1,044
defect
88074c0aebf25161c3aa5458531a6b1fb321839f
16203d609984071df582a6cd468fcc9466753a44
LifeInfo Parametrized Constructor
# LiveInfo Parametrized Constructor This change added a parameterized LiveInfo constructor. This is required for external tools developed along with AutoPas. In my case this is a tool for estimating the runtime of a program based on previously collected tuning data. # How Has This Been Tested? - [X] Detailed T...
diff --git a/src/autopas/tuning/tuningStrategy/LiveInfo.h b/src/autopas/tuning/tuningStrategy/LiveInfo.h index a0599e9b3d..8dbe2060dd 100644 --- a/src/autopas/tuning/tuningStrategy/LiveInfo.h +++ b/src/autopas/tuning/tuningStrategy/LiveInfo.h @@ -118,6 +118,146 @@ class LiveInfo { using InfoType = std::variant<bool,...
5
5
3
[{"id": "G0", "claim": "The domain-size guard should use the `or` keyword instead of `||` for consistency with AutoPas style.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The constructor validation should log a warning instead of throwing exce...
null
AutoPas__AutoPas__154
AutoPas/AutoPas
154
defect
51dc61d39afd0b1f113e6a03be5fd35579882720
cce0cad0e3cff422684d4d544780472e97820bf2
LJ Functor with AVX Intrinsics
# Description Reimplemented the SoA Version of the LJ Functor with ~AVX2~ AVX Intrinsics. I did not use FMA Intrinsics on purpose since the compiler should optimize this by itself (see https://gcc.godbolt.org/z/RaCgmZ). This way the code also runs on CPUs with AVX only (like my laptop :D ). - [x] LJFunctorAVX - ...
diff --git a/examples/md-flexible/MDFlexParser.cpp b/examples/md-flexible/MDFlexParser.cpp index b11c27ce48..9586e358d3 100644 --- a/examples/md-flexible/MDFlexParser.cpp +++ b/examples/md-flexible/MDFlexParser.cpp @@ -77,11 +77,13 @@ bool MDFlexParser::parseInput(int argc, char **argv) { break; } ...
5
4
1
[{"id": "G0", "claim": "The CI's Jenkinsfile builds with -DUSE_VECTORIZATION=OFF, which appears to cause build problems for the AVX intrinsics code on Archer, and the author asks whether vectorization is disabled there for a reason.", "category": "testing", "verdict": "uncertain", "priority": "P2", "scope": "pre_existi...
null
AutoPas__AutoPas__201
AutoPas/AutoPas
201
defect
4cf33ad7a674a123af64a5ab03acc0b82c27f3c6
3d067c79f97f9d85497bc0647a32c6c0785d416a
Allow cell sizes < 1.0 for linked cells, refactoring
# Description 1. support for cell size factors < 1.0 for all traversals of LinkedCells. 2. The existing tests for the LinkedCells Traversals were replaced by new automatically generated tests (TraversalTest). 3. refactoring: Basic traversal iteration for traversals based on domain coloring moved to own class (CBa...
diff --git a/docs/C08TraversalScheme.py b/docs/C08TraversalScheme.py new file mode 100644 index 0000000000..c6bb946c30 --- /dev/null +++ b/docs/C08TraversalScheme.py @@ -0,0 +1,74 @@ +''' + * @file C08TraversalScheme.cpp + * @author C. Menges + * @date 14.04.2019 +''' + +import matplotlib as mpl +from mpl_toolki...
5
4
0
[{"id": "G0", "claim": "The new cell-size < 1.0 handling (halo sizing and cell assignment) may not work when particles travel further than one cell per time step.", "category": "correctness", "verdict": "opposed", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The sanity-check comment in CellBlock3D.h...
null
AutoPas__AutoPas__217
AutoPas/AutoPas
217
defect
aa87c9093606a0d1fefc10b8e4e9de7220b3177a
72944b5f1eea4134ee4136500ad23c7fe6a4285f
adapt updateContainer interface change
# Description Adapts change of updateContainer function, i.e., they now return a vector of invalid particles. ## Related Pull Requests - part of #215
diff --git a/src/autopas/AutoPas.h b/src/autopas/AutoPas.h index fc4d920a98..55bce4f83c 100644 --- a/src/autopas/AutoPas.h +++ b/src/autopas/AutoPas.h @@ -98,10 +98,9 @@ class AutoPas { * It resorts particles into appropriate cells and moves them to the halo, if necessary. * @todo update doc * @return A vec...
6
5
0
[{"id": "G0", "claim": "The clang compiler should be handled by the AUTOPAS_WARN_UNUSED_RESULT macro definition (guarded only by __GNUC__).", "category": "correctness", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The OpenMP pragma blocks in LinkedCells::updateContainer shoul...
null
AutoPas__AutoPas__219
AutoPas/AutoPas
219
defect
9d180193f00dbc9ab4dde10d0d5041902c3e7929
cf98ef8390ae02d748a8594a820281b75267f048
Avx functor globals
# Description - [x] Implemented calculation of globals (virial and upot) for the AVX based Lennard-Jones-Functor. - [x] Changed LJFunctorAVXTest st. it checks the correctness of the calculation of globals. ## Related Pull Requests ## Resolved Issues # (issue) Missing calculation of globals in the LJFunct...
diff --git a/src/autopas/pairwiseFunctors/LJFunctorAVX.h b/src/autopas/pairwiseFunctors/LJFunctorAVX.h index 05500af152..ee932b05b0 100644 --- a/src/autopas/pairwiseFunctors/LJFunctorAVX.h +++ b/src/autopas/pairwiseFunctors/LJFunctorAVX.h @@ -25,7 +25,8 @@ namespace autopas { * @tparam calculateGlobals Defines whethe...
2
2
1
[{"id": "G0", "claim": "If the exception inside the calculateGlobals-or-duplicatedCalculation branch is no longer needed, the surrounding `if` should be removed too.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "A halo check is missing in the A...
null
AutoPas__AutoPas__259
AutoPas/AutoPas
259
defect
74bf6ebf3319a4ae161aae81ee815356d2e0ccec
338eff0e46bf2b6ca67d4c71afed0131da1f9439
Removed newton3 parameter from all iteratePairwise methods in the containers
# Description Removed newton 3 parameter from all iteratePairwise methods in the containers. ## Related Pull Requests None ## Resolved Issues None # How Has This Been Tested? Jenkins
diff --git a/examples/cluster-test/cluster-test.cpp b/examples/cluster-test/cluster-test.cpp index 32233bf789..9845e377a6 100644 --- a/examples/cluster-test/cluster-test.cpp +++ b/examples/cluster-test/cluster-test.cpp @@ -105,7 +105,7 @@ int main(int argc, char *argv[]) { dummyTraversal({0, 0, 0}, &func); ...
5
5
0
[{"id": "G0", "claim": "The stale `@param useNewton3` doxygen line in DirectSum.h should be removed now that the parameter is gone.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The stale `@param useNewton3` doxygen line in VerletClusterLists.h s...
null
AutoPas__AutoPas__295
AutoPas/AutoPas
295
defect
fd86e56681020d444d6edd6b5aba7cbf2b29c37c
27d27a8a4336c40d909ace6d77e78607ef8d4d32
VerletClusterLists coloring traversal
# Description Adds a new traversal to the verlet cluster lists container that uses a coloring over the grids. ## Related Pull Requests - None ## Resolved Issues - None # How Has This Been Tested? - Unit Tests and Jenkins (especially `LinkedCellsVersusVerletClusterListsTest::verletClustersColoringTe...
diff --git a/examples/md-flexible/measurePerf.sh b/examples/md-flexible/measurePerf.sh index b21ada3455..1e1cb872d2 100755 --- a/examples/md-flexible/measurePerf.sh +++ b/examples/md-flexible/measurePerf.sh @@ -103,12 +103,6 @@ do filename="${filename}.csv" - # workaround bec...
22
19
2
[{"id": "G0", "claim": "The class documentation should briefly explain why the coloring stride is 3x2 (six colors).", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The long sentences in the buildClusterIndexMap documentation should be split up.", "...
null
AutoPas__AutoPas__299
AutoPas/AutoPas
299
defect
47f038f4484756446354708781c1eae9b9c38053
c3c46c184a32d686422eb632128289ad68588275
Add first version of SoAView
# Description Adds views on `SoA`s. The view contains only the methods that are needed by the functors at the moment, `begin()` and `getNumParticles()`. It can be used to iterate over only a small part of a `SoA`, making it possible to e.g. use the same SoA for multiple clusters of the VerletClusterLists. They ar...
diff --git a/src/autopas/containers/linkedCells/traversals/C01Traversal.h b/src/autopas/containers/linkedCells/traversals/C01Traversal.h index 3d0d3697a6..c40cc86f18 100644 --- a/src/autopas/containers/linkedCells/traversals/C01Traversal.h +++ b/src/autopas/containers/linkedCells/traversals/C01Traversal.h @@ -255,10 +2...
6
2
0
[{"id": "G0", "claim": "Replace the occurrences of viewStart in C01Traversal and C04SoATraversal by SoAView and remove viewStart from class SoA.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "pre_existing"}, {"id": "G1", "claim": "Calling the pairwise functor directly in C01Traversal, there...
null
AutoPas__AutoPas__360
AutoPas/AutoPas
360
defect
dd54452c1d4203d98bec64806d825cc0cad6ce50
9dd7eb02a5e85d78afdd1a39dde4745f9c8212f4
Bayesian Search: Change FeatureVector diff
# Description Changes the return type of the - operator of FeatureVector to Eigen::VectorXd. This seems reasonable since the previously returned feature vector was only used to be cast to a Eigen::VectorXd. Also with #348 the construction of invalid options will not be possible anymore. ## Related Pull Requests ...
diff --git a/src/autopas/selectors/FeatureVector.h b/src/autopas/selectors/FeatureVector.h index d20d7561b0..f0304eca82 100644 --- a/src/autopas/selectors/FeatureVector.h +++ b/src/autopas/selectors/FeatureVector.h @@ -52,13 +52,12 @@ class FeatureVector : public Configuration { * @param other * @return */ ...
3
3
1
[{"id": "G0", "claim": "The new operator- should use cellSizeFactor - other.cellSizeFactor instead of the bare cellSizeFactor as the first component of the result vector.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The comment at GaussianProcess....
null
AutoPas__AutoPas__427
AutoPas/AutoPas
427
defect
981c73497546d20c7cb1e706cbb40a3e8369763a
333696e0e82db199ca350921a3d2cd0d81ab3bcb
Remove restrictions on Particle constructors
# Description Removes all restrictions on constructors of the Particle classes. AutoPas now works with non-default constructible particles and thus will never call any real constructor of a particle. The copy constructor is, however, required! # How Has This Been Tested? Please describe the tests that you ra...
diff --git a/src/autopas/cells/FullParticleCell.h b/src/autopas/cells/FullParticleCell.h index 8505388ede..6edc598de5 100644 --- a/src/autopas/cells/FullParticleCell.h +++ b/src/autopas/cells/FullParticleCell.h @@ -107,8 +107,9 @@ class FullParticleCell : public ParticleCell<Particle> { /** * Resizes the contain...
3
3
0
[{"id": "G0", "claim": "Add a comment to collectAllActualParticles mentioning that the resize always shrinks the vector and therefore the passed value is never actually inserted.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Wrap the dummy-partic...
null
AutoPas__AutoPas__432
AutoPas/AutoPas
432
defect
bb6b220fb42be716f85c545dbe18b97024d1028e
864b26fe48f9df26f2e022fb914c3c8ca26e77fb
Type parameterized lj function tests
# Description Restructure tests to properly test LJFunctor and LJFunctorAVX by means of type parameterized tests. - [x] Globals tests - [x] NoGlobals tests - [x] VS tests - [x] Readable test names - [x] Bugfixes in LJFunctorAVX discovered by new tests ## Related Pull Requests - merges into #423 ## ~...
diff --git a/src/autopas/molecularDynamics/LJFunctor.h b/src/autopas/molecularDynamics/LJFunctor.h index 71dec1b815..43b1de1c0f 100644 --- a/src/autopas/molecularDynamics/LJFunctor.h +++ b/src/autopas/molecularDynamics/LJFunctor.h @@ -788,6 +788,12 @@ class LJFunctor Particle::AttributeNames::forceX, Particle:...
4
3
1
[{"id": "G0", "claim": "Delete the leftover tests/testAutopas/tests/pairwiseFunctors/LJFunctorTest.cpp, which the PR gutted down to a dangling include.", "category": "maintainability", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The nested for loops over additionalDummyParti...
null
AutoPas__AutoPas__444
AutoPas/AutoPas
444
defect
bc912aec211b843fbd6aa4dc6957fe2690594b20
1bd5188c1bb2cad5fea7cb7bc76e50cc8989254e
Feature/reference linked cell
# Description - [x] Simplify template structure (Remove ParticleCell template from Autopas, Autotuner, Containers, Functor,....) - [x] Remove ParticleCell from Main Interface - [x] All Containers hardcode their Cell Type - [x] Functors are independent of Cells, `SoALoader` and `SoAExtractor` now take the Ce...
diff --git a/src/autopas/cells/ReferenceParticleCell.h b/src/autopas/cells/ReferenceParticleCell.h new file mode 100644 index 0000000000..25cda21f5e --- /dev/null +++ b/src/autopas/cells/ReferenceParticleCell.h @@ -0,0 +1,158 @@ +/** + * @file FullParticleCell.h + * @date 18.01.2018 + * @author seckler + */ + +#pragma ...
9
7
2
[{"id": "G0", "claim": "Insert an empty line between the end of the previous function and the start of the new documentation comment in CompatibleTraversals.h.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Any reason that this container is not ...
null
AutoPas__AutoPas__45
AutoPas/AutoPas
45
defect
5cde97c3a664c01637d26eb84c7aae81f1edf725
50808ee112fa01586eaeb73e98118e37961d21f8
Omp c08
concerning #9 OpenMP parallelization pattern c08. Basically the same as in mardyn. Existing tests should already cover it to some extent therefore not too sophisticated tests were added. TODO: selection via selector class (should go into a new pull req)
diff --git a/src/containers/LinkedCells.h b/src/containers/LinkedCells.h index f888139e89..228201393b 100644 --- a/src/containers/LinkedCells.h +++ b/src/containers/LinkedCells.h @@ -11,6 +11,7 @@ #include "CellBlock3D.h" #include "ParticleContainer.h" #include "containers/cellPairTraversals/SlicedTraversal.h" +#inc...
8
7
1
[{"id": "G0", "claim": "The macro AUTOPASAUTOPAS_OPENMP (a string-replace artifact) should be renamed, e.g. to AUTOPASOPENMP, so that such duplication does not occur again.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Selecting the traversal v...
null
AutoPas__AutoPas__480
AutoPas/AutoPas
480
defect
43417e3450db7dd9b6aa1f64a7429e43c55afcb1
4ae296fda0dfa92aa1151d4693eef162dcc4b255
Refactored encoding of FeatureVectors
# Description - Refactored encoding functions of FeatureVector to FeatureVectorEncoder. - Combined Container, Traversal and LoadEstimator as one tunable dimension. # How Has This Been Tested? - [ ] FeatureVectorTest
diff --git a/examples/md-flexible/src/parsing/MDFlexConfig.h b/examples/md-flexible/src/parsing/MDFlexConfig.h index adea3c155b..1b029f4af2 100644 --- a/examples/md-flexible/src/parsing/MDFlexConfig.h +++ b/examples/md-flexible/src/parsing/MDFlexConfig.h @@ -6,7 +6,6 @@ #pragma once -#include <autopas/options/Load...
1
1
1
[{"id": "G0", "claim": "Initialize the member as `size_t _oneHotDims{0};` because the constructors never initialize it.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
AutoPas__AutoPas__508
AutoPas/AutoPas
508
defect
06e1de701aa3950257d2a4d187365d01d915867c
cb807e1f5e07f99a80613a98e903079e90ed097c
Add blacklist for bad configurations
# Description - [x] add blacklist - [x] add functionality that bad configuration get no longer tested after the first tuning phase - [x] adapt md-flexible - [x] changes in python scipts - [x] additional refactoring # How Has This Been Tested? Please describe the tests that you ran to verify your changes....
diff --git a/examples/md-flexible/src/Simulation.h b/examples/md-flexible/src/Simulation.h index 13c8d4c3a7..574984ca75 100644 --- a/examples/md-flexible/src/Simulation.h +++ b/examples/md-flexible/src/Simulation.h @@ -186,6 +186,7 @@ void Simulation<Particle, ParticleCell>::initialize(const MDFlexConfig &mdFlexCo a...
17
15
1
[{"id": "G0", "claim": "The default of maxTuningPhasesWithoutTest was changed from 5 to 10 without an explanation of why.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The description of the relative-range-blacklist option is garbled (the sentence with ...
null
AutoPas__AutoPas__580
AutoPas/AutoPas
580
defect
c6376356f6fbbb1ccf98da4f0032cf82cb228f89
0e77c2d75fff4c24fe7f6c3a921898eb60ff7f4a
Refactor Iterator Tests
# Description - [x] Change `IteratorBehavior` `enum` to an `Option` class. - [x] Refactor `RegionParticleIteratorTest` - [x] Merge common functionality of `IteratorTest`, `RegionParticleIteratorTest`, and `ParticleIteratorTest` - [x] Add Test for Iterator copying (copy constructor, copy assignment) - [x] Throw o...
diff --git a/README.md b/README.md index 0b57b3a379..3906a97182 100644 --- a/README.md +++ b/README.md @@ -179,6 +179,9 @@ The default parameter is `haloAndOwned`, which is also used for range-based for Analogously to `begin()`, `cbegin()` is also defined, which guarantees to return a `const_iterator`. +Iterators ...
13
12
1
[{"id": "G0", "claim": "The README should state \"Adding particles while iterating is not supported.\" instead of the vaguer \"Iterators are not guaranteed to be valid after particle insertion.\".", "category": "documentation", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The...
null
AutoPas__AutoPas__586
AutoPas/AutoPas
586
defect
11e2bf6ccf27ee1d77775402fe02e522b64ff520
1104c3f6ab4ea8ee4cc088ac142e122c2555544f
Memory Profiler Test
# Description Add a basic functionality test for the MemoryProfiler ## ~Related Pull Requests~ ## ~Resolved Issues~ # How Has This Been Tested? - [x] The new test :D
diff --git a/tests/testAutopas/tests/utils/MemoryProfilerTest.cpp b/tests/testAutopas/tests/utils/MemoryProfilerTest.cpp new file mode 100644 index 0000000000..3e5b58f0bd --- /dev/null +++ b/tests/testAutopas/tests/utils/MemoryProfilerTest.cpp @@ -0,0 +1,17 @@ +/** + * @file MemoryProfilerTest.cpp.cc + * @author F. Gra...
1
1
0
[{"id": "G0", "claim": "The test's failure message cites a ~3300kb expectation that is not explained anywhere, and should instead explain that gtest itself allocates some memory.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
AutoPas__AutoPas__612
AutoPas/AutoPas
612
defect
3fc478e8b6fbbf82683dfbed4cbf8d58341388e1
dd0a1b8ff74334e6988db2c3a10408c5439c2a52
Mpi tuning for inhomogeneous scenarios
# Description Improved MPIParallelizedStrategy to work with inhomogeneous scenarios. Ranks with similar scenarios are now distributed in buckets. Each bucket has its own search space. Each bucket has a optimal configuration. # TODOs - [x] need to improve bucket distribution - [x] also use max_density for di...
diff --git a/examples/md-flexible/src/Simulation.cpp b/examples/md-flexible/src/Simulation.cpp index 196a2ee82f..c62ff83473 100644 --- a/examples/md-flexible/src/Simulation.cpp +++ b/examples/md-flexible/src/Simulation.cpp @@ -8,9 +8,6 @@ #include <sys/ioctl.h> #include <unistd.h> -#ifdef AUTOPAS_INTERNODE_TUNING -...
12
12
3
[{"id": "G0", "claim": "Do not use malloc in distributeRanksInBuckets; use RAII (a std::vector<double>) so the Allgather buffer is always freed instead of leaking.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "calculateHomogeneityAndMaxDensity allo...
null
AutoPas__AutoPas__619
AutoPas/AutoPas
619
defect
13e700173326c5b6e243f69fad97feff242b26d2
42e491719953d6a5fde5816737b235a8d75ddef1
Sortedcellviewfix
# Description This PR should fix the bugs encountered when using `SortedCellViews` for all affected traversals (c01, c04, c08, c18). The bug was basically that the wrong offsets were used for the calculation of the direction vector. To check if two cells interact with each other, we calculate the minimum distance...
diff --git a/src/autopas/containers/linkedCells/traversals/LCC01Traversal.h b/src/autopas/containers/linkedCells/traversals/LCC01Traversal.h index 69207a6854..cb03b159de 100644 --- a/src/autopas/containers/linkedCells/traversals/LCC01Traversal.h +++ b/src/autopas/containers/linkedCells/traversals/LCC01Traversal.h @@ -2...
1
1
0
[{"id": "G0", "claim": "The start-sorting threshold should be validated by running tests to see whether enabling sorting for all particle counts is still a reasonable heuristic (instead of blindly lowering it from max to 1).", "category": "performance", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
AutoPas__AutoPas__666
AutoPas/AutoPas
666
defect
4d38b4845235d51bf15d19ded7523bc21619a524
3dd95fbf930a0617f6df6681be0e070693e67ac2
Md flex/post thesis improvements
# Description This pullrequest only contains the implementation for the configurable load balancing interval. # How Has This Been Tested? This has been tested manually and by running MD-Flexible's test with and without MPI.
diff --git a/examples/md-flexible/src/Simulation.cpp b/examples/md-flexible/src/Simulation.cpp index 65d5adff2b..7e61c8ba4f 100644 --- a/examples/md-flexible/src/Simulation.cpp +++ b/examples/md-flexible/src/Simulation.cpp @@ -175,12 +175,14 @@ void Simulation::run() { const double work = _timers.work.stop(); ...
2
2
2
[{"id": "G0", "claim": "The check rejecting load balancer arguments that do not parse to exactly one option was removed and should be reincluded.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The loadBalancingInterval option must use __LINE__ as it...
null
AutoPas__AutoPas__702
AutoPas/AutoPas
702
defect
1e201e618a6bd3f5507dcde4c48309da36e2ac36
b6bb73d3c313be31e86e3437efd027f7c1db1f83
Make addParticle() ThreadSafe
# Description `AutoPas::addParticle()` is not thread-safe since we use the logic handler buffers because `std::vector::push_back()` is not thread-safe. This PR solves this by adding one buffer per thread. ## ~Related Pull Requests~ ## ~Resolved Issues~ # How Has This Been Tested? - [x] Existing CI test ...
diff --git a/examples/sph-mpi/sph-main-mpi.cpp b/examples/sph-mpi/sph-main-mpi.cpp index 0917a22ac7..344d92cd9f 100644 --- a/examples/sph-mpi/sph-main-mpi.cpp +++ b/examples/sph-mpi/sph-main-mpi.cpp @@ -422,11 +422,14 @@ void printConservativeVariables(AutoPasContainer &sphSystem, MPI_Comm &comm) { if (myrank == 0) ...
4
2
0
[{"id": "G0", "claim": "doRemainderTraversal should have an expanded description because its current doc comment is too vague.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The bufferIdInner loop should be swapped outside the i loop (or the order...
null
AutoPas__AutoPas__82
AutoPas/AutoPas
82
defect
5e842be01f8824efed11824d0db5bcf7c6bc802e
4ab65544911bdb66f102fb9c617a358c8e713dca
Simple auto tuning
A simple version of auto-tuning. When the tuning interval is reached (or at the start of the simulation) in every iteration a new container/traversal is selected and measured. When all options are tested the fastest combination is selected and used until the next tuning phase. This implementation resolves #71 in the ...
diff --git a/README.md b/README.md index 477eb3b318..cd245f7951 100644 --- a/README.md +++ b/README.md @@ -55,6 +55,7 @@ make ## Testing +### Running Tests to run tests: ``` make test @@ -82,7 +83,15 @@ or `ctest` arguments like `-R` (run tests matching regex) and `-D` (exclude test ``` ctest -R 'Array.*testA...
14
8
2
[{"id": "G0", "claim": "The md-flexible example hardcodes the AutoPas logger level to debug, and the reviewer asks whether that set_level line should be commented out.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The per-iteration AutoPasLogge...
null
AutoPas__AutoPas__837
AutoPas/AutoPas
837
defect
9c9c8bc4ea976796154726c907901501f925873d
1cd2908c9e95be33368f11e0881c9bda7a9b0119
Last result as extrapolation method
# Description This PR adds an option to use the last traversal time as an estimate for the upcoming iterations to predictive tuning. ## Resolved Issues - [x] fixes #831 # How Has This Been Tested? Added the new extrapolation method to the existing tests for predictive tuning.
diff --git a/src/autopas/options/ExtrapolationMethodOption.h b/src/autopas/options/ExtrapolationMethodOption.h index 02be75787f..81159fd045 100644 --- a/src/autopas/options/ExtrapolationMethodOption.h +++ b/src/autopas/options/ExtrapolationMethodOption.h @@ -33,6 +33,10 @@ class ExtrapolationMethodOption : public Optio...
2
2
0
[{"id": "G0", "claim": "The nested-ternary initialisation of _minNumberOfEvidence should be rewritten as the proposed immediately-invoked lambda, which is more readable and explicit.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The conditional...
null
AutoPas__AutoPas__983
AutoPas/AutoPas
983
defect
0324b2a5e8742fc3c26f7e1168ea29fa3957d83d
b39c1c0504f0091c4b987f09e85db3b448a4091d
AoS Remiander Traversal
# Description The remainder traversal for 2B always used AoS AND SoA functor calls, forcing the user to implement both. This is potentially problematic / annoying (see LADDS). This PR introduces a mechanic that SoA is only used if the current configuration asks for it. Otherwise only AoS is used. ## ~Related P...
diff --git a/applicationLibrary/molecularDynamics/molecularDynamicsLibrary/LJFunctor.h b/applicationLibrary/molecularDynamics/molecularDynamicsLibrary/LJFunctor.h index 13e8ec19f9..0d9ccd8489 100644 --- a/applicationLibrary/molecularDynamics/molecularDynamicsLibrary/LJFunctor.h +++ b/applicationLibrary/molecularDynamic...
7
7
0
[{"id": "G0", "claim": "The comment should read 'This is always AoS-based because the container particles are found with region iterators,' instead of 'AoS based' and the misspelled 'contaienr'.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The d...
null
Automattic__harper__1237
Automattic/harper
1,237
defect
2b29ab01d1c2a48440c146313fd9e15a525635a8
44264df5b76d22259e4c90fac1205efd65e9220d
feat(core): use Rayon in snapshot tests
# Issues Follow up to #1228 # Description <!-- Please include a summary of the change. --> <!-- Any details that you think are important to review this PR? --> <!-- Are there other PRs related to this one? --> I saw an easy candidate to parallelize snapshot tests using Rayon. This PR reduces total test ti...
diff --git a/Cargo.lock b/Cargo.lock index e0820b3f9b..ac90f87b6f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -815,6 +815,7 @@ dependencies = [ "quickcheck", "quickcheck_macros", "rand", + "rayon", "serde", "serde_json", "smallvec", diff --git a/Cargo.toml b/Cargo.toml index a9a573eae9..781ab496ea 100644 --...
1
1
0
[{"id": "G0", "claim": "The issues with debug breakpoints not working under the new `opt-level = 1` test profile should be documented.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
Automattic__harper__1694
Automattic/harper
1,694
defect
8a9299f75fd490d69a7af1baa249bfe8ada9c7c4
c5144c25e98bbc0fa7689fbd32064eb6133af9e1
feat(core): create rule to detect duplicate punctuation
# Description <!-- Please include a summary of the change. --> <!-- Any details that you think are important to review this PR? --> <!-- Are there other PRs related to this one? --> Detects erroneous use of extra punctuation. # How Has This Been Tested? <!-- Please describe how you tested your changes. --> ...
diff --git a/harper-core/src/linting/duplicate_punctuation.rs b/harper-core/src/linting/duplicate_punctuation.rs new file mode 100644 index 0000000000..e2780bb95b --- /dev/null +++ b/harper-core/src/linting/duplicate_punctuation.rs @@ -0,0 +1,197 @@ +use crate::linting::{Lint, LintKind, Linter, Suggestion}; +use crate:...
6
1
0
[{"id": "G0", "claim": "A test covering URL-like text such as https://example.com should be added.", "category": "testing", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The rule should not flag informal emphatic sequences like '!!!', '??' and the '?!' interrobang, or should p...
null
Automattic__harper__1894
Automattic/harper
1,894
defect
4de02447fd7a10242ab0cdb8ae26968d14a82654
61d1a41d37e9563d0c36a3edb2e89936f516a56a
feat: add ink support
# Issues Closes #1421 # Description Introduces parsing for the [ink](https://github.com/inkle/ink) language. As ink is a prose-ish language, like markdown and org mode, it seems like this should be a top level supported language. I'd like some guidance on how to add support to `harper-cli` and `harper-ls`, as ...
diff --git a/Cargo.lock b/Cargo.lock index acdbec0e3f..cc97f4da07 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2299,6 +2299,7 @@ dependencies = [ "dirs 6.0.0", "harper-comments", "harper-core", + "harper-ink", "harper-literate-haskell", "harper-pos-utils", "harper-stats", @@ -2393,6 +2394,17 @@ dependencies...
5
4
3
[{"id": "G0", "claim": "cargo clippy reports issues in the new code that the author needs to address.", "category": "maintainability", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "To add support to harper-cli and harper-ls, an entry for ink needs to be added to the parser mat...
null
Automattic__harper__2082
Automattic/harper
2,082
defect
812cf68f93a619494fc6c7cffe83efb576b54189
c1f17b2d3b5399a1c86b01fc88692f37c6f584d4
feat: add jjdescription parser
# Issues <!-- Link any relevant GitHub issues here. --> <!-- If this PR resolves the issue(s), write closes/fixes/resolves before the issue number(s) (e.g. Fixes #____, closes #____). --> jjdescription was briefly mentioned in https://github.com/Automattic/harper/issues/79. # Description <!-- Please include a s...
diff --git a/Cargo.lock b/Cargo.lock index ba1b0cbc4a..784c05f804 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2405,6 +2405,17 @@ dependencies = [ "tree-sitter-ink-lbz", ] +[[package]] +name = "harper-jjdescription" +version = "0.68.0" +dependencies = [ + "harper-core", + "harper-tree-sitter", + "paste", + "tree-s...
1
1
1
[{"id": "G0", "claim": "The PR adds a git dependency on tree-sitter-jjdescription, and the project cannot consume git dependencies, so it must come from a published crate instead.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
Automattic__harper__2299
Automattic/harper
2,299
defect
a437d1abd6ef083cfb8c90c38fae94b649fb3734
513eed667290b49885ac19ffd266fd154d50e92a
feat: implement #1036 join prefix to word
# Issues Resolves #1036 # Description Looks for prefixes that can be joined to their base word according to the dictionary. If written with a space, it checks the dictionary to see if it can be hyphenated or joined. If written with a hyphen it only checks if it can be joined. It first checks if it's in th...
diff --git a/harper-comments/tests/language_support_sources/common.mill b/harper-comments/tests/language_support_sources/common.mill index 57f76648d6..e6629e8df7 100644 --- a/harper-comments/tests/language_support_sources/common.mill +++ b/harper-comments/tests/language_support_sources/common.mill @@ -9,7 +9,7 @@ objec...
2
2
0
[{"id": "G0", "claim": "Remove the preexisting.md test registration and the underlying test file entirely.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "pre_existing"}, {"id": "G1", "claim": "Edit the yogurt_british_clean.md fixture so it stays clean (0 lints) instead of raising its expec...
null
Automattic__harper__2750
Automattic/harper
2,750
defect
5b6b149dcbe98cd73ae7592408011987a653f2e4
4a938b9895cc39e8ea7fda16180981df3d85ca47
fix(core): ignore top-level domains
# Issues <!-- Link any relevant GitHub issues here. --> <!-- If this PR resolves the issue(s), write closes/fixes/resolves before the issue number(s) (e.g. Fixes #____, closes #____). --> N/A # Description <!-- Please include a summary of the change. --> <!-- Any details that you think are important to review this P...
diff --git a/harper-core/src/document.rs b/harper-core/src/document.rs index c3986efecf..08e0267f2c 100644 --- a/harper-core/src/document.rs +++ b/harper-core/src/document.rs @@ -147,6 +147,7 @@ impl Document { self.condense_number_suffixes(); self.condense_ellipsis(); self.condense_latin(); ...
2
2
0
[{"id": "G0", "claim": "The COMMON_TOP_LEVEL_DOMAINS constant should be placed inside the function instead of at Document scope, where it feels out of place.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The loop in condense_common_top_level_do...
null
Automattic__harper__442
Automattic/harper
442
defect
adbf2b339b01a9179d9ef9c3423387449150a472
fecaab35d25598a7a1ab851f07f4f85f1f0a5e52
Typst Corrections
There are many issues with Typst support. Based on #391, so merge that one first.
diff --git a/harper-typst/src/lib.rs b/harper-typst/src/lib.rs index bd9ed1bbfe..325a74011b 100644 --- a/harper-typst/src/lib.rs +++ b/harper-typst/src/lib.rs @@ -7,8 +7,8 @@ use typst_translator::TypstTranslator; use harper_core::{Token, parsers::Parser}; use itertools::Itertools; use typst_syntax::{ - Source, -...
2
2
0
[{"id": "G0", "claim": "If the issue_399 test is being disabled rather than removed, a comment explaining why should be added at the commented-out line.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The pull request should include a brief summary...
null
Automattic__harper__452
Automattic/harper
452
defect
1717342a664576957160b04916b83e13f355a9d1
0fff589a41c841fc9fba9c3fc31f208d5509da62
feat(core): created linter for #426
This PR introduces a rule that searches for incorrect usage of the contraction `let's`. @ccoVeille or @hippietrail, before merging I'd like to add more test cases. If have some more, just shoot 'em below. Closes #426.
diff --git a/harper-core/src/linting/let_us_redundancy.rs b/harper-core/src/linting/let_us_redundancy.rs new file mode 100644 index 0000000000..ef85b0fe16 --- /dev/null +++ b/harper-core/src/linting/let_us_redundancy.rs @@ -0,0 +1,55 @@ +use crate::{ + patterns::{Pattern, SequencePattern, WordSet}, + Token, Token...
4
3
3
[{"id": "G0", "claim": "The rule should handle `let's`/`lets` followed by each of the listed pronouns (me, you, them, him, it, her, us), not only `us` and `me`.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The linter should catch the real `lets`-w...
null
Automattic__harper__553
Automattic/harper
553
defect
40f613884f4ef1648ca53f69955170e894725135
48296e6dafb44ee176d0b40ce5340c10e76007ce
feat(core): start support for hex numbers
towards #543 based on the existing `lex_number` which cuts off when the digits finish, which is fine because a unit of measurement etc might immediately follow. But with a hex number a non-hex letter might follow and not be flagged if it's a single letter. Also if it's very wrong, the start won't be flagged if it's ...
diff --git a/harper-core/src/lexing/mod.rs b/harper-core/src/lexing/mod.rs index d5f0f74a05..2aee8d5b59 100644 --- a/harper-core/src/lexing/mod.rs +++ b/harper-core/src/lexing/mod.rs @@ -3,6 +3,7 @@ mod hostname; mod url; use hostname::lex_hostname_token; +use ordered_float::OrderedFloat; use url::lex_url; use ...
3
2
1
[{"id": "G0", "claim": "The lexer should decide how to handle non-hex text stuck directly after a hex number, and ideally flag such \"hex with appendages\".", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Add Markdown test cases under harper-core/tests/te...
null
Automattic__juice__222
Automattic/juice
222
defect
70780ef3c951bbc17b772bde9c05e9cb9c0e700a
fadb57e3310d91ee0cb23244dbd42e28c99d05a7
Multiple properties declarations support
Here is my attempt to support multiple properties (See #221). Implementation notes: I decided to try to keep the current "styleProps" structure similar to the older one so that if you simply lookup a property value you will get the "more specific" value for that property, but if you know "multiple values" are supporte...
diff --git a/client.js b/client.js index 490f4423..f9bc5078 100644 --- a/client.js +++ b/client.js @@ -155,14 +155,23 @@ function inlineDocument($, css, options) { var value = style[i].value; var important = style[i].value.match(/!important$/) !== null; if (important && !options.p...
2
2
0
[{"id": "G0", "claim": "The Property constructor should treat additionalPriority as optional like priority and default it to an empty array (`this.additionalPriority = additionalPriority || [];`) so the optional-parameter handling is consistent.", "category": "maintainability", "verdict": "supported", "priority": "P2",...
null
Automattic__mongoose__13418
Automattic/mongoose
13,418
defect
7fee2dd221272b961e91d3b3eba062c971eea909
621d825a2d95c3954a703b8a206b651740e78196
fix: custom debug function not processing all args
closes #13364 Had to fix a couple of tests because of the changes. Let me know if that is not the correct approach.
diff --git a/lib/drivers/node-mongodb-native/collection.js b/lib/drivers/node-mongodb-native/collection.js index 6f5a97037d5..fc9235f6f48 100644 --- a/lib/drivers/node-mongodb-native/collection.js +++ b/lib/drivers/node-mongodb-native/collection.js @@ -208,8 +208,14 @@ function iter(i) { if (debug) { if (...
2
2
0
[{"id": "G0", "claim": "Do not initialize non-string placeholder values to empty strings; use `null` (e.g. `let range = null`) instead of `let range = ''`.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The fix should be backported to the 6.x br...
null
Automattic__mongoose__13649
Automattic/mongoose
13,649
defect
70fa116eefce220901614378302b1233aff79934
39b0b1b288769eb575cae34a616fb3cf655edbcf
fix: timestamps:false on bulkWrite works
closes #13611
diff --git a/lib/helpers/model/castBulkWrite.js b/lib/helpers/model/castBulkWrite.js index 4ae1f47efc8..1b0cafaef53 100644 --- a/lib/helpers/model/castBulkWrite.js +++ b/lib/helpers/model/castBulkWrite.js @@ -20,7 +20,6 @@ const setDefaultsOnInsert = require('../setDefaultsOnInsert'); module.exports = function castB...
2
2
1
[{"id": "G0", "claim": "The test should sleep for a few milliseconds (5 suggested) before executing bulkWrite so it cannot run in the same millisecond as the create and produce a false positive.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The new `ti...
null
Automattic__mongoose__13654
Automattic/mongoose
13,654
defect
70fa116eefce220901614378302b1233aff79934
a6bf1161e26db49dbb5de912f68b70ec203aaae2
disable id virtual if `alias:id` set
closes #13650
diff --git a/lib/helpers/schema/idGetter.js b/lib/helpers/schema/idGetter.js index ba5ef1011c2..6df8a8cc04f 100644 --- a/lib/helpers/schema/idGetter.js +++ b/lib/helpers/schema/idGetter.js @@ -12,6 +12,9 @@ module.exports = function addIdGetter(schema) { if (!autoIdGetter) { return schema; } + if (schema.al...
1
1
0
[{"id": "G0", "claim": "The test's `removeMultipleSpaces` helper should be inlined as a concise arrow function in the schema definition.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}]
null
Automattic__mongoose__13846
Automattic/mongoose
13,846
defect
f552fe286a42373e50970072352b66a1fd443a1c
b36fd11d0399e7e4348e9b3da7c6b3d94795ef7f
fix(discriminator): make base schema paths come before discriminator schema paths when running setters, validators, etc.
Fix #13794 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/helpers/discriminator/mergeDiscriminatorSchema.js b/lib/helpers/discriminator/mergeDiscriminatorSchema.js index fcba6c231c4..669bba4c33d 100644 --- a/lib/helpers/discriminator/mergeDiscriminatorSchema.js +++ b/lib/helpers/discriminator/mergeDiscriminatorSchema.js @@ -34,7 +34,8 @@ module.exports = func...
1
1
0
[{"id": "G0", "claim": "The schema.tree merge should be done inside mergeDiscriminatorSchema as a separate case rather than as a standalone Object.assign call outside it in discriminator.js.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
Automattic__mongoose__14068
Automattic/mongoose
14,068
defect
f58c6c254c7af28f511c8ff246f9f7afd175c59c
fd94cd1db3a4e7f88b0ddad3bb1d75c98975e43d
Island rhythms/gh 14055
closes #14055 It works but the simplicity of the solution makes me feel like I might have broken a bunch of other stuff.
diff --git a/lib/schema.js b/lib/schema.js index a4b6e6c2d54..a21f845699d 100644 --- a/lib/schema.js +++ b/lib/schema.js @@ -413,7 +413,7 @@ Schema.prototype._clone = function _clone(Constructor) { s.tree = clone(this.tree); s.paths = Object.fromEntries( - Object.entries(this.paths).map(([key, value]) => ([k...
1
1
1
[{"id": "G0", "claim": "Skipping cloning of document arrays in _clone() undercuts the core idea of clone() and seems incorrect; the author should instead add a _skipApplyDiscriminators option in the DocumentArray schema file (as in PR #14011) so doc arrays are still cloned.", "category": "design", "verdict": "supported...
null
Automattic__mongoose__14161
Automattic/mongoose
14,161
defect
c97d91ccb95736b8d3365de8bffb02c31d6fd541
86df50cde6e1a9c3561c5389ffeb0ec6cb35d61a
fix(update): set CastError path to full path if casting update fails
Fix #14114 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/schema/bigint.js b/lib/schema/bigint.js index f6619a19e35..02912627dd5 100644 --- a/lib/schema/bigint.js +++ b/lib/schema/bigint.js @@ -212,7 +212,14 @@ SchemaBigInt.prototype.castForQuery = function($conditional, val, context) { return this.applySetters(null, val, context); } - return this....
1
1
1
[{"id": "G0", "claim": "Other schematypes like uuid or Decimal128 may not get the same CastError full-path handling, since the change seems tied to applySetters calls in castForQuery.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
Automattic__mongoose__14306
Automattic/mongoose
14,306
defect
8ef0d9a8f314535e0b9863f4065549094eb52f3a
c480bd6dbbad7682a05edd99353d0bac0d0c334a
feat(model): add `recompileSchema()` function to models to allow applying schema changes after compiling
Fix #14296 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/model.js b/lib/model.js index 0ced344223a..b793218077f 100644 --- a/lib/model.js +++ b/lib/model.js @@ -4861,6 +4861,34 @@ Model.__subclass = function subclass(conn, schema, collection) { return Model; }; +/** + * Apply changes made to this model's schema after this model was compiled. + * By def...
4
3
2
[{"id": "G0", "claim": "Add another test case verifying that the schema isn't modified without calling recompileSchema, unless that is already implicitly tested elsewhere.", "category": "testing", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Insert a blank jsdoc line between ...
null
Automattic__mongoose__14395
Automattic/mongoose
14,395
defect
c02141b916029cee9be5ffb0aae00db62248456b
4ee3d277013642af9d4e4026eff709ff6f961d17
fix(document): make `$clone` avoid converting subdocs into POJOs
Re: #14353 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/document.js b/lib/document.js index 4127102f0c9..78b6f58eff2 100644 --- a/lib/document.js +++ b/lib/document.js @@ -4735,7 +4735,7 @@ Document.prototype.$clone = function() { const clonedDoc = new Model(); clonedDoc.$isNew = this.$isNew; if (this._doc) { - clonedDoc._doc = clone(this._doc);...
1
1
1
[{"id": "G0", "claim": "The retainDocuments condition added in clone() tests every operand against null, which is out of style with the surrounding ifs and, as the author's reply confirms, incorrect: `options.retainDocuments === false` should turn off the retainDocuments functionality but `options.retainDocuments != nu...
null
Automattic__mongoose__14453
Automattic/mongoose
14,453
defect
e3f320515297240f6bca4ec6be7b14c442a97a46
e73e822f09639855ceaddc6dd2ba700a05cc0b60
fix(schema): avoid returning string 'nested' as schematype
Fix #14435 Fix #14443 @FaizBShah <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding...
diff --git a/lib/schema.js b/lib/schema.js index 35e3de56b4d..0c60ff16ca9 100644 --- a/lib/schema.js +++ b/lib/schema.js @@ -1220,10 +1220,18 @@ function _getPath(schema, path, cleanPath) { return schema.paths[path]; } if (schema.subpaths.hasOwnProperty(cleanPath)) { - return schema.subpaths[cleanPath]; +...
5
5
0
[{"id": "G0", "claim": "In the second added test, the Code document should be created with `Code.create()` instead of `new Code({...}).save()`, unless that syntax is explicitly meant to be tested.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "I...
null
Automattic__mongoose__14531
Automattic/mongoose
14,531
defect
c97c060119bdc3c52d42d63b7fe6d6af046b6f5b
299828d3d7a447d69fc114c502bd84595ecbf943
fix(array): avoid converting to `$set` when calling `pull()` on an element in the middle of the array
Re: #14502 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/document.js b/lib/document.js index d820f2974f5..b8b8ed4360b 100644 --- a/lib/document.js +++ b/lib/document.js @@ -2381,15 +2381,29 @@ Document.prototype.isDirectModified = function(path) { } if (typeof path === 'string' && path.indexOf(' ') === -1) { - return this.$__.activePaths.getStateP...
1
1
0
[{"id": "G0", "claim": "The new test's schema variable should be named BlogPostSchema instead of blogPostSchema for consistency with the surrounding CamelCase naming.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}]
null
Automattic__mongoose__14580
Automattic/mongoose
14,580
defect
88afc3397cd7540ac9ab3193b7f240cf15badf5d
a20eaa8e6753ea318cb7aeaedaa5390f67ebd129
fix(query): shallow clone $or, $and if merging onto empty query filter
Fix #14567 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/query.js b/lib/query.js index 22956fb818f..63b17a1746d 100644 --- a/lib/query.js +++ b/lib/query.js @@ -2380,13 +2380,21 @@ Query.prototype.merge = function(source) { } opts.omit = {}; - if (this._conditions && this._conditions.$and && source.$and) { + if (source.$and) { opts.omit['$and'...
5
3
2
[{"id": "G0", "claim": "Properties are copied from `from` to `to` in utils.merge without guarding against prototype pollution.", "category": "security", "verdict": "uncertain", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The `$and` merge code dereferences `this._conditions.$and` in an `else` branch...
null
Automattic__mongoose__14679
Automattic/mongoose
14,679
defect
23f6e0af927b0dc929aa0106635b96cb80119437
19deceeb7f453d24de60608336f1806bfe7f5d1e
Remove default connection if setting createInitialConnection to false after Mongoose instance created
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in the `test/do...
diff --git a/lib/mongoose.js b/lib/mongoose.js index cfac2331ced..0676ceeb355 100644 --- a/lib/mongoose.js +++ b/lib/mongoose.js @@ -33,6 +33,7 @@ const SetOptionError = require('./error/setOptionError'); const applyEmbeddedDiscriminators = require('./helpers/discriminator/applyEmbeddedDiscriminators'); const defau...
2
2
1
[{"id": "G0", "claim": "The inline default-connection-creation code should be put in a function to de-duplicate default connection creation.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Add tests for the case where a model is registered on the...
null
Automattic__mongoose__14717
Automattic/mongoose
14,717
defect
1a0cda7d974cf6d10700d4fb7f0d3f0e9ab26523
02afe2ba7937cfb11745758cf04a582c8dd41332
feat: allow setting array default value to `null`
Fix #6691 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in...
diff --git a/docs/faq.md b/docs/faq.md index 8ae6a441b35..a0d493bc879 100644 --- a/docs/faq.md +++ b/docs/faq.md @@ -314,7 +314,7 @@ const Kitten = connection.model('Kitten', kittySchema); <a class="anchor" href="#array-defaults">**Q**</a>. How can I change mongoose's default behavior of initializing an array path t...
1
1
1
[{"id": "G0", "claim": "It would likely be good to add new tests for the new behavior of setting an array default value to `null`.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
Automattic__mongoose__14728
Automattic/mongoose
14,728
defect
446b9232885b9e550eeacacceac4f7ba51695948
f28514ec11b7221bde3322cd6bed5b80038e8ba1
Avoid leaving subdoc defaults on top-level doc when setting subdocument to same value
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in the `test/do...
diff --git a/lib/document.js b/lib/document.js index ffaa066ef58..cf204974f0c 100644 --- a/lib/document.js +++ b/lib/document.js @@ -155,7 +155,9 @@ function Document(obj, fields, skipId, options) { // By default, defaults get applied **before** setting initial values // Re: gh-6155 if (defaults) { - ...
1
1
1
[{"id": "G0", "claim": "Since mongoose 8.5.1, getters on properties in deeply nested subdocuments (3 levels down) are called but their results do not show up in the object returned by toObject({ getters: true, virtuals: false }), which the reporter suspects means this change stopped applying getters recursively to nest...
null
Automattic__mongoose__14744
Automattic/mongoose
14,744
defect
090297e7fc904f4d43f6af953e905939e9ef4669
1f9fa4ab85a091df1760c7029a1eba7d1a965955
fix(model): support `session: null` option for `save()` to opt out of automatic `session` option with `transactionAsyncLocalStorage`
Fix #14736 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/model.js b/lib/model.js index 9cd7a14d6de..82dd0857bed 100644 --- a/lib/model.js +++ b/lib/model.js @@ -290,9 +290,9 @@ Model.prototype.$__handleSave = function(options, callback) { const session = this.$session(); const asyncLocalStorage = this[modelDbSymbol].base.transactionAsyncLocalStorage?...
1
1
1
[{"id": "G0", "claim": "The replica-set transaction tests consistently fail with this PR (5 failures in test/docs/transactions.test.js), possibly because `options.session` is never transferred to `saveOptions.session`.", "category": "correctness", "verdict": "supported", "priority": "P0", "scope": "introduced"}]
null
Automattic__mongoose__14756
Automattic/mongoose
14,756
defect
e4462c6c80b8b395187b382f7dcb3c398293cd78
195103cec3aad94830f7f341387538d11e1dd06b
types: allow calling `SchemaType.cast()` without `parent` and `init` parameters
Fix #14748 Re: #9076 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or ...
diff --git a/test/schema.test.js b/test/schema.test.js index 8cd58ba7b9f..3076c9df62a 100644 --- a/test/schema.test.js +++ b/test/schema.test.js @@ -3258,4 +3258,24 @@ describe('schema', function() { await q; }); + + it('supports casting object to subdocument (gh-14748) (gh-9076)', function() { + const ne...
2
2
0
[{"id": "G0", "claim": "Fix the lint issue at the end of test/types/schema.test.ts by adding the missing newline at end of file.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "Also add a test line covering the return type of the cast() overload ...
null
Automattic__mongoose__14803
Automattic/mongoose
14,803
defect
f98b46307fa7a8487b469823c75cbb72e13c8193
28b50f01f90717ab896a3ea10d8526805250fab0
fix(document): make sure depopulate does not convert hydrated arrays to vanilla arrays
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in the `test/do...
diff --git a/lib/document.js b/lib/document.js index afc9e5ceacc..19298d05773 100644 --- a/lib/document.js +++ b/lib/document.js @@ -4774,7 +4774,23 @@ Document.prototype.depopulate = function(path) { continue; } delete populated[key]; - utils.setValue(key, populatedIds, this._doc); + i...
1
1
0
[{"id": "G0", "claim": "Asks whether the commented-out failing assertion about band.embeddedMembers[0].$populated('member') was already failing before the PR, i.e. whether depopulate() not updating subdocs' $populated() is a pre-existing gap rather than a regression.", "category": "correctness", "verdict": "supported",...
null
Automattic__mongoose__14837
Automattic/mongoose
14,837
defect
05055f0a6fa921a045e943827eaefa90be730f37
b42be657de04b9ad2eb1b13fe74c67aee9a71448
fix(model): throw error if `bulkSave()` did not insert or update any documents
Re: #14763 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/model.js b/lib/model.js index e0270872155..3891bef8a13 100644 --- a/lib/model.js +++ b/lib/model.js @@ -3364,11 +3364,19 @@ Model.bulkWrite = async function bulkWrite(ops, options) { }; /** - * takes an array of documents, gets the changes and inserts/updates documents in the database - * accordi...
1
1
0
[{"id": "G0", "claim": "The docs bullet should say that `bulkWrite()` did not insert or update **any** documents.", "category": "documentation", "verdict": "supported", "priority": "P3", "scope": "introduced"}]
null
Automattic__mongoose__14883
Automattic/mongoose
14,883
defect
286ab985297e8debb85b20144d82196572a978c1
5e0e36e387b6665cc40b8e9be525256f78b8ab30
fix: depopulate if `push()` or `addToSet()` with an ObjectId on a populated array
Fix #1635 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in...
diff --git a/lib/types/array/methods/index.js b/lib/types/array/methods/index.js index cf31914bb7e..3322bbe56e8 100644 --- a/lib/types/array/methods/index.js +++ b/lib/types/array/methods/index.js @@ -410,6 +410,7 @@ const methods = { addToSet() { _checkManualPopulation(this, arguments); + _depopulateIfNec...
1
1
1
[{"id": "G0", "claim": "The new behaviour introduced by this PR — pushing a raw id type (e.g. an ObjectId) to a populated array depopulates it — should be documented in the guide; the reviewer asks whether it already is.", "category": "documentation", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
Automattic__mongoose__14887
Automattic/mongoose
14,887
defect
4352d903aef147be17853cc59802606f631da196
01075919b1d6b49d3c96226284beaf145a6ca3f4
feat(query): cast $rename
Fix #3027 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in...
diff --git a/lib/helpers/query/castUpdate.js b/lib/helpers/query/castUpdate.js index eb69bc89a09..94f374d8b58 100644 --- a/lib/helpers/query/castUpdate.js +++ b/lib/helpers/query/castUpdate.js @@ -2,6 +2,7 @@ const CastError = require('../../error/cast'); const MongooseError = require('../../error/mongooseError'); ...
1
1
0
[{"id": "G0", "claim": "The rewritten $rename test should likely also assert that the source field was removed, i.e. doc.foo is undefined after the update (unless that is already tested elsewhere).", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
Automattic__mongoose__14890
Automattic/mongoose
14,890
defect
1b18d5bafe9dab07d8c7d3e0f6c78730522fdafa
5b5f3d822f49908c4e257ee7350880eba9bf0bb2
fix: make getters convert uuid to string when calling toObject() and toJSON()
Fix #14869 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/schema/uuid.js b/lib/schema/uuid.js index aa72c42107f..cbee764e4ab 100644 --- a/lib/schema/uuid.js +++ b/lib/schema/uuid.js @@ -26,19 +26,6 @@ function hex2buffer(hex) { return buff; } -/** - * Helper function to convert the buffer input to a string - * @param {Buffer} buf The buffer to convert t...
2
2
0
[{"id": "G0", "claim": "In binaryToString, drop the redundant `uuidBin != null &&` from the hex assignment since the if directly above already checks for null.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "In SchemaUUID's cast, remove the dupli...
null
Automattic__mongoose__14908
Automattic/mongoose
14,908
defect
f9ca7459ed9080ec462f251734185ade537c2afd
a06debe2363490bb140001a570ced20a4a0227e8
fix(model): filter applying static hooks by default if static name conflicts with mongoose middleware
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in the `test/do...
diff --git a/lib/constants.js b/lib/constants.js index f5f5c5a19b3..3a03bd502fc 100644 --- a/lib/constants.js +++ b/lib/constants.js @@ -44,3 +44,30 @@ const aggregateMiddlewareFunctions = [ ]; exports.aggregateMiddlewareFunctions = aggregateMiddlewareFunctions; + +/*! + * ignore + */ + +const modelMiddlewareFuncti...
1
1
0
[{"id": "G0", "claim": "The dedupe of middleware function names could use `Array.from(new Set([...]))` instead of `reduce()`.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
Automattic__mongoose__14987
Automattic/mongoose
14,987
defect
e12301b3fa6b143ab70217d3e2c46489806a4950
100e896de204556cb2fadb044b2cee3303104170
feat(model): add hideIndexes option to syncIndexes() and cleanIndexes()
Fix #14868 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/model.js b/lib/model.js index 60e6ee2e147..80fa8849fd0 100644 --- a/lib/model.js +++ b/lib/model.js @@ -1220,6 +1220,7 @@ Model.createCollection = async function createCollection(options) { * * @param {Object} [options] options to pass to `ensureIndexes()` * @param {Boolean} [options.background=n...
1
1
0
[{"id": "G0", "claim": "Since hiding indexes still returns their names, the JSDoc @return should say \"list of dropped or hidden index names\" instead of \"list of dropped index names\".", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
Automattic__mongoose__15000
Automattic/mongoose
15,000
defect
10a3aeda6bfb15f04fc2dd5698826a80005460da
008f708360ac7e9bbb1353bd470734c1ff5207e8
fix(query): add `overwriteImmutable` option to allow updating immutable properties without disabling strict mode
Fix #8619 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in...
diff --git a/docs/timestamps.md b/docs/timestamps.md index 17706a6e0f9..dcb4a47be83 100644 --- a/docs/timestamps.md +++ b/docs/timestamps.md @@ -236,3 +236,20 @@ await User.findOneAndUpdate({}, { $setOnInsert: { updatedAt: new Date() } }, { timestamps: { createdAt: true, updatedAt: false } }); ``` + +## Updating T...
6
6
1
[{"id": "G0", "claim": "The doc tells the user to set `overwriteImmutable` to `false` when it must be `true` to allow overwriting `createdAt`.", "category": "documentation", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "Move the entire second sentence of the comment to its own...
null
Automattic__mongoose__15036
Automattic/mongoose
15,036
defect
a0fdb9e2e17b9444e9ac02b4c21dbf10d073cb3f
f386004c061ebaeda767fbd094180a42d6f9092a
fix(model): handle array filters when casting bulkWrite
Fix #14978 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/helpers/model/castBulkWrite.js b/lib/helpers/model/castBulkWrite.js index 1afb36987fa..6420ad7e2e6 100644 --- a/lib/helpers/model/castBulkWrite.js +++ b/lib/helpers/model/castBulkWrite.js @@ -103,7 +103,8 @@ module.exports = function castBulkWrite(originalModel, op, options) { }); op[...
2
1
0
[{"id": "G0", "claim": "The blank line before the closing `});` of the new array-filters test should be removed.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "For completeness, the test's testArray should also contain an element that does not m...
null
Automattic__mongoose__15080
Automattic/mongoose
15,080
defect
cf50772805184ccd1de5bd31ee5c44d3fbebc15f
f8c705e17c442a73489c27f6789eed9e76bd2a0b
fix: mark documents that are populated using hydratedPopulatedDocs option as populated in top-level doc
Fix #15048 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/document.js b/lib/document.js index 06204519db9..9ae9fc8758b 100644 --- a/lib/document.js +++ b/lib/document.js @@ -805,6 +805,14 @@ function init(self, obj, doc, opts, prefix) { reason: e })); } + } else if (opts.hydratedPopulatedDocs) { + doc[i] ...
2
2
1
[{"id": "G0", "claim": "The new hydrate test should call db.deleteModel(/Company/) alongside db.deleteModel(/User/) before registering the Company model.", "category": "testing", "verdict": "supported", "priority": "P0", "scope": "introduced"}, {"id": "G1", "claim": "The hydratedPopulatedDocs option is not documented i...
null
Automattic__mongoose__15112
Automattic/mongoose
15,112
defect
b9136c1e46644e6cee32d8fbf36d0d489a26afe9
e25dafc296d9930b17c52d3fc6d33590e29a1de9
fix(schema): avoid throwing duplicate index error if index spec keys have different order or index has a custom name
Fix #15109 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/helpers/indexes/isIndexSpecEqual.js b/lib/helpers/indexes/isIndexSpecEqual.js new file mode 100644 index 00000000000..f26ed34efd9 --- /dev/null +++ b/lib/helpers/indexes/isIndexSpecEqual.js @@ -0,0 +1,32 @@ +'use strict'; + +/** + * Compares two index specifications to determine if they are equal. + * ...
1
1
0
[{"id": "G0", "claim": "The `-` in the JSDoc `@param` lines for spec1 and spec2 is unnecessary and should be removed.", "category": "documentation", "verdict": "supported", "priority": "P3", "scope": "introduced"}]
null
Automattic__mongoose__15124
Automattic/mongoose
15,124
defect
efae3baec02a9b0a0660e2e35e154f0e6309d297
3696a0db66251b81c255eac55f279d8abbfe42ec
fix(model): handle document array paths set to non-array values in Model.castObject()
Fix #15075 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/model.js b/lib/model.js index ddf149dd5d9..e27cdba98d9 100644 --- a/lib/model.js +++ b/lib/model.js @@ -69,6 +69,7 @@ const util = require('util'); const utils = require('./utils'); const minimize = require('./helpers/minimize'); const MongooseBulkSaveIncompleteError = require('./error/bulkSaveIncom...
1
1
0
[{"id": "G0", "claim": "The castNonArraysOption lookup should use optional chaining and nullish coalescing (schemaType.options?.castNonArrays ?? schemaType.constructor.options.castNonArrays) instead of the longer ternary, per the reviewer's suggestion block.", "category": "maintainability", "verdict": "supported", "pri...
null
Automattic__mongoose__15162
Automattic/mongoose
15,162
defect
03343adcaced15f05234c4232e10dfe8a73722f5
e519ac3c9392f52bfc1481e1ba0c7c9e6194a632
feat(model): add insertOne() function to insert a single doc
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in the `test/do...
diff --git a/lib/model.js b/lib/model.js index e400536eb94..b0b7a89566e 100644 --- a/lib/model.js +++ b/lib/model.js @@ -2774,6 +2774,49 @@ Model.create = async function create(doc, options) { return res; }; +/** + * Shortcut for saving one document to the database. + * `MyModel.insertOne(obj, options)` is almost...
3
3
0
[{"id": "G0", "claim": "The JSDoc `@param` name should be `doc` instead of `docs`, matching the function's actual parameter.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Why introduce the `toSave` alias instead of using `doc` directly?", "catego...
null
Automattic__mongoose__15163
Automattic/mongoose
15,163
defect
03343adcaced15f05234c4232e10dfe8a73722f5
fc0ee9f2e7fd376858b315c2c3d5158551f3f881
feat(document): support schematype-level transform option
Fix #15084 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/document.js b/lib/document.js index 52f39f43288..55b916893ea 100644 --- a/lib/document.js +++ b/lib/document.js @@ -4256,24 +4256,25 @@ function applySchemaTypeTransforms(self, json) { for (const path of paths) { const schematype = schema.paths[path]; - if (typeof schematype.options.transf...
4
4
1
[{"id": "G0", "claim": "The new test's static class field (`static schemaName = 'CustomType'`) uses syntax the project's eslint ecmaVersion doesn't support, so the eslint ecmaVersion should be updated (node 16.20 supports it) or the static defined with the old syntax.", "category": "tooling", "verdict": "supported", "p...
null
Automattic__mongoose__15206
Automattic/mongoose
15,206
defect
1020947f9ca719068ab71cea214614c48c5d40f8
6e5e048cc67ab9fb9a2e2844a59278fe2369b4dd
fix(aggregate): improve error when calling `near()` with invalid coordinates
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in the `test/do...
diff --git a/lib/aggregate.js b/lib/aggregate.js index 1d4a0d18e22..34d658d1188 100644 --- a/lib/aggregate.js +++ b/lib/aggregate.js @@ -397,6 +397,17 @@ Aggregate.prototype.project = function(arg) { */ Aggregate.prototype.near = function(arg) { + if (arg == null) { + throw new MongooseError('Aggregate `near()...
1
1
0
[{"id": "G0", "claim": "The `arg` and `arg.near` properties handled by the new validation should be documented in the jsdoc, or the link to the MongoDB docs should be confirmed sufficient.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
Automattic__mongoose__15229
Automattic/mongoose
15,229
defect
610740379727dc84a82e3a60c1728054acdf3da4
9444bfe55d070bfe39278a3c7e9fbcf3d173fc35
feat(connection): make connection helpers respect bufferTimeoutMS
Fix #15201 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/collection.js b/lib/collection.js index 117a8c69551..2e4272be505 100644 --- a/lib/collection.js +++ b/lib/collection.js @@ -311,13 +311,7 @@ Collection.prototype._getBufferTimeoutMS = function _getBufferTimeoutMS() { if (opts && opts.schemaUserProvidedOptions != null && opts.schemaUserProvidedOption...
1
1
0
[{"id": "G0", "claim": "The timeout test could await the promise itself until it times out instead of adding a `setTimeout()` in-between.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
Automattic__mongoose__15231
Automattic/mongoose
15,231
defect
610740379727dc84a82e3a60c1728054acdf3da4
97d7fae96d35ba4e8db1dbd618b648d2520292f0
Introduce populate ordered option for populating in series rather than in parallel
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in the `test/do...
diff --git a/lib/document.js b/lib/document.js index 9554c3a811e..7b5d43bde79 100644 --- a/lib/document.js +++ b/lib/document.js @@ -4508,6 +4508,8 @@ Document.prototype.equals = function(doc) { * @param {Object|Function} [options.match=null] Add an additional filter to the populate query. Can be a filter object cont...
1
1
1
[{"id": "G0", "claim": "The pull request should add tests for the populate `ordered` option — at least a basic test that the new ordered code path produces a correct result instead of erroring — since that diverging code path is otherwise completely untested.", "category": "testing", "verdict": "supported", "priority":...
null
Automattic__mongoose__15266
Automattic/mongoose
15,266
defect
987f1ada7ed2c4c2f3b3ce8bf812e8e58b44393e
0173dece051669f7bd61c2ced6e30d3b7724cdde
fix(model+connection): return MongoDB BulkWriteResult instance even if no valid ops
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in the `test/do...
diff --git a/lib/connection.js b/lib/connection.js index 9c75df9739e..53137d0b10a 100644 --- a/lib/connection.js +++ b/lib/connection.js @@ -559,7 +559,12 @@ Connection.prototype.bulkWrite = async function bulkWrite(ops, options) { 'bulkWrite' ); } - return getDefaultBulkwriteResult(); +...
1
1
0
[{"id": "G0", "claim": "The repeated setup of a BulkWriteResult's .mongoose properties in Model.bulkWrite is a somewhat common operation and should maybe be extracted into its own function.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
Automattic__mongoose__15337
Automattic/mongoose
15,337
defect
0aa998371e2a6deffdf525770f81d5441f73f4cb
12671f4eeb9d2b77a091ff789b49238b5657d1e7
Implement Query findById methods
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in the `test/do...
diff --git a/lib/query.js b/lib/query.js index af8efb2f078..4c878b5b675 100644 --- a/lib/query.js +++ b/lib/query.js @@ -3333,8 +3333,6 @@ function prepareDiscriminatorCriteria(query) { * @param {Boolean} [options.multipleCastError] by default, mongoose only returns the first error that occurred in casting the query....
2
1
0
[{"id": "G0", "claim": "The callback checks in the new Query.prototype.findById/findByIdAndUpdate/findByIdAndDelete methods should be removed, since those methods did not exist when Mongoose supported callbacks.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G...
null
Automattic__mongoose__15366
Automattic/mongoose
15,366
defect
2fc58dae924c688ec9796cfaafd8f4b253327a00
9049eff2ef96fd05426578862692e55b513d36d3
ci(NODE-6919): Use `mongodb-runner` in encryption cluster setup
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in the `test/do...
diff --git a/.gitignore b/.gitignore index ac921cdc28c..477987d925e 100644 --- a/.gitignore +++ b/.gitignore @@ -69,5 +69,4 @@ notes.md list.out data -*.pid -mo-expansion* +fle-cluster-config.json diff --git a/package.json b/package.json index 32f4fafafbe..3ad277dae7e 100644 --- a/package.json +++ b/package.json @@...
1
1
0
[{"id": "G0", "claim": "The PR author should merge the latest changes from the csfle branch into this branch so the tests can run correctly in this PR, since they currently do not run because GitHub Actions dropped support for Ubuntu 20.04.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope":...
null
Automattic__mongoose__15378
Automattic/mongoose
15,378
defect
98b4f0f90fff33d65dd986b4eb48ab6e81d9da07
f26d218002b4b8549760e236d9b6c1ceceb7b4a2
BREAKING CHANGE: make UUID schema type return bson UUIDs
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in the `test/do...
diff --git a/docs/migrating_to_9.md b/docs/migrating_to_9.md index 26a34b50df9..a2b508cb93d 100644 --- a/docs/migrating_to_9.md +++ b/docs/migrating_to_9.md @@ -207,3 +207,34 @@ In Mongoose 9, this option is no longer necessary because Mongoose no longer sto ## Node.js version support Mongoose 9 requires Node.js 18...
2
2
1
[{"id": "G0", "claim": "The stray 'Buffer' appended to the closing brace of the IProfile interface in test/types/schema.test.ts appears to be a typo that may cause a syntax error and should be removed so that only '}' remains.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}...
null
Automattic__mongoose__15388
Automattic/mongoose
15,388
defect
b1ac0f50ec925f9b87c2c4d6bc6ab9b9740a9a28
16ae35d9df68ac9d3f55328fac3bc7425cddde48
fix(query): handle casting array filter paths underneath array filter paths with embedded discriminators
Fix #15386 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/helpers/query/getEmbeddedDiscriminatorPath.js b/lib/helpers/query/getEmbeddedDiscriminatorPath.js index 548cf3b0330..60bad97f816 100644 --- a/lib/helpers/query/getEmbeddedDiscriminatorPath.js +++ b/lib/helpers/query/getEmbeddedDiscriminatorPath.js @@ -17,7 +17,7 @@ const updatedPathsByArrayFilter = req...
5
2
0
[{"id": "G0", "claim": "The JSDoc for getPath should be updated to describe the new 'discriminatorValueMap' parameter to aid future maintainers.", "category": "documentation", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "A comment should be added to castArrayFilters.js docume...
null
Automattic__mongoose__15402
Automattic/mongoose
15,402
defect
65b2d12a8f85f86136cfaf32947f338ba0c5f451
ce4c3d58de447a70724ff118b49a0302d36b9e82
Fix: Add strictFilter option to findOneAndUpdate (#14913)
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. --> **Summary** This PR addresses [Issue #14913](https://github.com/Automattic/mongoose/issues/14913) by adding a `strictFilter` option to `findOneAndUpdate...
diff --git a/lib/query.js b/lib/query.js index f34ac4bba8b..aafcc89cfb8 100644 --- a/lib/query.js +++ b/lib/query.js @@ -3311,6 +3311,7 @@ function prepareDiscriminatorCriteria(query) { * - `maxTimeMS`: puts a time limit on the query - requires mongodb >= 2.6.0 * - `runValidators`: if true, runs [update validators]...
4
4
4
[{"id": "G0", "claim": "Verify that 'filter' is a plain object before checking its keys (e.g. using typeof filter === 'object' and filter !== null) to ensure that non-object inputs do not bypass the strictFilter check.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id":...
null
Automattic__mongoose__15415
Automattic/mongoose
15,415
defect
2dda096c423d38f226453c3a673d2fb8b2013f93
b107906eb3e162ca06aeb51c56e5fe3e2b2409d7
fix(model): make bulkSave() rely on document.validate() to validate docs and skip bulkWrite casting
Fix #15410 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/model.js b/lib/model.js index 667c7ec309c..4ae9c3f90bd 100644 --- a/lib/model.js +++ b/lib/model.js @@ -3394,7 +3394,7 @@ Model.bulkWrite = async function bulkWrite(ops, options) { return bulkWriteResult; } - const validations = ops.map(op => castBulkWrite(this, op, options)); + const valid...
3
2
1
[{"id": "G0", "claim": "The unconditionally returning null in Model.buildBulkWriteOperations may override valid write operations from the map callback; consider returning null only when a document has no changes.", "category": "correctness", "verdict": "uncertain", "priority": "P3", "scope": "introduced"}, {"id": "G1",...
null
Automattic__mongoose__15477
Automattic/mongoose
15,477
defect
7f98d3fead5fe3ab0a985a49fbe7a2c898004f4f
923bacb8ecb1d538960a5a51afbf02aee1037fa5
fix(document+schema): improve handling for setting paths underneath maps, including maps of maps
Fix #15461 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/document.js b/lib/document.js index 46b21e3397c..3ec2aea0fc2 100644 --- a/lib/document.js +++ b/lib/document.js @@ -1302,7 +1302,7 @@ Document.prototype.$set = function $set(path, val, type, options) { let cur = this._doc; let curPath = ''; for (i = 0; i < parts.length - 1; ++i) { - cur = c...
4
2
0
[{"id": "G0", "claim": "The assertion for 'myMap.key.name' is duplicated in the test and the redundant copy should be removed to keep the test concise.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "An inline comment should be added in getMapPath explai...
null
Automattic__mongoose__15492
Automattic/mongoose
15,492
defect
ffaadd142d2d42438940743faaa9458adbdd7b03
1d65452b583c209cd26c9ed21be0b3a1f41dbed6
fix(schema): support toJSONSchema() on mixed types and improve error message about unsupported types
Fix #15489 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/schema/mixed.js b/lib/schema/mixed.js index a645a981f7b..658d5e56e87 100644 --- a/lib/schema/mixed.js +++ b/lib/schema/mixed.js @@ -124,6 +124,18 @@ SchemaMixed.prototype.castForQuery = function($cond, val) { return val; }; +/** + * Returns this schema type's representation in a JSON schema. + * ...
2
1
0
[{"id": "G0", "claim": "The new SchemaMixed.prototype.toJSONSchema is declared with no parameters while its JSDoc documents an options object; the signature should take an options parameter (e.g. function toJSONSchema(options = {})) for consistency with other types.", "category": "correctness", "verdict": "supported", ...
null
Automattic__mongoose__15514
Automattic/mongoose
15,514
defect
8ac9f8f7d7050873377a6f418a62d1e27a1355df
5734c009c1a2021990c2b0132ce1e54624531a54
BREAKING CHANGE: remove background option from indexes
Fix #15476 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/docs/compatibility.md b/docs/compatibility.md index ffe6a031778..f3b95148215 100644 --- a/docs/compatibility.md +++ b/docs/compatibility.md @@ -18,20 +18,13 @@ Below are the [semver](http://semver.org/) ranges representing which versions of | MongoDB Server | Mongoose ...
3
1
0
[{"id": "G0", "claim": "package.json contains unresolved Git conflict markers that should be removed and the dependencies reconciled correctly.", "category": "correctness", "verdict": "uncertain", "priority": "P3", "scope": "pre_existing"}, {"id": "G1", "claim": "The pipe character inside a code span in the docs/compat...
null
Automattic__mongoose__15567
Automattic/mongoose
15,567
defect
3fcf91cd738216a3c278dd949432fdb5604b2001
5f538e03764bb17e65e4dbbe01c679fa25f3a489
fix(query): propagate read preference to populate if `read()` called after `populate()`
Fix #15553 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/query.js b/lib/query.js index ad539e3518e..02a9711c7b7 100644 --- a/lib/query.js +++ b/lib/query.js @@ -2133,6 +2133,15 @@ Query.prototype._optionsForExec = function(model) { } } + if (this._mongooseOptions.populate && options.readPreference) { + for (const pop of Object.values(this._mong...
1
1
1
[{"id": "G0", "claim": "The new propagation in _optionsForExec() unconditionally overwrites any existing readPreference in populate options, which could override user-specified read preferences for individual populate queries; it should check whether pop.options.readPreference is already set before overwriting.", "cate...
null
Automattic__mongoose__15568
Automattic/mongoose
15,568
defect
3fcf91cd738216a3c278dd949432fdb5604b2001
a7f912764858a46d44da5117f4d0b16713113945
fix(model): allow setting `statics` option on discriminator schema
Fix #15556 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/helpers/model/discriminator.js b/lib/helpers/model/discriminator.js index 62fedf409d7..7e9242c07b1 100644 --- a/lib/helpers/model/discriminator.js +++ b/lib/helpers/model/discriminator.js @@ -14,7 +14,8 @@ const CUSTOMIZABLE_DISCRIMINATOR_OPTIONS = { _id: true, id: true, virtuals: true, - met...
1
1
1
[{"id": "G0", "claim": "The PR should include a test that actually exercises having a static on a discriminator model, rather than only updating the error-message string.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
Automattic__mongoose__15571
Automattic/mongoose
15,571
defect
3fcf91cd738216a3c278dd949432fdb5604b2001
59858bb577b6ccaf5825954ca1b0e3f7ae340fae
fix: trim long strings in minLength and maxLength error messages and display the string length
Fix #15550 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case i...
diff --git a/lib/error/messages.js b/lib/error/messages.js index a2db50a6fce..94a239d6b13 100644 --- a/lib/error/messages.js +++ b/lib/error/messages.js @@ -43,5 +43,5 @@ msg.Date.max = 'Path `{PATH}` ({VALUE}) is after maximum allowed value ({MAX}).' msg.String = {}; msg.String.enum = '`{VALUE}` is not a valid enum ...
2
1
1
[{"id": "G0", "claim": "The magic number 30 hard-coded in both doValidate and doValidateSync in lib/schemaType.js should be extracted to a named shared constant to improve maintainability, consistency and configurability.", "category": "maintainability", "verdict": "uncertain", "priority": "P2", "scope": "introduced"},...
null
Automattic__mongoose__15574
Automattic/mongoose
15,574
defect
d333d8eda0f61ef93120419a51b73968456adb32
bde97c1904c72d5b75d76593d0f5d80423629ba5
feat(schema): support for union types
Fix #10894. There's still work to do on this PR (TypeScript types, options testing, thinking about how to handle getters/setters on unions) but I wanted to get this out there for review. <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two ...
diff --git a/lib/options/schemaUnionOptions.js b/lib/options/schemaUnionOptions.js new file mode 100644 index 00000000000..165683fc33c --- /dev/null +++ b/lib/options/schemaUnionOptions.js @@ -0,0 +1,32 @@ +'use strict'; + +const SchemaTypeOptions = require('./schemaTypeOptions'); + +/** + * The options defined on a Un...
4
3
1
[{"id": "G0", "claim": "The JSDoc for `of` in SchemaUnionOptions was copied from the Map option and describes casting 'this map's values' with @type {Function|string}; it should be rewritten to describe the Union type's `of` semantics and its allowed types.", "category": "documentation", "verdict": "supported", "priori...
null
Automattic__mongoose__15580
Automattic/mongoose
15,580
defect
adc1799c8f0b5c87791e9c12526db5e1a9418812
e288f4456f226901240880544c9d4b33558e5029
Bugfix: `Model.validate()` hangs when all paths fail casting
### Problem `Model.validate()` hangs indefinitely when all specified validation paths fail type casting. The Promise never resolves or rejects, causing timeouts. ### Root cause 1. `castObject()` throws a ValidationError and removes failed paths from the validation queue 2. The main validation loop becomes empty (...
diff --git a/lib/model.js b/lib/model.js index b71a21f1197..e581393eb6d 100644 --- a/lib/model.js +++ b/lib/model.js @@ -4304,6 +4304,10 @@ Model.validate = async function validate(obj, pathsOrOptions, context) { let remaining = paths.size; return new Promise((resolve, reject) => { + if (remaining === 0) { +...
1
1
1
[{"id": "G0", "claim": "The test's assertion `err.errors['invalidPath1', 'invalidPath2']` evaluates via the comma operator to `err.errors['invalidPath2']`, so it should be two separate assertions checking that both paths' errors have name 'CastError'.", "category": "testing", "verdict": "supported", "priority": "P1", "...
null
Automattic__mongoose__15590
Automattic/mongoose
15,590
defect
53d70cb9a194b5d338eb18e3aef110d5eb7b027f
f2a659c4e26537522388bc2e876931d212d86758
docs(schema): expose "DocumentArrayElement"
**Summary** While doing the typegoose migration for #15587, i noticed that the type `SchemaDocumentArrayElement` was not publicly exposed, but typegoose tested against a path being something specific. Though i dont know if this type is only meant as a private type. (though it is marked `@api public`) [typegoose ...
diff --git a/lib/schema/array.js b/lib/schema/array.js index 0479b0bcccc..25d7917bc4c 100644 --- a/lib/schema/array.js +++ b/lib/schema/array.js @@ -155,7 +155,7 @@ SchemaArray.defaultOptions = {}; * #### Example: * * // Make all Array instances have `required` of true by default. - * mongoose.Schema.Arra...
5
5
1
[{"id": "G0", "claim": "The set() JSDoc example added in lib/schema/documentArrayElement.js calls mongoose.Schema.Types.SchemaDocumentArrayElement, but the path should be mongoose.Schema.Types.DocumentArrayElement to match the exported name and schemaName.", "category": "documentation", "verdict": "supported", "priorit...
null
Automattic__mongoose__15656
Automattic/mongoose
15,656
defect
bf52aa036a73b82e671abf6c156a60b1e0f93791
aff67b83d8a3d018a86487ee085e98183cbb98aa
BREAKING CHANGE: remove skipId parameter to Document() and Model(), always use as options
Fix #8862 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. If you're making a change to documentation, do **not** modify a `.html` file directly. Instead, find the corresponding `.pug` file or test case in...
diff --git a/docs/migrating_to_9.md b/docs/migrating_to_9.md index 204cb56f220..cb242a76f54 100644 --- a/docs/migrating_to_9.md +++ b/docs/migrating_to_9.md @@ -295,12 +295,18 @@ console.log(schema.path('docArray').Constructor); // EmbeddedDocument constructo In Mongoose 8, there was also an internal `$embeddedSchem...
3
2
0
[{"id": "G0", "claim": "The error message 'Tried to use skipId' thrown when a boolean is passed is unclear and unhelpful, and should instead say that the skipId parameter has been removed and that { skipId: true } in the options parameter should be used.", "category": "documentation", "verdict": "supported", "priority"...
null
Automattic__mongoose__15735
Automattic/mongoose
15,735
defect
4786c93df203237c336514090ff7bc4ab43e68c3
f49c751b091f86170a02eecf11217623ec2d52bf
feat: add index and doc to insertMany validation errors
This PR addresses feature request #14351 and introduces an enhancement for the insertMany() method when used with `{ ordered: false }` It adds two new properties to validation errors: - `error.index`: the index of the failed document in the input array These additions align Mongoose’s error reporting more clos...
diff --git a/lib/model.js b/lib/model.js index 3929413e767..f27bb38060e 100644 --- a/lib/model.js +++ b/lib/model.js @@ -3042,6 +3042,9 @@ Model.$__insertMany = function(arr, options, callback) { const results = ordered ? null : new Array(arr.length); const toExecute = arr.map((doc, index) => callback => { +...
1
1
0
[{"id": "G0", "claim": "Including the full doc in the validation error is unnecessary since the index lets users look the document up in the original array, and attaching doc creates potential clones.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null