Skip to content
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

Filter out non-standard channels from channelInfo API #2107

Merged
merged 20 commits into from
Dec 15, 2021
Merged

Filter out non-standard channels from channelInfo API #2107

merged 20 commits into from
Dec 15, 2021

Conversation

akumaigorodski
Copy link
Contributor

@akumaigorodski akumaigorodski commented Dec 14, 2021

This change makes it possible for a non-standard channel to reply with CommandFailure which in turn will be filtered out in channelsInfo method.

The reason is that currently hosted channels have to return something to make the whole API call succeed and whatever they return would break external tools which only expect standard channel formats.

akumaigorodski and others added 15 commits November 13, 2020 20:46
# Conflicts:
#	eclair-core/src/main/scala/fr/acinq/eclair/channel/Channel.scala
…e.scala

Co-authored-by: Pierre-Marie Padiou <pm47@users.noreply.github.com>
# Conflicts:
#	eclair-core/src/test/scala/fr/acinq/eclair/integration/ChannelIntegrationSpec.scala
#	eclair-core/src/test/scala/fr/acinq/eclair/integration/PaymentIntegrationSpec.scala
#	eclair-core/src/test/scala/fr/acinq/eclair/payment/PaymentInitiatorSpec.scala
#	eclair-core/src/test/scala/fr/acinq/eclair/payment/PaymentLifecycleSpec.scala
#	eclair-node/src/main/scala/fr/acinq/eclair/api/handlers/Invoice.scala
# Conflicts:
#	eclair-core/src/test/scala/fr/acinq/eclair/payment/PaymentInitiatorSpec.scala
#	eclair-core/src/test/scala/fr/acinq/eclair/payment/PaymentLifecycleSpec.scala
@codecov-commenter
Copy link

codecov-commenter commented Dec 15, 2021

Codecov Report

Merging #2107 (13dbb63) into master (498e9a7) will decrease coverage by 0.10%.
The diff coverage is 86.67%.

@@            Coverage Diff             @@
##           master    #2107      +/-   ##
==========================================
- Coverage   87.73%   87.63%   -0.11%     
==========================================
  Files         159      165       +6     
  Lines       12455    12758     +303     
  Branches      522      535      +13     
==========================================
+ Hits        10927    11180     +253     
- Misses       1528     1578      +50     
Impacted Files Coverage Δ
...n/scala/fr/acinq/eclair/balance/BalanceActor.scala 10.16% <0.00%> (-1.16%) ⬇️
.../acinq/eclair/blockchain/bitcoind/ZmqWatcher.scala 88.13% <ø> (+2.54%) ⬆️
...ir/blockchain/bitcoind/rpc/BitcoinCoreClient.scala 94.23% <ø> (ø)
...in/scala/fr/acinq/eclair/channel/ChannelData.scala 100.00% <ø> (ø)
.../main/scala/fr/acinq/eclair/db/DualDatabases.scala 0.00% <0.00%> (ø)
...a/fr/acinq/eclair/payment/relay/ChannelRelay.scala 98.00% <ø> (ø)
...la/fr/acinq/eclair/payment/relay/NodeRelayer.scala 100.00% <ø> (ø)
...scala/fr/acinq/eclair/payment/send/Autoprobe.scala 0.00% <0.00%> (ø)
...ire/internal/channel/version0/ChannelCodecs0.scala 96.77% <ø> (ø)
...q/eclair/wire/protocol/LightningMessageTypes.scala 96.77% <ø> (ø)
... and 77 more

Copy link
Member

@t-bast t-bast left a comment

Choose a reason for hiding this comment

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

This needs a test (and probably a squash/rebase with a clean commit message), otherwise LGTM.

@akumaigorodski
Copy link
Contributor Author

Sigh, looks like I've done something wrong again with squashing, maybe we can do without it?

@t-bast
Copy link
Member

t-bast commented Dec 15, 2021

Sigh, looks like I've done something wrong again with squashing, maybe we can do without it?

Sure, no worries.

It's really worth a bit of time to learn to master git, it's not that hard and really helps productivity, I can only highly recommend it!

Copy link
Member

@t-bast t-bast left a comment

Choose a reason for hiding this comment

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

A couple of nits

akumaigorodski and others added 2 commits December 15, 2021 16:51
Co-authored-by: Bastien Teinturier <31281497+t-bast@users.noreply.github.com>
@t-bast t-bast merged commit 7e7de53 into ACINQ:master Dec 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants