Repository navigation
fix(vpn): re-enable dial idle timeout by default to prevent permanent connection stalls #3097
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
varunagarwal-pro
wants to merge
2
commits into
celzero:main
from
varunagarwal-pro:fix/dial-timeout-default-firestack-stall
+21
−2
Closed
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎯 Functional Correctness | 🟠 Major | ⚡ Quick win
🔎 Supported by static analysis
🏁 Script executed:
Repository: celzero/rethink-app
Length of output: 50375
🤖 get_repo_knowledge executed:
get_repo_knowledge celzero/rethink-app /tmp/coderabbit-repo-knowledge/celzero-rethink-app-9eab9aee/learningsLength of output: 824
🏁 Script executed:
Repository: celzero/rethink-app
Length of output: 50375
🏁 Script executed:
Repository: celzero/rethink-app
Length of output: 33426
🌐 Web query:
Krate 2.0.0 hu.autsoft.krate default withDefault source💡 Result:
Krate (hu.autsoft:krate:2.0.0) is a library designed as a SharedPreferences wrapper for Kotlin, utilizing property delegates for convenient data access [1][2][3]. Based on the available documentation for Krate 2.0.0, the "withDefault" functionality and the specific "source" parameter mentioned in your query are not part of the core hu.autsoft.krate library API [1][2]. The confusion likely arises from the similarly named, but separate, KStorage library (makeevrserg/klibs.kstorage) [4][5]. The KStorage library explicitly provides a.withDefault extension function that allows users to wrap a nullable Krate (or similar storage type) and provide a fallback value, effectively converting it into a non-null Krate [4][5]. In the context of the KStorage library,.withDefault is used as follows [4][5]: // Example using KStorage (not part of hu.autsoft:krate) val nullableKrate: MutableKrate<Int?> =... // A nullable krate val nonNullKrate: MutableKrate = nullableKrate.withDefault { 42 } If you are using the hu.autsoft:krate library (version 2.0.0), you typically define defaults by providing a default value directly to the delegate functions (e.g., intPref(key, defaultValue)) during the property initialization within your Krate class [3].
Citations:
🏁 Script executed:
Repository: celzero/rethink-app
Length of output: 31815
🏁 Script executed:
Repository: celzero/rethink-app
Length of output: 4218
🌐 Web query:
site:github.com/autsoft/krate "hu.autsoft.krate.default" "withDefault"💡 Result:
In the Krate library, developed by AutSoft, the withDefault function is used to provide a default value to a SharedPreferences property, effectively transforming a nullable property into a non-nullable one [1]. By chaining.withDefault(defaultValue) to the delegate function (e.g., stringPref, intPref), the property will return the specified default value if it has not been previously set in SharedPreferences [1]. Once a default value is defined, the property no longer supports nullability, and there is no mechanism to remove the value from SharedPreferences, other than explicitly setting it back to the default value [1]. An example of this usage is: var username: String by stringPref.withDefault("admin") [1].
Citations:
🏁 Script executed:
Repository: celzero/rethink-app
Length of output: 5663
Migrate the legacy
dial_timeout_secvalue.withDefault<Int>(10)returns10only when the key is absent. The previous declaration persisted a default of0, andHomeScreenActivity.updateNewVersion()has no migration for this key. Existing installations can therefore continue passing0toGoVpnAdapter.setDialStrategy(). Add a versioned migration that changes only the legacy default and preserves an explicit user-selected disabled timeout.🤖 Prompt for AI Agents