In which directory do files get downloaded when using download_data command in gae - google-app-engine

I am following the instructions at https://developers.google.com/appengine/docs/python/tools/uploadingdata to download data from google app engine. The data gets successfully downloaded (per the python output) but I am not able to find the file on the filesystem.
E.g., For the following command, I get success but I can't find bulkloader.yaml in my computer. I have tried microsoft (Win 7) inbuilt search, google-desktop search, but I get 0 results.
C:\Program Files (x86)\Google\google_appengine>python appcfg.py create_bulkloader_config --filename=bulkloader.yaml --url=http://appname.appspot.com/remote_api
Any help in this regard will be greatly appreciated. Thanks.

Assuming that all worked, the file should be in the same directory from which you started the command appcfg.py. the default directory of command prompt windows is something like C:\Documents and Settings\User. Try to take a look there or restart command from a directory of your choice.
edit: in your case the file is probably in C:\Program Files (x86)\Google\google_appengine

Related

Running app engine local development server from command prompt (v1.9.36) - Google Cloud complications (No module named portpicker)

I've been running app engine local development server from the command prompt for 3 years without any issues (windows 7, 64bit). I just updated to v1.9.36 (download 960cfe2157c6e984802db4b0224cfe8273d727dc from this page), and now when I run
dev_appserver.py [anything]
I get:
Traceback (most recent call last): File "C:\Program
Files\Google\Cloud
SDK\google-cloud-sdk\platform/google_appengine\dev_appserver.py", line
82, in
_run_file(file, globals()) File "C:\Program Files\Google\Cloud
SDK\google-cloud-sdk\platform/google_appengine\dev_appserver.py", line
78, in _run_file
execfile(_PATHS.script_file(script_name), globals_) File "C:\Program Files
(x86)\Google\google_appengine\google\appengine\tools\devappserver2\devappserver2.py",
line 37, in
from google.appengine.tools.devappserver2 import dispatcher File "C:\Program Files
(x86)\Google\google_appengine\google\appengine\tools\devappserver2\dispatcher.py",
line 29, in
from google.appengine.tools.devappserver2 import module File "C:\Program Files
(x86)\Google\google_appengine\google\appengine\tools\devappserver2\module.py",
line 55, in
from google.appengine.tools.devappserver2 import http_runtime File "C:\Program Files
(x86)\Google\google_appengine\google\appengine\tools\devappserver2\http_runtime.py",
line 53, in
import portpicker ImportError: No module named portpicker
The strange thing is that if I use the SDK GUI, and hit the 'Run' button, it launches just fine, no errors. So my guess is that when running from the command line, it's using the version of 'dev_appserver.py' in the Cloud SDK folder, whereas the GUI is running the version in C:\Program Files (x86)\Google\google_appengine\. But my environment variables are:
GAE_SDK_ROOT: C:\Program Files (x86)\Google\google_appengine
PATH: lots of other things, plus C:\Program Files (x86)\Google\google_appengine\
And I dont see any reference to Cloud SDK, so I cant figure why the version in the folder would be run.
There are versions of dev_appserver.py in both C:\Program Files\Google\Cloud SDK\google-cloud-sdk\platform\google_appengine and C:\Program Files (x86)\Google\google_appengine
Seems that in combining GAE SDK with Google Cloud, Google has made this more complicated than it used to be..
[UPDATE]
If I run echo %PATH% then among many other things, I see
C:\Program Files\Google\Cloud SDK\google-cloud-sdk..
before
C:\Program Files (x86)\Google\google_appengine\
Which explains why it's running that version. The question now is: why is the former in my PATH if I havent set it in my user PATH variable? Where else is the Windows PATH manipulated? Presumable the Google Cloud SDK installer did this - how do I undo it?
Executing dev_appserver.py [anything] will launch the first dev_appserver.py executable encountered in your executable PATH environment, which appears to be not the one you expect :)
You have 2 options:
update your PATH as needed
execute the desired dev_appserver.py by specifying its full path:
C:\Program Files (x86)\Google\google_appengine\dev_appserver.py [anything]
This answer is somehow related: appcfg.py not working in command line
New answer
I turns out that the Cloud SDK folder was in my system path, which is checked before the user path, so the version of dev_appserver.py in Cloud SDK was being executed, rather than the more up to date version in the app engine folder.
To fix this I simply removed the Cloud SDK from my system path, using the handy app detailed here
Original answer
I worked out that if I rename the Cloud SDK folder in C:\Program Files\Google this fixes it. But that's a hacky fix, and presumably makes the Cloud SDK functionality unavailable (I dont think I currently need it).
So I'd still like a proper answer to this question. It seems that I need a way to control which version of dev_appserver.py gets run, and short of setting my environment variables (which I've already done) I dont know what else to try.
As an alternative to the other answers, if you do not have the old standalone Google App Engine installed and only uses the Google SDK, you can also install portpicker with the following command line (assuming you have pip installed):
pip install portpicker

