You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by GitBox <gi...@apache.org> on 2022/05/25 00:00:36 UTC

[GitHub] [netbeans] OlexYarm opened a new issue, #4148: NPE in Git checkout

OlexYarm opened a new issue, #4148:
URL: https://github.com/apache/netbeans/issues/4148

   ### Apache NetBeans version
   
   Apache NetBeans 13
   
   ### What happened
   
   java.lang.NullPointerException on Git checkout.
   
   ### How to reproduce
   
   1) I cloned FreeBSD Port Git Repository from https://git.freebsd.org/ports.git.
   The Git clone finished with error below:
   Commit 8363a8c281d18d4ecc0ca898d5a93fa2e2aba02d cannot be checked out because an invalid file name in one of the files.
   Please remove the file from repository with an external tool and try again.
   
   Invalid path: japanese/prn
   2) I tried to run Git checkout from NetBeans Git Repository Browser and got NPE:
   java.lang.NullPointerException: Cannot invoke "org.netbeans.libs.git.GitBranch.getName()" because "branch" is null
   	at org.netbeans.modules.git.ui.checkout.AbstractCheckoutAction$1.log(AbstractCheckoutAction.java:175)
   	at org.netbeans.modules.git.ui.checkout.AbstractCheckoutAction$1.perform(AbstractCheckoutAction.java:102)
   	at org.netbeans.modules.git.client.GitProgressSupport.performIntern(GitProgressSupport.java:92)
   	at org.netbeans.modules.git.client.GitProgressSupport.run(GitProgressSupport.java:85)
   	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1418)
   	at org.netbeans.modules.openide.util.GlobalLookup.execute(GlobalLookup.java:45)
   	at org.openide.util.lookup.Lookups.executeWith(Lookups.java:278)
   [catch] at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2033)
   3) I could not send issue report because it was no "submit" or "send" button anywhere.
   4) I closed NetBeans, open it again and did not see cloned Git repository in Git Repository Browser.
   
   ### Did this work correctly in an earlier version?
   
   No
   
   ### Operating System
   
   Windows 11
   
   ### JDK
   
   Microsoft build OpenJDK with Hotspot 17.0.3+7 (x64) (microsoft-jdk-17.0.3-windows-x64.msi)
   
   ### Apache NetBeans packaging
   
   Apache NetBeans provided installer
   
   ### Anything else
   
   _No response_
   
   ### Are you willing to submit a pull request?
   
   No
   
   ### Code of Conduct
   
   Yes


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] OlexYarm commented on issue #4148: NPE in Git checkout

