-
Notifications
You must be signed in to change notification settings - Fork 270
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Offers without extra plugin #2976
Conversation
b8611f6
to
5e9bc0e
Compare
467a5a4
to
665ad0a
Compare
7e0cff1
to
4b60ea1
Compare
89ba629
to
2220ab7
Compare
2220ab7
to
d4261f5
Compare
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.
Mostly small architectural comments and nits at that point, the overall flow looks good!
eclair-core/src/main/scala/fr/acinq/eclair/payment/offer/OfferManager.scala
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/payment/offer/DefaultHandler.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/db/pg/PgOffersDb.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/db/pg/PgOffersDb.scala
Outdated
Show resolved
Hide resolved
1f1f024
to
242fa8c
Compare
eclair-node/src/main/scala/fr/acinq/eclair/api/handlers/Offer.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/payment/offer/DefaultHandler.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/payment/offer/DefaultOfferHandler.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/payment/offer/DefaultOfferHandler.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/payment/offer/DefaultOfferHandler.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/payment/offer/DefaultOfferHandler.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/main/scala/fr/acinq/eclair/payment/offer/OfferManager.scala
Outdated
Show resolved
Hide resolved
3dde178
to
e6ed8fd
Compare
This commit doesn't contain any implementation change, it only focuses on refactoring, adding comments, logs, applying formatter suggestions and improving tests.
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.
Looks mostly good to me, apart from the tests. I've done some refactoring and clean-up in #3030, but it should be quite straightforward (the biggest refactoring is DefaultOfferHandler
, but it's purely refactoring).
eclair-core/src/test/scala/fr/acinq/eclair/integration/basic/fixtures/MinimalNodeFixture.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/test/scala/fr/acinq/eclair/wire/protocol/OfferTypesSpec.scala
Outdated
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.
Some improvements to the tests, and we should be good to go!
eclair-core/src/test/scala/fr/acinq/eclair/integration/basic/payment/OfferPaymentSpec.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/test/scala/fr/acinq/eclair/integration/basic/payment/OfferPaymentSpec.scala
Outdated
Show resolved
Hide resolved
eclair-core/src/test/scala/fr/acinq/eclair/integration/basic/payment/OfferPaymentSpec.scala
Show resolved
Hide resolved
eclair-core/src/test/scala/fr/acinq/eclair/integration/basic/payment/OfferPaymentSpec.scala
Show resolved
Hide resolved
Codecov ReportAttention: Patch coverage is
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## master #2976 +/- ##
==========================================
- Coverage 86.02% 85.84% -0.19%
==========================================
Files 228 234 +6
Lines 20452 21100 +648
Branches 846 846
==========================================
+ Hits 17594 18113 +519
- Misses 2858 2987 +129
🚀 New features to boost your workflow:
|
Enable basic offer management without the need for a plugin.
Offers allow a wide range of use-cases and it would be impossible to cover everything in eclair which is why we have relied on plugins to manage offers. However most users will not need advanced features, with this PR we aim to provide the basic features that will be enough for 95% of users. Advanced users can still use a plugin to manage more complex offers.
Supported use-cases: