I'm using {:ok, goth} = Goth.Token.for_scope("https://www.googleapis.com/auth/devstorage.full_control")
But i seen a bug. Please help me
** (exit) an exception was raised:
** (UndefinedFunctionError) function :crypto.mpint/1 is undefined or private
(crypto) :crypto.mpint(19687873431742193920055970243130294467124206658682087298983794038798216955530975915146333586732314900700035611611045789143545904247799428447896803420118324471667046274052296120024954651561469080093219328190691149886440049200669636272584661976356321702914680136369124759272732574776698998044554776915282967732669956832401458331945711479325049514685797410840542208523089896590986235120222095570675226125560522026179882816977851505433864383972624362893774956738669017687990725035030542706539434148824251987312659383648295704127681204473207295376320651645980971185202320992998884262991006767805018245431366563316696488933)
Please check that you are using Goth 0.6.0 or later version, so that json_web_token will be updated to its newest version that does not rely on mpint/1.
More detailed explanation:
:crypto.mpint/1 was removed in the latest version of Erlang/OTP 20 since it was deprecated few versions ago.
Goth has a dependency called json_web_token which used to use mpint/1 up until the middle of 2017. Since then version 0.2.10 was released as an emergency fix for the removal of mpint/1 in the crypto package and you can see that Goth had this dependency updated in the summer also - https://github.com/peburrows/goth/commit/b983dc15447ee6b59a0f170f5a47da9e298549ff .
Related
I am new to the Modelica world and installed JModelica2.14 on win10 via the binary file provided from the offical webpage. From the console I call setenv.bat, start the 64bit python envrionment and import '.\install\Python_64'. However, running the example files already throws an error. The minimal code example throwing the error is provided below. I assume that the binaries do not have a bug without anyone mentioning it. It would be great if someone could give a hint about what I am missing. Thanks a lot!
import modelicacasadi_wrapper
modelicacasadi_wrapper.OptimicaOptionsWrapper()
RuntimeError Traceback (most recent call last)
<ipython-input-11-ce2bcdfa3f06> in <module>()
----> 1 modelicacasadi_wrapper.OptimicaOptionsWrapper()
C:\JModelica.org-2.14\install\Python_64\modelicacasadi_wrapper\modelicacasadi_wrapper.pyc in __init__(self, *args)
3472 __init__(ModelicaCasADi::OptimicaOptionsWrapper self, OptimicaOptionsWrapper other) -> OptimicaOptionsWrapper
3473 """
-> 3474 this = _modelicacasadi_wrapper.new_OptimicaOptionsWrapper(*args)
3475 try:
3476 self.this.append(this)
RuntimeError: java.lang.NoClassDefFoundError org/jmodelica/optimica/compiler/ModelicaCompiler
Caused by: java.lang.ClassNotFoundException: org.jmodelica.optimica.compiler.ModelicaCompiler
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:583)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
This function is only given in binary format compiled from c++ code. therefore, I can not change the function without recompiling the library (I already tried). To me it seems like the org.jmodelica.optimica.compiler.ModelicaCompiler should have been a org.jmodelica.optimica.compiler.OptimicaCompiler. This would mean that I have to install the package from source and I haven't been sucessful with that yet.
I still use JModelica 2.14 in Python 2 and then have installed virtual environment with Conda to create a Python 3 environment where I then run the FMUs with the latest PyFMI package in Python 3.10 and Jupyter notebook. It all works very fine, but as Imke Kreuger indicated you have MSL 3.2.2 build 3 and there has been development in the Modelica Standard Library since then.
During installation you are asked whether you want "Graybox OPC Automation wrapper" and I usually say "NO" there. You may have said "YES" though, right? See Chapter 2.2.1 in the User guide.
The JModelica installation actually provide you with two different compilers.
One is for standard Modelica brings as output an FMU of CS or ME type. The other compiler is for Modelica extended with Optimica and does not bring any FMU and you are bound to work in Python 2.
Tried to reproduce your error (with my installation without the "Graybox OPC..."). If I (in the Python 2 environment) literally do the two commands, I get "Press any key to continue...." and when I press key the IPython window collapse.
However if you skip the two brackets at the end of the second command, then it is accepted!
If you write a question mark at the end you get information about what arguments you should have.
If you describe better what you want to do, we likely can help you better.
Note, it seems you want to use Optimica and that is an extension of Modelica that is only partially supported by OpenModelica, what I understand. The Optimica extension is well integrated in JModelica and originated in this context. For "ordinary" Modelica use I do not think you need to use this wrapper.
I am trying to execute a SQL statement on BQ Database by initializing the BQ Client. This has been running smoothly for a while but lately seeing an issue.
My code specifically fails when its trying to wait for the results from the DB
query_job = client.query(QUERY) # API request to start the query
db_rslt = query_job.result() # Wait for the query to return results
Here is error message:
File "/opt/conda/default/lib/python3.7/site-packages/google/cloud/bigquery/job.py", line xxx, in result super(QueryJob, self).result(retry=retry, timeout=timeout) File "/opt/conda/default/lib/python3.7/site-packages/google/cloud/bigquery/job.py", line xxx, in result return super(_AsyncJob, self).result(timeout=timeout) File "/opt/conda/default/lib/python3.7/site-packages/google/api_core/future/polling.py", line xxx, in result self._blocking_poll(timeout=timeout, retry=retry, polling=polling) TypeError: _blocking_poll() got an unexpected keyword argument 'retry'
Added the timeout parameter to the result method but did not help
It depends on the version of your installed google-cloud-bigquery library, if you are using a 1.x version, make sure to set google-api-core to a version less than 1.34.0.
What is actually happening here is that when you install google-cloud-bigquery, a bunch of other google related libraries are installed automatically with it, google-api-core is one of these libraries. However, a higher version is being installed thus causing this problem.
In my case, setting my google-api-core==1.33.2 solves the issue. Other solution would be is to upgrade google-cloud-bigquery to a later version .
7 days ago Google released an update to google-api-core==1.34.0 for bug fixes. I guess this introduced some breaking changes if you are not using the later versions of google-cloud-bigquery. You may either:
Pin google-api-core to the previous working version (eg. 1.33.2)
Upgrade google-cloud-bigquery to the latest versions.
I solved it by changing the bigquery version to the latest: 'google-cloud-bigquery==3.4.0'.
This also happened to me.
My python image is 3.8.13:bulleye.
It was using the following stack of google library.
google-auth==1.33.0
google-cloud-bigquery==1.25.0
google-cloud-firestore==2.3.1
Changing them to
db-dtypes==1.0.0
google-auth==2.6.0
google-cloud-bigquery==3.0.1
google-cloud-firestore==2.5.3
solved the problems.
db-dtypes is required for new version of google cloud library.
This did the trick for me, although I was having this issue on Kaggle notebooks:
pip install -U google-cloud-bigquery google-api-core==1.33.2
Also the v2 version of google-api-core seems to work:
google-api-core==2.11.0
https://github.com/googleapis/python-api-core/releaseshttps://github.com/googleapis/python-api-core/releases
Current jetty version is 9.4.6, I tried to upgrade 9.4.44, I got the error. Could you please help me?
WebAppContext:554 -Failed startup of context o.e.j.w.WebAppContext#163f1cd{passwd-change,/passwd-change,file:///run/opt/corp/gsec/7.0.0/java-service/gsec-jetty-base/temp/jetty-gsec-2443-passwd-change.war-_passwd-change-any-6326268666909012254.dir/webapp/,UNAVAILABLE}{/passwd-change.war}
Caused by: java.lang.IllegalAccessError: tried to access method org.eclipse.jetty.server.handler.ContextHandler$StaticContext.createInstance(Ljava/lang/Class;)Ljava/lang/Object; from class jetty.webapp.StandardDescriptorProcessor
at org.eclipse.jetty.webapp.StandardDescriptorProcessor.newListenerInstance(StandardDescriptorProcessor.java:1945) ~[apacheds-service-2.0.0-M24.jar:2.0.0-M24]
at org.eclipse.jetty.webapp.StandardDescriptorProcessor.visitListener(StandardDescriptorProcessor.java:1900) ~[apacheds-service-2.0.0-M24.jar:2.0.0-M24]
The jetty files in your apacheds-service-2.0.0-M24.jar needs to be upgraded as well.
List the contents of the apacheds-service-2.0.0-M24.jar file and you'll see classes in the org.eclipse.jetty. namespace.
Those are conflicting with your efforts to upgrade Jetty via the jetty-distribution zip.
I had a different setup that triggered a similar stacktrace: using cargo-maven2-plugin 16.1 in a spring 5 project, mvn cargo:run would fail because of a conflict with javafx.base-11.0.0-SNAPSHOT.jar files.
Upgrading to cargo-maven3-plugin 1.9.9 fixed the matter.
I'd encourage who ever uses cargo-maven2-plugin to migrate to cargo-maven3-plugin as the doc states:
Please be aware that the Maven 2 / Maven 3 plugin of Codehaus Cargo has been retired with our version 1.9.0 and has been superseded by a Maven 3 only plugin.
I am trying to use cmake to compile and noticed the boost binary link is not available (forbidden). Is there a workaround to this?
[ 25%] Performing download step (download, verify and extract) for 'Boost'
-- verifying file...
file='/home/op/.hunter/_Base/Download/Boost/1.66.0/075d0b4/boost_1_66_0.7z'
-- SHA1 hash of
/home/op/.hunter/_Base/Download/Boost/1.66.0/075d0b4/boost_1_66_0.7z
does not match expected value
expected: '075d0b43980614054b1f1bafd189f863bba6600e'
actual: 'da39a3ee5e6b4b0d3255bfef95601890afd80709'
-- File already exists but hash mismatch. Removing...
-- Downloading...
dst='/home/op/.hunter/_Base/Download/Boost/1.66.0/075d0b4/boost_1_66_0.7z'
timeout='none'
-- Using src='https://dl.bintray.com/boostorg/release/1.66.0/source/boost_1_66_0.7z'
-- Retrying...
-- Using src='https://dl.bintray.com/boostorg/release/1.66.0/source/boost_1_66_0.7z'
-- Retry after 5 seconds (attempt #2) ...
-- Using src='https://dl.bintray.com/boostorg/release/1.66.0/source/boost_1_66_0.7z'
-- Retry after 5 seconds (attempt #3) ...
-- Using src='https://dl.bintray.com/boostorg/release/1.66.0/source/boost_1_66_0.7z'
-- Retry after 15 seconds (attempt #4) ...
relevant config:
hunter_config(CURL VERSION ${HUNTER_CURL_VERSION} CMAKE_ARGS HTTP_ONLY=ON CMAKE_USE_OPENSSL=OFF CMAKE_USE_LIBSSH2=OFF CURL_CA_PATH=none)
hunter_config(Boost VERSION 1.66.0)
A workaround that fixed the issue for me was to manually download boost_1_66_0.7z from https://www.boost.org/ and place it under $HOME/.hunter/_Base/Download/Boost/1.66.0/075d0b4/
Bintray went out of service per May 1st, 2021¹:
https://lists.boost.org/Archives/boost/2021/02/250813.php
Thank you for supporting JFrog through your use of Bintray. We are and continue to be a community-focused company, and in the spirit of transparency we’re giving you advance notice that as of May 2021, we will be sunsetting Bintray.
Boost downloads are available here now:
https://lists.boost.org/Archives/boost//2021/04/251468.php
Bintray is “sunsetting†on the 1st of May. At that time, you will
be unable to download boost releases from there. Before that time,
their service will be occasionally interrupted. The web site has been
updated, all the download links now refer to
https://boostorg.jfrog.io/artifactory/main/release/
Example: Instead
of downloading from:
https://dl.bintray.com/boostorg/release/1.76.0/source/boost_1_76_0.tar.gz
You should download from:
https://boostorg.jfrog.io/artifactory/main/release/1.76.0/source/boost_1_76_0.tar.gz
This applies to all releases from 1.63.0 onward (The pre-1.63 releases
are still hosted at SourceForge)
The fix is using the working version of hunter, with the latest version of CMake, I have made a pull request with this solution, it is working
Check it here https://github.com/ethereum-mining/ethminer/pull/2413/files
My Google Cloud Function won't upload if I include this line, which came from the docs:
const {Translate} = require('#google-cloud/translate').v2;
The error is
TypeError: Cannot read property 'Reader' of undefined
There's no Reader in my code.
My version is:
npm -v #google-cloud/translate
6.14.10
Which is odd, because the current npm version is 6.0.5, and the release notes say there hasn't been an update since March 2020.
I tried both Node 10 and Node 12 for the Firebase Cloud Functions engine, same error.
Am I getting this error because I'm on the event horizon of a black hole and downloaded a future version of #google-cloud/translate? I think I might be in an alternative universe, 2020 was awful. How are things in your universe?
I updated the npm modules in my /functions directory and the error message is gone. Both firebase-functions and #google-cloud/translate were out of date.