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: refactor error annotation, to not loose original error #1152

Merged
merged 1 commit into from Jul 19, 2022
Merged

Conversation

danez
Copy link
Contributor

@danez danez commented Jul 19, 2022

With the previous approach all custom error properties like for example code were lost
Instead of wrapping the error we now only add the customErrorInfo and leave it untouched otherwise.

The current version of zisi breaks @netlify/build because it makes some assumptions about errors (message, code, type) that were changed in #1146

With the previous approach for example `code` was lost
Instead of wrapping the error we now only annotate it
@danez danez added the type: bug code to address defects in shipped code label Jul 19, 2022
@danez danez requested a review from a team July 19, 2022 11:58
@github-actions
Copy link
Contributor

⏱ Benchmark results

Comparing with eb1d3dd

largeDepsEsbuild: 7.8s

⬇️ 4.14% decrease vs. eb1d3dd

^                                                                   8.2s          
│                                                                   ┌──┐    7.8s  
│                                                   7.4s            |  |    ┌──┐  
│                                                   ┌──┐            |  |    |▒▒|  
│                                                   |  |            |  |    |▒▒|  
│ ──────────────────6.2s─────────────6s──────6s─────┼──┼─────6s─────┼──┼────|▒▒|──
│   5.9s    5.9s    ┌──┐    5.8s    ┌──┐    ┌──┐    |  |    ┌──┐    |  |    |▒▒|  
│   ┌──┐    ┌──┐    |  |    ┌──┐    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
└───┴──┴────┴──┴────┴──┴────┴──┴────┴──┴────┴──┴────┴──┴────┴──┴────┴──┴────┴──┴──>
    T-9     T-8     T-7     T-6     T-5     T-4     T-3     T-2     T-1      T    
Legend

largeDepsNft: 37.5s

⬇️ 9.01% decrease vs. eb1d3dd

^                                                                  40.9s          
│                                                  38.7s            ┌──┐          
│                                                   ┌──┐            |  |   37.5s  
│                                                   |  |            |  |    ┌──┐  
│                                                   |  |            |  |    |▒▒|  
│ ─────────────────────────────────────────29.8s────┼──┼───29.8s────┼──┼────|▒▒|──
│  29.2s   29.1s                            ┌──┐    |  |    ┌──┐    |  |    |▒▒|  
│   ┌──┐    ┌──┐           26.8s            |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |            ┌──┐            |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |            |  |            |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |            |  |            |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |            |  |            |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |            |  |            |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |            |  |            |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |            |  |            |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |            |  |            |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |            |  |            |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |            |  |            |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |            |  |            |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |            |  |            |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |            |  |            |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    |  |    n/a     |  |    n/a     |  |    |  |    |  |    |  |    |▒▒|  
└───┴──┴────┴──┴────────────┴──┴────────────┴──┴────┴──┴────┴──┴────┴──┴────┴──┴──>
    T-9     T-8     T-7     T-6     T-5     T-4     T-3     T-2     T-1      T    
Legend

largeDepsZisi: 56.8s

⬇️ 0.60% decrease vs. eb1d3dd

^                                                                  57.1s   56.8s  
│                                                  54.3s            ┌──┐    ┌──┐  
│                                                   ┌──┐            |  |    |▒▒|  
│                                                   |  |            |  |    |▒▒|  
│ ─────────────────45.7s───────────────────44.8s────┼──┼────────────┼──┼────|▒▒|──
│  43.7s            ┌──┐   41.8s    44s     ┌──┐    |  |   44.2s    |  |    |▒▒|  
│   ┌──┐            |  |    ┌──┐    ┌──┐    |  |    |  |    ┌──┐    |  |    |▒▒|  
│   |  |            |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |            |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |            |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |            |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |            |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |            |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |            |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |            |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |            |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |            |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |            |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |            |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |            |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |            |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
│   |  |    n/a     |  |    |  |    |  |    |  |    |  |    |  |    |  |    |▒▒|  
└───┴──┴────────────┴──┴────┴──┴────┴──┴────┴──┴────┴──┴────┴──┴────┴──┴────┴──┴──>
    T-9     T-8     T-7     T-6     T-5     T-4     T-3     T-2     T-1      T    
Legend

@danez danez merged commit adc08c5 into main Jul 19, 2022
@danez danez deleted the error branch July 19, 2022 12:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug code to address defects in shipped code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants