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 support for async functions as config #3472

Merged
merged 2 commits into from Mar 30, 2020

Conversation

lukastaegert
Copy link
Member

This PR contains:

  • bugfix
  • feature
  • refactor
  • documentation
  • other

Are tests included?

  • yes (bugfixes and features will not be merged without tests)
  • no

Breaking Changes?

  • yes (breaking changes will not be merged unless absolutely necessary)
  • no

List any relevant issue numbers:
Resolves #3470

Description

Don't know how this could slip past the radar. We had tests for configs as Promises and configs as functions, but functions that return promises...
Now async functions are supported again.

@rollup-bot
Copy link
Collaborator

Thank you for your contribution! ❤️

You can try out this pull request locally by installing Rollup via

npm install rollup/rollup#gh-3470-async-function-config

or load it into the REPL:
https://rollupjs.org/repl/?circleci=10214

@codecov
Copy link

codecov bot commented Mar 30, 2020

Codecov Report

Merging #3472 into master will not change coverage by %.
The diff coverage is 100.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #3472   +/-   ##
=======================================
  Coverage   95.81%   95.81%           
=======================================
  Files         174      174           
  Lines        5898     5898           
  Branches     1737     1736    -1     
=======================================
  Hits         5651     5651           
  Misses        127      127           
  Partials      120      120           
Impacted Files Coverage Δ
cli/run/loadConfigFile.ts 95.55% <100.00%> (ø)

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 9fa326f...bff1431. Read the comment docs.

@lukastaegert lukastaegert merged commit 943995d into master Mar 30, 2020
@lukastaegert lukastaegert deleted the gh-3470-async-function-config branch March 30, 2020 19:29
@3cp
Copy link

3cp commented Apr 2, 2020

I am seeing syntax error in my CI task running nodejs v8. This probably should be released as breaking change since it does not run on nodejs v8.

> bcx-validation@1.2.0 build /home/runner/work/bcx-validation/bcx-validation
12
> env BABEL_ENV=development rollup -c
13

14
/home/runner/work/bcx-validation/bcx-validation/node_modules/rollup/dist/shared/loadConfigFile.js:484
15
        ? (await import(url.pathToFileURL(fileName).href)).default
16
                 ^^^^^^
17

18
SyntaxError: Unexpected token import

@lukastaegert
Copy link
Member Author

Node 8 is no longer supported since v2.0.0

@3cp
Copy link

3cp commented Apr 2, 2020

Oh, I missed that :-) Obviously it is only broken on latest v2, as I didn't have any issue on last few v2 versions.

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.

2.3.0 no longer supports async functions for config
4 participants