dave2wave commented on issue #243:
URL: 
https://github.com/apache/tooling-trusted-releases/issues/243#issuecomment-3621290126

   A full review should look at all of these:
   
   ```
   atr % find . -type f -name "*.py" -exec grep -li asfquartexception {} \; 
-exec grep -ni asfquartexception {} \;
   ./jwtoken.py
   65:            raise base.ASFQuartException("Token has expired", 
errorcode=401) from exc
   67:            raise base.ASFQuartException("Invalid Bearer JWT format", 
errorcode=401) from exc
   69:            raise base.ASFQuartException(f"Invalid Bearer JWT: {exc}", 
errorcode=401) from exc
   116:            raise base.ASFQuartException(
   131:        raise base.ASFQuartException(
   ./server.py
   410:    @app.errorhandler(base.ASFQuartException)
   411:    async def handle_asfquart_exception(error: base.ASFQuartException) 
-> Any:
   ./web.py
   73:            raise base.ASFQuartException("Not authenticated", 
errorcode=401)
   94:            raise base.ASFQuartException("You do not have access to this 
project", errorcode=403)
   104:            raise base.ASFQuartException("You do not have access to this 
committee", errorcode=403)
   190:                ).demand(base.ASFQuartException("Release does not 
exist", errorcode=404))
   201:            ).demand(base.ASFQuartException("Release does not exist", 
errorcode=404))
   ./blueprints/post.py
   51:                raise base.ASFQuartException("Not authenticated", 
errorcode=401)
   ./blueprints/api.py
   47:@_BLUEPRINT.errorhandler(base.ASFQuartException)
   48:async def _handle_asfquart_exception(err: base.ASFQuartException) -> 
tuple[quart.Response, int]:
   ./blueprints/admin.py
   40:        raise base.ASFQuartException("Not authenticated", errorcode=401)
   43:        raise base.ASFQuartException("You are not authorized to access 
the admin interface", errorcode=403)
   ./blueprints/get.py
   48:                raise base.ASFQuartException("Not authenticated", 
errorcode=401)
   ./post/revisions.py
   55:            raise base.ASFQuartException("Cannot set revision for 
non-draft or preview release", errorcode=400)
   58:            base.ASFQuartException(f"Revision {selected_revision_number} 
not found", errorcode=404)
   63:            raise base.ASFQuartException(
   78:            raise base.ASFQuartException("Internal error: New revision 
not found", errorcode=500)
   97:            base.ASFQuartException(f"Revision {revision_number} not 
found", errorcode=404)
   ./post/keys.py
   258:        raise base.ASFQuartException(f"Unable to fetch keys from remote 
server: {e.status} {e.message}", errorcode=502)
   260:        raise base.ASFQuartException(f"Network error while fetching 
keys: {e}", errorcode=503)
   ./post/start.py
   49:    except (web.FlashError, base.ASFQuartException) as e:
   ./post/sbom.py
   58:        raise base.ASFQuartException("SBOM augmentation is only supported 
for .cdx.json files", errorcode=400)
   101:        raise base.ASFQuartException("OSV scanning is only supported for 
.cdx.json files", errorcode=400)
   ./post/projects.py
   158:                base.ASFQuartException(f"Project {project_name} not 
found", errorcode=404)
   181:                base.ASFQuartException(f"Project {project_name} not 
found", errorcode=404)
   253:                base.ASFQuartException(f"Project {project_name} not 
found", errorcode=404)
   276:                base.ASFQuartException(f"Project {project_name} not 
found", errorcode=404)
   ./post/draft.py
   166:        raise base.ASFQuartException(f"Invalid hash type '{hash_type}'. 
Supported types: sha256, sha512", errorcode=400)
   198:        raise base.ASFQuartException(
   221:                    raise base.ASFQuartException("SBOM file already 
exists", errorcode=400)
   ./util.py
   442:        raise base.ASFQuartException("Not authenticated", errorcode=401)
   994:        raise base.ASFQuartException("Invalid form submission. Please 
check your input and try again.", errorcode=400)
   ./admin/__init__.py
   132:        raise base.ASFQuartException("Not authenticated", 401)
   203:        raise base.ASFQuartException("Duplicate release directories in 
database", errorcode=500)
   269:            raise base.ASFQuartException(f"Model type '{model}' not 
found", 404)
   300:        raise base.ASFQuartException("Test operations are disabled in 
this environment", errorcode=403)
   315:        raise base.ASFQuartException("Test operations are disabled in 
this environment", errorcode=403)
   637:        raise base.ASFQuartException("APP is not set", errorcode=500)
   941:        except base.ASFQuartException as e:
   ./get/release.py
   36:            base.ASFQuartException(f"Project {project_name} not found", 
errorcode=404)
   87:            base.ASFQuartException(f"Project {project_name} not found", 
errorcode=404)
   ./get/compose.py
   39:        ).demand(base.ASFQuartException("Release does not exist", 
errorcode=404))
   ./get/checks.py
   104:        ).demand(base.ASFQuartException("Release does not exist", 
errorcode=404))
   ./get/committees.py
   53:        ).demand(base.ASFQuartException(f"Committee {name} not found", 
errorcode=404))
   ./get/revisions.py
   57:    except base.ASFQuartException:
   ./get/download.py
   152:            base.ASFQuartException("Release does not exist", 
errorcode=404)
   ./get/test.py
   53:        raise base.ASFQuartException("Test login not enabled", 
errorcode=404)
   125:        raise base.ASFQuartException("Test routes not enabled", 
errorcode=404)
   137:        raise base.ASFQuartException(
   143:        raise base.ASFQuartException("You must be logged in to preview 
authenticated views", errorcode=401)
   148:        raise base.ASFQuartException("Release is not a candidate", 
errorcode=404)
   ./get/start.py
   40:            base.ASFQuartException(f"Project {project_name} not found", 
errorcode=404)
   ./get/sbom.py
   80:        raise base.ASFQuartException("Invalid SBOM score result", 
errorcode=500)
   ./get/vote.py
   68:        ).demand(base.ASFQuartException("Release does not exist", 
errorcode=404))
   136:            raise base.ASFQuartException("Release is not a candidate", 
errorcode=404)
   ./get/projects.py
   52:            base.ASFQuartException(f"Committee {committee_name} not 
found", errorcode=404)
   135:        ).demand(base.ASFQuartException(f"Project {name} not found", 
errorcode=404))
   ./get/draft.py
   43:        raise base.ASFQuartException("File does not exist", errorcode=404)
   ./get/report.py
   41:    except base.ASFQuartException:
   47:        raise base.ASFQuartException("Release has no committee", 
errorcode=500)
   52:        raise base.ASFQuartException("Release has no revision", 
errorcode=500)
   56:        raise base.ASFQuartException("File does not exist", errorcode=404)
   ./get/finish.py
   148:        ).demand(base.ASFQuartException("Release does not exist", 
errorcode=404))
   ./api/__init__.py
   1291:        raise base.ASFQuartException(f"Invalid token subject: 
{asf_uid!r}, type: {type(asf_uid)}", errorcode=401)
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to