Skip to content

Commit

Permalink
Merge branch 'hotfix/2.12.4'
Browse files Browse the repository at this point in the history
  • Loading branch information
denis-yuen committed Jul 24, 2024
2 parents e223b18 + 16c07d9 commit e195d22
Show file tree
Hide file tree
Showing 9 changed files with 78 additions and 80 deletions.
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ jobs:
- setup_integration_test
- run:
name: Test
command: bash -i -c 'npx cypress run --record --config numTestsKeptInMemory=1 --reporter junit --spec cypress/e2e/<< parameters.integration_test_name >>/**/*'
command: bash -i -c 'npx cypress run --browser chrome --record --config numTestsKeptInMemory=1 --reporter junit --spec cypress/e2e/<< parameters.integration_test_name >>/**/*'
no_output_timeout: 30m
environment:
MOCHA_FILE: integration-tests/test-results/junit/test-results-[hash].xml
Expand Down
6 changes: 4 additions & 2 deletions cypress/e2e/group2/myworkflows.ts
Original file line number Diff line number Diff line change
Expand Up @@ -512,9 +512,11 @@ describe('Dockstore my workflows part 3', () => {
// Untouched form should not have errors but is disabled
cy.get('#submitButton').should('be.disabled');
notHaveAlert();
cy.get('#sourceCodeRepositoryInput').clear().type('beef/stew');
cy.get('#sourceCodeRepositoryInput').clear();
cy.get('#sourceCodeRepositoryInput').type('beef/stew');
cy.get('#submitButton').should('be.disabled');
cy.get('#sourceCodeRepositoryWorkflowPathInput').clear().type('/Dockstore.cwl');
cy.get('#sourceCodeRepositoryWorkflowPathInput').clear();
cy.get('#sourceCodeRepositoryWorkflowPathInput').type('/Dockstore.cwl');
notHaveAlert();
// Apparently the actual radio button inside Angular material buttons is hidden, so doing it this way
cy.get('#descriptorTypeRadioButtons').contains(cwlDescriptorType).find('.mat-radio-container').click();
Expand Down
30 changes: 24 additions & 6 deletions cypress/e2e/group3/mytools.ts
Original file line number Diff line number Diff line change
Expand Up @@ -265,10 +265,16 @@ describe('Dockstore my tools', () => {
// Make sure page is loaded first
cy.get('#tool-path').should('be.visible');
cy.get('#register_tool_button').click();
// TODO: Fix this. When 'Next' is clicked too fast, the next step is empty
cy.wait(1000);
cy.contains('Create tool with descriptor(s) on remote sites').should('be.visible').click();
cy.get('.modal-footer').contains('Next').first().click();
cy.contains('button', 'Next').click();

cy.get('#sourceCodeRepositoryInput').type('testnamespace/testname').wait(1000);
// Untouched form should not have errors but is disabled
cy.get('#submitButton').should('be.disabled');
cy.get('.mat-error').should('not.exist');
cy.get('#sourceCodeRepositoryInput').clear();
cy.get('#sourceCodeRepositoryInput').type('testnamespace/testname');

cy.get('[data-cy=imageRegistryProviderSelect]').click();
cy.contains('Amazon ECR').click();
Expand Down Expand Up @@ -329,10 +335,16 @@ describe('Dockstore my tools', () => {
// Make sure page is loaded first
cy.get('#tool-path').should('be.visible');
cy.get('#register_tool_button').click();
// TODO: Fix this. When 'Next' is clicked too fast, the next step is empty
cy.wait(1000);
cy.contains('Create tool with descriptor(s) on remote sites').should('be.visible').click();
cy.get('.modal-footer').contains('Next').first().click();
cy.contains('button', 'Next').click();

cy.get('#sourceCodeRepositoryInput').type('testnamespace/testname').wait(1000);
// Untouched form should not have errors but is disabled
cy.get('#submitButton').should('be.disabled');
cy.get('.mat-error').should('not.exist');
cy.get('#sourceCodeRepositoryInput').clear();
cy.get('#sourceCodeRepositoryInput').type('testnamespace/testname');

cy.get('[data-cy=imageRegistryProviderSelect]').click();
cy.contains('Amazon ECR').click();
Expand Down Expand Up @@ -435,10 +447,16 @@ describe('Dockstore my tools', () => {
});
cy.get('#tool-path').should('be.visible');
cy.get('#register_tool_button').click();
// TODO: Fix this. When 'Next' is clicked too fast, the next step is empty
cy.wait(1000);
cy.contains('Create tool with descriptor(s) on remote sites').should('be.visible').click();
cy.get('.modal-footer').contains('Next').first().click();
cy.contains('button', 'Next').click();

cy.get('#sourceCodeRepositoryInput').type('testnamespace/testname').wait(1000);
// Untouched form should not have errors but is disabled
cy.get('#submitButton').should('be.disabled');
cy.get('.mat-error').should('not.exist');
cy.get('#sourceCodeRepositoryInput').clear();
cy.get('#sourceCodeRepositoryInput').type('testnamespace/testname');

cy.get('[data-cy=imageRegistryProviderSelect]').click();
cy.contains('mat-option', 'Seven Bridges').click();
Expand Down
4 changes: 2 additions & 2 deletions cypress/support/commands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ export function checkFeaturedContent() {
cy.get('app-featured-content').should('exist');
cy.get('.feat-content-container').within(() => {
cy.get('.feat-content-card').its('length').should('be.gt', 0);
cy.get('.feat-content-card').first().contains('a').should('have.attr', 'href');
cy.get('.feat-content-card').first().get('a').should('have.attr', 'href');
cy.get('.small-btn-structure').first().contains('View');
});
}
Expand All @@ -272,7 +272,7 @@ export function checkNewsAndUpdates() {
cy.get('app-news-and-updates').should('exist');
cy.get('.news-and-updates-box').within(() => {
cy.get('.news-entry').its('length').should('be.gt', 0);
cy.get('.news-entry').first().contains('a').should('have.attr', 'href');
cy.get('.news-entry').first().get('a').should('have.attr', 'href');
});
}

Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

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

2 changes: 2 additions & 0 deletions src/app/container/container.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,8 @@ export class ContainerComponent extends Entry<Tag> implements AfterViewInit, OnI
} else if (url.includes('containers') || url.includes('tools')) {
// Only get published tool if the URI is for a specific tool (/containers/quay.io%2FA2%2Fb3)
// as opposed to just /tools or /docs etc.
this.containerService.setTool(null);
this.displayAppTool = false;
this.containersService.getPublishedContainerByToolPath(this.title, includesValidation).subscribe(
(tool) => {
this.containerService.setTool(tool);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,26 +78,29 @@ export class DownloadCLIClientComponent extends Base implements OnInit {
}
generateMarkdown(): void {
this.textDataRequirements = `
### Setup Command Line Interface
### Set Up Command Line Interface
------------------------------
Set up our Dockstore CLI application in order to test workflows from the command line for [local development](${Dockstore.DOCUMENTATION_URL}/launch-with/launch.html#dockstore-cli), [validate .dockstore.yml files](${Dockstore.DOCUMENTATION_URL}/advanced-topics/dockstore-cli/yaml-command-line-validator-tool.html) for registering tools and workflows,
You can search for workflows or launch them with our cloud partners using the Dockstore website, but we also provide a command-line tool to make developing and launching workflows more convenient. Set up our Dockstore CLI application in order to test workflows from the command line for [local development](${Dockstore.DOCUMENTATION_URL}/launch-with/launch.html#dockstore-cli), [validate .dockstore.yml files](${Dockstore.DOCUMENTATION_URL}/advanced-topics/dockstore-cli/yaml-command-line-validator-tool.html) for registering tools and workflows,
run scripts or interact programmatically against Dockstore APIs, and [run workflows via the GA4GH WES standard](${Dockstore.DOCUMENTATION_URL}/advanced-topics/wes/cli-wes-tutorial.html) in platforms such as Amazon Genomics CLI.
#### Requirements
1. Linux/Ubuntu (Recommended - Tested on 22.04 LTS) or Mac OS X machine
2. Java 17 (Tested with OpenJDK 17, Oracle JDK may work but is untested)
2. Java 17 (Tested with OpenJDK 17 and Eclipse Temurin JDK 17; Oracle JDK may work but is untested)
3. Python3 and pip3 (Required if working with CWL, optional otherwise)
`;

this.textDataUbuntuLinux = `
#### Part 1 - Install dependencies
1. Install Java 17 (This example installs OpenJDK 17)
#### Part 1 - Install Java
Install Java 17 (This example installs OpenJDK 17)
\`\`\`
sudo apt-get update -q \
&& sudo apt install -y openjdk-17-jdk
\`\`\`
2. Install Docker Engine following the instructions on [Docker's website](https://docs.docker.com/engine/install/ubuntu/#install-using-the-repository). You should have at least version 19.03.1 installed. Ensure that you install Docker Engine. Docker Desktop does not run containers natively and the Dockstore CLI is not currently compatible with Docker Desktop's use of a VM.
3. Ensure that you are able to run Docker without using sudo directly with the
#### Part 2 - Install Docker
Install Docker Engine following the instructions on [Docker's website](https://docs.docker.com/engine/install/ubuntu/#install-using-the-repository). You should have at least version 19.03.1 installed. Ensure that you install Docker Engine. The Ubuntu version of Docker Desktop does not run containers natively, so it is not compatible with the Dockstore CLI.
Ensure that you are able to run Docker without using sudo directly with the
[post install instructions](https://docs.docker.com/engine/installation/linux/linux-postinstall/#manage-docker-as-a-non-root-user).
\`\`\`
sudo usermod -aG docker $USER
Expand All @@ -106,73 +109,49 @@ exec newgrp docker
`;
this.textDataMacOs = `
#### Part 1a - Install Java dependencies
We'll cover two ways to install Java 11.
1. The first way is to download OpenJDK for Mac OS from [here](https://jdk.java.net/archive/), and execute the following commands. First, unpack the downloaded tar archive, then move the resulting JDK directory to its standard location. Then check the Java version:
\`\`\`
sudo mv jdk-11.0.2.jdk /Library/Java/JavaVirtualMachines/
java -version
\`\`\`
If the reported version is JDK 11, you've correctly installed Java! If not, check the list of the JDKs that are installed; you should see version 11:
\`\`\`
/usr/libexec/java_home -V
\`\`\`
Next, set the \`JAVA_HOME\` environment variable to the correct JDK system path
and confirm the Java version:
\`\`\`
unset JAVA_HOME
export JAVA_HOME=\`/usr/libexec/java_home -v 11\`
java -version
\`\`\`
Add the above export line to your \`.bashrc\` or \`.bash_profile\` to set \`JAVA_HOME\` properly every time you invoke a shell.
2. Alternatively, to install Java 11 using Homebrew, execute the following commands:
\`\`\`
brew update
brew install openjdk@11
\`\`\`
For the system Java wrappers to be able to use this JDK, symlink with the command:
\`\`\`
sudo ln -sfn $(brew --prefix)/opt/openjdk@11/libexec/openjdk.jdk /Library/Java/JavaVirtualMachines/openjdk-11.jdk
\`\`\`
Next, set the \`JAVA_HOME\` environment variable to the correct JDK system path, and confirm the
Java version is correct:
\`\`\`
unset JAVA_HOME
export JAVA_HOME=\`/usr/libexec/java_home -v 11\`
java -version
\`\`\`
#### Part 1b - Install Docker dependencies
Install Docker following the instructions on [Docker's website](https://docs.docker.com/docker-for-mac/install/). You should have at least version 2.0.0.3 installed.
#### Part 1 - Install Java
There are several ways to install Java on Mac OS. Here are some examples:
* Using a package manager
* [Homebrew](https://brew.sh/)
* [SDKMAN!](https://sdkman.io/)
* Using a GUI installer with a .pkg file
* [Temurin](https://adoptium.net/temurin/)
* [Corretto](https://docs.aws.amazon.com/corretto/)
* Downloading an archive directly
* [OpenJDK](https://openjdk.org/install/)
After you've installed Java, make sure the version is correct by running \`java -version\` in the terminal, and verifying the major version is 17 or greater.
#### Part 2 - Install Docker
Install Docker following the instructions on [Docker's website](https://docs.docker.com/docker-for-mac/install/). You should have at least version 4.3.0 installed. Make sure to install the correct version for your hardware.
`;

this.textDataInstallCLI = `
#### Part 2 - Install Dockstore CLI
1. Install the dockstore command-line program and add it to the path.
#### Part 3 - Install Dockstore CLI
Install the dockstore command-line program and add it to the path. (If you are using zsh, change the last two lines to use ~/.zshrc instead of ~/.bashrc)
\`\`\`
mkdir -p ~/bin
curl -L -o ~/bin/dockstore ${this.downloadCli}
chmod +x ~/bin/dockstore
echo 'export PATH=~/bin:$PATH' >> ~/.bashrc
source ~/.bashrc
\`\`\`
2. Alternatively, click here to download and configure the CLI yourself.
As an alternative, click here to download and configure the CLI manually.
`;

this.textDataCLIConfig = `
#### Part 3 - Setup Dockstore CLI Config
1. Create the folder \`~/.dockstore\` and create a configuration file \`~/.dockstore/config\`:
#### Part 4 - Set up Dockstore CLI Config
Create the folder \`~/.dockstore\` and create a configuration file \`~/.dockstore/config\`:
\`\`\`
mkdir -p ~/.dockstore
printf "token: ${this.dsToken}\\nserver-url: ${this.dsServerURI}\\n" > ~/.dockstore/config
\`\`\`
2. Alternatively, copy this content to your config file directly.
Alternatively, copy this content to your config file directly.
`;
this.textDataConfirmInstallation = `
#### Part 4 - Confirm installation
1. Run our dependencies to verify that they have been installed properly.
#### Part 5 - Confirm installation
Run our dependencies to verify that they have been installed properly. (Note that the precise version of openjdk may vary depending on how you installed it.)
\`\`\`
$ java -version
openjdk 17.0.5 2022-10-18
Expand All @@ -185,28 +164,29 @@ Hello from Docker!
...
\`\`\`
#### Part 5 - Install cwltool (Optional)
Dockstore relies on [cwltool](https://github.com/common-workflow-language/cwltool) -a reference implementation of CWL- for local execution of tools and workflows described with CWL.
At this point, you now have the Dockstore CLI set up for interacting with the Dockstore website, as well as executing WDL workflows. If you wish to run CWL or Nextflow workflows, you will need two more dependencies.
#### Part 6 - Install cwltool (Optional)
Dockstore relies on [cwltool](https://github.com/common-workflow-language/cwltool) - a reference implementation of CWL - for local execution of tools and workflows described with CWL.
You'll need to have Python 3 and [pip3](https://pip.pypa.io/en/latest/installing/) to be installed on your machine.
**Note:** cwltool must be available on your PATH.
**Note:** cwltool must be available on your PATH for the Dockstore CLI to find it.
You can install the version of cwltool that we've tested for use with Dockstore using the following commands:
1. Run this to verify that pip has been installed \`pip3 --version\`
2. Run these commands to install cwltool
1. Install cwltool
\`\`\`
curl -o requirements.txt "${this.dsServerURI}/metadata/runner_dependencies?client_version=${this.dockstoreVersion}&python_version=3"
pip3 install -r requirements.txt
\`\`\`
3. Verify using \`pip3 list\` that the installed pip packages match the ones specified in the downloaded requirements.txt. Confirm cwltool installation by checking the version.
2. Verify using \`pip3 list\` that the installed pip packages match the ones specified in the downloaded requirements.txt. Confirm cwltool installation by checking the version.
\`\`\`
$ cwltool --version
/usr/local/bin/cwltool ${this.cwltoolVersion}
\`\`\`
Although Dockstore has only been tested with the above cwltool version, if you have issues installing cwltool please try running \`pip3 install cwltool\`. This will install the latest released version from PyPi that is compatible with your Python version.
#### Part 6 - Install Nextflow (Optional)
#### Part 7 - Install Nextflow (Optional)
The Dockstore CLI does not run Nextflow workflows. Users can run them directly by using the Nextflow command line tool. For installation instructions, follow [Nextflow's documentation](https://github.com/nextflow-io/nextflow#download-the-package)
`;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ <h5>Dockstore External Services</h5>
<button mat-raised-button matStepperPrevious class="pull-right mt-2"><mat-icon>navigate_before</mat-icon>Back</button>
</mat-step>
<mat-step>
<ng-template matStepLabel>Setup Dockstore CLI</ng-template>
<ng-template matStepLabel>Set Up Dockstore CLI</ng-template>
<app-downloadcliclient></app-downloadcliclient>
<button mat-raised-button matStepperNext class="pull-right mt-2 ml-1">Next<mat-icon>navigate_next </mat-icon></button>
<button mat-raised-button matStepperPrevious class="pull-right mt-2"><mat-icon>navigate_before</mat-icon>Back</button>
Expand Down
6 changes: 1 addition & 5 deletions src/app/shared/mastodon/mastodon.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,7 @@
<div [innerHTML]="data.postContent"></div>
</div>
<div class="toot-media" *ngIf="data.mediaContent.length > 0">
<img
*ngFor="let picid of data.mediaContent"
src="{{ data.mediaContent[picid].preview_url }}"
alt="{{ data.mediaContent[picid].description }}"
/>
<img *ngFor="let media of data.mediaContent" src="{{ media.preview_url }}" alt="{{ media.description }}" />
</div>
<a *ngIf="data.previewLink" [href]="data.previewLink['url']" class="toot-preview-link" target="_blank" rel="noopener noreferrer">
<div *ngIf="!data.previewLink['image']" class="toot-preview-noImage">📄</div>
Expand Down

0 comments on commit e195d22

Please sign in to comment.