Commit Graph

2034 Commits

Author SHA1 Message Date
David Glasser
5fbb8bc9f1 help update for create --package 2014-08-21 18:45:08 -07:00
Emily Stark
3c6c51acd1 Add extra check in stats retrieval in test 2014-08-21 18:31:46 -07:00
Emily Stark
1852e7b2c0 Update test for new package stats format 2014-08-21 18:23:38 -07:00
Emily Stark
81a0a0c7e2 Update to new package stats format 2014-08-21 18:23:38 -07:00
Emily Stark
0c2dd7aff4 Change package stats server hostname 2014-08-21 18:23:37 -07:00
David Glasser
e36c4184ab fix old bundler test failure 2014-08-21 17:46:51 -07:00
David Glasser
bc1520cbdd great, now we can use parseConstraint 2014-08-21 17:09:36 -07:00
David Glasser
5d5d1876da De-dup package name/constraint parsing code
Now we can all any of them from even before uniload is ready in the tool

I <3 symlinks
2014-08-21 17:00:21 -07:00
David Glasser
a9c740165c stop uniload packages from using versionsFrom
They don't need to and it won't work.
2014-08-21 16:52:02 -07:00
David Glasser
d6855456a2 Use buildmessage better in api.use, etc
Provide good messages when you provide invalid things to api.use and
api.imply.

Provide better message when you provide invalid things to
api.versionsFrom.

Drop "notInitialized" hack from catalog: now that we load things in
order, it's not necessary.  (This means life will break if you use
api.versionsFrom in a uniloaded package. So don't do that.)
2014-08-21 16:48:13 -07:00
David Glasser
2453820597 fix buildmessage errors within onUse/onTest
Adding buildmessage.markBoundary ensures that we don't display a stack
containing the call stack in the tool above this point.
2014-08-21 16:42:46 -07:00
David Glasser
5bc415c51a Improve package name/version parsing errors
We now throw more specific errors, consistent between both tools and
package-version-parser (copy-and-pasted code, sadly, but we really do
have to make this check before uniload-from-checkout).
2014-08-21 16:21:12 -07:00
David Glasser
c68e1489bd 'meteor create --package foo' in app DTRT
It puts the package in $APPROOT/packages/foo instead of ./foo.
2014-08-21 15:06:46 -07:00
ekatek
2f73eebf0a even better wording 2014-08-21 15:01:58 -07:00
ekatek
7f0e7eee67 even better wording 2014-08-21 15:00:48 -07:00
ekatek
d81bbefa22 better error message 2014-08-21 15:00:12 -07:00
ekatek
c89ff1fa25 check to make sure package names don't start with a dot 2014-08-21 13:49:36 -07:00
ekatek
e859266aaf changes, as per glasser's code review 2014-08-21 13:41:29 -07:00
David Glasser
f1a50bbc93 show stack if error is unexpected 2014-08-21 10:48:20 -07:00
David Glasser
e98cd49b3b A more specific error for nonexistent package
This helps with #2410 though that particular case doesn't work since
paths are explored in a bad order.
2014-08-20 23:21:30 -07:00
David Glasser
7e32a1cba4 Revert "one weird hack to maybe have better messages for nonexistent packages"
This reverts commit 75df1097e0.
2014-08-20 23:21:30 -07:00
David Glasser
4586d60e7d Revert "bad merge diffs"
This reverts commit 7946be9f9b.
2014-08-20 23:21:30 -07:00
Matthew Arbesfeld
d771fdbf2a Fix uniload for packages with plugins 2014-08-20 20:54:58 -07:00
ekatek
7946be9f9b bad merge diffs 2014-08-20 16:20:29 -07:00
ekatek
75df1097e0 one weird hack to maybe have better messages for nonexistent packages 2014-08-20 16:19:24 -07:00
David Glasser
0bc445e8d2 Make slow operations more bearable with Patience
Introduces a "Patience" class which lets CPU-bound operations like the
constraint solver yield every so often, and print messages if an
operation (CPU-bound or not) are taken or not.
2014-08-20 15:49:58 -07:00
ekatek
019d3d289e don't crash when removing a nonexistent package 2014-08-20 15:20:22 -07:00
David Glasser
6f1c74465b adjust which tests are from checkout 2014-08-19 19:34:26 -07:00
ekatek
b28a84cca2 wrap opennign server connection in a try/catch block from refresh 2014-08-19 18:47:37 -07:00
Matthew Arbesfeld
0df7bdc378 Fix client side reload race condition
There was a race condition between the bundle process and when we established
the client watch set. We now store the future for the old bundle process so
that it cannot be invalidated.
2014-08-19 18:38:36 -07:00
ekatek
ff8498dd1b mark tests from checkout if they use the test server due to release duplication issues 2014-08-19 17:07:53 -07:00
ekatek
6e6a48a913 output safety 2014-08-19 15:33:38 -07:00
David Glasser
ec3ecb3523 Remove work-around for fstream bug
Now fixed upstream.
2014-08-19 14:10:00 -07:00
David Glasser
fceacf2885 Use 15-second timeout for service connections
This should reduce failures to send package stats.
2014-08-19 12:41:00 -07:00
ekatek
52e3eafa5c tests and minor fixes for --name 2014-08-19 12:32:16 -07:00
ekatek
b29a4cc439 more detaled wip on name coming from package.js 2014-08-19 12:32:16 -07:00
David Glasser
84955c7ff4 selftest.fail instead of faux expectEqual 2014-08-19 10:39:56 -07:00
David Glasser
69cf01a138 don't leak readstream 2014-08-18 20:11:47 -07:00
David Glasser
883fc8516d files.OfflineError prettier than [object Object]
(It should also be caught at every httpHelpers.getUrl call and handled
properly, but this is a start.)
2014-08-18 20:10:52 -07:00
David Glasser
196089ae33 package-client: Help users without usernames
- If they're in deferred-registration state, give them their
  registration link and exit.

- Before running the login prompt, mention that it's a Meteor developer
  account which you can sign up for on www.meteor.com.
2014-08-18 19:13:06 -07:00
David Glasser
9054effdeb Fix ServiceConnection DDP negotiation
Now ServiceConnection's guarantee is that once a DDP connection is
successfully negotiated, it won't restart. This relies on the assumption
that the only use of reconnect({_force: true}) is DDP protocol
negotiation!

Drop some unnecessary (and flawed, for this application) `disconnect`
stream events.

Also, remove some unnecessary `new` calls.

Fixes 'meteor mongo some-galaxy app'.
2014-08-18 17:09:04 -07:00
David Glasser
f3085db2d2 Work around a node-tar bug
See https://github.com/npm/fstream/issues/26
2014-08-18 15:10:15 -07:00
David Glasser
4ac638d60b oops, didn't mean to add blank line 2014-08-18 00:32:15 -07:00
David Glasser
558fb92651 state that package stat error is only in checkout 2014-08-18 00:31:12 -07:00
David Glasser
4af87eadb1 old test app version bump (this is silly) 2014-08-18 00:28:37 -07:00
David Glasser
73b33ee4da note about why official.refresh uses buildmessage 2014-08-18 00:28:23 -07:00
David Glasser
08a6fa99fd Don't use _.once or instanceof with uniload
_.once has the problem that if you call the once'd function while it is
still in progress (re-entrantly or in another Fiber), it returns
undefined immediately.  That's bad for uniload! uniload already has a
cache, so just use that.  (In the future, perhaps detect an attempt to
uniload something that's currently in the process of being uniloaded in
another fiber and block until the other fiber is ready.)

Using instanceof with things you've uniloaded is a little sketchy: maybe
two different uniload calls will end up with two different copies of
Package.meteor.Meteor.Error, and it seems kind of hairy to ensure you're
not mixing and matching copies.  However, Meteor.Errors are all tagged
with a string errorType, which fills me with much less fear,
uncertainty, and doubt than instanceof.
2014-08-17 23:37:38 -07:00
David Glasser
acd5e0b04c remove deprecated release option from uniload.load 2014-08-17 23:33:06 -07:00
David Glasser
9427c803e1 fix report-stats test again 2014-08-17 23:12:03 -07:00
David Glasser
3b3e8d7b93 Simplify ServiceConnection.
- ServiceConnection should never try to reconnect. It's already the case
  that we don't hold open ServiceConnections over long periods while
  idle; it makes the class much simpler if it corresponds to a single
  TCP connection. This also means that as soon as we have one connection
  failure (eg you're offline) we can fail instantly instead of retrying
  pointlessly.

- Drop the explicit timeout code in ServiceConnection. There's already
  timeout handling in stream_client, and now that we don't retry, it
  actually takes effect.

- Be more rigorous about uses of Future in ServiceConnection. Ensure
  that each Future is only used once (ie, avoid "Future resolved more
  than once" errors).  Hopefully fixes #2390.

- ServiceConnection constructor now blocks until it's connected (and
  throws if there's a connection failure).  Maybe this introduces a tiny
  bit more latency to the connection, but it makes it much easier to
  handle errors properly.

- In packageClient.handlePackageServerConnectionError, show the error
  message corresponding to the connection failure.

- In Node, the (newish) error passed to the Stream callback is now a
  "DDP.ConnectionError" object. We can detect this in the tool (and we
  don't even need to do some complex uniload/instanceof dance, since
  error classes made with Meteor.makeErrorType label themselves with a
  string errorType).  We also no longer have a special
  ServiceConnection.ConnectionTimeoutError.
2014-08-17 21:34:57 -07:00