GithubHelp home page GithubHelp logo

Comments (7)

benjackson avatar benjackson commented on September 18, 2024

Hey @jelmerderonde. It would be good to know some more details about the error. Perhaps you could paste a gist showing it? Or a bare minimum example project that makes the error happen because the tests for Devise with neo4j all seem to be passing fine.

If you just wanted a quick-ish fix, you could try extending Recoverable and overwriting the after_password_reset method (which is empty in Devise's Recoverable module), to set whatever you need in order for the error not to occur.

from devise-activegraph.

jelmerderonde avatar jelmerderonde commented on September 18, 2024

Hi @benjackson,

Thanks for the quick reply. A gist showing the rails server output when the error occurs: https://gist.github.com/jelmerderonde/2930788bfed7b80f4b2b

A minimum project would frankly be just rails, neo4j and devise-neo4j, with a single User resource with the Recoverable module. When a user tries to reset their password, because devise tries to set the reset_sent_at to nil which is not accepted.

I did some more research and I think it might be because of this commit in neo4jrb:
neo4jrb/activegraph@f8689b5#diff-3fa03f2e2089eba3ae28988a375ac16a

However I'm not sure of this. I will try to implement the fix you mentioned, but if you have any suggestion on what I can do to implement a more complete fix let me know.

from devise-activegraph.

subvertallchris avatar subvertallchris commented on September 18, 2024

Sorry for coming into this a little late. I'm still a little unsure about how it's getting to the point that it can try to convert a nil value. Do we know where reset_sent_at is defined?

from devise-activegraph.

jelmerderonde avatar jelmerderonde commented on September 18, 2024

@subvertallchris I think it is here:
https://github.com/plataformatec/devise/blob/master/lib/devise/models/recoverable.rb

line 85

from devise-activegraph.

benjackson avatar benjackson commented on September 18, 2024

@jelmerderonde I haven't tried a real example yet, but any idea why this integration test that gets run as part of all the devise tests wouldn't suffer from the same issue you're seeing?:

https://github.com/plataformatec/devise/blob/master/test/integration/recoverable_test.rb

from devise-activegraph.

jelmerderonde avatar jelmerderonde commented on September 18, 2024

@benjackson is there a way I can run these tests in the context of my app? I will take a look at it.

from devise-activegraph.

benjackson avatar benjackson commented on September 18, 2024

@jelmerderonde you could just recreate the integration test that covers the functionality that is breaking for you, but that might still be something attributable to your app rather than the gem.

If you're able to create an example in a public repo, with a failing integration test, I'd be happy to take a look and see if I can figure out why the Devise test doesn't capture the same problem.

from devise-activegraph.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.