Page MenuHomePhabricator

Stop using external Javascript hosting
Closed, ResolvedPublic


We get some Javascript libraries via CDN. We should instead import them directly to the project and stop relying on external hosting.

Related Objects


Event Timeline

Samwalton9 created this task.
Shubh1815 added a subscriber: Shubh1815.

I will raise a PR on this soon.

Samwalton9 moved this task from Ready to Review on the The-Wikipedia-Library (Kanban) board.

Thanks! One of our engineers will review this PR soon :)

Samwalton9 moved this task from Done to Review on the The-Wikipedia-Library (Kanban) board.

Sorry, not sure why I closed this as resolved.

Do I still need to do anything in this PR?

Not for now - one of our engineers will review this soon.

Hey @Samwalton9, I am getting this error when I run tests, and I am not able to figure out why, as I haven't changed any code after I made the PR and before creating the PR I had ran the tests and it didn't gave any error at that time.

django.db.transaction.TransactionManagementError: An error occurred in the current transaction. You can't execute queries until the end of the 'atomic' block.

Screenshot from 2021-02-24 20-33-19.png (768×1 px, 602 KB)

Can you try rebasing your PR and running the tests again?

Thanks @Scardenasmolinar, its working now. Also, can you explain how rebasing the branch fixed it?

@Shubh1815 You branch was probably out of date with the master branch. By rebasing, you get your branch up to date, which can fix errors you might have been having.

jsn.sherman added a subscriber: jsn.sherman.

Merged, thanks!
@Samwalton9 a previous contributor had moved our javascript hosting to the tools static proxy, which resolved the underlying privacy concern behind the security team's recommendation to avoid external asset hosting. My guess is that this is why you closed this out. Moving them into the platform is a cleaner approach, IMO, so I consider this an improvement.