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

Appearance settings

Commit 3f320af

Browse filesBrowse files
nejchJohnVillalovos
authored andcommitted
refactor(objects): remove deprecated constants defined in objects
BREAKING CHANGE: remove deprecated constants defined in gitlab.v4.objects, and use only gitlab.const module
1 parent 2b8a94a commit 3f320af
Copy full SHA for 3f320af

File tree

Expand file treeCollapse file tree

3 files changed

+4
-16
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

3 files changed

+4
-16
lines changed
Open diff view settings
Collapse file

‎gitlab/const.py‎

Copy file name to clipboardExpand all lines: gitlab/const.py
+3-4Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,11 @@
2525
REPORTER_ACCESS: int = 20
2626
DEVELOPER_ACCESS: int = 30
2727
MAINTAINER_ACCESS: int = 40
28-
MASTER_ACCESS: int = MAINTAINER_ACCESS
2928
OWNER_ACCESS: int = 50
3029

31-
VISIBILITY_PRIVATE: int = 0
32-
VISIBILITY_INTERNAL: int = 10
33-
VISIBILITY_PUBLIC: int = 20
30+
VISIBILITY_PRIVATE: str = "private"
31+
VISIBILITY_INTERNAL: str = "internal"
32+
VISIBILITY_PUBLIC: str = "public"
3433

3534
NOTIFICATION_LEVEL_DISABLED: str = "disabled"
3635
NOTIFICATION_LEVEL_PARTICIPATING: str = "participating"
Collapse file

‎gitlab/v4/objects/__init__.py‎

Copy file name to clipboardExpand all lines: gitlab/v4/objects/__init__.py
-11Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -74,15 +74,4 @@
7474
from .variables import *
7575
from .wikis import *
7676

77-
# TODO: deprecate these in favor of gitlab.const.*
78-
VISIBILITY_PRIVATE = "private"
79-
VISIBILITY_INTERNAL = "internal"
80-
VISIBILITY_PUBLIC = "public"
81-
82-
ACCESS_GUEST = 10
83-
ACCESS_REPORTER = 20
84-
ACCESS_DEVELOPER = 30
85-
ACCESS_MASTER = 40
86-
ACCESS_OWNER = 50
87-
8877
__all__ = [name for name in dir() if not name.startswith("_")]
Collapse file

‎tests/functional/api/test_snippets.py‎

Copy file name to clipboardExpand all lines: tests/functional/api/test_snippets.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ def test_project_snippets(project):
3333
"title": "snip1",
3434
"file_name": "foo.py",
3535
"content": "initial content",
36-
"visibility": gitlab.v4.objects.VISIBILITY_PRIVATE,
36+
"visibility": gitlab.VISIBILITY_PRIVATE,
3737
}
3838
)
3939

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.