-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Conversation
Hey @AaronTJDev Thanks for the help. So I forgot that ember 3.4 introduced stricter template linting rules by default. @MatthewDorner - What's your thinking on this? Should we ignore the template linting rules and then turn them back on, or try to fix them all up front? @AaronTJDev Would you be willing to give the template linting rules a stab? |
@donaldwasserman Well, l was working on resolving that, but honestly I'm kind of lost on the template-linting issue. I tried running an "eslint --fix" on it, but it wasn't effective. Only thing that was working for me was disabling rules. Are there any automated tools that you could suggest that I look into? |
@AaronTJDev There's two solutions:
module.exports = {
extends: 'recommended',
ignore: ['node_modules/*'],
rules: {
'simple-unless': false,
'link-rel-noopener': false,
'attribute-indentation': false,
}
}; This is copied and pasted from my work's template lint file, so we'd want different values
There may be some functionality in VSCode to deal with this. I'll ask around (I'm not personally a VSCode user) |
So I was looking into the VS Code linting options and found this , https://youtu.be/qYOw2z6Og8I, I already have vs code but don't use it either, so I'll look into it when I have some time. |
config.couchAuthDbURL = config.getProtocol(config.couchDbUseSsl) + config.couchCredentials() + config.couchDbServer + ':' + config.couchDbPort; | ||
// config.searchURL = 'http:https://localhost:9200'; ELASTIC SEARCH URL (OPTIONAL) | ||
config.serverInfo = 'Development Ember CLI server'; | ||
module.exports = config; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file shouldn't get deleted.
I tried the VSCode thing, I think it only works for .js ESLint though, not .hbs ember-template-lint. I am not very familiar with configuring these linters, or even with the upgrade process generally. But any things I can work on to help, I will. Regarding the template errors, seems like a separate task. If there's a way to do it quickly now then we should, but otherwise later. I'm getting more errors on "ember test" than just lint errors so maybe just get this to the point it passes all tests, and then decide what else we should do now and what later. Also @AaronTJDev how did those "avoid-leaking-state-in-components" errors you were discussing in Slack get resolved? |
This extension works for VSCode https://marketplace.visualstudio.com/items?itemName=emberjs.vscode-ember, but doesn't have auto fix. Most common violations are for 'quotes' (must use double quotes) which we can probably fix easily, and then this 'attribute-indentation' as seen in the screenshot. I don't even like that one. Aside from those 2, there are 269 remaining instances of various types, that somebody can fix but will take a while. A lot of them don't seem like they would be fixable automatically even if there was such a tool. |
@donaldwasserman @MatthewDorner Alright, so for now I'll just disable the template lint rules until I can get "ember test" to pass all tests. Also, will restore the config-example.js. As far as the "avoid-leaking-state-in-components" errors, it was an error in how I had resolved the merge conflicts after running ember-cli-update, so I just started from scratch by cloning the repo again and ran a "git checkout --their ." I believe. |
@@ -130,6 +130,16 @@ If you would like to load sample data, you can do so by navigating to **Load DB* | |||
|
|||
![Load DB screenshot](screenshots/load-db.png) | |||
|
|||
<<<<<<< HEAD |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like there is a merge conflict here.
"start": "node script/server.js", | ||
"test": "ember test", | ||
"electron-test": "ember electron:test", | ||
"translation-sync": "babel-node script/translation/sync.js --presets es2015 && eslint --fix app/locales", | ||
"stylelint": "stylelint 'app/styles/**/*.scss'" | ||
}, | ||
"repository": { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like some of these properties got deleted
"ember-browserify": "^1.1.12", | ||
"ember-cli": "2.17.1", | ||
"ember-cli": "~3.5.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you pin this to 3.5.0
instead of ~3.5.0
?
"ember-cli": "~3.5.0", | |
"ember-cli": "3.5.0", |
"ember-concurrency": "0.8.21", | ||
"ember-concurrency-test-waiter": "0.3.1", | ||
"ember-data": "2.18.2", | ||
"ember-data": "~3.5.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See comment about ember-cli versioning
"ember-radio-buttons": "^4.0.1", | ||
"ember-rapid-forms": "^1.2.5", | ||
"ember-resolver": "^5.0.1", | ||
"ember-simple-auth": "^1.5.1", | ||
"ember-sinon-qunit": "3.2.0", | ||
"ember-source": "2.18.2", | ||
"ember-source": "~3.5.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See comment about ember cli versioning
@AaronTJDev That sounds good. I'll look into finding some more automated solutions for handling the template linting errors automatically. |
@MatthewDorner Alright, so I took a step back from this for about a week because I was having a ton of trouble getting the tests to pass. After coming back to it, I realized that it looks like the way the tests are performed have changed. |
Might we want to work on this in a new branch instead of master, so we can separate tasks into multiple smaller PRs? |
regarding the tests, looks like we can try this https://github.com/rwjblue/ember-qunit-codemod |
@MatthewDorner @AaronTJDev I've used the Qunit Codemod and it works really well. I'd say if all the tests pass after you run it, let's just keep it on master. If there are more problems, breaking up is probably the right call |
@MatthewDorner @donaldwasserman Yeah I'm still getting a lot of trouble out of it, breaking up may be the way to go. I tried running ember-qunit-codemod, as well as ember-test-helpers-codemod with little success. |
Fixes #[1528].
Changes proposed in this pull request:
cc @HospitalRun/core-maintainers