illegal access to package_private script include: caller not in rhino.global
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
6 hours ago
I cloned the client original widget (which is global) using scoped app "digital" so the new clone is scoped app.
I also updated the script to "global.SPCart" to make it callable.
when I test run it, the error above shows up.
I found out that the widget use a default script include that is "this app scope only" below
I can't change the default SI so I will have to clone the code (which is not recommended)
the second option I find is to make a Cross scope privilege but it doesnt work. Did I make it wrong? is there other way than clone the SI?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 hours ago
The cross-scope privilege record has the wrong Source Scope. Looking at your screenshot, the Source Scope is set to "CI Guided Setup", but it should be set to your scoped app "digital" — that's the app that's trying to call SPCart, so it needs to be the one granted the privilege.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 hours ago
the script include is already accessible only from Global so you can't make it call from outside even with cross scope
Also you can't change the Accessible all setting on that script include since it's OOTB
better create a new script include, same code in Global scope, make it accessible from All scopes and then call that
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 10x ServiceNow MVP || ✨ ServiceNow Community Leader
