Skip to content

Commit

Permalink
Release v2.3.0 (#3776)
Browse files Browse the repository at this point in the history
  • Loading branch information
NSeydoux authored Nov 14, 2024
1 parent 20ef109 commit 5391f75
Show file tree
Hide file tree
Showing 15 changed files with 82 additions and 48 deletions.
32 changes: 30 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,29 @@ This project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html

The following changes have been implemented but not released yet:

## Deprecation notice

- A new signature was introduced for `getSessionFromStorage` in release 2.3.0. The legacy signature is
deprecated, and could be removed with the next major release.

```javascript
// Deprecated signature
const session = await getSessionFromStorage(
sessionId,
storage,
onNewRefreshToken,
refresh,
);
// Replacement signature
const session = await getSessionFromStorage(sessionId, {
storage,
onNewRefreshToken,
refresh,
});
```

## [2.3.0](https://github.com/inrupt/solid-client-authn-js/releases/tag/v2.3.0) - 2024-11-14

### Bugfix

#### node
Expand All @@ -24,9 +47,14 @@ The following changes have been implemented but not released yet:
It defaults to `true`, which makes this a non-breaking change. In addition, a new signature
is introduced to make it easier to provide the optional arguments:

```
```javascript
// Legacy signature only specifying one optional argument
const session = await getSessionFromStorage(sessionId, undefined, undefined, false);
const session = await getSessionFromStorage(
sessionId,
undefined,
undefined,
false,
);

// New signature
const session = await getSessionFromStorage(sessionId, { refresh: false });
Expand Down
4 changes: 2 additions & 2 deletions e2e/browser/solid-client-authn-browser/test-app/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "test-app",
"version": "2.2.7",
"version": "2.3.0",
"private": true,
"scripts": {
"dev": "next dev",
Expand All @@ -11,7 +11,7 @@
},
"dependencies": {
"@inrupt/internal-playwright-testids": "^3.0.2",
"@inrupt/solid-client-authn-browser": "^2.2.7",
"@inrupt/solid-client-authn-browser": "^2.3.0",
"next": "^15.0.3",
"react": "^18.3.1",
"react-dom": "^18.3.1"
Expand Down
6 changes: 6 additions & 0 deletions e2e/browser/solid-ui-react/test-app/next-env.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
/// <reference types="next" />
/// <reference types="next/image-types/global" />
/// <reference types="next/navigation-types/compat/navigation" />

// NOTE: This file should not be edited
// see https://nextjs.org/docs/app/building-your-application/configuring/typescript for more information.
2 changes: 1 addition & 1 deletion lerna.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"useNx": true,
"version": "2.2.7"
"version": "2.3.0"
}
34 changes: 17 additions & 17 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion packages/browser/examples/single/bundle/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "browser-in-bundle",
"private": true,
"version": "2.2.7",
"version": "2.3.0",
"description": "",
"main": "index.js",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion packages/browser/examples/single/script/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@inrupt/solid-client-authn-browser-via-script-tag-example",
"private": true,
"version": "2.2.7",
"version": "2.3.0",
"description": "",
"main": "index.js",
"scripts": {
Expand Down
6 changes: 3 additions & 3 deletions packages/browser/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@inrupt/solid-client-authn-browser",
"version": "2.2.7",
"version": "2.3.0",
"license": "MIT",
"types": "dist/index.d.ts",
"browser": "dist/index.js",
Expand Down Expand Up @@ -30,8 +30,8 @@
"@types/uuid": "^10.0.0"
},
"dependencies": {
"@inrupt/oidc-client-ext": "^2.2.7",
"@inrupt/solid-client-authn-core": "^2.2.7",
"@inrupt/oidc-client-ext": "^2.3.0",
"@inrupt/solid-client-authn-core": "^2.3.0",
"events": "^3.3.0",
"jose": "^5.1.3",
"uuid": "^11.0.3"
Expand Down
2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@inrupt/solid-client-authn-core",
"version": "2.2.7",
"version": "2.3.0",
"license": "MIT",
"main": "dist/index.js",
"module": "dist/index.mjs",
Expand Down
4 changes: 2 additions & 2 deletions packages/node/examples/authenticated-script/package.json
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
{
"name": "@inrupt/demo-authn-node-script",
"private": true,
"version": "2.2.7",
"version": "2.3.0",
"description": "Demo for script authentication in NodeJS",
"type": "module",
"main": "./index.mjs",
"author": "Inrupt, Inc.",
"license": "MIT",
"dependencies": {
"@inrupt/solid-client-authn-node": "^2.2.7",
"@inrupt/solid-client-authn-node": "^2.3.0",
"dotenv": "^16.4.5"
}
}
2 changes: 1 addition & 1 deletion packages/node/examples/demoClientApp/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@inrupt/demo-app-authn-node",
"private": true,
"version": "2.2.7",
"version": "2.3.0",
"description": "Demo client application for authentication in NodeJS",
"main": "src/index.js",
"scripts": {
Expand Down
4 changes: 2 additions & 2 deletions packages/node/examples/multiSession/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@inrupt/demo-authn-node-script-multisession",
"private": true,
"version": "2.2.7",
"version": "2.3.0",
"description": "Demo for session management in NodeJS",
"main": "src/index.js",
"repository": {
Expand All @@ -15,7 +15,7 @@
},
"homepage": "https://github.com/inrupt/solid-client-authn-js#readme",
"dependencies": {
"@inrupt/solid-client-authn-node": "^2.2.7",
"@inrupt/solid-client-authn-node": "^2.3.0",
"cookie-session": "^2.1.0",
"express": "^4.21.1"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/node/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@inrupt/solid-client-authn-node",
"version": "2.2.7",
"version": "2.3.0",
"license": "MIT",
"main": "dist/index.js",
"types": "dist/index.d.ts",
Expand Down Expand Up @@ -28,7 +28,7 @@
"@types/uuid": "^10.0.0"
},
"dependencies": {
"@inrupt/solid-client-authn-core": "^2.2.7",
"@inrupt/solid-client-authn-core": "^2.3.0",
"jose": "^5.1.3",
"openid-client": "^5.7.0",
"uuid": "^11.0.3"
Expand Down
22 changes: 11 additions & 11 deletions packages/node/src/multiSession.ts
Original file line number Diff line number Diff line change
Expand Up @@ -141,17 +141,14 @@ async function internalGetSessionFromStorage(
* from storage on logout.
*
* @param sessionId The ID of the Session to retrieve.
* @param storage The storage where the Session can be found.
* @param onNewRefreshToken A callback to call on refresh token rotation.
* @returns A session object, authenticated if possible, or undefined if no Session
* @param options Options to control the session loading behavior.
* @returns A Session object, potentially authenticated, or undefined if no Session
* in storage matches the given ID.
* @deprecated use the `options` object argument instead.
* @since 2.3.0
*/
export async function getSessionFromStorage(
sessionId: string,
storage?: IStorage,
onNewRefreshToken?: (newToken: string) => unknown,
refresh?: boolean,
options?: GetSessionOptions,
): Promise<Session | undefined>;
/**
* Retrieve a Session from the given storage based on its session ID. If possible,
Expand All @@ -166,14 +163,17 @@ export async function getSessionFromStorage(
* from storage on logout.
*
* @param sessionId The ID of the Session to retrieve.
* @param options Options to control the session loading behavior.
* @returns A Session object, potentially authenticated, or undefined if no Session
* @param storage The storage where the Session can be found.
* @param onNewRefreshToken A callback to call on refresh token rotation.
* @returns A session object, authenticated if possible, or undefined if no Session
* in storage matches the given ID.
* @since unreleased
* @deprecated use the `options` object argument instead.
*/
export async function getSessionFromStorage(
sessionId: string,
options?: GetSessionOptions,
storage?: IStorage,
onNewRefreshToken?: (newToken: string) => unknown,
refresh?: boolean,
): Promise<Session | undefined>;
/**
* Retrieve a Session from the given storage based on its session ID. If possible,
Expand Down
4 changes: 2 additions & 2 deletions packages/oidc-browser/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@inrupt/oidc-client-ext",
"version": "2.2.7",
"version": "2.3.0",
"description": "A module extending oidc-client-js with new features, such as dynamic client registration and DPoP support.",
"homepage": "https://github.com/inrupt/solid-client-authn-js/tree/main/packages/oidc/",
"bugs": "https://github.com/inrupt/solid-client-authn-js/issues",
Expand All @@ -26,7 +26,7 @@
},
"dependencies": {
"@inrupt/oidc-client": "^1.11.6",
"@inrupt/solid-client-authn-core": "^2.2.7",
"@inrupt/solid-client-authn-core": "^2.3.0",
"jose": "^5.1.3",
"uuid": "^11.0.3"
},
Expand Down

0 comments on commit 5391f75

Please sign in to comment.