- Jan 30, 2025
-
- Jan 28, 2025
-
-
dependabot[bot] authored
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 5.3.0 to 5.4.0. - [Release notes](https://github.com/actions/setup-python/releases) - [Commits](https://github.com/actions/setup-python/compare/v5.3.0...v5.4.0 ) --- updated-dependencies: - dependency-name: actions/setup-python dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by:
dependabot[bot] <support@github.com>
-
- Oct 25, 2024
-
-
dependabot[bot] authored
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 5.2.0 to 5.3.0. - [Release notes](https://github.com/actions/setup-python/releases) - [Commits](https://github.com/actions/setup-python/compare/v5.2.0...v5.3.0 ) --- updated-dependencies: - dependency-name: actions/setup-python dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by:
dependabot[bot] <support@github.com>
-
- Oct 18, 2024
-
-
Marc Troelitzsch authored
closes #128
-
Marc Troelitzsch authored
Refactored `Site.expandtemplates` to use the updated API, addressing deprecation warnings in recent MediaWiki versions. The older API triggered the following warnings: ``` WARNING:mwclient.client:Subscribe to the mediawiki-api-announce mailing list at <https://lists.wikimedia.org/postorius/lists/mediawiki-api-announce.lists.wikimedia.org/> for notice of API deprecations and breaking changes. Use [[Special:ApiFeatureUsage]] to see usage of deprecated features by your application. WARNING:mwclient.client:The parameter "generatexml" has been deprecated. Because "prop" was not specified, a legacy format has been used for the output. This format is deprecated, and in the future the new format will always be used. ```
-
- Oct 16, 2024
-
-
Marc Troelitzsch authored
-
Marc Troelitzsch authored
-
- Oct 11, 2024
-
-
Marc Troelitzsch authored
These options had been removed in 96dea321. They were (accidentally) re-added in #360 (859f3eec).
-
Marc Troelitzsch authored
This change replaces the deprecated `pkg_resources` (part of `setuptools`) with `importlib.metadata` for Python 3.8 and above. Switching to `importlib.metadata` allows us to drop the test-dependency on `setuptools` and gets rid of the `DeprecationWarning` raised by certain versions of `pkg_resources` when being imported: ``` DeprecationWarning: pkg_resources is deprecated as an API ```
-
Marc Troelitzsch authored
-
Marc Troelitzsch authored
ubuntu-latest is in the process of being updated from ubuntu-22.04 to ubuntu-24.04, which leads to issues with py37: ``` Version 3.7 was not found in the local cache Error: The version '3.7' with architecture 'x64' was not found for Ubuntu 24.04. ``` This commit hard-codes the ubuntu-version for py37 to ubuntu-22.04, similar to what we've done for py36. See https://github.com/actions/runner-images/issues/10636 for more information.
-
- Oct 10, 2024
-
-
Marc Troelitzsch authored
The flake8 section is the only one left, so might as well rename the file.
-
Marc Troelitzsch authored
To keep build-compatibility with Python 3.6, I've switched the build backend from `setuptools` to `hatchling`. `setuptools` only supports `pyproject.toml` from version 61 onwards, which itself isn't compatible with Python 3.6. This does not mean we have to fully use Hatch as we can still create build using `python -m build`. Hatchling automatically includes all non-gitignored files, so the `MANIFEST.in` file has been removed.
-
NDKDD authored
-
NDKDD authored
-
NDKDD authored
-
NDKDD authored
-
NDKDD authored
-
- Oct 05, 2024
-
-
Marc Trölitzsch authored
-
- Sep 29, 2024
-
-
Marc Troelitzsch authored
-
- Sep 28, 2024
-
-
Marc Troelitzsch authored
Renaming `types.py` to `_types.py` to avoid conflicts with Python's built-in modules. This change addresses some `ImportErrors` such as: ``` ImportError: cannot import name 'MappingProxyType' from partially initialized module 'types' (most likely due to a circular import) ``` As far as I can tell this is not a problem when installing the library using pip or running tests in tox, only local execution when adding the source-root to the `PYTHONPATH`. This is e.g. the case in the default IntelliJ/Pycharm run configuration when testing in scratch files.
-
Marc Trölitzsch authored
-
- Sep 27, 2024
-
- Sep 16, 2024
-
-
Marc Troelitzsch authored
-
Marc Troelitzsch authored
-
Marc Troelitzsch authored
Previously only `mwclient.errors.InsufficientPermission` was included
-
Marc Troelitzsch authored
The logic for this was removed in cd4830a5, seems like the error was forgotten at the time.
-
Marc Troelitzsch authored
-
- Sep 05, 2024
-
-
Marc Troelitzsch authored
-
Marc Troelitzsch authored
Non-integers in these positions would lead to issues when comparing versions, e.g. `self.version[:2] > (1, 27)`.
-
Marc Troelitzsch authored
In the examples in the MediaWiki documentation, versions are compared using the `version_compare` function from the PHP standard library: https://www.mediawiki.org/wiki/Manual:$wgVersion#Example_code Before comparison, this version canonicalizes version strings according to the following rules: - Replace _, - and + with a dot . - Insert dots . before and after any non number This commit updates `Site.version_tuple_from_generator` to parse versions according to those rules.
-
Marc Troelitzsch authored
-
- Sep 01, 2024
-
-
Adam Williamson authored
100%, baby Signed-off-by:
Adam Williamson <awilliam@redhat.com>
-
Adam Williamson authored
This fallback seems broken and weird. I can't see why: 1) We do it at all 2) Given that we do it, we do it only for namespace IDs in site.namespaces It's existed since the first version of mwclient, but I really can't see how it's valid. A `Site` instance's `self.namespaces` starts out as `default_namespaces`, then in `site_init`, we read in the real namespace configuration of the specific wiki. If the wiki changes the default namespaces, we should respect that. So it seems to me we should just trust `self.namespaces`. I don't see how any kind of fallback to `self.default_namespaces` is ever going to give a more useful result than not doing it. Signed-off-by:
Adam Williamson <awilliam@redhat.com>
-
Adam Williamson authored
This covers missing statements in the PageList class. Signed-off-by:
Adam Williamson <awilliam@redhat.com>
-
Adam Williamson authored
This covers some uncovered statements in the Category class. Signed-off-by:
Adam Williamson <awilliam@redhat.com>
-
Adam Williamson authored
I had to invent the API response because this is only used for the CheckUser extension and I don't have enough privileges to actually use that extension on any wiki with it installed, but I'm pretty sure this more or less captures what it's meant to do. Signed-off-by:
Adam Williamson <awilliam@redhat.com>
-
Adam Williamson authored
This covers the `List.__repr__` method. Signed-off-by:
Adam Williamson <awilliam@redhat.com>
-
Adam Williamson authored
This covers the `if self.result_member not in data['query']` branch of `set_iter`. Signed-off-by:
Adam Williamson <awilliam@redhat.com>
-
Adam Williamson authored
new-style continuation is available since 1.21, and we are already forcing it for mw 1.21-1.25 in `api` by adding `continue` to kwargs if it's not there. Old-style continuation is only available by passing `rawcontinue=` and is not recommended. I don't think we need to maintain support for it in the List class. Theoretically it could maybe still be used if someone is passing `rawcontinue=""` as an arg to `List` or a subclass of it (and that overrides the `continue=` that we force in - I'm not sure which wins), but I can't imagine why anyone would want to do that. This improves test coverage because old-style continuation is uncovered at present. I'd rather remove it than write a test for it. See: https://www.mediawiki.org/wiki/API:Continue Signed-off-by:
Adam Williamson <awilliam@redhat.com>
-