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

Default bundle not showing #25

Closed
ghost opened this issue Nov 26, 2014 · 8 comments
Closed

Default bundle not showing #25

ghost opened this issue Nov 26, 2014 · 8 comments

Comments

@ghost
Copy link

ghost commented Nov 26, 2014

I'm using RBE to translate bundles for a dev team.
In certain project, the "default" bundle appears, in other project, it does not.§
I cannot figure out a pattern there.
Any idea?
Thanks
FX

@Endeavourl
Copy link

I have the same issue. I even tried debugging, deleting eclipse indexes, nothing helps.
It's even worse because it used to work until today, now the Default tab just doesn't show and i didn't change anything.

Now tried importing the project into a clean fresh workspace - this helped.

@ghost
Copy link

ghost commented Jan 20, 2015

I can confirm the issue. Using Eclipse 4.4 and RBE 1.0.4, the "default" bundle often doesn't show up in RBE (although the RBE is started from the default bundle). Some resource bundles initially work, then they stop working at some time.
I am suspecting this issue might be related to the resource bundles being under version control using SVN. While I have no proof, the default bundle seems to go missing somewhen after the Eclipse projects are committed to SVN.

@fitoRiera
Copy link

I have same problem with a project under version control using git.

I also found the following behavior:
1- Try to open the default bundle with RBE
2- The RBE opens but not show the default language
3- Ask RBE to create default language bundle
4- RBE creates a new file without extension for the default language bundle

Looking at this, the cause to not show the default bundle could be a problem setting the default resource bundle file's name.
So the 'bundle.properties' is there but RBE is looking for 'bundle' file as default.

@rheydenr
Copy link

Hi all, I've the same problem. Suddenly, without prenotification, the RBE doesn't show the default bundle tab. No idea what's wrong...

/Ralf.

@rsoucase
Copy link

I have a same problem Elclipse Luna 4.4, Dont show editor.

@Endeavourl
Copy link

Okay so with a bit of debugging we here realized what's wrong.

First, the workaround is to disable support for loading of resources from fragment (3rd checkbox from the top in settings), or close your plugin's fragments projects before opening resources.

Now, the error itself.
First, ResourceFactory uses FragmentResourceFactory if current project has fragments. It loads all available resources from all fragments and then calls ResourceFactory again to look for a factory to load host (current) project's resources, that is StandardResourceFactory.
StandardResourceFactoryloads all the host's resources correctly, including the default resource for which it assigns the Locale value of null.
But then FragmentResourceFactory adds all the SourceEditors created by StandardResourceFactory except those, which have null Locale thus discarding the default resource.

I'm not sure of implications of removing that null check, so i didn't try to make any changes.
Error line: https://github.com/essiembre/eclipse-rbe/blob/bf15767b27/eclipse-rbe-plugin/src/com/essiembre/eclipse/rbe/ui/editor/resources/FragmentResourceFactory.java#L161

LZaruba added a commit to LZaruba/eclipse-rbe that referenced this issue Nov 3, 2015
Changed behavior of fragment vs. host plugin resulting files merging to
prefer fragment files over the host files but if there is no file for
the given locale in fragment, host file is loaded.
This fixes the bug as it no longer checks and skip for null locale (=
default)
@LZaruba
Copy link
Collaborator

LZaruba commented Nov 3, 2015

Hi,
I created a pull request which fixes this issue.
Can you please verify&accept this change or you can possibly give me an access to merge the change by myself.

Thank you

Lukas

@LZaruba
Copy link
Collaborator

LZaruba commented Dec 1, 2015

Fixed in the latest release

@LZaruba LZaruba closed this as completed Dec 1, 2015
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

5 participants