Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Eliom_shared_content not linked in client-side #275

Closed
vouillon opened this issue Feb 25, 2016 · 9 comments
Closed

Eliom_shared_content not linked in client-side #275

vouillon opened this issue Feb 25, 2016 · 9 comments

Comments

@vouillon
Copy link
Member

Since the recent changes in TyXML, Eliom_shared_content generates client-values (for constant reactive attributes, I think). However, no module depends on Eliom_shared_content client-side. Thus, it is not linked in, and we get error messages: "Code generating the following client values is not linked on the client".

And it is not possible to force a dependency from outside of Eliom, as the cmi file is not packaged.

A possible fix is to force a dependency of Eliom_content on Eliom_shared_content client-side.

@vasilisp
Copy link
Contributor

My attempt to force a dependency (with a force_link value referenced from outside) didn't help. We can in principle add a unit -> ... around attributes, but that involves Eliom_content as a whole.

@Drup, can we just add unit arguments to the constant attributes inside TyXML? That's safer for complicated instantiations of the functor.

@Drup
Copy link
Member

Drup commented Feb 25, 2016

I would rather avoid it, unless you really can't make it work at all.

@vasilisp
Copy link
Contributor

vasilisp commented Mar 4, 2016

It is not just a question of linking. If I add this line to eliom_content.eliom:

let _ = {int React.S.t{ React.S.const 32 }}

we get an additional line in the browser log. It is a problem of client values appearing at the toplevel (and not produced by functions) inside Eliom. I haven't gone very deeply on the matter, but I suspect supporting such client values might be non-trivial.

I have a TyXML branch and an Eliom branch (both named fix-eliom-275) that in combination solve the issue. @Drup, I would prefer to merge these for now. In the future, TyXML can export a finer-grained interface with a separate type for constant attributes, so that a client of the functor like Eliom can treat these specifically. (That is useful in any case, e.g., to avoid useless React.S.const x signals.)

@Drup
Copy link
Member

Drup commented Mar 4, 2016

I don't understand, what's the problem with this line ? It should be supported just fine.

@vasilisp Just use stable tyxml for now.

@vasilisp
Copy link
Contributor

vasilisp commented Mar 4, 2016

"Should" be supported maybe, but it isn't. It leads to the following:

Code generating the following client values is not linked on the client:
5WxLvI1/1

It is not the right time for the runtime cleanup that would resolve the above.

@vasilisp Just use stable tyxml for now.

We will have to resolve such issues in batch, they don't just go away. In the interim, we will have to update numerous Jenkins configurations, and TyXML itself will be unusable, so it won't receive any testing.

@balat
Copy link
Member

balat commented Mar 10, 2016

Do you have a solution for this?

@balat
Copy link
Member

balat commented Mar 21, 2016

Any news? This bug makes it very difficult to work :/

@vasilisp
Copy link
Contributor

No news. The fix has been there for a while, waiting to be merged :).

@Drup
Copy link
Member

Drup commented Mar 21, 2016

@vasilisp You didn't do any PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants