Skip to content
This repository was archived by the owner on Jun 15, 2023. It is now read-only.

Commands#49

Merged
cryogenian merged 3 commits into
slamdata:masterfrom
cryogenian:commands
Oct 30, 2017
Merged

Commands#49
cryogenian merged 3 commits into
slamdata:masterfrom
cryogenian:commands

Conversation

@cryogenian

Copy link
Copy Markdown
Member

Two things were added

  • try/catch to set and reset foreign implementations
  • All commands now thread value of subdsls throug e.g.
a <- legend do 
  items [ "foo", "bar" ]
  pure 12

traceAnyA a -- prints 12

@garyb would you mind to take a quick look? I'm not sure if this change is major or patch real breaks may occur only in situation like in Line module when user maps DSL.

@cryogenian cryogenian requested a review from garyb October 24, 2017 18:18

@garyb garyb left a comment

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.

I'd say this is a breaking change, as the type signature of existing functions has been changed (like the need to change to set' illustrates).

It's true that the DSL interface may not have changed breakingly, but if any part of the interface of a library does it's considered breaking. :)

Comment thread src/ECharts/Chart.js Outdated
try {
chart.setOption(option, false, false);
} catch (e) {
connsole.error(e);

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.

Typo on console

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.

Also, is this a good idea anyway? What's the thinking by making it a silent error?

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.

Well, that's provide at least a message, because halogen for example eats all exceptions and silently breaks

Comment thread src/ECharts/Commands.purs Outdated
series a = set "series" =<< buildSeries a
series ∷ ∀ i m. Monad m ⇒ CommandsT TP.SeriesI m ~> CommandsT (series ∷ I|i) m
series a = do
set "series" =<< buildSeries a

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.

Redundant do?

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.

👍 Thanks

@cryogenian cryogenian merged commit 4866c2c into slamdata:master Oct 30, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants