From 4899cfa1604be292d35c17bd9244bd3ad6bfc3d6 Mon Sep 17 00:00:00 2001 From: Ben Richard <143630488+benrichard-amd@users.noreply.github.com> Date: Fri, 16 May 2025 15:45:16 -0400 Subject: [PATCH] Update illegal character check for profile name (#703) [ROCm/rocprofiler-compute commit: 41dd4aab907d043bd9895229c17343caa8f8d7a3] --- projects/rocprofiler-compute/src/rocprof_compute_base.py | 3 +++ .../src/rocprof_compute_profile/profiler_base.py | 6 ------ 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/projects/rocprofiler-compute/src/rocprof_compute_base.py b/projects/rocprofiler-compute/src/rocprof_compute_base.py index 9bc7afcc49..13e14fc30e 100644 --- a/projects/rocprofiler-compute/src/rocprof_compute_base.py +++ b/projects/rocprofiler-compute/src/rocprof_compute_base.py @@ -252,6 +252,9 @@ class RocProfCompute: elif self.__args.name is None: sys.exit("Either --list-name or --name is required") + if self.__args.name.find("/") != -1: + console_error("'/' not permitted in profile name") + # Deprecation warning for hardware blocks if [ name diff --git a/projects/rocprofiler-compute/src/rocprof_compute_profile/profiler_base.py b/projects/rocprofiler-compute/src/rocprof_compute_profile/profiler_base.py index e1a461d1ac..dd47a62497 100644 --- a/projects/rocprofiler-compute/src/rocprof_compute_profile/profiler_base.py +++ b/projects/rocprofiler-compute/src/rocprof_compute_profile/profiler_base.py @@ -308,12 +308,6 @@ class RocProfCompute_Base: "Profiling command required. Pass application executable after -- at the end of options.\n\t\ti.e. rocprof-compute profile -n vcopy -- ./vcopy -n 1048576 -b 256" ) - # verify name meets MongoDB length requirements and no illegal chars - if len(self.__args.name) > 35: - console_error("-n/--name exceeds 35 character limit. Try again.") - if self.__args.name.find(".") != -1 or self.__args.name.find("-") != -1: - console_error("'-' and '.' are not permitted in -n/--name") - gen_sysinfo( workload_name=self.__args.name, workload_dir=self.get_args().path,