Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

chore: make code PEP597 compliant#2201

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
nejch merged 1 commit intomainfromjlvillal/encoding_warning
Jul 29, 2022
Merged
Show file tree
Hide file tree
Changes fromall commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletiongitlab/config.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -135,7 +135,7 @@ def __init__(

def _parse_config(self) -> None:
_config = configparser.ConfigParser()
_config.read(self._files)
_config.read(self._files, encoding="utf-8")

if self.gitlab_id and not _config.has_section(self.gitlab_id):
raise GitlabDataError(
Expand Down
2 changes: 1 addition & 1 deletiontests/meta/test_v4_objects_imported.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -13,7 +13,7 @@ def test_verify_v4_objects_imported() -> None:
assert len(gitlab.v4.objects.__path__) == 1

init_files: Set[str] = set()
with open(gitlab.v4.objects.__file__, "r") as in_file:
with open(gitlab.v4.objects.__file__, "r", encoding="utf-8") as in_file:
for line in in_file.readlines():
if line.startswith("from ."):
init_files.add(line.rstrip())
Expand Down
2 changes: 1 addition & 1 deletiontests/unit/objects/test_packages.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -276,7 +276,7 @@ def test_delete_project_package_file_from_package_file_object(

def test_upload_generic_package(tmp_path, project, resp_upload_generic_package):
path = tmp_path / file_name
path.write_text(file_content)
path.write_text(file_content, encoding="utf-8")
package = project.generic_packages.upload(
package_name=package_name,
package_version=package_version,
Expand Down
3 changes: 2 additions & 1 deletiontests/unit/test_config.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -290,7 +290,8 @@ def test_data_from_helper(m_open, monkeypatch, tmp_path):
#!/bin/sh
echo "secret"
"""
)
),
encoding="utf-8",
)
helper.chmod(0o755)

Expand Down

[8]ページ先頭

©2009-2025 Movatter.jp