Timeline



Jan 30, 2019:

8:16 PM Changeset [1766:eae3caeeb146]default by Stefan Schwarzer <sschwarzer@…>
Use `twine` to upload package to PyPI According to https://truveris.github.io/articles/configuring-pypirc/ , twine uses the `~/.pypirc` configuration file. Note, however, that the section `server-login` is no longer used. Instead, username and password go in the `[pypi]` section. Should the configuration file _not_ be picked up by twine, there's still the possibility of setting the environment variables `TWINE_USERNAME` and `TWINE_PASSWORD`. Of course, care must be taken so that they're only readable/usable by the owner of the PyPI account!
8:02 PM Changeset [1765:5d3932c657ca] by Stefan Schwarzer <sschwarzer@…>
Add TODO on `twine` usage
7:57 PM Changeset [1764:618a99c291d4] by Stefan Schwarzer <sschwarzer@…>
Emphasize missing Python 2 support even more
7:52 PM Changeset [1763:9439a6ed3795] by Stefan Schwarzer <sschwarzer@…>
Add check to prevent Python < 3.5 install Prevent installation with a helpful message before an incompatible pip/setuptools may encounter the `python_requires` keyword argument. See https://python3statement.org/practicalities .
7:28 PM Changeset [1762:d5ce348ec42f] by Stefan Schwarzer <sschwarzer@…>
Add `python_requires` argument to `setup` See https://python3statement.org/practicalities .

Jan 28, 2019:

9:07 PM Changeset [1761:23c1639ea0e5] by Stefan Schwarzer <sschwarzer@…>
Remove `ScriptedSession` from `__all__` `ScriptedSession` shouldn't be used directly. Instead use `factory` to create `ScriptedSession`s implicitly.
9:01 PM Changeset [1760:5eb6ef13362a] by Stefan Schwarzer <sschwarzer@…>
Implement the multi-script factory more clearly Use a class `MultisessionFactory` with a `__call__` method to return consecutive factories that will use the respective scripts from the constructor argument `scripts`. See also the docstring of `MultisessionFactory` for an example.
8:43 PM Changeset [1759:e207929eef6c] by Stefan Schwarzer <sschwarzer@…>
Generalize session factory creation Allow more than one script in the `factory` function. For each script in `scripts`, a new `ScriptedSession` with the corresponding `script` will be used when the factory is called by `FTPHost._make_session`. The implementation seems to work fine, but it's even more difficult to understand than the previous version. I'm considering implementing this with a class.
8:21 PM Changeset [1758:ebd10c7d0d1f] by Stefan Schwarzer <sschwarzer@…>
Explain purpose of `init` call
7:45 PM Changeset [1757:480538e14451] by Stefan Schwarzer <sschwarzer@…>
Print when a session factory is called Print when a session factory is called, in other words, when a new `ScriptedSession` is instantiated. This is very helpful for tests that involve more than one `ScriptedSession` instance, e. g. tests for the download/upload functionality.
7:43 PM Changeset [1756:ad291ad87245] by Stefan Schwarzer <sschwarzer@…>
Prefix `print`s with `ScriptedSession` instance When printing from a `ScriptedSession` instance for tracking/debugging, prepend information on the respective `ScriptedSession` instance. Example: <ScriptedSession at 0x7ff1881a72e8> Expected method name: '__init__' This makes it much clearer what's going on if a test needs more than one `ScriptedSession`.
7:11 PM Changeset [1755:c7abe644763b] by Stefan Schwarzer <sschwarzer@…>
Comment `_index` instance variable
6:29 PM Ticket #116 (Deal with Pylint messages) closed by schwa
fixed: With the current Pylint configuration messages are manageable now. The …
6:16 PM Ticket #110 (Directory listings are empty if a server doesn't support the`-a` option) closed by schwa
fixed: This is changed in master (changeset [766c15f83205]).

Jan 3, 2019:

3:07 PM SubversionVsMercurialRevisions edited by schwa
Point to new mailing list archive (diff)

Jan 2, 2019:

12:19 PM Changeset [1754:ab3eaedc03cb] by Stefan Schwarzer <sschwarzer@…>
Use `ScriptedSession` in `TestRecursiveListingForDotAsPath` Update the tests in `TestRecursiveListingForDotAsPath` to use the new test code in `scripted_session.py`.
12:17 PM Changeset [1753:54a4611470c3] by Stefan Schwarzer <sschwarzer@…>
Simplify "__init__" call assertion `ScriptedSession._next_call` already has an argument for checking if the next call is an expected call. Therefore, just use the argument instead of using an extra `assert` statement.

Jan 1, 2019:

2:50 PM Changeset [1752:1d6514ef2206] by Stefan Schwarzer <sschwarzer@…>
Explain specific error text If we used `result=ftplib.error_perm`, `chmod` would only see a generic `FTPOSError`, not a `CommandNotImplementedError` (which derives from `FTPOSError`).
2:30 PM Changeset [1751:91115f000cd9] by Stefan Schwarzer <sschwarzer@…>
Use `ScriptedSession` in `test_command_not_implemented_error`
2:10 PM Changeset [1750:2930f3422938] by Stefan Schwarzer <sschwarzer@…>
Improve formatting in `test_set_parser`
2:05 PM Changeset [1749:a72b82f6aeaa] by Stefan Schwarzer <sschwarzer@…>
Convert more tests to use `ScriptedSession`
2:04 PM Changeset [1748:59ed56ce841c] by Stefan Schwarzer <sschwarzer@…>
Add `ScriptedSession.dir` method The result handling for this method is different from the default result handling. `dir` will treat its `Call.result` attribute as a multiline string and call the `callback` argument on each line of this multiline string.
1:59 PM Changeset [1747:ffa05876b460] by Stefan Schwarzer <sschwarzer@…>
Improve `Call` and `ScriptedSession` Some of the changes: - Allow passing expected args and kwargs to `Call` constructor and have them checked against the actual args and kwargs. - Move the call logic (raise or return) into the new method `Call.__call__`. - Print more output to help with debugging. (Pytest will print this output only if a test fails.) - Use an integer index instead of an iterator to get the next scripted call. This change makes it easier to "see" in the debugger "where" we are in the execution.

Dec 31, 2018:

11:05 PM Changeset [1746:72d797a82efe] by Stefan Schwarzer <sschwarzer@…>
Add test support class `ScriptedSession` This code is intended as the replacement of (most of) the currently used mock code. In the current mock code, multiple tests sometimes share test data. Hence, a developer must be careful not to add a test and make other tests fail as a side effect. The basis of the new mock code is the class `scripted_session.ScriptedSession`, which is used as (kind of) a replacement for the session factory argument of `FTPHost`. Since `ScriptedSession` needs a `script` parameter that common session factories don't take, I added a helper function `scripted_session.factory`, which takes a `script` and returns a session factory that can be used in `FTPHost`. With the new test code, I could rewrite some of the tests in `test_host.py` rather nicely. I was able to remove the session class `UnnormalizedCurrentWorkingDirectory`. However, I had to keep `FailOnLoginSession`, but only because the class is still used in another test module. I'm not yet sure how well the new approach will work with the remaining tests, but I'm about to find out. I couldn't determine this just by looking at the test code.

Dec 29, 2018:

10:58 PM Ticket #122 (FTPHost() deprecated?) closed by schwa
invalid: I'm closing the ticket as "invalid" since there weren't any further …
10:56 PM Ticket #115 (Use TLS on website) closed by schwa
fixed: Done since a few months, so I close this ticket.
10:36 PM WikiStart edited by schwa
(diff)
10:03 PM Ticket #125 (Add support for removedirs function) created by ftputiluser
As makedirs() is implemented it sounds reasonable to also implement …
9:49 PM Changeset [1745:2402b8a75178] by Stefan Schwarzer <sschwarzer@…>
Unify formatting of XXX-style comments Use consistent format `# XXX: ...` for all FIXME, TODO and XXX comments.
9:31 PM Changeset [1744:194d13209ff4] by Stefan Schwarzer <sschwarzer@…>
Remove remark about Python 2.6 Python 2 support will be removed in ftputil 4.0.0.

Dec 28, 2018:

10:18 PM Changeset [1743:4b773b472e7e] by Stefan Schwarzer <sschwarzer@…>
Disable `protected-access` `_Stat` needs to work closely together with other classes in the `ftputil.stat` module.
10:14 PM Changeset [1742:9993f6af7b40] by Stefan Schwarzer <sschwarzer@…>
Disable message `no-self-use` Keep the `self` argument because derived classes may need it.
10:08 PM Changeset [1741:0a9be69f9436] by Stefan Schwarzer <sschwarzer@…>
Suppress warning about protected access The classes `_Node` and `LRUCache` work closely together. It's ok to access the `_sort_key` attribute of (other) `_Node` instances.
10:04 PM Changeset [1740:bf5ae0f90520] by Stefan Schwarzer <sschwarzer@…>
Don't require `q` to exit `less` Don't require `q` to exit `less` if the output isn't more than a screenful.
10:01 PM Changeset [1739:8a0ab80584c7] by Stefan Schwarzer <sschwarzer@…>
Disable `misplaced-bare-raise` Contrary to what Pylint complains about, this is _not_ an error because the `new_onerror` function is supposed to be called only during handling of an exception.
9:50 PM Changeset [1738:fe7717b0c3ad] by Stefan Schwarzer <sschwarzer@…>
Disable more Pylint messages Disable `no-else-returns` for structures like if condition: return 1 else: return 2 In some cases using `else` here is more "symmetrical" and thus reads better. Disable `unnecessary-pass`. This applies mostly to custom exception classes that have both a docstring and a `pass` after that. I think the `pass` looks good here, even if Python doesn't require it. Of course I could disable these messages only for the above cases, but I think it's not justified to clutter the code with the pragmas if "violating" the respective rule is harmless.
9:48 PM Changeset [1737:4dee27f19dca] by Stefan Schwarzer <sschwarzer@…>
Sort message identifiers alphabetically
9:45 PM Changeset [1736:4c45dfcbf33a] by Stefan Schwarzer <sschwarzer@…>
Update copyright year Update copyright year because of the recent changes to the file.
9:43 PM Changeset [1735:97c07a8b60c9] by Stefan Schwarzer <sschwarzer@…>
Insert empty line above `__all__` assignment
9:42 PM Changeset [1734:4052933a7485] by Stefan Schwarzer <sschwarzer@…>
Remove Python 2 support

Dec 26, 2018:

9:27 PM Changeset [1733:9f3c5bd51a54] by Stefan Schwarzer <sschwarzer@…>
Fix typo Different from the "factory" usage, this typo was _not_ intentional. ;-)
8:54 PM Changeset [1732:a602a48f5f12] by Stefan Schwarzer <sschwarzer@…>
Remove unused imports
8:52 PM Changeset [1731:a4c634fe6853] by Stefan Schwarzer <sschwarzer@…>
Remove unused variable `hour` Also fix docstring. Rounding to full hours would be an error for timezones that contain 0.5-hour or 0.25-hour offsets.
8:49 PM Changeset [1730:28b990e4255c] by Stefan Schwarzer <sschwarzer@…>
Don't disable Pylint `incomplete-protocol` It seems this message no longer exists in current Pylint versions.
8:44 PM Changeset [1729:01e2cbf52b1e] by Stefan Schwarzer <sschwarzer@…>
Disable "bad-whitespace" messages
8:33 PM Changeset [1728:f0d526af5686] by Stefan Schwarzer <sschwarzer@…>
Don't inherit from `object` This is no longer necessary because the next version of ftputil won't support Python 2.
8:15 PM Changeset [1727:2652fb65ded9] by Stefan Schwarzer <sschwarzer@…>
Use `print` as a function in non-code Add parentheses for `print` calls in - documentation - docstrings - comments
8:10 PM Changeset [1726:b9ad96ee9c7b] by Stefan Schwarzer <sschwarzer@…>
Remove Python 2-specific code
8:06 PM Changeset [1725:7cd9bcf41226] by Stefan Schwarzer <sschwarzer@…>
Fix formatting
8:02 PM Changeset [1724:0570e7f70e00] by Stefan Schwarzer <sschwarzer@…>
Make it explicit that we no longer support Python 2
8:00 PM Changeset [1723:7d731aea5360] by Stefan Schwarzer <sschwarzer@…>
Remove positional argument specifiers for `format` In strings for `format` calls, remove the digits for positional arguments. For example, "{0}, {1}" becomes "{}, {}".
7:49 PM Changeset [1722:2500d9b34941] by Stefan Schwarzer <sschwarzer@…>
Remove obsolete features Remove detection of "invalid" features that are either ancient or no longer invalid. "Ancient" is the use of `xreadlines`; this should hardly be used anymore nowadays. "No longer invalid" are detections of byte strings starting with quotes. In Python 3, these are unicode strings, and it's unlikely that code _deliberately_ uses actual byte strings starting with `b`.
3:22 PM Changeset [1721:3557f65ded13] by Stefan Schwarzer <sschwarzer@…>
Remove `compat.py` This module was for Python 2/3 compatibility, similar to the `six` package. Since the next version of ftputil will only support Python 3, hardcode the types from `compat.py` in the code that used to use the `compat` module. There may still be redundant code that isn't needed when running the tests under Python 3.
Note: See TracTimeline for information about the timeline view.