Examples: query, "exact match", wildcard*, wild?ard, wild*rd
Fuzzy search: cake~ (finds cakes, bake)
Term boost: "red velvet"^4, chocolate^2
Field grouping: tags:(+work -"fun-stuff")
Escape special characters +-&|!(){}[]^"~*?:\ - e.g. \+ \* \!
Range search: properties.timestamp:[1587729413488 TO *] (inclusive), properties.title:{A TO Z}(excluding A and Z)
Combinations: chocolate AND vanilla, chocolate OR vanilla, (chocolate OR vanilla) NOT "vanilla pudding"
Field search: properties.title:"The Title" AND text
 
Answered
Q2 Console javascript files getting blocked

Hello,

We are developing a console extension, and realized that we are not able to load any of our js files into our jinja templates in development. The network tab reads that the script request failed, and the console reads:

"violates the following Content Security Policy directive: "script-src 'self' https://cdn1-dev.onlineaccess1.com https://cdn1-stage.onlineaccess1.com https://cdn1.onlineaccess1.com https://sdk-cdn.onlineaccess1.com https://sdk-cdn-stg.onlineaccess1.com https://sdk-stg.onlineaccess1.com https://local-dev-api.q2developer.com 'unsafe-inline' 'unsafe-eval'". Note that 'script-src-elem' was not explicitly set, so 'script-src' is used as a fallback. The action has been blocked."

Our workaround has been to just include our javascript in script tags on the jinja template, although this is not ideal. Is this a known behavior for developing in console?

I also want to mention that this only happens in development mode. The error messages disappeared and the index.js file loaded just fine in PTE.

Votes Newest

Answers


Where are you developing from? I would expect local-dev-api.q2developer.com in that list would provide your host. Maybe you're on the shared dev box?

Posted 8 months ago
Brian Mego
227 × 1 Administrator
0

Yes, I am in the shared dev box

— Emanuel Bernard   8 months ago
0

Ah, I bet we didn't take shared dev into account with this. We can have a fix for this next week.

— Brian Mego   8 months ago
0

I'm sorry, I have not gotten to this. The box I need access to has had my access rights removed. I'm working on getting that back.

— Brian Mego   8 months ago
0

I have what I need now to fix this, but I'm having trouble reproducing. You still having this issue?

— Brian Mego   7 months ago
0

Good Afternoon Brian, I was able to replicate Emanuels experience with the csp headers today. Please let me know if I can assist, happy to demo if that would help.

— Tyler Maus   6 months ago
Show more results postcomments
149 Views
1 Answer
8 months ago
8 months ago