Posted by GitBox <gi...@apache.org>.
OlexYarm commented on issue #4148:
URL: https://github.com/apache/netbeans/issues/4148#issuecomment-1137470735

   Hi Michael,
   
   Thanks for the quick response.
   I agree, there is a problem with Git clone on Windows 11. I got error below when did that.
   
   F:\GitHubRepos>git clone https://git.freebsd.org/ports.git /usr/ports
   Cloning into '/usr/ports'...
   remote: Enumerating objects: 5350190, done.
   remote: Counting objects: 100% (936/936), done.
   remote: Compressing objects: 100% (120/120), done.
   Receiving objects: 100% (5350190/5350190), 953.58 MiB | 16.88 MiB/s, done.9254Receiving objects: 100% (5350190/5350190), 949.39 MiB | 16.35 MiB/s
   
   Resolving deltas: 100% (3225734/3225734), done.
   error: invalid path 'japanese/prn/Makefile'
   fatal: unable to checkout working tree
   warning: Clone succeeded, but checkout failed.
   You can inspect what was checked out with 'git status'
   and retry with 'git restore --source=HEAD :/'
   
   
   F:\GitHubRepos>
   
   And “git clone” works fine on FreeBSD.
   ***@***.***:~ # git clone https://git.freebsd.org/ports.git /usr/ports
   
   Cloning into '/usr/ports'...
   remote: Enumerating objects: 5350456, done.
   remote: Counting objects: 100% (936/936), done.
   remote: Compressing objects: 100% (120/120), done.
   Receiving objects:   0% (1/5350456)
   Receiving objects:   0% (2434/5350456), 764.01 KiB | 731.00 KiB/s
   …
   Updating files: 100% (146290/146290)
   Updating files: 100% (146290/146290), done.
   ***@***.***:~ #
   
   Anyway, what I see is a bug in NetBeans – I think it does not check for null somewhere after “git clone” and shows alert with NPE.
   I’ll install NetBeans on FreeBSD or Ubuntu and check it again.
   
   Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows
   
   ________________________________
   From: Michael Bien ***@***.***>
   Sent: Wednesday, May 25, 2022 6:30:46 AM
   To: apache/netbeans ***@***.***>
   Cc: OlexYarm ***@***.***>; Author ***@***.***>
   Subject: Re: [apache/netbeans] NPE in Git checkout (Issue #4148)
   
   
   I just cloned the repository you linked using NetBeans and everything worked fine on linux
   
   ==[IDE]== May 25, 2022, 12:10:48 PM Validating destination...
   ==[IDE]== May 25, 2022, 12:10:48 PM Validating destination... finished.
   ==[IDE]== May 25, 2022, 12:10:48 PM Cloning
   git init /mnt/ram/ports
   git fetch https://git.freebsd.org/ports.git +refs/heads/main:refs/remotes/origin/main
   Total 5312749 (delta 121665), reused 113212 (delta 113212), pack-reused 5188196
   ....
   ....
   Tag    : release/5.5.0
   Result : NEW
   
   Branch  : origin/main
   Old Id : null
   New Id : 240c20b01b8f0139ccac5d8c929e2573f06878f2
   Result : NEW
   
   Tag    : release/5.3.0
   Result : NEW
   
   Tag    : release/13.0.0
   Result : NEW
   
   setting up remote: origin
   git branch --track main origin/main
   git checkout main
   git reset --hard main
   git submodule status
   ==[IDE]== May 25, 2022, 12:20:45 PM Cloning finished.
   
   
   maybe the windows filesystem doesn't support a filename or path which is in the repository?
   have you tried to clone the repository via command line?
   
   NetBeans 14 had some updates to git related dependencies, you could also check if the same issue occurs on 14rc4
   link to RC announcement: https://lists.apache.org/thread/v70t3nsop1q3bv43xxtlsg1fngk6p0p4
   
   —
   Reply to this email directly, view it on GitHub<https://github.com/apache/netbeans/issues/4148#issuecomment-1137072993>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AY5BMHBBCJANWLPWCJSW3RLVLX6NNANCNFSM5W3IYIDQ>.
   You are receiving this because you authored the thread.Message ID: ***@***.***>
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] mbien commented on issue #4148: NPE in Git checkout

Posted by GitBox <gi...@apache.org>.
mbien commented on issue #4148:
URL: https://github.com/apache/netbeans/issues/4148#issuecomment-1137486786

   i can fix the NPE thats no problem. This won't change anything on the fact that git can't checkout the repo on windows but at least it will log everything properly and show the git error message in the output window instead of the NPE.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] mbien closed issue #4148: NPE in Git checkout

Posted by GitBox <gi...@apache.org>.
mbien closed issue #4148: NPE in Git checkout
URL: https://github.com/apache/netbeans/issues/4148


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


[GitHub] [netbeans] mbien commented on issue #4148: NPE in Git checkout

Posted by GitBox <gi...@apache.org>.
mbien commented on issue #4148:
URL: https://github.com/apache/netbeans/issues/4148#issuecomment-1137072993

   I just cloned the repository you linked using NetBeans and everything worked fine on linux
   ```
   ==[IDE]== May 25, 2022, 12:10:48 PM Validating destination...
   ==[IDE]== May 25, 2022, 12:10:48 PM Validating destination... finished.
   ==[IDE]== May 25, 2022, 12:10:48 PM Cloning
   git init /mnt/ram/ports
   git fetch https://git.freebsd.org/ports.git +refs/heads/main:refs/remotes/origin/main
   Total 5312749 (delta 121665), reused 113212 (delta 113212), pack-reused 5188196
   ....
   ....
   Tag    : release/5.5.0
   Result : NEW
   
   Branch  : origin/main
   Old Id : null
   New Id : 240c20b01b8f0139ccac5d8c929e2573f06878f2
   Result : NEW
   
   Tag    : release/5.3.0
   Result : NEW
   
   Tag    : release/13.0.0
   Result : NEW
   
   setting up remote: origin
   git branch --track main origin/main
   git checkout main
   git reset --hard main
   git submodule status
   ==[IDE]== May 25, 2022, 12:20:45 PM Cloning finished.
   ```
   
   maybe the windows filesystem doesn't support a filename or path which is in the repository?
   have you tried to clone the repository via command line?
   
   NetBeans 14 had some updates to git related dependencies, you could also check if the same issue occurs on 14rc4
   link to RC announcement: https://lists.apache.org/thread/v70t3nsop1q3bv43xxtlsg1fngk6p0p4


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists