These are chat archives for adaptlearning/adapt_authoring

15th
Aug 2017
davetaz
@davetaz
Aug 15 2017 08:33
Has anyone hacked a way to use multiple languages via the language picker when using the authoring tool to create the content?
Louise McMahon
@canstudios-louisem
Aug 15 2017 08:42
do you mean create courses with multiple languages or use the AT in multiple languages @davetaz ?
davetaz
@davetaz
Aug 15 2017 08:45
create courses with multiple languages
So far my strategy is to clone the master language course to a second one in the AT, then translate that in the AT and set the language. On the original master one add the language picker with the languages and phrases. Finally export the source code of both and drop the second language folder into the first one and build it using command line. This works however I am aware that all the IDs of components will be wrong which makes tracking interesting as it essentially thinks it is two courses.
Of course the downside of this is that if you make a change (add a component etc) then you need to reflect this on multiple courses in the AT
however this is better for my team than reverting to command line
i don't mind the build being on the command line, however want to keep course writing in the AT
Louise McMahon
@canstudios-louisem
Aug 15 2017 09:21
Oliver Foster
@oliverfoster
Aug 15 2017 09:23
uhoh, not json-stable-stringify! # face-palm #
too much consistent hash
davetaz
@davetaz
Aug 15 2017 09:28
and way too early for hash :P
Oliver Foster
@oliverfoster
Aug 15 2017 09:28
seemingly so
x)
Louise McMahon
@canstudios-louisem
Aug 15 2017 09:50
this is why i like yarn stops you from having the someone 7 packages down the line breaks something issue
Oliver Foster
@oliverfoster
Aug 15 2017 09:58
i'm glad that kind of volitility is so rare
Tom Taylor
@taylortom
Aug 15 2017 10:02
looks like grunt-casperjs is the culprit
ironically, we’ve only just started actually using it
Oliver Foster
@oliverfoster
Aug 15 2017 10:03
deleted
Tom Taylor
@taylortom
Aug 15 2017 10:09
there are also a few packages that have already dropped support for node v4 in their supported releases
Louise McMahon
@canstudios-louisem
Aug 15 2017 10:47
:(
Oliver Foster
@oliverfoster
Aug 15 2017 10:48
we need to agree and document how we choose packages.
Louise McMahon
@canstudios-louisem
Aug 15 2017 10:48
looks like its one of their dependency's which will be a pain to deal with
Oliver Foster
@oliverfoster
Aug 15 2017 10:48
:/
Louise McMahon
@canstudios-louisem
Aug 15 2017 10:49
we have had grunt-casperjs in the dependency list for a while now but we only just started to run it is what tom means
it was in 3.0
Oliver Foster
@oliverfoster
Aug 15 2017 10:56
https://github.com/ronaldlokers/grunt-casperjs last commit was a year ago, last release was 2014
Louise McMahon
@canstudios-louisem
Aug 15 2017 10:58
yeah but it has a dependency of https://www.npmjs.com/package/phantomjs-prebuilt which pushed an update 20 hours ago
does anyone have a working node 4 install that could build a shrinkwrap for us
?
Oliver Foster
@oliverfoster
Aug 15 2017 11:07
we shouldn't have started to use it. in 2015 when grunt-casperjs was updated from v1 to v2.x in the AT it was already clear that the package was defunct. its dependency should be removed.
Oliver Foster
@oliverfoster
Aug 15 2017 11:39
i think any other resolution other than moving away from grunt-casperjs is covering up the issue
Louise McMahon
@canstudios-louisem
Aug 15 2017 12:03
That dosent really solve the issue that we arent locking to specific dependencys and this could easily happen again now node 4 is out of LTS
this wouldn't have happens if we had a proper lock file as their is nothing wrong with the package as it is.
Oliver Foster
@oliverfoster
Aug 15 2017 12:12
the package is out of date and unmaintained. that isn't covered by my definition of 'nothing wrong'
locking to dependencies is, i agree, a great idea
we can do that without using casperjs
Louise McMahon
@canstudios-louisem
Aug 15 2017 12:20
the package works fine for what we use it for at the moment its not breaking because it needs to be updated its breaking because one of its dependency's pushed breaking changes into a patch version. If you want to get rid of casper their a discussion here adaptlearning/adapt_authoring#1440 feel free to add to that.
Oliver Foster
@oliverfoster
Aug 15 2017 12:35
done. so to fix this issue with the grunt-casperjs dependency, you'll need an npm shrinkwrap, or yarn.lock from someone who has a working version + update the AT, or switch to yarn etc? what's the proposal?
Louise McMahon
@canstudios-louisem
Aug 15 2017 12:45
oh this is cool https://greenkeeper.io/
that plus yarn would be awsome
Oliver Foster
@oliverfoster
Aug 15 2017 12:48
can we make it package manager agnostic or is it all or one? it seems to me as though yarn is a project to force updates in npm and not a solid long term replacement.
Louise McMahon
@canstudios-louisem
Aug 15 2017 12:48
do you mean use bower aswell?
Oliver Foster
@oliverfoster
Aug 15 2017 12:49
no, i mean either yarn or npm
what is stopping you from using yarn and me from using npm?
Louise McMahon
@canstudios-louisem
Aug 15 2017 12:50
nothing i could generate a yarn lock file commit it to develop and you could continue to use npm install
Oliver Foster
@oliverfoster
Aug 15 2017 12:51
ok, that doesn't solve the grunt-casperjs issue, so we'd probs need a shrinkwrap and a yarn lock?
Louise McMahon
@canstudios-louisem
Aug 15 2017 12:52
if we generated a yarn lock from a working node_modules folder anyone could use that to get a working version of grunt-casperjs and any other packages
Oliver Foster
@oliverfoster
Aug 15 2017 12:52
they would need to switch to yarn to use the yarn.lock?
Louise McMahon
@canstudios-louisem
Aug 15 2017 12:52
yes
will you be on the call at 2:30 its probly better if explain it via voice
it was just a suggestion though shrinkwrap could work but basically everyone says they are terible npm5 is supposed to be better but still not great
Oliver Foster
@oliverfoster
Aug 15 2017 12:55
i'm not normally on the AT calls, and i'd rather not start. i'm just not sure switching package managers is the right move for solving a short term dependency issue for something that has (at the moment) very little cost to remove.
Louise McMahon
@canstudios-louisem
Aug 15 2017 12:58
i agree i was just talking more generally im not sure we have a solution of something was to happen with say async
we have a lot of dependency's and it concerns me a bit
Oliver Foster
@oliverfoster
Aug 15 2017 12:59
we don't, you're right, it's why i'm arguing for a bit of restraint on the quality and number packages we rely on
a long term solution is definitely a good idea
Tom Taylor
@taylortom
Aug 15 2017 13:00
grunt-casperjs v1 doesn’t spit out an error, haven’t tested it much beyond that
I suggest we remove the dependency completely for now
Louise McMahon
@canstudios-louisem
Aug 15 2017 13:01
its used in npm test at the moment? @taylortom
Tom Taylor
@taylortom
Aug 15 2017 13:01
not as far as I’m aware
the casper test doesn’t run at all does it?
Louise McMahon
@canstudios-louisem
Aug 15 2017 13:03
ah you commented it out in 8a9fed146da23b4eb2fc4023a40ad4e73e87f155
then yeah we may aswell remove it along with the casperjs grunt task they dont pass anyway
Tom Taylor
@taylortom
Aug 15 2017 13:06
:+1: works for me for now
Oliver Foster
@oliverfoster
Aug 15 2017 13:08
:+1:
Tom Taylor
@taylortom
Aug 15 2017 13:08
Have opened this to keep the dep issue on the radar: adaptlearning/adapt_authoring#1704
Oliver Foster
@oliverfoster
Aug 15 2017 13:11
Superb :+1: