Repository navigation
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Context
An
sastre deploy --as-diff --rejectagainst staging failed while applying an ERP pull request. The installedapply_pr3.4.8 then raised an ASCII decoding error while handling Git output containing UTF-8 text, which hid the actual patch conflict. Its unconditionalgit stash poprestored pre-existing work over the partially applied diff and left the staging checkout dirty with rejected/partial files.The UTF-8 diagnostic issue has already been addressed on current
masterby #189. This pull request closes the remaining operational gap: failed diff deployments must not leave their partial changes in the target checkout.@abaena-gisce: Això m'ho vaig trobar quan em va petar per tenir accents al cos de la PR quan vaig correr el sastre a l'entorn de python 2 que per defecte no es UTF-8. I et deixa tot el repo brut i amb un estat inconsistent. Hauria de netejar sempre tot el que fa tant els fitxers modificats/creats/eliminats + els .rej. Si no per accident es poden arribar a pujar fitxers o canvis no desitjats. La implementació del giscebot no sé si és correcte això no ho he provat encara.
Changes
HEADcaptured beforegit apply.stash popover an inconsistent checkout.--as-diffdeployments.Regression coverage
--rejecthunks no longer leave.rejfiles or partial changes.Validation
PYTHONPATH=. python -m unittest discover -s tests— 59 tests passed.PYTHONPATH=. python -m unittest discover -s tests— 59 tests passed.git diff --check— clean.Traceability
gisce/erp#29405to staging.