I'm following the instructions in this blog post (http://www.badlogicgames.com/wordpress/?p=3073) for trying to debug the GWT version of my LibGDX project.
I can compile the GWT project fine, and start the superdev code server using en Eclipse "Run As" profile. I then start Jetty using mvn verify -Phtml, browse to localhost:8080/index.html and enable dev mode as per the blog post. Something of note is that I don't see the dialog box as described in the post ("GWT modile 'blah' may need to be recompiled").
When looking at sources in Chrome's developer tools, I don't see any of my linked Java source under the localhost:9876 tree node; instead I see something like this:
localhost:9876
projectname
gwt/chrome
chrome.css
{some long MD5-lookign thing}.cache.js
projectname.nocache.js
It's be ace if I could figure out how to see my code linked there and put breakpoints in, as at the moment I'm getting a GdxRuntimeException with a message of "Not implemented" thrown somewhere, but I've no idea from where.
Related
I am following the eclipse set up from MIT's software construction course1. The installation yields an error and I am not sure how to fix this (pictured below)2. The URL yielding an error returns a 404 error, so I don't know if their site is down or an issue with the package I'm using from MIT. Any advice is appreciated!
Error Message From Eclipse
It seems the update site recently moved to a new location.
If you don't want to contact the course staff directly, you could raise an issue against the relevant GitHub project, suggesting they update the setup file.
In the short term, you should be able to download the file to disk, change the URL (look for a line like <repository url="https://checkstyle.github.io/eclipse-cs/update"/> and change the URL to https://checkstyle.org/eclipse-cs-update-site/) and use the "Browse File System" button in the Eclipse installer instead of pasting the remote URL.
So I followed the netbeans (I'm using 12.2) tutorial for handling images:
https://netbeans.org/kb/73/java/gui-image-display.html?print=yes
I can see the icon in the designer but when run getResource() returns a null indicating it can't find the resource.
I have found this question which seemed to be related:
Netbeans ImageIcon not displaying
I have ensured that I am using a package and not a folder.
The error generated :
Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
at java.desktop/javax.swing.ImageIcon.<init>(ImageIcon.java:217)
at com.byotrader.zom.ZomFrame.initComponents(ZomFrame.java:37)
The line of code:
jButton1.setIcon(new javax.swing.ImageIcon(getClass().getResource("/com/byotrader/zom/resources/ZomIcon.gif"))); // NOI18N
I have no idea why this is failing when run.
So my introduction to netbeans isn't going as smoothly as I hoped!
As requested project screen shot:
https://photos.app.goo.gl/CJ4EB3PD4a86nAVK8
Any ideas what I have failed to do?
One suggested answer relating to the following question :
netbeans & java, resourceMap.getString returning null
However the answer clearly states this is only a problem if a Clean build has not been done. That is not my issue as I have tried a clean build!
However looking in the .jar file I can see the picture resources have not been added! I assume this is the problem. However I have no idea how I can force the IDE to do its job!
Link to files structure:
https://photos.app.goo.gl/bRxHHW2UtRjPF7LeA
This link may also help others in future:
Netbeans Maven Project - Other Sources does not appear
(It is a Maven-Project!*) Put your image under:
src/main/resources/com/byotrader/zom/resources/ZomIcon.gif
../resources/...
Explanation:
Netbeans (when on a maven project) completely (except maybe in designer mode!;) builds with maven! ...which means... no gif (etc.) files are considered form src/main/java ... (check your target/classes folder!)
After my fix proposal, the image should be in the desired location.
* The tutorial(, which explicitly tells "Java Project") is little outdated for Netbeans 12.2, where there is no "Java Project"... possible alternatives are (maven/gradle) "Java Frontend Project" (requires javaFX!) or the "good ole" (ant) "Samples>Java With Ant".
My Eclipse works fine, but now, periodically a message box comes up saying
Code Recommenders cannot download its model repository index
What does this mean?
If you go to "Preferences"/"Code Recommenders"/"Models" you will see some Repository URL's listed. In my case it is http://download.eclipse.org/recommenders/models/photon/.
But when you call that URL you will get a 404 since the site has been archived in July 2019.
So this URL beeing invalid causes the Error. Since the URL is not available is seems save to silently ignore it, as beeing suggested in the error-dialog.
As beeing said in the Reviews on eclipse Marketplace the project is archived due to lack of comitting developers. And you may find an archived last version here: https://repo.eclipse.org/content/shadows/releases.unzip/org/eclipse/recommenders/stable/
As written in the other answer, Code Recommenders has been archived due to lack of active maintainers, see this forum post.
Therefore when the plugin tries to download the models it fails because the site does not exist anymore, and you will see the following error dialog:
While you could choose to ignore this download failure in the future, I am not sure if Code Recommenders actually does anything without its models (please correct me if I am wrong), so at this point you could also uninstall the plugin.
OR, you could download the models manually:
Download the archived data of Code Recommenders: https://archive.eclipse.org/archived_projects/recommenders.tgz (9.7 GB!)
Extract recommenders/downloads/models/photon
In Eclipse: Open "Window" > "Preferences" > "Code Recommenders" > "Models"
Remove the existing download.eclipse.org entry
Add a new entry with a file URI pointing to the folder you extracted earlier. Note that you have to percent escape the URI, e.g.
C:\Program Files\eclipse\recommenders becomes file:///C:/Program%20Files/eclipse/recommenders
Click the "Apply" (and Close) button
Note however, that since you downloaded the files locally and there is no active development, you won't get recommendations for new Java features.
I don't want any of you to have to download 10 gigabytes like in #Marcono1234's solution, so I re-uploaded version-specific code recommender models to mega.nz and shared them here.
Download the code recommenders
For Eclipse Juno users: https://mega.nz/file/tuRFGYQD#zB_mq6XwO7nupLqMDRWQRnnhD3-FAgT3ijtDQyGvjFE
For Eclipse Kelper users: https://mega.nz/file/NjxXFYyb#uwpP3zxESL02prgTimhDL35xPXMnDkbDwzrhJG1rcgc
For Eclipse Luna users: https://mega.nz/file/02g1DASB#3GSzaKtFSGsxhdnNx2aX47DoD22ZZ6aUu9eXTUvoxKg
For Eclipse Mars users:
https://mega.nz/file/xnQDTQLC#wmA0cfL_ChVHuQ9r0Mo_Js3ef_eDyg2yU6Z2_JTUPbE
For Eclipse Neon users: https://mega.nz/file/siBF1QYC#aVfX3-FS5sNfLmRqCPg6eUaovQPpEkMqIPWugv3E3qk
For Eclipse Oxygen users: https://mega.nz/file/9nAjUITQ#BpQ4HagdlrfZOelW8jqVgJWI-5QlA38JLCGpGoMbWpc
For Eclipse Photon users: https://mega.nz/file/oq5klCBR#vB8f0vmPH3gaYGwkw7U1SVThW5IxKMuvhBughN-sJi4
Extract it to any folders you want (in my case, c:\workspaces\eclipse\recommenders)
In Eclipse: Open "Window" > "Preferences" > "Code Recommenders" > "Models"
Remove the default entry
Add a file URL to the path you extracted your code recommender model. In my case, it's file://workspaces/eclipse/recommenders.
Click the "Apply" (and Close) button
Enjoy!
I created a new web project on Netbeans. As usual, in order to be sure that everything is OK before coding, I tried to run my project directlywith Netbeans.
For what I can see, evrything is great, except that I have a popin with the followed message : "Cannot run /usr/bin/firefox". A fex months ago, running a project by this way was perfectly good. I don't know what has changed.
What I tired/checked :
The file /usr/bin/firefox exists ;
I give it all the rights (reading, writing, executing) ;
if I specify another browser in Netbeans, the result is the same (of course, the message changes but keeps the same format) ;
My firefox is pefectly running, excpet for that.
I'm currently on Debian and Firefox v45.9.0.
Do you have any idea of what could cause this problem ? Any help is welcome !
Marine
Go to Netbeans menu Tools > Options. In the General Tab, Web browser section tab click edit.
Select Web browser as firefox (I guess it is already like that for you).
On the right hand side, if the text in Arguments section is -remote "openURL({URL})" , bingo that could be the problem.
Change it to {URL}.
Save and try running the project. Hope it works..
Possible duplicate of Google App Engine JDO enhancement is failing.
This is my first app engine app which I'm implementing based on "appengine-java-sdk-1.8.8" and Intellij Idea 13.0. Following image shows my application.
I have designed my application based on tutorial on Intellij Idea page.
In web.xml file if I clear lines 8-18 and remove mobilesoft.asia package from src folder then application works fine and when I click on Run button then I can see my "Hello world" message that I have written on index.jsp file.
However, with having of my package and lines 8-18 in web.xml then exception happens when I click on Run button.
Any suggestion would be appreciated.
==============
Edit: I downloaded 'datanucleus-appengine-2.0.0-final-dist' via this page. Seems it is latest release. Then I compared with what items I found under appengine-java-sdk-1.8.8\lib\opt\tools\datanucleus\v2 and realized that seems appengine has newer version of datanucleus. Therefore, app engine shouldn't have problem with compile, I'm confused....
finally I found the solution. I set 'Persistence' to "JPA 2" during creation of project. By set it to "JPA 1" problem solved (I don't know why) and I am able to compile the project.
So, select your project from Project panel. Then hit F4. Project structure opens. Select Google App Enfine from middle panel (under name of your project). Set Persistence to "JPA 1".