Commit Graph

21499 Commits

Author SHA1 Message Date
Ben Newman
bcaeed676e Move puppeteer back to dependencies for test applications.
This should fix test failures, because apparently it's important that
puppeteer not be installed in devDependencies.
2018-08-04 14:49:55 -04:00
Ben Newman
a007738d2f Bump package versions for 1.7.1-beta.27 release. release/METEOR@1.7.1-beta.27 2018-08-04 14:40:57 -04:00
Ben Newman
96c72791ed Increment LINKER_CACHE_SALT to force relinking after Babel updates. 2018-08-04 14:27:39 -04:00
Ben Newman
b23b1213f4 Update @babel/... dependencies of modules test app to 7.0.0-beta.56.
Also moving puppeteer to devDependencies.
2018-08-04 14:27:38 -04:00
Ben Newman
ce68c4b91c Update dynamic-import test app dependencies. 2018-08-04 14:12:23 -04:00
Ben Newman
4d4a678c7d Use Npm.depends to install core-js in ecmascript-runtime-client.
The @babel/plugin-transform-runtime@7.0.0-beta.56 plugin used by
meteor-babel@7.0.0-beta.56 now generates code that imports helpers from
@babel/runtime@7.0.0-beta.56, which no longer relies on core-js:
https://github.com/babel/babel/pull/8266
https://github.com/babel/babel/releases/tag/v7.0.0-beta.56

This is not much of a change for modern browsers, since we were already
using @babel/runtime/helpers/builtin to avoid relying on core-js. However,
for the legacy bundle, it's now more important than ever that we import
appropriate core-js polyfills in ecmascript-runtime-client, since they are
not going to be imported as a side-effect of using @babel/runtime.

That means there's no longer as much benefit to sharing the application's
copy of core-js with ecmascript-runtime-client, so it seems simpler just
to give ecmascript-runtime-client its own private copy of core-js, so that
it can import appropriate polyfills without forcing the developer to
install core-js explicitly in the application.
2018-08-04 13:50:42 -04:00
Ben Newman
6901089b20 Update core-js used by ecmascript-runtime-server to latest version. 2018-08-04 13:46:01 -04:00
Ben Newman
d38101bdde Bump package versions for 1.7.1-beta.26 release. release/METEOR@1.7.1-beta.26 2018-08-04 13:15:33 -04:00
Ben Newman
a655cf3dd5 Bump $BUNDLE_VERSION to 8.11.3.10 before rebuilding dev bundle. 2018-08-04 13:01:45 -04:00
Ben Newman
97bd20449f Update meteor-babel to version 7.0.0-beta.56.
Fixes https://github.com/meteor/babel/issues/22.
2018-08-04 12:59:04 -04:00
Ben Newman
d6f78ae4d8 Enforce installation of node_modules/core-js in modern browsers, too. 2018-08-04 12:57:23 -04:00
Ben Newman
350a3952c9 Bump package versions for 1.7.1-beta.25 release. release/METEOR@1.7.1-beta.25 2018-08-03 12:00:07 -04:00
Ben Newman
89b7d1f57e Bump $BUNDLE_VERSION to 8.11.3.9 before rebuilding dev bundle. 2018-08-03 11:53:01 -04:00
Ben Newman
e8987eb0b9 Update node-gyp and node-pre-gyp to latest versions. 2018-08-03 11:13:54 -04:00
Ben Newman
960f8d61cc Update npm to version 6.3.0.
The pacote dependency (a small fork of which we maintain) remains at
version 8.1.6.
2018-08-03 11:11:34 -04:00
Ben Newman
7dc77cdaf1 Fix importing local .json modules within Meteor packages.
The ImportScanner was mistakenly generating module.useNode() stub modules
for local .json files within Meteor packages, just because their absolute
module identifiers include "node_modules", which happens because we put
package modules under the /node_modules/meteor/<package name/ namespace.

Fix: make logic for determining when to generate module.useNode() stubs
match Module.prototype.useNode logic in modules-runtime/server.js.

Closes #10122.
2018-08-03 11:07:51 -04:00
Ben Newman
f2c864ec66 Avoid TDZ error from calling observe callbacks synchronously.
Should fix #10092.
2018-07-31 22:39:09 -04:00
Ben Newman
1bd1fcf588 Bump package versions for 1.7.1-beta.24 release. release/METEOR@1.7.1-beta.24 2018-07-31 21:16:09 -04:00
Ben Newman
41aa06789f Bump $BUNDLE_VERSION to 8.11.3.8 before rebuilding dev bundle. 2018-07-31 20:49:40 -04:00
Ben Newman
09950c403b Update reify npm package to version 0.17.2. 2018-07-31 20:48:25 -04:00
Ben Newman
95d7cdbf6d Use module.link in dynamic-import/client.js. release/METEOR@1.7.1-beta.23 2018-07-31 17:10:14 -04:00
Ben Newman
cd52a0b458 Bump package versions for 1.7.1-beta.23 release. 2018-07-31 17:08:40 -04:00
Ben Newman
0636cffaf1 Use module.link to bridge modules in ImportScanner. 2018-07-31 17:02:59 -04:00
Ben Newman
c5a74a0a1e Bump $BUNDLE_VERSION to 8.11.3.7 before rebuilding dev bundle. 2018-07-31 17:02:59 -04:00
Ben Newman
3a0778fc85 Update meteor-babel and reify npm packages to latest versions.
Probably the most notable change in this update is that the Reify compiler
now generates

  module.link("./child", { ...setters... });

instead of

  module.watch(require("./child"), { ...setters... });

for import and export-from declarations.
2018-07-31 17:02:58 -04:00
Ben Newman
44cdfeb686 Prepare for module.link(id, setters) replacing module.watch.
Thanks to these commits in the Reify project, there's a new runtime module
system method: module.link(id, setters), which replaces the previous (more
cumbersome) module.watch(require(id), setters).

This is more than a cosmetic change, since it will allow creating module
Entry objects before evaluating modules, which will help improve spec
compliance around import cycles and hoisted function declarations.

It's also shorter than the module.watch style, which is always nice.

However, since require(id) no longer appears in the generated code, we
can't just rely on findImportedModuleIdentifiers looking for require
function calls, so the scanner now needs to look for module.link(id, ...)
calls as well.
2018-07-31 17:02:58 -04:00
James Burgess
8a4a62a79b Fix another map function in oauth1 (#10104)
* Fix another map function in oauth1

* Switch const to let on changing variable in oauth1

* Package tests for recent bugs in oauth1 package
2018-07-30 12:05:39 -07:00
Ben Newman
c0b9af522d Ignore another harmless error from {pause,refresh}Client. 2018-07-30 15:03:43 -04:00
Ben Newman
c32fd23b1a Bump package versions for 1.7.1-beta.22 release. release/METEOR@1.7.1-beta.22 2018-07-26 20:27:16 -04:00
Ben Newman
691053175b Ignore some {pause,refresh}Client errors if child process exited. 2018-07-26 20:18:15 -04:00
Ben Newman
8e3f3d8db6 Update mongodb npm package to version 3.1.1. 2018-07-26 19:36:21 -04:00
Ben Newman
d945c49736 Merge branch 'devel' into release-1.7.1 2018-07-26 19:35:58 -04:00
Ben Newman
6747a63c7c Update mongodb npm package to version 3.0.11. (#10101)
Should fix #10087.
2018-07-26 16:19:16 -07:00
James Burgess
644a3494fd Fix map and reduce functions in oauth1 package (#10099)
Also fix whitespace

Fixes #10094
2018-07-26 08:24:26 -07:00
James Burgess
30df020c9d Cache fetch and mongo-decimal npm dependencies and bump key versions (#10091) 2018-07-20 17:39:42 -07:00
Ben Newman
9fb02e9bb2 Bump package versions for 1.7.1-beta.21 release. release/METEOR@1.7.1-beta.21 2018-07-20 19:12:12 -04:00
Ben Newman
f8c76b90dc Force .meteor/local/build to be rebuilt in-place on Windows.
Because in-place rebuilds are disabled by default on Windows, we were
losing .meteor/local/build/programs/web.browser.legacy every time we
rebuilt .meteor/local/build as part of writeSiteArchive, as reported by
@lmachens in this comment: https://github.com/meteor/meteor/pull/9942#issuecomment-406656741

In-place rewriting of .meteor/local/build seems essential for the new
strategy of writing different targets at different times, though I have
attempted to limit the risk of overwriting open files on Windows by
continuing to build the individual target directories from scratch (that
is, by writing a fresh temporary directory and then renaming it over the
existing directory).

Though I don't have any specific ideas in this direction, it may be worth
noting: if we could find a way to make in-place builds safer on Windows
(as they are on Linux and Mac), Windows rebuilds would be significantly
faster than they are with the current strategy of rewriting everything
from scratch every time.
2018-07-20 19:10:18 -04:00
James Miller Burgess
4e22a7c086 Bump npm deps cache version numbers
With the addition of inter-process-messaging npm deps to the cache, but
no change in the shrinkwrap checksum, the cache will not get updated
until we either change any of the shrinkwrap files or change the cache
keys. So I'm bumping the version numbers to do the latter.
2018-07-19 18:28:12 -04:00
James Miller Burgess
fcc5101812 Cache inter-process-messaging dependencies in circleci
Also, fix some whitespace issues that I probably caused!
2018-07-19 18:28:11 -04:00
Ben Newman
a58775663f Bump package versions for 1.7.1-beta.20 release. release/METEOR@1.7.1-beta.20 2018-07-19 18:12:30 -04:00
Ben Newman
a4657f34d5 Merge branch 'devel' into release-1.7.1 2018-07-19 17:53:10 -04:00
Ben Newman
e91b3776e5 Make sure file.jsonData is defined for imported package.json modules.
The defaultExtensionHandlers[".json"] function in import-scanner.js sets
file.jsonData as a side effect, which is important because that's what the
linker uses to construct a stub module.exports object for dynamically
imported package.json modules.

When I introduced ImportScanner#_readPackageJson as an alternative to
ImportScanner#_readModule in a recent commit, I intentionally did not call
defaultExtensionHandlers[".json"], but in so doing I neglected to preserve
the behavior of setting file.jsonData.

Without a proper package.json stub with at least a "main" property, the
dynamic import() system can't resolve dynamically imported packages until
the full package.json module has been fetched from the server, which leads
to missing module errors in the initial dynamic import().
2018-07-19 17:43:53 -04:00
Ben Newman
35473f29e4 Move package.json private field stripping tests into modules test app.
Follow-up to #9903.
2018-07-19 15:31:17 -04:00
Ben Newman
8a7db9b094 Move logic for stripping private package.json fields into ImportScanner.
Follow-up to #9903.
2018-07-19 15:31:05 -04:00
Bartosz Wojtkowiak
c6b136d3ca Remove non deterministic fields from included package.json files. (#9903) 2018-07-19 12:30:17 -07:00
Ben Newman
753be8d2ff Rewrite RoutePolicy#checkForConflictWithStatic to avoid WebApp.defaultArch.
This should help with the problem that @lmachens reported here:
https://github.com/meteor/meteor/pull/9942#issuecomment-406241869
2018-07-19 14:06:42 -04:00
Ben Newman
82174ff0a8 Stop overriding autoupdate version in test-in-browser driver.
This hack dates all the way back to 2013: a2c4a78743

Though it is convenient to reload the browser when server files change
while running test-packages, that's not the behavior of most Meteor apps
that use the autoupdate package, and this hack introduced a signficant
difference in behavior between the test-in-browser and test-in-console
driver packages, which finally surfaced due to the interaction between
@toinevk's headless testing PR #9814 and my refactoring of the autoupdate
package (fe9e4035f9). Tests should behave
the same regardless of which driver package is used.

It turns out there's a better way to make the browser reload each time the
server restarts: simply modify Meteor.settings.public, since that object
is included in the client hashes computed by the webapp package.
2018-07-19 14:06:42 -04:00
Ben Newman
45bbac5940 Fix appcache test by tolerating both Autoupdate.{versions,autoupdateVersion}. 2018-07-19 14:04:33 -04:00
Ben Newman
60c670f0b3 Move AUTOUPDATE_VERSION logic out of webapp_server.js.
It seems obvious in hindsight, but any logic relating to the
AUTOUPDATE_VERSION override should reside within the autoupdate package,
and the true client hashes should be available to any other package that
needs them, without AUTOUPDATE_VERSION getting in the way.
2018-07-19 14:04:32 -04:00
Ben Newman
977ce228b3 Import puppeteer more reliably. 2018-07-19 14:04:32 -04:00