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

Authorization isn't working properly #138

Closed
2 tasks done
M7MDE7EGAZY opened this issue May 11, 2022 · 66 comments · Fixed by #208
Closed
2 tasks done

Authorization isn't working properly #138

M7MDE7EGAZY opened this issue May 11, 2022 · 66 comments · Fixed by #208
Labels
triage/needs-more-info This issue/PR needs more infomation. type/bug This issue reports an unwanted behavior.

Comments

@M7MDE7EGAZY
Copy link

Before you start...

  • Have you updated the FluentHub? You might be using an old version.
  • Have you checked if similar issue have already been reported?

What windows are you seeing the problem on?

Windows 11 Dev

What FluentHub version/architecture are you seeing the problem on?

0.3.0
X64

Description

The Authorization isn't working

Steps To Reproduce

No response

Expected behavior

The Authorization must work to login

Relevant Assets

No response

@M7MDE7EGAZY M7MDE7EGAZY added the type/bug This issue reports an unwanted behavior. label May 11, 2022
@0x5bfa 0x5bfa added triage/needs-more-info This issue/PR needs more infomation. Pri: High labels May 11, 2022
@0x5bfa
Copy link
Owner

0x5bfa commented May 11, 2022

Can you paste log files or log screenshots?

@M7MDE7EGAZY
Copy link
Author

Screenshot 2022-05-11 122612

@0x5bfa
Copy link
Owner

0x5bfa commented May 11, 2022

can you rebuild with deleting all chaches(by solution cleaning or re-clone).

@M7MDE7EGAZY
Copy link
Author

i'll try

@0x5bfa 0x5bfa changed the title Authorization isn't working 0.3.0 Authorization isn't working properly May 11, 2022
@0x5bfa
Copy link
Owner

0x5bfa commented May 11, 2022

on my machine, good work. so this is a not general issue.

@0x5bfa
Copy link
Owner

0x5bfa commented May 15, 2022

@M7MDE7EGAZY Any progress?

@M7MDE7EGAZY
Copy link
Author

nothing new , i'll try after exams again

@HelderRocket
Copy link

It also happens in Windows 10, the store version.
It does not advance from this screen.

image

@M7MDE7EGAZY
Copy link
Author

It also happens in Windows 10, the store version. It does not advance from this screen.

yes tried many times always not working

@0x5bfa
Copy link
Owner

0x5bfa commented May 21, 2022

@M7MDE7EGAZY @HelderRocket Can you show me logs in FluentHub.Logs and FluentHub.Octokit.Logs?

@0x5bfa 0x5bfa pinned this issue May 21, 2022
@BobbyESP
Copy link
Collaborator

Screenshot 2022-05-11 122612

I think this happened to us before @onein528

@0x5bfa
Copy link
Owner

0x5bfa commented May 21, 2022

right. but suddenly fixed that at that time. at this time, suddenly appear this issue. very wierd. this is not our project's issue(maybe Octokit.NET issue).

@BobbyESP
Copy link
Collaborator

Yeah, maybe it's... When i finish my exams i would take a look

@0x5bfa
Copy link
Owner

0x5bfa commented May 21, 2022

ok

@HelderRocket
Copy link

@M7MDE7EGAZY @HelderRocket ¿Puede mostrarme registros en FluentHub.Logs y FluentHub.Octokit.Logs?

How do I do this?
😅😅

@0x5bfa
Copy link
Owner

0x5bfa commented May 21, 2022

@M7MDE7EGAZY

downloaded from Store: C:\Users\username\AppData\Local\Packages\49462fluenthub-uwp.FluentHub_tq8wa33sfftnm\LocalState

build from source: C:\Users\username\AppData\Local\Packages\FluentHubAlpha_9es9q7t8fr9b8\LocalState

@0x5bfa
Copy link
Owner

0x5bfa commented May 21, 2022

Why is there difference.

image

@HelderRocket
Copy link

2022-05-18 16:31:38.572 -05:00 [ERR] RequestOAuthTokenAsync(): Select() is not supported
2022-05-18 16:33:06.703 -05:00 [INF] RequestGitHubIdentityAsync() completed successfully: [url: "https://github.com/login/oauth/authorize?client_id=0c0d30a8cbd9465373e2&scope=repo%2Cworkflow%2Cwrite%3Apackages%2Cdelete%3Apackages%2Cadmin%3Aorg%2Cadmin%3Apublic_key%2Cadmin%3Arepo_hook%2Cadmin%3Aorg_hook%2Cgist%2Cnotifications%2Cuser%2Cdelete_repo%2Cwrite%3Adiscussion%2Cadmin%3Aenterprise%2Cadmin%3Agpg_key"]
2022-05-18 16:33:09.561 -05:00 [INF] App.InitializeAsync() done
2022-05-18 16:33:09.961 -05:00 [ERR] RequestOAuthTokenAsync(): Select() is not supported
2022-05-18 16:34:37.754 -05:00 [ERR] RequestOAuthTokenAsync(): Select() is not supported
2022-05-18 16:35:38.569 -05:00 [INF] RequestGitHubIdentityAsync() completed successfully: [url: "https://github.com/login/oauth/authorize?client_id=0c0d30a8cbd9465373e2&scope=repo%2Cworkflow%2Cwrite%3Apackages%2Cdelete%3Apackages%2Cadmin%3Aorg%2Cadmin%3Apublic_key%2Cadmin%3Arepo_hook%2Cadmin%3Aorg_hook%2Cgist%2Cnotifications%2Cuser%2Cdelete_repo%2Cwrite%3Adiscussion%2Cadmin%3Aenterprise%2Cadmin%3Agpg_key"]
2022-05-18 16:35:39.887 -05:00 [INF] App.InitializeAsync() done
2022-05-18 16:35:40.317 -05:00 [ERR] RequestOAuthTokenAsync(): Select() is not supported
2022-05-18 16:35:49.322 -05:00 [ERR] RequestOAuthTokenAsync(): Select() is not supported

@0x5bfa
Copy link
Owner

0x5bfa commented May 21, 2022

@HelderRocket From ms store?

same issue occuring.

@Mabc365
Copy link

Mabc365 commented May 21, 2022

same issue for me too

@HelderRocket
Copy link

Yes, it is the store version (I have the old version because I recently restored the computer).

image

@0x5bfa
Copy link
Owner

0x5bfa commented May 21, 2022

I will implement authorization service without using Octokit.Net. Also use raw http request.

@0x5bfa
Copy link
Owner

0x5bfa commented May 21, 2022

Then, i will publish app package, same as store version, can yall be tester?

@BobbyESP
@M7MDE7EGAZY
@Mabc365
@HelderRocket
@luandersonn
@DeveloperWOW64

@0x5bfa
Copy link
Owner

0x5bfa commented May 28, 2022

nice idea. i can.

@Lamparter
Copy link
Collaborator

nice idea. i can.

It was your idea

@0x5bfa
Copy link
Owner

0x5bfa commented May 28, 2022

More specific

2022-05-28 23:03:39.067 +09:00 [ERR] LoadHomeContentsAsync
System.NotSupportedException: Select() is not supported
   at Octokit.GraphQL.Core.Builders.QueryBuilder.RewriteListExtension(MethodCallExpression, MemberInfo) + 0x11e6
   at Octokit.GraphQL.Core.Builders.QueryBuilder.VisitMethodCall(MethodCallExpression, MemberInfo) + 0x9a
   at Octokit.GraphQL.Core.Builders.QueryBuilder.VisitMethodCall(MethodCallExpression) + 0xb
   at System.Linq.Expressions.MethodCallExpression.Accept(ExpressionVisitor) + 0x16
   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression) + 0x18
   at Octokit.GraphQL.Core.Builders.QueryBuilder.Build[TResult](IQueryableList`1) + 0x5a
   at FluentHub.Octokit.Queries.Users.RepositoryQueries.<GetAllAsync>d__1.MoveNext() + 0x1d53
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x21
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0x70
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task) + 0x38
   at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task) + 0x17
   at FluentHub.ViewModels.Home.UserHomeViewModel.<LoadHomeContentsAsync>d__14.MoveNext() + 0x1a0

2022-05-28 23:03:42.918 +09:00 [ERR] MainPageViewModel.GetSignedInUser(): 
System.NotSupportedException: Select() is not supported
   at Octokit.GraphQL.Core.Builders.QueryBuilder.RewriteValueExtension(MethodCallExpression, MemberInfo) + 0x6b8
   at Octokit.GraphQL.Core.Builders.QueryBuilder.VisitMethodCall(MethodCallExpression, MemberInfo) + 0x56
   at Octokit.GraphQL.Core.Builders.QueryBuilder.VisitMethodCall(MethodCallExpression) + 0xb
   at System.Linq.Expressions.MethodCallExpression.Accept(ExpressionVisitor) + 0x16
   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression) + 0x18
   at Octokit.GraphQL.Core.Builders.QueryBuilder.Build[TResult](IQueryableValue`1) + 0x40
   at FluentHub.Octokit.Queries.Users.UserQueries.<GetAsync>d__1.MoveNext() + 0xd66
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x21
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0x70
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task) + 0x38
   at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task) + 0x17
   at FluentHub.ViewModels.MainPageViewModel.<LoadSignedInUserAsync>d__75.MoveNext() + 0x142

