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 export when keyword preservation is enabled: Cannot read properties of null (reading 'find')) #807

Closed
6 tasks done
jcerjak opened this issue Jun 30, 2023 · 3 comments
Labels

Comments

@jcerjak
Copy link

jcerjak commented Jun 30, 2023

Checklist

  • I have looked into the README and have not found a suitable solution or answer.
  • I have looked into the documentation and have not found a suitable solution or answer.
  • I have searched the issues and have not found a suitable solution or answer.
  • I have upgraded to the latest version of this tool and the issue still persists.
  • I have searched the Auth0 Community forums and have not found a suitable solution or answer.
  • I agree to the terms within the Auth0 Code of Conduct.

Description

This is a similar issue as #763 (which was resolved also for me).

The error is slightly different:

$ a0deploy export -c config.json -f yaml -o config/
2023-06-30T11:58:07.489Z - info: Loading Auth0 Tenant Data
2023-06-30T11:58:07.755Z - info: Retrieving rules data from Auth0
2023-06-30T11:58:07.966Z - info: Retrieving rulesConfigs data from Auth0
2023-06-30T11:58:08.201Z - info: Retrieving hooks data from Auth0
2023-06-30T11:58:08.655Z - info: Retrieving pages data from Auth0
2023-06-30T11:58:08.911Z - info: Retrieving resourceServers data from Auth0
2023-06-30T11:58:09.156Z - info: Retrieving clients data from Auth0
2023-06-30T11:58:09.393Z - info: Retrieving databases data from Auth0
2023-06-30T11:58:09.619Z - info: Retrieving connections data from Auth0
2023-06-30T11:58:09.825Z - info: Retrieving tenant data from Auth0
2023-06-30T11:58:10.031Z - info: Retrieving emailProvider data from Auth0
2023-06-30T11:58:23.520Z - info: Retrieving emailTemplates data from Auth0
2023-06-30T11:58:23.796Z - info: Retrieving clientGrants data from Auth0
2023-06-30T11:58:24.171Z - info: Retrieving guardianFactors data from Auth0
2023-06-30T11:58:24.446Z - info: Retrieving guardianFactorProviders data from Auth0
2023-06-30T11:58:24.725Z - info: Retrieving guardianFactorTemplates data from Auth0
2023-06-30T11:58:24.943Z - info: Retrieving guardianPolicies data from Auth0
2023-06-30T11:58:25.204Z - info: Retrieving guardianPhoneFactorSelectedProvider data from Auth0
2023-06-30T11:58:25.548Z - info: Retrieving guardianPhoneFactorMessageTypes data from Auth0
2023-06-30T11:58:25.754Z - info: Retrieving roles data from Auth0
2023-06-30T11:58:26.220Z - info: Retrieving branding data from Auth0
2023-06-30T11:58:40.268Z - info: Retrieving prompts data from Auth0
2023-06-30T11:58:40.469Z - info: Retrieving migrations data from Auth0
2023-06-30T11:58:40.717Z - info: Retrieving actions data from Auth0
2023-06-30T11:58:46.775Z - info: Retrieving triggers data from Auth0
2023-06-30T11:58:47.216Z - info: Retrieving organizations data from Auth0
2023-06-30T11:58:47.483Z - info: Retrieving attackProtection data from Auth0
2023-06-30T11:58:47.712Z - info: Retrieving logStreams data from Auth0
2023-06-30T11:58:47.911Z - info: Retrieving customDomains data from Auth0
2023-06-30T11:58:48.117Z - info: Retrieving themes data from Auth0
2023-06-30T11:58:48.143Z - error: Problem running command export
2023-06-30T11:58:48.143Z - error: Problem loading tenant data from Auth0 TypeError: Cannot read properties of null (reading 'find')

The issue occurs only with keyword preservation enabled. However this looks like a different issue than #763, because here the issue appears to happen with themes, but this parameter is empty in my tenant.yaml (themes: [] ).

Expectation

I would like export to finish successfully, when AUTH0_PRESERVE_KEYWORDS is enabled.

Reproduction

See Description above, issue can be reproduced consistently.

Deploy CLI version

7.17.2

Node version

v18.12.1

@jcerjak jcerjak added the bug label Jun 30, 2023
@willvedd
Copy link
Contributor

willvedd commented Jul 6, 2023

Thanks for opening this issue. Though it appears that the themes handler is the epicenter of the problem, I believe it to occur further along the keyword preservation process, likely a missing null check. I'm not exactly sure what combination of local configuration and remote tenant configuration can cause this specific error, but I think I should be able to reverse-engineer or provide a fix at the very least. Unfortunately, I cannot offer any immediate workarounds. Please stay tuned.

@willvedd
Copy link
Contributor

@jcerjak I believe that I was able to recreate the specific scenario that triggers this runtime issue. We have provided a fix for it in 7.18.0. Please update and provide feedback if your issue remains.

@jcerjak
Copy link
Author

jcerjak commented Jul 18, 2023

Thanks, works now!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants