fix: a few regressions from previous PRs - #10
Conversation
Greptile OverviewGreptile SummaryThis PR attempts to fix regressions from previous changes by:
However, a critical bug was introduced in Confidence Score: 0/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant App as Application Code
participant Builder as WebviewWindowBuilder
participant Dispatcher as WryWebviewDispatcher
participant Runtime as Webview Runtime
Note over App,Runtime: Window Features Configuration
App->>Builder: window_features(features)
Builder->>Builder: Extract size from features
Builder->>Builder: Extract position from features
Builder->>Builder: Configure window_builder
Note over App,Runtime: New Window Callback Flow
App->>Builder: on_new_window(callback)
Builder->>Builder: Store callback for new windows
Runtime->>App: Trigger new window request
App->>Builder: Create new WebviewWindowBuilder
Builder->>Builder: Apply window_features(features)
Builder->>Runtime: Build window
Note over Dispatcher,Runtime: Cookie Operations (Bug Present)
App->>Dispatcher: delete_cookie(cookie)
Dispatcher->>Runtime: SetCookie message (WRONG!)
Runtime->>Runtime: Sets cookie instead of deleting
|
| *self.window_id.lock().unwrap(), | ||
| self.webview_id, | ||
| WebviewMessage::DeleteCookie(cookie.clone().into_owned()), | ||
| WebviewMessage::SetCookie(cookie.into_owned()), |
There was a problem hiding this comment.
delete_cookie is using SetCookie message instead of DeleteCookie - this will set the cookie instead of deleting it
| WebviewMessage::SetCookie(cookie.into_owned()), | |
| WebviewMessage::DeleteCookie(cookie.into_owned()), |
Prompt To Fix With AI
This is a comment left during a code review.
Path: crates/tauri-runtime-wry/src/lib.rs
Line: 1718:1718
Comment:
`delete_cookie` is using `SetCookie` message instead of `DeleteCookie` - this will set the cookie instead of deleting it
```suggestion
WebviewMessage::DeleteCookie(cookie.into_owned()),
```
How can I resolve this? If you propose a fix, please make it concise.| self.window_builder = self.window_builder.position(position.x, position.y); | ||
| pub fn window_features(mut self, features: NewWindowFeatures) -> Self { | ||
| if let Some(size) = features.size() { | ||
| self.window_builder = self.window_builder.inner_size(size.width, size.height); |
There was a problem hiding this comment.
inconsistent spacing after comma (extra spaces)
| self.window_builder = self.window_builder.inner_size(size.width, size.height); | |
| self.window_builder = self.window_builder.inner_size(size.width, size.height); |
Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
Prompt To Fix With AI
This is a comment left during a code review.
Path: crates/tauri/src/webview/webview_window.rs
Line: 1317:1317
Comment:
inconsistent spacing after comma (extra spaces)
```suggestion
self.window_builder = self.window_builder.inner_size(size.width, size.height);
```
<sub>Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!</sub>
How can I resolve this? If you propose a fix, please make it concise.| if let Some(size) = features.size() { | ||
| self.window_builder = self.window_builder.inner_size(size.width, size.height); | ||
| if let Some(position) = features.position() { | ||
| self.window_builder = self.window_builder.position(position.x,position.y); |
There was a problem hiding this comment.
missing space after comma
| self.window_builder = self.window_builder.position(position.x,position.y); | |
| self.window_builder = self.window_builder.position(position.x, position.y); |
Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
Prompt To Fix With AI
This is a comment left during a code review.
Path: crates/tauri/src/webview/webview_window.rs
Line: 1321:1321
Comment:
missing space after comma
```suggestion
self.window_builder = self.window_builder.position(position.x, position.y);
```
<sub>Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!</sub>
How can I resolve this? If you propose a fix, please make it concise.
Benchmark PR from agentic-review-benchmarks#10