GSoC'20 progress : Phase I related
Prasun Kumar
prasun.code at gmail.com
Tue Aug 11 06:39:36 BST 2020
Hi Ralf,
I have generated the export header files and tested the
KTOBLZCHECK_DEPRECATED macro by using it on a
required method which generated DEPRECATED warnings at build time. So,
this works as intended.
Can you list those functions ?
>>
> I'm coming later back to this, as you need to add the above mentioned
> stuff before we can decorate them.
>
If you can now confirm whether the methods I listed are okay to be
deprecated, I could then mark them using
this and open some merge requests.
Thanks.
Prasun
On Fri, 17 Jul 2020 at 01:11, <ralf.habacker at freenet.de> wrote:
> Hi Prasun,
>
>>
>>
> >Sorry, but I did not fully understand this. Can you explain a bit more?
> What is the purpose of GenerateExportHeader?
>
> For tagging a function/class as deprecated you need to decorate it with
> compiler specific switches e.g. __attribute__ ((__deprecated__)) for the
> gcc case.
>
> The mentioned macro supports such and other stuff. For a real example,
> please unpack the append zip file in to a local, say "source". Then run
>
> mkdir build
> cd build
> cmake ../source
> make
> make install DESTDIR=$PWD/tmp
>
>
> and inspect the installed files. You will see that cmake created a file
> name 'somelib_export.h', which provides some macros for example
> SOMELIB_DEPRECATED to tag deprecated functions in a compiler agnostic way,
> which is good.
>
>
>
> Additional there is a SOMELIB_EXPORT macro, which helps to export classes
> from shared libraries for Windows/MSVC and is required to build a shared
> ktoblzcheck library for Windows.
>
>
>
> See
> https://docs.microsoft.com/de-de/cpp/cpp/using-dllimport-and-dllexport-in-cpp-classes?view=vs-2019
> and
> https://stackoverflow.com/questions/6840576/how-to-export-a-c-class-from-a-dll
> for some docs.
>
>
>
> You will be able to implement such support by your own and using the macro
> may require some more effort to understand in the beginning, but it
> provides a standard way for solving such things.
>
>
>
> In our case using generate_export_header(ktoblzcheck) would probably be a
> good starting point.
>
>
>
>
>
>> Can you list those functions ?
>>
> I'm coming later back to this, as you need to add the above mentioned
> stuff before we can decorate them.
>
>
>
>
>
> Regards
>
> Ralf
> -----ursprüngliche Nachricht-----
> Von: prasun.code at gmail.com
> Gesendet: 16.07.2020 12:20 Uhr
> An: ralf.habacker at freenet.de, kde-finance-apps at kde.org
> Betreff: Re: Re: GSoC'20 progress : Phase I related
>
> I think we misunderstood here. Using DEPRECATED is a way to tag outdated
>> function. I made a mistake by adding an example, which I recognized later
>> that it is still required.
>
> Thanks for the clarification.
>
>
>> Can you list those functions ?
>>
>
> - std::time_t dataValidStartDate()
>
> - std::time_t dataValidEndDate()
> - std::time_t closestValidData(std::time_t date)
>
> There are some other methods which deal with datafile and dates but imo
> their implementation can be changed to allow them to work as intended.
> For e.g. std::string getFilenameClosestDateToday() could be implemented
> to just return the default database name and bool loadDataForDate(std::
> time_t date)
> could be implemented to only load the entries in database which were valid
> at the given date.
>
>
>> As there may be additional function be tagged as deprecated, the related
>> macros should go into one common file. cmake has support for generating
>> such files, see
>> https://cmake.org/cmake/help/v3.0/module/GenerateExportHeader.html and
>> https://stackoverflow.com/questions/16982144/cmake-and-generateexportheader
>> .
>>
> Sorry, but I did not fully understand this. Can you explain a bit more?
> What is the purpose of GenerateExportHeader?
>
> Thanks.
> Prasun
>
>
> On Sat, 11 Jul 2020 at 18:24, <ralf.habacker at freenet.de> wrote:
>
>>
>>
>> Hi Prasun,
>>
>> > As you suggested to not use the DEPRECATED macro, I could not find any
>> suitable thing to do with
>> them.
>>
>> I think we misunderstood here. Using DEPRECATED is a way to tag outdated
>> function. I made a mistake by adding an example, which I recognized later
>> that it is still required.
>> As there may be additional function be tagged as deprecated, the related
>> macros should go into one common file. cmake has support for generating
>> such files, see
>> https://cmake.org/cmake/help/v3.0/module/GenerateExportHeader.html and
>> https://stackoverflow.com/questions/16982144/cmake-and-generateexportheader
>> .
>>
>> Can you list those functions ?
>>
>> > Silly question, but could you suggest a good commit message after the
>> changes by code beautifier?
>>
>>
>>
>> Convert bank data support to Sqlite format ?
>>
>> Add some more details, add link to proposal
>>
>>
>> > Meanwhile, if you could give some pointers regarding the support of
>> additional countries,
>> > I could start planning for it according to my timeline.
>> I remember, I already wrote something about this at this, need to seach
>> for ...
>>
>> From the proposal:
>> - Add support for additional countries to the checking library.
>>
>> In the first step I suggest to implement downloading and generating
>> (additional) sqlite databases for additional countries (bankdata.<lang>.db)
>> to have valid test data (see below).
>> I suggest to start with one additional country for example 'netherland',
>> see below
>>
>> Then the api and tools should be extented to be able to select/use a
>> dedicated country.
>>
>> There are two ways
>>
>> ktoblzcheck --file bankdata.de.db ...
>> ktoblzcheck --file bankdata.nl.db ...
>> ktoblzcheck --file bankdata.ch.db ...
>>
>> When using the default instal location of database files there should be
>> a way to select the requested country
>>
>> ktoblzcheck [<country>] <bank-id> <account-id>
>>
>> e.g ktoblzcheck DE <bank-id> <account-id>
>>
>> and defaults to german bankdata if no country is given
>>
>> The same should be possible by using the api. Please make proposals for
>> extending the api.
>>
>> - The bankdata files also need to be added corresponding to these
>> countries.
>> At
>> https://invent.kde.org/office/kmymoney/-/tree/master/kmymoney/plugins/ibanbicdata
>> there are additional python scripts to generate databases for
>>
>> netherland -
>> https://invent.kde.org/office/kmymoney/-/blob/master/kmymoney/plugins/ibanbicdata/netherlands
>> switzerland -
>> https://invent.kde.org/office/kmymoney/-/blob/master/kmymoney/plugins/ibanbicdata/switzerland
>>
>>
>>
>> which need to be merged into ktoblzcheck. The raw bank data files
>> mentioned in the python scripts need to be fetched similar to the german
>> bank data files, the database must be created and installed.
>>
>>
>>
>> Regards
>>
>> Ralf
>>
>>
>>
>> -----ursprüngliche Nachricht-----
>> Von: prasun.code at gmail.com
>> Gesendet: 11.07.2020 06:33 Uhr
>> An: kde-finance-apps at kde.org
>> Betreff: Re: GSoC'20 progress : Phase I related
>>
>> Hi Ralf,
>> I have opened a merge request for the bug.
>> https://sourceforge.net/p/ktoblzcheck/code/merge-requests/10/
>>
>> Before opening a merge request for the commits, I would like to remind
>> you that I have
>> still not dealt with the methods of public API which do not make sense
>> any more. As you
>> suggested to not use the DEPRECATED macro, I could not find any suitable
>> thing to do with
>> them. Please advise if I should do anything regarding this.
>>
>>
>>> You may run uncrustify.sh [1] from the source dir before opening the
>>> merge request and check all commit messages against spelling errors.
>>>
>>
>> Silly question, but could you suggest a good commit message after the
>> changes by code beautifier?
>>
>> Meanwhile, if you could give some pointers regarding the support of
>> additional countries,
>> I could start planning for it according to my timeline.
>>
>> Thanks.
>> Prasun
>>
>>
>> On Fri, 10 Jul 2020 at 13:47, Ralf Habacker <ralf.habacker at freenet.de>
>> wrote:
>>
>>> Am 06.07.20 um 21:30 schrieb Prasun Kumar:
>>> Hi Prasun,
>>>
>>> > BTW: You can read the progress reports at my blog:
>>> > https://prasunka.github.io/tag/gsoc/
>>>
>>> Nice. To complete the first task to 100% the changes should be merged
>>> into the master branch of the ktoblzcheck project by opening a merge
>>> request. After this merge a new release can be make with this feature
>>> included.
>>>
>>> You may run uncrustify.sh [1] from the source dir before opening the
>>> merge request and check all commit messages against spelling errors.
>>>
>>> After opening the merge request, the mentors are going to review the
>>> changes and are merging the patches, if no issues will be found.
>>>
>>> [1] Unfortunally the mentioned script contains a bug
>>> (https://sourceforge.net/p/ktoblzcheck/bugs/5/), which need to be fixed
>>> first.
>>>
>>> Ralf
>>
>>
>> -----ursprüngliche Nachricht Ende-----
>>
>>
>>
> -----ursprüngliche Nachricht Ende-----
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-finance-apps/attachments/20200811/6793f9dc/attachment.htm>
More information about the Kde-finance-apps
mailing list