- Jun 08, 2020
-
-
Georges Racinet authored
Apparently, the recently released dulwich 0.20 requires Python 3
-
Georges Racinet authored
-
Georges Racinet authored
I was glad not to see the stupidest of all rules any more, turns out that was only because we were running an old version of flake8. In a nutshell, this rule is harmful, line breaks before binary *boolean* operators are useful for clarity. I've grumpily tolerated this rule in the past on new codebases. Won't waste time on it for an existing code base because of a linter version change.
-
Georges Racinet authored
We're using 'l' as identifier only when there's no ambiguity (very short-lived loop where it essentially doesn't matter and can't be confused with '1' in context)
-
- Jun 07, 2020
-
-
Georges Racinet authored
We're going to add more in the `heptapod.gitlab` package
-
- May 28, 2020
-
-
Georges Racinet authored
-
Georges Racinet authored
-
Georges Racinet authored
-
- May 27, 2020
-
-
Georges Racinet authored
This will help with heptapod#278 and anything that gives rise to doubts as to what's exactly sent.
-
- May 23, 2020
-
-
Georges Racinet authored
-
- May 22, 2020
-
-
Georges Racinet authored
-
Georges Racinet authored
Previously, it was actually expecting the current working directory to be in a Mercurial repository, which works only coincidentally on Heptapod source installations made from a repo.
-
Georges Racinet authored
Testing that a branch name encoded in iso-latin-1 is presented as-is to Git.
-
- May 21, 2020
-
-
Georges Racinet authored
It's cool to write tests, it's better to have assertions.
-
Georges Racinet authored
`ui.write()` expects bytes, but we were feeding `str`. Of course wasn't catched by our tests, since they rely on patching `ui.write()`
-
Georges Racinet authored
and that means we have to fix for py3.
-
- May 15, 2020
-
-
Georges Racinet authored
main use case: displaying detailed version info in the Rails UI (heptapod#199, heptapod#271) - the information we need - as JSON, since parsing that is a solved problem
-
- May 18, 2020
-
-
Georges Racinet authored
Because Mercurial is loaded through PYTHONPATH, it's not visible to pip (even if we'd set PYTHONPATH for the pip command), therefore that triggers download/build/install of an unrelated Mercurial version.
-
- May 17, 2020
-
-
Georges Racinet authored
-
Georges Racinet authored
-
Georges Racinet authored
The common ci-base image will probably not live very long (see octobus/ci-dockerfiles#2), forcing us to make two steps later. We'll see.
-
- May 18, 2020
-
-
Georges Racinet authored
Since we have base images for both, it's quite fast.
-
- May 17, 2020
-
-
Georges Racinet authored
While we have plans to remove the auxiliary Git mirror repository used to expose content to the web app as soon as in Heptapod 0.14, we know that this won't be possible before a longer time for the repositories backing the wikis. Also this allows us to test with python3 earlier, and it's not completely excluded that 0.14 could support both Python 2 and Python 3. As a side note, the difference in representation of bytes string between the two Python versions force us to resort to assertions with poor style in doctests. We'll live with that.
-
- May 16, 2020
-
-
Georges Racinet authored
-
Georges Racinet authored
The declarations for these booleans were already spelled as bytes.
-
Georges Racinet authored
Actually, only the tests needed to be ported.
-
Georges Racinet authored
To recall, this patch gives limited access (as system environment variables) to ui.environ (can be from WSGI)
-
- May 20, 2020
-
-
Georges Racinet authored
-
Georges Racinet authored
This forced us to clean up the situation with HTTP error responses. - the status line now conforms to the common practice (no user level message) - the body (error details) is normalized to UTF-8. This gives us simpler code paths and the odds of outputting garbage are very low (complete assessment in the comment, keep in mind that we'll be supporting python2 for one or two months at most in Heptapod).
-
Georges Racinet authored
In the case of `gitlab-mirror`, at this point the underlying command from `hgext3rd.heptapod` is not ported.
-
- May 17, 2020
-
-
Georges Racinet authored
This was on Python2 neatly solved by using `repr()` or `%r` now we have to do it on our side.
-
- May 16, 2020
-
-
Georges Racinet authored
GitLab filesystem paths are enforced to be ASCII, see `app/validators/project_path_validator.rb` and `lib/gitlab/path_regex.rb`. The paradigm here is that output sent back to the caller will have to be as bytes, since we'll be in Mercurial code. The `format_` functions all take unicode strings as input, so that alignments are less wrong than with bytes. Mostly all of this is ASCII anyway at this point, but it doesn't harm to be somewhat ready for i18n in push messages. Overall, we prefer to have occasional `?` replacement marks rather than failed pushes (these can be business critical for our users).
-
- May 20, 2020
-
-
Georges Racinet authored
The conventions about incoming strings had to be made explicit, which led us to initiate a proper docstring for `LocalRepoWrapper`. Of course that doesn't mean that the convention is perfectly respected, but it can be considered a specification. We already have at least one case that needs conversions, to be handled when the need arises.
-
Georges Racinet authored
This is the minimum so that Mercurial accepts to load it. In turn the heptapod extension is used as an example of how to load an extension in tests in `test_testhelpers`, so this intermediate change is needed to port testhelpers to Python3. Of course we should use another extension, perhaps one shipping with Mercurial so that testhelpers don't depend onto hgext3rd.heptapod any more, but that will be another day.
-
- May 17, 2020
-
-
Georges Racinet authored
Without it, we can't be sure there aren't unicode strings passed to `ui.note()` and the like.
-
Georges Racinet authored
-
- May 18, 2020
-
-
Georges Racinet authored
This will be useful on CI where it can depend how pytest has actually been installed, especially on Python3.
-
- May 16, 2020
-
-
Georges Racinet authored
-
Georges Racinet authored
-
- May 19, 2020
-
-
Georges Racinet authored
-