From 5305dbea0c46c375e4d14fe0fff4ddc2d1d07a21 Mon Sep 17 00:00:00 2001 From: Chris Guida Date: Fri, 26 Jan 2024 14:38:16 -0600 Subject: [PATCH] Remove all references to DEVELOPER env var --- .github/workflows/main.yml | 5 +---- drain/test_drain.py | 6 ------ feeadjuster/test_feeadjuster.py | 6 +----- jitrebalance/test_jitrebalance.py | 5 +---- noise/test_chat.py | 3 +-- probe/test_probe.py | 3 --- summary/test_summary.py | 3 +-- 7 files changed, 5 insertions(+), 26 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index a873b72..880a471 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -12,14 +12,13 @@ on: jobs: build-and-test: - name: Test PY=${{ matrix.python-version }}, DEV=${{ matrix.developer }}, EXP=${{ matrix.experimental }}, DEP=${{ matrix.deprecated }} + name: Test PY=${{ matrix.python-version }}, EXP=${{ matrix.experimental }}, DEP=${{ matrix.deprecated }} runs-on: ubuntu-latest timeout-minutes: 60 strategy: fail-fast: false matrix: python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"] - developer: [0,1] experimental: [1] deprecated: [0] @@ -46,7 +45,6 @@ jobs: - name: Compile & install c-lightning@master run: | export EXPERIMENTAL_FEATURES=${{ matrix.experimental }} - export DEVELOPER=${{ matrix.developer }} export COMPAT=${{ matrix.deprecated }} export VALGRIND=0 sudo apt-get install -y \ @@ -89,7 +87,6 @@ jobs: - name: Test with pytest run: | export EXPERIMENTAL_FEATURES=${{ matrix.experimental }} - export DEVELOPER=${{ matrix.developer }} export COMPAT=${{ matrix.deprecated }} export SLOW_MACHINE=1 export TEST_DEBUG=1 diff --git a/drain/test_drain.py b/drain/test_drain.py index 2366100..e473126 100644 --- a/drain/test_drain.py +++ b/drain/test_drain.py @@ -1,5 +1,4 @@ from pyln.testing.fixtures import * # noqa: F401,F403 -from pyln.testing.utils import DEVELOPER from pyln.client import RpcError from .utils import get_ours, get_theirs, wait_ours, wait_for_all_htlcs import os @@ -24,7 +23,6 @@ def test_plugin_starts(node_factory): l1.start() -@unittest.skipIf(not DEVELOPER, "slow gossip, needs DEVELOPER=1") def test_drain_and_refill(node_factory, bitcoind): # Scenario: first drain then refill # @@ -84,7 +82,6 @@ def test_drain_and_refill(node_factory, bitcoind): assert(get_theirs(l1, scid12) < theirs_before * 0.05) -@unittest.skipIf(not DEVELOPER, "slow gossip, needs DEVELOPER=1") def test_fill_and_drain(node_factory, bitcoind): # Scenario: first fill of an empty channel and drain afterwards. # @@ -133,7 +130,6 @@ def test_fill_and_drain(node_factory, bitcoind): assert(get_theirs(l1, scid12) < theirs_before * 0.05) # account some reserves -@unittest.skipIf(not DEVELOPER, "slow gossip, needs DEVELOPER=1") def test_setbalance(node_factory, bitcoind): # SETUP: a basic circular setup to run setbalance tests # @@ -194,7 +190,6 @@ def balance(node, node_a, scid_a, node_b, scid_b, node_c): wait_for_all_htlcs([node, node_a, node_b]) -@unittest.skipIf(not DEVELOPER, "slow gossip, needs DEVELOPER=1") def test_drain_chunks(node_factory, bitcoind): # SETUP: a small mesh that enables testing chunks # @@ -277,7 +272,6 @@ def test_drain_chunks(node_factory, bitcoind): assert(get_theirs(l1, scid41) > amount * 0.9) -@unittest.skipIf(not DEVELOPER, "slow gossip, needs DEVELOPER=1") def test_fill_chunks(node_factory, bitcoind): # SETUP: a small mesh that enables testing chunks # diff --git a/feeadjuster/test_feeadjuster.py b/feeadjuster/test_feeadjuster.py index a2b8346..9efa77c 100644 --- a/feeadjuster/test_feeadjuster.py +++ b/feeadjuster/test_feeadjuster.py @@ -4,7 +4,7 @@ import string import unittest from pyln.testing.fixtures import * # noqa: F401,F403 -from pyln.testing.utils import DEVELOPER, wait_for +from pyln.testing.utils import wait_for plugin_path = os.path.join(os.path.dirname(__file__), "feeadjuster.py") @@ -70,7 +70,6 @@ def sync_gossip(nodes, scids): wait_for(lambda: node.rpc.listchannels(scid) == n.rpc.listchannels(scid)) -@unittest.skipIf(not DEVELOPER, "Too slow without fast gossip") def test_feeadjuster_adjusts(node_factory): """ A rather simple network: @@ -140,7 +139,6 @@ def test_feeadjuster_adjusts(node_factory): f'Adjusted fees of {scid_B} with a ratio of 0.2']) -@unittest.skipIf(not DEVELOPER, "Too slow without fast gossip") def test_feeadjuster_imbalance(node_factory): """ A rather simple network: @@ -217,7 +215,6 @@ def test_feeadjuster_imbalance(node_factory): wait_for_fees(l2, scids, default_fees[0]) -@unittest.skipIf(not DEVELOPER, "Too slow without fast gossip") def test_feeadjuster_big_enough_liquidity(node_factory): """ A rather simple network: @@ -292,7 +289,6 @@ def test_feeadjuster_big_enough_liquidity(node_factory): wait_for_not_fees(l2, scids, default_fees[0]) -@unittest.skipIf(not DEVELOPER, "Too slow without fast gossip") def test_feeadjuster_median(node_factory): """ A rather simple network: diff --git a/jitrebalance/test_jitrebalance.py b/jitrebalance/test_jitrebalance.py index f071c99..0be989e 100644 --- a/jitrebalance/test_jitrebalance.py +++ b/jitrebalance/test_jitrebalance.py @@ -1,6 +1,6 @@ from pyln.client import RpcError from pyln.testing.fixtures import * # noqa: F401, F403 -from pyln.testing.utils import wait_for, DEVELOPER +from pyln.testing.utils import wait_for import os import time import pytest @@ -13,7 +13,6 @@ hold_plugin = os.path.join(currdir, 'tests/hold_htlcs.py') reject_plugin = os.path.join(currdir, 'tests/refuse_htlcs.py') -@unittest.skipIf(not DEVELOPER, "gossip is too slow if we're not in developer mode") def test_simple_rebalance(node_factory): """Simple rebalance that routes along a cycle to enable the original payment @@ -82,7 +81,6 @@ def test_simple_rebalance(node_factory): assert l2.daemon.is_in_log('Succesfully re-filled outgoing capacity') -@unittest.skipIf(not DEVELOPER, "gossip is too slow if we're not in developer mode") def test_rebalance_failure(node_factory): """Same setup as the first test : @@ -158,7 +156,6 @@ def test_rebalance_failure(node_factory): assert l2.daemon.is_in_log('Timed out while trying to rebalance') -@unittest.skipIf(not DEVELOPER, "gossip is too slow if we're not in developer mode") def test_issue_88(node_factory): """Reproduce issue #88: crash due to unconfirmed channel. diff --git a/noise/test_chat.py b/noise/test_chat.py index ecf4b93..26b8d21 100644 --- a/noise/test_chat.py +++ b/noise/test_chat.py @@ -3,7 +3,7 @@ from flaky import flaky from pprint import pprint from pyln.client import RpcError from pyln.testing.fixtures import * # noqa: F401,F403 -from pyln.testing.utils import DEVELOPER, wait_for +from pyln.testing.utils import wait_for import hashlib import os import pytest @@ -33,7 +33,6 @@ def test_sendmsg_success(node_factory, executor): @flaky # since we cannot force a payment to take a specific route -@unittest.skipIf(not DEVELOPER, "Fails often") @unittest.skipIf(True, "Just not stable") def test_sendmsg_retry(node_factory, executor): """Fail a sendmsg using a cheap route, and check that it retries. diff --git a/probe/test_probe.py b/probe/test_probe.py index ee54d91..4a6580d 100644 --- a/probe/test_probe.py +++ b/probe/test_probe.py @@ -1,7 +1,6 @@ import unittest import os from pyln.testing.fixtures import * # noqa: F401,F403 -from pyln.testing.utils import DEVELOPER plugin_path = os.path.join(os.path.dirname(__file__), "probe.py") @@ -18,7 +17,6 @@ def test_probe_starts(node_factory): l1.start() -@unittest.skipIf(not DEVELOPER, "Gossip is slow") def test_probe(node_factory): l1, l2, l3, l4 = node_factory.line_graph( 4, @@ -36,7 +34,6 @@ def test_probe(node_factory): assert(res['failcode'] == 16399) -@unittest.skipIf(not DEVELOPER, "Gossip is slow") def test_route_unreachable(node_factory): l1, l2, l3, l4 = node_factory.line_graph( 4, diff --git a/summary/test_summary.py b/summary/test_summary.py index 364cfed..e4f8e39 100644 --- a/summary/test_summary.py +++ b/summary/test_summary.py @@ -5,7 +5,7 @@ import os from pyln.client import Plugin from pyln.testing.fixtures import * # noqa: F401,F403 -from pyln.testing.utils import DEVELOPER, wait_for +from pyln.testing.utils import wait_for from .summary_avail import trace_availability @@ -264,7 +264,6 @@ def test_summary_opts(directory): assert(o in help_out) -@unittest.skipIf(not DEVELOPER, "We need fast gossip for line_graph") def test_summary_exclude(node_factory): l1, l2 = node_factory.line_graph(2, opts=pluginopt)