Skip to content

Commit 54d4e92

Browse files
Changing default behavior to remove onshape tags--requiring users to have unique link names.
1 parent e79b6b2 commit 54d4e92

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

onshape_robotics_toolkit/utilities/helpers.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -278,7 +278,7 @@ def make_unique_name(name: str, existing_names: set[str]) -> str:
278278
return f"{name}-{count}"
279279

280280

281-
def get_sanitized_name(name: str, replace_with: str = "_", remove_onshape_tags: bool = False) -> str:
281+
def get_sanitized_name(name: str, replace_with: str = "_", remove_onshape_tags: bool = True) -> str:
282282
"""
283283
Sanitize a name by removing special characters, preserving only the specified
284284
replacement character, and replacing spaces with it. Ensures no consecutive
@@ -289,7 +289,7 @@ def get_sanitized_name(name: str, replace_with: str = "_", remove_onshape_tags:
289289
Args:
290290
name (str): Name to sanitize.
291291
replace_with (str): Character to replace spaces and other special characters with (default is '_').
292-
remove_onshape_tags (bool): If True, removes a trailing " <n>" tag where n is a number. Default is False.
292+
remove_onshape_tags (bool): If True, removes a trailing " <n>" tag where n is a number. Default is True.
293293
294294
Returns:
295295
str: Sanitized name.

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "onshape-robotics-toolkit"
3-
version = "0.1.8"
3+
version = "0.1.9"
44
description = "A python library to facilitate interaction with Onshape's REST API"
55
authors = ["Senthur Ayyappan <[email protected]>"]
66
repository = "https://github.com/neurobionics/onshape-robotics-toolkit"

0 commit comments

Comments
 (0)