How can I debug FireFox when it won't load local add-on? - firefox-addon

I'm working on a Browser extension/add-on. We have it working in Chrome, so I'm trying to get it working in Firefox.
When I try to load it in my current version of Firefox by visiting about:debugging and selecting its manifest.json on Mac 47.0.1, it silently fails.
I've found success by installing the FirefoxDeveloperEdition, but is there another way?

Related

In Fitnesse I am getting an error when I try to run tests but my coworkers are able to run tests on the same scripts with no problem

Here's what some of it looks like:
script com.appiancorp.ps.automatedtest.fixture.SitesFixture Could not invoke constructor for com.appiancorp.ps.automatedtest.fixture.SitesFixture[0]
setup with The instance scriptTableActor.setupWithBrowser. does not exist CHROME browser
set appian version to The instance scriptTableActor.setAppianVersionTo. does not exist 19.4
set appian locale to The instance scriptTableActor.setAppianLocaleTo. does not exist
I do have Chrome installed and chrome driver and I opened fitnesse through chrome.
Obviously, the problem is that you don't have Chrome installed.

How to run cypress open with electron

I am having issues with cy.visit hanging in electron only, but chrome is fine. There are no errors in the console with cypress run, so would like to run cypress open with electron, but not sure how. cypress open --browser electron or node_modules/cypress/bin/cypress open --browser node_modules/electron/dist/Electron.app/Contents/MacOS/Electron doesn't work.
I have tried cypress run --headed but cypress run doesn't allow you to stop the test mid way through and investigate what is wrong. Pausing the test closes the window.
As stated in the docs about the open command, the browser flag is used only to specify a path to a custom browser to be added to the list of available browsers in Cypress. Electron being the default browser bundled with Cypress, you don't have to specify it when launching the UI. You can choose any browser you need on the UI before launching a test suite (see screenshoot).

Failed to load packages - Dart Angular Tutorial

I tried to follow the tutorial of Angular with Dart.
Everything worked fine until I got to the navigation chapter.
When I run the project with webstorm and chromium I always get this error.
I also tried to run the solution repo but I get the same error.
It seems like these packages browser / angular etc. are not loaded.
Perhaps there are some restrictions by webstorm?! The funny thing is it worked occasionally on the first run but when I refreshed the page in the browser the error always comes back.
http://localhost:63342/toh-5-master/web/packages/browser/dart.js Failed to load resource: the server responded with a status of 404 (Not Found)
http://localhost:63342/toh-5-master/web/packages/angular/angular.dart Failed to load resource: the server responded with a status of 404 (Not Found)
package:angular/angular.dart:1 An error occurred loading file: package:angular/angular.dart
http://localhost:63342/toh-5-master/web/packages/angular_router/angular_router.dart Failed to load resource: the server responded with a status of 404 (Not Found)
package:angular_router/angular_router.dart:1 An error occurred loading file: package:angular_router/angular_router.dart
http://localhost:63342/toh-5-master/web/packages/angular_tour_of_heroes/app_component.dart Failed to load resource: the server responded with a status of 404 (Not Found)
package:angular_tour_of_heroes/app_component.dart:1 An error occurred loading file: package:angular_tour_of_heroes/app_component.dart
EDIT
The things above are working now because I changed to this repo:
github.com/angular-examples/toh-5/tree/5-dev which works with Dart 2.
Right now I have another problem with the new 5-dev repo.
Here is my console of pub serve. It says the main.template.dart is missing.
(I'm using the Dart version 2.0.0-dev.44.0.)
Does anyone how to fix this problem??
Compiling angular_tour_of_heroes|web/main.dart...
[web] GET styles.css => (cached) angular_tour_of_heroes|web/styles.css
[Error from Dart2JS on angular_tour_of_heroes|web/main.dart]:
file:///C:/xampp/htdocs/flutterprojects/toh-5-5-dev/web/main.template.dart: Could not find asset angular_tour_of_heroes|web/main.template.dart.
[Info from Dart2JS]:
Took 0:00:03.911463 to compile angular_tour_of_heroes|web/main.dart.
Build completed with 1 errors.
[web] GET main.dart.js => Could not find asset angular_tour_of_heroes|web/main.dart.js.
[web] GET index.html => angular_tour_of_heroes|web/index.html
When I run it directly with the console I get the following error.
> pub serve --web-compiler=dartdevc
Build completed successfully
[web] GET => angular_tour_of_heroes|web/index.html
[web] GET styles.css => angular_tour_of_heroes|web/styles.css
Unable to find module for angular|lib/src/bootstrap/modules.template.dart
Unable to find module for angular|lib/src/bootstrap/modules.template.dart
Unable to find module for angular|lib/src/bootstrap/modules.template.dart
For Angular 4 example apps
Load failures like this can happen if you have an error in your app that is preventing dart2js from compiling it successfully. Are any errors or warnings being reported by pub in WebStorm's Pub Serve tab? Also make sure that you are using version 1.24.3 of the Dart SDK.
I'm unable to reproduce the problem you mention. I've downloaded the project zip, and it runs fine from both the command line and WebStorm (even after making some edits and refreshing). Note that the first time you load the app, you might get a 404 because pub might not have finished compiling your app yet.
For Angular 5 example apps
As you've found out, if you'd like to try out an example using Angular 5-alpha, switch to the 5-dev branch of the repo. Ensure that you are using at least a Dart 2-dev version of the SDK.
The Dart 2 SDK no longer has support for pub build and pub serve. As of 2018Q2 you cannot use WebStorm to build and serve Angular 5 apps. Instead, you'll need to do that from the command line:
pub run build_runner serve
Then open localhost:8080 in Chrome.
For the full details see the Angular 5 Setup for Development.
Angular 5 is nearly out. I can imagine that the TOH hasn't quite caught up. You can look at https://github.com/dart-lang/site-webdev.git to see the known issues.

Firefox addon element abnormally flashing using CSS animation on Mac

The problem only happens on Mac:
The 'Test Link' element flashes abnormally when used in a Firefox addon panel (sdk/panel) when compared to the JSFiddle demo despite they share the same source code.
Firefox addon source code: https://drive.google.com/file/d/0BzHBWuszZv5_eWl1RTdIOW84NG8/view?usp=sharing
to run
download and unzip
$ cd CSSFlashing3; cfx run
Is there any workaround to the problem because who knows how long does it take for Mozilla to fix this?

main.dart not found since upgrade to Dart 1.9.1

Since I upgraded to Dart 1.9.1 whenever I try to run my main.dart by clicking in Run in Dartium or Run as JavaScript I get this error on the browsers console
Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost:8080/main.dart
Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost:8080/main.dart.js
I tried running my own bin/server.dart so I didn't rely on the pub server to serve my static files. From this script, the directions to reach the web folder usually where "../web", I had to change this to just "web" in order for this to work.
Was there a change I am not aware? Is this a bug?
Edit
I also get this message on Dartium
You are using an unsupported command-line flag: --no-sandbox. Stability and security will suffer.
Update
The directory problem might be because of a change an update in Shelf or Redstone. I did a pub update as suggested and that might have changed the way the framework looked for folders.
The problem seems to be that you're trying to run an application (server-side) as a website.
If you press the icon next to the run icon and in the dropdown menu click on "Manage launches" you can click the left of the icons (the server-icon) which allows you to run a CommandLine application.
If you select your dart script here (server.dart or main.dart) you'll be able to use it.

Resources