Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Asset-Upload fixed #750

Merged
merged 4 commits into from
Jul 10, 2024
Merged

Asset-Upload fixed #750

merged 4 commits into from
Jul 10, 2024

Conversation

wsmirnow
Copy link
Contributor

This patch fixes the asset upload.

This patch fixes the asset upload.
@wsmirnow wsmirnow added the type:bug Something isn't working label Jun 26, 2024
Copy link
Contributor

Use docker or podman to test this pull request locally.

Run test server using develop.opencast.org as backend:

podman run --rm -it -p 127.0.0.1:3000:3000 ghcr.io/opencast/opencast-admin-interface:pr-750

Specify a different backend like stable.opencast.org:

podman run --rm -it -p 127.0.0.1:3000:3000 -e PROXY_TARGET=https://stable.opencast.org ghcr.io/opencast/opencast-admin-interface:pr-750

It may take a few seconds for the interface to spin up.
It will then be available at http://127.0.0.1:3000.
For more options you can pass on to the proxy, take a look at the README.md.

Copy link
Contributor

github-actions bot commented Jun 26, 2024

This pull request is deployed at test.admin-interface.opencast.org/750/2024-07-08_14-12-16/ .
It might take a few minutes for it to become available.

Copy link
Member

@Arnei Arnei left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works and makes sense to me.

Ideally we would not have to make assumptions about magic variables in workflows and have the backend sort it out somehow, but arguably restoring the upload to working order is more important and the assumptions we have to make are not too annoying.

Minor nitpicks below:


let processing: {
workflow: string | undefined,
configuration: typeof uploadAssetWorkflowConfiguration,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be using tabs instead of spaces for indentation.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

}
});

let uploadAssetWorkflowConfiguration: {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor stylistic nitpick: It is preferred to use const instead of let whenever possible.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the info. I've updated the PR.

options: [],
};

let assetFlavors: string = "";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is not necessary to type everything explicitly. For example, in this case typescripts type inference would have no problem inferring that this should be a string.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

wsmirnow and others added 2 commits July 8, 2024 15:47
@wsmirnow
Copy link
Contributor Author

wsmirnow commented Jul 8, 2024

Thank you @Arnei. I've updated the PR with your suggestions. Please continue review.

@wsmirnow wsmirnow requested a review from Arnei July 8, 2024 14:15
@Arnei Arnei merged commit 09862dd into opencast:main Jul 10, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants