Skip to content

fix: update parser-js to v2 - #615

Merged
asyncapi-bot merged 2 commits into
asyncapi:masterfrom
smoya:chore/updateParsers
Jun 22, 2023
Merged

asyncapi-bot merged 2 commits into
asyncapi:masterfrom
smoya:chore/updateParsers

Conversation

@smoya

@smoya smoya commented May 2, 2023 •

Copy link
Copy Markdown
Member

Replaces #572

Description

This PR updates @asyncapi/parser to v2 and uses the recently released custom schema parsers.

Note: this PR does not change Studio to start using the new Parser-API but keeps using the old wrapper const oldDocument = convertToOldAPI(document);.

Related issue(s)
asyncapi/parser-js#585

@netlify

netlify Bot commented May 2, 2023 •

Copy link
Copy Markdown

✅ Deploy Preview for modest-rosalind-098b67 ready!

Name Link
🔨 Latest commit 7182f5b
🔍 Latest deploy log https://app.netlify.com/sites/modest-rosalind-098b67/deploys/64930430e9c873000831c607
😎 Deploy Preview https://deploy-preview-615--modest-rosalind-098b67.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

Comment thread src/services/parser.service.ts Outdated
Comment on lines +31 to +32
await this.subscribeToSettings();
await this.parseSavedDocuments();

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

It won't wait because subscription is a procedure, not function :) So I don't think so that this is needed.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

SonarCloud complains about this being missing.

Comment thread src/index.tsx Outdated
}

async function bootstrap() {
(async () => {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Why did you change bootstrap function to something like that?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

SonarCloud complains (marks as a bug) with something like this iirc: "Promises must be awaited, end with a call to .catch, or end with a call to .then with a rejection handler"

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

As we see, Sonarcloud was written by Java people 😆 Ok.

@magicmatatjahu

magicmatatjahu commented May 4, 2023 •

Copy link
Copy Markdown
Member

Something doesn't work. When I remove info.title from the spec then I see errors, but when I update the config to hide the warnings they aren't filtered (still with errors). Rest are good for me. Please only check that described bug, because it works as I described in current studio https://studio.asyncapi.com/

@smoya

smoya commented May 30, 2023

Copy link
Copy Markdown
Member Author

Something doesn't work. When I remove info.title from the spec then I see errors, but when I update the config to hide the warnings they aren't filtered (still with errors). Rest are good for me. Please only check that described bug, because it works as I described in current studio https://studio.asyncapi.com/

Being honest, I don't understand why changing the following lines back to what it was previously fixes the issue: 768b01c

@smoya
smoya requested a review from magicmatatjahu May 30, 2023 21:24
@jonaslagoni jonaslagoni mentioned this pull request Jun 5, 2023
9 tasks done
@smoya
smoya requested a review from KhudaDad414 as a code owner June 21, 2023 10:26
@netlify

netlify Bot commented Jun 21, 2023 •

Copy link
Copy Markdown

✅ Deploy Preview for asyncapi-studio-design-system ready!

Name Link
🔨 Latest commit 7182f5b
🔍 Latest deploy log https://app.netlify.com/sites/asyncapi-studio-design-system/deploys/6493043015b046000885dc38
😎 Deploy Preview https://deploy-preview-615--asyncapi-studio-design-system.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@smoya
smoya force-pushed the chore/updateParsers branch from 0b2fa93 to 2f45428 Compare June 21, 2023 11:51
@smoya
smoya force-pushed the chore/updateParsers branch from 2f45428 to 04ec1f9 Compare June 21, 2023 13:16
@sonarqubecloud

Copy link
Copy Markdown

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.3% 0.3% Duplication

@smoya

smoya commented Jun 22, 2023

Copy link
Copy Markdown
Member Author

/rtm

@asyncapi-bot
asyncapi-bot merged commit 7658834 into asyncapi:master Jun 22, 2023
Amzani pushed a commit to Amzani/studio that referenced this pull request Jun 22, 2023
@asyncapi-bot

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version @asyncapi/studio-v1.0.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@asyncapi-bot

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version @asyncapi/studio-v1.0.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants