AllenNeuralDynamics / AllenNeuralDynamics/one-liner
Make `Client.version` and `Client.server_version` properties
- Dominant language
- Python
- Stars
- 3
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Description
Current code in client.py
```python
def version(self):
"""Return client version."""
return local_version
def server_version(self):
"""Return the server version."""
return self.rpc_client.call("__router_server", "version")[1]
```
Should be
```python
@property
def version(self):
"""Return client version."""
return local_version
@property
def server_version(self):
"""Return the server version."""
return self.rpc_client.call("__router_server", "version")[1]
```
Or potentially `@cached_property`
This allows for the more idiomatic user experience of `client.version` rather than `client.version()`
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.