Hi, If we create an action or relation with _ (und...
# permit-saas
y
Hi, If we create an action or relation with _ (underscore) using api or sdk it works ok and we have used this a lot. the issue is now we can't change anything in permitui that has underscore as it seems there is an enforcement in UI that doesn't allow underscore in names. any advice?
a
Hi @Yilmaz Alizadeh, I'm an AI assistant for Permit.io. I'll analyze available sources and get back to you shortly.
It sounds like you're experiencing a validation inconsistency between the Permit API/SDK and the UI, where underscores in action or relation names work via API but are blocked in the UI. The Configuration Plane manages resources, roles, and relationships (1) , and can be accessed through multiple methods including the UI, Infrastructure as Code, and Raw Policy as Code . Since the API allows underscores but the UI doesn't, you have a few options: 1. ​*Continue using the API/SDK*​ for managing these specific actions and relations with underscores 2. ​*Use GitOps workflows*​ or ​*Infrastructure as Code*​ (like the Permit Terraform provider) to manage these configurations 3. ​*Manage directly via Raw Policy as Code*​ in version control systems To help our engineers investigate this UI validation issue: 1. Which Workspace / Project / Env are you using? 2. What specific API/SDK calls are you performing (as SDK code or CURL) ? 3. Which PDP version are you running? 4. Can you share relevant logs from your PDP? This information will help us understand the validation discrepancy better and potentially address it in a future update.
To learn more, see the sources I considered: [[1] Modeling and Implementation Components](https://docs.permit.io/how-to/SDLC/modeling-implementation-components)
a
Hey @Yilmaz Alizadeh, I’m looking into your case and I see that you’re right. I’m checking with the team and will get back to you with an answer.
🙌 1
Hey @Yilmaz Alizadeh, I just opened a ticket for this issue. I saw that you’re right about actions not allowing underscores in the UI, but relations seemed to work properly for me. Could you show me where you saw the problem with relations?
Bumping this @Yilmaz Alizadeh
y
@Alon Boshi The video should highlight the issue. please let me know if you need more information.
a
Hey @Yilmaz Alizadeh, Can you please explain what is not working on your end, I don't fully understand where is the problem here
y
@Alon Boshi so when there is _ in relation name or action name or attribute name (which is created using api) I can't update the resource in PermitIO UI (Save Button is disabled). it seems there is a validation in UI that is not enforced in api for unserscore.
this validation is only being applied in your front-end it seems
I can modify the html and remove the disable attributes and I can save.
@Alon Boshi is there any update on this. we still can't save changes on resources using UI when there are relation with underscore in name.
a
Hey @Yilmaz Alizadeh, sorry for the delay in updating you. We've opened a ticket for this issue, and a fix will be released to production by the end of the day. Thanks for flagging it!
Just noting that the bug is caused by the actions. Until it’s fixed, you can remove the actions with the underscore. It’s not related to the relations.
Hey @Yilmaz Alizadeh The fix is live in production, let us know if anything comes up
y
@Alon Boshi thanks. the underscore seems to be working fine many thanks. however it seem also when there is a dash "-" in the name we still can't save using UI.
a
Sending you a DM