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

FIX #1678: update isReadyLock state to fix deadlock on second render #1679

Merged
merged 5 commits into from
Jul 19, 2022

Conversation

IlyaSV
Copy link
Contributor

@IlyaSV IlyaSV commented Jul 12, 2022

calling "render()" twice fixes some render issues (see #1678 ).
This update fixes deadlock on calling second "render()".

update isReadyLock state to fix deadlock on second render
@IlyaSV IlyaSV changed the title FIX 1678: update isReadyLock state to fix deadlock on second render FIX #1678: update isReadyLock state to fix deadlock on second render Jul 12, 2022
@codecov-commenter
Copy link

codecov-commenter commented Jul 12, 2022

Codecov Report

Merging #1679 (661388a) into master (873eccb) will increase coverage by 0.04%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master    #1679      +/-   ##
==========================================
+ Coverage   78.60%   78.64%   +0.04%     
==========================================
  Files          74       74              
  Lines        3010     3011       +1     
  Branches      624      624              
==========================================
+ Hits         2366     2368       +2     
  Misses        590      590              
+ Partials       54       53       -1     
Flag Coverage Δ
base 27.03% <100.00%> (+25.87%) ⬆️
browser 0.00% <0.00%> (ø)
node 78.61% <100.00%> (+<0.01%) ⬆️
offscreen 0.00% <0.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
src/Screen.ts 72.02% <100.00%> (+0.66%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 873eccb...661388a. Read the comment docs.

Copy link
Collaborator

@dangreen dangreen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi. Thank you for your contribution. Could you please also add some tests for it?

src/Screen.ts Outdated Show resolved Hide resolved
@IlyaSV
Copy link
Contributor Author

IlyaSV commented Jul 13, 2022

Hi. Thank you for your contribution. Could you please also add some tests for it?

Hi, @dangreen . I'm new in this project, so could you please show me a file there such async test should be placed?

@dangreen
Copy link
Collaborator

@IlyaSV Please create file test/canvg.spec.ts

import { Canvg } from '../src'

describe('Canvg', () => {
  describe('render', () => {
    it('should render twice without deadlock', () => {
      // ...
    });
  })
})

IlyaSV and others added 2 commits July 14, 2022 13:35
Co-authored-by: Dan Onoshko <danon0404@gmail.com>
test/canvg.spec.ts Outdated Show resolved Hide resolved
Co-authored-by: Dan Onoshko <danon0404@gmail.com>
test/canvg.spec.ts Outdated Show resolved Hide resolved
@dangreen dangreen merged commit 4bbc37e into canvg:master Jul 19, 2022
@dangreen
Copy link
Collaborator

@IlyaSV Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants