labnex/LabNex
2
6
Fork
You've already forked LabNex
0

When token doesn't have the required permission for an action, make it explicit in error message #82

Open
opened 2025年03月10日 00:38:12 +01:00 by Porkepix · 0 comments
Porkepix commented 2025年03月10日 00:38:12 +01:00 (Migrated from github.com)
Copy link

I confirm that I have searched the issue tracker

Before opening an issue, take a few minutes to search the issue tracker (both open and closed issues) for the problem you are facing. This will reduce the need for issue triage and save time.

  • I confirm that I have searched the issue tracker

Describe the bug

When trying to do in the application an action not allowed by token's permissions, the error message is wrong: it says it cannot reach the server (see screenshot below).

To Reproduce

Add an account with a token with insufficient permissions, for example not enough to read groups and try to access groups.

Expected behavior

The error message should be explicit

Screenshots

Screenshot

Image

Versions (please complete the following information)**

  • LabNex: 4.0.0
  • Android: 14
  • GitLab: 14.7.8

GitLab instance

  • gitlab.com
  • framagit.org
  • Self-hosted instance
  • Other service (Name/URL: )

Mode of installation

  • Google Play Store
  • F-droid
  • APK
  • Built from source
  • OpenAPK
  • Other stores (Name: )

Declaration

### I confirm that I have searched the issue tracker Before opening an issue, take a few minutes to search the issue tracker (both open and closed issues) for the problem you are facing. This will reduce the need for issue triage and save time. - [x] I confirm that I have searched the issue tracker ### Describe the bug When trying to do in the application an action not allowed by token's permissions, the error message is wrong: it says it cannot reach the server (see screenshot below). ### To Reproduce Add an account with a token with insufficient permissions, for example not enough to read groups and try to access groups. ### Expected behavior The error message should be explicit ### Screenshots <details> <summary> Screenshot </summary> ![Image](https://github.com/user-attachments/assets/4e06024c-0604-44af-aae7-4a2c1d9b3249) </details> ### Versions (please complete the following information)** - LabNex: 4.0.0 - Android: 14 - GitLab: 14.7.8 ### GitLab instance - [ ] gitlab.com - [ ] framagit.org - [x] Self-hosted instance - [ ] Other service (Name/URL: ) ### Mode of installation - [ ] Google Play Store - [x] F-droid - [ ] APK - [ ] Built from source - [ ] OpenAPK - [ ] Other stores (Name: ) ### Declaration - [x] I have carefully read and agree to follow the [contribution guidelines](https://github.com/labnex/LabNex/wiki/Contributing).
Sign in to join this conversation.
No Branch/Tag specified
main
release-8.0
release-7.0
release-6.0
release-5.0
release-4.0
release-3.0
release-2.0
release-1.0
8.0.1
8.0.0
8.0.0-rc2
8.0.0-rc1
7.0.0
6.0.1
6.0.0
5.0.0
4.0.0
3.0.0
2.0.0
1.0.2
1.0.1
Labels
Clear labels
⚔️ Wontfix
This will not be worked on
⚙️ CI
Update
⛏️ Breaking
Fixed
Duplicate
This issue or pull request already exists
Invalid
This doesn't seem right
Question
❤️ Support
➡️ Frontport
➡️ Needs-frontport
🌐 Translation
🎉 Feature
🎯 Enhancement
🏗️ Build
🐛 Bug
Something isn't working
👋 Good-first-issue
💀 Deprecation
💡 Suggestion
💬 Discussion
💭 Brainstorming
💰 Sponsored
A feature which is sponsored by someone
💻 UI/UX
📄 Documentation
Improvements or additions to documentation
📈 Performance
📌 Priority-critical
📌 Priority-high
📍 Priority-low
📍 Priority-medium
📡 Needs-feedback
📱 F-droid
📸 Release
🔒 Security
🔙 Backport
Bugfix ported to a release branch for point release
🔙 Has-backport
🔙 Needs-backport
🔙 Regression
🔭 Cannot-reproduce
🗄️ Repository
🗒️ Changelog
🗓️ Summary
🤾 Google-play
🥑 Ready
🧪 Testing
🧺 Cleanup
🧺 Needs-cleanup
🧾 Confirmed
🧾 To-confirm
🩹 External-dependecy
🪒 Refactor
🪜 Upstream
🙇‍♂️ Help-wanted
Extra attention is needed
🚀 Improvement
🚨 Investigate
🛡️ Blocked
🛰️ API-dependency
🟦 Website
No labels
⚔️ Wontfix
⚙️ CI
Update
⛏️ Breaking
Fixed
Duplicate
Invalid
Question
❤️ Support
➡️ Frontport
➡️ Needs-frontport
🌐 Translation
🎉 Feature
🎯 Enhancement
🏗️ Build
🐛 Bug
👋 Good-first-issue
💀 Deprecation
💡 Suggestion
💬 Discussion
💭 Brainstorming
💰 Sponsored
💻 UI/UX
📄 Documentation
📈 Performance
📌 Priority-critical
📌 Priority-high
📍 Priority-low
📍 Priority-medium
📡 Needs-feedback
📱 F-droid
📸 Release
🔒 Security
🔙 Backport
🔙 Has-backport
🔙 Needs-backport
🔙 Regression
🔭 Cannot-reproduce
🗄️ Repository
🗒️ Changelog
🗓️ Summary
🤾 Google-play
🥑 Ready
🧪 Testing
🧺 Cleanup
🧺 Needs-cleanup
🧾 Confirmed
🧾 To-confirm
🩹 External-dependecy
🪒 Refactor
🪜 Upstream
🙇‍♂️ Help-wanted
🚀 Improvement
🚨 Investigate
🛡️ Blocked
🛰️ API-dependency
🟦 Website
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
labnex/LabNex#82
Reference in a new issue
labnex/LabNex
No description provided.
Delete branch "%!s()"

Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?