Error with "SMTP end Email (V2)" - azure-logic-apps

When I select "SMTP end Email (V2)" I immediately get the error "Unable to get property 'parameters' of undefined or null reference". I know it's a preview, but I assume that it should be working.

Should be - have alerted the team. In the future for bugs feel free to email team directly at logicappsbug[at]microsoft[dot]com

Related

Calling /connect/userinfo return error "Unhandled exception: Sequence contains more than one matching element"

I am using IdentityServer4, AspnetCore 2.1 and angular 6 client
Everything is working fine except the call to the userinfo endpoint
Looking through my log I found the following lines that I thought could be pointers to how to deal with the error. So far I havent been sucessfully
StsServerIdentity> Profile service returned the following claim
types: sub name given_name family_name email role sub role role role
preferred_username email email_verified
StsServerIdentity> crit:
IdentityServer4.Hosting.IdentityServerMiddleware[0]
StsServerIdentity> Unhandled exception: Sequence contains more
than one matching element
StsServerIdentity> System.InvalidOperationException: Sequence contains
more than one matching element
StsServerIdentity> at System.Linq.Enumerable.SingleOrDefault[TSource]
(IEnumerable`1 source, Func`2 predicate)
looking forward to some guidance
Thanks
Looks you are using a 3rd party solution and it has it's own IProfileService implementation where sub claim is added twice and not distincted. You could either try to debug or distinct the sub claims (as that's a primary user identifier and must be unique), or try the original quickstarts.

Powerapps Office365Users.UserPhoto failed

Making a Powerapps Leave Request app. I can get all user and manager info, but when I try to obtain a user or manager photo, I get this error:
Office365Users.UserPhoto failed: {
"status":404,
"message": "No user found with the specified id...."
...
"source": "office365users-eus.azconn-eus.p.azukrewebsites.net"
}
Here's the troubleshooting strategies I'd take to resolve your issue:
Find out what User().Email is actually showing--insert a label and set it to that expression.
User().Email
Manually type in the expected email address into Office365Users.UserPhoto function. What comes out?
Office365Users.UserPhoto("name#email.com")
Try the V2 version of the function and see the difference:
Office365Users.UserPhotoV2(User().Email)
Alternatively, collect User().Email to a variable:
Set(userEmail, User().Email)
Then reference the variable instead of the User().Email function:
Office365Users.UserPhotoV2(userEmail)
Let me know if that is helpful.
Try using the id that you get on the MyProfile (or MyProfileV2) function of the Office365Users connector:
Office365Users.UserPhotoV2(Office365Users.MyProfileV2().id)
Since the id came from the same connector of the UserPhotoV2 operation, you should not have the error that the id was not found.
try
If(!IsBlank(ThisItem.userprincipalname),Office365Users.UserPhotoV2(ThisItem.userprincipalname),SampleImage)
Office365Users.UserPhotoV2(User().Email) , this worked for me

GMail API: Not Found (404) errors when calling retrieving drafts with drafts.get from ids supplied by drafts.list

In the Gmail API quite frequently drafts.list will return a draft id
but when I pass it to drafts.get it returns a 404 error. This is
repeatable for certain draft ids, I can call drafts.list again and
they're still there and I can then call drafts.get and get the same
error again. I can also call messages.get with the given message id
and get a response as expected and I can see the draft in the gmail client.
Seems to be a bug in the GMail API. Any ideas for workarounds? And does anyone know the right way to report bugs to Google?
I'm getting the same issue, here is how to reproduce:
1) Start writing a new message in the Gmail web client. Don't add anything in the To field or the Body. Then close the message to save it as a Draft.
2) Retrieve a list of threads with the following code:
threads = gmail_client.users().threads().list(userId='me', maxResults=15, pageToken=pageToken, q='-in:(chats OR draft) in:all').execute()
4) Then retrieve each of these threads in a batch request:
batch.add(gmail_client.users().threads().get(userId='me', id=thread['id'], format='metadata', metadataHeaders=['subject','date','to','from']), callback=threadCallback)
The error that gets returned is:
https://www.googleapis.com/gmail/v1/users/me/threads/154e44a4c80ec7e4?format=metadata&metadataHeaders=subject&metadataHeaders=date&metadataHeaders=to&metadataHeaders=from&alt=json returned "Not Found">
In order to use drafts.get, you should use immutable id of the draft, not the message id of the draft which will change after each update in draft. Drafts.list supplies both immutable id and the message id of the messages in the draft.

Why would I get Login Required for Calendar List Query but not for Calendar Queries

Why would:
events = calservice.events().list(calendarId='CAL_ID#group.calendar.google.com', singleEvents='true', showDeleted='false', timeMin='{:%Y-%m-%dT%H:%M:%SZ}'.format(now), timeMax='{:%Y-%m-%dT%H:%M:%SZ}'.format(nowplusonemin)).execute(http=decorator.http())
https://www.googleapis.com/calendar/v3/calendars/CAL_ID#group.calendar.google.com/events?timeMax=2013-06-12T11%3A04%3A09Z&showDeleted=true&alt=json&singleEvents=true&timeMin=2013-06-12T11%3A03%3A09Z
work and return me the events for the requested query but:
calendar_list = calservice.calendarList().list(pageToken=page_token).execute()
Give me a Login Required error:
<HttpError 401 when requesting https://www.googleapis.com/calendar/v3/users/me/calendarList?alt=json returned "Login Required">
The SCOPE should give me access to both I believe:
SCOPE='https://www.googleapis.com/auth/calendar'
So I missed the http=decorator.http() from the execute().

Trigger a 404 error with CakePHP 2.0?

I've been reading CakePHP's 2.0 migration guide where it's stated that cakeError() has been removed because it was used for exceptions. It's a really weird change IMHO because I used it to block access to unauthorized users or to trigger an error when the paginated items exceeded the total, and things like that.
And now what? Should I just throw a die() or a redirect? I really want to let know the users that something was not found and Cake used to provie a stright way to do so... now it doesn't.
Any thoughts/hacks/workarounds about it? Thanks, happy holidays!
You have to throw the corresponding exception, in your case the NotFoundException:
throw new NotFoundException();
See also the chapter about exceptions in the cook book.
try this
if ($this->Session->read('Auth.User.role') == 'P' || $this->Session->read('Auth.User.role') == 'U') {
//die('you are not allowed to access this page');
//throw new ForbiddenException;
throw new NotFoundException('404 Error - Page not found');
}

Resources