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

Drop web3.providers.tester.py (V5 beta) #1199

Merged
merged 2 commits into from
Jan 11, 2019
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ Read more in the [documentation on ReadTheDocs](http://web3py.readthedocs.io/).
import json
import web3

from web3 import Web3, HTTPProvider, TestRPCProvider
Copy link
Member

Choose a reason for hiding this comment

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

We should probably remove this entire section from the README in favor of just using RTD.

from web3 import Web3
from web3.providers.eth_tester import EthereumTesterProvider
from solc import compile_source
from web3.contract import ConciseContract

Expand Down Expand Up @@ -46,7 +47,7 @@ compiled_sol = compile_source(contract_source_code) # Compiled source code
contract_interface = compiled_sol['<stdin>:Greeter']

# web3.py instance
w3 = Web3(TestRPCProvider())
w3 = Web3(EthereumTesterProvider())

# Instantiate and deploy contract
contract = w3.eth.contract(abi=contract_interface['abi'], bytecode=contract_interface['bin'])
Expand Down
36 changes: 1 addition & 35 deletions docs/providers.rst
Original file line number Diff line number Diff line change
Expand Up @@ -294,9 +294,7 @@ EthereumTesterProvider
~~~~~~~~~~~~~~~~~~~~~~

.. warning:: Experimental: This provider is experimental. There are still significant gaps in
functionality. However, it is the default replacement for
:class:`web3.providers.tester.EthereumTesterProvider`
and is being actively developed and supported.
functionality. However it is being actively developed and supported.

.. py:class:: EthereumTesterProvider(eth_tester=None)

Expand All @@ -312,38 +310,6 @@ EthereumTesterProvider
>>> w3 = Web3(EthereumTesterProvider())



EthereumTesterProvider (legacy)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

.. warning:: Deprecated: This provider is deprecated in favor of
:class:`~web3.providers.eth_tester.EthereumTesterProvider` and the newly created eth-tester.

.. py:class:: web3.providers.tester.EthereumTesterProvider()

This provider can be used for testing. It uses an ephemeral blockchain
backed by the ``ethereum.tester`` module.

.. code-block:: python

>>> from web3 import Web3
>>> from web3.providers.tester import EthereumTesterProvider
>>> w3 = Web3(EthereumTesterProvider())

TestRPCProvider
~~~~~~~~~~~~~~~

.. warning:: Deprecated: This provider is deprecated in favor of
:class:`~web3.providers.eth_tester.EthereumTesterProvider` and the newly created eth-tester.

.. py:class:: TestRPCProvider()

This provider can be used for testing. It uses an ephemeral blockchain
backed by the ``ethereum.tester`` module. This provider will be slower
than the ``EthereumTesterProvider`` since it uses an HTTP server for RPC
interactions with.


AutoProvider
~~~~~~~~~~~~

Expand Down
3 changes: 0 additions & 3 deletions web3/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,6 @@
from web3.providers.eth_tester import ( # noqa: E402
EthereumTesterProvider,
)
from web3.providers.tester import ( # noqa: E402
TestRPCProvider,
)
from web3.providers.ipc import ( # noqa: E402
IPCProvider,
)
Expand Down
4 changes: 0 additions & 4 deletions web3/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,6 @@
from web3.providers.rpc import (
HTTPProvider,
)
from web3.providers.tester import (
TestRPCProvider,
)
from web3.providers.websocket import (
WebsocketProvider,
)
Expand Down Expand Up @@ -102,7 +99,6 @@ class Web3:
# Providers
HTTPProvider = HTTPProvider
IPCProvider = IPCProvider
TestRPCProvider = TestRPCProvider
EthereumTesterProvider = EthereumTesterProvider
WebsocketProvider = WebsocketProvider

Expand Down
163 changes: 0 additions & 163 deletions web3/providers/tester.py

This file was deleted.