I am running Yaws server version 2.0.2 with Erlang/OTP 18 [erts-7.3] on ubuntu 16.04 and installed it using apt. Now when i try to run this example i get
undef yaws_dynopts random_seed. I have verified that module yaws_dynopts is not loaded OR compiled.
error is:
{undef,[{yaws_dynopts,random_seed,[6885,441906,806568],[]},
{m1,'-out/1-fun-0-',1,
[{file,"/home/my_account/.yaws/yaws/default/m1.erl"},{line,16}]}]}
which corresponds to line in example:
yaws_dynopts:random_seed(erlang:phash(node(), 100000),
erlang:phash(A2, A3),
A3),
Do anyone have solution to this? And is it a bug?
Does l(yaws_dynopts). also cause an error? I'm starting to believe whoever packaged your version of Yaws didn't do it correctly, leaving out this critical module. You should look to see if version 2.0.3 is available, or alternatively consider building your own from source. We're currently at 2.0.4.
Related
I installed Phalcon PHP as described in https://docs.phalcon.io/3.4/en/webserver-wamp.
In this case the URL reads 3.4 because it applies alike for versions 4 and 5.
The WAMP server version is 3.2.6 configured with PHP 8.0.13
Everything was fine so far, so I continued installing the developer tools using composer as described in https://docs.phalcon.io/5.0/en/devtools.
Composer was installed globally and so were the developer tools, but when I type "phalcon" in the command window, the following error is shown:
C:\>phalcon
Fatal error: Uncaught Error: Class "Phalcon\Script" not found in C:\Users\Joachim\AppData\Roaming\Composer\vendor\phalcon\devtools\phalcon.php:38
Stack trace:
#0 {main}
thrown in C:\Users\Joachim\AppData\Roaming\Composer\vendor\phalcon\devtools\phalcon.php on line 38
C:\>
PSR and Phalcon extensions were successfully installed and I can see them in the WAMP Localhost page.
The Path environment variable contains the path to phalcon, composer, wamp, etc, nothing is missing as far as I can see.
Have anyone dealt with this error?
What could be the problem?
I'm a bit late answering this, but in case anyone else stumbles across it via Google the problem is that some namespaces have been altered between Phalcon4 and Phalcon5. I believe Phalcon\Config is one of those classes.
Until the devtools have been updated for Phalcon5, you'll either need to build the scaffolding manually, or copy an old Phalcon 3 or 4 project and update the namespaces.
The perils of using alpha/beta releases, unfortunately.
you didn't mention which phalcon version but since you are using php 8 the only version supporting php 8 is phalcon 5
your issue is most likely in your php.ini for the cli since wamp uses different files for apache and cli.
to fix the issue first remove the devtools package you installed globally then edit the cli php.ini in [wampDir]\bin\php\php8.0.13\php.ini and include psr and phalcon and install the devtools again using composer
you can also download the phar file here and test it in the cli
php phalcon.phar
I wish to use an erlang client library to communicate with an mqtt broker for one of my projects. So I've started an application using rebar3's built-in templates and added emqttc as a dependency. Since erlang/otp 21 does not have support for gen_logger(emqttc depends on gen_logger) and the tuple_calls compiler options do not suffice, I had to downgrade to erlang#20 according to this post.
Now the issue with downgrading erlang is that, none of rebar3's commands(clean/compile/shell/report etc) work as expected and my previous projects built with rebar3 do not compile, I get to see this error message:
=ERROR REPORT==== 21-Aug-2018::12:54:29 === Loading of /usr/local/bin/rebar3/rebar/ebin/rebar3.beam failed: badfile escript:
exception error: undefined function rebar3:main/1 in function
escript:run/2 (escript.erl, line 759) in call from escript:start/1
(escript.erl, line 277) in call from init:start_em/1 in call from
init:do_boot/3
=ERROR REPORT==== 21-Aug-2018::12:54:29 === beam/beam_load.c(1863): Error loading module rebar3: This BEAM file was compiled for a later
version of the run-time system than 20. To fix this, please
recompile this module with an 20 compiler. (Use of opcode 160; this
emulator supports only up to 159.)
I've uninstalled and reinstalled rebar3, looked up on the web for this but nothing's clear and specific to rebar. Any help on this would be appreciated.
This may not be the exact answer for your question. But it may give you and idea.
What about using Docker. Its an easy way to keep your environment clean and neat.
If you use docker, you just have to include your new erlang version in Dockerfile as an environment variable.
ENV OTP_VERSION="20.3.6"
Check your _build/prod/rel/YOURAPPNAME/ directory. Most probably it has a release which doesn't match your erlang version. You can safely delete this directory and rebuild using rebar3 compile
Env: rebar 3.6.0 on Erlang/OTP 21 Erts 10.0 Ubuntu 16.04
When I try to install the rebar3 pulgins (such as rebar3_hex), it reports:
===> Package <<"rebar3_hex">> not found. Fetching registry updates and trying again...
===> Updating package registry...
===> Plugin rebar3_hex not available. It will not be used.
There is only one line in my ~/.config/rebar3/rebar.config:
{plugins, [rebar3_hex]}.
as recommended in https://www.rebar3.org/docs/using-available-plugins#hex-package-management and https://github.com/tsloughter/rebar3_hex.
I can't get more useful information from google, rebar3 doc and existed question here.
So, I open a new question to ask Why and How to resolve it.
ps: I use proxychains for rebar3, it reports |DNS-response| repo.hex.pm is 151.101.54.2
inet_gethost[10708]: WARNING:Malformed reply (header) from worker process 10709.
In my case, it's fixed when set proxy environmental variable(http_proxy) instead of use proxychains.
I'm kind of newbie in ruby and I'm trying to create a new project in my Win8.1 pc.
I'm using the latest rails installer. The installations ends successfully but when I run rails new my_project I got this error when it is Installing json.
Installing json (1.8.1) creating Makefile
0 [main] make 5852 handle_exceptions: Exception: STATUS_ACCESS_VIOLATION
439 [main] make 5852 open_stackdumpfile: Dumping stack trace to make.exe.stackdump
MSYS-1.0.17 Build:2011-04-24 23:39
Exception: STATUS_ACCESS_VIOLATION at eip=10002840
eax=00000000 ebx=00000000 ecx=75BE6DB4 edx=00000003 esi=00000024 edi=00000001
ebp=0028D638 esp=0028D4A0 program=C:\RailsInstaller\DevKit\bin\make.exe
cs=0023 ds=002B es=002B fs=0053 gs=002B ss=002B
I've try installing as administrator, compatibility mode (win7) and replacing DevKit but nothing works.
Thanks
If you are using rails on windows its obvious that you will have to face so many issues with gems installation, etc. I suggest you to switch to Unix-based system as suggested by Serge Vinogradoff.
If you still wants to continue with windows then you need to check if c compiler is installed on your machine properly or not. If not then RubyInstaller Development Kit may help you: http://rubyinstaller.org/add-ons/devkit/
The devkit installs a C-compiler (and some other stuff) to compile C-written parts.
Install it and try again to install the gem - perhaps with option --platform=ruby.
Also you can try to use json_pure written on pure Ruby
I would suggest to switch to Unix-based system if you want to work with Rails.
I have recently started to work with grails. I was able to create applications and generate stuff. Yesterday I wanted to resume my work, after a little break and ran into the following error, when trying to create a new project:
Command terminated with an exception:
org.grails.ide.eclipse.longrunning.client.GrailsProcessDiedException: Grails process died
(see details for partial output)
Grails process died
------System.out:-----------
------System.err:-----------
This error only occurs when I use the SpringSourceTool, if I try using the command line it works fine. My first reaction was to change the java version from 1.8 to 1.7, but that didn't help. My environment variables look like this (I am running Fedora Linux 19)
JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.0.x86_64
GRAILS_HOME=/home/peer/grails/grails-2.3.0
They are also included in the PATH variable.
Can anybody help? Thanks, Peer
This is a known issue in STS:
https://issuetracker.springsource.com/browse/STS-3277
A work-around is provided in the link.
For anyone pulling their hair out trying to create a grails project using the STS extension for Grails, here is my setup and following is what I did to get it working:
-- OSX 10.8.4 Build 12E3067 --
-- STS Version 3.4.0 --
-- Grails 2.3.3 (installed separately to STS) --
Fresh installed STS 3.4.0
I *de*selected the Preferences/Groovy/Compiler/Enable checking for mismatches between
project and workspace Groovy compiler levels
I ONLY selected the Grails Support option when installing the extensions (nothing else)
Restart STS 3.4.0 (i.e. restart eclipse)
I then pointed my Grails project to my existing Grails 2.3.3 installation
Make sure that the environment variable GRAILS_HOME is set and exported in the same
shell from which you invoke STS otherwise you will get a process termination error in
Eclipse (STS)
This worked.