-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Back navigation to previous tab #897
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
Back navigation to previous tab #897
Conversation
…navigate to that tab
… been opened from another tab
Cleanup a isDefaultTab as it was never used in some parts of the code.
…'s more explicit about what's happening.
| val MIGRATION_23_TO_24: Migration = object : Migration(23, 24) { | ||
| override fun migrate(database: SupportSQLiteDatabase) { | ||
| database.execSQL("ALTER TABLE `tabs` ADD COLUMN `sourceTabId` TEXT") | ||
| //https://stackoverflow.com/a/57797179/980345 |
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.
@CDRussell When testing migrations I detected an issue trying to ALTER a table to introduce a FOREIGN key. It seems it's not supported and the workaround is to migrate -> drop -> create a new table.
I have my worries (based on nothing in concrete, just a feeling), don't know if this can be an issue for users with many open tabs...
app/src/androidTest/java/com/duckduckgo/app/browser/BrowserTabViewModelTest.kt
Show resolved
Hide resolved
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.
Crashes on upgrading DB:
java.lang.IllegalStateException: Room cannot verify the data integrity. Looks like you've changed schema but forgot to update the version number. You can simply fix this by increasing the version number.
Otherwise, excellent stuff! Get that upgrade path sorted and we should be good to go!
app/src/main/java/com/duckduckgo/app/tabs/model/TabDataRepository.kt
Outdated
Show resolved
Hide resolved
|
@CDRussell sorry for not pointing out how to test the database migration, I've added the info in the description (also in this comment) The current production release has database version Test database migration:
|
I can do that. Though going forward i'd like to have nightly builds from |
CDRussell
left a comment
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.
I'm soooo happy to see this finally improved. great stuff!
Task/Issue URL: https://app.asana.com/0/414730916066338/1187653972293689/f
Tech Design URL:
CC:
Description:
Tries to fix the following issue:
Current behavior:
Expected behavior:
Related open issues:
#815
#696
Steps to test this PR:
Test: Open link on a new tab
Test: Open link on a new tab (source tab deleted)
Test: Open link on a background tab
Test: Open link on a background tab (source tab deleted)
Test: Open link in new tab (target=_blank)
Test: Open link in new tab (target=_blank / source tab deleted)
Steps to test previous logic is preserved:
Test: Open a New Empty tab
Test: External links
Test: Search widget
Test: Shortcut
Test database migration:
mainbranchInternal references:
Software Engineering Expectations
Technical Design Template