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

Regression with 2.20.5 (from 2.20.1) #636

Closed
doompadee opened this issue Nov 15, 2023 · 2 comments
Closed

Regression with 2.20.5 (from 2.20.1) #636

doompadee opened this issue Nov 15, 2023 · 2 comments

Comments

@doompadee
Copy link

Updating from 2.20.1 to 2.20.5 breaks my Hugo build. The error message reads:

ERROR MINIFY: failed to transform "file.js" (text/javascript): unexpected else in expression on line 6200 and column 19
 6200:                   else if (e3 === Pl.Bytes)
                         ^

which seems to relate to the following code (from the maplibre-gl dependency I would guess):

Pl.prototype = {
  ...,skip: function(t2) {
    var e3 = 7 & t2;
    if (e3 === Pl.Varint)
      for (; this.buf[this.pos++] > 127; )
        ;
    else if (e3 === Pl.Bytes) // line 6200
      this.pos = this.readVarint() + this.pos;
    else if (e3 === Pl.Fixed32)
      this.pos += 4;
    else {
      if (e3 !== Pl.Fixed64)
        throw new Error("Unimplemented type: " + e3);
      this.pos += 8;
    }
  },...
}

Maybe minify has a problem with the empty statement in the first branch of the conditional?

@julianlampert
Copy link

+1

@tdewolff
Copy link
Owner

Thanks, has been fixed!

notdryft added a commit to gatling/gatling.io-doc that referenced this issue Nov 21, 2023
Motivation:

- Until they use a fixed version of minify: tdewolff/minify#636 (i.e.: 2.20.7)
notdryft added a commit to gatling/gatling.io-doc that referenced this issue Nov 21, 2023
Motivation:

- Until they use a fixed version of minify: tdewolff/minify#636 (i.e.: 2.20.7)
kodiakhq bot referenced this issue in cloudquery/codegen Jan 1, 2024
)

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [github.com/tdewolff/minify/v2](https://togithub.com/tdewolff/minify) | indirect | patch | `v2.20.6` -> `v2.20.10` |

---

### Release Notes

<details>
<summary>tdewolff/minify (github.com/tdewolff/minify/v2)</summary>

### [`v2.20.10`](https://togithub.com/tdewolff/minify/releases/tag/v2.20.10)

[Compare Source](https://togithub.com/tdewolff/minify/compare/v2.20.9...v2.20.10)

-   [cmd: default value for --preserve only includes ownership if supported on platform](https://togithub.com/tdewolff/minify/commit/d579304e76fbf4c9de4b6cafab3dd9246c00edcc), see [https://github.com/tdewolff/minify/issues/646](https://togithub.com/tdewolff/minify/issues/646)
-   [cmd: fix endless loop on preserving attributes on Windows, see](https://togithub.com/tdewolff/minify/commit/ca97b30acea0a22471011ccd3b075325a5e576b8) [https://github.com/tdewolff/minify/issues/646](https://togithub.com/tdewolff/minify/issues/646)
-   Fix various parsing bugs for JS/HTML in `tdewolff/parse`

### [`v2.20.9`](https://togithub.com/tdewolff/minify/releases/tag/v2.20.9)

[Compare Source](https://togithub.com/tdewolff/minify/compare/v2.20.8...v2.20.9)

Fix build

### [`v2.20.8`](https://togithub.com/tdewolff/minify/releases/tag/v2.20.8)

[Compare Source](https://togithub.com/tdewolff/minify/compare/v2.20.7...v2.20.8)

-   [HTML: fix parsing of PHP/ASP/EJS files](https://togithub.com/tdewolff/minify/commit/5b4030cc8240edf4b87bc8d195bc3f3d1ca46f50)
-   [cmd: support ASP, PHP, Mustache, Handlebars, EJS and Go templates for command line](https://togithub.com/tdewolff/minify/commit/5b4030cc8240edf4b87bc8d195bc3f3d1ca46f50)

### [`v2.20.7`](https://togithub.com/tdewolff/minify/releases/tag/v2.20.7)

[Compare Source](https://togithub.com/tdewolff/minify/compare/v2.20.6...v2.20.7)

-   [JS: fix parsing of empty for-loop,](https://togithub.com/tdewolff/minify/commit/be084bb11b53852ae0b8147585b210bed1f85a85) [fixes](https://togithub.com/tdewolff/minify/commit/be084bb11b53852ae0b8147585b210bed1f85a85) [https://github.com/tdewolff/minify/issues/636](https://togithub.com/tdewolff/minify/issues/636)

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "before 4am on the first day of the month" (UTC), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR has been generated by [Renovate Bot](https://togithub.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4xMTUuMCIsInVwZGF0ZWRJblZlciI6IjM3LjExNS4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiJ9-->
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

No branches or pull requests

3 participants