Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Getting "Couldn't infer metadata" type consistently on the conversion command from source to mdapi format for some of the newly-used SF Component Type #3181

Closed
Zenithoriumatic opened this issue Jan 16, 2025 · 13 comments
Labels
more information required Issue requires more information or a response from the customer

Comments

@Zenithoriumatic
Copy link

Getting "Couldn't infer metadata" type consistently on the conversion command from source to mdapi format for some of the newly-used SF Component Types that includes:

GenAiFunction
GenAiPlanner
GenAiPluggin
MessagingChannel, etc.

Note that we are using we tried every latest version till 61.0 configuring in sfdx.json, the issue remains the same.
We noticed that MessagingChannel is getting validated successfully (both through source as well as mdapi format) when done through SFDX CLI in local, but failed via CI/CD.

Having said that, we assumed the same for GenAi related components when done locally, but it failed in both source and mdapi, both when done locally and through CI/CD.

Kindly assist on this matter urgently, thanks.

Best Regards,
Utkarsh

Image
@Zenithoriumatic Zenithoriumatic added the investigating We're actively investigating this issue label Jan 16, 2025
Copy link

Hello @Zenithoriumatic 👋 It looks like you didn't include the full Salesforce CLI version information in your issue.
Please provide the output of version --verbose --json for the CLI you're using (sf or sfdx).

A few more things to check:

  • Make sure you've provided detailed steps to reproduce your issue.
    • A repository that clearly demonstrates the bug is ideal.
  • Make sure you've installed the latest version of Salesforce CLI. (docs)
    • Better yet, try the rc or nightly versions. (docs)
  • Try running the doctor command to diagnose common issues.
  • Search GitHub for existing related issues.

Thank you!

Copy link

Thank you for filing this issue. We appreciate your feedback and will review the issue as soon as possible. Remember, however, that GitHub isn't a mechanism for receiving support under any agreement or SLA. If you require immediate assistance, contact Salesforce Customer Support.

@github-actions github-actions bot added more information required Issue requires more information or a response from the customer and removed investigating We're actively investigating this issue labels Jan 16, 2025
@Zenithoriumatic
Copy link
Author

Awaiting any response on this matter!

@mdonnalley
Copy link
Contributor

@Zenithoriumatic According to our metadata support, those types should be supported. It's possible that you're using an older version of sf that doesn't know about those types. Can you provide the version of sf that you're using? sf version --verbose?

@Zenithoriumatic
Copy link
Author

  • sf version --verbose
    You acknowledge and agree that the CLI tool may collect usage information, user environment, and crash reports for the purposes of providing services or functions that are relevant to use of the CLI tool and product improvements.
    CLI Version:
    @salesforce/cli/1.86.7-legacy.0
    Architecture:
    linux-x64
    Node Version:
    node-v18.15.0
    Plugin Version:
    @oclif/plugin-autocomplete 2.3.1 (core)
    @oclif/plugin-commands 2.2.17 (core)
    @oclif/plugin-help 5.2.11 (core)
    @oclif/plugin-not-found 2.3.26 (core)
    @oclif/plugin-plugins 3.1.6 (core)
    @oclif/plugin-search 0.0.18 (core)
    @oclif/plugin-update 3.1.22 (core)
    @oclif/plugin-version 1.3.6 (core)
    @oclif/plugin-warn-if-update-available 2.0.41 (core)
    @oclif/plugin-which 2.2.22 (core)
    @salesforce/cli 1.86.7-legacy.0 (core)
    apex 2.3.4 (core)
    auth 2.8.4 (core)
    data 2.4.5 (core)
    deploy-retrieve 1.13.5 (core)
    info 2.6.30 (core)
    limits 2.3.23 (core)
    login 1.2.15 (core)
    org 2.9.19 (core)
    schema 2.3.17 (core)
    settings 1.4.17 (core)
    sobject 0.1.32 (core)
    source 2.10.22 (core)
    telemetry 2.2.1 (core)
    templates 55.5.2 (core)
    trust 2.4.27 (core)
    user 2.3.20 (core)
    OS and Version:
    Linux 6.1.79
    Shell:
    bash
    Root Path:
    /usr/local/lib/nodejs/lib/node_modules/@salesforce/cli

Copy link

Hello @Zenithoriumatic 👋

It looks like you're using an outdated version of Salesforce CLI. sf (v1) is in "maintenance mode" as of July 12, 2023. We highly recommend you move from sf (v1) to sf (v2) ASAP.

Moving to sf (v2) is easy and takes just two commands. Find all the information here.

After you move to the latest version of sf (v2), run your command again and provide the output of sf version --verbose --json.

@Zenithoriumatic
Copy link
Author

Am already on sf (v2). Pls refer to the attested snippet.

Image

@mdonnalley
Copy link
Contributor

@Zenithoriumatic 2.16.10 is over a year old at this point. Try using latest - 2.72.21

@Zenithoriumatic
Copy link
Author

The thing is we use docker image, can we update sf version within the image, not right?

@Zenithoriumatic
Copy link
Author

This is the image we leverage: image: salesforce/salesforcedx:latest-full

@Zenithoriumatic
Copy link
Author

Do you recommend any latest docker image to be kept in our yaml script which should put sf latest version in use while performing validation and deployment?

@mdonnalley
Copy link
Contributor

I don't think that docker image is maintained anymore. Take a look at our docs on docker images: https://developer.salesforce.com/docs/atlas.en-us.sfdx_setup.meta/sfdx_setup/sfdx_setup_docker.htm

@Zenithoriumatic
Copy link
Author

Well, I've updated my docker image to the one mentioned in your provided resource and you know what, it worked.
salesforce/cli:latest-slim - this image worked and yes, this is allowing the convert command to be an operable one and the relevant pkg.xml is getting generated.

Thankful to your reverts to my on-demand asks, much appreciated.
Keeping the thread open for a day or so, in case of any assistance on the same, thanks again.

Best Regards,
Utkarsh

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
more information required Issue requires more information or a response from the customer
Projects
None yet
Development

No branches or pull requests

2 participants