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

Move "Open only one instance of JabRef" preference option to somewhere else #9306

Closed
tobiasdiez opened this issue Oct 24, 2022 · 18 comments · Fixed by #10602
Closed

Move "Open only one instance of JabRef" preference option to somewhere else #9306

tobiasdiez opened this issue Oct 24, 2022 · 18 comments · Fixed by #10602
Assignees
Labels
good first issue An issue intended for project-newcomers. Varies in difficulty. preferences type: enhancement ui

Comments

@tobiasdiez
Copy link
Member

Is your suggestion for improvement related to a problem? Please describe.
The option to limit to only one running instance of JabRef is currently under the "Network" tab, which is highly confusing since from a users perspective there is nothing "networky" going on.

Describe the solution you'd like
Move it to another tab, maybe "General"?

@koppor koppor moved this to Normal priority in Features & Enhancements Nov 7, 2022
@koppor koppor moved this from Normal priority to Low priority in Features & Enhancements Dec 16, 2022
@Ivens-Zhang
Copy link

If that's possible, would you like to provide more detail about this issue. Which item you consider that could be moved to 'General'? Is this the one I highlight on the snapshot?

image

@tobiasdiez
Copy link
Member Author

Yes, this is the option I meant!

@DiamondMyK
Copy link
Contributor

Hi, I'm new to open source and want to try to solve some simple problems. Can you assign this issue to me? I would appreciate it!

@ThiloteE
Copy link
Member

"Listen for remote operation on port xxxx" sounds very much "networky" to me.

@tobiasdiez
Copy link
Member Author

That we are using a local socket ('remote' is very misleading here) on some port is an implementation detail. We could also store the "remote command" in some file, and check that file in the running instance. But that doesn't mean it should go in the "external files" tab. The point here being that as a user I would never look under "network" to see if I can limit jabref to only one instance.

@ThiloteE
Copy link
Member

ThiloteE commented Oct 21, 2023

Hmm. Maybe it would make sense to have this option twice in the preferences?

  1. Once under general with heavy emphasis on "Open only one instance of JabRef / Allow only one running instance of JabRef"
  2. Once under "Remote" just like it is currently.

As a non-programmer I don't know the term "local sockets".
I also never have tried to open a file from JabRef from my webbrowser. How does that work exactly? I assume we have two devices. One local, one remote. The local conncts via web-browser (e.g. via apps like cockpit) to the remote and somehow JabRef detects that and then "somehow" can open a file from remote?

@tobiasdiez
Copy link
Member Author

In this context, "remote" refers to the second instance of JabRef that you start. This new instance detects another one is already running and then closes down. There is no connection over a network, nor any possibility to interact with the browser. The best way to think of it is as a glorified lock file, and "port" is the name of that lock file. "Remote" is just a very confusing name for that feature.

@ThiloteE
Copy link
Member

ThiloteE commented Oct 21, 2023

Then I would suggest to not only move this preference to the general preferences, just like you suggested, but also to completely rewrite the description and purge all remote and port related vocabulary and replace it with something that is more easily understood. Maybe it is best to remove the "port" option completely (hence hard-code the port and hide from preferences GUI). Unless, there is a workflow that requires specific ports?

@github-project-automation github-project-automation bot moved this to Free to take in Good First Issues Oct 21, 2023
@ThiloteE ThiloteE moved this from Free to take to Reserved in Good First Issues Oct 21, 2023
@Siedlerchr
Copy link
Member

Now, port can be necessary if you have another application running.
I would rename it simply to Allow only once instance of JabRef

@koppor
Copy link
Member

koppor commented Oct 24, 2023

That feature is also used at the web search to add entries to a running JabRef instance. Thus, it's not only about "one instance" only.

For me, it is OK to move it to "general".

[x] Enforce single JabRef instance (and allow remote operations)   [...port...] (?)

Alternative:

Just add another text for the semantics

image

@koppor koppor added the good first issue An issue intended for project-newcomers. Varies in difficulty. label Oct 24, 2023
@koppor
Copy link
Member

koppor commented Oct 24, 2023

@DiamondMyK Move it above "Libraries" in "General"

image

Should be little effort only.

@DiamondMyK
Copy link
Contributor

@DiamondMyK将其移至“常规”中的“库”上方

图像

应该只需要很少的努力。

Ok, I see what you mean! I will try my best to solve this problem!

@DiamondMyK
Copy link
Contributor

DiamondMyK commented Oct 28, 2023

111 Hello, I have modified according to your suggestions! Does this meet your expectations? I will submit my changes if the requirements are met. :) @koppor

@koppor
Copy link
Member

koppor commented Oct 28, 2023

I will submit my changes if the requirements are met. :) @koppor

I am so sorry that my new text proposal was not understandsable. By "(heading)" I meant, "Use 'Single instance' as heading".

Here an update on your screenshot:

image

Replace the skried-through text at "1" by "Enforce single JabRef instance (and allow remote operations)" and append "using"

The current settings links to the help page. https://docs.jabref.org/advanced/remote. Your explanation text in the UI is nice. JabRef, however, has currently very short items. The thing is that these texts need to be translated. We therefore opted to keep a link to the help pages. If the "final" preference is there, you can file an update pull request to https://github.com/JabRef/user-documentation/blob/main/en/advanced/remote.md

@tobiasdiez
Copy link
Member Author

I really like the explanation (maybe shorten it a little bit and use smaller font) and think we should do this more often. It's also quite common to see this (eg windows settings). On the other points I agree with olly

@DiamondMyK
Copy link
Contributor

I'm sorry I misunderstood you. Now I have made new changes according to your expectations, and the changed layout is shown in the figure. Does this meet your expectations? If there are no other questions, I will submit PR. :)
222

DiamondMyK added a commit to DiamondMyK/jabref that referenced this issue Oct 29, 2023
@DiamondMyK
Copy link
Contributor

Hello, I have completed the expectation of issue, if there is any problem, I will modify it again. Can I ask you to review and merge? I would appreciate it! :)

@Siedlerchr
Copy link
Member

I'll test it look later. But so far it looks good.

