Skip to content

Commit

Permalink
Update pom.xml dependency versions
Browse files Browse the repository at this point in the history
  • Loading branch information
marcmonfort committed Nov 6, 2023
1 parent 14eb918 commit 38f91e1
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 12 deletions.
2 changes: 1 addition & 1 deletion addons/storage/dependency-reduced-pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.11</version>
<version>4.13.2</version>
<scope>test</scope>
<exclusions>
<exclusion>
Expand Down
10 changes: 5 additions & 5 deletions addons/storage/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.11</version>
<version>4.13.2</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>redis.clients</groupId>
<artifactId>jedis</artifactId>
<version>4.3.0</version>
<version>5.0.2</version>
</dependency>
<dependency>
<groupId>com.google.code.gson</groupId>
Expand All @@ -40,18 +40,18 @@
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-netty-shaded</artifactId>
<version>1.56.0</version>
<version>1.59.0</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-protobuf</artifactId>
<version>1.56.0</version>
<version>1.59.0</version>
</dependency>
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-stub</artifactId>
<version>1.56.0</version>
<version>1.59.0</version>
</dependency>
<dependency> <!-- necessary for Java 9+ -->
<groupId>org.apache.tomcat</groupId>
Expand Down
5 changes: 3 additions & 2 deletions src/dataclay/annotated.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
class PropertyTransformer:
"""Parent class for annotations that transform object attributes.
This class is not intended to be used by itself, but instead inherited and
implemented. Right now, this class is a trivial implementation, i.e.
passthrough of getter and setter.
Expand All @@ -23,10 +23,11 @@ def setter(self, value):

class LocalOnly:
"""Annotation to specify attributes that must no be persisted.
Example::
class ComplexAlgorithm(DataClayObject):
primes_cache: Annotated[list[int], LocalOnly]
"""

pass
2 changes: 1 addition & 1 deletion src/dataclay/contrib/mqtt.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class MQTTMixin:
"""MQTT mechanisms"""

@activemethod
def produce_mqtt_msg(self, data: dict[str, Any], topic: str="dataclay"):
def produce_mqtt_msg(self, data: dict[str, Any], topic: str = "dataclay"):
import os
from json import dumps

Expand Down
11 changes: 9 additions & 2 deletions src/dataclay/contrib/nvm.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,16 @@
import npp2nvm
except ImportError:
import warnings
warnings.warn("npp2nvm package is not installed. InNVM annotation will fail. Install npp2nvm package.")

warnings.warn(
"npp2nvm package is not installed. InNVM annotation will fail. Install npp2nvm package."
)
except KeyError:
import warnings
warnings.warn("npp2nvm had a configuration error. InNVM annotation will fail. Check npp2nvm documentation.")

warnings.warn(
"npp2nvm had a configuration error. InNVM annotation will fail. Check npp2nvm documentation."
)


class InNVM(PropertyTransformer):
Expand All @@ -38,5 +44,6 @@ class Experiment(DataClayObject):
>>> e.make_persistent()
>>> e.observations = np.array([1,2,3])
"""

def setter(self, value):
return npp2nvm.np_persist(value)
2 changes: 1 addition & 1 deletion src/storage/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

def get_client() -> Client:
"""Get the global (singleton) Client instance.
This can be run in the worker nodes (i.e., inside a task). Given the
regular initialization flow of the worker (i.e., after it calls initWorker)
a global Client instane is available and can be used.
Expand Down

0 comments on commit 38f91e1

Please sign in to comment.