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

Missing context in minify errors #9852

Closed
bep opened this issue May 2, 2022 · 2 comments
Closed

Missing context in minify errors #9852

bep opened this issue May 2, 2022 · 2 comments
Assignees
Milestone

Comments

@bep
Copy link
Member

bep commented May 2, 2022

Here's one I have no idea where to even look:

Error: Error building site: failed to render pages: expected Identifier instead of < in dot expression on line 3803 and column 99
    1:  tag.</dd>
@bep bep self-assigned this May 2, 2022
@bep bep removed the NeedsTriage label May 2, 2022
@bep bep added this to the v0.99.0 milestone May 2, 2022
bep added a commit to bep/hugo that referenced this issue May 2, 2022
bep added a commit to bep/hugo that referenced this issue May 3, 2022
* Remove usage of `github.com/pkg/errors`, mostly because of pkg/errors#223 -- but also because most of this is now built-in to Go.

Fixes gohugoio#9852
bep added a commit to bep/hugo that referenced this issue May 4, 2022
To get to this, this commit also cleans up and simplifies the code surrounding errors and files. This also removes the usage of `github.com/pkg/errors`, mostly because of pkg/errors#223 -- but also because most of this is now built-in to Go.

Fixes gohugoio#9852
Fixes gohugoio#9857
@bep
Copy link
Member Author

bep commented May 4, 2022

OK, so with the long detour improving the error handling here, it pointed me to this part:

<dd>The output format.
One of: <code>iife</code>, <code>cjs</code>, <code>esm</code>.
Default is <code>iife</code>, a self-executing function, suitable for inclusion as a <script> tag.</dd>
<dt>sourceMap</dt>
<dd>Whether to generate source maps. Enum, currently only <code>inline</code> (we will improve that).</dd>
</dl>

Which got my memory back to where I enabled unsafe mode on the site which let the <script> tag through ... Bonkers, OK, at least this will be easier for others in the future.

bep added a commit to bep/hugo that referenced this issue May 4, 2022
To get to this, this commit also cleans up and simplifies the code surrounding errors and files. This also removes the usage of `github.com/pkg/errors`, mostly because of pkg/errors#223 -- but also because most of this is now built-in to Go.

Fixes gohugoio#9852
Fixes gohugoio#9857
bep added a commit to bep/hugo that referenced this issue May 4, 2022
To get to this, this commit also cleans up and simplifies the code surrounding errors and files. This also removes the usage of `github.com/pkg/errors`, mostly because of pkg/errors#223 -- but also because most of this is now built-in to Go.

Fixes gohugoio#9852
Fixes gohugoio#9857
bep added a commit to bep/hugo that referenced this issue May 5, 2022
To get to this, this commit also cleans up and simplifies the code surrounding errors and files. This also removes the usage of `github.com/pkg/errors`, mostly because of pkg/errors#223 -- but also because most of this is now built-in to Go.

Fixes gohugoio#9852
Fixes gohugoio#9857
bep added a commit to bep/hugo that referenced this issue May 5, 2022
To get to this, this commit also cleans up and simplifies the code surrounding errors and files. This also removes the usage of `github.com/pkg/errors`, mostly because of pkg/errors#223 -- but also because most of this is now built-in to Go.

Fixes gohugoio#9852
Fixes gohugoio#9857
bep added a commit to bep/hugo that referenced this issue May 6, 2022
* Add file context to minifier errors when publishing
* Misc fixes (see issues)

To get to this, this commit also cleans up and simplifies the code surrounding errors and files. This also removes the usage of `github.com/pkg/errors`, mostly because of pkg/errors#223 -- but also because most of this is now built-in to Go.

Fixes gohugoio#9852
Fixes gohugoio#9857
Fixes gohugoio#9863
bep added a commit to bep/hugo that referenced this issue May 6, 2022
* Add file context to minifier errors when publishing
* Misc fixes (see issues)

To get to this, this commit also cleans up and simplifies the code surrounding errors and files. This also removes the usage of `github.com/pkg/errors`, mostly because of pkg/errors#223 -- but also because most of this is now built-in to Go.

Fixes gohugoio#9852
Fixes gohugoio#9857
Fixes gohugoio#9863
bep added a commit to bep/hugo that referenced this issue May 6, 2022
* Add file context to minifier errors when publishing
* Misc fixes (see issues)

To get to this, this commit also cleans up and simplifies the code surrounding errors and files. This also removes the usage of `github.com/pkg/errors`, mostly because of pkg/errors#223 -- but also because most of this is now built-in to Go.

Fixes gohugoio#9852
Fixes gohugoio#9857
Fixes gohugoio#9863
bep added a commit to bep/hugo that referenced this issue May 6, 2022
* Add file context to minifier errors when publishing
* Misc fixes (see issues)
* Allow custom server error template in layouts/server/error.html

To get to this, this commit also cleans up and simplifies the code surrounding errors and files. This also removes the usage of `github.com/pkg/errors`, mostly because of pkg/errors#223 -- but also because most of this is now built-in to Go.

Fixes gohugoio#9852
Fixes gohugoio#9857
Fixes gohugoio#9863
bep added a commit to bep/hugo that referenced this issue May 6, 2022
* Add file context to minifier errors when publishing
* Misc fixes (see issues)
* Allow custom server error template in layouts/server/error.html

To get to this, this commit also cleans up and simplifies the code surrounding errors and files. This also removes the usage of `github.com/pkg/errors`, mostly because of pkg/errors#223 -- but also because most of this is now built-in to Go.

Fixes gohugoio#9852
Fixes gohugoio#9857
Fixes gohugoio#9863
bep added a commit to bep/hugo that referenced this issue May 6, 2022
* Add file context to minifier errors when publishing
* Misc fixes (see issues)
* Allow custom server error template in layouts/server/error.html

To get to this, this commit also cleans up and simplifies the code surrounding errors and files. This also removes the usage of `github.com/pkg/errors`, mostly because of pkg/errors#223 -- but also because most of this is now built-in to Go.

Fixes gohugoio#9852
Fixes gohugoio#9857
Fixes gohugoio#9863
bep added a commit to bep/hugo that referenced this issue May 6, 2022
* Add file context to minifier errors when publishing
* Misc fixes (see issues)
* Allow custom server error template in layouts/server/error.html

To get to this, this commit also cleans up and simplifies the code surrounding errors and files. This also removes the usage of `github.com/pkg/errors`, mostly because of pkg/errors#223 -- but also because most of this is now built-in to Go.

Fixes gohugoio#9852
Fixes gohugoio#9857
Fixes gohugoio#9863
@bep bep closed this as completed in f2946da May 6, 2022
@github-actions
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 28, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant