Giter Club home page Giter Club logo

powsybl-gse's People

Contributors

annetill avatar geofjamg avatar jonenst avatar mathbagu avatar miovd avatar murgeyseb avatar nashousni avatar nicolaslhuillier avatar pl-buiquang avatar powsybl-ci avatar yichen88 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

powsybl-gse's Issues

[NetworkExplorer] Difference between single or multiple drag

Currently, there is a discrimination of the drag event if it is a single element or multiple element in the onDragDetected() method in NetworkExplorer. Instead of doing this, we could consider that it is always a list of elements and handle the discrimination in the onDragDropped() methods in the targets.

[DnD] Drag&Drop in GroovyCodeArea

  • If one drag&drop plain text (from a text editor) to the GroovyCodeArea, the caret should follow the mouse move to help user to know where the text will be dropped.
  • One should be able to drag&drop from a script to another. For now, dragging move code inside the GroovyCodeArea

[DnD] Target node renderer

It is not really standard to change the text color to indicate which TreeNode is currently selected. For instance, in Windows Explorer, both source and target node are selected.

screenshot

Delete project tab when project is deleted in OpenProject window

Currently, if a project is deleted in the OpenProject Window while opened in project tab, the tab remains opened when deleted. It should either:

  • delete the project tab when the project is deleted in the OpenProject Window
  • forbid deleting projects opened in project tab

[NetworkExplorer] clear selection doesn't trigger a SelectionChangeEvent

If I select one element and I deselect it (ctrl+click), no event is triggered and the substationDetailedView view is not cleared.

There is the same kind of issue if I select two elements and I deselect one of them. If I deselect the second item, an event is triggered and the substationDetailedView view is not cleared.

I think there is an issue in the MultipleSelectionModel implementation. Could you try to find if there is an known issue in OpenJDK issue tracker and if possible, try to find a workaround (maybe a MouseEvent handler or something...)

Automatic module name

Configure maven-jar-plugin to generate automatic module:

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <configuration>
                    <archive>
                        <manifestEntries>
                            <Automatic-Module-Name>com.powsybl.XXXX</Automatic-Module-Name>
                        </manifestEntries>
                    </archive>
                </configuration>
            </plugin>

RteOpenData base voltage format has changed

  • Do you want to request a feature or report a bug?
    Bug

  • What is the current behavior?
    There is an AssertionError(63kv) thrown when we try to show the map. There is also an error for "INFERIEUR A 45 KV".
    We should be able to parse old and new versions of the OpenRTE data files.

  • If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem
    Download the last versions of RTE OpenData files (lignes-aeriennes-rte.csv, lignes-souterraines-rte.csv and postes-electriques-rte.csv) from https://opendata.reseaux-energies.fr
    Put these files in ~/.itools and show the map in GSE.

  • What is the expected behavior?
    The exception should not be thrown.

  • What is the motivation / use case for changing the behavior?

  • Please tell us about your environment:

    • PowSyBl Version: 2.4.1
    • OS Version: ...
  • Other information (e.g. detailed explanation, stacktraces, related issues, suggestions how to fix, links for us to have context, eg. stackoverflow, spectrum, etc)

(if a question doesn't apply, you can delete it)

Security Analysis Results filters not saved when switching between projects that have respectively precontingencies and postcontingencies in mapdb

  • Do you want to request a feature or report a bug?
    A bug

  • What is the current behavior?
    In the following circumstances, the filters of the security analysis results are not saved.

  • If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem
    Prepare 2 projects with security analyses, where one project has precontingency and the other postcontingency violations. Change the default filter on both projects to show the contingency. Close the GSE and reopen it. Only the filter of the project selected during shutdown is saved, the other is reset.

  • What is the expected behavior?
    Both filters should be saved.

  • Please tell us about your environment:

    • PowSyBl Version: 2.5
    • OS Version: linux

[Cosmetics] Dialog size

Dialogs should not be able to be shrunk to the point their elements are not visible anymore.

Refactor the creation and rename dialog

Almost all the creation and rename are the same but the code is duplicated.
I propose to create a generic class that can be extended to be completed for all dialogs that uses a NameTextField component:

  • Creation of contingencies, folder, action script, configuration,...)
  • Renaming

For more complex dialog (virtual case, security analysis), this class should be easy to complete with additional components.

File explorer: alphabetical instead of ASCII sort order

In the file explorer presented to the user to select files to be imported (e.g. network file), the folders are ordered following what seems to be an ASCII sort order.
A more classical and intuitive alphabetical rule might be more efficient for most users.

Drag&Drop a project tab inside and outside the GSE

It should be possible to drag&drop a project tab outside a GSE instance to create a complete new GSE window.
It should also be possible to drag&drop a project tab into an existing GSE instance. If the source window has no project tabs left, it should be closed.

window flicker/move on java11

Running on fedora 27 with gnome3. I'm running the exact same jar in both cases (adding the javafx jars manually for java11 since they were removed from the jdk)

On java 8, there is one flicker when the main window opens. The splash screen and the open dialog don't flicker.
java8

On java 11, it flickers everytime:
java11

We need to find if it's a bug in our code or not.

[DnD] Collapse source folder when dropping

Dropping an element should not collapse the source folder. Each node should stay in the same state (open or close) after dropping. I think there is a better solution than calling the refreshNode method which collapse/expand the nodes.

Improve the content of the tooltip of a project

Currently, the tooltip of a project shows its description

Project: <description>

If a project has no description, the content is not very interesting:

Project:

The tooltip should show the complete path (if not too long), and the description of the project:

Project: <path of the project>
Description: <description>

The description line should be shown only if the description is set.

[Bug] Renaming or moving an open file

Changing the name of an open file (by renaming it or moving it) should change the name of the tab. In current state, the name of the tab does not change.

The description of a project is not displayed

To reproduce the bug, you have to create a new project with a description. Once the project is created, click on the open button in the application bar. Browse in the folder to the project: the description column is empty.

gse-network-map unit tests

The classes DataTest, LineGraphicTest and MapTest are not in the good folder. The classes should be moved to src/test/java
The MapTest should be renamed because this class has no unit tests.
The DataTest can probably be removed because it checks nothing.

Crash when using a proxy without a user

  • Do you want to request a feature or report a bug?
    bug

  • What is the current behavior?
    The gse crashes during startup if a proxy config without a user/password is given

  • If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem
    Specify a proxy in config.yaml without a user:

proxy:    
  host: localhost                                                                           
  port: 3128         

or with a null value:

proxy:    
  host: localhost                                                                           
  port: 3128 
  user: ~
  password: ~        

equivalent to

proxy:    
  host: localhost                                                                           
  port: 3128 
  user: 
  password: 

The app crashes with the following stacktrace:
com.powsybl.commons.PowsyblException: Property user is not set
at com.powsybl.commons.config.AbstractModuleConfig.createPropertyNotSetException(AbstractModuleConfig.java:29)
at com.powsybl.commons.config.AbstractModuleConfig.lambda$getStringProperty$0(AbstractModuleConfig.java:34)
at java.util.Optional.orElseThrow(Optional.java:290)
at com.powsybl.commons.config.AbstractModuleConfig.getStringProperty(AbstractModuleConfig.java:34)
at com.powsybl.gse.util.GseUtil.lambda$setProxy$8(GseUtil.java:196)
at java.util.Optional.ifPresent(Optional.java:159)
at com.powsybl.gse.util.GseUtil.setProxy(GseUtil.java:193)
at com.powsybl.gse.app.GseApp.main(GseApp.java:94)
at com.powsybl.gse.demo.GseDemo.main(GseDemo.java:60)

  • What is the expected behavior?
    Without a user password, the code should just assume an unauthenticated proxy

  • What is the motivation / use case for changing the behavior?
    don"t force user to invent fake usernames/passwords

  • Please tell us about your environment:

    • PowSyBl Version: 2.4, GSE 1.4
  • Other information (e.g. detailed explanation, stacktraces, related issues, suggestions how to fix, links for us to have context, eg. stackoverflow, spectrum, etc)
    We should just change GseUtils.java public static void setProxy() to use getOptionalConfig, and create the authenticator only if they are set.

[DnD] Drag in GroovyScriptEditor without state variable

Currently, to detect a drag gesture in groovy script editor (GroovyScriptEditor.java), we use a state variable allowedDrag to check if this is indeed a drag or a selection gesture. This is not a good practice, this discrimination should be done differently.

Unable to load project due to missing dependency

When I change the dependencies of my project (removing for instance CGMES importer), the loading of a project fails and an error message is displayed to the user.

2018-12-18 08:47:44,089 ERROR [JavaFX Application Thread] c.p.g.u.GseUtil [GseUtil.java:139] com.powsybl.afs.AfsException: Importer not found for format CGMES
com.powsybl.afs.AfsException: Importer not found for format CGMES
	at com.powsybl.afs.ext.base.ImportedCase.lambda$getImporter$1(ImportedCase.java:67)
	at java.util.Optional.orElseThrow(Optional.java:290)
	at com.powsybl.afs.ext.base.ImportedCase.getImporter(ImportedCase.java:67)
	at com.powsybl.gse.afs.ext.base.BaseExtNodeGraphicProvider.getGraphic(BaseExtNodeGraphicProvider.java:58)
	at com.powsybl.gse.util.NodeGraphics.getGraphic(NodeGraphics.java:35)
	at com.powsybl.gse.app.ProjectPane.createFileTreeItem(ProjectPane.java:535)
	at com.powsybl.gse.app.ProjectPane.createNodeTreeItem(ProjectPane.java:481)
	at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
	at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1382)
	at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481)
	at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471)
	at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:708)
	at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
	at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:499)
	at com.powsybl.gse.app.ProjectPane.lambda$null$7(ProjectPane.java:507)
	at com.powsybl.gse.util.GseUtil.lambda$execute$4(GseUtil.java:130)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)

I think we have two options here:

  • close the project, because it is unusable
  • catch the exception, load the rest of the project and set as unknown this node (like in node chooser)

ContingencyStoreEditor: ergonomics

  1. Bind "delete" key to remove a Contingency or a ContingencyElement
  2. Bind "F2" key to rename a Contingency
  3. Dragging a Contingency or a ContingencyElement outside the editor should remove it
  4. Sometimes, it is difficult to drag&drop an equipment to create a new N-1 Contingency: you have to drop in the green area. If you drop upper the green area, a ContingencyElement is added to RIVENL61TARAS contingency (ref. screenshot)
    screenshot

[Bug] Bug in handling renamed files

Use case

  • create a contingency file "test"
  • rename your file "test1" via the context menu in the project pane
  • rename your file "test" via the context menu in the project pane -> return error "this file already exists"

image

  • delete your file (named "test1")
  • create a new file "test" -> return error "node not found"

image

Delete project

It should be possible to delete one or several projects from the OpenProject and NewProject windows

When deleting a contingency, the selected item in the panel is also prompted for deletion

  • Do you want to request a feature or report a bug?
    Bug

  • What is the current behavior?
    When selecting a contingency and pressing the Del key, the contingency is prompted for deletion, and then another prompt is show to delete the item that is selected in the left pane in the project file explorer. If instead you use the trash icon it works correctly.

  • If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem
    open the contingencies list, select something on the project explorer tab (by default the contingency list is already selected so this can be skipped), select a contingency and press the del key on the keyboard.

  • What is the expected behavior?
    No second prompt, like when clicking the trash icon

  • Please tell us about your environment:

    • PowSyBl Version: 2.5
    • OS Version: linux

[DnD] Implement Drag&Drop between two projects

Users should be able to Drag&Drop files or folders between two projects:

  • inside the same GSE application (dragging on the project tab should switch the active project, like a browser does).
  • between two GSE application
    I think we can use the archive/unarchive to fill the clipboard, to do a copy of a sub-tree between two projects.

Exception when relaunching a security analysis

  • Do you want to request a feature or report a bug?
    bug

  • What is the current behavior?
    There is an error popup window when relaunching a security analysis

  • If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem
    Run a security analysis, then close the project, then reopen the project, then run a security analysis again.

  • What is the expected behavior?
    No exception

  • Please tell us about your environment:

    • PowSyBl Version: 2.5
    • OS Version: linux
  • Other information (e.g. detailed explanation, stacktraces, related issues, suggestions how to fix, links for us to have context, eg. stackoverflow, spectrum, etc)

2019-05-06 18:34:53,163 ERROR [JavaFX Application Thread] c.p.g.u.GseUtil [GseUtil.java:138] com.powsybl.commons.PowsyblException: Variant index not set for current thread GSE-3
com.powsybl.commons.PowsyblException: Variant index not set for current thread GSE-3
	at com.powsybl.iidm.network.impl.ThreadLocalMultiVariantContext.getVariantIndex(ThreadLocalMultiVariantContext.java:23)
	at com.powsybl.iidm.network.impl.VariantManagerImpl.allowVariantMultiThreadAccess(VariantManagerImpl.java:183)
	at com.powsybl.security.afs.local.LocalSecurityAnalysisRunningService.run(LocalSecurityAnalysisRunningService.java:60)
	at com.powsybl.security.afs.SecurityAnalysisRunner.run(SecurityAnalysisRunner.java:82)
	at com.powsybl.gse.security.SecurityAnalysisExecutionTaskExtension.execute(SecurityAnalysisExecutionTaskExtension.java:43)
	at com.powsybl.gse.security.SecurityAnalysisExecutionTaskExtension.execute(SecurityAnalysisExecutionTaskExtension.java:21)
	at com.powsybl.gse.app.ProjectPane.lambda$executionTaskLaunch$28(ProjectPane.java:837)
	at com.powsybl.gse.util.GseUtil.lambda$execute$4(GseUtil.java:129)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.