Skip to content

Commit

Permalink
Stacktrace this error
Browse files Browse the repository at this point in the history
  • Loading branch information
mxcl committed Jul 9, 2022
1 parent 788a674 commit 8356775
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Change how your team works.
 


# tea/cli 0.3.3
# tea/cli 0.3.4

tea is a universal virtual‑environment manager:

Expand Down Expand Up @@ -525,10 +525,10 @@ If you got this error message, you need to install tea:
## Dependencies
| Project | Version | Lock |
|-------------|---------|--------|
| deno.land | ^1.18 | 1.20.3 |
| tea.xyz | ^0 | 0.3.3 |
| Project | Version |
|-------------|---------|
| deno.land | ^1.18 |
| tea.xyz | ^0 |
[pantry]: ../../../../pantry
Expand Down
5 changes: 3 additions & 2 deletions src/hooks/useInventory.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@ export interface Inventory {
export default function useInventory(): Response {
const getVersions = async ({ project, constraint }: PackageRequirement) => {
const { platform, arch } = usePlatform()
const rsp = await fetch(`https://s3.amazonaws.com/dist.tea.xyz/${project}/${platform}/${arch}/versions.txt`)
const url = `https://s3.amazonaws.com/dist.tea.xyz/${project}/${platform}/${arch}/versions.txt`
const rsp = await fetch(url)

if (!rsp.ok) throw "404-not-found" //TODO
if (!rsp.ok) throw new Error(`404-not-found: ${url}`) //FIXME

const releases = await rsp.text()

Expand Down

0 comments on commit 8356775

Please sign in to comment.