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

Error on sign out in Meteor 0.8.0 #130

Closed
dkoo761 opened this issue Mar 29, 2014 · 19 comments
Closed

Error on sign out in Meteor 0.8.0 #130

dkoo761 opened this issue Mar 29, 2014 · 19 comments

Comments

@dkoo761
Copy link
Contributor

dkoo761 commented Mar 29, 2014

After signing out, I see the following error in the console:

Exception from Deps recompute function: Error: BlazeLayout: Sorry, couldn't find a template named entrySignOut. Are you sure you defined it?
at Component.lookupTemplate (http://localhost:3000/packages/blaze-layout.js?3dc9f80fff25f73dbaaad071907ff24046419cb4:127:11)
at http://localhost:3000/packages/blaze-layout.js?3dc9f80fff25f73dbaaad071907ff24046419cb4:267:35
at http://localhost:3000/packages/ui.js?b523ef986d3d39671bcb40319d0df8982acacfe8:2299:21
at callWithNoYieldsAllowed (http://localhost:3000/packages/deps.js?7afb832ce6e6c89421fa70dc066201f16f9b9105:74:5)
at _.extend._compute (http://localhost:3000/packages/deps.js?7afb832ce6e6c89421fa70dc066201f16f9b9105:212:7)
at _.extend._recompute (http://localhost:3000/packages/deps.js?7afb832ce6e6c89421fa70dc066201f16f9b9105:226:16)
at _.extend.flush (http://localhost:3000/packages/deps.js?7afb832ce6e6c89421fa70dc066201f16f9b9105:323:16)

@AJ-Acevedo
Copy link
Contributor

I'm not experiencing this issue. Try mrt remove blaze-layout then mrt update.

@queso
Copy link
Contributor

queso commented Mar 31, 2014

@dkoo761 can you try AJ's suggestion?

@dkoo761
Copy link
Contributor Author

dkoo761 commented Apr 2, 2014

I tried the above suggestion but it didn't solve it. Just to be clear, I'm seeing the error on the client side in the browser console, not the Meteor server console.

@Art1Sec8
Copy link
Contributor

Art1Sec8 commented Apr 5, 2014

I have been running into the same issue, but I think I may have found a fix: #143

Looks like the issue is that @stop() should be switched over to @pause().

queso added a commit that referenced this issue Apr 7, 2014
Correcting error #130 - changing @Stop to @Pause()
@cinjon
Copy link

cinjon commented Apr 15, 2014

I don't think this is solved. See my comment in the pull-request.

@dkoo761
Copy link
Contributor Author

dkoo761 commented May 4, 2014

Agreed, this is not solved. I'll leave a comment in the PR as well.

@Art1Sec8
Copy link
Contributor

Art1Sec8 commented May 5, 2014

Ok; I think I may have gotten this one now. Take a look at iron-meteor/iron-router#620

Looks like the the issue is that pause needs to be passed as a parameter like so:

 @route 'entrySignOut',
    path: '/sign-out'
    onBeforeAction: (pause)->
      Session.set('entryError', undefined)
      if AccountsEntry.settings.homeRoute
        Meteor.logout () ->
          Router.go AccountsEntry.settings.homeRoute
        pause();

I put together a PR: #168

queso added a commit that referenced this issue May 6, 2014
updating #143 which attempts to correct error #130
@ryw
Copy link
Contributor

ryw commented Jun 11, 2014

#168 is merged, closing this.
Re-open if still an issue.

@ryw ryw closed this as completed Jun 11, 2014
@benmgreene
Copy link
Contributor

I just hit this again:

Exception in defer callback: TypeError: undefined is not a function
    at route.onBeforeAction (http://wsdev.local:3000/packages/accounts-entry.js?913ad2d242cee193ec76a0c8505c3a3ce0e303c1:1716:19)
    at RouteController.runHooks (http://wsdev.local:3000/packages/iron-router.js?e9fac8016598ea034d4f30de5f0d356a9a24b6c5:827:16)
    at http://wsdev.local:3000/packages/iron-router.js?e9fac8016598ea034d4f30de5f0d356a9a24b6c5:2150:14
    at http://wsdev.local:3000/packages/iron-router.js?e9fac8016598ea034d4f30de5f0d356a9a24b6c5:2098:21
    at callWithNoYieldsAllowed (http://wsdev.local:3000/packages/deps.js?91f1235baecd83915f7d3a7328526dbba41482be:87:5)
    at _assign._compute (http://wsdev.local:3000/packages/deps.js?91f1235baecd83915f7d3a7328526dbba41482be:225:7)
    at new Deps.Computation (http://wsdev.local:3000/packages/deps.js?91f1235baecd83915f7d3a7328526dbba41482be:157:10)
    at Object._assign.autorun (http://wsdev.local:3000/packages/deps.js?91f1235baecd83915f7d3a7328526dbba41482be:377:13)
    at http://wsdev.local:3000/packages/iron-router.js?e9fac8016598ea034d4f30de5f0d356a9a24b6c5:2148:12
    at http://wsdev.local:3000/packages/iron-router.js?e9fac8016598ea034d4f30de5f0d356a9a24b6c5:2098:21 

Which points to the last line of this:

this.route('entrySignOut', {
    path: '/sign-out',
    onBeforeAction: function() {
      Session.set('entryError', void 0);
      if (AccountsEntry.settings.homeRoute) {
        Meteor.logout(function() {
          return Router.go(AccountsEntry.settings.homeRoute);
        });
      }
      return this.pause();
    }

Using Meteor 0.8.1.3, accounts-entry 0.7.3, iron-router 0.7.1.

@benmgreene
Copy link
Contributor

Just looks like we need to add pause as the parameter to the onBeforeAction function. But it seems like everyone in these threads knew that, so is there a reason it wasn't done?

@benmgreene
Copy link
Contributor

Just to confirm, the required change is in the master branch, but has not yet made it to release (i.e., it is not in 0.7.3).

@queso
Copy link
Contributor

queso commented Jul 9, 2014

You can point to master in your smart.json.

Honestly, it hasn't been released because I need to update docs and changelogs and haven't sat down to do it.

  "accounts-entry": {
    "git": "https://github.com/Differential/accounts-entry.git",
    "branch": "master"
  },

@benmgreene
Copy link
Contributor

No worries, just didn’t want to reinvent the “oh, wait…”

Switching to master has unfortunately resulted in:

Your app is crashing. Here's the latest log.

=> Errors prevented startup:

While building package `accounts-entry`:
error: no such package: 'simple-form'
error: no such package: 'sha'

=> Your application has errors. Waiting for file change.

There is no sha package in atmosphere… thoughts? Thanks!

On Jul 9, 2014, at 12:09 PM, Josh Owens notifications@github.com wrote:

You can point to master in your smart.json.

Honestly, it hasn't been released because I need to update docs and changelogs and haven't sat down to do it.

"accounts-entry": {
"git": "https://github.com/Differential/accounts-entry.git",
"branch": "master"
},

Reply to this email directly or view it on GitHub.

@queso
Copy link
Contributor

queso commented Jul 9, 2014

Upgrade to 0.8.2 :)

@queso
Copy link
Contributor

queso commented Jul 9, 2014

Upgrade meteor, that is.

@benmgreene
Copy link
Contributor

I was under the impression iron-router wasn’t compatible with Meteor 0.8.2 yet — I guess I’m wrong on that? Good to know.

On Jul 9, 2014, at 12:13 PM, Josh Owens notifications@github.com wrote:

Upgrade meteor, that is.


Reply to this email directly or view it on GitHub.

@queso
Copy link
Contributor

queso commented Jul 9, 2014

Do you have a specific issue that Iron Router is having with 0.8.2?

@benmgreene
Copy link
Contributor

Nope, based on the iron-router chatter, I didn’t even try it — was waiting to see a new release from iron-router saying they were ready for it.

On Jul 9, 2014, at 12:15 PM, Josh Owens notifications@github.com wrote:

Do you have a specific issue that Iron Router is having with 0.8.2?


Reply to this email directly or view it on GitHub.

@benmgreene
Copy link
Contributor

Upgraded Meteor to 0.8.2, no problems. Thanks much — happy to be using accounts-entry now.

On Jul 9, 2014, at 12:15 PM, Ben Greene ben.m.greene@gmail.com wrote:

Nope, based on the iron-router chatter, I didn’t even try it — was waiting to see a new release from iron-router saying they were ready for it.

On Jul 9, 2014, at 12:15 PM, Josh Owens notifications@github.com wrote:

Do you have a specific issue that Iron Router is having with 0.8.2?


Reply to this email directly or view it on GitHub.

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

No branches or pull requests

7 participants