Skip to content

Conversation

promag
Copy link
Contributor

@promag promag commented Apr 13, 2020

No description provided.

@promag
Copy link
Contributor Author

promag commented Apr 13, 2020

Currently based on #18608.

@promag promag force-pushed the 2020-04-review-18608 branch from 5730554 to 8aa9b53 Compare April 13, 2020 14:04
Copy link
Contributor

@ryanofsky ryanofsky left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code review ACK 8aa9b53

@@ -17,18 +16,18 @@

#include <utility>

RecentRequestsTableModel::RecentRequestsTableModel(WalletModel *parent) :
QAbstractTableModel(parent), walletModel(parent)
RecentRequestsTableModel::RecentRequestsTableModel(interfaces::Wallet& wallet, OptionsModel* options_model, QObject* parent) :
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In commit "gui: Drop RecentRequestsTableModel dependency to WalletModel" (8aa9b53)

Would be nice to make options_model and m_options_model references instead of pointers if they are not allowed to be null

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, I think its unrelated to this PR though. For instance, the check in L126 could be removed. Lots of other members could be references including cases like WalletView::walletModel where there's a setter.

@DrahtBot
Copy link
Contributor

DrahtBot commented Apr 13, 2020

The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

Conflicts

Reviewers, this pull request conflicts with the following ones:

If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

Copy link
Contributor

@ryanofsky ryanofsky left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code review ACK aa2b55a. No changes since last review, just rebased base PR

Copy link
Contributor

@ryanofsky ryanofsky left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code review ACK c5ebb4d. Only change since last review is rebasing to fix bilingual_str conflict

ryanofsky and others added 2 commits May 27, 2020 07:16
This is cleanup that doesn't change external behavior.

- Removes awkward `StringMap` intermediate representation
- Deals with receive request "rr" keys in walletdb.cpp instead of all over qt, wallet, and interfaces code
- Deals with destination "used" keys in walletdb.cpp instead of all over wallet code
- Adds test coverage
- Reduces code (+85/-138 lines)
- Reduces memory usage

This PR doesn't change externally observable behavior. Internally, only change in behavior is that EraseDestData deletes directly from database because the `StringMap` is gone. This is more direct and efficient because it uses a single btree lookup and scan instead of multiple lookups

Motivation for this cleanup is making changes like bitcoin#18550, bitcoin#18192, bitcoin#13756 easier to reason about and less likely to result in unintended behavior and bugs
@DrahtBot
Copy link
Contributor

🐙 This pull request conflicts with the target branch and needs rebase.

@promag promag marked this pull request as draft June 17, 2020 10:05
@fanquake
Copy link
Member

fanquake commented Jul 9, 2020

This is based on #18608 (which itself has 1, I think, refuted Concept NACK & needs a rebase), is purely a qt circular dependency refactor and also needs a rebase. I'm going to suggest reopening this in https://github.com/bitcoin-core/gui.

@fanquake fanquake closed this Jul 9, 2020
@ryanofsky
Copy link
Contributor

#18608 is up to date (and I think was only conflicted for a few hours)

@bitcoin bitcoin locked as resolved and limited conversation to collaborators Feb 15, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants