--chaos should warn instead of error on recipe lint checks #497
Closed
opened 2023-10-03 20:20:04 +00:00 by 3wordchant
·
10 comments
Labels
Clear labels
abra
awaiting-feedback
backups
bug
build
ci/cd
community organising
contributing
coopcloud.tech
design
documentation
duplicate
enhancement
fedi
fedi-infra
finance
funding
good first issue
help wanted
installer
legal
performance
proposal
question
security
test
wontfix
Everything to do with abra
Ping/pong on comms
Something is not working
Go build related issues
Getting the robots into the mix
Opening this thing up
Contributors stuff
Our main website
Design thinking required
Let's write things together
This issue or pull request already exists
New feature
Democratic decision making
Money things
Anything related to grant funding
Easy start with development
Need some help
Installation related issues
Performance related
Large change which requires feedback & decisin making
More information is needed
Securing our shit
Unit or integration test suite
This won't be fixed
Milestone
No items
No Milestone
Projects
Clear projects
No projects
Abra v0.11.x
Done
Assignees
3wordchant
aadil (Aadil Ayub)
abra-bot (Abra Bot)
ammaratef45
amras (Sarma)
Apfelwurm
BornDeleuze
Brooke
carla
cas (Cassowary)
coopcloud
cyrnel
decentral1se (d1)
dede
devydave
fauno (fauno)
iexos
jade (Jade Ambrose)
jjsfunhouse
jmakdah2 (Jackie Makdah)
joe-irving (Joe Irving)
kawaiipunk (KawaiiPunk)
knoflook
kolaente
lambdabundesverband
linnealovespie (April)
moosemower
moritz
notplants
oxaliq (sorrel)
p4u1
pharaohgraphy (Andrew 🐦🔥❤️🔥✴️)
renovate-bot (Comrade Renovate Bot)
ripclap
simon
sixsmith (Sixsmith)
stevensting
trav (Trav Fryer)
val (val (he/him))
yksflip
Clear assignees
No Assignees
3wordchant
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: toolshed/organising#497
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Deep in the hacking mines - it feels like the intention of specifying
--chaosshould turn recipe lint errors into warnings@3wordchant True!
The
LintForErrorslogic errors out on first linting error, would you like to see all errors turned into warnings and outputted? That might be a good change to make in general, to see all possible errors/warnings at once instead of running into them one by one?Altho, probably the simplest thing to do on the code side would be to warn and skip linting altogether when
--chaos. Unless you think it's handy & worth it to see your potential errors while--chaos'in ❔OK I think I have it, in
calix/497:Multi-line display of the linting errors is a little wacky, but functional. @decentral1se what do you reckon UI-wise?
Looking good @3wordchant! I'm not actually sure why we even do
lint error in test configs: ...? It seems like double logging since we have the line above it already? Sure do whatever is handiest on your side. I'll be happy to review whatever.Yeah, down to remove duplication. So you reckon the output should be like this (1):
Or like this (2):
Sorry, yeh this is going a bit into refactor territory... but all these outputs seem really noisy to me now that I see them again. No strong feelings on it though, so proceed as you see fit. I'm also looking into the code, I'm like of course saying to myself: "why did I do this" 😂
I was thinking why can it not just be:
So, just detect that there is a critical failure and fail without further duplicate logging. And actually, now that I look at
LintForErrorsinpkg/lint/recipe.go, I see that it bails out on the first error and doesn't show all the possible errors, so that could even be a bonus?Slipping out the backdoor now...
Because my output has two different lint errors:
Because you said:
And I thought "yes that would be neat".
I agree having 2x "failed lint checks" is nonideal, how about:
@3wordchant ah sorry, going in circles 😅 that bullet-point one looks legit!
OK makingitso
@decentral1se am I correct that we still want to just unconditionally bail in
upgradeandrollbackwhich have no--chaosoption?@3wordchant i believe so? If the code is doing that then probably that is what people expect 🤔