Skip to content

Commit 13553c5

Browse files
remove excessive prints, made a note to add back useful ones in the log.
1 parent 0d1a0c5 commit 13553c5

3 files changed

Lines changed: 3 additions & 12 deletions

File tree

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "oshconnect"
3-
version = "0.5.1a11"
3+
version = "0.5.1a13"
44
description = "Library for interfacing with OSH, helping guide visualization efforts, and providing a place to store configurations. Implements OGC CS API Part 3 (Pub/Sub) MQTT topic conventions including :data topics and resource event topics."
55
readme = "README.md"
66
authors = [

src/oshconnect/streamableresource.py

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -312,9 +312,7 @@ def discover_systems(self) -> list[System] | None:
312312
if result.ok:
313313
new_systems = []
314314
system_objs = result.json()['items']
315-
print(system_objs)
316315
for system_json in system_objs:
317-
print(system_json)
318316
system = SystemResource.model_validate(system_json, by_alias=True)
319317
sys_obj = System(label=system.properties['name'],
320318
name=to_camel(system.properties['name'].replace(" ", "_")),
@@ -793,7 +791,6 @@ def insert_data(self, data: dict):
793791
No Checks are performed to ensure the data is valid for the underlying resource.
794792
:param data: Data to be sent, typically bytes or str
795793
"""
796-
print(f"Inserting data into message writer queue: {data}")
797794
data_bytes = json.dumps(data).encode("utf-8") if isinstance(data, dict) else data
798795
self._msg_writer_queue.put_nowait(data_bytes)
799796

@@ -1349,7 +1346,6 @@ def insert_self(self):
13491346
self._resource_id = sys_id
13501347
if self._underlying_resource is not None:
13511348
self._underlying_resource.system_id = sys_id
1352-
print(f'Created system: {self._resource_id}')
13531349

13541350
def retrieve_resource(self):
13551351
"""GET ``/systems/{id}`` and refresh the underlying `SystemResource`.
@@ -1361,9 +1357,7 @@ def retrieve_resource(self):
13611357
res_id=self._resource_id)
13621358
if res.ok:
13631359
system_json = res.json()
1364-
print(system_json)
13651360
system_resource = SystemResource.model_validate(system_json)
1366-
print(f'System Resource: {system_resource}')
13671361
self._underlying_resource = system_resource
13681362
return None
13691363

@@ -1499,8 +1493,7 @@ def insert_observation_dict(self, obs_data: dict):
14991493
req_headers={'Content-Type': 'application/json'})
15001494
if res.ok:
15011495
obs_id = res.headers['Location'].split('/')[-1]
1502-
print(f'Inserted observation: {obs_id}')
1503-
return id
1496+
return obs_id
15041497
else:
15051498
raise Exception(f'Failed to insert observation: {res.text}')
15061499

@@ -1535,9 +1528,7 @@ def _emit_inbound_event(self, msg):
15351528
EventHandler().publish(evt)
15361529

15371530
def _queue_push(self, msg):
1538-
print(f'Pushing message to reader queue: {msg}')
15391531
self._msg_writer_queue.put_nowait(msg)
1540-
print(f'Queue size is now: {self._msg_writer_queue.qsize()}')
15411532

15421533
def _queue_pop(self):
15431534
return self._msg_reader_queue.get_nowait()

uv.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)