These are chat archives for ceylon/ceylon-ide-eclipse

17th
Oct 2016
Stéphane Épardaud
@FroMage
Oct 17 2016 14:22
So how is it looking @jeffmaury ?
David Festal
@davidfestal
Oct 17 2016 14:24
I think I'll have to give up the idea of having a nice Android / Eclipse / Ceylon integration very soon. I've spendthe last days trying to find a way to add the META-INF/ceylon/metamodel file inside the final signed APK, but it seemseverything is done to rpevent adding anything under META-INF.
that's really a pity, since I was really near.
having something really nice
and even it could have been released on the 1.3.0 release
update site
but ... I don't hope too much anymore
Stéphane Épardaud
@FroMage
Oct 17 2016 14:29
frankly if you tell me where else you want to put it we can look it up from another location
quite weird though because gradle is fine with putting META-INF files there
David Festal
@davidfestal
Oct 17 2016 14:29
anywhere apart from META-INF it seems
Stéphane Épardaud
@FroMage
Oct 17 2016 14:30
so change JvmBackendUtil.getStaticMetamodelInputStream to look it up from another location if it's not found in META-INF?
David Festal
@davidfestal
Oct 17 2016 14:30
you could at least seach it in both places
yeah, I'll try to do that
but I would have liked to produce this plugin for 1.3.0
=> compatible with the 1.3.0 distrib
Stéphane Épardaud
@FroMage
Oct 17 2016 14:31
well, not much more I can do
David Festal
@davidfestal
Oct 17 2016 14:31
at least this was my idea, so I'mon the 1.3.0 branch.
Jeff MAURY
@jeffmaury
Oct 17 2016 14:31
@FroMage @davidfestal sorry but busy working on a release. I just validated the new update site and it fixes the issue I had. Need to validate if perfomance issues we had while testing a long ago are now resolved, won't be able to do it before next week
David Festal
@davidfestal
Oct 17 2016 14:31
sure, I understand
Stéphane Épardaud
@FroMage
Oct 17 2016 14:32
just call the new META-INF folder ITS-REALLY-META-INF-YOU-STUPID-ECLIPSE ;)
@jeffmaury ok great, thanks
David Festal
@davidfestal
Oct 17 2016 14:32
yes, I'll have to do something like that : ANDROID-META-INF:-)
are you sure this doesn't bring problems in Android studio also when signing the produced APK ?
Stéphane Épardaud
@FroMage
Oct 17 2016 14:39
no idea
I never signed it
David Festal
@davidfestal
Oct 17 2016 14:39
did you try to debug an android application from studio ?
Stéphane Épardaud
@FroMage
Oct 17 2016 14:39
no
David Festal
@davidfestal
Oct 17 2016 14:40
because to be debugged it should be signed also in some case afaik
OK, let mecome back to master
and continue my work on master, using ANDROID-META-INF
or you might have a better idea ?
instead of ANDROID-META-INF ?
Bastien Jansen
@bjansen
Oct 17 2016 14:42
FNI-ATEM :)
David Festal
@davidfestal
Oct 17 2016 14:42
The thing is that we have to keep previous entry (META-INF/ceylon/metamodel) for compatibility I assume
Stéphane Épardaud
@FroMage
Oct 17 2016 14:42
@bjansen +1
David Festal
@davidfestal
Oct 17 2016 14:42
:-)
Stéphane Épardaud
@FroMage
Oct 17 2016 14:42
well, and also for normal jars this is the place where it makes sense
so just support both locations
David Festal
@davidfestal
Oct 17 2016 14:43
yes, I'll do that
John Vasileff
@jvasileff
Oct 17 2016 15:57
Is it possible to specify an alternate Ceylon dist to compile & run Ceylon projects in Eclipse?
or do you always have to use the embedded dist?
Bastien Jansen
@bjansen
Oct 17 2016 15:57
it's called "system repository" in the project settings
John Vasileff
@jvasileff
Oct 17 2016 15:57
cool, thanks
Bastien Jansen
@bjansen
Oct 17 2016 15:58
in 'Module Repositories'
David Festal
@davidfestal
Oct 17 2016 15:58
but there might be problems if the ceylon language version is not the same as the one in the embedded distribution
Bastien Jansen
@bjansen
Oct 17 2016 15:58
and it will still use the embedded dist to typecheck files, right?
David Festal
@davidfestal
Oct 17 2016 15:58
yes
John Vasileff
@jvasileff
Oct 17 2016 15:59
yeah, it would be the same version, just fresher compile of 1.3.1-SNAPSHOT
Bastien Jansen
@bjansen
Oct 17 2016 16:00
that should work
David Festal
@davidfestal
Oct 17 2016 16:00
yes
Bastien Jansen
@bjansen
Oct 17 2016 16:01
I have ../ceylon/dist/osgi/embeddedRepository/repo for ceylon-ide-common :)
John Vasileff
@jvasileff
Oct 17 2016 16:15
Ok, this is weird. After overriding the “system repository”, I was no longer able to compile a *.java file that uses a type from a *.ceylon file.
there could be some other factor, but after clearing out the “system repository”, it compiles cleanly
David Festal
@davidfestal
Oct 17 2016 16:16
that seems strange to me.I don't see how it's related.But I might miss some point
John Vasileff
@jvasileff
Oct 17 2016 16:16
yeah, sure does seem like there must be something else, but that’s all I changed.
for now I guess I’ll just rewrite the type in java, which should be easy
Bastien Jansen
@bjansen
Oct 17 2016 16:26
@jvasileff a Java declaration that uses a Ceylon declaration located in the same project in its signature?
John Vasileff
@jvasileff
Oct 17 2016 16:27
The java code calls new CeylonDefinedClass(), which I know used to not work at all, but I thought was supported now?
Bastien Jansen
@bjansen
Oct 17 2016 16:28
it should work if your Java method doesn't take or return a CeylonDefinedClass
if it's just using it in the method body, it should work fine
John Vasileff
@jvasileff
Oct 17 2016 16:28
yeah, the only mention of the class in the entire file is JsonParameter param = new JsonParameter();
Bastien Jansen
@bjansen
Oct 17 2016 16:28
have you tried a clean build after changing the system repo?
John Vasileff
@jvasileff
Oct 17 2016 16:28
yes
Bastien Jansen
@bjansen
Oct 17 2016 16:29
weird
John Vasileff
@jvasileff
Oct 17 2016 17:28
Ok, finally, mystery (partially) solved. "JsonParameter cannot be resolved to a type” errors always occur immediately when you “Clean…”, but then disappear after a successful build.
My problem is that there were other errors with the build that apparently were not reported
Root cause: trying to use the 4127 branch as the dist override, which is missing some commits in master.
Bastien Jansen
@bjansen
Oct 17 2016 17:33
IIRC it compiles Java files, then Ceylon files, then Java files again for refs to Ceylon declarations
so if the compilation of Ceylon files fails, it won't recompile Java files a 2nd time and you'll see such errors
the 2nd compilation is meant to remove errors like "unknown type CeylonDeclarationInSameProject"
not sure what I'm saying is clear, but for bidirectional interop we need 3 rounds of compilation I believe
David Festal
@davidfestal
Oct 17 2016 17:35
yes, that's right
well, at least for now
Bastien Jansen
@bjansen
Oct 17 2016 17:35
yep
John Vasileff
@jvasileff
Oct 17 2016 17:37
makes sense
Bastien Jansen
@bjansen
Oct 17 2016 17:38
the downside is, if you have one single Ceylon error, that can lead to dozens or hundreds of "false" Java errors
depending on how much you use Ceylon from Java
John Vasileff
@jvasileff
Oct 17 2016 17:39
fortunately I’ve found the need to be quite rare