Unable to find package 'Microsoft.Graph.GraphServiceClient' is not defined

Hi

I am trying to publish a new library activity which uses o365 and I am getting the following error:

Workflow ‘XXXXX’ has the following compilation errors:
Type ‘Microsoft.Graph.GraphServiceClient’ is not defined.

image
I am unable to find this in manage packages.

I have installed:
Microsoft.Graph (v1.12.0)
Microsoft Graph.Core (v1.12.0)
Microsoft.Identity.Client (Microsoft Authentication Library for .Net) (v2.7.1)

Any advice is appreciated.

Cheers

@Steven_McKeering

Are you publishing the custom library built in .net or built in UiPath?

Cheers

Hey @Anil_G

I have built it in UiPath.

@Steven_McKeering

What authetication are you using…if its integration services than I think library is not an option

Cheers

Are you referring to authentication for O365?
If so, its ‘UsernameAndPassword’.

@Steven_McKeering

Which version of o365 is it?

Did you try changing the version of it…

And you need not ideally install any other packages…they shpuld be present…is o365 2.1+?

Cheers

UiPath.MicrosoftOffice365.Activities - v1.3.0

Tried v1.6 and v1.11.1 and getting the same error.
Workflow ‘XXXXX’ has the following compilation errors:
Type ‘Microsoft.Graph.GraphServiceClient’ is not defined.

@Steven_McKeering

Can you try removing the project.json and reload

Alternately try deeting the package from .nuget folder in userprofile and then refownload the package

As we are using the same 1.11.1 and never faced an issue

Any recent orchestrator upgrades or atudio upgrades? Till 22.10 i can confirm it would work as expected on 1.11.1

Cheers

Removing the project.json and reloading did the trick.

Thanks @Anil_G :clap:

But unfortunately UiPath now thinks this is a normal package and not a library. What do I need to do get UiPath to ‘see’ it as a Library?

edit:
Do I just swap the highlight from ‘Process’ to ‘Library’. Is it that simple?
image

Unfortunately the message has returned.

I will keep digging.
image

No recent orchestrator upgrades or studio upgrades. We are upgrading very soon to 22.10.

@Steven_McKeering

Is it possible to share the workflow …so that we csn check from our end

Cheers

Hey @Anil_G

Please take a look.
o365.Get_Mail.xaml (35.6 KB)

Hi @Steven_McKeering

I think it might be something to do with the dependency conflicts :confused:

What is strange though - your file compiled for me in a Library Legacy project on latest Community Studio 23.4, which might mean that this was fixed on the Studio side.

Would you mind sharing your versions of the System package? Also, trying to downgrade/upgrade both packages to their latest stable versions (and maybe even latest preview, if needed).

I would also stick to the minimum amount of packages needed for test purpose.

1 Like

Hey @loginerror

Thank you for your assistance.

Here is a screenshot of the Manage Packages window. (Is that what you were referring to?)

Studio version:
image

Orchestrator version:
image

We are upgrading to 22.10 very soon :sweat_smile:

@Anil_G

1 Like

It is an older version of the System package and Studio. There is a high chance that this bug was indeed already fixed in the new Studio version.

For the record, I tried to reproduce this issue with the same package versions (but just System and O365 one) on the latest Studio Community 2023.4.0 and I was not able to reproduce it anymore.

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.