jsr-io / jsr

The open-source package registry for modern JavaScript and TypeScript
https://jsr.io
MIT License
2.51k stars 116 forks source link

Optional peer dependencies do not work #301

Open alexgleason opened 8 months ago

alexgleason commented 8 months ago

This is driving me crazy, trying to publish with GitHub actions:

Downloading JSR binary...
Publishing @nostr/tools@2.3.2 ...
Download completed
Warning Publishing a library with slow types is not recommended. This may lead to poor type checking performance for users of your package, may affect the quality of automatic documentation generation, and your package will not be shipped with a .d.ts file for Node.js users.
error: Failed to publish @nostr/tools@2.3.2
Caused by:
    Failed to publish @nostr/tools at 2.3.2: failed to build module graph: Module not found "file:///nostr-wasm".
        at file:///wasm.ts:2:3[6](https://github.com/nbd-wtf/nostr-tools/actions/runs/8330400433/job/22794952000#step:6:7)
Child process exited with: 1
Error: Process completed with exit code 1.

https://github.com/nbd-wtf/nostr-tools/actions/runs/8330480216/job/22795230558

I must be missing something.

lucacasonato commented 7 months ago

It looks like nostr-wasm is specified as an optional dependency?

We may not be dealing with these correctly at the moment. @dsherret

alexgleason commented 7 months ago

It looks like nostr-wasm is specified as an optional dependency?

Yes.

Also, it didn't work from the command-line either. So it's not just github actions.