You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
app.enableAuth should fail when models are not configured correctly #171
@raymondfeng I disagree, this issue is not resolved. The error should be raised at the time you call app.enableAuth (during startup), not at the time the first request arrives. I am reopening this issue.
In #1323, we added an option to enableAuth to auto-attach any missing auth models to a given data-source. When this option is set, enableAuth will validate that all required models are present and attached to a data source.
However, when the option is not present, the validation is skipped.
I am proposing to modify enableAuth to run the validation even when the new option is not set. This may break existing applications (although it's not very likely), let's make this change in 3.0 only.
@bajtos : thanks for bringing this to my attention !
(Gosh we are traveling through time here! 3 years back you were discussing this already, seems like things happen eventually :-) )
I am proposing to modify enableAuth to run the validation even when the new option is not set. This may break existing applications (although it's not very likely), let's make this change in 3.0 only.
👍
Do we implement this right away, or do we use a feature-flag?
IMO: i don't see valid use cases where enableAuth() is called, models are not set up, and the app is fully functional. So i'd go without a feature-flag.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
This issue has been closed due to continued inactivity. Thank you for your understanding. If you believe this to be in error, please contact one of the code owners, listed in the CODEOWNERS file at the top-level of this repository.
Activity
bajtos commentedon Feb 5, 2014
#158 is attacking the same problem from a different side.
raymondfeng commentedon Jul 23, 2014
PersistedModel is now the base class that reports errors if the model is not attached to a data source
bajtos commentedon Jul 24, 2014
@raymondfeng I disagree, this issue is not resolved. The error should be raised at the time you call
app.enableAuth(during startup), not at the time the first request arrives. I am reopening this issue.bajtos commentedon Apr 7, 2016
In #1323, we added an option to
enableAuthto auto-attach any missing auth models to a given data-source. When this option is set,enableAuthwill validate that all required models are present and attached to a data source.However, when the option is not present, the validation is skipped.
I am proposing to modify
enableAuthto run the validation even when the new option is not set. This may break existing applications (although it's not very likely), let's make this change in 3.0 only.5 remaining items
bajtos commentedon Mar 23, 2017
@ebarault PTAL, this may be something to consider in your current work on verifying auth setup.
ebarault commentedon Mar 23, 2017
@bajtos : thanks for bringing this to my attention !
(Gosh we are traveling through time here! 3 years back you were discussing this already, seems like things happen eventually :-) )
👍
Do we implement this right away, or do we use a feature-flag?
IMO: i don't see valid use cases where enableAuth() is called, models are not set up, and the app is fully functional. So i'd go without a feature-flag.
stale commentedon Aug 27, 2017
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
stale commentedon Sep 11, 2017
This issue has been closed due to continued inactivity. Thank you for your understanding. If you believe this to be in error, please contact one of the code owners, listed in the
CODEOWNERSfile at the top-level of this repository.