Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Intervals and timeouts are orphaned if editor crashes #17531

Open
lkszzajac opened this issue Nov 25, 2024 · 2 comments · May be fixed by #17686
Open

Intervals and timeouts are orphaned if editor crashes #17531

lkszzajac opened this issue Nov 25, 2024 · 2 comments · May be fixed by #17686
Assignees
Labels
domain:dx This issue reports a developer experience problem or possible improvement. support:2 An issue reported by a commercially licensed client. type:bug This issue reports a buggy (incorrect) behavior.

Comments

@lkszzajac
Copy link

📝 Provide detailed reproduction steps (if any)

  1. Set tokenUrl to a function call that throws an error:
cloudServices: {
		tokenUrl: async () => {
			const response = {status: 404}
		   
			if (response.status < 200 || response.status > 299) {
			throw new Error('Cannot download new token.');
			}
		   
			if (typeof response.data !== 'string') {
			throw new Error('Unable to parse token.');
			}
		   
			return response.data;
		   },

✔️ Expected result

  • after editor crashes, the getToken interval call should be cleared

❌ Actual result

  • getToken interval call is being executed indefinitely

📃 Other details

  • Browser: n/a
  • OS: n/a
  • First affected CKEditor version: n/a
  • Installed CKEditor plugins: …

If you'd like to see this fixed sooner, add a 👍 reaction to this post.

@lkszzajac lkszzajac added domain:dx This issue reports a developer experience problem or possible improvement. type:bug This issue reports a buggy (incorrect) behavior. labels Nov 25, 2024
@f1ames
Copy link
Contributor

f1ames commented Nov 25, 2024

@lkszzajac could it be related or the same as #17462? 🤔

@martynawierzbicka martynawierzbicka added the support:2 An issue reported by a commercially licensed client. label Nov 26, 2024
@Mati365 Mati365 self-assigned this Dec 23, 2024
@Mati365
Copy link
Member

Mati365 commented Dec 23, 2024

@f1ames Apparently, it's. I added the detection for failing of the token initialization process in the cloud services plugin. Take a look at proposed solution: #17686.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
domain:dx This issue reports a developer experience problem or possible improvement. support:2 An issue reported by a commercially licensed client. type:bug This issue reports a buggy (incorrect) behavior.
Projects
None yet
4 participants