@0x5bfa
Copy link
Owner

0x5bfa commented May 28, 2022

@DeveloperWOW64 Experiment with GU10 latest commit Experimental commit

Artifacts here: https://fluenthub-community.visualstudio.com/FluentHub/_build/results?buildId=749&view=artifacts&pathAsName=false&type=publishedArtifacts

@HelderRocket
Copy link

It worked!
Well, in part.

image

It does not load anything, not even by link.

@0x5bfa
Copy link
Owner

0x5bfa commented May 28, 2022

yes, so do I. So this is not auth problem and also not FluentHub problem. just Linq problem. maybe missing assemblies for System.Linq.

@0x5bfa
Copy link
Owner

0x5bfa commented Jun 2, 2022

I should notice. Currently, I decided to abandon the option to publish to ms store and github releases(not now). I could not solve this issue. but some progress there is. this issue is not auth problem and is caused by Select() - one of the Linq extention methods - in Octokit.GraphQL.Net
It seems that this is general issue, and so not only our app.

I have another option to this. but I have no time to switch to that option. sorry for any inconvenience.

Exception:

Select() is not supported

@HelderRocket
Copy link

Is that error something generated by the tool you use to compile the application?

Sorry, I'm not very knowledgeable about how UWP apps work (although it even occurred to me to make a UWP app for Facebook and YT Music).

Maybe that bug can be reported to the tool developer.

@0x5bfa
Copy link
Owner

0x5bfa commented Jun 3, 2022

Yes. I already reported to Octokit.GraphQL.net(is generated by this)

@0x5bfa
Copy link
Owner

0x5bfa commented Jun 3, 2022

octokit/octokit.graphql.net#262

but this project seems to be abandoned by owner(there are no activities these days)

@HelderRocket
Copy link

I see it's specifically geared towards Github libraries, so I don't think it's possible to do what I came up with.

@BobbyESP
Copy link
Collaborator

BobbyESP commented Jun 3, 2022

Maybe it's a good idea to mirror/fork the octokit library and fix the problem by ourselves

@0x5bfa
Copy link
Owner

0x5bfa commented Jun 4, 2022

what I came up with.

What is that.

@Lamparter
Copy link
Collaborator

Maybe it's a good idea to mirror/fork the octokit library and fix the problem by ourselves

How would we do that?

@BobbyESP
Copy link
Collaborator

BobbyESP commented Jun 6, 2022

Well, forking the repository in the GitHub FluentHub organization and building us the dll files from source

@0x5bfa
Copy link
Owner

0x5bfa commented Jun 6, 2022

the most problem is if we can fix that.

but I will try that.
FYI, it seems that Octokit.GraphQL.NET project was abandoned. no recent commits and response of issue/pr

@BobbyESP
Copy link
Collaborator

BobbyESP commented Jun 7, 2022

Okey nice. And suddenly yeah, i think that is abandoned

@Lamparter
Copy link
Collaborator

It seems difficult - but it's worth a try

@BobbyESP
Copy link
Collaborator

BobbyESP commented Jun 7, 2022

Sorry, it's the only thing that occurs to me, just to try.

These days i'm gonna return to work. Today, my school is going to give me the final marks.

@0x5bfa
Copy link
Owner

0x5bfa commented Jun 12, 2022

Hi all. @BobbyESP @M7MDE7EGAZY @Mabc365 @HelderRocket @luandersonn @DeveloperWOW64

Upon checking, there was no problem with authentication, and there was a problem with the code that was getting the user's information at the time of authentication. But this wasn't an exception caused by our code, it was caused by Octokit.GraphQL. So I reported it to the GitHub Octokit.GraphQL team on GitHub, but I think the project has been abandoned because I haven't received a reply for a week. We didn't want to use a non-maintainable project, and we came up with a new solution, but the cost of rewriting was huge and the code could be verbose. As a result, this project will not publish the release mode app package to the Microsoft Store or the release page on GitHub.

Thank you for all contribution or help!

onein528 6/12/2022

@0x5bfa
Copy link
Owner

0x5bfa commented Jun 12, 2022

And I specify this in the README.

@0x5bfa 0x5bfa closed this as not planned Won't fix, can't repro, duplicate, stale Jun 12, 2022
@BobbyESP
Copy link
Collaborator

Okey, thanks for the info!

@0x5bfa 0x5bfa unpinned this issue Jun 17, 2022
@Lamparter Lamparter linked a pull request Aug 30, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
triage/needs-more-info This issue/PR needs more infomation. type/bug This issue reports an unwanted behavior.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants