0

I'm not sure where to look to help me troubleshoot this issue.

I've tried reinstalling the CLI - logging out and logged back into the orgs. When I use the same sfdx:force:create command as a different user I'm not getting this issue, but as far as I can tell the only difference between the two users are the access codes found in ~/.sfdx/{orgname}.json

Any ideas?

This is a summary of the logs (could it be due to JWT workflow- I'm thinking to try web auth next):

{
   "name":"sfdx",
   "hostname":"host",
   "pid":14098,
   "log":"OrgCreateCommand",
   "level":30,
   "msg":"Running command [OrgCreateCommand] with flags [{\"definitionfile\":\"project-scratch.json-my\",\"durationdays\":1,\"loglevel\":\"debug\",\"setalias\":\"host_project-scratch_1\",\"type\":\"scratch\",\"wait\":{\"quantity\":6,\"unit\":0}}] and args [{}]",
   "time":"2020-05-22T22:02:51.106Z",
   "v":0
}
{
  "name":"sfdx",
  "hostname":"host",
  "pid":14913,
  "log":"scratchOrgInfoApi",
  "level":20,
  "msg":"_authorize - scratchOrgInfoComplete: {---redacted (but had all the scratch org info)---}",
  "time":"2020-05-22T22:34:32.778Z",
  "v":0
}
{
  "name":"sfdx",
  "hostname":"host",
  "pid":14913,
  "log":"scratchOrgInfoApi",
  "level":20,
  "msg":"_authorize - isJwtFlow: true",
  "time":"2020-05-22T22:34:32.796Z",
  "v":0
}
{
  "name":"sfdx",
  "hostname":"host",
  "pid":14913,
  "log":"scratchOrgInfoApi",
  "level":20,
  "msg":"_authorize - oauthConfig: {---redacted (but contained all the login info)---}",
  "time":"2020-05-22T22:34:32.797Z",
  "v":0
}
{
   "name":"sfdx",
   "hostname":"host",
   "pid":14636,
   "log":"OrgCreateCommand",
   "level":50,
   "msg":"[ 'ERROR running force:org:create: ',\n  'Cannot read property \\'details\\' of undefined' ]",
   "time":"2020-05-22T22:16:23.731Z",
   "v":0
}
2
  • Do both the users have same set of profiles and permission sets ? Also what happens when you provide loglevel param as trace ? Commented May 23, 2020 at 0:00
  • to clarify - when I mentioned users I meant users on the machine. Both users are logged in as the same user to the salesforce org - although the auth for one is using web the other is jwt. Commented May 23, 2020 at 19:19

2 Answers 2

0

Seemed that my problem was caused because I had initially authenticated to the org using jwt... than at a later date re-authenticated to the org via web.

Logging out and authenticating using jwt resolved my issue.

0

I was also running into this issue. I tried logging out and logging back into the org, as well as updating SFDX, uninstalling and reinstalling. None of these resolved the issue. Finally, when I tried to do a force:source:push to another org, I got an error indicating that .sfdx/stash.json had invalid json in it, and sure enough it had an extra "}" at the end. Once I fixed that, both force:source:push and force:org:create worked.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .