Commit Graph

19664 Commits

Author SHA1 Message Date
Jesse Rosenberger
9efe9e8b80 Bump package versions for 1.5.3-rc.1 release. release/METEOR@1.5.3-rc.1 2017-10-31 11:21:02 -07:00
Ben Newman
f9a9e9f2f9 Another small improvement to temp directory removal logic. 2017-10-31 14:00:46 -04:00
Ben Newman
c257183a55 Use files.rm_recursive_async to implement files.freeTempDir. 2017-10-31 14:00:33 -04:00
Ben Newman
afd556f931 Allow Builder#copyDirectory to re-create symlinks again.
Commit 86ec7eb5db broke tests because we
rely on symlinks even when the symlink option is false.
2017-10-31 14:00:12 -04:00
Ben Newman
fe5479400e Avoid calling files.stat(source) in symlinkWithOverwrite.
This was dangerous because source is often a path relative to the old
target file, whereas files.stat was interpreting source as a path relative
to process.cwd().

Fixes #9203.
2017-10-31 14:00:05 -04:00
Ben Newman
b7695d2e8b Avoid creating symlinks in Builder#copyDirectory when forbidden. 2017-10-31 13:59:59 -04:00
Ben Newman
b2db70a727 Allow files.rm_recursive to yield whenever possible.
A while back, for performance reasons, we disabled yielding for all
files.* operations unless METEOR_DISABLE_FS_FIBERS was set to false.

This was safe for almost all files.* operations, because most of them have
a synchronous fs.*Sync version available.

For a more complicated operation like files.rm_recursive, however, there
is no synchronous or asynchronous counterpart in the fs.* namespace, so
the safety of disabling fibers is not guaranteed.

Lately, files.rm_recursive has become a major source of uncaught ENOTEMPTY
errors on Windows, because rimraf.sync fails with that error, and we don't
give files.rm_recursive_async a chance to delete the directory in a more
persistent, forgiving manner.

The only reason we haven't been falling back to files.rm_recursive_async
is that YIELD_ALLOWED is false by default, so canYield() returns false.

This commit distinguishes between canYield() and mayYield(), and uses
canYield() in files.rm_recursive to determine whether it is technically
safe to yield, regardless of YIELD_ALLOWED.

Anyone who ever asked "Can I go to the bathroom?" in elementary school,
only to be mercilessly rebuked with "I don't know, CAN YOU?" should
understand the difference between these two functions.
2017-10-31 13:59:37 -04:00
Ben Newman
f73c7207e2 Use files.rm_recursive_async to implement meteor reset.
This should hopefully prevent ENOTEMPTY errors on Windows.
2017-10-31 13:59:10 -04:00
Ben Newman
b567fa0a39 Allow asynchronous meteor command implementations. 2017-10-31 13:59:03 -04:00
Ben Newman
ddc490c66d Use module.watch live bindings to solve #9176.
Further explanation / discussion:
https://github.com/meteor/meteor/issues/9176#issuecomment-335913296

Another (complementary) solution to the same problem: #9190
2017-10-31 13:58:31 -04:00
Ben Newman
699768f39d Stop using file.imported to mark fake files in the ImportScanner.
Using a Symbol ensures compiler plugins can't mark files fake accidentally
(or maliciously) when calling inputFile.addJavaScript(options).
2017-10-31 13:58:30 -04:00
Ben Newman
f2b800c927 Remove target directory in files.rename to avoid Windows EPERM errors.
These errors are especially harmful because they cause files.rename to
fall back to copying rather than atomically renaming, which is both much
slower and not even remotely atomic.
2017-10-31 13:58:30 -04:00
Ben Newman
55a6d1b50b Revert "Rename installPath property to absModuleId, and make absolute."
This reverts commit b9f0a54b39.

Though probably a good idea for the future, this change was not really
necessary for Meteor 1.6, and probably too risky for a release candidate.
2017-10-31 10:06:25 -07:00
Jesse Rosenberger
1995c8d445 Bump $BUNDLE_VERSION to 4.8.43 before rebuilding dev bundle. release/METEOR@1.5.3-rc.0 2017-10-27 15:15:56 -07:00
Jesse Rosenberger
d6fc953ba6 Bump $NODE_BUILD_NUMBER to 120 before rebuilding dev bundle. 2017-10-27 15:15:55 -07:00
Jesse Rosenberger
9c62a55137 Bump $NODE_BUILD_NUMBER to 116 before rebuilding dev bundle. 2017-10-27 14:47:06 -07:00
Jesse Rosenberger
e5211e4876 Bump package versions for 1.5.3-rc.0 release. 2017-10-27 11:39:02 -07:00
Ben Newman
8dc1fc3512 Fix typo in ImportScanner#_scanFile.
Introduced by 3faee05eed.

cc @cpury @JanMP
2017-10-26 12:47:19 -07:00
Ben Newman
6323a34d6a Adjust npm update notifier opt-out environment variable.
https://github.com/zkat/npx/issues/98#issuecomment-316936135
https://www.npmjs.com/package/update-notifier#user-settings
2017-10-26 12:37:35 -07:00
Ben Newman
c03a46f70f Regression test for #9185 (fixed by #9187). 2017-10-26 12:37:23 -07:00
Ben Newman
3b7943f631 Add more comments to recently-modified ImportScanner logic. 2017-10-26 12:23:49 -07:00
Ben Newman
202e913faa Call _scanFile far fewer times in ImportScanner#scanMissingModules. 2017-10-26 12:23:49 -07:00
Ben Newman
1470bc841f Remember whether parent module of failed import was dynamic.
Fixes #9182.
2017-10-26 12:23:49 -07:00
Ben Newman
4e778b6e17 Rename installPath property to absModuleId, and make absolute.
The `installPath` property was always essentially an absolute module
identifier that was simply missing the leading '/' character, so this
commit acknowledges that role by renaming the property to `absModuleId`
and adding the leading slash.
2017-10-26 12:23:48 -07:00
Ben Newman
9ac6d60ba2 Track all failed imports separately.
Previously, if more than one module in a package tried and failed to
import the same identifier, we would record information about only the
last failed import.

This was good enough for later attempting to resolve the failed import in
other packges or the application's `node_modules` directory (a concept
known as "peer dependencies"), but it sometimes discarded information
about whether the failed imports were dynamic. In particular, if the last
recorded failed import was a dynamic import, it could accidentally render
the entire peer dependency tree dynamic.

Although it's a bit more complicated than what we did before, I believe
the simplest solution is for the ImportScanner to maintain a mapping from
failed identifiers to lists of import information objects, rather than a
single object, so that no information is lost.
2017-10-26 12:23:48 -07:00
Ben Newman
6cee042b54 Simplify checking/setting file.imported in ImportScanner#_scanFile.
By checking and setting this property earlier, we can avoid scanning files
more than once.
2017-10-26 12:23:33 -07:00
Jesse Rosenberger
16a4bbab04 Bump $NODE_VERSION to 4.8.5 before rebuilding dev bundle.
While the actual version included for Unix developers will be our own
build at NODE_VERSION, this is important for the Windows version, since
it is not being rebuilt by our Jenkins at the moment.
2017-10-24 16:03:07 -07:00
Jesse Rosenberger
cc2608f4a0 Bump $BUNDLE_VERSION to 4.8.42 before rebuilding dev bundle. 2017-10-24 16:00:55 -07:00
Jesse Rosenberger
8841080c9e Bump $NODE_BUILD_NUMBER to 113 before rebuilding dev bundle. 2017-10-24 16:00:54 -07:00
Ben Newman
cb85625520 Remove dev_bundle/.npm (-30MB due to .npm/_cacache). 2017-10-24 16:00:54 -07:00
Ben Newman
450e6b4ae0 Merge pull request #9151 from meteor/release-1.5.2.2
Release 1.5.2.2
2017-09-29 18:03:10 -04:00
Ben Newman
807bfa560c Bump package versions for the official 1.5.2.2 release. release/METEOR@1.5.2.2 2017-09-29 17:14:38 -04:00
Ben Newman
2df59ba229 Mention another 1.5.2.2 bug fix in History.md and update date. 2017-09-29 17:13:22 -04:00
Ben Newman
ee43eba7b3 Bump package versions for 1.5.2.2-rc.1 release. release/METEOR@1.5.2.2-rc.1 2017-09-29 14:09:16 -04:00
Ben Newman
4420e4526f Bump $BUNDLE_VERSION to 4.8.41 before rebuilding dev bundle. 2017-09-29 13:51:51 -04:00
Ben Newman
ea1800d065 Include Node headers and node.lib in dev bundle on Windows.
Fixes #9153.
2017-09-29 13:51:24 -04:00
Jesse Rosenberger
24b9ea4a08 Update History.md with miscellaneous changes in Meteor 1.5.2.2. 2017-09-28 21:22:37 +03:00
Jesse Rosenberger
e1180c0377 Bump package versions for 1.5.2.2-rc.0 release. release/METEOR@1.5.2.2-rc.0 2017-09-28 20:53:08 +03:00
Jesse Rosenberger
cdc5c5101f Bump $BUNDLE_VERSION to 4.8.40 before rebuilding dev bundle. 2017-09-28 19:18:50 +03:00
Jesse Rosenberger
8bda1309b4 Bump $NODE_BUILD_NUMBER to 111 before rebuilding dev bundle. 2017-09-28 19:17:37 +03:00
Jesse Rosenberger
56b3706432 Bump package versions for 1.5.2.2-rc.0 release. 2017-09-28 19:15:22 +03:00
Jesse Rosenberger
01b5487aab Merge pull request #9148 from hwillson/issue-9140
Make sure Accounts login only sets 1 onReconnect callback
2017-09-28 19:05:31 +03:00
Jesse Rosenberger
8a627c1b75 Move comment about DESTDIR/PORTABLE=1 into place. 2017-09-28 17:44:28 +03:00
Ben Newman
462a29702d Make Npm.require import built-in modules first. 2017-09-28 17:21:17 +03:00
Jesse Rosenberger
573ccb95a3 Bump $BUNDLE_VERSION to 4.8.39 before rebuilding dev bundle. 2017-09-28 17:13:41 +03:00
Jesse Rosenberger
576490d3f9 Bump $NODE_BUILD_NUMBER to 106 before rebuilding dev bundle. 2017-09-28 17:08:20 +03:00
Jesse Rosenberger
c10c5c161b Don't strip the top directory when extracting our Node tarball.
Thanks to changes in the `build-node-for-dev-bundle.sh` script done in
0583e5883c, we now build a tarball which
is identical to the structure provided by Node.js themselves.

While generally we are using the main Node releases, this will allow
our users to (if need be), use a tarball directly in place of their own
in production without additional changes.  Similarly, the only change
we need to make now when building the dev bundle is to use a different
URL.
2017-09-28 16:29:20 +03:00
Hugh Willson
c5f642cb86 Make sure Accounts login only sets 1 onReconnect callback
The changes added in
d854a4b9ba
fixed a long standing issue where the Accounts system was
overwriting other DDP `connection.onReconnect` callbacks,
that were potentially set by developers (and vice-versa -
developers could overwrite the `onReconnect` callback registered
by the Accounts system, which impacted logging back in after
reconnecting). Unfortunately these changes are also registering a
new duplicate `onReconnect` callback to be called, after every
login. These duplicate callbacks pile up and are all called when
reconnecting, which eventually breaks user logins.

The changes in this commit make sure that any previously set
Accounts login `onReconnect` callback is first removed, before
adding a new callback. This ensures the Accounts system is only
ever setting one `onReconnect` callback after logging in.

Fixes #9140.
2017-09-28 08:55:16 -04:00
Ben Newman
96bc29295a Don't extract bin/node (we'll do this on Jenkins). 2017-09-27 20:56:25 -04:00
Jesse Rosenberger
0583e5883c Changes to Node.js build script. 2017-09-27 17:25:18 -04:00