Skip to content

Commit

Permalink
Direct setup patch.
Browse files Browse the repository at this point in the history
  • Loading branch information
jfjlaros committed Nov 13, 2021
1 parent f1532db commit 2a78a49
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
4 changes: 0 additions & 4 deletions docs/conf.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
from subprocess import call

call('pip install six sphinx-argparse ..', shell=True)

from simple_rpc import _get_metadata


Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = arduino-simple-rpc
version = 2.4.1
version = 2.4.2
description = Arduino simpleRPC API client library and CLI.
long_description = file: README.rst
author = Jeroen F.J. Laros
Expand Down
7 changes: 5 additions & 2 deletions simple_rpc/__init__.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
from pkg_resources import get_distribution
from pkg_resources import DistributionNotFound, get_distribution

from .extras import dict_to_object, object_to_dict
from .simple_rpc import Interface, SerialInterface, SocketInterface


def _get_metadata(name: str) -> str:
pkg = get_distribution('arduino_simple_rpc')
try:
pkg = get_distribution('arduino_simple_rpc')
except DistributionNotFound:
pkg = get_distribution('simple_rpc')

for line in pkg.get_metadata_lines(pkg.PKG_INFO):
if line.startswith('{}: '.format(name)):
Expand Down

0 comments on commit 2a78a49

Please sign in to comment.