I'm trying to launch Chromium edge browser using codeceptjs framework. I'm new to codeceptjs. My scripts are running fine with Chrome and Firefox browsers but, getting following error with Chromium edge.
Error: Can't connect to WebDriver.
Error: Failed to create session.
Unable to create session from {
"desiredCapabilities": {
"browserName": "edge",
"ms:edgeChromium": true,
"platformName": "windows",
"browserVersion": "88.0.705.81"
},
"capabilities": {
"firstMatch": [
{
"browserName": "edge",
"browserVersion": "88.0.705.81",
"ms:edgeChromium": true,
"platformName": "windows"
}
]
}
}
Build info: version: '3.141.59', revision: 'e82be7d358', time: '2018-11-14T08:25:53'
System info: host: 'XXX', ip: 'YYY', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0',
java.version: '1.8.0_231'
Driver info: driver.version: unknown
Please make sure Selenium Server (ChromeDriver or PhantomJS) is running and accessible
Can someone please help me here?
I think browser name should be MicrosoftEdge. At least it's working such way using Selenoid
Related
I'm working on the observability part of Opensearch so I'm trying to collect the trace data of a wordpress website and send it to Opensearch.
I'm collecting the trace data using the wordpress plugin Decalog, this later sends the data to Jaeger agent, then from jaeger i'm sending the data to Opentelemetry and then to Data prepper and lastly to Opensearch.
Jaeger agent service in docker-compose :
jaeger-agent:
container_name: jaeger-agent
image: jaegertracing/jaeger-agent:latest
command: [ "--reporter.grpc.host-port=otel-collector:14250" ]
ports:
- "5775:5775/udp"
- "6831:6831/udp"
- "6832:6832/udp"
- "5778:5778/tcp"
networks:
- our-network
The "command" ligne got me this error : Err: connection error: desc = "transport: Error while dialing dial tcp: lookup otel-collector on 127.0.0.11:53: server misbehaving"","system":"grpc","grpc_log":true
So I changed otel-collector to the IP of the otel-collector container.
Otel collector and data prepper are installed using docker-compose.
data-prepper:
restart: unless-stopped
container_name: data-prepper
image: opensearchproject/data-prepper:latest
volumes:
- ./data-prepper/examples/trace_analytics_no_ssl.yml:/usr/share/data-prepper/pipelines.yaml
- ./data-prepper/examples/data-prepper-config.yaml:/usr/share/data-prepper/data-prepper-config.yaml
- ./data-prepper/examples/demo/root-ca.pem:/usr/share/data-prepper/root-ca.pem
ports:
- "21890:21890"
networks:
- our-network
depends_on:
- "opensearch"
otel-collector:
container_name: otel-collector
image: otel/opentelemetry-collector:0.54.0
command: [ "--config=/etc/otel-collector-config.yml" ]
working_dir: "/project"
volumes:
- ${PWD}/:/project
- ./otel-collector-config.yml:/etc/otel-collector-config.yml
- ./data-prepper/examples/demo/demo-data-prepper.crt:/etc/demo-data-prepper.crt
ports:
- "4317:4317"
depends_on:
- data-prepper
networks:
- our-network
The configuration of otel.yaml (to send data from opentelemetry to opensearch):
receivers:
jaeger:
protocols:
grpc:
exporters:
otlp/2:
endpoint: data-prepper:21890
tls:
insecure: true
insecure_skip_verify: true
logging:
service:
pipelines:
traces:
receivers: [jaeger]
exporters: [logging, otlp/2]
The configuration for data prepper pipeline : entry-pipeline:
delay: "100"
source:
otel_trace_source:
ssl: false
sink:
- pipeline:
name: "raw-pipeline"
- pipeline:
name: "service-map-pipeline"
raw-pipeline:
source:
pipeline:
name: "entry-pipeline"
prepper:
- otel_trace_raw_prepper:
sink:
- opensearch:
hosts: [ "http://localhost:9200" ]
cert: "/usr/share/data-prepper/root-ca.pem"
username: "admin"
password: "admin"
trace_analytics_raw: true
service-map-pipeline:
delay: "100"
source:
pipeline:
name: "entry-pipeline"
prepper:
- service_map_stateful:
sink:
- opensearch:
hosts: ["http://localhost:9200"]
cert: "/usr/share/data-prepper/root-ca.pem"
username: "admin"
password: "admin"
trace_analytics_service_map: true
As of now I'm getting the following errors:
Jaeger agent :
Err: connection error: desc = \"transport: Error while dialing dial tcp otel-collector-container-IP:14250: i/o timeout\"","system":"grpc","grpc_log":true}
Open telemetry collector :
2022-08-04T15:31:32.675Z info pipelines/pipelines.go:78 Exporter is starting... {"kind": "exporter", "data_type": "traces", "name": "logging"}
2022-08-04T15:31:32.675Z info pipelines/pipelines.go:82 Exporter started. {"kind": "exporter", "data_type": "traces", "name": "logging"}
2022-08-04T15:31:32.675Z info pipelines/pipelines.go:78 Exporter is starting... {"kind": "exporter", "data_type": "traces", "name": "otlp/2"}
2022-08-04T15:31:32.682Z info pipelines/pipelines.go:82 Exporter started. {"kind": "exporter", "data_type": "traces", "name": "otlp/2"}
2022-08-04T15:31:32.682Z info pipelines/pipelines.go:86 Starting processors...
2022-08-04T15:31:32.682Z info pipelines/pipelines.go:98 Starting receivers...
2022-08-04T15:31:32.682Z info pipelines/pipelines.go:102 Exporter is starting... {"kind": "receiver", "name": "jaeger", "pipeline": "traces"}
2022-08-04T15:31:32.683Z info static/strategy_store.go:203 No sampling strategies provided or URL is unavailable, using defaults {"kind": "receiver", "name": "jaeger", "pipeline": "traces"}
2022-08-04T15:31:32.683Z info pipelines/pipelines.go:106 Exporter started. {"kind": "receiver", "name": "jaeger", "pipeline": "traces"}
2022-08-04T15:31:32.683Z info service/collector.go:220 Starting otelcol... {"Version": "0.54.0", "NumCPU": 2}
2022-08-04T15:31:32.683Z info service/collector.go:128 Everything is ready. Begin running and processing data.
2022-08-04T15:31:32.684Z warn zapgrpc/zapgrpc.go:191 [core] [Channel #1 SubChannel #2] grpc: addrConn.createTransport failed to connect to {
"Addr": "data-prepper:21890",
"ServerName": "data-prepper:21890",
"Attributes": null,
"BalancerAttributes": null,
"Type": 0,
"Metadata": null
}. Err: connection error: desc = "transport: Error while dialing dial tcp data-prepper-container-ip:21890: connect: connection refused" {"grpc_log": true}
Data prepper :
Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.amazon.dataprepper.DataPrepper]: Constructor threw exception; nested exception is java.lang.RuntimeException: No valid pipeline is available for execution, exiting
Followed by this at the end :
WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance.
2022-08-04T15:23:22,803 [main] INFO com.amazon.dataprepper.parser.config.DataPrepperAppConfiguration - Command line args: /usr/share/data-prepper/pipelines.yaml,/usr/share/data-prepper/data-prepper-config.yaml
2022-08-04T15:23:22,806 [main] INFO com.amazon.dataprepper.parser.config.DataPrepperArgs - Using /usr/share/data-prepper/pipelines.yaml configuration file
Opensearch needs a separate tool to support ingestion of Opentelemetry data. It is called DataPrepper and is part of the Opensearch project. There is a nice getting started guide on how to set up trace analytics in Opensearch.
DataPrepper works similar as Fluentd or the Opentelemetry Collector, but has proper support for Opensearch as a data sink. It pre-processes trace data adequately for the Opensearch Dashboards UI tracing plugin. DataPrepper also supports the Opentelemetry metrics format.
Are you still having issues running Data Prepper? The configuration used in this example has been updated since the latest release, and should now be up to date and working (https://github.com/opensearch-project/data-prepper/blob/main/examples/trace_analytics_no_ssl.yml)
I've been working with Symfony 2.7 and the RabbitMQBundle to handle some long processes asynchronously.
After facing the issue where the MySQL connection dies after a few minutes, I discovered rabbitmq-cli-consumer, a small app in Go that takes care of consuming the queue, and gives its content to a command.
In my case, I use it with this command: ./rabbitmq-cli-consumer -c configuration-stock.conf --include -V -e 'php app/console amqp:consume:stock --env=prod -vvv', with this configuration file:
[rabbitmq]
host = HOST
username = USERNAME
password = PASSWORD
vhost=/VHOST
port=PORT
queue=stock
compression=Off
[exchange]
name=exports
type=direct
durable=On
[queuesettings]
routingkey=stock
messagettl=10000
deadLetterExchange=exports.dl
deadLetterroutingkey=stock
priority=10
To handle errors, I intend to use RabbitMQ's x-dead-letter-exchange and x-dead-letter-routing-key configuration, to be able to retry the message later (in case something went temporarly wrong).
My issue is that, when I define my queues in RabbitMQBundle's configuration, rabbitmq-cli-consumer is unable to consume the queue, throwing this error:
2018/04/23 11:35:54 Connecting RabbitMQ...
2018/04/23 11:35:54 Connected.
2018/04/23 11:35:54 Opening channel...
2018/04/23 11:35:54 Done.
2018/04/23 11:35:54 Setting QoS...
2018/04/23 11:35:54 Succeeded setting QoS.
2018/04/23 11:35:54 Declaring queue "stock"...
2018/04/23 11:35:54 Registering consumer...
2018/04/23 11:35:54 failed to register a consumer: Exception (504) Reason: "channel/connection is not open"
Here is the configuration I use for RabbitMQBundle:
old_sound_rabbit_mq:
producers:
exports:
connection: default
exchange_options:
name: 'exports'
type: direct
exports_dl:
connection: default
exchange_options:
name: 'exports.dl'
type: direct
consumers:
stock_dead_letter:
connection: default
exchange_options:
name: exports.dl
type: direct
queue_options:
name: stock.dl
routing_keys:
- stock
arguments:
x-dead-letter-exchange: ['S', 'exports']
x-dead-letter-routing-key: ['S', 'stock']
x-message-ttl: ['I', 60000]
callback: amqp.consumers.exports.stock
multiple_consumers:
exports:
connection: default
exchange_options:
name: 'exports'
type: direct
queues:
stock:
name: stock
callback: amqp.consumers.exports.stock
routing_keys:
- stock
arguments:
x-dead-letter-exchange: ['S', 'exports.dl']
x-dead-letter-routing-key: ['S', 'stock']
Has anyone ever encountered something similar ? And how did you solve it ?
I am testing my meteor app's UI with some browser tests. I use http://webdriver.io and a selenium chrome https://hub.docker.com/r/selenium/standalone-chrome/ node.
I use the webdriver.io testrunner for tests and mocha as the test framework.
When I enter this block inside a jade template (by opening the corresponding page):
Template.boardBody.onRendered(function() {
let imagePath = new ReactiveVar('');
this.autorun(() => {
imagePath.set(Meteor.settings.public.backgroundPath[1]);
//document.getElementsByClassName('board-wrapper')[0].style.backgroundImage = "url('" + imagePath.get() + "')";
$('.board-wrapper').css('background-image', "url('" + path + "')");
});
}
The headless chrome crashes with this error:
{ Error: An unknown server-side error occurred while processing the command.
at BoardPage.open (tests/board.page.js:20:5)
at Context.<anonymous> (tests/board.test.js:22:17)
at Promise.F (node_modules/core-js/library/modules/_export.js:35:28)
at execute(<Function>) - at BoardPage.open (tests/page.js:11:13)
message: 'unknown error: session deleted because of page crash\nfrom tab crashed',
type: 'RuntimeError',
screenshot: 'Just a black page',
seleniumStack:
{ status: 13,
type: 'UnknownError',
message: 'An unknown server-side error occurred while processing the command.',
orgStatusMessage: 'unknown error: session deleted because of page crash\nfrom tab crashed\n (Session info: chrome=59.0.3071.115)\n (Driver info: chromedriver=2.30.477691 (6ee44a7247c639c0703f291d320bdf05c1531b57),platform=Linux 4.4.4-200.fc22.x86_64 x86_64) (WARNING: The server did not provide any stacktrace information)\nCommand duration or timeout: 4.13 seconds\nBuild info: version: \'3.4.0\', revision: \'unknown\', time: \'unknown\'\nSystem info: host: \'f362d8ab8951\', ip: \'172.17.0.1\', os.name: \'Linux\', os.arch: \'amd64\', os.version: \'4.4.4-200.fc22.x86_64\', java.version: \'1.8.0_131\'\nDriver info: org.openqa.selenium.chrome.ChromeDriver\nCapabilities [{applicationCacheEnabled=false, rotatable=false, mobileEmulationEnabled=false, networkConnectionEnabled=false, chrome={chromedriverVersion=2.30.477691 (6ee44a7247c639c0703f291d320bdf05c1531b57), userDataDir=/tmp/.org.chromium.Chromium.NUsUeZ}, takesHeapSnapshot=true, pageLoadStrategy=normal, databaseEnabled=false, handlesAlerts=true, hasTouchScreen=false, version=59.0.3071.115, platform=LINUX, browserConnectionEnabled=false, nativeEvents=true, acceptSslCerts=true, locationContextEnabled=true, webStorageEnabled=true, browserName=chrome, takesScreenshot=true, javascriptEnabled=true, cssSelectorsEnabled=true, unexpectedAlertBehaviour=}]\nSession ID: f1e261ec57fde3697e98945af051d236' },
shotTaken: true }
I use chai.expect for my assertion statements and i have a feeling that the promises are somehow messing up the headless chrome.
Anyone knows why this is happening?
I'm using RSelenium to construct a data frame with information about managers. I have problem to select an element in a drop-down list.
My code is the following:
> require(RSelenium)
> remDr<-remoteDriver(browserName = "chrome")
> remDr$open()
> enlace<-'https://www.sisben.gov.co/atencion-al-ciudadano/Paginas/Directorio-administradores.aspx'
> remDr$navigate(enlace)
> remDr$findElement(using = "xpath", '//*[#id="ddlDepartamento"]/option[2]')$clickElement()
With the last line, I obtain the following error:
Selenium message:no such element: Unable to locate element: {"method":"xpath","selector":"//*[#id="ddlMunicipio"]"}
(Session info: chrome=58.0.3029.110)
(Driver info: chromedriver=2.27.440174 (e97a722caafc2d3a8b807ee115bfb307f7d2cfd9),platform=Windows NT 10.0.14393 x86_64) (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 140 milliseconds
For documentation on this error, please visit: http://seleniumhq.org/exceptions/no_such_element.html
Build info: version: '3.2.0', revision: '8c03df6', time: '2017-03-02 09:34:51 -0800'
System info: host: 'PATY-FRAN', ip: '192.168.0.20', os.name: 'Windows 10', os.arch: 'x86', os.version: '10.0', java.version: '1.8.0_121'
Driver info: org.openqa.selenium.chrome.ChromeDriver
Capabilities [{applicationCacheEnabled=false, rotatable=false, mobileEmulationEnabled=false, networkConnectionEnabled=false, chrome={chromedriverVersion=2.27.440174 (e97a722caafc2d3a8b807ee115bfb307f7d2cfd9), userDataDir=C:\Users\victor\AppData\Local\Temp\scoped_dir6076_6551}, takesHeapSnapshot=true, pageLoadStrategy=normal, databaseEnabled=false, handlesAlerts=true, hasTouchScreen=false, version=58.0.3029.110, platform=XP, browserConnectionEnabled=false, nativeEvents=true, acceptSslCerts=true, locationContextEnabled=true, webStorageEnabled=true, browserName=chrome, takesScreenshot=true, javascriptEnabled=true, cssSelectorsEnabled=true, unexpectedAlertBehaviour=}]
Session ID: 0815f4f9dcca9d364a7c15b4a50352e7
*** Element info: {Using=xpath, value=//*[#id="ddlMunicipio"]}
Error: Summary: NoSuchElement
Detail: An element could not be located on the page using the given search parameters.
class: org.openqa.selenium.NoSuchElementException
Further Details: run errorDetails method
I will be grateful with your help.
The content is in an iframe. You need to switch to the iframe first:
library(RSelenium)
rD<-rsDriver()
remDr <- rD$client
enlace<-'https://www.sisben.gov.co/atencion-al-ciudadano/Paginas/Directorio-administradores.aspx'
remDr$navigate(enlace)
# content is in iframe
frames <- remDr$findElements("css", "iframe")
# switch to first iframe
remDr$switchToFrame(frames[[1]])
selectElem <- remDr$findElement("id", "ddlDepartamento")
selectOpt <- selectElem$selectTag()
> selectOpt$text
[1] "AMAZONAS" "ANTIOQUIA" "ARAUCA" "ATLANTICO"
[5] "BOGOTÁ D.C." "BOLIVAR" "BOYACA" "CALDAS"
[9] "CAQUETA" "CASANARE" "CAUCA" "CESAR"
[13] "CHOCO" "CORDOBA" "CUNDINAMARCA" "GUAINIA"
[17] "GUAJIRA" "GUAVIARE" "HUILA" "MAGDALENA"
[21] "META" "NARIÑO" "NORTE DE SANTANDER" "PUTUMAYO"
[25] "QUINDIO" "RISARALDA" "SAN ANDRES" "SANTANDER"
[29] "SUCRE" "TOLIMA" "VALLE" "VAUPES"
[33] "VICHADA"
# click 2nd one
selectOpt$elements[[2]]$clickElement()
....
....
rm(rD)
gc()
I'm new to dynamoDB. I have created a table and am trying to insert data into the table. It works well when I connect from my home internet. But when I try from my office network, I get the below error:
I suspect this is due to proxy issues. Can you please help me resolve this issue? Thank you.
[UnknownEndpoint: Inaccessible host: dynamodb.ap-southeast-2.amazonaws.com'. This service may not be available in theap-southeast-2' region.]
message: 'Inaccessible host: dynamodb.ap-southeast-2.amazonaws.com\'. This service may not be available in theap-southeast-2\' region.',
code: 'UnknownEndpoint',
region: 'ap-southeast-2',
hostname: 'dynamodb.ap-southeast-2.amazonaws.com',
retryable: true,
originalError:
{ [NetworkingError: getaddrinfo ENOTFOUND dynamodb.ap-southeast-2.amazonaws.com dynamodb.ap-southeast-2.amazonaws.com:443]
message: 'getaddrinfo ENOTFOUND dynamodb.ap-southeast-2.amazonaws.com dynamodb.ap-southeast-2.amazonaws.com:443',
code: 'NetworkingError',
errno: 'ENOTFOUND',
syscall: 'getaddrinfo',
hostname: 'dynamodb.ap-southeast-2.amazonaws.com',
host: 'dynamodb.ap-southeast-2.amazonaws.com',
port: 443,
region: 'ap-southeast-2',
retryable: true,
time: Mon Sep 21 2015 11:19:58 GMT+1000 (AUS Eastern Standard Time) },
time: Mon Sep 21 2015 11:19:58 GMT+1000 (AUS Eastern Standard Time) }
Thank you for the pointers. I managed to solve the issue using below code snipped.
var proxy = require('proxy-agent');
AWS.config.update({
httpOptions: {
agent: proxy('http://{user_name}:{password}#<proxy>:<port>')
}
});
This is documented in amazon's aws-sdk configuration site: http://docs.aws.amazon.com/AWSJavaScriptSDK/guide/node-configuring.html