After the second time deploying the Django app to Pythonanywhere, (I re-edited and overwritten in VS code and did git push) I got the following error.
WARNING: Package(s) not found: django
Traceback (most recent call last):
File "/home/hogehohe/.local/bin/pa_autoconfigure_django.py", line 47, in <module>
main(arguments['<git-repo-url>'], arguments['--domain'], arguments['--python'], nuke=arguments.get('--nuke'))
File "/home/hogehohe/.local/bin/pa_autoconfigure_django.py", line 36, in main
project.update_settings_file()
File "/home/hogehohe/.local/lib/python3.6/site-packages/pythonanywhere/django_project.py", line 74, in update_settings_file
new_django = version.parse(self.virtualenv.get_version("django")) >= version.parse("3.1")
File "/home/hogehohe/.local/lib/python3.6/site-packages/pythonanywhere/virtualenvs.py", line 32, in get_version
output = subprocess.check_output(commands).decode()
File "/usr/lib/python3.6/subprocess.py", line 356, in check_output
**kwargs).stdout
File "/usr/lib/python3.6/subprocess.py", line 438, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['/home/hogehohe/.virtualenvs/hogehohe.pythonanywhere.com/bin/pip', 'show', 'django']' returned non-zero exit status 1.
The command is
$ pa_autoconfigure_django.py https://github.com/[user_name]/[project_name].git --nuke
The first deployment succeeded but the second one is not. I don't know the cause and how to overwrite it...
You need to have a requirements.txt file in your project that specifies the packages that you need for your app. I'm guessing that your first project had one that included django and that your second one does not.
Related
So i'm installing Chromium source code and trying to get ios code but keep getting error. Here's a documentation i'm following: https://chromium.googlesource.com/chromium/src/+/master/docs/ios/build_instructions.md
When i'm trying to run python3 setup-gn.py i keep getting an error:
markmarus#MacBook-Pro-Mark tools % python3 setup-gn.py
ERROR at //build/config/compiler/BUILD.gn:1343:22: Script returned non-zero exit code.
clang_revision = exec_script("//tools/clang/scripts/update.py",
^----------
Current dir: /Users/markmarus/src/out/_tempzfw_t_3r/
Command: python3 /Users/markmarus/src/tools/clang/scripts/update.py --print-revision --verify-version=16.0.0
Returned 1 and printed out:
The expected clang version is llvmorg-16-init-8697-g60809cd2-1 but the actual version is
Did you run "gclient sync"?
See //build/config/BUILDCONFIG.gn:334:3: which caused the file to be included.
"//build/config/compiler:afdo_optimize_size",
^-------------------------------------------
Traceback (most recent call last):
File "/Users/markmarus/src/ios/build/tools/setup-gn.py", line 340, in <module>
sys.exit(Main(sys.argv[1:]))
^^^^^^^^^^^^^^^^^^
File "/Users/markmarus/src/ios/build/tools/setup-gn.py", line 336, in Main
GenerateXcodeProject(gn_path, args.root, args.proj_name, out_dir, settings)
File "/Users/markmarus/src/ios/build/tools/setup-gn.py", line 220, in GenerateXcodeProject
generator.Generate(gn_path, proj_name, root_dir, temp_path)
File "/Users/markmarus/src/ios/build/tools/setup-gn.py", line 114, in Generate
subprocess.check_call(self.GetGnCommand(
File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/subprocess.py", line 413, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['/usr/local/bin/gn', '--root=/Users/markmarus/src', '-q', '--ide=xcode', '--ninja-executable=autoninja', '--xcode-build-system=new', '--xcode-project=all', '--xcode-additional-files-patterns=*.md', '--xcode-additional-files-roots=//ios;//ios_internal;//docs', '--xcode-configs=Debug;Release;Profile;Official', '--xcode-config-build-dir=//out/${CONFIGURATION}${EFFECTIVE_PLATFORM_NAME}', '--filters=//base:base_unittests;//components:components_unittests;//crypto:crypto_unittests;//google_apis:google_apis_unittests;//ios/*;//ios_internal/*;//net:net_unittests;//services:services_unittests;//skia:skia_unittests;//sql:sql_unittests;//ui/base:ui_base_unittests;//ui/gfx:gfx_unittests;//url:url_unittests;//third_party/crashpad/*', 'gen', '//out/_tempzfw_t_3r']' returned non-zero exit status 1.
markmarus#MacBook-Pro-Mark tools % build.py
I simply can't run the command
I've been working on a Course that makes us do online labs on Jupyter
I have completed three out of 5, however whenever I try to open the 4th and 5th one, its starts my server, however it shows this message before opening
$ git fetch
$ git -c user.email=nbgitpuller#nbgitpuller.link -c user.name=nbgitpuller merge -Xours origin/master
fatal: You have not concluded your merge (MERGE_HEAD exists).
Please, commit your changes before you merge.
Traceback (most recent call last):
File "/srv/conda/envs/notebook/lib/python3.7/threading.py", line 926, in _bootstrap_inner
self.run()
File "/srv/conda/envs/notebook/lib/python3.7/threading.py", line 870, in run
self._target(*self._args, **self._kwargs)
File "/srv/conda/envs/notebook/lib/python3.7/site-packages/nbgitpuller/handlers.py", line 88, in pull
raise e
File "/srv/conda/envs/notebook/lib/python3.7/site-packages/nbgitpuller/handlers.py", line 82, in pull
for line in gp.pull():
File "/srv/conda/envs/notebook/lib/python3.7/site-packages/nbgitpuller/pull.py", line 86, in pull
yield from self.update()
File "/srv/conda/envs/notebook/lib/python3.7/site-packages/nbgitpuller/pull.py", line 233, in update
], cwd=self.repo_dir)
File "/srv/conda/envs/notebook/lib/python3.7/site-packages/nbgitpuller/pull.py", line 45, in execute_cmd
raise subprocess.CalledProcessError(ret, cmd)
subprocess.CalledProcessError: Command '['git', '-c', 'user.email=nbgitpuller#nbgitpuller.link', '-c', 'user.name=nbgitpuller', 'merge', '-Xours', 'origin/master']' returned non-zero exit status 128.
I know its a lot to ask to ask but what does this mean. How do I get rid of this message, that is not allowing my lab to open up
If you are not aware of any local git merge in progress, you can get rid of that MERGE_HEAD with (using Git 2.23+):
cd /path/to/local/repository
git merge --quit
I am trying to install google cloud SDK using install.bat. I have tried downloading the bundled pythons versions 275 and current version 276, they both fail at the same spot. It is able to find python in the platform/bundledpython folder so that is not the issue. I have also tried the suggestions online including making sure that the "Find" command works on a command prompt. Any help appreciated.
The latest available version is: 276.0.0
���───────────────────────────────────────────────────────────────────────────────────────────────────────────────┐Trac
back (most recent call last):
File "C:\google-cloud-sdk\google-cloud-sdk\\bin\bootstrapping\install.py", line 225, in <module>
main()
File "C:\google-cloud-sdk\google-cloud-sdk\\bin\bootstrapping\install.py", line 203, in main
Install(pargs.override_components, pargs.additional_components)
File "C:\google-cloud-sdk\google-cloud-sdk\\bin\bootstrapping\install.py", line 148, in Install
_CLI.Execute(['--quiet', 'components', 'list'])
File "C:\google-cloud-sdk\google-cloud-sdk\lib\googlecloudsdk\calliope\cli.py", line 1007, in Execute
self._HandleAllErrors(exc, command_path_string, specified_arg_names)
File "C:\google-cloud-sdk\google-cloud-sdk\lib\googlecloudsdk\calliope\cli.py", line 1040, in _HandleAllErrors
exceptions.HandleError(exc, command_path_string, self.__known_error_handler)
File "C:\google-cloud-sdk\google-cloud-sdk\lib\googlecloudsdk\calliope\exceptions.py", line 527, in HandleError
core_exceptions.reraise(exc)
File "C:\google-cloud-sdk\google-cloud-sdk\lib\googlecloudsdk\core\exceptions.py", line 146, in reraise
six.reraise(type(exc_value), exc_value, tb)
File "C:\google-cloud-sdk\google-cloud-sdk\lib\googlecloudsdk\calliope\cli.py", line 981, in Execute
resources = calliope_command.Run(cli=self, args=args)
File "C:\google-cloud-sdk\google-cloud-sdk\lib\googlecloudsdk\calliope\backend.py", line 809, in Run
display_info=self.ai.display_info).Display()
File "C:\google-cloud-sdk\google-cloud-sdk\lib\googlecloudsdk\calliope\display.py", line 483, in Display
self._printer.Print(self._resources)
File "C:\google-cloud-sdk\google-cloud-sdk\lib\googlecloudsdk\core\resource\resource_printer_base.py", line 279, in P
int
self.Finish()
File "C:\google-cloud-sdk\google-cloud-sdk\lib\googlecloudsdk\core\resource\table_printer.py", line 467, in Finish
self._out.write(line)
File "C:\google-cloud-sdk\google-cloud-sdk\lib\googlecloudsdk\core\log.py", line 239, in write
self._Write(plain_text, styled_text)
File "C:\google-cloud-sdk\google-cloud-sdk\lib\googlecloudsdk\core\log.py", line 232, in _Write
self.__stream_wrapper.stream.write(stream_msg)
I just had the same problem trying to install the latest Google Cloud SDK (276.0.0). The Windows setup was stuck on "Installing components".
Looking at the process list with Process Explorer I could see it was running this command that was stuck, as you probably did to get your stack trace. I took the command line and ran it in a separate Administror cmd.exe (paths might differ per system, the idea is the same).
cd "C:\Program Files (x86)\Google\Cloud SDK"
SET "CLOUDSDK_CORE_DISABLE_PROMPTS=1"
SET "CLOUDSDK_CONFIG=%APPDATA%\gcloud"
"C:\Program Files (x86)\Google\Cloud SDK\google-cloud-sdk\install.bat" --quiet --disable-installation-options --path-update "FALSE" --usage-reporting "true" --additional-components beta powershell"
Running them would produce the same error / stack trace.
Editing log.py and commenting out (prefix with #) line 232 would make it get further, but it runs into a separate problem:
ERROR: Cannot use bundled Python installation to update Cloud SDK in non-interactive mode.
Please run again in interactive mode.
Enable prompts with CLOUDSDK_CORE_DISABLE_PROMPTS envvar and remove --quiet and --disable-installation-options from the install.bat command line and run it again.
SET "CLOUDSDK_CORE_DISABLE_PROMPTS=0"
"C:\Program Files (x86)\Google\Cloud SDK\google-cloud-sdk\install.bat" --path-update "FALSE" --usage-reporting "true" --additional-components beta powershell"
This time it should continue, start a new console where it actually installs the components and eventually finish succesfully.
I am getting this error while trying to run mrjob example on the hadoop cluster.
I have set up my hadoop_home and I can also create a new dir on the hdfs file system.
I can run python map-reduce if I use hadoop streaming. It's only with mrjob I am getting this issue.
When I run this command:
python mr_word_freq_count.py -r hadoop --hadoop-bin /usr/bin/hadoop -o hdfs:///user/zkdmkrq/out1 hdfs:///user/zkdmkrq/input1
I get:
no configs found; falling back on auto-configuration no configs found;
falling back on auto-configuration creating tmp directory
/tmp/mr_word_freq_count.zkdmkrq.20150226.172000.917957 writing wrapper
script to
/tmp/mr_word_freq_count.zkdmkrq.20150226.172000.917957/setup-wrapper.sh
STDERR: mkdir:
`hdfs:///user/zkdmkrq/tmp/mrjob/mr_word_freq_count.zkdmkrq.20150226.172000.917957/files/':
No such file or directory Traceback (most recent call last): File
"mr_word_freq_count.py", line 37, in <module>
MRWordFreqCount.run() File "/usr/lib/python2.6/site-packages/mrjob/job.py", line 494, in run
mr_job.execute() File "/usr/lib/python2.6/site-packages/mrjob/job.py", line 512, in execute
super(MRJob, self).execute() File "/usr/lib/python2.6/site-packages/mrjob/launch.py", line 147, in
execute
self.run_job() File "/usr/lib/python2.6/site-packages/mrjob/launch.py", line 208, in
run_job
runner.run() File "/usr/lib/python2.6/site-packages/mrjob/runner.py", line 458, in run
self._run() File "/usr/lib/python2.6/site-packages/mrjob/hadoop.py", line 238, in _run
self._upload_local_files_to_hdfs() File "/usr/lib/python2.6/site-packages/mrjob/hadoop.py", line 265, in
_upload_local_files_to_hdfs
self._mkdir_on_hdfs(self._upload_mgr.prefix) File "/usr/lib/python2.6/site-packages/mrjob/hadoop.py", line 273, in
_mkdir_on_hdfs
self.invoke_hadoop(['fs', '-mkdir', path]) File "/usr/lib/python2.6/site-packages/mrjob/fs/hadoop.py", line 109, in
invoke_hadoop
raise CalledProcessError(proc.returncode, args) subprocess.CalledProcessError: Command '['/usr/bin/hadoop', 'fs',
'-mkdir',
'hdfs:///user/zkdmkrq/tmp/mrjob/mr_word_freq_count.zkdmkrq.20150226.172000.917957/files/']'
returned non-zero exit status 1
I actually found the solution to this issue.
I had to alter the mrjob/hadoop.py file. Here is the exact solution
https://github.com/Yelp/mrjob/issues/850
Hope it helps to anyone who encounters this issue.
This issue occurs when deploying either by the Google App Engine Launcher and via the command-line using appcfg.py
I have tried:
- Changing version - (doesn't work)
- Deleting version from when the issue stated (24 hours ago- around the time there was some Python issues on Google) - Doesn't work
- Install one of my other applications (works)
I have been banging my head against the wall on this for 24 hours and can't get any updates onto production
-------- Output -------------------------
Scanning files on local disk.
Cloning 10 static files.
Cloning 98 application files.
Compilation starting.
Compilation completed.
Starting deployment.
Checking if deployment succeeded.
Will check again in 1 seconds.
............
Will check again in 60 seconds.
Checking if deployment succeeded.
Will check again in 60 seconds.
Checking if deployment succeeded.
Will check again in 60 seconds.
Checking if deployment succeeded.
2012-02-24 07:38:36,362 WARNING appcfg.py:1948 Version still not ready to serve, aborting.
2012-02-24 07:38:36,363 ERROR appcfg.py:2178 An unexpected error occurred. Aborting.
Traceback (most recent call last):
File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/tools/appcfg.py", line 2164, in DoUpload
app_summary = self.Commit()
File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/tools/appcfg.py", line 1949, in Commit
raise Exception('Version not ready.')
Exception: Version not ready.
Rolling back the update.
Password for XXXXX#XXXXXX: Traceback (most recent call last):
File "google_appengine/appcfg.py", line 101, in <module>
run_file(__file__, globals())
File "google_appengine/appcfg.py", line 97, in run_file
execfile(script_path, globals_)
File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/tools/appcfg.py", line 3935, in <module>
main(sys.argv)
File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/tools/appcfg.py", line 3926, in main
result = AppCfgApp(argv).Run()
File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/tools/appcfg.py", line 2497, in Run
self.action(self)
File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/tools/appcfg.py", line 3692, in __call__
return method()
File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/tools/appcfg.py", line 2915, in Update
self.UpdateVersion(rpcserver, self.basepath, appyaml)
File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/tools/appcfg.py", line 2904, in UpdateVersion
self.options.max_size)
File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/tools/appcfg.py", line 2164, in DoUpload
app_summary = self.Commit()
File "/Applications/GoogleAppEngineLauncher.app/Contents/Resources/GoogleAppEngine-default.bundle/Contents/Resources/google_appengine/google/appengine/tools/appcfg.py", line 1949, in Commit
raise Exception('Version not ready.')
Exception: Version not ready.
If deploy fails you might need to 'rollback' manually.
The "Make Symlinks..." menu option can help with command-line work.
*** appcfg.py has finished with exit code 1 ***