github-merge-queue bot pushed a commit that referenced this issue Oct 30, 2023
…ption to somewhere else (#10602)

* Fix issue #9306: Move "Open only one instance of JabRef" preference option to somewhere else

* edit issue#9306

* edit

* edit

* edit

* edit

* edit

* edit

* edit

* fix trustStoreManager NullPointerException

* use one action factory

---------

Co-authored-by: Siedlerchr <[email protected]>
@github-project-automation github-project-automation bot moved this from Reserved to Done in Good First Issues Oct 30, 2023
Siedlerchr added a commit to xuanan20020/jabref that referenced this issue Nov 1, 2023
* upstream/main:
  Fix CHANGELOG.md
  Bump commons-cli:commons-cli from 1.5.0 to 1.6.0 (JabRef#10607)
  Fix issue JabRef#9306: Move "Open only one instance of JabRef" preference option to somewhere else (JabRef#10602)
  Update README.md (JabRef#10604)
  Bump me.champeau.jmh from 0.7.1 to 0.7.2
  Bump org.beryx.jlink from 3.0.0 to 3.0.1
  Bump com.dlsc.gemsfx:gemsfx from 1.82.0 to 1.84.0
  Bump org.apache.logging.log4j:log4j-to-slf4j from 2.21.0 to 2.21.1

# Conflicts:
#	src/main/resources/l10n/JabRef_en.properties
Siedlerchr added a commit to guipmenezes/jabref that referenced this issue Nov 1, 2023
* upstream/main: (419 commits)
  Fix CHANGELOG.md
  Bump commons-cli:commons-cli from 1.5.0 to 1.6.0 (JabRef#10607)
  Fix issue JabRef#9306: Move "Open only one instance of JabRef" preference option to somewhere else (JabRef#10602)
  Update README.md (JabRef#10604)
  Bump me.champeau.jmh from 0.7.1 to 0.7.2
  Bump org.beryx.jlink from 3.0.0 to 3.0.1
  Bump com.dlsc.gemsfx:gemsfx from 1.82.0 to 1.84.0
  Bump org.apache.logging.log4j:log4j-to-slf4j from 2.21.0 to 2.21.1
  Synchronize scrollbars in the change resolver dialog (JabRef#10587)
  Add button for a user to reset the cite command to the default value. (JabRef#10580)
  openrerwrite
  Update .github/PULL_REQUEST_TEMPLATE.md
  Update PULL_REQUEST_TEMPLATE.md
  Update .github/PULL_REQUEST_TEMPLATE.md
  Update PULL_REQUEST_TEMPLATE.md
  Replace "fixes" by "resolves"
  Change JavaDoc to annotation (JabRef#10571)
  Fix link (JabRef#10575)
  Enable collecting GitHub build artifacts for forks (JabRef#10574)
  Fix file field merging (JabRef#10573)
  ...

# Conflicts:
#	src/main/java/org/jabref/gui/fieldeditors/identifier/IdentifierEditor.java
#	src/main/java/org/jabref/logic/importer/WebFetchers.java
Siedlerchr added a commit that referenced this issue Nov 4, 2023
* upstream/main: (1565 commits)
  Enable journal information fetcher directly in popup (#10598)
  Make generate button wider (#10588)
  make openRewrite stable again
  Rename cleanup_pr.yml to cleanup-pr.yml
  Changelog
  Fix failing fetcher tests (#10613)
  ShortDoi
  Fix CHANGELOG.md
  Bump commons-cli:commons-cli from 1.5.0 to 1.6.0 (#10607)
  Fix issue #9306: Move "Open only one instance of JabRef" preference option to somewhere else (#10602)
  Update README.md (#10604)
  Bump me.champeau.jmh from 0.7.1 to 0.7.2
  Bump org.beryx.jlink from 3.0.0 to 3.0.1
  Bump com.dlsc.gemsfx:gemsfx from 1.82.0 to 1.84.0
  Bump org.apache.logging.log4j:log4j-to-slf4j from 2.21.0 to 2.21.1
  Synchronize scrollbars in the change resolver dialog (#10587)
  Add button for a user to reset the cite command to the default value. (#10580)
  openrerwrite
  Update .github/PULL_REQUEST_TEMPLATE.md
  Update PULL_REQUEST_TEMPLATE.md
  ...

# Conflicts:
#	.devcontainer/devcontainer.json
#	build.gradle
#	src/main/java/org/jabref/gui/DefaultInjector.java
#	src/main/java/org/jabref/gui/libraryproperties/general/GeneralProperties.fxml
#	src/main/java/org/jabref/gui/libraryproperties/general/GeneralPropertiesView.java
#	src/main/java/org/jabref/gui/libraryproperties/general/GeneralPropertiesViewModel.java
#	src/main/java/org/jabref/logic/exporter/MetaDataSerializer.java
#	src/main/java/org/jabref/logic/importer/util/MetaDataParser.java
#	src/main/java/org/jabref/model/metadata/MetaData.java
#	src/main/java/org/jabref/preferences/JabRefPreferences.java
Siedlerchr added a commit to liyou969/jabref that referenced this issue Nov 4, 2023
* upstream/main: (44 commits)
  change codecov (JabRef#10616)
  Add entry based on ISSN number JabRef#10124 (JabRef#10178)
  Enable journal information fetcher directly in popup (JabRef#10598)
  Make generate button wider (JabRef#10588)
  make openRewrite stable again
  Rename cleanup_pr.yml to cleanup-pr.yml
  Changelog
  Fix failing fetcher tests (JabRef#10613)
  ShortDoi
  Fix CHANGELOG.md
  Bump commons-cli:commons-cli from 1.5.0 to 1.6.0 (JabRef#10607)
  Fix issue JabRef#9306: Move "Open only one instance of JabRef" preference option to somewhere else (JabRef#10602)
  Update README.md (JabRef#10604)
  Bump me.champeau.jmh from 0.7.1 to 0.7.2
  Bump org.beryx.jlink from 3.0.0 to 3.0.1
  Bump com.dlsc.gemsfx:gemsfx from 1.82.0 to 1.84.0
  Bump org.apache.logging.log4j:log4j-to-slf4j from 2.21.0 to 2.21.1
  Synchronize scrollbars in the change resolver dialog (JabRef#10587)
  Add button for a user to reset the cite command to the default value. (JabRef#10580)
  openrerwrite
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue An issue intended for project-newcomers. Varies in difficulty. preferences type: enhancement ui
Projects
Archived in project
6 participants