Nunit TestResult.xml is not created during Jenkins build

To run tests in Jenkins I use the next batch command:
"C:\Program Files (x86)\NUnit 2.6.4\bin\nunit-console.exe" /result:TestResult.xml "C:\Users\Denis\Documents\Visual Studio 2013\Projects\MyProject\App.nunit"
Here how it looks in Jenkis:
The problem is: it doesn't generate TestResult.xml file!
When I run the same command as a .bat file from my desctop it creates the TestResult.xml file.
Any ideas what is wrong with Jenkins?
P.S. I searched for created file in all possible folders and even via "search"
I came up with thought that the file is generated and removed then or something like this.
The thing is that I don't see this file indeed but Jenkins generated report based on this file! So I think maybe after generating report the file was removed automatically.
I had faced the same issue and I found the test results xml file under my user directory in Win 7.
Note : I think it's some problem with nunit that it doesn't export the file to the location of which we provide the path.

Getiing error message 'Failed Installing JBAS50SVC' whle running service.bat file in Windows 7

I need to run Jboss 7 as service.
Followed these steps :-
Copied my Jboss to C:\Program Files <86>
Downloaded Jboss-native-2.0.10-windows-x64-ssl and copied the contenst of bin catalog to %JBOSS_HOME%/bin
Changes done on service.bat as per link instructions
https://community.jboss.org/message/724488
Changed my dir location to my Jboss bin
and given command service.bat install
C:\Program Files \jboss7>bin>service.bat install
Failed installing JBAS50SVC
Access is Denied.
Service JBoss Application Server 7.1.1 installed.
I'm not able to rectify this problem .
It appears to be windows access issue.
Try the following:
Does the windows ID you are using have Administrator privileges? If no, get a Admin ID else if Yes, proceed to step 2.
Try to do the same but in some other drive (not c: )
UPDATE #1 : OP says he can not see the output of service.bat file
Follow the following steps
Open start menu
Search for "cmd"
Right click "cmd" and run as Administrator
type in following command
cd C:\Program Files \jboss7\bin
Type service.bat and observe the output
On a 2008 Windows Server this occurs because you're not running the command line as an administrator. Those of us who have spent considerable amounts of time on 2003 server, and others before that, keep forgetting that your logged in ADMIN level account does NOT get passed to the command line automatically like with previous versions of Windows.
With any additional errors, past this one, I would keep going back to the service.bat file and looking at the path statements, throughout that file, to ensure that they are all correct to reach what is correct for your installation.
Also, don't forget to create a log folder under standalone (unless you're doing a domain install). Failure to do that will also cause issues as well.
yoda

GAE plugin or GAE appcfg.cmd are not working with --enable_jar_splitting parameter

