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

Fixed aliasing issue with relative HPGL export. #335

Merged
merged 2 commits into from
Nov 12, 2021
Merged

Conversation

abey79
Copy link
Owner

@abey79 abey79 commented Nov 12, 2021

Description

Lack of proper rounding could yield aliasing issues with relative export.

To reproduce:

vpype -v begin grid -o 0 0.11mm 1 1200 line 0 0 0 0.11mm end linemerge translate 0.1cm 0 line 0 0 0 13.2cm linemerge layout a4 write -d hp7475a test.hpgl

Both lines should be the same length but the first one is shorter when exported in HPGL without --absolute.

Checklist

  • feature/fix implemented
  • code formatting ok (black and isort)
  • mypy vpype vpype_cli tests returns no error
  • tests added/updated and pytest succeeds
  • documentation added/updated
    • command docstring and option/argument help
    • README.md updated (Feature Overview)
    • CHANGELOG.md updated
    • RTD doc updated and building with no error (make clean && make html in docs/)

@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@codecov
Copy link

codecov bot commented Nov 12, 2021

Codecov Report

Merging #335 (0159462) into master (ce8026b) will increase coverage by 0.02%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #335      +/-   ##
==========================================
+ Coverage   92.31%   92.33%   +0.02%     
==========================================
  Files          50       50              
  Lines        3970     3981      +11     
  Branches      521      521              
==========================================
+ Hits         3665     3676      +11     
  Misses        203      203              
  Partials      102      102              
Impacted Files Coverage Δ
tests/test_hpgl.py 100.00% <100.00%> (ø)
vpype/io.py 78.23% <100.00%> (+0.07%) ⬆️

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 ce8026b...0159462. Read the comment docs.

@abey79 abey79 merged commit 2cebb44 into master Nov 12, 2021
@abey79 abey79 deleted the fix-relative-hpgl branch December 28, 2021 10:35
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.

1 participant