I have this error message:
Preparing to deploy: Created staging directory at:
'C:\Users\leet\AppData\Local\Temp\appcfg4768292050846213939.tmp'
Scanning for jsp files. Compiling jsp files. Scanning files on
local disk. java.io.IOException: Jar
C:\Users\leet\AppData\Local\Temp\appcfg4768292050846213939.tmp\WEB-INF\lib\appengine-api-1.0-sdk-1.7.7.jar
is too large. Consider using --enable_jar_splitting.
I issued the command like this, but it does not work with --enable_jar_splitting.
"C:\Program Files\Java\jdk1.7.0_17\bin\java.exe" -Xmx1100m -cp
"%~dp0..\lib\appengine-tools-api.jar"
com.google.appengine.tools.admin.AppCfg --enable_jar_splitting -e
user#domain.com update "C:\myfolder\myproject\war"
Any comment?
The Java App Engine 1.7.7.1 SDK has been released to address this windows specific issue.
The Google Eclipse plugin has been updated, as well as the Google App Engine Maven artifacts and plugin (just use the 1.7.7.1 version).
to solve the library error message, you have to do this:
1) open your windows explorer and locate it to your eclipse folder. e.g. ".\eclipse\plugins\com.google.appengine.eclipse.sdkbundle_1.7.7\appengine-java-sdk-1.7.7\lib\user".
2) you will then see a file called "appengine-api-1.0-sdk-1.7.7.jar", rename it to "appengine-api-1.0-sdk-1.7.7.original". (just don't delete as you need in future)
3) copy that 2 files you created earlier - "appengine-api-1.0-sdk-1.7.7-1.jar" and "appengine-api-1.0-sdk-1.7.7-2.jar" and paste into this folder.
4) switch it eclipse ide, clean the project and rebuild it. then, the error message will go away.
i solved the issue by splitting the "appengine-api-1.0-sdk-1.7.7.jar" file my own.
in case anyone else want to know how to do that, follow these steps
1) unzip "appengine-api-1.0-sdk-1.7.7.jar" file from 7z.
2) balance them into 2 folders (each about 15mb) regardless any structure.
3) name the first folder as "appengine-api-1.0-sdk-1.7.7-1" and second folder as "appengine-api-1.0-sdk-1.7.7-2".
4) make sure you have jdk installed. e.g. "C:\Program Files\Java\jdk1.7.0_17\bin". set it to environment so you can run the file from that bin folder.
5) IMPORTANT: you must go into that first "appengine-api-1.0-sdk-1.7.7-1" folder and not at the parent folder of those folders.
6) launch cmd.exe and type "jar cf appengine-api-1.0-sdk-1.7.7-1.jar *" for the first archive.
7) do it again the same for the second archive (repeat step 5 and step 6).
8) go to \war\web-inf\libs folder, delete the existing appengine-api-1.0-sdk-1.7.7.jar.
9) copy and paste the appengine-api-1.0-sdk-1.7.7-1.jar and appengine-api-1.0-sdk-1.7.7-2.jar into \war\web-inf\libs folder.
10) now deploy it. it should work like charms!
EDIT:
Spelling correction.
Using that instruction :
To clarify, we're going to release a minor update for 1.7.7. For the
meantime, you can re-jar the file as follows:
cd to the working directory
$ jar xf somewhere\appengine-java-sdk-1.7.7\lib\user\
appengine-api-1.0-sdk-1.7.7.**jar
$ jar cfm somewhere\appengine-api-1.0-sdk-1.7.7.**jar META-INF/MANIFEST.MF *
and replace the old jar with the newly created one.
from http://www.mail-archive.com/google-appengine#googlegroups.com/msg67954.html
and the messages from the solutions here, I was able to make it work like this :
Open a command line and go into the bin directory of your JAVA installation where the jar.exe file is
cd "C:\Program Files\Java\jdk1.7.0_17\bin\"
Then, you need to find the file "appengine-api-1.0-sdk-1.7.7.jar" somewhere on your computer. It's at 2 places (not counting the temp directories), in the \war\WEB-INF\lib folder in your eclipse project and also in the "plugins" folder of your eclipse installation. Precisely there : \plugins\com.google.appengine.eclipse.sdkbundle_1.7.7\appengine-java-sdk-1.7.7\lib\
You just need one of those 2 paths.
Now in the command line, just type :
jar xf "C:\whatever-folder-your-eclipse-is-in\plugins\com.google.appengine.eclipse.sdkbundle_1.7.7\appengine-java-sdk-1.7.7\lib\user\appengine-api-1.0-sdk-1.7.7.jar"
and then
jar cfm "C:\whatever-folder-your-eclipse-is-in\plugins\com.google.appengine.eclipse.sdkbundle_1.7.7\appengine-java-sdk-1.7.7\lib\user\appengine-api-1.0-sdk-1.7.7.jar" META-INF/MANIFEST.MF
Now, if you go to that folder and check the .jar file, it should now be 11 mb instead of 30 something. Now you need to copy this one and replace the same jar in your webapp folder in \war\WEB-INF\lib\ so that both jars named "appengine-api-1.0-sdk-1.7.7.jar" have a 11 mb size.
Now the error should be gone and you don't have to split anything.

Running appcfg.py

I have python + google app engine installed on a windows XP machine. Google App engine is installed in the default directory of python25.
How do I run appcfg.py from command line?
I tried running it after changing directory to python25 but I get an error that the program is not a valid win32.exe
I also tried running it directly from c:\program files\google\google_appengine but I also get an error.
Secondly, I need to run appcfg with the rollback option. How do I do this?
Thanks
you needs to assign python scripts to python.exe or do the following [Path to Python]\python.exe [Path to appcfg]\appcfg.py rollback [path to app].

Resources